Created
June 18, 2012 05:24
-
-
Save aileron/2946977 to your computer and use it in GitHub Desktop.
Gem (active_paypal_adaptive_payment) 初期化コード config/initializers/paypal.rb
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
unless Rails.env.production? | |
ActiveMerchant::Billing::Base.mode = :test | |
end | |
config = YAML.load(ERB.new(File.read("#{Rails.root}/config/paypal.yml")).result)[Rails.env] | |
PaypalGateway = ActiveMerchant::Billing::PaypalAdaptivePayment.new( | |
:login => config["username"], | |
:password => config["password"], | |
:signature => config["signature"], | |
:appid => config["application_id"] | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment