[16.0][FIX]purchase_manual_delivery: pending in forecast
Purchase Order Lines that are pending to receive are not considered for stock forecast. Thus, the manual and automatic reordering of products can be done despite having already create a Purchase Order and surpassing the max quantity. Confirmed Purchase Orders with pending to receive Purchase Order Lines are now considered at the forecast and the forecast report.
How to replicate at the runboat: Assumption: Manual Delivery is already enabled in the settings
- Login as Admin
- Go to Inventory/Configuration/Reordering Rules
- Create a new Rule
- Set "[E-COM10] Pedal bin" as Product, Min Quantity to 50 and Max Quantity to 100
- The forecast should be 22
- Click the button "Order once"
- The forecast changed to 100
- Click on the button "Forecast Report" for the product "[E-COM10] Pedal bin" and then on the Purchase Order that just got created
- Confirm the Purchase Order
- Go back to the "Reordering Rules" or the "Forecast Report" The Purchase Order is no part of the forecast anymore. Therefore, the "Order Once" button is shown again and when automatic reordering would trigger as well.
Picked in my 17.0 migration https://github.com/OCA/purchase-workflow/pull/2417
/ocabot merge major
What a great day to merge this nice PR. Let's do it! Prepared branch 16.0-ocabot-merge-pr-2383-by-HviorForgeFlow-bump-major, awaiting test results.
@HviorForgeFlow your merge command was aborted due to failed check(s), which you can inspect on this commit of 16.0-ocabot-merge-pr-2383-by-HviorForgeFlow-bump-major.
After fixing the problem, you can re-issue a merge command. Please refrain from merging manually as it will most probably make the target branch red.
/ocabot merge major
This PR looks fantastic, let's merge it! Prepared branch 16.0-ocabot-merge-pr-2383-by-HviorForgeFlow-bump-major, awaiting test results.
Congratulations, your PR was merged at fbaae0d7537ebb051aac7aff11486db2e38b4a77. Thanks a lot for contributing to OCA. ❤️