I have created a custom report for invoice summary, i can easily fetch the header part of the invoice line invoice date, partner name etc.. But when it comes to invoice lines I am unable to fetch the data.
Please check this code out
for invoice in invoice_objs:
invoice_date = invoice.invoice_date.strftime('%Y-%m-%d') /correct
worksheet.write(row, 0, invoice_date) /correct
worksheet.write(row, 1, invoice.name) /correct
worksheet.write(row, 2, invoice.partner_id.name)
for product_id in account.move.line:
worksheet.write(row, 3, invoice_line_ids.product_id.name)
I am getting error in the last 3 lines of the code
can anyone suggest how to fetch data from a one2many field in odoo13