mirror of
https://github.com/bringout/oca-ocb-l10n_europe.git
synced 2026-04-27 04:01:59 +02:00
19.0 vanilla
This commit is contained in:
parent
ff721d030e
commit
7721452493
1826 changed files with 124775 additions and 274114 deletions
|
|
@ -1,5 +1,5 @@
|
|||
# -*- coding:utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from . import template_fi
|
||||
from . import account_journal
|
||||
from . import account_move
|
||||
from . import res_partner
|
||||
|
|
|
|||
|
|
@ -3,11 +3,10 @@ from odoo import models, fields
|
|||
|
||||
|
||||
class AccountJournal(models.Model):
|
||||
|
||||
_inherit = 'account.journal'
|
||||
|
||||
invoice_reference_model = fields.Selection(selection_add=[
|
||||
('fi', 'Finnish Standard Reference'),
|
||||
('fi_rf', 'Finnish Creditor Reference (RF)'),
|
||||
('fi', 'Finnish Standard Reference (2024000068)'),
|
||||
('fi_rf', 'Finnish Creditor Reference (RF) (RF952024000071)'),
|
||||
], ondelete={'fi': lambda recs: recs.write({'invoice_reference_model': 'odoo'}),
|
||||
'fi_rf': lambda recs: recs.write({'invoice_reference_model': 'odoo'})})
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import logging
|
|||
log = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class AccountInvoiceFinnish(models.Model):
|
||||
class AccountMove(models.Model):
|
||||
_inherit = 'account.move'
|
||||
|
||||
@api.model
|
||||
|
|
|
|||
10
odoo-bringout-oca-ocb-l10n_fi/l10n_fi/models/res_partner.py
Normal file
10
odoo-bringout-oca-ocb-l10n_fi/l10n_fi/models/res_partner.py
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
from odoo import _, models
|
||||
|
||||
|
||||
class ResPartner(models.Model):
|
||||
_inherit = 'res.partner'
|
||||
|
||||
def _get_company_registry_labels(self):
|
||||
labels = super()._get_company_registry_labels()
|
||||
labels['FI'] = _('Business ID')
|
||||
return labels
|
||||
46
odoo-bringout-oca-ocb-l10n_fi/l10n_fi/models/template_fi.py
Normal file
46
odoo-bringout-oca-ocb-l10n_fi/l10n_fi/models/template_fi.py
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
from odoo import models
|
||||
from odoo.addons.account.models.chart_template import template
|
||||
|
||||
|
||||
class AccountChartTemplate(models.AbstractModel):
|
||||
_inherit = 'account.chart.template'
|
||||
|
||||
@template('fi')
|
||||
def _get_fi_template_data(self):
|
||||
return {
|
||||
'code_digits': '4',
|
||||
'property_account_receivable_id': 'account_1701',
|
||||
'property_account_payable_id': 'account_2871',
|
||||
}
|
||||
|
||||
@template('fi', 'res.company')
|
||||
def _get_fi_res_company(self):
|
||||
return {
|
||||
self.env.company.id: {
|
||||
'account_fiscal_country_id': 'base.fi',
|
||||
'bank_account_code_prefix': '1921',
|
||||
'cash_account_code_prefix': '1910',
|
||||
'transfer_account_code_prefix': '1950',
|
||||
'account_default_pos_receivable_account_id': 'account_1701',
|
||||
'income_currency_exchange_account_id': 'account_3500',
|
||||
'expense_currency_exchange_account_id': 'account_4380',
|
||||
'account_journal_early_pay_discount_loss_account_id': 'account_4230',
|
||||
'account_journal_early_pay_discount_gain_account_id': 'account_3500',
|
||||
'account_sale_tax_id': 'tax_dom_sales_goods_25_5',
|
||||
'account_purchase_tax_id': 'tax_dom_purchase_goods_25_5',
|
||||
'expense_account_id': 'account_4000',
|
||||
'income_account_id': 'account_3000',
|
||||
'account_stock_journal_id': 'inventory_valuation',
|
||||
'account_stock_valuation_id': 'account_1501',
|
||||
},
|
||||
}
|
||||
|
||||
@template('fi', 'account.account')
|
||||
def _get_fi_account_account(self):
|
||||
return {
|
||||
'account_1501': {
|
||||
'account_stock_expense_id': 'account_4000',
|
||||
'account_stock_variation_id': 'account_4400',
|
||||
},
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue