[19.0][MIG] product_packaging_calculator - #2363
Conversation
…ator And moved from OCA/stock-logistics-warehouse where it was already migrated. As this module doesn't depend on `stock`, there is no need for this module to: - be hosted in a stock-logistics-* repository - be named with prefix `stock_` `stock_packaging_calculator` will be transformed into a transitional module to install the new `product_packaging_calculator`.
…oaded With the changes introduced in odoo/odoo@de056cc#diff-b37c7fd5520c97a29ddc59495779e7be61a66e15e85603928e27b3affb9dc31f, an error was occurring because the change validation on the model was being performed before tearDownClass was executed. Therefore, it has been modified so that the mock changes are applied in each test and cleaned up after each test. This way, the error will no longer appear and the test will run normally.
Currently translated at 100.0% (5 of 5 strings) Translation: product-attribute-18.0/product-attribute-18.0-product_packaging_calculator Translate-URL: https://translation.odoo-community.org/projects/product-attribute-18-0/product-attribute-18-0-product_packaging_calculator/sl/
|
the commits before the module rename are missing, I am not sure this is something we can fix at this point, I think that had to be done in the PR of the rename 😕 according to this: https://github.com/OCA/maintainer-tools/wiki/Migration-to-version-19.0
|
AaronHForgeFlow
left a comment
There was a problem hiding this comment.
Functional review + code LGTM. Just minor comments.
|
|
||
| The minimal quantity is always represented by the UoM of the product. | ||
|
|
||
| Limitation: fractional quantities are lost. |
There was a problem hiding this comment.
I think fractionals are covered, see models/product.py:145-152
| from odoo import api, models | ||
| from odoo.tools import float_compare, float_is_zero, float_round | ||
|
|
||
| from odoo.addons.base_sparse_field.models.fields import Serialized |
There was a problem hiding this comment.
do you know why base_sparse_field is not a dependency in the manifest?
| return self[self._qty_by_pkg__product_field_name] | ||
|
|
||
| def _qty_by_packaging_get_qty(self): | ||
| return self[self._qty_by_pkg__qty_field_name] |
There was a problem hiding this comment.
perhaps we can cover the case where self._qty_by_pkg__qty_field_name is None?
Standard Migration
@ForgeFlow