Class: Shipping::ShippingRate
- Inherits:
-
Object
- Object
- Shipping::ShippingRate
- Includes:
- ActiveModel::API, ActiveModel::Attributes, ActiveModel::Validations::Callbacks, StripAttributes
- Defined in:
- app/services/shipping/shipping_rate.rb
Class Method Summary collapse
Class Method Details
.expedited ⇒ Object
28 29 30 31 32 33 34 35 36 37 38 |
# File 'app/services/shipping/shipping_rate.rb', line 28 def self.expedited exp_values = { service: 'expedited', per_order: 15.00, per_pound: 1.50, multiplier_ak: 2.5, multiplier_hi: 2.5, early_am: 0.0 } exp_values end |
.priority ⇒ Object
40 41 42 43 44 45 46 47 48 49 50 |
# File 'app/services/shipping/shipping_rate.rb', line 40 def self.priority pty_values = { service: 'rush', per_order: 25.00, per_pound: 2.50, multiplier_ak: 2.0, multiplier_hi: 2.0, early_am: 0.0 } pty_values end |
.priority_am ⇒ Object
52 53 54 55 56 57 58 59 60 61 62 |
# File 'app/services/shipping/shipping_rate.rb', line 52 def self.priority_am pty_am_values = { service: 'rush early am', per_order: 25.00, per_pound: 2.50, multiplier_ak: 2.0, multiplier_hi: 2.0, early_am: 10.0 } pty_am_values end |
.standard ⇒ Object
15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'app/services/shipping/shipping_rate.rb', line 15 def self.standard std_values = { service: 'ground', per_order: 8.00, # order handling is $8.00 dollars. per_pound: 0.50, # cost by weight handling is $0.50 ctvs. multiplier_ak: 4.0, # When you ship to Alaska you should multiply the total by 4. multiplier_hi: 5.0, # When you ship to Hawaii you should multiply the total by 5. per_oversize: 0.5, # the increase should be 50% when length, width or height are greater than 48 inches. early_am: 0.0 # additional cost if the customer wants to receive package early morning. } std_values end |