Odoo Help


i create a object inherit from product.product,but the field not shows in the view

figol New
on 5/20/13, 7:59 AM 4,489 views

what i want to do is add a column to product.product table so i create a new object inheriting from product.product , and i also create a new view inheriting from product.product_normal_form_view but the field i have added to product.product not showing in the form view. i can see the itemid field in product_product table. it is so strange , anyone can help me?? many thanks.

here is the code my_product.py

# -*- coding: utf-8 -*-
from openerp.osv import fields, osv
from datetime import datetime 

class ebayerp_product(osv.osv):
    _name = 'product.product'
    _inherit = "product.product"
    _columns = {
        'itemid' : fields.char('eBay ItemID', size=32, readonly=True, invisible=False),


<?xml version="1.0" encoding="utf-8"?>
        <record id="product_normal_form_view" model="ir.ui.view">
            <field name="name">product.normal.form.inherit1</field>
            <field name="model">product.product</field>
            <field name="type">form</field>
            <field name="priority" eval="1"/>
            <field name="inherit_id" ref="product.product_normal_form_view"/>
            <field name="arch" type="xml">
                 <sheet position="inside">
                    <label for="ebayitemid"/>
                    <div name="ean">
                        <field name="itemid"/>

product_normal_form_view form view (not all code, because not neccessary)

<record id="product_normal_form_view" model="ir.ui.view">
            <field name="name">product.normal.form</field>
            <field name="model">product.product</field>
            <field eval="7" name="priority"/>
            <field name="arch" type="xml">
                <form string="Product" version="7.0">
                        <field name="image_medium" widget="image" class="oe_avatar oe_left"/>
                        <div class="oe_title">
                            <div class="oe_edit_only">
                                <label for="name" string="Product Name"/>
                                <field name="name"/>
                            <label for="categ_id" class="oe_edit_only"/>
                            <h2><field name="categ_id"/></h2>
                            <div name="options" groups="base.group_user">
                                <field name="sale_ok"/>
                                <label for="sale_ok"/>
                        <div class="oe_right oe_button_box" name="buttons">

Hi , can you put all your codes so I can test and correct the error so the problem will solved quickly

on 5/20/13, 8:26 AM

ok , i will post the code soon.

figol New
on 5/21/13, 12:32 AM

the problem has been resolved . delete 'readonly=True' will be ok

figol New
on 5/21/13, 5:00 AM

Ok @figol New .... if there is no problem can you send me all codes

on 5/21/13, 6:40 AM

ClueLogics Technologies Pvt. Ltd.

--ClueLogics Technologies Pvt. Ltd.--
| 6 5 8
Delhi NCR, India
--ClueLogics Technologies Pvt. Ltd.--

 ClueLogics Technologies Pvt Ltd is a Software product and services provider. We are positioned to deliver robust, rapid and reliable Information Technology solutions that work. What we succeed upon is Technology and Technical Expertise. The industry review of ClueLogics has been commendable for the past years as most of its business comes from repeat orders by highly satisfied clients.

ClueLogics Technologies Pvt. Ltd.
On 5/20/13, 8:19 AM

Hi you define wrong field name in your view

 <field name="ebayitemid"/>

replace it with

 <field name="itemid"/>

and plz be remember you should use same whither same class name (product_product) or place a new field in class label _table=product_product other wise this field will not be added in the product table

Thanks Sandeep

I have changed ,but there is no luck

figol New
on 5/21/13, 12:26 AM


--Borni DHIFI--
| 6 8 9
Tunis, Tunisia
--Borni DHIFI--

Techno Functional Consultant Odoo(OpenERP) 


Skype : dhifi.borni

On 5/20/13, 8:05 AM


replace <field name="ebayitemid"/> to <field name="itemid"/> in form and view.

i have changed it , but there is no luck

figol New
on 5/21/13, 12:39 AM

Serpent Consulting Services Pvt. Ltd.

--Serpent Consulting Services Pvt. Ltd.--
| 6 6 8
Gandhinagar, India
--Serpent Consulting Services Pvt. Ltd.--

Serpent Consulting Services Pvt. Ltd. Your Odoo/OpenERP Solution, just an email away!

Serpent Consulting Services Pvt. Ltd.
On 5/20/13, 8:24 AM


your field is wrong

<field name="ebayitemid"/>

to replace it <field name="itemid"/>

About This Community

This platform 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.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

1 follower(s)


Asked: 5/20/13, 7:59 AM
Seen: 4489 times
Last updated: 3/16/15, 8:10 AM