[FIX] event: confirmation_event and confirmation_registration

-The lang of the partner linked to the "event_registration" record
must be used to send the registration/confirmation email.

-strftime cannot be used on a string.

opw:649510
This commit is contained in:
Goffin Simon 2015-09-17 10:40:10 +02:00
parent 3c39b62bce
commit 75233860a2
1 changed files with 3 additions and 1 deletions

View File

@ -6,10 +6,11 @@
<field name="model_id" ref="event.model_event_registration"/>
<field name="email_from" >${(object.user_id.email or object.company_id.email or 'noreply@' + object.company_id.name + '.com')|safe}</field>
<field name="email_to" >${object.email|safe}</field>
<field name="lang">${object.partner_id.lang}</field>
<field name="subject">Your registration at ${object.event_id.name}</field>
<field name="body_html"><![CDATA[
<p>Hello ${object.name},</p>
<p>The event ${object.event_id.name} that you registered for is confirmed and will be held from ${object.event_id.date_begin_located.strftime('%Y-%m-%d %H:%M:%S (%Z)')} to ${object.event_id.date_end_located.strftime('%Y-%m-%d %H:%M:%S (%Z)')}.
<p>The event ${object.event_id.name} that you registered for is confirmed and will be held from ${object.event_id.date_begin_located} to ${object.event_id.date_end_located}.
For any further information please contact our event department.</p>
<p>Thank you for your participation!</p>
<p>Best regards</p>]]></field>
@ -20,6 +21,7 @@
<field name="model_id" ref="event.model_event_registration"/>
<field name="email_from" >${(object.user_id.email or object.company_id.email or 'noreply@' + object.company_id.name + '.com')|safe}</field>
<field name="email_to" >${object.email|safe}</field>
<field name="lang">${object.partner_id.lang}</field>
<field name="subject">Your registration at ${object.event_id.name}</field>
<field name="body_html"><![CDATA[
<p>Hello ${object.name},</p>