diff options
| author | Swapnesh Shah <swapneshshah111@gmail.com> | 2020-07-16 18:41:25 +0000 |
|---|---|---|
| committer | Swapnesh Shah <swapneshshah111@gmail.com> | 2020-10-06 16:08:13 +0000 |
| commit | 7c658f4cbd832a3ede58701ec37103a0787fa818 (patch) | |
| tree | 52fba0404c913b2068bd3aaf84c9e4dd5f55fc0e /addons/website/static | |
| parent | f3cc47f49acec2e5e1a6fa8b56a8766fb614458d (diff) | |
[FIX] purchase_account: consider archived valuation layers
Before this this commit there would be `ZeroDivisionError` if product is archived.
Steps to Reproduce Issue:
Create product with AVCO and Automated Valuation
Create PO and Received all Quantities
Archive Product
Create Bill and Post
There will be Traceback
```
File "/data/build/odoo/addons/purchase_stock/models/account_invoice.py", line 84, in _stock_account_prepare_anglo_saxon_in_lines_vals
valuation_price_unit = valuation_price_unit_total / valuation_total_qty
ZeroDivisionError: division by zero
```
Now we consider Archived `stock_valuation_layer_ids` as well.
closes odoo/odoo#59312
X-original-commit: bedbc577d13148527fa9bab104eaf67b3ffba34f
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
Diffstat (limited to 'addons/website/static')
0 files changed, 0 insertions, 0 deletions
