From c6f346642e5a4ba2d9c15a3f3eb78e42e1dabb5c Mon Sep 17 00:00:00 2001 From: Alessio Renda Date: Tue, 9 Jan 2024 15:51:51 +0100 Subject: [PATCH] [IMP] mrp_bom_attribute_match_duplicate_kit: add group access --- mrp_bom_attribute_match_duplicate_kit/README.rst | 3 ++- mrp_bom_attribute_match_duplicate_kit/__manifest__.py | 4 ++++ .../demo/res_users_demo.xml | 9 +++++++++ mrp_bom_attribute_match_duplicate_kit/readme/USAGE.rst | 1 + .../security/ir.model.access.csv | 2 +- .../security/security.xml | 7 +++++++ .../static/description/index.html | 3 ++- .../views/product_template_views.xml | 4 ++++ 8 files changed, 30 insertions(+), 3 deletions(-) create mode 100644 mrp_bom_attribute_match_duplicate_kit/demo/res_users_demo.xml create mode 100644 mrp_bom_attribute_match_duplicate_kit/security/security.xml diff --git a/mrp_bom_attribute_match_duplicate_kit/README.rst b/mrp_bom_attribute_match_duplicate_kit/README.rst index c38ff8616..8ed303592 100644 --- a/mrp_bom_attribute_match_duplicate_kit/README.rst +++ b/mrp_bom_attribute_match_duplicate_kit/README.rst @@ -7,7 +7,7 @@ BOM Attribute Match Duplicate Kit !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - !! source digest: sha256:799dde4fcb103960a4af12b6bd212c0913ffd0f478293ff3c0fd559245ecae1a + !! source digest: sha256:579e72588e9246276b56f9620c385563a09215a87f10d04a0cd038bad0745153 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! .. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png @@ -45,6 +45,7 @@ The use case is that customer sells the same product with two different names, p Usage ===== +* In user, enable "Can duplicate with kit" access right * Open "Product 1" with variants * Use server action: "Duplicate with attribute match kit" * A wizard opens up with field "New product template name" diff --git a/mrp_bom_attribute_match_duplicate_kit/__manifest__.py b/mrp_bom_attribute_match_duplicate_kit/__manifest__.py index 9d9700aa0..499fb9d1b 100644 --- a/mrp_bom_attribute_match_duplicate_kit/__manifest__.py +++ b/mrp_bom_attribute_match_duplicate_kit/__manifest__.py @@ -12,8 +12,12 @@ "license": "AGPL-3", "website": "https://github.com/OCA/manufacture", "data": [ + "security/security.xml", "security/ir.model.access.csv", "views/product_template_views.xml", "wizard/product_template_kit_wizard.xml", ], + "demo": [ + "demo/res_users_demo.xml", + ], } diff --git a/mrp_bom_attribute_match_duplicate_kit/demo/res_users_demo.xml b/mrp_bom_attribute_match_duplicate_kit/demo/res_users_demo.xml new file mode 100644 index 000000000..76b584d7d --- /dev/null +++ b/mrp_bom_attribute_match_duplicate_kit/demo/res_users_demo.xml @@ -0,0 +1,9 @@ + + + + + + diff --git a/mrp_bom_attribute_match_duplicate_kit/readme/USAGE.rst b/mrp_bom_attribute_match_duplicate_kit/readme/USAGE.rst index a11280583..b901b4e58 100644 --- a/mrp_bom_attribute_match_duplicate_kit/readme/USAGE.rst +++ b/mrp_bom_attribute_match_duplicate_kit/readme/USAGE.rst @@ -1,3 +1,4 @@ +* In user, enable "Can duplicate with kit" access right * Open "Product 1" with variants * Use server action: "Duplicate with attribute match kit" * A wizard opens up with field "New product template name" diff --git a/mrp_bom_attribute_match_duplicate_kit/security/ir.model.access.csv b/mrp_bom_attribute_match_duplicate_kit/security/ir.model.access.csv index cc8696391..38214d30a 100644 --- a/mrp_bom_attribute_match_duplicate_kit/security/ir.model.access.csv +++ b/mrp_bom_attribute_match_duplicate_kit/security/ir.model.access.csv @@ -1,2 +1,2 @@ id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink -access_product_template_kit_wizard,access.product.template.kit.wizard,model_product_template_kit_wizard,mrp.group_mrp_user,1,1,1,1 +access_product_template_kit_wizard,access.product.template.kit.wizard,model_product_template_kit_wizard,mrp_bom_attribute_match_duplicate_kit.group_mrp_bom_duplicate_access,1,1,1,1 diff --git a/mrp_bom_attribute_match_duplicate_kit/security/security.xml b/mrp_bom_attribute_match_duplicate_kit/security/security.xml new file mode 100644 index 000000000..6a2525521 --- /dev/null +++ b/mrp_bom_attribute_match_duplicate_kit/security/security.xml @@ -0,0 +1,7 @@ + + + + Can duplicate with kit + + + diff --git a/mrp_bom_attribute_match_duplicate_kit/static/description/index.html b/mrp_bom_attribute_match_duplicate_kit/static/description/index.html index d6ec0a56f..61bdca09b 100644 --- a/mrp_bom_attribute_match_duplicate_kit/static/description/index.html +++ b/mrp_bom_attribute_match_duplicate_kit/static/description/index.html @@ -367,7 +367,7 @@ ul.auto-toc { !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -!! source digest: sha256:799dde4fcb103960a4af12b6bd212c0913ffd0f478293ff3c0fd559245ecae1a +!! source digest: sha256:579e72588e9246276b56f9620c385563a09215a87f10d04a0cd038bad0745153 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->

Beta License: AGPL-3 OCA/manufacture Translate me on Weblate Try me on Runboat

This module allows to duplicate a product with variants, at the same time creating a BoM with type “Kit” for the new product mapping variants of the original product.

@@ -393,6 +393,7 @@ ul.auto-toc {

Usage