2011-06-30 13:37:57 +00:00
|
|
|
<?xml version="1.0" ?>
|
|
|
|
<openerp>
|
2011-09-30 21:21:54 +00:00
|
|
|
<data>
|
2011-11-05 01:59:22 +00:00
|
|
|
<!-- EDI related Email Templates menu -->
|
|
|
|
<record model="ir.actions.act_window" id="action_email_templates">
|
|
|
|
<field name="name">Email Templates</field>
|
|
|
|
<field name="res_model">email.template</field>
|
|
|
|
<field name="view_type">form</field>
|
|
|
|
<field name="view_mode">form,tree</field>
|
|
|
|
<field name="view_id" ref="email_template.email_template_tree" />
|
|
|
|
<field name="search_view_id" ref="email_template.view_email_template_search"/>
|
|
|
|
<field name="context">{'search_default_model_id':'account.invoice'}</field>
|
|
|
|
<field name="context" eval="{'search_default_model_id': ref('account.model_account_invoice')}"/>
|
|
|
|
</record>
|
2012-03-22 13:46:57 +00:00
|
|
|
<menuitem id="menu_email_templates" parent="menu_configuration_misc" action="action_email_templates" sequence="30" groups="base.group_no_one"/>
|
2011-11-05 01:59:22 +00:00
|
|
|
|
2011-09-30 21:21:54 +00:00
|
|
|
</data>
|
2011-06-30 13:37:57 +00:00
|
|
|
|
2012-10-11 15:20:08 +00:00
|
|
|
<!-- Mail template are declared in a NOUPDATE block
|
2011-09-30 21:21:54 +00:00
|
|
|
so users can freely customize/delete them -->
|
|
|
|
<data noupdate="1">
|
|
|
|
<!--Email template -->
|
|
|
|
<record id="email_template_edi_invoice" model="email.template">
|
2012-11-16 16:16:38 +00:00
|
|
|
<field name="name">Invoice - Send by Email</field>
|
2013-11-22 10:45:09 +00:00
|
|
|
<field name="email_from">${(object.user_id.email or object.company_id.email or 'noreply@localhost')|safe}</field>
|
2014-08-04 15:24:56 +00:00
|
|
|
<field name="subject">${object.company_id.name|safe} Invoice (Ref ${object.number or 'n/a'})</field>
|
2013-02-25 10:19:18 +00:00
|
|
|
<field name="partner_to">${object.partner_id.id}</field>
|
2011-09-30 21:21:54 +00:00
|
|
|
<field name="model_id" ref="account.model_account_invoice"/>
|
2011-11-03 01:10:34 +00:00
|
|
|
<field name="auto_delete" eval="True"/>
|
2012-10-23 11:42:14 +00:00
|
|
|
<field name="report_template" ref="account_invoices"/>
|
|
|
|
<field name="report_name">Invoice_${(object.number or '').replace('/','_')}_${object.state == 'draft' and 'draft' or ''}</field>
|
2012-04-30 14:35:27 +00:00
|
|
|
<field name="lang">${object.partner_id.lang}</field>
|
2011-10-05 00:34:09 +00:00
|
|
|
<field name="body_html"><![CDATA[
|
2012-04-30 13:21:03 +00:00
|
|
|
<div style="font-family: 'Lucica Grande', Ubuntu, Arial, Verdana, sans-serif; font-size: 12px; color: rgb(34, 34, 34); background-color: #FFF; ">
|
2011-08-26 11:09:14 +00:00
|
|
|
|
2012-12-14 09:10:57 +00:00
|
|
|
<p>Hello ${object.partner_id.name},</p>
|
2012-03-07 10:42:05 +00:00
|
|
|
|
2012-11-21 10:04:34 +00:00
|
|
|
<p>A new invoice is available for you: </p>
|
2011-09-30 21:21:54 +00:00
|
|
|
|
2011-10-05 00:34:09 +00:00
|
|
|
<p style="border-left: 1px solid #8e0000; margin-left: 30px;">
|
|
|
|
<strong>REFERENCES</strong><br />
|
|
|
|
Invoice number: <strong>${object.number}</strong><br />
|
2011-10-06 11:36:51 +00:00
|
|
|
Invoice total: <strong>${object.amount_total} ${object.currency_id.name}</strong><br />
|
|
|
|
Invoice date: ${object.date_invoice}<br />
|
|
|
|
% if object.origin:
|
|
|
|
Order reference: ${object.origin}<br />
|
|
|
|
% endif
|
2012-10-23 11:42:14 +00:00
|
|
|
% if object.user_id:
|
2012-12-14 09:03:40 +00:00
|
|
|
Your contact: <a href="mailto:${object.user_id.email or ''}?subject=Invoice%20${object.number}">${object.user_id.name}</a>
|
2012-10-23 11:42:14 +00:00
|
|
|
% endif
|
2011-10-05 00:34:09 +00:00
|
|
|
</p>
|
2011-09-30 21:21:54 +00:00
|
|
|
|
2012-12-14 11:31:32 +00:00
|
|
|
% if object.paypal_url:
|
2011-10-05 00:34:09 +00:00
|
|
|
<br/>
|
|
|
|
<p>It is also possible to directly pay with Paypal:</p>
|
2012-12-14 11:31:32 +00:00
|
|
|
<a style="margin-left: 120px;" href="${object.paypal_url}">
|
2015-01-06 15:59:48 +00:00
|
|
|
<img class="oe_edi_paypal_button" src="/account/static/src/img/btn_paynowcc_lg.gif"/>
|
2011-10-28 13:49:32 +00:00
|
|
|
</a>
|
2011-09-30 21:21:54 +00:00
|
|
|
% endif
|
|
|
|
|
2011-10-05 00:34:09 +00:00
|
|
|
<br/>
|
|
|
|
<p>If you have any question, do not hesitate to contact us.</p>
|
|
|
|
<p>Thank you for choosing ${object.company_id.name or 'us'}!</p>
|
|
|
|
<br/>
|
|
|
|
<br/>
|
2011-10-26 00:01:10 +00:00
|
|
|
<div style="width: 375px; margin: 0px; padding: 0px; background-color: #8E0000; border-top-left-radius: 5px 5px; border-top-right-radius: 5px 5px; background-repeat: repeat no-repeat;">
|
2012-04-30 13:21:03 +00:00
|
|
|
<h3 style="margin: 0px; padding: 2px 14px; font-size: 12px; color: #DDD;">
|
2011-10-05 00:34:09 +00:00
|
|
|
<strong style="text-transform:uppercase;">${object.company_id.name}</strong></h3>
|
|
|
|
</div>
|
2011-10-26 00:01:10 +00:00
|
|
|
<div style="width: 347px; margin: 0px; padding: 5px 14px; line-height: 16px; background-color: #F2F2F2;">
|
|
|
|
<span style="color: #222; margin-bottom: 5px; display: block; ">
|
2011-09-30 21:21:54 +00:00
|
|
|
% if object.company_id.street:
|
2011-10-05 00:34:09 +00:00
|
|
|
${object.company_id.street}<br/>
|
2011-09-30 21:21:54 +00:00
|
|
|
% endif
|
|
|
|
% if object.company_id.street2:
|
2011-10-05 00:34:09 +00:00
|
|
|
${object.company_id.street2}<br/>
|
2011-09-30 21:21:54 +00:00
|
|
|
% endif
|
|
|
|
% if object.company_id.city or object.company_id.zip:
|
2011-10-05 00:34:09 +00:00
|
|
|
${object.company_id.zip} ${object.company_id.city}<br/>
|
2011-09-30 21:21:54 +00:00
|
|
|
% endif
|
|
|
|
% if object.company_id.country_id:
|
2011-10-05 00:34:09 +00:00
|
|
|
${object.company_id.state_id and ('%s, ' % object.company_id.state_id.name) or ''} ${object.company_id.country_id.name or ''}<br/>
|
2011-09-30 21:21:54 +00:00
|
|
|
% endif
|
2011-10-05 00:34:09 +00:00
|
|
|
</span>
|
2011-09-30 21:21:54 +00:00
|
|
|
% if object.company_id.phone:
|
2011-10-05 00:34:09 +00:00
|
|
|
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
|
2011-09-30 21:21:54 +00:00
|
|
|
Phone: ${object.company_id.phone}
|
2011-10-05 00:34:09 +00:00
|
|
|
</div>
|
2011-09-30 21:21:54 +00:00
|
|
|
% endif
|
|
|
|
% if object.company_id.website:
|
2011-10-05 00:34:09 +00:00
|
|
|
<div>
|
2012-12-14 09:03:40 +00:00
|
|
|
Web : <a href="${object.company_id.website}">${object.company_id.website}</a>
|
2011-10-05 00:34:09 +00:00
|
|
|
</div>
|
2011-09-30 21:21:54 +00:00
|
|
|
%endif
|
2011-10-05 00:34:09 +00:00
|
|
|
<p></p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
]]></field>
|
2011-09-30 21:21:54 +00:00
|
|
|
</record>
|
|
|
|
</data>
|
2011-06-30 13:37:57 +00:00
|
|
|
</openerp>
|