Add a 'send & save' button next to 'save & close'

This commit is contained in:
Arnaud LAYEC
2024-06-14 18:05:12 +02:00
committed by Alexis de Lattre
parent 67ff087f6e
commit 827557689f

View File

@@ -20,19 +20,28 @@
</record>
<!-- Add "Opportunity" field on calendar event -->
<record id="view_calendar_event_form" model="ir.ui.view">
<field name="name">calendar.event.form.usability</field>
<field name="model">calendar.event</field>
<field name="inherit_id" ref="calendar.view_calendar_event_form"/>
<field name="arch" type="xml">
<xpath expr="//notebook" position="inside">
<!-- Add "Opportunity" field on calendar event -->
<notebook position="inside">
<page name="crm" string="CRM">
<group>
<field name="opportunity_id" />
</group>
</page>
</xpath>
</notebook>
<!-- Add "send & save" button next to "save & close" -->
<form position="inside">
<footer>
<button name="action_open_composer" type="object" string="Save &amp; Send" class="btn btn-primary" />
<button string="Save &amp; Close" special="save" />
<button string="Discard" special="cancel"/>
</footer>
</form>
</field>
</record>
</odoo>