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

i want to get al invoice record with invoice line

By
kartik
on 10/20/15, 5:53 AM 304 views

hi in account module i want to get all invoice record with invoice line and customer wise filter

i create one parser file parser.py

in which following function is used

def invoices(self):

self.cr.execute(

"SELECT * FROM account_move_line l ")

res = self.cr.dictfetchall()

return res

after i access in report.xml file

like

<t t-foreach="invoices()" t-as="i">

<tr>

<td>

<span t-esc="i['ref']"/>

</td>

<td>

<span t-esc="i['id']"/>

</td>

<td>

<span t-esc="i['date_created']"/>

</td>

<td>

<span t-esc="i['name']"/>

</td>

<td>

<span t-esc="i['partner_id']"/>

</td>

<td>

<span t-esc="i['credit']"/>

</td>

</tr>

</t>


but it will nit return information properly

how can i get all invoice with invoice line in report.xml

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

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

Question tools

1 follower(s)

Stats

Asked: 10/20/15, 5:53 AM
Seen: 304 times
Last updated: 10/20/15, 5:53 AM