[FIX] sale: Color column invisible in product attribute

Before this commit, when we click on a item in the tree view of
exclude item of product attribute value view, we got a traceback.
It come from the attribute column_invisible. This attribute was
used the remove the color column if the display type was not
color. But each line can have a display type different, so we
can't use invisible_column, we must use instead invisible
attribute.

After this commit, the invisible attribute is use, and each line
will display or not the color column, depends his display type.

closes odoo/odoo#38157

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
This commit is contained in:
jbm-odoo
2019-10-08 07:45:36 +00:00
parent 2a60e82e98
commit dc8cbe3940
@@ -49,7 +49,7 @@
<field name="arch" type="xml">
<field name="name" position="after">
<field name="display_type"/>
<field name="html_color" attrs="{'column_invisible': [('display_type', '!=', 'color')]}" widget="color"/>
<field name="html_color" attrs="{'invisible': [('display_type', '!=', 'color')]}" widget="color"/>
</field>
</field>
</record>