* product.category: remove complete_name field as display_name can be used
where the field was used
* product.supplierinfo: remove computed qty field. This field originally
contained the min_qty computed into the product_uom. However commit
3c186c5807 broke that field without reason.
Since 2011 no one complained about this field being unnecessary, so let us
remove it.
* product.template: shorter and less spaghetti version of create_variant
method
* product_product._sellect_seller: fix use of default parameter in method
kwargs + use odoo standard datetime default value
A new API is introduced for price computing using pricelists. It is simplier
to use in most use cases, which is computing the product price in a given
pricelist. Old methods return dictionnaries and tuples, which are rarely
used in the code.
product_uom._compute_quantity is an ensure one multi method taking a browse
record as second paramter. It replaces _compute_qty and _compute_qty_obj
to have a single and standard computation method.
product_uom._compute_price() is now an ensure_one multi methods, taking
a browse record as second unit. This helps simplifying and unifying the
various calls and price computation methods.
Old price_get method is now replaced by price_compute and ready for migration.
Explicit parameters for unit of measure and currency have been added to ease
code understanding.
product.py and product_views.xml contained code related to several models.
This commit split those files to separate submodels :
* decimal_precision
* product_attribute: product.attribute, product.attribute.value,
product.attribute.line
* product_template: product.template
* product_uom: product.uom and product.uom.categ
* res_currency
Product now contains product.product model, along with some smaller
models (product.packaging, product.supplierinfo, product.category,
product.price.history)
The less refactoring in 5b65befcd8
wrongly removed the css directive that hide some elements in edit mode.
As a side effect, the product price was appearing twice when editing a
product. Commit 44ca4317a9 tempt to fix
it but removed the edition part.
opw:683343
The field state was replaced by ‘active’ in project.project (see commit 9b69184).
However, someone forgot to update the arch for the default list view which
was not longer possible to open.