[IMP] add module product_variant_usability
This commit is contained in:
1
product_variant_usability/__init__.py
Normal file
1
product_variant_usability/__init__.py
Normal file
@@ -0,0 +1 @@
|
|||||||
|
# -*- coding: utf-8 -*-
|
||||||
30
product_variant_usability/__openerp__.py
Normal file
30
product_variant_usability/__openerp__.py
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
# -*- coding: utf-8 -*-
|
||||||
|
# Copyright 2017 Akretion (http://www.akretion.com).
|
||||||
|
# @author Sébastien BEAU <sebastien.beau@akretion.com>
|
||||||
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
|
{
|
||||||
|
"name": "Product Variant Usability",
|
||||||
|
"summary": "Improve the product variant usability",
|
||||||
|
"version": "8.0.1.0.0",
|
||||||
|
"category": "Uncategorized",
|
||||||
|
"website": "www.akretion.com",
|
||||||
|
"author": " Akretion",
|
||||||
|
"license": "AGPL-3",
|
||||||
|
"application": False,
|
||||||
|
"installable": True,
|
||||||
|
"external_dependencies": {
|
||||||
|
"python": [],
|
||||||
|
"bin": [],
|
||||||
|
},
|
||||||
|
"depends": [
|
||||||
|
"product_variant_inactive",
|
||||||
|
],
|
||||||
|
"data": [
|
||||||
|
"views/product_view.xml",
|
||||||
|
],
|
||||||
|
"demo": [
|
||||||
|
],
|
||||||
|
"qweb": [
|
||||||
|
]
|
||||||
|
}
|
||||||
35
product_variant_usability/views/product_view.xml
Normal file
35
product_variant_usability/views/product_view.xml
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<openerp>
|
||||||
|
<data>
|
||||||
|
|
||||||
|
<record id="product_template_view_form" model="ir.ui.view">
|
||||||
|
<field name="model">product.template</field>
|
||||||
|
<field name="inherit_id" ref="product.product_template_only_form_view"/>
|
||||||
|
<field name="priority" eval="64"/>
|
||||||
|
<field name="arch" type="xml">
|
||||||
|
<field name="attribute_line_ids" position="after">
|
||||||
|
<field name="product_variant_ids" nolabel="1" domain="['|', ('active', '=', False), ('active', '=', True)]">
|
||||||
|
<tree>
|
||||||
|
<field name="default_code"/>
|
||||||
|
<field name="attribute_value_ids" widget="many2many_tags"/>
|
||||||
|
<field name="qty_available"/>
|
||||||
|
<field name="active" invisible="1"/>
|
||||||
|
<button type="object"
|
||||||
|
name="button_activate"
|
||||||
|
attrs="{'invisible': [('active','=',True)]}"
|
||||||
|
icon="gtk-stop"/>
|
||||||
|
<button type="object"
|
||||||
|
name="button_deactivate"
|
||||||
|
attrs="{'invisible': [('active','=',False)]}"
|
||||||
|
icon="gtk-apply"/>
|
||||||
|
</tree>
|
||||||
|
</field>
|
||||||
|
</field>
|
||||||
|
<xpath expr="//field[@name='product_variant_count']/../.." position="attributes">
|
||||||
|
<attribute name="invisible">1</attribute>
|
||||||
|
</xpath>
|
||||||
|
</field>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
</data>
|
||||||
|
</openerp>
|
||||||
Reference in New Issue
Block a user