diff options
| author | Nicolas Martinelli <nim@odoo.com> | 2019-06-28 12:07:41 +0000 |
|---|---|---|
| committer | Goffin Simon <sig@odoo.com> | 2019-07-01 08:53:53 +0000 |
| commit | baf1580be44eab39f901d153f73546d4a4709588 (patch) | |
| tree | e6fcd1655af3de033caebab8939c5078075fe81a /addons/web_editor/static/src/xml/editor.xml | |
| parent | eedcaca503b3cea4953c088a4a181857553aa6b2 (diff) | |
[FIX] purchase_stock: average cost
- Create 2 rates:
2019-05-01: 1.0
2019-06-01: 0.5
- Set-up a product A in AVCO
- Create a PO for A on 2019-05-15
- Receive the product after 2019-06-01
The AML are created with a rate of 0.5, but the product cost is updated
with the rate of 1.0.
This is because the stock move date is used when it is still assigned,
and not done yet. As described in:
https://github.com/odoo/odoo/blob/2f789b6863407e63f90b3a2d4cc3be09815f7002/addons/stock/models/stock_move.py#L36
The date is the scheduled date until the move is done, then it is the
date of the actual move processing.
We change the date to today's date, since it is the value used to update
the move date:
https://github.com/odoo/odoo/blob/2f789b6863407e63f90b3a2d4cc3be09815f7002/addons/stock/models/stock_move.py#L1143
opw-2006368
closes odoo/odoo#34446
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
Diffstat (limited to 'addons/web_editor/static/src/xml/editor.xml')
0 files changed, 0 insertions, 0 deletions
