Class: Teambox::Page
- Defined in:
- lib/teambox-client/models/page.rb
Instance Attribute Summary
Attributes inherited from Resource
Instance Method Summary collapse
- #project ⇒ Object
-
#slots ⇒ Object
Returns an Array of Teambox::PageSlot.
-
#url ⇒ Object
:nodoc:.
- #user ⇒ Object
Methods inherited from Resource
#created_at, #destroy, #id, #initialize, #inspect, #method_missing, #next, #prev, #reload, #save, #updated_at
Methods included from ReferenceList
#generate_references, #get_or_make_reference, #get_or_make_references, #get_reference, #set_reference
Constructor Details
This class inherits a constructor from Teambox::Resource
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Teambox::Resource
Instance Method Details
#project ⇒ Object
7 8 9 |
# File 'lib/teambox-client/models/page.rb', line 7 def project get_or_make_reference('Project', @data, 'project_id') end |
#slots ⇒ Object
Returns an Array of Teambox::PageSlot
12 13 14 |
# File 'lib/teambox-client/models/page.rb', line 12 def slots get_or_make_references('PageSlot', @data, 'slot_ids', 'slots') end |
#url ⇒ Object
:nodoc:
16 17 18 |
# File 'lib/teambox-client/models/page.rb', line 16 def url #:nodoc: "/projects/#{@data['project_id']}/pages/#{@data['id']}" end |
#user ⇒ Object
3 4 5 |
# File 'lib/teambox-client/models/page.rb', line 3 def user get_or_make_reference('User', @data, 'user_id') end |