Files
odoo_source/addons/l10n_es/models/template_es_coop_pymes.py
Dylan Kiss (dyki) ecee62ccd5 [IMP] l10n_es: add CoA for Cooperativas
In Spain, "Cooperativas" have their own variant of the Spanish chart of
accounts. In order to support these businesses, we add two extra CoA
templates: Cooperatives - SMEs and Cooperatives - Complete.

task-3803050

closes odoo/odoo#159357

Signed-off-by: Josse Colpaert <jco@odoo.com>
2024-04-09 13:04:11 +00:00

27 lines
912 B
Python

from odoo import _, models
from odoo.addons.account.models.chart_template import template
class AccountChartTemplate(models.AbstractModel):
_inherit = 'account.chart.template'
@template('es_coop_pymes')
def _get_es_coop_pymes_template_data(self):
return {
'name': _('Cooperatives - SMEs (2008)'),
'parent': 'es_common',
}
@template('es_coop_pymes', 'res.company')
def _get_es_coop_pymes_res_company(self):
return {
self.env.company.id: {
'account_fiscal_country_id': 'base.es',
'bank_account_code_prefix': '572',
'cash_account_code_prefix': '570',
'transfer_account_code_prefix': '57299',
'account_sale_tax_id': 'account_tax_template_s_iva21b',
'account_purchase_tax_id': 'account_tax_template_p_iva21_bc',
},
}