-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
[18.0][MIG] sale_procurement_group_by_line: Migration to 18.0. #3420
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[18.0][MIG] sale_procurement_group_by_line: Migration to 18.0. #3420
Conversation
This module extract logic to create multiple procurement group for a single sale order for grouped sale order lines.
* Fix OCA#264 * Fix : Can't create delivery from shipping exception
* [ADD] [9.0] sale_delivery_block * [IMP] Add data with an example Delivery Block Reason. * [FIX] * Able to edit the Delivery Block Reason in state 'sent' * README * [FIX] make sale_delivery_block compatible with sale_procurement_group_by_line * [FIX] travis and data nouptade. * [ADD] delivery block tests. * [IMP] Add the 'Default Delivery Block Reason' in partners. * [IMP] track visibility of delivery block reason * [9.0][IMP] sale_delivery_block: * default_delivery_block is now a comercial field. * When duplicating a sale order the delivery block is recomputed. * [9.0][UPD] sale_delivery_block_proc_group_by_line: Update README. * [FIX] api.model used with api.constrains
Currently translated at 66.7% (2 of 3 strings) Translation: sale-workflow-11.0/sale-workflow-11.0-sale_procurement_group_by_line Translate-URL: https://translation.odoo-community.org/projects/sale-workflow-11-0/sale-workflow-11-0-sale_procurement_group_by_line/de/
Currently translated at 100.0% (3 of 3 strings) Translation: sale-workflow-13.0/sale-workflow-13.0-sale_procurement_group_by_line Translate-URL: https://translation.odoo-community.org/projects/sale-workflow-13-0/sale-workflow-13-0-sale_procurement_group_by_line/es/
…_qty. This avoids duplicated procurements in some cases, basically for any operation that has a specific `<sale.order.line>._get_qty_procurement` relying on `previous_product_uom_qty`. E.g: manufacturing kits, dropshipping...
…uom_qty Prevents having duplicated procurements when having several order lines involving any operation that has a specific `<sale.order.line>._get_qty_procurement` relying on `previous_product_uom_qty` (Manufacturing kits, dropshipping..)
Currently translated at 100.0% (6 of 6 strings) Translation: sale-workflow-15.0/sale-workflow-15.0-sale_procurement_group_by_line Translate-URL: https://translation.odoo-community.org/projects/sale-workflow-15-0/sale-workflow-15-0-sale_procurement_group_by_line/ca/
Before the fix, when new quantities are added into an already confirmed line, we are writing in the previous_product_uom_qty only the new qty that has been processed, not the total amount that has actually been processed for the line. Due to this, when we call super() on _action_launch_stock_rule, the new quantities are procured again, as we have not really updated the amount in previous_product_uom_qty including what we have already procured before calling super().
…ing qty in a sales order
c22bae1 to
efd1ae8
Compare
sale_procurement_group_by_line/tests/test_sale_procurement_group_by_line.py
Outdated
Show resolved
Hide resolved
efd1ae8 to
cac406c
Compare
e6c97a9 to
9fc802a
Compare
9fc802a to
1c7646d
Compare
|
Added v17 changes in a separated commit (a forward port of #3428). |
|
This PR has the |
|
Hi @rousseldenis, could you check this PR? Thank you very much! 😄 |
|
/ocabot migration sale_procurement_group_by_line |
| line.state != "sale" | ||
| or line.order_id.locked | ||
| or line.product_id.type not in ("consu", "product") | ||
| or line.product_id.type != "consu" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm wondering if we should test is_storable field
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @rousseldenis, I see Odoo does this
sale_stock/models/sale_order_line.py#L357
Although is_storable=False implies no inventory tracking, consumable products (type: consu, is_storable: False) may still require provisioning rules.
Do you agree?
rvalyi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
code review LGTM
|
/ocabot merge nobump |
|
Hey, thanks for contributing! Proceeding to merge this for you. |
|
Congratulations, your PR was merged at 4acf5aa. Thanks a lot for contributing to OCA. ❤️ |
Migration to 18.0
@ForgeFlow