Atul Patel d76e608da4 [FIX] product: fixed wrong value for cost_currency_id
will get multiple company with multiple currency record
as it will try to calculate multiple template
cost currency field value. we need to do iteration
for template record then it will resolve the error.
Error has been introduced during upgrade.

```
  File "/home/odoo/src/odoo/saas-16.4/addons/product/models/product_template.py", line 189, in _compute_cost_currency_id
    self.cost_currency_id = self.company_id.currency_id or self.env.company.currency_id.id
   File "/home/odoo/src/odoo/saas-16.4/odoo/fields.py", line 1306, in __set__
    self.write(protected_records, value)
   File "/home/odoo/src/odoo/saas-16.4/odoo/fields.py", line 3087, in write
    cache_value = self.convert_to_cache(value, records)
   File "/home/odoo/src/odoo/saas-16.4/odoo/fields.py", line 3010, in convert_to_cache
    raise ValueError("Wrong value for %s: %r" % (self, value))
 ValueError: Wrong value for product.template.cost_currency_id: res.currency(2, 139)
```

closes odoo/odoo#144523

X-original-commit: a8d884b8fb47ad0ac3960ffc5f84f5c6316d20a6
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
Signed-off-by: Atul Patel (atp) <atp@odoo.com>
2023-12-01 18:14:22 +00:00
2023-10-27 08:36:16 +00:00
2023-11-02 21:02:44 +00:00
2023-11-20 04:58:31 +00:00
2023-12-01 18:14:20 +00:00
…
…
…
…

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials

S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%