Class: DashCreator::Chart

Inherits:
ApplicationRecord show all
Defined in:
app/models/dash_creator/chart.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#user_idObject

Returns the value of attribute user_id.



3
4
5
# File 'app/models/dash_creator/chart.rb', line 3

def user_id
  @user_id
end

Instance Method Details

#as_json(options = {}) ⇒ Object



8
9
10
11
12
13
14
# File 'app/models/dash_creator/chart.rb', line 8

def as_json(options = {})
  json = {
      name: name,
      data: data
  }
  json
end