Sha256: db0207eb1b94c4fda70379a5b0995c84c0dbd84d95519faf763e85d39ae5d649

Contents?: true

Size: 1.61 KB

Versions: 58

Compression:

Stored size: 1.61 KB

Contents

module ActiveMerchant #:nodoc:
  module Billing #:nodoc:
    module Integrations #:nodoc:

      # Documentation: http://robokassa.ru/Doc/En/Interface.aspx
      module Robokassa
        autoload :Helper, File.dirname(__FILE__) + '/robokassa/helper.rb'
        autoload :Notification, File.dirname(__FILE__) + '/robokassa/notification.rb'
        autoload :Return, File.dirname(__FILE__) + '/robokassa/return.rb'
        autoload :Common, File.dirname(__FILE__) + '/robokassa/common.rb'

        # Overwrite this if you want to change the Robokassa test url
        mattr_accessor :test_url
        self.test_url = 'http://test.robokassa.ru/Index.aspx'

        # Overwrite this if you want to change the Robokassa production url
        mattr_accessor :production_url
        self.production_url = 'https://merchant.roboxchange.com/Index.aspx'

        mattr_accessor :signature_parameter_name
        self.signature_parameter_name = 'SignatureValue'

        def self.service_url
          mode = ActiveMerchant::Billing::Base.integration_mode
          case mode
          when :production
            self.production_url
          when :test
            self.test_url
          else
            raise StandardError, "Integration mode set to an invalid value: #{mode}"
          end
        end

        def self.helper(order, account, options = {})
          Helper.new(order, account, options)
        end

        def self.notification(query_string, options = {})
          Notification.new(query_string, options)
        end

        def self.return(query_string)
          Return.new(query_string)
        end
      end
    end
  end
end

Version data entries

58 entries across 58 versions & 5 rubygems

Version Path
activemerchant-1.29.3 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.29.2 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.29.1 lib/active_merchant/billing/integrations/robokassa.rb
jelaniharris-activemerchant-1.29.1 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.29.0 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-nsp-1.27.0 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.28.0 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.27.0 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.26.0 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.25.0 lib/active_merchant/billing/integrations/robokassa.rb
jelaniharris-activemerchant-1.24.1 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.24.0 lib/active_merchant/billing/integrations/robokassa.rb
tlconnor-activemerchant-1.23.3 lib/active_merchant/billing/integrations/robokassa.rb
tlconnor-activemerchant-1.23.2 lib/active_merchant/billing/integrations/robokassa.rb
tlconnor-activemerchant-1.23.1 lib/active_merchant/billing/integrations/robokassa.rb
tlconnor-activemerchant-1.23.0 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.23.0 lib/active_merchant/billing/integrations/robokassa.rb
activemerchant-1.22.0 lib/active_merchant/billing/integrations/robokassa.rb