Class: Centaman::Object::Customer
- Inherits:
-
Centaman::Object
- Object
- Centaman::Object
- Centaman::Object::Customer
- Defined in:
- lib/centaman/object/customer.rb
Instance Attribute Summary collapse
-
#phone ⇒ Object
readonly
Returns the value of attribute phone.
Instance Method Summary collapse
-
#after_init(args) ⇒ Object
rubocop:disable Metrics/MethodLength.
- #attributes ⇒ Object
Methods inherited from Centaman::Object
#define_variables, #initialize
Constructor Details
This class inherits a constructor from Centaman::Object
Instance Attribute Details
#phone ⇒ Object (readonly)
Returns the value of attribute phone.
3 4 5 |
# File 'lib/centaman/object/customer.rb', line 3 def phone @phone end |
Instance Method Details
#after_init(args) ⇒ Object
rubocop:disable Metrics/MethodLength
5 6 7 |
# File 'lib/centaman/object/customer.rb', line 5 def after_init(args) @phone = args["Address"]["HomePhone"] end |
#attributes ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/centaman/object/customer.rb', line 9 def attributes [ Centaman::Attribute.new( centaman_key: 'MemberCode', app_key: :member_code, type: :integer ), Centaman::Attribute.new( centaman_key: 'MemberNumber', app_key: :member_number, type: :integer ), Centaman::Attribute.new( centaman_key: 'FirstName', app_key: :first_name, type: :string ), Centaman::Attribute.new( centaman_key: 'LastName', app_key: :last_name, type: :string ), Centaman::Attribute.new( centaman_key: 'Email', app_key: :email, type: :string ), ] end |