Sha256: 2fefdfacba3e881b7b41d0329e31c8c43438b6082c5b476a9b7b52f85f54fa94

Contents?: true

Size: 1013 Bytes

Versions: 22

Compression:

Stored size: 1013 Bytes

Contents

module ActiveMerchant #:nodoc:
  module Billing #:nodoc:
    class PayflowExpressResponse < Response
      def email
        @params['e_mail']
      end

      def full_name
        "#{@params['name']} #{@params['lastname']}"
      end

      def token
        @params['token']
      end

      def payer_id
        @params['payer_id']
      end

      # Really the shipping country, but it is all the information provided
      def payer_country
        address['country']
      end

      def phone
        @params['phone']
      end

      def address
        {  'name'       => @params['shiptoname'] || full_name,
           'company'    => nil,
           'address1'   => @params['street'],
           'address2'   => @params['shiptostreet2'] || @params['street2'],
           'city'       => @params['city'],
           'state'      => @params['state'],
           'country'    => @params['country'],
           'zip'        => @params['zip'],
           'phone'      => phone }
      end
    end
  end
end

Version data entries

22 entries across 22 versions & 3 rubygems

Version Path
swiss-activemerchant-1.0.5 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
swiss-activemerchant-1.0.4 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.137.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
swiss-activemerchant-1.0.2 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
swiss-activemerchant-1.0.1 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.133.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.131.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.130.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.129.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.126.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.125.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
archetype2142_activemerchant-1.124.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.124.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.123.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.121.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.120.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.119.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.118.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.117.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
activemerchant-1.116.0 lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb