Class: CapsuleCRM::Contact

Inherits:
Child show all
Defined in:
lib/capsulecrm/contact.rb

Direct Known Subclasses

Address, Email, Phone

Instance Attribute Summary collapse

Attributes inherited from Child

#parent

Attributes inherited from Base

#id, #raw_data

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Child

init_many, init_one, #initialize

Methods inherited from Base

#==, #errors, find, #initialize, last_response, #new_record?

Constructor Details

This class inherits a constructor from CapsuleCRM::Child

Instance Attribute Details

#typeObject

Returns the value of attribute type.



3
4
5
# File 'lib/capsulecrm/contact.rb', line 3

def type
  @type
end

Class Method Details

.xml_mapObject

nodoc



23
24
25
26
# File 'lib/capsulecrm/contact.rb', line 23

def self.xml_map
  map = {'type' => 'type'}
  super.merge map
end

Instance Method Details

#attributesObject

nodoc



7
8
9
10
11
12
13
14
# File 'lib/capsulecrm/contact.rb', line 7

def attributes
  attrs = {}
  arr = [:type]
  arr.each do |key|
    attrs[key] = self.send(key)
  end
  attrs
end