[FIX] l10n_ch_hr_payroll_account: Fix employee cost account codes

In https://github.com/odoo/odoo/pull/105119, new accounts were added
to represent employee-related expenses. Based on the non-official
document https://swissdec.ch/document/share/295/4cc46aca-8b47-49e9-882a-03c37eb8dea3
we used account codes 2990 and 2999 for accounts 'Indemnities' and
'Company Car Correction'.

However, these accounts have no place with the equity accounts in 29xx,
since they are not equity but rather expense accounts. Examples of CoAs
that include employee indemnity accounts place them under account group
5 with the other employee-related expenses.

(e.g. https://plancompta.com/plan-comptable-suisse-pcg-2021/)

As such, we move accounts 2990 Indemnities -> 5840
and 2999 Company Car Correction -> 5031.

Fixing this in stable will not cause any in-database corruption, since
the updated code is only executed when the CoA is loaded/reloaded.
However, users will need to reload the CoA in order to take advantage
of the fix.

This also ensures that the Swiss Balance Sheet is balanced.

taskid:3060790

closes odoo/odoo#150692

Related: odoo/enterprise#54941
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
This commit is contained in:
Antoine Dupuis (andu)
2024-01-24 10:44:42 +00:00
parent 9792d5d761
commit 69d292fa2e
@@ -99,8 +99,6 @@
"ch_coa_2970","Profits brought forward / Losses brought forward","2970","equity","False","Gewinnvortrag / Verlustvortrag","Utile / perdita riportata","Bénéfice / perte reporté","","",""
"ch_coa_2979","Annual profit or annual loss","2979","equity","False","Jahresgewinn oder Jahresverlust","Utile/perdita annuale","Bénéfice / perte de l’exercice","","",""
"ch_coa_2980","Treasury stock, shares, participation rights (negative item)","2980","equity","False","","","","","",""
"ch_coa_2990","Indemnities","2990","equity","False","","","","","",""
"ch_coa_2999","Company Car Correction","2999","equity","False","","","","","",""
"ch_coa_3000","Sales of products (Manufacturing)","3000","income","False","Verkauf von Produkten (Herstellung)","Ricavi prodotti fabbricati","Ventes de produits fabriqués","","",""
"ch_coa_3009","Deductions on sales","3009","income","False","Abzüge bei Verkäufen","Diminuzione di ricavi","Déductions sur ventes","","",""
"ch_coa_3200","Sales of goods (Trade)","3200","income","False","Warenverkauf (Handel)","Ricavi merci di rivendita","Ventes de marchandises","","",""
@@ -153,6 +151,7 @@
"ch_coa_5007","Bonus","5007","expense","False","","","","","",""
"ch_coa_5009","Jubilee Gift","5009","expense","False","","","","","",""
"ch_coa_5030","Travelling Expenses","5030","expense","False","","","","","",""
"ch_coa_5031","Company Car Correction","5031","expense","False","","","","","",""
"ch_coa_5040","Salary Allowances","5040","expense","False","","","","","",""
"ch_coa_5601","CA Fees","5601","expense","False","","","","","",""
"ch_coa_5700","Social benefits","5700","expense","False","Sozialleistungen","Oneri sociali","Charges sociales","","",""
@@ -170,6 +169,7 @@
"ch_coa_5830","Representation Fees","5830","expense","False","","","","","",""
"ch_coa_5831","Car Fees","5831","expense","False","","","","","",""
"ch_coa_5832","Other Fees","5832","expense","False","","","","","",""
"ch_coa_5840","Indemnities","5840","expense","False","","","","","",""
"ch_coa_5900","Temporary staff expenditures","5900","expense","False","Leistungen DritterAusgaben für Zeitarbeitskräfte","Spese per il personale temporaneo","Charges de personnels temporaires","","",""
"ch_coa_6000","Rent","6000","expense","False","Miete","Costi dei locali","Charges de locaux","","",""
"ch_coa_6100","Maintenance & repair expenses","6100","expense","False","Kosten für Wartung und Reparatur","Manutenzioni, riparazioni e sostituzione immobilizzazioni mobiliari","Entretien, réparations et remplacement des inst. servant à l’exploitation","","",""
1 id name code account_type reconcile name@de name@it name@fr name@ar name@zh_CN name@nl
99 ch_coa_2970 Profits brought forward / Losses brought forward 2970 equity False Gewinnvortrag / Verlustvortrag Utile / perdita riportata Bénéfice / perte reporté
100 ch_coa_2979 Annual profit or annual loss 2979 equity False Jahresgewinn oder Jahresverlust Utile/perdita annuale Bénéfice / perte de l’exercice
101 ch_coa_2980 Treasury stock, shares, participation rights (negative item) 2980 equity False
ch_coa_2990 Indemnities 2990 equity False
ch_coa_2999 Company Car Correction 2999 equity False
102 ch_coa_3000 Sales of products (Manufacturing) 3000 income False Verkauf von Produkten (Herstellung) Ricavi prodotti fabbricati Ventes de produits fabriqués
103 ch_coa_3009 Deductions on sales 3009 income False Abzüge bei Verkäufen Diminuzione di ricavi Déductions sur ventes
104 ch_coa_3200 Sales of goods (Trade) 3200 income False Warenverkauf (Handel) Ricavi merci di rivendita Ventes de marchandises
151 ch_coa_5009 Jubilee Gift 5009 expense False
152 ch_coa_5030 Travelling Expenses 5030 expense False
153 ch_coa_5040 ch_coa_5031 Salary Allowances Company Car Correction 5040 5031 expense False
154 ch_coa_5040 Salary Allowances 5040 expense False
155 ch_coa_5601 CA Fees 5601 expense False
156 ch_coa_5700 Social benefits 5700 expense False Sozialleistungen Oneri sociali Charges sociales
157 ch_coa_5701 Social benefits AC 5701 expense False
169 ch_coa_5831 Car Fees 5831 expense False
170 ch_coa_5832 Other Fees 5832 expense False
171 ch_coa_5900 ch_coa_5840 Temporary staff expenditures Indemnities 5900 5840 expense False Leistungen DritterAusgaben für Zeitarbeitskräfte Spese per il personale temporaneo Charges de personnels temporaires
172 ch_coa_5900 Temporary staff expenditures 5900 expense False Leistungen DritterAusgaben für Zeitarbeitskräfte Spese per il personale temporaneo Charges de personnels temporaires
173 ch_coa_6000 Rent 6000 expense False Miete Costi dei locali Charges de locaux
174 ch_coa_6100 Maintenance & repair expenses 6100 expense False Kosten für Wartung und Reparatur Manutenzioni, riparazioni e sostituzione immobilizzazioni mobiliari Entretien, réparations et remplacement des inst. servant à l’exploitation
175 ch_coa_6105 Leasing movable tangible fixed assets 6105 expense False Leasing von beweglichen Sachanlagen Leasing di immobilizzazioni materiali mobiliari Leasing immobilisations corporelles meubles