Sha256: 881af569848d57a119138431066ad41a5247e4584d9089ea263b3dcffb6f5efa

Contents?: true

Size: 1.07 KB

Versions: 17

Compression:

Stored size: 1.07 KB

Contents

module ActiveMerchant #:nodoc:
  module Billing #:nodoc:
    module Integrations #:nodoc:
      module Webmoney
        class Helper < ActiveMerchant::Billing::Integrations::Helper
          include Common

          def initialize(order, account, options = {})
            @webmoney_options = options.dup
            options.delete(:description)
            options.delete(:fail_url)
            options.delete(:success_url)
            options.delete(:result_url)
            super
            @webmoney_options.each do |key, value|
              add_field mappings[key], value
            end
          end

          def form_fields
            @fields
          end

          def params
            @fields
          end

          mapping :account, 'LMI_PAYEE_PURSE'
          mapping :amount, 'LMI_PAYMENT_AMOUNT'
          mapping :order, 'LMI_PAYMENT_NO'
          mapping :description, 'LMI_PAYMENT_DESC'
          mapping :fail_url, 'LMI_FAIL_URL'
          mapping :success_url, 'LMI_SUCCESS_URL'
          mapping :result_url, 'LMI_RESULT_URL'
        end
      end
    end
  end
end

Version data entries

17 entries across 17 versions & 2 rubygems

Version Path
activemerchant-1.35.0 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.35.1 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.34.1 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.34.0 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.33.0 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.32.1 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.32.0 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.31.1 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.31.0 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.30.0 lib/active_merchant/billing/integrations/webmoney/helper.rb
jelaniharris-activemerchant-1.29.2 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.29.3 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.29.2 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.29.1 lib/active_merchant/billing/integrations/webmoney/helper.rb
jelaniharris-activemerchant-1.29.1 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.29.0 lib/active_merchant/billing/integrations/webmoney/helper.rb
activemerchant-1.28.0 lib/active_merchant/billing/integrations/webmoney/helper.rb