Class: Amorail::Contact
- Includes:
- Leadable
- Defined in:
- lib/amorail/entities/contact.rb
Overview
AmoCRM contact entity
Instance Method Summary collapse
- #company ⇒ Object
-
#reload ⇒ Object
Clear company cache.
Methods included from Leadable
Methods inherited from Entity
amo_field, amo_names, amo_property, attributes, find, find!, find_all, find_by_query, inherited, #initialize, #load_record, #new_record?, #params, #persisted?, properties, #reload_model, remote_url, #save, #save!, #update, #update!, where
Instance Method Details
#company ⇒ Object
25 26 27 28 29 |
# File 'lib/amorail/entities/contact.rb', line 25 def company return if linked_company_id.nil? @company ||= Amorail::Company.find(linked_company_id) end |
#reload ⇒ Object
Clear company cache
20 21 22 23 |
# File 'lib/amorail/entities/contact.rb', line 20 def reload @company = nil super end |