[15.0][ADD] sale_product_matrix_secondary_unit: New module
With this module we'll be able to set the secondary units in the product matrix for a quick quotation for those products using this kind of configurator.
Depends on the following change to be reliable:
- [ ] https://github.com/OCA/sale-workflow/pull/3588
cc @Tecnativa TT52531
please take a look @sergio-teruel @CarlosRoca13 @pedrobaeza
In runboat i got this error when opening the matrix:
Error: QWeb2 - template['product_matrix.matrix']: No enumerator given to foreach
at Object.exception (http://oca-product-attribute-15-0-pr1854-7ca9f9ba4811.runboat.odoo-community.org/web/assets/debug/web.assets_common.js:57861:19) (/web/static/lib/qweb/qweb2.js:48)
at Object.foreach (http://oca-product-attribute-15-0-pr1854-7ca9f9ba4811.runboat.odoo-community.org/web/assets/debug/web.assets_common.js:58023:22) (/web/static/lib/qweb/qweb2.js:210)
at Engine.eval (eval at _render (http://oca-product-attribute-15-0-pr1854-7ca9f9ba4811.runboat.odoo-community.org/web/assets/debug/web.assets_common.js:58285:33), <anonymous>:19:23) (/web/static/lib/qweb/qweb2.js:472)
at Engine._render (http://oca-product-attribute-15-0-pr1854-7ca9f9ba4811.runboat.odoo-community.org/web/assets/debug/web.assets_common.js:58274:58) (/web/static/lib/qweb/qweb2.js:461)
at Engine.render (http://oca-product-attribute-15-0-pr1854-7ca9f9ba4811.runboat.odoo-community.org/web/assets/debug/web.assets_common.js:58266:26) (/web/static/lib/qweb/qweb2.js:453)
at Engine._render (http://oca-product-attribute-15-0-pr1854-7ca9f9ba4811.runboat.odoo-community.org/web/assets/debug/web.assets_common.js:58296:29) (/web/static/lib/qweb/qweb2.js:483)
at Engine.render (http://oca-product-attribute-15-0-pr1854-7ca9f9ba4811.runboat.odoo-community.org/web/assets/debug/web.assets_common.js:58266:26) (/web/static/lib/qweb/qweb2.js:453)
at Class._openMatrixConfigurator (http://oca-product-attribute-15-0-pr1854-7ca9f9ba4811.runboat.odoo-community.org/web/assets/debug/web.assets_backend.js:153961:30) (/sale_product_matrix_secondary_unit/static/src/js/section_and_note_widget.js:61)
at onSuccess (http://oca-product-attribute-15-0-pr1854-7ca9f9ba4811.runboat.odoo-community.org/web/assets/debug/web.assets_backend.js:151529:22) (/product_matrix/static/src/js/section_and_note_widget.js:78)
Hi..
The name on secondary is not shown correctly, the used field seems name instead of display_name
In matrix view
Some errors are shown when I mix different secondary units on same sale order
We can define different seconday units by variant, This is not covered, is it?
@CarlosRoca13 @sergio-teruel @pedrobaeza I’ve tested this module, and it works as expected based on the customer’s requirements. I’ve also added some tests. Please update your review and, if possible, proceed with the merge. I’m planning to migrate this module to v17.
/ocabot merge nobump
On my way to merge this fine PR! Prepared branch 15.0-ocabot-merge-pr-1854-by-pedrobaeza-bump-nobump, awaiting test results.
Congratulations, your PR was merged at 0f848fcfafb110ebc7fb1f5caf623e4708164aca. Thanks a lot for contributing to OCA. ❤️