From 276f0806381d4e03903521cfa2e4e2ca00c688a6 Mon Sep 17 00:00:00 2001 From: ptr-odoo Date: Tue, 29 Aug 2017 16:08:10 +0530 Subject: [PATCH] [IMP] account: allow to archive journal, account.tag and analytic.tag Currently there is no option to Archive / Unarchive Journal + Accounting Tag + Analytic Account Tag task: https://www.odoo.com/web#id=27447&view_type=form&model=project.task&menu_id=4720 PR: #12864 --- addons/account/models/account.py | 2 ++ addons/account/views/account_view.xml | 19 ++++++++++++++++--- addons/analytic/models/analytic_account.py | 1 + .../analytic/views/analytic_account_views.xml | 13 ++++++++++--- 4 files changed, 29 insertions(+), 6 deletions(-) diff --git a/addons/account/models/account.py b/addons/account/models/account.py index b9d5b680820..02188a2ba71 100644 --- a/addons/account/models/account.py +++ b/addons/account/models/account.py @@ -35,6 +35,7 @@ class AccountAccountTag(models.Model): name = fields.Char(required=True) applicability = fields.Selection([('accounts', 'Accounts'), ('taxes', 'Taxes')], required=True, default='accounts') color = fields.Integer('Color Index', default=10) + active = fields.Boolean(default=True, help="Set active to false to hide the Account Tag without removing it.") #---------------------------------------------------------- # Accounts @@ -236,6 +237,7 @@ class AccountJournal(models.Model): name = fields.Char(string='Journal Name', required=True) code = fields.Char(string='Short Code', size=5, required=True, help="The journal entries of this journal will be named using this prefix.") + active = fields.Boolean(default=True, help="Set active to false to hide the Journal without removing it.") type = fields.Selection([ ('sale', 'Sale'), ('purchase', 'Purchase'), diff --git a/addons/account/views/account_view.xml b/addons/account/views/account_view.xml index 1f78b86b9bd..0d1ee78eb16 100644 --- a/addons/account/views/account_view.xml +++ b/addons/account/views/account_view.xml @@ -230,6 +230,7 @@ + @@ -245,6 +246,11 @@
+
+ +