Class: Moneybird::Resource::Contact

Inherits:
Object
  • Object
show all
Extended by:
ClassMethods
Includes:
Moneybird::Resource
Defined in:
lib/moneybird/resource/contact.rb

Instance Attribute Summary

Attributes included from ClassMethods

#attributes, #logger, #nillable_attributes

Attributes included from Moneybird::Resource

#client, #errors

Instance Method Summary collapse

Methods included from ClassMethods

build, has_attributes, has_boolean_attributes, has_datetime_attributes, has_integer_attributes, has_nillable_attributes, resource

Methods included from Moneybird::Resource

#attributes, #attributes=, #initialize, #link_booking, #path, #persisted?, #to_json

Instance Method Details

#custom_fields=(custom_fields) ⇒ Object



64
65
66
# File 'lib/moneybird/resource/contact.rb', line 64

def custom_fields=(custom_fields)
  @custom_fields = custom_fields.map { |custom_field| Moneybird::Resource::CustomField.build(custom_field) }
end

#events=(events) ⇒ Object



60
61
62
# File 'lib/moneybird/resource/contact.rb', line 60

def events=(events)
  @events = events.map{ |event| Moneybird::Resource::Generic::Event.build(event) }
end

#notes=(notes) ⇒ Object



56
57
58
# File 'lib/moneybird/resource/contact.rb', line 56

def notes=(notes)
  @notes = notes.map{ |note| Moneybird::Resource::Generic::Note.build(note) }
end