Class: Seedy::Teams
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Record
#initialize, #inspect, #to_s, #to_sql
Constructor Details
This class inherits a constructor from Seedy::Record
Class Method Details
Instance Method Details
#associate(user) ⇒ Object
22 23 24 25 26 |
# File 'lib/seedy/records/teams.rb', line 22 def associate(user) write_attribute(:name, user.first_name + " " + user.last_name) write_attribute(:associated_user_id, user.id) write_attribute(:description, team_description) end |
#team_description ⇒ Object
28 29 30 |
# File 'lib/seedy/records/teams.rb', line 28 def team_description "Private team for #{read_attribute(:name)}" end |