[FIX] base: adapt ir.rule view

Since 7b3796d77c, view attributes are
validated against use of invalid field names.

However, the use of `global` field is a special case due to fact of
being a python keyword.

Rewrite the python expression to avoid using it, while keeping the same
visual effect.

Close #21631
This commit is contained in:
Christophe Simonis
2017-12-13 17:30:33 +01:00
parent 31cbc23956
commit 8a257b08b6
2 changed files with 2 additions and 4 deletions
+1 -2
View File
@@ -175,10 +175,9 @@
</page>
<page string="Record Rules">
<field name="rule_ids">
<tree string="Record Rules" editable="top" decoration-info="global">
<tree string="Record Rules" editable="top" decoration-info="not groups">
<field name="name"/>
<field name="groups" widget="many2many_tags" options="{'no_create':True}"/>
<field name="global" invisible="1"/>
<field name="domain_force"/>
<field name="perm_read"/>
<field name="perm_write"/>
+1 -2
View File
@@ -54,10 +54,9 @@
<record id="view_rule_tree" model="ir.ui.view">
<field name="model">ir.rule</field>
<field name="arch" type="xml">
<tree string="Record Rules" decoration-info="global">
<tree string="Record Rules" decoration-info="not groups">
<field name="name"/>
<field name="model_id"/>
<field name="global" invisible="1"/>
<field name="groups" widget="many2many_tags" options="{'no_create':True}"/>
<field name="domain_force"/>
<field name="perm_read"/>