Class: Trello::Item

Inherits:
BasicData show all
Defined in:
lib/trello/item.rb

Overview

An Item is a basic task that can be checked off and marked as completed.

Instance Method Summary collapse

Methods inherited from BasicData

#==, find, #initialize, many, one, #refresh!, register_attributes

Constructor Details

This class inherits a constructor from Trello::BasicData

Instance Method Details

#update_fields(fields) ⇒ Object

Updates the fields of an item.

Supply a hash of string keyed data retrieved from the Trello API representing an item.



11
12
13
14
15
16
# File 'lib/trello/item.rb', line 11

def update_fields(fields)
  attributes[:id]   = fields['id']
  attributes[:name] = fields['name']
  attributes[:type] = fields['type']
  self
end