[FIX] replace old naming of exception + simplify xpath expression to make it more portable

This commit is contained in:
Florian da Costa
2014-03-13 16:44:34 +01:00
parent 975df8c3e2
commit a1d2a4806b
2 changed files with 3 additions and 3 deletions

View File

@@ -34,10 +34,10 @@
<field name="type">form</field>
<field eval="20" name="priority"/>
<field name="arch" type="xml">
<xpath expr="/form/sheet/notebook/page/field[@name='line_ids']/form/group/field[@name='account_id']" position="attributes">
<xpath expr="//field[@name='line_ids']/form//field[@name='account_id']" position="attributes">
<attribute name="attrs">{'required': [('already_completed','=', True)]}</attribute>
</xpath>
<xpath expr="/form/sheet/notebook/page/field[@name='line_ids']/tree/field[@name='account_id']" position="attributes">
<xpath expr="//field[@name='line_ids']/tree//field[@name='account_id']" position="attributes">
<attribute name="attrs">{'required': [('already_completed','=', True)]}</attribute>
</xpath>
</field>