cartodb/app/controllers/carto/api/state_presenter.rb
2020-06-15 10:58:47 +08:00

20 lines
367 B
Ruby

module Carto
module Api
class StatePresenter
def initialize(state)
@state = state
end
def to_hash
{
id: @state.id,
visualization_id: @state.visualization_id,
created_at: @state.created_at,
updated_at: @state.updated_at,
json: @state.json
}
end
end
end
end