<?xml version="1.0"?>
<form string="Templates">
                    <header>
                        <field name="template_fs" invisible="1"/>
                        <button string="Reset Template" name="105" type="action" groups="mail.group_mail_template_editor" attrs="{'invisible': [('template_fs', '=', False)]}"/>
                    </header>
                    <sheet>
                        <div class="oe_button_box" name="button_box">
                            <field name="ref_ir_act_window" invisible="1"/>
                            <button class="oe_stat_button" groups="base.group_no_one" name="create_action" type="object" attrs="{'invisible':[('ref_ir_act_window','!=',False)]}" icon="fa-plus" help="Display an option on related documents to open a composition wizard with this template">
                                <div class="o_field_widget o_stat_info">
                                    <span class="o_stat_text">Add</span>
                                    <span class="o_stat_text">Context Action</span>
                                </div>
                            </button>
                            <button name="unlink_action" type="object" groups="base.group_no_one" class="oe_stat_button" icon="fa-minus" attrs="{'invisible':[('ref_ir_act_window','=',False)]}" help="Remove the contextual action to use this template on related documents" widget="statinfo">
                                <div class="o_field_widget o_stat_info">
                                    <span class="o_stat_text">Remove</span>
                                    <span class="o_stat_text">Context Action</span>
                                </div>
                            </button>
                            <button class="oe_stat_button" name="104" icon="fa-search-plus" string="Preview" type="action" target="new"/>
                        </div>
                        <div class="oe_title">
                            <label for="name"/>
                            <h1><field name="name" class="w-100" required="1" placeholder="e.g. &quot;Welcome email&quot;"/></h1>
                            <group>
                                <field name="model_id" placeholder="e.g. Contact" required="1" options="{'no_create': True}"/>
                                <field name="subject" placeholder="e.g. &quot;Welcome to MyCompany&quot; or &quot;Nice to meet you, {{ object.name }}&quot;"/>
                                <field name="model" invisible="1"/>
                                <field name="description"/>
                            </group>
                        </div>
                        <notebook>
                            <page string="Content" name="content">
                                <field name="can_write" invisible="1"/>
                                <field name="body_html" widget="html" class="oe-bordered-editor" options="{'style-inline': true, 'codeview': true, 'dynamic_placeholder': true}" attrs="{'readonly': [('can_write', '=', False), ('id', '!=', False)]}"/>
                                <field name="attachment_ids" widget="many2many_binary"/>
                            </page>
                            <page string="Email Configuration" name="email_configuration">
                                <group>
                                    <field name="email_from" placeholder="Override author's email"/>
                                    <field name="use_default_to"/>
                                    <field name="email_to" attrs="{'invisible': [('use_default_to', '=', True)]}" placeholder="Comma-separated recipient addresses"/>
                                    <field name="partner_to" attrs="{'invisible': [('use_default_to', '=', True)]}" placeholder="Comma-separated ids of recipient partners"/>
                                    <field name="email_cc" attrs="{'invisible': [('use_default_to', '=', True)]}" placeholder="Comma-separated carbon copy recipients addresses"/>
                                    <field name="reply_to" placeholder="Email address to which replies will be redirected when sending emails in mass"/>
                                    <field name="scheduled_date" string="Scheduled Send Date"/>
                                </group>
                            </page>
                            <page string="Settings" name="email_settings">
                                <group>
                                    <field name="lang" placeholder="{{ object.partner_id.lang }}"/>
                                    <field name="mail_server_id"/>
                                    <field name="auto_delete"/>
                                    <field name="report_template" domain="[('model','=',model)]"/>
                                    <field name="report_name" attrs="{'invisible':[('report_template','=',False)]}"/>
                                </group>
                            </page>
                        </notebook>
                       </sheet>
                </form>
            