9cd316f038dc95051814ede9474f8f15f7d165df
Currently the standard price for products with FIFO as cost_method, show the price of the next product to go out. It could be confusing on the report page because the standard price * quantity is different than the stock value. Another issue, is the margin, they are only computed on the last piece even if we sell multiple ones. For example: MOVE IN 5 units @ 10$ MOVE IN 5 units @ 20$ If we do an order for 10 units at 30$ each we will have a margin of 200$ (30$ - 10$)*10. And the report page will be 10*10$ --> 150$. The purpose of this task is to have always a report correct. For the margin it will not be always true because it's depending the number of pieces that we sell. In the above example: - if we sell 9 units, the margin will be better with this patch 135$/130$ with this commit and 90$/130$ without - but if we sell 6 units it will be closer to reality with the old patch. 90$/70$ and without 60$/70$ It has other implications: the inventory adjustement and edition of moves will now takes the AVCO values and not the next to go out. With the upper example if we add 10 units following an inventory adjustement (10 * `standard_price`): - With this commit: 150$ - Current behavior: 100$ Globally it will be closer to reality for products with a price having a lot of variance and it won't change for the other. Task-2918885 closes odoo/odoo#108468 Signed-off-by: William Henrotin (whe) <whe@odoo.com>
…
…
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
Languages
Python
49.6%
JavaScript
47.8%
SCSS
2%
CSS
0.3%
HTML
0.2%