diff options
Diffstat (limited to 'addons/account_fleet/views/account_move_views.xml')
| -rw-r--r-- | addons/account_fleet/views/account_move_views.xml | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/addons/account_fleet/views/account_move_views.xml b/addons/account_fleet/views/account_move_views.xml new file mode 100644 index 00000000..e4c86d01 --- /dev/null +++ b/addons/account_fleet/views/account_move_views.xml @@ -0,0 +1,18 @@ +<?xml version='1.0' encoding='utf-8'?> +<odoo> + <record id="view_move_form" model="ir.ui.view"> + <field name="name">account.move.form</field> + <field name="model">account.move</field> + <field name="inherit_id" ref="account.view_move_form"/> + <field name="arch" type="xml"> + <xpath expr="//field[@name='line_ids']//field[@name='account_id']" position="after"> + <field name='need_vehicle' invisible='1'/> + <field name='vehicle_id' attrs="{'required': [('need_vehicle', '=', True), ('parent.move_type', 'in', ('in_invoice', 'in_refund'))], 'column_invisible': [('parent.move_type', 'not in', ('in_invoice', 'in_refund'))]}" optional='hidden'/> + </xpath> + <xpath expr="//field[@name='invoice_line_ids']//field[@name='account_id']" position="after"> + <field name='need_vehicle' invisible='1'/> + <field name='vehicle_id' attrs="{'required': [('need_vehicle', '=', True), ('parent.move_type', 'in', ('in_invoice', 'in_refund'))], 'column_invisible': [('parent.move_type', 'not in', ('in_invoice', 'in_refund'))]}" optional='hidden'/> + </xpath> + </field> + </record> +</odoo> |
