odoo/odoo#189216

Created by fw-bot
Merged at 0c633e3a6733030f8004e2c2a2dc448bbb00811f

Statuses:

label
odoo-dev:saas-17.4-16.0-opw-4347110-fix-agr-3XB0-fw
head
2ee02910e7b3e1dc2144abf7df0b923a6f0af52e
merged
1 year ago by Bugfix, Andrea Grazioso (agr)
odoo/odoo
16.0 #188865
17.0 #189130
saas-17.2 #189184
saas-17.4 #189216
18.0 #189243
saas-18.2
saas-18.3
saas-18.4
19.0
master #189271

[FW][REV] stock_account: remove CoGS analytic_distribution

Users rely on analytical accounting for accurate sales reporting.
In operations involving automated inventory valuation, when an account
move is confirmed, cogs entries are created with the same analytic
account as the product line.
However, due to a recent commit this is no longer the case.

Steps to reproduce:
- Enable Analytic Accounting and Anglo-Saxon Accounting in the settings
- Create a storable product
- Set inventory valuation to Automated on the product's category
- Add a cost to the product
- Create an invoice with the product and add an analytic distribution
- When the invoice is confirmed, COGS line are created

Issue: Analytic distribution is not applied to COGS line

This reverts commit 2a5463eb013aecc1d24041928974a9bbff5fb23a.

opw-4347110
opw-4351323
opw-4351111
opw-4350640
opw-4350188
...

Forward-Port-Of: #189184
Forward-Port-Of: #188865