./lib/ews/transaction/mapping.rb in exact4r-0.9.1 vs ./lib/ews/transaction/mapping.rb in exact4r-0.9.2

- old
+ new

@@ -11,68 +11,69 @@ # * REST/XML # * SOAP/XML class Mapping # :nodoc: XML_REQUEST_TAGS_TO_ATTRS = { - :ExactID => :gateway_id, - :Password => :password, - :Transaction_Type => :transaction_type, - :DollarAmount => :amount, - :SurchargeAmount => :surcharge_amount, - :Card_Number => :cc_number, - :Transaction_Tag => :transaction_tag, - :Track1 => :track1, - :Track2 => :track2, - :PAN => :pan, :Authorization_Num => :authorization_num, - :Expiry_Date => :cc_expiry, :CardHoldersName => :cardholder_name, - :VerificationStr1 => :cc_verification_str1, - :VerificationStr2 => :cc_verification_str2, + :Card_Number => :cc_number, + :CAVV => :cavv, + :CAVV_Algorithm => :cavv_algorithm, + :Client_Email => :client_email, + :Client_IP => :client_ip, + :Customer_Ref => :customer_ref, :CVD_Presence_Ind => :cvd_presence_ind, - :ZipCode => :zip_code, + :DollarAmount => :amount, + :Ecommerce_Flag => :ecommerce_flag, + :ExactID => :gateway_id, + :Expiry_Date => :cc_expiry, + :Language => :language, + :PAN => :pan, + :Password => :password, + :Reference_3 => :reference_3, + :Reference_No => :reference_no, + :Secure_AuthRequired => :secure_auth_required, + :Secure_AuthResult => :secure_auth_result, + :SurchargeAmount => :surcharge_amount, :Tax1Amount => :tax1_amount, :Tax1Number => :tax1_number, :Tax2Amount => :tax2_amount, :Tax2Number => :tax2_number, - :Secure_AuthRequired => :secure_auth_required, - :Secure_AuthResult => :secure_auth_result, - :Ecommerce_Flag => :ecommerce_flag, + :Track1 => :track1, + :Track2 => :track2, + :Transaction_Tag => :transaction_tag, + :Transaction_Type => :transaction_type, + :VerificationStr1 => :cc_verification_str1, + :VerificationStr2 => :cc_verification_str2, + :User_Name => :user_name, :XID => :xid, - :CAVV => :cavv, - :CAVV_Algorithm => :cavv_algorithm, - :Reference_No => :reference_no, - :Customer_Ref => :customer_ref, - :Reference_3 => :reference_3, - :Language => :language, - :Client_IP => :client_ip, - :Client_Email => :client_email + :ZipCode => :zip_code } unless defined?(XML_REQUEST_TAGS_TO_ATTRS) XML_RESPONSE_TAGS_TO_ATTRS = { - :LogonMessage => :logon_message, - :Error_Number => :error_number, - :Error_Description => :error_description, - :Transaction_Error => :transaction_error, - :Transaction_Approved => :transaction_approved, - :EXact_Resp_Code => :exact_resp_code, - :EXact_Message => :exact_message, - :Bank_Resp_Code => :bank_resp_code, + :AVS => :avs, :Bank_Message => :bank_message, + :Bank_Resp_Code => :bank_resp_code, :Bank_Resp_Code_2 => :bank_resp_code_2, - :SequenceNo => :sequence_no, - :AVS => :avs, - :CVV2 => :cvv2, - :Retrieval_Ref_No => :retrieval_ref_no, :CAVV_Response => :cavv_response, - :MerchantName => :merchant_name, + :CTR => :ctr, + :CVV2 => :cvv2, + :Error_Description => :error_description, + :Error_Number => :error_number, + :EXact_Message => :exact_message, + :EXact_Resp_Code => :exact_resp_code, + :LogonMessage => :logon_message, :MerchantAddress => :merchant_address, :MerchantCity => :merchant_city, - :MerchantProvince => :merchant_province, :MerchantCountry => :merchant_country, + :MerchantName => :merchant_name, :MerchantPostal => :merchant_postal, + :MerchantProvince => :merchant_province, :MerchantURL => :merchant_url, - :CTR => :ctr + :Retrieval_Ref_No => :retrieval_ref_no, + :SequenceNo => :sequence_no, + :Transaction_Approved => :transaction_approved, + :Transaction_Error => :transaction_error }.merge(XML_REQUEST_TAGS_TO_ATTRS) unless defined?(XML_RESPONSE_TAGS_TO_ATTRS) def self.request_to_json(request) request.to_json end \ No newline at end of file