Class: PipedriveJetrockets::Organization
- Defined in:
- lib/pipedrive_jetrockets/organization.rb
Instance Method Summary collapse
-
#initialize(hash) ⇒ Organization
constructor
A new instance of Organization.
Methods inherited from Entity
#assign_custom_fields, #transform_field_name
Constructor Details
#initialize(hash) ⇒ Organization
Returns a new instance of Organization.
3 4 5 6 7 8 9 |
# File 'lib/pipedrive_jetrockets/organization.rb', line 3 def initialize(hash) @@key_name_hash ||= Pipedrive.organization_fields.key_field_hash super(hash.except(*@@key_name_hash.keys)) @id = hash['value'] if hash['value'].present? assign_custom_fields(@@key_name_hash, hash) end |