تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
1 الرد
4598 أدوات العرض

I need to completely change the invoice layout. I'm inheriting "account.report_invoice_document" and replacing everything inside:

<template id="report_invoice" inherit_id="account.report_invoice_document" name="Custom invoice">
    <xpath expr="." position="replace">


I've removed "external_layout" and replaced it with only this:

<div class="article" t-att-data-oe-model="o and o._name" t-att-data-oe-id="o and o.id" t-att-data-oe-lang="o and o.env.context.get('lang')" style="position:absolute; top:0px; ">


But I have but trouble with a blank space above actual content. I've read that I can change a paper format and remove top margin. But this will also break other reports that use normal layout.

How do I do this? Can I assign custom paper format only for invoices? How? Or is there other way?

Also this class="article" seems to be necessary for some reason.


Using Odoo 13




الصورة الرمزية
إهمال
أفضل إجابة

Hi,

You need to create a new Paper-format and assigned to Invoice Report.

Thanks 

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
2
أغسطس 20
4850
1
أبريل 15
4655
2
ديسمبر 20
2581
0
يونيو 20
2037
3
يناير 20
7505