Skip to content

Commit

Permalink
[MIG] account_fiscal_position_rule: Migration to 14.0
Browse files Browse the repository at this point in the history
  • Loading branch information
MiquelRForgeFlow committed Mar 28, 2023
1 parent 5df55d1 commit 61e4814
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 7 deletions.
2 changes: 1 addition & 1 deletion account_fiscal_position_rule/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"name": "Account Fiscal Position Rule",
"summary": "Account Fiscal Position Rule",
"category": "Generic Modules/Accounting",
"version": "13.0.1.3.1",
"version": "14.0.1.0.0",
"author": "Akretion, Odoo Community Association (OCA)",
"license": "AGPL-3",
"website": "https://github.com/OCA/account-fiscal-rule",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 13.0\n"
"Project-Id-Version: Odoo Server 14.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ def _compute_fiscal_position_rule_count(self):
def action_fiscal_position_rules(self):
self.ensure_one()
fpos_rules = self.fiscal_position_rule_ids
action = self.env.ref(
action = self.env["ir.actions.act_window"]._for_xml_id(
"account_fiscal_position_rule.action_account_fiscal_position_rule_form"
).read()[0]
)
if len(fpos_rules) > 1:
action["domain"] = [("id", "in", fpos_rules.ids)]
elif len(fpos_rules) == 1:
Expand Down
1 change: 1 addition & 0 deletions account_fiscal_position_rule/security/ir.model.access.csv
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
"account_fiscal_position_rule","account.fiscal.position.rule","model_account_fiscal_position_rule","account.group_account_invoice",1,1,1,1
"account_fiscal_position_rule_template","account.fiscal.position.rule.template","model_account_fiscal_position_rule_template","account.group_account_invoice",1,1,1,1
"account_fiscal_position_rule_wizard","wizard.account.fiscal.position.rule",model_wizard_account_fiscal_position_rule,"account.group_account_invoice",1,1,1,1
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@ class WizardAccountFiscalPositionRule(models.TransientModel):
comodel_name="res.company",
string="Company",
required=True,
default=lambda self: self.env["res.company"]._company_default_get(
"wizard.account.fiscal.position.rule"
),
default=lambda self: self.env.company,
)

def _template_vals(self, template, company_id, fiscal_position_id):
Expand Down
6 changes: 6 additions & 0 deletions setup/account_fiscal_position_rule/setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import setuptools

setuptools.setup(
setup_requires=['setuptools-odoo'],
odoo_addon=True,
)

0 comments on commit 61e4814

Please sign in to comment.