Invoicing: Invoice email ${(object.user_id.email and '"%s" <%s>' % (object.user_id.name, object.user_id.email) or '')|safe} ${object.company_id.name} Invoice (Ref ${object.number or 'n/a'}) ${object.partner_id.id} Invoice_${(object.number or '').replace('/','_')}_${object.state == 'draft' and 'draft' or ''} ${object.partner_id.lang}

Dear ${object.partner_id.name} % set access_action = object.with_context(force_website=True).get_access_action() % set is_online = access_action and access_action['type'] == 'ir.actions.act_url' % set access_url = object.get_mail_url() % if object.partner_id.parent_id: (${object.partner_id.parent_id.name}) % endif ,

Here is, in attachment, your % if object.number: invoice ${object.number} % else: invoice % endif % if object.origin: (with reference: ${object.origin}) % endif amounting in ${format_amount(object.amount_total, object.currency_id)} from ${object.company_id.name}.

% if is_online:

View Invoice
% endif

% if object.state=='paid':

This invoice is already paid.

% else:

Please remit payment at your earliest convenience.

% endif

Thank you,

% if object.user_id and object.user_id.signature: ${object.user_id.signature | safe} % endif

Account: Invoice notification header ${object.subject}
% set record = ctx.get('record') % set company = record and record.company_id or ctx.get('company')
Invoice ${object.record_name} ${company.name}
${object.body | safe}
${company.name}
${company.phone or ''}
% if company.email: ${company.email}
% endif % if company.website: ${company.website} % endif