Class: Group

Inherits:
ActiveRecord::Base
  • Object
show all
Defined in:
app/models/group.rb

Instance Method Summary collapse

Instance Method Details

#as_jsonObject



23
24
25
26
27
28
29
30
# File 'app/models/group.rb', line 23

def as_json
  {
    :id => id,
    :title => title,
    :icon => icon.url,
    :parent => group_id
  }
end

#icon_urlObject



19
20
21
# File 'app/models/group.rb', line 19

def icon_url
  icon.url
end