Skip methods that distributor can't use in Package

This ensures that Spree's shipping methods take into account the ones
the order's distributor uses.

This reimplements what `#available_to_order_with_distributor_check?`
used to do and it doesn't work with Spree 2.0.4.
This commit is contained in:
Pau Perez
2018-04-30 13:54:40 +02:00
parent 6784621c1b
commit 776b5a23f6
4 changed files with 86 additions and 6 deletions

View File

@@ -20,6 +20,8 @@ Spree.config do |config|
# Auto-capture payments. Without this option, payments must be manually captured in the paypal interface.
config.auto_capture = true
#config.override_actionmailer_config = false
config.package_factory = Stock::Package
end
# TODO Work out why this is necessary