Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
6932 Lượt xem
How to inherit this report and set the landscape orientation in my module?
<report
string="Purchase Order"
id="action_report_purchase_order"
model="purchase.order"
report_type="qweb-pdf"
name="purchase.report_purchaseorder"
file="purchase.report_purchaseorder"
print_report_name="
(object.state in ('draft', 'sent') and 'Request for Quotation - %s' % (object.name) or
'Purchase Order - %s' % (object.name))"
/>
Ảnh đại diện
Huỷ bỏ

Please use a meaningful title.

Câu trả lời hay nhất

Hello

make new paperformat with the orientation option "Landscape", like below option.

<record id="paperformat_landscape" model="report.paperformat">

            <field name="orientation">Landscape</field>

 </record>

=> for update the paperformat to report, inherit the report action.

<record id="purchase.action_report_purchase_order" model="ir.actions.report">

            <field name="paperformat_id" ref="your_module.paperformat_landscape"/>

 </record>

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 5 16
3149
1
thg 3 15
5779
2
thg 8 19
3230
0
thg 9 17
3477
2
thg 3 25
4891