diff options
| author | Thibault Delavallée <tde@odoo.com> | 2020-07-29 08:52:00 +0000 |
|---|---|---|
| committer | Thibault Delavallée <tde@odoo.com> | 2020-07-31 15:34:30 +0000 |
| commit | 4ac288b9444229729f01f1ec7c14121fbd2bab0f (patch) | |
| tree | c260659e800e1ed82f849593b290ee3c9442d4ce /addons/event/data | |
| parent | 0d4cb52b9dcd56cb463f2168eaea7a0e8fc2d9a8 (diff) | |
[REF] event: improve (and fix) default email templates
RATIONALE
Events are sometimes held online, gathering a community. In this merge we
improve Event application to better support full-online events with improved
tracks, wishlists, chat rooms, ...
PURPOSE
Prepare Event Online support by providing fixes in registration and event
frontend flows. Also provide a quick back2basic in backend views to prepare
addition of Online sub modules.
SPECIFICATIONS: CONFIRMATION / REMINDER EMAIL
Reorder a bit content: add links to add to calendar directly in header
text, between confirmation and signature.
Add a section holding a link to PWA in order to showcase it to customers.
Apply fixes :
* correctly use 50% width only for date / location display when location
is not set;
* correctly put jinja tags to make valid html, otherwise edit / save template
breaks it when browse move jinja tags a bit randomly (e.g. %if between
tr tag is not valid html and broken by design);
* correctly compute horizontal separation lines, display them only when there
is actually some content to separate;
* correctly support organizer / no organizer, address / no address and
online / not online in all template;
Notes: this require to re-generate the whole translations templates of both
templates but this seems a required pain. Indeed current template are broken
beyong redemption.
Fixes notably cfca2bb0ffa8a16aeafa3c4114c7f731ee0c87d9
LINKS
Community PR odoo/odoo#55197
Enterprise PR odoo/enterprise#12113
Task ID-2309702 (Event Preparatory Merge 4)
Prepares Task ID-2252655 (Main Online Event task)
Prepares Task ID-2283796 (Event B2Basics / Registration Flow)
Prepares Task ID-2299857 (Event Design Review)
Diffstat (limited to 'addons/event/data')
| -rw-r--r-- | addons/event/data/email_template_data.xml | 338 |
1 files changed, 197 insertions, 141 deletions
diff --git a/addons/event/data/email_template_data.xml b/addons/event/data/email_template_data.xml index 9ee4351ff89..b41bd61c623 100644 --- a/addons/event/data/email_template_data.xml +++ b/addons/event/data/email_template_data.xml @@ -37,6 +37,9 @@ <table border="0" cellpadding="0" cellspacing="0" style="padding-top: 16px; background-color: #F1F1F1; font-family:Verdana, Arial,sans-serif; color: #454748; width: 100%; border-collapse:separate;"><tr><td align="center"> % set date_begin = format_datetime(object.event_id.date_begin, tz='UTC', dt_format='%Y%m%dT%H%M%SZ') % set date_end = format_datetime(object.event_id.date_end, tz='UTC', dt_format='%Y%m%dT%H%M%SZ') +% set is_online = 'is_published' in object.event_id and object.event_id.is_published +% set event_organizer = object.event_id.organizer_id +% set event_address = object.event_id.address_id <table border="0" cellpadding="0" cellspacing="0" width="590" style="padding: 16px; background-color: white; color: #454748; border-collapse:separate;"> <tbody> <!-- HEADER --> @@ -49,7 +52,14 @@ ${object.name} </span> </td><td valign="middle" align="right"> + % if is_online + <a href="${object.event_id.website_url}" + style="padding: 8px 12px; font-size: 12px; color: #FFFFFF; text-decoration: none !important; font-weight: 400; background-color: #875A7B; border: 0px solid #875A7B; border-radius:3px"> + View Event + </a> + % else <img src="${'/logo.png?company=%s' % object.company_id.id}" style="padding: 0px; margin: 0px; height: auto; width: 80px;" alt="${'%s' % object.company_id.name}"/> + % endif </td></tr> <tr><td colspan="2" style="text-align:center;"> <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin:16px 0px 16px 0px;"/> @@ -65,27 +75,31 @@ <div> Hello ${object.name or ''},<br/> We are happy to confirm your registration to the event - % if 'website_published' in object.event_id and object.event_id.website_published: + % if is_online: <a href="${object.event_id.website_url}" style="color:#875A7B;text-decoration:none;">${object.event_id.name}</a> % else: <strong>${object.event_id.name}</strong> % endif for attendee ${object.name}. </div> - % if 'website_published' in object.event_id and object.event_id.website_published: - <div style="margin: 16px 0px 16px 0px;"> - <a href="${object.event_id.website_url}" - style="background-color: #875A7B; padding: 8px 16px 8px 16px; text-decoration: none; color: #fff; border-radius: 5px; font-size:16px;">View Event</a><br /> + <div> + <br /> + <strong>Add this event to your calendar</strong> + <a href="https://www.google.com/calendar/render?action=TEMPLATE&text=${object.event_id.name}&dates=${date_begin}/${date_end}&location=${location}" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;" target="new"><img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> Google</a> + <a href="/event/${slug(object.event_id)}/ics" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;"><img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> iCal/Outlook</a> + <a href="https://calendar.yahoo.com/?v=60&view=d&type=20&title=${object.event_id.name}&in_loc=${location}&st=${format_datetime(object.event_id.date_begin, tz='UTC', dt_format='%Y%m%dT%H%M%S')}&et=${format_datetime(object.event_id.date_end, tz='UTC', dt_format='%Y%m%dT%H%M%S')}" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;" target="new"> + <img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> Yahoo + </a> + <br /><br /> </div> - % endif <div> See you soon,<br/> <span style="color: #454748;"> -- <br/> - % if object.event_id.organizer_id: - ${object.event_id.organizer_id.name} + % if event_organizer: + ${event_organizer.name} % else: - The organizers. + The ${object.event_id.name} Team % endif </span> </div> @@ -111,84 +125,98 @@ <div><strong>To</strong> ${object.event_id.date_end_located}</div> <div style="font-size:12px;color:#9e9e9e"><i><strong>TZ</strong> ${object.event_id.date_tz}</i></div> </td> - % if object.event_id.address_id.country_id.name: - <td style="vertical-align:top;"> - <img src="/web_editor/font_to_img/61505/rgb(81,81,102)/34" style="padding:4px;max-width:inherit;" height="34" alt=""/> - </td> - <td style="padding: 0px 10px 0px 10px;width:50%;vertical-align:top;"> - % set location = '' - % if object.event_id.address_id.name: - <div>${object.event_id.address_id.name}</div> - % endif - % if object.event_id.address_id.street: - <div>${object.event_id.address_id.street}</div> - % set location = object.event_id.address_id.street - % endif - % if object.event_id.address_id.street2: - <div>${object.event_id.address_id.street2}</div> - % set location = '%s, %s' % (location, object.event_id.address_id.street2) - % endif - <div> - % if object.event_id.address_id.city: - ${object.event_id.address_id.city}, - % set location = '%s, %s' % (location, object.event_id.address_id.city) - % endif - % if object.event_id.address_id.state_id.name: - ${object.event_id.address_id.state_id.name}, - % set location = '%s, %s' % (location, object.event_id.address_id.state_id.name) - % endif - % if object.event_id.address_id.zip: - ${object.event_id.address_id.zip} - % set location = '%s, %s' % (location, object.event_id.address_id.zip) - % endif - </div> - % if object.event_id.address_id.country_id.name: - <div>${object.event_id.address_id.country_id.name}</div> - % set location = '%s, %s' % (location, object.event_id.address_id.country_id.name) - % endif - </td> - % endif + <td style="vertical-align:top;"> + % if event_address: + <img src="/web_editor/font_to_img/61505/rgb(81,81,102)/34" style="padding:4px;max-width:inherit;" height="34" alt=""/> + % endif + </td> + <td style="padding: 0px 10px 0px 10px;width:50%;vertical-align:top;"> + % if event_address: + % set location = '' + % if object.event_id.address_id.name: + <div>${object.event_id.address_id.name}</div> + % endif + % if object.event_id.address_id.street: + <div>${object.event_id.address_id.street}</div> + % set location = object.event_id.address_id.street + % endif + % if object.event_id.address_id.street2: + <div>${object.event_id.address_id.street2}</div> + % set location = '%s, %s' % (location, object.event_id.address_id.street2) + % endif + <div> + % if object.event_id.address_id.city: + ${object.event_id.address_id.city}, + % set location = '%s, %s' % (location, object.event_id.address_id.city) + % endif + % if object.event_id.address_id.state_id.name: + ${object.event_id.address_id.state_id.name}, + % set location = '%s, %s' % (location, object.event_id.address_id.state_id.name) + % endif + % if object.event_id.address_id.zip: + ${object.event_id.address_id.zip} + % set location = '%s, %s' % (location, object.event_id.address_id.zip) + % endif + </div> + % if object.event_id.address_id.country_id.name: + <div>${object.event_id.address_id.country_id.name}</div> + % set location = '%s, %s' % (location, object.event_id.address_id.country_id.name) + % endif + % endif + </td> </tr> </table> </td></tr> <tr><td style="text-align:center;"> - <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + % if event_organizer + <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + % endif </td></tr> - % if object.event_id.organizer_id: + <tr><td valign="top" style="font-size: 14px;"> + <!-- CONTACT ORGANIZER --> + % if event_organizer: <div> <span style="font-weight:300;margin:10px 0px">Questions about this event?</span> <div>Please contact the organizer:</div> <ul> - <li>${object.event_id.organizer_id.name}</li> - % if object.event_id.organizer_id.email - <li>Mail: <a href="mailto:${object.event_id.organizer_id.email}" style="text-decoration:none;color:#875A7B;">${object.event_id.organizer_id.email}</a></li> + <li>${event_organizer.name}</li> + % if event_organizer.email + <li>Mail: <a href="mailto:${event_organizer.email}" style="text-decoration:none;color:#875A7B;">${event_organizer.email}</a></li> % endif - % if object.event_id.organizer_id.phone - <li>Phone: ${object.event_id.organizer_id.phone}</li> + % if event_organizer.phone + <li>Phone: ${event_organizer.phone}</li> % endif </ul> </div> + % endif + </td></tr> + <tr><td style="text-align:center;"> + <!-- CONTACT ORGANIZER SEPARATION --> + % if is_online or event_address: + <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + % endif </td></tr> - % endif + <tr><td valign="top" style="font-size: 14px;"> - <table style="width:100%;border-top:1px solid #e1e1e1;"> - <tr> - <td style="padding:25px 0px;"> - <strong>Add this event to your calendar</strong> - <a href="https://www.google.com/calendar/render?action=TEMPLATE&text=${object.event_id.name}&dates=${date_begin}/${date_end}&location=${location}" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;" target="new"><img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> Google</a> - <a href="/event/${slug(object.event_id)}/ics" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;"><img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> iCal/Outlook</a> - <a href="https://calendar.yahoo.com/?v=60&view=d&type=20&title=${object.event_id.name}&in_loc=${location}&st=${format_datetime(object.event_id.date_begin, tz='UTC', dt_format='%Y%m%dT%H%M%S')}&et=${format_datetime(object.event_id.date_end, tz='UTC', dt_format='%Y%m%dT%H%M%S')}" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;" target="new"> - <img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> Yahoo</a> - </td> - </tr> - </table> + <!-- PWA MARKGETING --> + % if is_online: + <div> + <strong>Get the best mobile experience.</strong> + <a href="/event">Install our mobile app</a> + </div> + % endif </td></tr> <tr><td style="text-align:center;"> - <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + <!-- PWA MARKGETING SEPARATION--> + % if is_online and event_address: + <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + % endif </td></tr> - % if object.event_id.address_id: + <tr><td valign="top" style="font-size: 14px;"> + <!-- GOOGLE MAPS LINK --> + % if event_address: <table style="width:100%;"><tr><td> <div> <a href="https://maps.google.com/maps?q=${location}" target="new"> @@ -196,8 +224,8 @@ </a> </div> </td></tr></table> + % endif </td></tr> - % endif </table> </td> </tr> @@ -205,19 +233,19 @@ </table> </td></tr> <!-- FOOTER BY --> -% if object.company_id <tr><td align="center" style="min-width: 590px;"> + % if object.company_id <table width="590" border="0" cellpadding="0" cellspacing="0" style="min-width: 590px; background-color: #F1F1F1; color: #454748; padding: 8px; border-collapse:separate;"> <tr><td style="text-align: center; font-size: 14px;"> Sent by <a target="_blank" href="${object.company_id.website}" style="color: #875A7B;">${object.company_id.name}</a> - % if 'website_url' in object.event_id and object.event_id.website_url: + % if is_online: <br /> Discover <a href="/event" style="text-decoration:none;color:#717188;">all our events</a>. % endif </td></tr> </table> + % endif </td></tr> -% endif </table> </field> <field name="lang">${object.partner_id.lang}</field> @@ -233,6 +261,9 @@ <table border="0" cellpadding="0" cellspacing="0" style="padding-top: 16px; background-color: #F1F1F1; font-family:Verdana, Arial,sans-serif; color: #454748; width: 100%; border-collapse:separate;"><tr><td align="center"> % set date_begin = format_datetime(object.event_id.date_begin, tz='UTC', dt_format='%Y%m%dT%H%M%SZ') % set date_end = format_datetime(object.event_id.date_end, tz='UTC', dt_format='%Y%m%dT%H%M%SZ') +% set is_online = 'is_published' in object.event_id and object.event_id.is_published +% set event_organizer = object.event_id.organizer_id +% set event_address = object.event_id.address_id <table border="0" cellpadding="0" cellspacing="0" width="590" style="padding: 16px; background-color: white; color: #454748; border-collapse:separate;"> <tbody> <!-- HEADER --> @@ -245,7 +276,14 @@ ${object.name} </span> </td><td valign="middle" align="right"> + % if is_online + <a href="${object.event_id.website_url}" + style="padding: 8px 12px; font-size: 12px; color: #FFFFFF; text-decoration: none !important; font-weight: 400; background-color: #875A7B; border: 0px solid #875A7B; border-radius:3px"> + View Event + </a> + % else <img src="${'/logo.png?company=%s' % object.company_id.id}" style="padding: 0px; margin: 0px; height: auto; width: 80px;" alt="${'%s' % object.company_id.name}"/> + % endif </td></tr> <tr><td colspan="2" style="text-align:center;"> <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin:16px 0px 16px 0px;"/> @@ -261,27 +299,31 @@ <div> Hello ${object.name},<br/> We are excited to remind you that the event - % if 'website_published' in object.event_id and object.event_id.website_published: + % if is_online: <a href="${object.event_id.website_url}" style="color:#875A7B;text-decoration:none;">${object.event_id.name}</a> % else: <strong>${object.event_id.name}</strong> % endif is starting <strong>${object.get_date_range_str()}</strong>. </div> - % if 'website_published' in object.event_id and object.event_id.website_published: - <div style="margin: 16px 0px 16px 0px;"> - <a href="${object.event_id.website_url}" - style="background-color: #875A7B; padding: 8px 16px 8px 16px; text-decoration: none; color: #fff; border-radius: 5px; font-size:16px;">View Event</a><br /> + <div> + <br /> + <strong>Add this event to your calendar</strong> + <a href="https://www.google.com/calendar/render?action=TEMPLATE&text=${object.event_id.name}&dates=${date_begin}/${date_end}&location=${location}" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;" target="new"><img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> Google</a> + <a href="/event/${slug(object.event_id)}/ics" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;"><img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> iCal/Outlook</a> + <a href="https://calendar.yahoo.com/?v=60&view=d&type=20&title=${object.event_id.name}&in_loc=${location}&st=${format_datetime(object.event_id.date_begin, tz='UTC', dt_format='%Y%m%dT%H%M%S')}&et=${format_datetime(object.event_id.date_end, tz='UTC', dt_format='%Y%m%dT%H%M%S')}" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;" target="new"> + <img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> Yahoo + </a> + <br /><br /> </div> - % endif <div> We confirm your registration and hope to meet you there,<br/> <span style="color: #454748;"> -- <br/> - % if object.event_id.organizer_id: - ${object.event_id.organizer_id.name} + % if event_organizer: + ${event_organizer.name} % else: - The organizers. + The ${object.event_id.name} Team % endif </span> </div> @@ -307,84 +349,98 @@ <div><strong>To</strong> ${object.event_id.date_end_located}</div> <div style="font-size:12px;color:#9e9e9e"><i><strong>TZ</strong> ${object.event_id.date_tz}</i></div> </td> - % if object.event_id.address_id.country_id.name: - <td style="vertical-align:top;"> - <img src="/web_editor/font_to_img/61505/rgb(81,81,102)/34" style="padding:4px;max-width:inherit;" height="34" alt=""/> - </td> - <td style="padding: 0px 10px 0px 10px;width:50%;vertical-align:top;"> - % set location = '' - % if object.event_id.address_id.name: - <div>${object.event_id.address_id.name}</div> - % endif - % if object.event_id.address_id.street: - <div>${object.event_id.address_id.street}</div> - % set location = object.event_id.address_id.street - % endif - % if object.event_id.address_id.street2: - <div>${object.event_id.address_id.street2}</div> - % set location = '%s, %s' % (location, object.event_id.address_id.street2) - % endif - <div> - % if object.event_id.address_id.city: - ${object.event_id.address_id.city}, - % set location = '%s, %s' % (location, object.event_id.address_id.city) - % endif - % if object.event_id.address_id.state_id.name: - ${object.event_id.address_id.state_id.name}, - % set location = '%s, %s' % (location, object.event_id.address_id.state_id.name) - % endif - % if object.event_id.address_id.zip: - ${object.event_id.address_id.zip} - % set location = '%s, %s' % (location, object.event_id.address_id.zip) - % endif - </div> - % if object.event_id.address_id.country_id.name: - <div>${object.event_id.address_id.country_id.name}</div> - % set location = '%s, %s' % (location, object.event_id.address_id.country_id.name) - % endif - </td> - % endif + <td style="vertical-align:top;"> + % if event_address: + <img src="/web_editor/font_to_img/61505/rgb(81,81,102)/34" style="padding:4px;max-width:inherit;" height="34" alt=""/> + % endif + </td> + <td style="padding: 0px 10px 0px 10px;width:50%;vertical-align:top;"> + % if event_address: + % set location = '' + % if object.event_id.address_id.name: + <div>${object.event_id.address_id.name}</div> + % endif + % if object.event_id.address_id.street: + <div>${object.event_id.address_id.street}</div> + % set location = object.event_id.address_id.street + % endif + % if object.event_id.address_id.street2: + <div>${object.event_id.address_id.street2}</div> + % set location = '%s, %s' % (location, object.event_id.address_id.street2) + % endif + <div> + % if object.event_id.address_id.city: + ${object.event_id.address_id.city}, + % set location = '%s, %s' % (location, object.event_id.address_id.city) + % endif + % if object.event_id.address_id.state_id.name: + ${object.event_id.address_id.state_id.name}, + % set location = '%s, %s' % (location, object.event_id.address_id.state_id.name) + % endif + % if object.event_id.address_id.zip: + ${object.event_id.address_id.zip} + % set location = '%s, %s' % (location, object.event_id.address_id.zip) + % endif + </div> + % if object.event_id.address_id.country_id.name: + <div>${object.event_id.address_id.country_id.name}</div> + % set location = '%s, %s' % (location, object.event_id.address_id.country_id.name) + % endif + % endif + </td> </tr> </table> </td></tr> <tr><td style="text-align:center;"> - <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + % if event_organizer + <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + % endif </td></tr> - % if object.event_id.organizer_id: + <tr><td valign="top" style="font-size: 14px;"> + <!-- CONTACT ORGANIZER --> + % if event_organizer: <div> <span style="font-weight:300;margin:10px 0px">Questions about this event?</span> <div>Please contact the organizer:</div> <ul> - <li>${object.event_id.organizer_id.name}</li> - % if object.event_id.organizer_id.email - <li>Mail: <a href="mailto:${object.event_id.organizer_id.email}" style="text-decoration:none;color:#875A7B;">${object.event_id.organizer_id.email}</a></li> + <li>${event_organizer.name}</li> + % if event_organizer.email + <li>Mail: <a href="mailto:${event_organizer.email}" style="text-decoration:none;color:#875A7B;">${event_organizer.email}</a></li> % endif - % if object.event_id.organizer_id.phone - <li>Phone: ${object.event_id.organizer_id.phone}</li> + % if event_organizer.phone + <li>Phone: ${event_organizer.phone}</li> % endif </ul> </div> + % endif + </td></tr> + <tr><td style="text-align:center;"> + <!-- CONTACT ORGANIZER SEPARATION --> + % if is_online or event_address: + <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + % endif </td></tr> - % endif + <tr><td valign="top" style="font-size: 14px;"> - <table style="width:100%;border-top:1px solid #e1e1e1;"> - <tr> - <td style="padding:25px 0px;"> - <strong>Add this event to your calendar</strong> - <a href="https://www.google.com/calendar/render?action=TEMPLATE&text=${object.event_id.name}&dates=${date_begin}/${date_end}&location=${location}" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;" target="new"><img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> Google</a> - <a href="/event/${slug(object.event_id)}/ics" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;"><img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> iCal/Outlook</a> - <a href="https://calendar.yahoo.com/?v=60&view=d&type=20&title=${object.event_id.name}&in_loc=${location}&st=${format_datetime(object.event_id.date_begin, tz='UTC', dt_format='%Y%m%dT%H%M%S')}&et=${format_datetime(object.event_id.date_end, tz='UTC', dt_format='%Y%m%dT%H%M%S')}" style="padding:3px 5px;border:1px solid #875A7B;color:#875A7B;text-decoration:none;border-radius:3px;" target="new"> - <img src="/web_editor/font_to_img/61525/rgb(135,90,123)/16" style="vertical-align:middle;" height="16" alt=""/> Yahoo</a> - </td> - </tr> - </table> + <!-- PWA MARKGETING --> + % if is_online: + <div> + <strong>Get the best mobile experience.</strong> + <a href="/event">Install our mobile app</a> + </div> + % endif </td></tr> <tr><td style="text-align:center;"> - <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + <!-- PWA MARKGETING SEPARATION--> + % if is_online and event_address: + <hr width="100%" style="background-color:rgb(204,204,204);border:medium none;clear:both;display:block;font-size:0px;min-height:1px;line-height:0; margin: 16px 0px 16px 0px;"/> + % endif </td></tr> - % if object.event_id.address_id: + <tr><td valign="top" style="font-size: 14px;"> + <!-- GOOGLE MAPS LINK --> + % if event_address: <table style="width:100%;"><tr><td> <div> <a href="https://maps.google.com/maps?q=${location}" target="new"> @@ -392,8 +448,8 @@ </a> </div> </td></tr></table> + % endif </td></tr> - % endif </table> </td> </tr> @@ -401,8 +457,8 @@ </table> </td></tr> <!-- FOOTER BY --> -% if object.company_id <tr><td align="center" style="min-width: 590px;"> + % if object.company_id <table width="590" border="0" cellpadding="0" cellspacing="0" style="min-width: 590px; background-color: #F1F1F1; color: #454748; padding: 8px; border-collapse:separate;"> <tr><td style="text-align: center; font-size: 14px;"> Sent by <a target="_blank" href="${object.company_id.website}" style="color: #875A7B;">${object.company_id.name}</a> @@ -412,8 +468,8 @@ % endif </td></tr> </table> + % endif </td></tr> -% endif </table> </field> <field name="lang">${object.partner_id.lang}</field> |
