You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
1.6 KiB
34 lines
1.6 KiB
<?xml version="1.0" encoding="UTF-8"?>
|
|
<odoo>
|
|
<!-- This XML defines a new view that inherits from 'account.view_move_form'.
|
|
It adds a button for sending by Whatsapp after the 'Draft' button in the form header. -->
|
|
<record id="view_move_form" model="ir.ui.view">
|
|
<field name="name">
|
|
account.move.view.form.inherit.all.in.one.whatsapp.integration
|
|
</field>
|
|
<field name="model">account.move</field>
|
|
<field name="inherit_id" ref="account.view_move_form"/>
|
|
<field name="arch" type="xml">
|
|
<xpath expr="//form/header/button[@name='button_draft']"
|
|
position="after">
|
|
<button name="action_send_by_whatsapp" type="object"
|
|
class="oe_highlight" string="Send By Whatsapp"
|
|
icon="fa-whatsapp"/>
|
|
</xpath>
|
|
</field>
|
|
</record>
|
|
<record model="ir.actions.act_window"
|
|
id="mail_template_invoice_action">
|
|
<field name="name">Whatsapp Templates for Invoice</field>
|
|
<field name="res_model">mail.template</field>
|
|
<field name="view_mode">form,tree</field>
|
|
<field name="view_id" ref="mail.email_template_tree"/>
|
|
<field name="search_view_id" ref="mail.view_email_template_search"/>
|
|
<field name="domain">[('is_invoice_template','=', True)]</field>
|
|
</record>
|
|
<menuitem id="account_move_menu"
|
|
name="Whatsapp Templates"
|
|
parent="account.menu_finance_configuration"
|
|
action="all_in_one_whatsapp_integration.mail_template_invoice_action"
|
|
sequence="100"/>
|
|
</odoo>
|
|
|