Class: PaysonAPI::V2::Requests::Customer

Inherits:
Object
  • Object
show all
Defined in:
lib/payson_api/v2/requests/customer.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#cityObject

Returns the value of attribute city.



7
8
9
# File 'lib/payson_api/v2/requests/customer.rb', line 7

def city
  @city
end

#emailObject

Returns the value of attribute email.



7
8
9
# File 'lib/payson_api/v2/requests/customer.rb', line 7

def email
  @email
end

#first_nameObject

Returns the value of attribute first_name.



7
8
9
# File 'lib/payson_api/v2/requests/customer.rb', line 7

def first_name
  @first_name
end

#identity_numberObject

Returns the value of attribute identity_number.



7
8
9
# File 'lib/payson_api/v2/requests/customer.rb', line 7

def identity_number
  @identity_number
end

#last_nameObject

Returns the value of attribute last_name.



7
8
9
# File 'lib/payson_api/v2/requests/customer.rb', line 7

def last_name
  @last_name
end

#streetObject

Returns the value of attribute street.



7
8
9
# File 'lib/payson_api/v2/requests/customer.rb', line 7

def street
  @street
end

#zipObject

Returns the value of attribute zip.



7
8
9
# File 'lib/payson_api/v2/requests/customer.rb', line 7

def zip
  @zip
end

Instance Method Details

#to_hashObject



9
10
11
12
13
14
15
16
17
18
19
# File 'lib/payson_api/v2/requests/customer.rb', line 9

def to_hash
  {}.tap do |hash|
    hash['email'] = @email
    hash['firstName'] = @first_name
    hash['lastName'] = @last_name
    hash['identityNumber'] = @identity_number
    hash['postalCode'] = @zip
    hash['street'] = @street
    hash['city'] = @city
  end
end