Skip to content
Snippets Groups Projects
Commit a4869fce authored by Thibault Delavallée's avatar Thibault Delavallée
Browse files

[FIX] hr_equipment: form view

Category is a classic m2o, not a statusbar. Moreover fixed category_id being twice
in the form, leading to one of them being impossible to use.
parent 1acd86a4
No related branches found
No related tags found
No related merge requests found
......@@ -199,10 +199,6 @@
<field name="model">hr.equipment</field>
<field name="arch" type="xml">
<form string="Equipments">
<header>
<field name="category_id" widget="statusbar" clickable="True"
options="{'fold_field': 'fold'}"/>
</header>
<sheet>
<div class="oe_button_box" name="button_box">
<button name="%(hr_equipment_request_action_from_equipment)d"
......@@ -215,13 +211,14 @@
<div class="oe_title">
<label for="name" class="oe_edit_only"/>
<h1><field name="name" string="Name" placeholder="Equipment Name"/></h1>
<label for="category_id" class="oe_edit_only"/>
<field name="category_id" options="{&quot;no_open&quot;: True}"/>
<label for="serial_no" class="oe_edit_only"/>
<field name="serial_no"/>
</div>
<group>
<group>
<field name="category_id" invisible="1" on_change="1" options="{&quot;no_open&quot;: True}"/>
<field name="equipment_assign_to" on_change="1" widget="radio"/>
<field name="equipment_assign_to" widget="radio"/>
<field name="employee_id" string="Employee" attrs="{'invisible': ['|', ('equipment_assign_to', '=', 'department'), ('equipment_assign_to', '=', False)]}"/>
<field name="department_id" string="Department" attrs="{'invisible': ['|', ('equipment_assign_to', '=', 'employee'), ('equipment_assign_to', '=', False)]}"/>
</group>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment