Skip to content

nwb/spree_location_prioritizer

Repository files navigation

SpreeLocationPrioritizer

Spree 3.0 has the priotitizer to sort the package capability but not implemented. This gem/extenstion assume every stock location has its own serving countries and priorities. Example, stock location with priorities as {"ca" => 1, "all" => 0, "us" => 10000} , and location with prioties as {"ca" => 10000} The second location should serve Canadian customers when possible.

The coordinator will put all items into one package and ship from one warehouse. It will will not check the on_hand_count. If you want remove one item away from one stock location, delete it from the item location lists, not just set the on_hand_count to 0.

Installation

Add spree_location_prioritizer to your Gemfile:

gem 'spree_location_prioritizer'

Bundle your dependencies and run the installation generator:

bundle
bundle exec rails g spree_location_prioritizer:install

Testing

First bundle your dependencies, then run rake. rake will default to building the dummy app if it does not exist, then it will run specs. The dummy app can be regenerated by using rake test_app.

bundle
bundle exec rake

When testing your applications integration with this extension you may use it's factories. Simply add this require statement to your spec_helper:

require 'spree_location_prioritizer/factories'

Copyright (c) 2014 [name of extension creator], released under the New BSD License

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published