changes
This commit is contained in:
96
fusion_reports_templates/data/hide_default_reports.xml
Normal file
96
fusion_reports_templates/data/hide_default_reports.xml
Normal file
@@ -0,0 +1,96 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Copyright 2026 Nexa Systems Inc.
|
||||
License OPL-1 (Odoo Proprietary License v1.0)
|
||||
|
||||
Remove Odoo's default PDF reports from each model's Print dropdown
|
||||
so users can't accidentally send the unbranded version. Setting
|
||||
`binding_model_id` to False leaves the underlying report intact;
|
||||
an admin can re-enable any of these from Settings → Technical →
|
||||
Actions → Reports.
|
||||
|
||||
Loaded last so it overrides the binding declarations shipped by
|
||||
the base modules.
|
||||
-->
|
||||
<odoo noupdate="0">
|
||||
|
||||
<!-- sale.order -->
|
||||
<record id="sale.action_report_saleorder" model="ir.actions.report">
|
||||
<field name="binding_model_id" eval="False"/>
|
||||
<field name="binding_type">action</field>
|
||||
</record>
|
||||
|
||||
<!-- account.move -->
|
||||
<record id="account.account_invoices" model="ir.actions.report">
|
||||
<field name="binding_model_id" eval="False"/>
|
||||
<field name="binding_type">action</field>
|
||||
</record>
|
||||
<record id="account.account_invoices_without_payment" model="ir.actions.report">
|
||||
<field name="binding_model_id" eval="False"/>
|
||||
<field name="binding_type">action</field>
|
||||
</record>
|
||||
|
||||
<!-- stock.picking -->
|
||||
<record id="stock.action_report_delivery" model="ir.actions.report">
|
||||
<field name="binding_model_id" eval="False"/>
|
||||
<field name="binding_type">action</field>
|
||||
</record>
|
||||
|
||||
<!-- purchase.order: PO + RFQ -->
|
||||
<record id="purchase.action_report_purchase_order" model="ir.actions.report">
|
||||
<field name="binding_model_id" eval="False"/>
|
||||
<field name="binding_type">action</field>
|
||||
</record>
|
||||
<record id="purchase.report_purchase_quotation" model="ir.actions.report">
|
||||
<field name="binding_model_id" eval="False"/>
|
||||
<field name="binding_type">action</field>
|
||||
</record>
|
||||
|
||||
<!-- sale.order: pro-forma -->
|
||||
<record id="sale.action_report_pro_forma_invoice" model="ir.actions.report">
|
||||
<field name="binding_model_id" eval="False"/>
|
||||
<field name="binding_type">action</field>
|
||||
</record>
|
||||
|
||||
<!-- account.payment -->
|
||||
<record id="account.action_report_payment_receipt" model="ir.actions.report">
|
||||
<field name="binding_model_id" eval="False"/>
|
||||
<field name="binding_type">action</field>
|
||||
</record>
|
||||
|
||||
<!-- ================================================================
|
||||
Print-menu sequencing — pin Fusion reports to the top.
|
||||
Portrait = 10 (primary), Landscape = 15 (secondary).
|
||||
================================================================ -->
|
||||
<record id="fusion_reports_templates.action_report_fr_sale_portrait" model="ir.actions.report">
|
||||
<field name="sequence" eval="10"/>
|
||||
</record>
|
||||
<record id="fusion_reports_templates.action_report_fr_sale_landscape" model="ir.actions.report">
|
||||
<field name="sequence" eval="15"/>
|
||||
</record>
|
||||
<record id="fusion_reports_templates.action_report_fr_invoice_portrait" model="ir.actions.report">
|
||||
<field name="sequence" eval="10"/>
|
||||
</record>
|
||||
<record id="fusion_reports_templates.action_report_fr_invoice_landscape" model="ir.actions.report">
|
||||
<field name="sequence" eval="15"/>
|
||||
</record>
|
||||
<record id="fusion_reports_templates.action_report_fr_delivery_portrait" model="ir.actions.report">
|
||||
<field name="sequence" eval="10"/>
|
||||
</record>
|
||||
<record id="fusion_reports_templates.action_report_fr_delivery_landscape" model="ir.actions.report">
|
||||
<field name="sequence" eval="15"/>
|
||||
</record>
|
||||
<record id="fusion_reports_templates.action_report_fr_purchase_portrait" model="ir.actions.report">
|
||||
<field name="sequence" eval="10"/>
|
||||
</record>
|
||||
<record id="fusion_reports_templates.action_report_fr_purchase_landscape" model="ir.actions.report">
|
||||
<field name="sequence" eval="15"/>
|
||||
</record>
|
||||
<record id="fusion_reports_templates.action_report_fr_receipt_portrait" model="ir.actions.report">
|
||||
<field name="sequence" eval="10"/>
|
||||
</record>
|
||||
<record id="fusion_reports_templates.action_report_fr_receipt_landscape" model="ir.actions.report">
|
||||
<field name="sequence" eval="15"/>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
80
fusion_reports_templates/data/mail_template_override.xml
Normal file
80
fusion_reports_templates/data/mail_template_override.xml
Normal file
@@ -0,0 +1,80 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Copyright 2026 Nexa Systems Inc.
|
||||
License OPL-1 (Odoo Proprietary License v1.0)
|
||||
|
||||
Re-point the stock "Send by Email" mail templates so the attached PDF
|
||||
uses Fusion Reports branded design instead of Odoo's default layout.
|
||||
|
||||
`report_template_ids` is Many2many on mail.template; replacing with a
|
||||
`[(6, 0, [...])]` op swaps the attached reports atomically.
|
||||
|
||||
noupdate="0" so upgrades re-apply the binding (counter-acts any manual
|
||||
edit a user may have made in Settings → Technical → Email Templates).
|
||||
-->
|
||||
<odoo noupdate="0">
|
||||
|
||||
<!-- Sales: Send Quotation -->
|
||||
<record id="sale.email_template_edi_sale" model="mail.template">
|
||||
<field name="report_template_ids" eval="[(6, 0, [
|
||||
ref('fusion_reports_templates.action_report_fr_sale_portrait')
|
||||
])]"/>
|
||||
</record>
|
||||
|
||||
<!-- Sales: Order Confirmation (confirmed SO) -->
|
||||
<record id="sale.mail_template_sale_confirmation" model="mail.template">
|
||||
<field name="report_template_ids" eval="[(6, 0, [
|
||||
ref('fusion_reports_templates.action_report_fr_sale_portrait')
|
||||
])]"/>
|
||||
</record>
|
||||
|
||||
<!-- Invoice: Send -->
|
||||
<record id="account.email_template_edi_invoice" model="mail.template">
|
||||
<field name="report_template_ids" eval="[(6, 0, [
|
||||
ref('fusion_reports_templates.action_report_fr_invoice_portrait')
|
||||
])]"/>
|
||||
</record>
|
||||
|
||||
<!-- Credit Note: Send -->
|
||||
<record id="account.email_template_edi_credit_note" model="mail.template">
|
||||
<field name="report_template_ids" eval="[(6, 0, [
|
||||
ref('fusion_reports_templates.action_report_fr_invoice_portrait')
|
||||
])]"/>
|
||||
</record>
|
||||
|
||||
<!-- Payment: Receipt -->
|
||||
<record id="account.mail_template_data_payment_receipt" model="mail.template">
|
||||
<field name="report_template_ids" eval="[(6, 0, [
|
||||
ref('fusion_reports_templates.action_report_fr_receipt_portrait')
|
||||
])]"/>
|
||||
</record>
|
||||
|
||||
<!-- Stock: Delivery confirmation -->
|
||||
<record id="stock.mail_template_data_delivery_confirmation" model="mail.template">
|
||||
<field name="report_template_ids" eval="[(6, 0, [
|
||||
ref('fusion_reports_templates.action_report_fr_delivery_portrait')
|
||||
])]"/>
|
||||
</record>
|
||||
|
||||
<!-- Purchase: RFQ -->
|
||||
<record id="purchase.email_template_edi_purchase" model="mail.template">
|
||||
<field name="report_template_ids" eval="[(6, 0, [
|
||||
ref('fusion_reports_templates.action_report_fr_purchase_portrait')
|
||||
])]"/>
|
||||
</record>
|
||||
|
||||
<!-- Purchase: Confirmed PO -->
|
||||
<record id="purchase.email_template_edi_purchase_done" model="mail.template">
|
||||
<field name="report_template_ids" eval="[(6, 0, [
|
||||
ref('fusion_reports_templates.action_report_fr_purchase_portrait')
|
||||
])]"/>
|
||||
</record>
|
||||
|
||||
<!-- Purchase: Vendor Reminder -->
|
||||
<record id="purchase.email_template_edi_purchase_reminder" model="mail.template">
|
||||
<field name="report_template_ids" eval="[(6, 0, [
|
||||
ref('fusion_reports_templates.action_report_fr_purchase_portrait')
|
||||
])]"/>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user