From 22728f498630a32ee3028e7dc09fffa8b56159ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sun, 7 Mar 2021 11:13:53 +0100 Subject: [PATCH] Add __access__ to Model issue9903 review324601002 --- product.py | 5 +++++ sale.xml | 16 ---------------- 2 files changed, 5 insertions(+), 16 deletions(-) diff --git a/product.py b/product.py index 465a84e0fa..8947cdcde0 100644 --- a/product.py +++ b/product.py @@ -38,6 +38,11 @@ class ProductCustomer( name = fields.Char("Name", translate=True) code = fields.Char("Code") + @classmethod + def __setup__(cls): + super().__setup__() + cls.__access__.update(['template', 'product']) + @fields.depends( 'product', '_parent_product.template') def on_change_product(self): diff --git a/sale.xml b/sale.xml index 28bd3a12e0..02c2bddaa5 100644 --- a/sale.xml +++ b/sale.xml @@ -60,22 +60,6 @@ this repository contains the full copyright notices and license terms. --> action="act_product_customer_form" sequence="20" id="menu_product_customer"/> - - - - - - - - - - - - - - - -