This question has been flagged
1 Reply
10546 Views

I tried to modify kanban element adding more attributes to it, but it gives me this error:

2014-01-02 14:22:23,653 23604 ERROR test2 openerp.addons.base.ir.ir_ui_view: <string>:1:0:ERROR:RELAXNGV:RELAXNG_ERR_NOELEM: Expecting an element , got nothing

My view:

    <record model="ir.ui.view" id="crm_case_kanban_view_leads_inherit">
        <field name="name">CRM - Leads Kanban Inherit</field>
        <field name="model">crm.lead</field>
        <field name="inherit_id" ref="crm.crm_case_kanban_view_leads"/>
        <field name="arch" type="xml">
            <kanban default_group_by="stage_id" position="replace">
                <kanban default_group_by="stage_id" edit="false" quick_create="false"/>
            </kanban>
        </field>
    </record>
Avatar
Discard
Best Answer

Hello Andrius, you can access the attributes of an element by using the position="attributes" syntax. See if the following works for you:

    <record model="ir.ui.view" id="crm_case_kanban_view_leads_inherit">
        <field name="name">CRM - Leads Kanban Inherit</field>
        <field name="model">crm.lead</field>
        <field name="inherit_id" ref="crm.crm_case_kanban_view_leads"/>
        <field name="arch" type="xml">
            <kanban position="attributes">
                <attribute name="edit">false</attribute>
                <attribute name="quick_create">false</attribute>
            </kanban>
        </field>
    </record>
Avatar
Discard