solidus
https://github.com/solidusio/solidus
Ruby
🛒 Solidus, the open-source eCommerce framework for industry trailblazers.
Spree::Stock::Coordinator#build_location_configured_packages
Build packages for the inventory units that have preferred stock locations first Certain variants have been selected to be fulfilled from a particular stock location during the process of the order being created. The rest of the service objects the coordinator uses do a lot of automated logic to determine which stock location is best for the inventory unit to be fulfilled from, but for these special snowflakes we KNOW which stock location they should be fulfilled from. So rather than sending these units through the rest of the packing / prioritization, lets just put them in packages we know they should be in and deal with other automatically- handled inventory units otherwise.
Edit
git clone [email protected]:solidusio/solidus.git
cd solidus
open core/app/models/spree/stock/coordinator.rb
Contribute
# Make a new branchgit checkout -b -your-name--update-docs-Spree--Stock--Coordinator-build_location_configured_packages-for-pr
# Commit to gitgit add core/app/models/spree/stock/coordinator.rbgit commit -m "better docs for Spree::Stock::Coordinator#build_location_configured_packages"
# Open pull requestgem install hub # on a mac you can `brew install hub`
hub fork
git push <your name> -your-name--update-docs-Spree--Stock--Coordinator-build_location_configured_packages-for-pr
hub pull-request
# Celebrate!