[FIX] account_group: Remove parent_order

This scrambles the proper order of the groups according the prefix.
This commit is contained in:
Pedro M. Baeza
2019-07-09 00:53:25 +02:00
parent 309b38fde0
commit 8e6269d350
3 changed files with 12 additions and 2 deletions

View File

@@ -4,7 +4,7 @@
{
"name": "Groups for accounts",
"summary": "Use v11 account groups feature",
"version": "10.0.1.0.0",
"version": "10.0.1.1.0",
"category": "Accounting",
"website": "https://github.com/OCA/account-financial-tools",
"author": "Tecnativa,"

View File

@@ -0,0 +1,11 @@
# coding: utf-8
# Copyright 2019 Tecnativa - Pedro M. Baeza
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from openupgradelib import openupgrade
@openupgrade.migrate()
def migrate(env, version):
"""Recompute parent store according new criteria."""
env['account.group']._parent_store_compute()

View File

@@ -9,7 +9,6 @@ from odoo.osv import expression
class AccountGroup(models.Model):
_name = 'account.group'
_parent_store = True
_parent_order = 'name'
_order = 'code_prefix'
parent_id = fields.Many2one(