Update sale_purchase_no_product_template_menu: now usable by companies who have multi-variants, because we keep one menu entry of product.template in Sales > Configuration > Products Categ and Attributes menu
This commit is contained in:
@@ -26,14 +26,12 @@
|
||||
'version': '0.1',
|
||||
'category': 'Sale and Purchase',
|
||||
'license': 'AGPL-3',
|
||||
'summary': "Use only if you don't use variants of products",
|
||||
'summary': "Remplace product.template menu entries by product.product menu entries",
|
||||
'description': """
|
||||
Sale Purchase No Product Template
|
||||
=================================
|
||||
|
||||
You may use this module only if you don't use product variants i.e. you don't have (and don't plan to have in the future) several product.product attached to one product.template.
|
||||
|
||||
This module replaces the menu entries for product.template by menu entries for product.product in the *Sales*, *Purchases* and *Warehouse* menu entry.
|
||||
This module replaces the menu entries for product.template by menu entries for product.product in the *Sales*, *Purchases* and *Warehouse* menu entry. The only remaining menu entry for product.template is in the menu *Sales > Configuration > Product Categories and Attributes*.
|
||||
|
||||
This module has been written by Alexis de Lattre from Akretion <alexis.delattre@akretion.com>.
|
||||
""",
|
||||
|
||||
@@ -33,14 +33,28 @@
|
||||
</record>
|
||||
|
||||
<!-- SALE -->
|
||||
<!-- Move template menu entry to configuration menu -->
|
||||
<record id="product.menu_product_template_action" model="ir.ui.menu">
|
||||
<field name="action" ref="product.product_normal_action_sell"/>
|
||||
<!-- related action is "product.product_template_action" -->
|
||||
<field name="parent_id" ref="product.prod_config_main"/>
|
||||
</record>
|
||||
|
||||
<record id="product.product_template_action" model="ir.actions.act_window">
|
||||
<field name="name">Product Templates</field> <!-- native value is "Products" -->
|
||||
<field name="view_mode">tree,form,kanban</field>
|
||||
<field name="view_id" eval="False"/>
|
||||
<field name="context">{}</field>
|
||||
</record>
|
||||
|
||||
<record id="product.product_normal_action_sell" model="ir.actions.act_window">
|
||||
<field name="name">Products</field> <!-- native value is "Product Variants" -->
|
||||
<field name="view_mode">tree,form,kanban</field>
|
||||
</record>
|
||||
|
||||
<!-- Hide the native 'Product Variants' menu entry for regular users -->
|
||||
<!-- Show the native 'Product Variants' menu entry for everybody -->
|
||||
<record id="product.menu_products" model="ir.ui.menu">
|
||||
<field name="groups_id" eval="[(6, 0, [ref('base.group_system')])]"/>
|
||||
<!-- related action is "product.product_normal_action_sell" -->
|
||||
<field name="groups_id" eval="False"/>
|
||||
</record>
|
||||
|
||||
<!-- set name as editable on product.product form -->
|
||||
|
||||
Reference in New Issue
Block a user