-
- Downloads
[FIX] stock_landed_costs: set AML's account on its creation
To reproduce the issue: 1. create a product category with inventory valuation set as Manual 2. create a landed cost product using above category 3. enable anglo saxon accounting in accounting settings 4. create a vendor bill with this product and click save Error: An error is displayed because of a missing account We can remove the `create` override introduced by [1]. That way, we avoid: - a useless `create` layer - a possible write on an AML just after its creation The method `_get_computed_account` is called during the AML creation process: https://github.com/odoo/odoo/blob/8c8d657c85f76bd74d663843382af3dde8d885b8/addons/account/models/account_move.py#L2058 https://github.com/odoo/odoo/blob/8c8d657c85f76bd74d663843382af3dde8d885b8/addons/account/models/account_move.py#L1933 [1] f36c5c8a OPW-3251714 closes odoo/odoo#119022 Signed-off-by:William Henrotin (whe) <whe@odoo.com> Signed-off-by:
Adrien Widart <awt@odoo.com>
Showing
- addons/stock_account/models/account_move.py 4 additions, 1 deletionaddons/stock_account/models/account_move.py
- addons/stock_landed_costs/models/account_move.py 3 additions, 9 deletionsaddons/stock_landed_costs/models/account_move.py
- addons/stock_landed_costs/tests/test_stock_landed_costs.py 51 additions, 0 deletionsaddons/stock_landed_costs/tests/test_stock_landed_costs.py
Loading
Please register or sign in to comment