Skip to Content
Menu
This question has been flagged
1 Reply
2161 Views

I am getting the odoo client error when I try to get the value of a field in Kanban.


<record model="ir.ui.view" id="equipment_form_kanban_view_extened">
<field name="name">maintenance.equipment.kanban.view.extened</field>
<field name="model">maintenance.equipment</field>
<field name="inherit_id" ref="maintenance.hr_equipment_view_kanban"/>
<field name="arch" type="xml">
<xpath expr='//div[hasclass("oe_kanban_bottom_left")]' position="inside">
<div class="badge badge-primary" style="width:100%;height:100%">
<span><t t-esc="record.allocation_status.value"/></span>
</div>
</xpath>
</field>
</record>
Avatar
Discard
Best Answer

Hi Catherine,

   Please try to update the code like this.Add the field in the view.


 <record model="ir.ui.view" id="equipment_form_kanban_view_extened">

            <field name="name">maintenance.equipment.kanban.view.extened</field>

            <field name="model">maintenance.equipment</field>

            <field name="inherit_id" ref="maintenance.hr_equipment_view_kanban"/>

            <field name="arch" type="xml">

                <xpath expr='//div[hasclass("oe_kanban_bottom_left")]' position="inside">

                     <field name="allocation_status"/>

                    <div class="badge badge-primary" style="width:100%;height:100%">

                        <span><t t-esc="record.allocation_status.value"/></span>

                    </div>

                </xpath>

            </field>

        </record>

Avatar
Discard
Author

Its work like a charm. Thank you