Odoo Help


Creating report using Webkit in OpenERP 7 (Adding Inherit fields)

on 6/25/14, 3:22 AM 1,843 views

I am trying to print inherited fields it is giving error if i try to print them my code is here as under in mako file,

I got help from this https://openerp.my.openerp.com/forum/Help-1/question/Doubt-when-creating-report-using-aeroo-report-in-Openerp7Adding-Inherit-fields-39539, and try to print inherited fields code is as,

NOTE In my module asset.provision is base class and asset.provision.line is other class by which I am creating one2many relation and asset_line is the only one2many field i am trying to print :(

     <p> Department ID id   ${ o.id }    

     <p style="font-family:verdana;">    Provision Name is "${ o.name }"  </p>
     <p> Deadline Date is "${ o.deadline_date }"  </p>
     <p> Current state is "${ o.state }"  </p>

          <for each="line in o.one2many field in asset.provision">
<p>value is </p>
      <line.fieldname in="S{asset.provision.line}" one2many="asset.provision" field.columnname="asset_line" >


i am getting error Undefined object in line ,

     <line.fieldname in="S{asset.provision.line}" one2many="asset.provision" field.columnname="asset_line" >

if i remove ${} it do not show any error and do not print any thing

     <line.fieldname in="asset.provision" one2many="asset.provision.line" field.columnname="asset_line" >

Hopes for your positive reply

Timothy Solomon
On 7/8/14, 7:37 AM

You are mixing aeroo reporting with webkit/mako syntax - its not going to work. 

Try something like 

%for line in o.asset_line:


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: 6/25/14, 3:22 AM
Seen: 1843 times
Last updated: 3/16/15, 8:10 AM