No commit activity in last 3 years
No release in over 3 years
Calculate weight based charges for a Spree order
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 4.0.0
>= 0.7.0
>= 1.24
>= 4.2.8
>= 0.5.1
>= 0.3.2
~> 3.1.0
~> 3.1.0
>= 0.24.1
~> 4.0.0
~> 0.9.0
~> 1.3.9

Runtime

~> 2.4.0
 Project Readme

Spree Postal Service

Build Status Coverage Status Code Climate Gem Version

A postal service is delivers based on weight only(*). Like most post services in Europe will.

This Spree extension adds a spree-calculator to model this.

Other features:

  • Size and weight restrictions can be specified.
  • You specify a weight/price table.
  • Handling fee may be added ( with a maximum when it won't be applied anymore).
  • Multi-parcel shipments are automatically created.
  • You can specify a maximum order price, orders over this will not be charged.

Off course this relies on your weight data to be correct (and if you want the restrictions to work, the size data too). Use the same measurements as in the product info page.

(*) You may install several ShippingMethods for (usually) different countries.

Usage

Add to your Gemfile:

gem 'spree_postal_service', github: 'futhr/spree-postal-service', branch: 'master'

Go to admin interface:

http://localhost:3000/admin/shipping_methods/new

and use Postal Service as calculator.

The size/weight table must have the same amount of (space separated) entries.


Example

With the default settings (measurements in kg and cm):

  • Max weight of one item: 18
  • Max width of one item: 60
  • Max length of one item: 90
  • Default weight: 1kg (applies when product weight is 0)
  • Handling fee: 10
  • Amount, over which handling fee won't be applied: 50
  • Max total of the order: 120.0
  • Weights (space separated): 1 2 5 10 20
  • Prices (space separated): 6 9 12 15 18

Applies?

The Shipping method does not apply to the order if:

  • Any items weighs more than 18 kg.
  • Any item is longer than 90 cm.
  • Any items second longest side (width) is over 60 cm. Eg a 70x70x20 item.

Costs

  • Items weighing 10 kg of worth 100 Euros will cost 15 Euros.
  • Items weighing 10 kg of worth 40 Euros will cost 25 Euros (15 + 10 handling).
  • Items weighing less than 1 kg of worth 60 Euros will cost 6 Euros.
  • Items weighing less than 1 kg of worth 40 Euros will cost 16 Euros (6 + 10).
  • Items weighing 25 kg of worth 200 Euros will cost 30 Euros (2 packages, 18 + 12 Euro).
  • 3 items without weight information of worth 100 euros will cost 12 Euro.
  • Any amount of items costing more than the max_price will cost 0 Euro.

Contributing

See corresponding contributing guidelines.


License

Copyright (c) 2011-2017 Torsten RĂ¼ger, Tobias Bohwalli and other contributors, released under the New BSD License.