From ebc3307f38c9d0cd264852fcb82bc125412446d7 Mon Sep 17 00:00:00 2001 From: ferran-73 Date: Thu, 29 Dec 2022 09:31:50 +0100 Subject: [PATCH] [MIG] base_global_discount: 16.0 --- base_global_discount/__manifest__.py | 2 +- base_global_discount/models/res_partner.py | 14 -------------- base_global_discount/views/res_partner_views.xml | 4 ++-- 3 files changed, 3 insertions(+), 17 deletions(-) diff --git a/base_global_discount/__manifest__.py b/base_global_discount/__manifest__.py index db1a3d39..133876b0 100644 --- a/base_global_discount/__manifest__.py +++ b/base_global_discount/__manifest__.py @@ -3,7 +3,7 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). { "name": "Base Global Discount", - "version": "15.0.1.0.0", + "version": "16.0.1.0.0", "category": "Base", "author": "Tecnativa, Odoo Community Association (OCA)", "website": "https://github.com/OCA/server-backend", diff --git a/base_global_discount/models/res_partner.py b/base_global_discount/models/res_partner.py index e95e29ad..1a01b992 100644 --- a/base_global_discount/models/res_partner.py +++ b/base_global_discount/models/res_partner.py @@ -22,17 +22,3 @@ class ResPartner(models.Model): string="Purchase Global Discounts", domain=[("discount_scope", "=", "purchase")], ) - # HACK: Looks like UI doesn't behave well with Many2many fields and - # negative groups when the same field is shown. In this case, we want to - # show the readonly version to any not in the global discount group. - # TODO: Check in future versions if it's fixed - customer_global_discount_ids_readonly = fields.Many2many( - string="Sale Global Discounts (readonly)", - related="customer_global_discount_ids", - readonly=True, - ) - supplier_global_discount_ids_readonly = fields.Many2many( - string="Purchase Global Discounts (readonly)", - related="supplier_global_discount_ids", - readonly=True, - ) diff --git a/base_global_discount/views/res_partner_views.xml b/base_global_discount/views/res_partner_views.xml index 95d49ee2..03fa2d71 100644 --- a/base_global_discount/views/res_partner_views.xml +++ b/base_global_discount/views/res_partner_views.xml @@ -14,7 +14,7 @@ attrs="{'invisible': [('is_company', '=', False), ('parent_id', '!=', False)]}" />