lib/centaman/service/update_member.rb in centaman-7.0.1 vs lib/centaman/service/update_member.rb in centaman-7.0.2
- old
+ new
@@ -2,19 +2,20 @@
module Centaman
class Service::UpdateMember < Centaman::Service
include Centaman::JsonWrapper
- attr_reader :id, :first_name, :last_name, :address,
- :gender, :phone, :email, :password, :is_primary
+ attr_reader :id, :first_name, :last_name, :address, :gender,
+ :date_of_birth, :phone, :email, :password, :is_primary
def after_init(args)
@id = args[:id].try(:to_i)
@first_name = args[:first_name].try(:squish)
@last_name = args[:last_name].try(:squish)
@address = args[:address].try(:symbolize_keys)
@gender = args[:gender]
+ @date_of_birth = args[:date_of_birth]
@phone = args[:phone]
@email = args[:email].try(:squish)
@password = args[:password]
@is_primary = args[:is_primary]
end
@@ -36,9 +37,10 @@
{
'FirstName' => first_name.try(:upcase),
'LastName' => last_name.try(:upcase),
'HomeAddress' => home_address,
'Gender' => gender,
+ 'DateOfBirth' => date_of_birth,
'Email' => email.try(:upcase),
'Password' => password,
'IsPrimary' => is_primary
}
end