Class: Calculator::Ups::Base
- Inherits:
-
ActiveShipping
- Object
- ActiveShipping
- Calculator::Ups::Base
- Defined in:
- app/models/calculator/ups/base.rb
Direct Known Subclasses
Ground, NextDayAir, NextDayAirEarlyAm, NextDayAirSaver, Saver, SecondDayAir, ThreeDaySelect, WorldwideExpedited
Instance Method Summary collapse
Instance Method Details
#carrier ⇒ Object
2 3 4 5 6 7 8 9 10 11 12 13 14 |
# File 'app/models/calculator/ups/base.rb', line 2 def carrier if Spree::ActiveShipping::Config[:shipper_number].nil? ActiveMerchant::Shipping::UPS.new(:login => Spree::ActiveShipping::Config[:ups_login], :password => Spree::ActiveShipping::Config[:ups_password], :key => Spree::ActiveShipping::Config[:ups_key]) else ActiveMerchant::Shipping::UPS.new(:login => Spree::ActiveShipping::Config[:ups_login], :password => Spree::ActiveShipping::Config[:ups_password], :key => Spree::ActiveShipping::Config[:ups_key], :origin_account => Spree::ActiveShipping::Config[:shipper_number]) end end |