Class: Trello::Label

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

Overview

A colored Label attached to a card

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

Update the fields of a label.

Supply a hash of stringkeyed data retrieved from the Trello API representing a label.



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

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