Purpose is to have all mail template into a mail_template_data.xml file when possible. It eases maintenance and update when having to work globally on template records. Also update some ``body_html`` declarations still using ``xml`` instead of ``html``. Task ID-2534550 (Template usage improvement) Task ID-2477164 (Composer mixin) Prepares Task ID-27033 (QWeb in templates) COM PR odoo/odoo#70889 ENT PR odoo/enterprise#18352
39 lines
3.0 KiB
XML
39 lines
3.0 KiB
XML
<?xml version="1.0" ?>
|
|
<odoo>
|
|
<record id="mail_template_gift_card" model="mail.template">
|
|
<field name="name">Gift Card: Send by Email</field>
|
|
<field name="model_id" ref="model_gift_card"/>
|
|
<field name="subject">Your Gift Card</field>
|
|
<field name="partner_to">${object.partner_id.id or object.buy_line_id.order_id.partner_id.id}</field>
|
|
<field name="body_html" type="html">
|
|
<div style="margin:0px; font-size:24px; font-family:arial, 'helvetica neue', helvetica, sans-serif; line-height:36px; color:#333333; text-align: center">
|
|
Here is your gift card!
|
|
</div>
|
|
<div style="padding-top:20px; padding-bottom:20px">
|
|
<img src="/gift_card/static/img/gift_card.png" style="display:block; border:0; outline:none; text-decoration:none; margin:auto;" width="300"/>
|
|
</div>
|
|
<div style="padding:0; margin:0px; padding-top:35px; padding-bottom:35px; text-align:center;">
|
|
<h3 style="margin:0px; line-height:48px; font-family:arial, 'helvetica neue', helvetica, sans-serif; font-size:40px; font-style:normal; font-weight:normal; color:#333333; text-align:center">
|
|
<strong>${format_amount(object.initial_amount, object.currency_id)}</strong></h3>
|
|
</div>
|
|
<div style="padding:0; margin:0px; padding-top:35px; padding-bottom:35px; background-color:#efefef; text-align:center;">
|
|
<p style="margin:0px; font-size:14px;font-family:arial, 'helvetica neue', helvetica, sans-serif; line-height:21px; color:#333333">
|
|
<strong>Gift Card Code</strong>
|
|
</p>
|
|
<p style="margin:0px; font-size:25px;font-family:arial, 'helvetica neue', helvetica, sans-serif; line-height:38px; color:#A9A9A9">
|
|
${object.code}
|
|
</p>
|
|
</div>
|
|
<div style="padding:0; margin:0px; padding-top:10px; padding-bottom:10px; text-align:center;">
|
|
<h3 style="margin:0px; line-height:17px; font-family:arial, 'helvetica neue', helvetica, sans-serif; font-size:14px; font-style:normal; font-weight:normal; color:#A9A9A9; text-align:center">Card expires ${format_date(object.expired_date)}</h3>
|
|
</div>
|
|
<div style="padding:20px; margin:0px; text-align:center;">
|
|
<span style="background-color:#999999; display:inline-block; width:auto; border-radius:5px;">
|
|
<a href="${object.buy_line_id.order_id.get_base_url()}/shop" target="_blank" style="text-decoration:none; font-family:arial, 'helvetica neue', helvetica, sans-serif; font-size:22px; color:#FFFFFF; border-style:solid; border-color:#999999; border-width:20px 30px; display:inline-block; background-color:#999999; border-radius:5px; font-weight:bold; font-style:normal; line-height:26px; width:auto; text-align:center">Use it right now!</a>
|
|
</span>
|
|
</div>
|
|
</field>
|
|
<field name="auto_delete" eval="True"/>
|
|
</record>
|
|
</odoo>
|