Hi what i trying to do is create report in odoo 12, here is what i do :
first i create toxicwork_invoice/reports/soreport.xml, and the code looked like this :
<odoo>
<report
id="so_invoices"
model="salesorder.salesorder"
string="Invoices"
report_type="qweb-pdf"
name="salesorder.report_invoice"
file="salesorder.report_invoice"
/>
</odoo>
and then i create toxicwork_invoice/reports/invoice_card.xml, here is the code :
<odoo>
<template id="report_invoice_cards">
<t t-call="web.html_container">
<t t-foreach="docs" t-as="doc">
<h2>Faktur</h2>
</t>
</t>
</template>
<template id="report_invoice">
<t t-call="web.html_container">
<t t-foreach="docs" t-as="doc">
<t t-call="report_invoice_cards"/>
</t>
</t>
</template>
</odoo>
but it give me an error like this
raise ValueError('External ID not found in the system: %s' % xmlid) ValueError: External ID not found in the system: salesorder.report_invoice
What i missed?
Please give the below code;
<odoo>
<report
id="so_invoices"
model="salesorder.salesorder"
string="Invoices"
report_type="qweb-pdf"
name="toxicwork_invoice.report_invoice"
file="toxicwork_invoice.report_invoice"
/>
</odoo>
<template id="report_invoice_cards">
<t t-call="web.html_container">
<t t-foreach="docs" t-as="doc">
<h2>Faktur</h2>
</t>
</t>
</template>
<template id="report_invoice">
<t t-call="web.html_container">
<t t-foreach="docs" t-as="doc">
<t t-call="toxicwork_invoice.report_invoice_cards"/>
</t>
</t>
</template>