spree-contrib / spree_active_shipping

Spree integration for Shopify's active_shipping gem.
http://guides.spreecommerce.org
134 stars 207 forks source link

usps first class mail parcel returns 0 #256

Open shahzebjaved23 opened 7 years ago

shahzebjaved23 commented 7 years ago

I have a spree app, using the spree_active_shipping gem. It uses following for shipping methods,

all the methods calculated prices are correct, except the usps first class mail parcel service, which returns 0, I have selected the zone based in country, and selected united stated

Please let me know how to debug this issue, and how to log the api response that usps sends back. What can be the possible reasons for this ?

cgcmart commented 7 years ago

app/models/spree/calculator/shipping/usps/base.rb needs to be updated. Since the max_weight is determined at the calculator level, base.rb needs to compute max_weight(package) and make it a parameter that other calculators can process.

shahzebjaved23 commented 7 years ago

@99cm can you kindly specify exactly what updations need to be made in app/models/spree/calculator/shipping/usps/base.rb