Module: Insightly::ContactInfoHelper
- Included in:
- Contact, Organisation
- Defined in:
- lib/insightly/contact_info_helper.rb
Instance Method Summary collapse
Instance Method Details
#add_contact_info(contact_info) ⇒ Object
12 13 14 15 16 |
# File 'lib/insightly/contact_info_helper.rb', line 12 def add_contact_info(contact_info) @data["CONTACTINFOS"] ||= [] @data["CONTACTINFOS"] << contact_info.remote_data true end |
#contact_infos ⇒ Object
3 4 5 6 |
# File 'lib/insightly/contact_info_helper.rb', line 3 def contact_infos @data["CONTACTINFOS"] ||= [] @data["CONTACTINFOS"].collect { |a| Insightly::ContactInfo.build(a) } end |
#contact_infos=(list) ⇒ Object
8 9 10 |
# File 'lib/insightly/contact_info_helper.rb', line 8 def contact_infos=(list) @data["CONTACTINFOS"] = list ? list.collect { |a| a.remote_data } : [] end |