mirror of
https://github.com/bringout/oca-ocb-l10n_europe.git
synced 2026-04-27 05:22:06 +02:00
Initial commit: L10N_Europe packages
This commit is contained in:
commit
9803722600
2377 changed files with 380711 additions and 0 deletions
4
odoo-bringout-oca-ocb-l10n_dk/l10n_dk/models/__init__.py
Normal file
4
odoo-bringout-oca-ocb-l10n_dk/l10n_dk/models/__init__.py
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from . import account_journal
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from odoo import api, models
|
||||
|
||||
|
||||
class AccountJournal(models.Model):
|
||||
_inherit = 'account.journal'
|
||||
|
||||
@api.model
|
||||
def _prepare_liquidity_account_vals(self, company, code, vals):
|
||||
# OVERRIDE
|
||||
account_vals = super()._prepare_liquidity_account_vals(company, code, vals)
|
||||
|
||||
if company.account_fiscal_country_id.code == 'DK':
|
||||
# Ensure the newly liquidity accounts have the right account tag in order to be part
|
||||
# of the Danish financial reports.
|
||||
account_vals.setdefault('tag_ids', [])
|
||||
account_vals['tag_ids'].append((4, self.env.ref('l10n_dk.account_tag_liquidity').id))
|
||||
|
||||
return account_vals
|
||||
Loading…
Add table
Add a link
Reference in a new issue