Class: Basecampx::Todo

Inherits:
Resource show all
Defined in:
lib/basecampx/resources/todo.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Methods inherited from Resource

#delete, #initialize, parse, #save, #update_attributes

Methods included from Relations

#has_many, #has_one, #mount

Constructor Details

This class inherits a constructor from Basecampx::Resource

Instance Attribute Details

#attachmentsObject

Returns the value of attribute attachments.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def attachments
  @attachments
end

#comments_countObject

Returns the value of attribute comments_count.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def comments_count
  @comments_count
end

#completedObject

Returns the value of attribute completed.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def completed
  @completed
end

#contentObject

Returns the value of attribute content.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def content
  @content
end

#created_atObject

Returns the value of attribute created_at.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def created_at
  @created_at
end

#due_atObject

Returns the value of attribute due_at.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def due_at
  @due_at
end

#idObject

Returns the value of attribute id.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def id
  @id
end

#positionObject

Returns the value of attribute position.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def position
  @position
end

#todolist_idObject

Returns the value of attribute todolist_id.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def todolist_id
  @todolist_id
end

#updated_atObject

Returns the value of attribute updated_at.



4
5
6
# File 'lib/basecampx/resources/todo.rb', line 4

def updated_at
  @updated_at
end

Class Method Details

.find(project_id, todo_id) ⇒ Object



12
13
14
# File 'lib/basecampx/resources/todo.rb', line 12

def self.find project_id, todo_id
  Todo.new Basecampx.request "projects/#{project_id}/todos/#{todo_id}.json"
end