<form model="clinic.dialyzer" attrs='{"readonly":[["state","in",["cancelled","drop","active"]]]}' show_company="1"> <head> <field name="state"/> <button string="Options" dropdown="1"> <item string="Copy" method="copy" states="active"/> <item string="To Draft" method="to_draft" states="drop,active"/> </button> </head> <group span="6" columns="1"> <field name="number"/> <field name="name"/> <field name="patient_id" required="1" onchange="onchange_patient"/> <field name="department_id" required="1"/> <field name="date"/> <field name="exp_date"/> <field name="membrane_type" required="1"/> </group> <group span="6" columns="1"> <field name="product_id" onchange="onchange_product"/> <field name="dialyzer_type"/> <field name="use_time"/> <field name="max_use_time"/> <field name="note"/> <field name="company_id" invisible="1"/> </group> <group span="6" columns="1"> </group> <group span="6" columns="1"> <template> <div><b>Note:</b> 'Use time' will count automatic after finish HD Case.</div> </template> </group> <foot> <button string="Validate" type="success" states="new" method="validate"/> <button string="Drop" type="danger" icon="remove" states="active" method="drop"/> </foot> <related> <field name="pickings" click_action="view_picking"/> <field name="hd_cases" readonly="1"/> </related> </form>