Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

How to add a selection field in res.partner kanban view for my custom module need a help.... [Closed]

By
Odoo
on 7/7/14, 2:59 AM 495 views

The Question has been closed for reason: not relevant or out dated

by
Odoo
on 07/21/2014 00:34:51

I want to add this field in kanban view

This is my py file 

 

'marital_status':fields.selection([('single','Single'),
                       ('married','Married'),
                                   ('divorced','Divorced'), ('engaged','Engaged'),
                           ('widower','Widower')], 'Marital status',required=True),

this is my xml file..---------------------------

<!-- Partner kanban view inherte -->
        <record model="ir.ui.view" id="new_partner_kanban_view">
            <field name="name">res.partner.kanban.inherit</field>
            <field name="model">res.partner</field>
            <field name="inherit_id" ref="base.res_partner_kanban_view"/>
            <field name="arch" type="xml">
                <field name="mobile" position="after">
                    <field name="marital_status"/>
                </field>
                <xpath expr="//div[@class='oe_kanban_partner_links']" position="after">
                    <li t-if="record.marital_status.raw_value">Single</li>

                    <li t-if="not record.marital_status.raw_value">Married</li>
                    <li t-if="not record.marital_status.raw_value">Divorced</li>
                    <li t-if="not record.marital_status.raw_value">Engaged</li>
                     <li t-if="not record.marital_status.raw_value">Widower</li>
                   

                </xpath>

            </field>
        </record >

But this got an error --

 

Uncaught Error: QWeb2: Error evaluating template: SyntaxError: Unexpected identifier

http://localhost:8069/web/static/lib/qweb/qweb2.js:24

 

 

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 7/7/14, 2:59 AM
Seen: 495 times
Last updated: 3/16/15, 8:10 AM