diff options
Diffstat (limited to 'templates/email')
25 files changed, 227 insertions, 29 deletions
diff --git a/templates/email/bromley/confirm_report_sent.html b/templates/email/bromley/confirm_report_sent.html new file mode 100644 index 000000000..5a0c19f0d --- /dev/null +++ b/templates/email/bromley/confirm_report_sent.html @@ -0,0 +1 @@ +[% INCLUDE 'other-reported.html' %]
\ No newline at end of file diff --git a/templates/email/bromley/confirm_report_sent.txt b/templates/email/bromley/confirm_report_sent.txt new file mode 100644 index 000000000..72fe01f6d --- /dev/null +++ b/templates/email/bromley/confirm_report_sent.txt @@ -0,0 +1 @@ +[% INCLUDE 'other-reported.txt' %]
\ No newline at end of file diff --git a/templates/email/default/_email_comment_list.html b/templates/email/default/_email_comment_list.html index 346efadfb..fe6cd5c4c 100644 --- a/templates/email/default/_email_comment_list.html +++ b/templates/email/default/_email_comment_list.html @@ -5,7 +5,7 @@ <img style="[% list_item_photo_style %]" src="[% inline_image(update.get_first_image_fp) %]" alt=""> </a> [%~ END %] - [% update.item_text | html_para | replace('<p>', '<p style="' _ list_item_p_style _ '">') %] + [% email_sanitize_html(update) | html_para | replace('<p>', '<p style="' _ list_item_p_style _ '">') %] <p style="[% list_item_date_style %]"> [%~ update.item_name | html IF update.item_name AND NOT update.item_anonymous -%] [% '(' _ cobrand.prettify_dt(update.confirmed) _ ') ' IF cobrand.include_time_in_update_alerts -%] diff --git a/templates/email/default/_email_comment_list.txt b/templates/email/default/_email_comment_list.txt index dbf00640f..3e01580c3 100644 --- a/templates/email/default/_email_comment_list.txt +++ b/templates/email/default/_email_comment_list.txt @@ -1,7 +1,7 @@ [% FOR row IN data -%] [% row.item_name _ ' : ' IF row.item_name AND NOT row.item_anonymous -%] [% '(' _ cobrand.prettify_dt(row.confirmed) _ ') ' IF cobrand.include_time_in_update_alerts -%] -[% row.item_text %] +[% email_sanitize_text(row) %] ------ diff --git a/templates/email/default/submit-example.txt b/templates/email/default/submit-example.txt index 1d9db23d3..8927914d5 100644 --- a/templates/email/default/submit-example.txt +++ b/templates/email/default/submit-example.txt @@ -46,7 +46,7 @@ Replies to this email will go to the user who submitted the problem. Yours, The FixMyStreet team -This message was sent via FixMyStreet, a project of UKCOD, +This message was sent via FixMyStreet, a project of mySociety, registered charity number 1076346. If there is a more appropriate email address for messages about 'Potholes', please let us know by visiting <https://www.fixmystreet.com/contact>. This will help diff --git a/templates/email/default/submit.html b/templates/email/default/submit.html index 0fed5770f..e08a31b5a 100644 --- a/templates/email/default/submit.html +++ b/templates/email/default/submit.html @@ -49,6 +49,14 @@ of a local problem that they believe might require your attention.</p> <h2 style="[% h2_style %]">[% report.title | html %]</h2> <p style="[% secondary_p_style %]">[% report.category | html %]</p> <p style="[% secondary_p_style %]">[% report.detail | html %]</p> + [% IF report.get_extra_fields %] + <p style="[% secondary_p_style %]"> + [%~ FOR field IN report.get_extra_fields %][% IF field.value %] + [% field.description %]: [% field.value %] + [% IF NOT loop.last %]<br>[% END %] + [%~ END %][% END %] + </p> + [% END %] <p style="[% secondary_p_style %]"> <strong>Location:</strong> <a href="[% osm_url %]" title="View OpenStreetMap of this location"> diff --git a/templates/email/default/submit.txt b/templates/email/default/submit.txt index f08e723a8..b380825e4 100644 --- a/templates/email/default/submit.txt +++ b/templates/email/default/submit.txt @@ -25,6 +25,11 @@ Subject: [% report.title %] Details: [% report.detail %] +[% FOR field IN report.get_extra_fields %][% IF field.value ~%] +[% field.description %]: [% field.value %] + +[% END %][% END ~%] + Latitude: [% report.latitude %] Longitude: [% report.longitude %] diff --git a/templates/email/fixamingata/_email_comment_list.html b/templates/email/fixamingata/_email_comment_list.html index 346efadfb..fe6cd5c4c 100644 --- a/templates/email/fixamingata/_email_comment_list.html +++ b/templates/email/fixamingata/_email_comment_list.html @@ -5,7 +5,7 @@ <img style="[% list_item_photo_style %]" src="[% inline_image(update.get_first_image_fp) %]" alt=""> </a> [%~ END %] - [% update.item_text | html_para | replace('<p>', '<p style="' _ list_item_p_style _ '">') %] + [% email_sanitize_html(update) | html_para | replace('<p>', '<p style="' _ list_item_p_style _ '">') %] <p style="[% list_item_date_style %]"> [%~ update.item_name | html IF update.item_name AND NOT update.item_anonymous -%] [% '(' _ cobrand.prettify_dt(update.confirmed) _ ') ' IF cobrand.include_time_in_update_alerts -%] diff --git a/templates/email/fixmystreet.com/_submit_footer.html b/templates/email/fixmystreet.com/_submit_footer.html index 0da75a3b7..9a53c942d 100644 --- a/templates/email/fixmystreet.com/_submit_footer.html +++ b/templates/email/fixmystreet.com/_submit_footer.html @@ -2,13 +2,15 @@ <tr> <th style="[% td_style %] padding: [% column_padding %]px; background-color: [% color_yellow %]; color: [% color_black %];"> <h2 style="[% h2_style %] margin-bottom: 15px;"> - In-depth stats from our new, exclusive dashboard + FixMyStreet Pro is making savings for authorities across the UK </h2> <p style="margin: 0;"> - What do people report most in your area? - How’s your response rate? - And how do you compare to other UK councils? - <a href="https://www.fixmystreet.com/about/council-dashboard/?utm_source=council_submit_email&utm_content=[% "View FixMyStreet stats for your area" | uri %]&utm_medium=email&utm_campaign=fms_stats_dashboard_promo">View FixMyStreet stats for your area.</a> + <a href="https://www.fixmystreet.com/pro/take-a-tour/webinar-schedule/?utm_source=council_submit_email&utm_content=[% "Join one of our regular informal webinars" | uri %]&utm_medium=email&utm_campaign=fms_webinars_promo"> + Join one of our regular informal webinars + </a> to discover how FixMyStreet Pro + integrates with your existing systems, + drives channel shift, + and saves you money from day one. </p> </th> </tr> diff --git a/templates/email/fixmystreet.com/bathnes/submit-street-light-fault.html b/templates/email/fixmystreet.com/bathnes/submit-street-light-fault.html index 8af8ea1b0..61aa9af34 100644 --- a/templates/email/fixmystreet.com/bathnes/submit-street-light-fault.html +++ b/templates/email/fixmystreet.com/bathnes/submit-street-light-fault.html @@ -48,8 +48,6 @@ <td>[% url %]</td> </tr> </table> -[% additional_information %] - <h2>Location Details</h2> diff --git a/templates/email/fixmystreet.com/bathnes/submit-street-light-fault.txt b/templates/email/fixmystreet.com/bathnes/submit-street-light-fault.txt index a860c0a34..20a2aeb4f 100644 --- a/templates/email/fixmystreet.com/bathnes/submit-street-light-fault.txt +++ b/templates/email/fixmystreet.com/bathnes/submit-street-light-fault.txt @@ -24,8 +24,6 @@ Title: [% title %] Description: [% detail %] -[% additional_information %] - [% url %] Location Details diff --git a/templates/email/fixmystreet.com/submit.html b/templates/email/fixmystreet.com/submit.html index f8b2db0dc..1d40f1eb6 100644 --- a/templates/email/fixmystreet.com/submit.html +++ b/templates/email/fixmystreet.com/submit.html @@ -49,9 +49,14 @@ of a local problem that they believe might require your attention.</p> <h2 style="[% h2_style %]">[% report.title | html %]</h2> <p style="[% secondary_p_style %]"><strong>Category:</strong> [% report.category | html %]</p> <p style="[% secondary_p_style %]">[% report.detail | html %]</p> - [%~ IF additional_information %] - <p style="[% secondary_p_style %]">[% additional_information %]</p> - [%~ END %] + [% IF report.get_extra_fields %] + <p style="[% secondary_p_style %]"> + [%~ FOR field IN report.get_extra_fields %][% IF field.value %] + [% field.description %]: [% field.value %] + [% IF NOT loop.last %]<br>[% END %] + [%~ END %][% END %] + </p> + [% END %] <p style="[% secondary_p_style %]"> <strong>Location:</strong> <br>Easting/Northing diff --git a/templates/email/fixmystreet.com/submit.txt b/templates/email/fixmystreet.com/submit.txt index c22d83713..3b3c0980f 100644 --- a/templates/email/fixmystreet.com/submit.txt +++ b/templates/email/fixmystreet.com/submit.txt @@ -25,7 +25,10 @@ Subject: [% report.title %] Details: [% report.detail %] -[% additional_information %] +[% FOR field IN report.get_extra_fields %][% IF field.value ~%] +[% field.description %]: [% field.value %] + +[% END %][% END ~%] Easting/Northing [%- " (IE)" IF coordsyst == "I" -%] diff --git a/templates/email/hackney/_email_bottom.html b/templates/email/hackney/_email_bottom.html new file mode 100644 index 000000000..64936c470 --- /dev/null +++ b/templates/email/hackney/_email_bottom.html @@ -0,0 +1,28 @@ + </tr> + </table> + </th> + <th class="spacer-cell"></th> + </tr> + </table> + <table [% wrapper_table | safe %] style="[% wrapper_style %]"> + <tr> + <th class="spacer-cell"></th> + <th width="[% wrapper_max_width %]" style="[% td_style %][% hint_style %]" class="hint"> + [%~ IF email_footer %] + [% email_footer | safe %] + [%~ ELSE %] + This email was sent automatically, from an unmonitored email account. Please do not reply to it. + [%~ END %] + </th> + <th class="spacer-cell"></th> + </tr> + <tr> + <th class="spacer-cell"></th> + <th width="[% wrapper_max_width %]" style="[% td_style %][% hint_style %]"> + Powered by <a href="http://www.fixmystreet.com">FixMyStreet</a> + </th> + <th class="spacer-cell"></th> + </tr> + </table> +</body> +</html> diff --git a/templates/email/hackney/_email_color_overrides.html b/templates/email/hackney/_email_color_overrides.html new file mode 100644 index 000000000..1af818eca --- /dev/null +++ b/templates/email/hackney/_email_color_overrides.html @@ -0,0 +1,25 @@ +[% + +color_green = '#00b341' +color_black = '#000000' +color_white = '#FFFFFF' +color_hackney_pale_green = '#f2f7f0' +color_hackney_dark_green = '#00664f' + +body_background_color = color_hackney_pale_green +body_text_color = color_black + +header_background_color = color_black +header_text_color = color_white + +secondary_column_background_color = color_white + +button_background_color = color_hackney_dark_green +button_text_color = color_white + +logo_file = 'hackney-logo-white.png' +logo_width = "200" # pixel measurement, but without 'px' suffix +logo_height = "36" # pixel measurement, but without 'px' suffix +header_padding = "20px 30px" + +%] diff --git a/templates/email/hackney/_email_setting_overrides.html b/templates/email/hackney/_email_setting_overrides.html new file mode 100644 index 000000000..00eeed9cc --- /dev/null +++ b/templates/email/hackney/_email_setting_overrides.html @@ -0,0 +1,7 @@ +[% + +only_column_style = "$only_column_style border: 1px solid $column_divider_color; border-top: none;" +primary_column_style = "$primary_column_style border: 1px solid $column_divider_color; border-top: none;" +secondary_column_style = "vertical-align: top; width: 50%; background-color: $secondary_column_background_color; color: $secondary_column_text_color; border: 1px solid $column_divider_color; border-top: none; border-left: none;" + +%] diff --git a/templates/email/hackney/signature.txt b/templates/email/hackney/signature.txt new file mode 100644 index 000000000..78a02659f --- /dev/null +++ b/templates/email/hackney/signature.txt @@ -0,0 +1,2 @@ + +Hackney Council diff --git a/templates/email/hackney/site-name.txt b/templates/email/hackney/site-name.txt new file mode 100644 index 000000000..29d7f1480 --- /dev/null +++ b/templates/email/hackney/site-name.txt @@ -0,0 +1 @@ +Report A Problem diff --git a/templates/email/hounslow/submit.html b/templates/email/hounslow/submit.html index 5b9f2e255..a22f15243 100644 --- a/templates/email/hounslow/submit.html +++ b/templates/email/hounslow/submit.html @@ -52,9 +52,6 @@ of a local problem that they believe might require your attention.</p> [% END %] <p style="[% secondary_p_style %]"><strong>Category:</strong> [% report.category | html %]</p> <p style="[% secondary_p_style %]">[% report.detail | html %]</p> - [%~ IF additional_information %] - <p style="[% secondary_p_style %]">[% additional_information %]</p> - [%~ END %] <p style="[% secondary_p_style %]"> <strong>Location:</strong> <br>Easting/Northing diff --git a/templates/email/hounslow/submit.txt b/templates/email/hounslow/submit.txt index 3d9518e53..bbf23326b 100644 --- a/templates/email/hounslow/submit.txt +++ b/templates/email/hounslow/submit.txt @@ -25,8 +25,6 @@ Subject: [% report.title %] Details: [% report.detail %] -[% additional_information %] - Easting/Northing [%- " (IE)" IF coordsyst == "I" -%] : [% easting %]/[% northing %] diff --git a/templates/email/oxfordshire/submit.html b/templates/email/oxfordshire/submit.html new file mode 100644 index 000000000..428436523 --- /dev/null +++ b/templates/email/oxfordshire/submit.html @@ -0,0 +1,74 @@ +[% + +PROCESS '_email_settings.html'; + +email_summary = "A new problem in your area has been reported by a " _ site_name _ " user."; +email_footer = PROCESS '_submit_footer.html'; +email_columns = 2; + +INCLUDE '_email_top.html'; + +%] + +<th style="[% td_style %][% primary_column_style %]" id="primary_column"> + [% start_padded_box | safe %] + <h1 style="[% h1_style %]">New problem in your area</h1> + <p style="[% p_style %]">[% missing %][% multiple %]A user of [% site_name %] has submitted the following report +of a local problem that they believe might require your attention.</p> + + <p style="margin: 20px auto; text-align: center"> + <a style="[% button_style %]" href="[% url %]">Show full report</a> + </p> + <h2 style="[% h2_style %] margin: 30px 0 10px 0">Reported by:</h2> + <table [% table_reset | safe %]> + <tr> + <th style="[% contact_th_style %]">Name</th> + <td style="[% contact_td_style %]">[% report.name | html %]</td> + </tr> + <tr> + <th style="[% contact_th_style %]">Email</th> + <td style="[% contact_td_style %]"> + [%~ IF report.user.email ~%] + <a href="mailto:[% report.user.email | html %]">[% report.user.email | html %]</a> + [%~ ELSE ~%] + <strong>No email address provided, only phone number</strong> + [%~ END ~%] + </td> + </tr> + [%~ IF report.user.phone %] + <tr> + <th style="[% contact_th_style %]">Phone</th> + <td style="[% contact_td_style %]"><a href="tel:[% report.user.phone | html %]">[% report.user.phone | html %]</a></td> + </tr> + [%~ END %] + </table> + <p style="[% p_style %] margin-top: 0.5em;">Replies to this message will go directly to [% report.name | html %], the user who reported the problem.</p> + [% end_padded_box | safe %] +</th> +[% WRAPPER '_email_sidebar.html' object = report %] + <h2 style="[% h2_style %]">[% report.title | html %]</h2> + <p style="[% secondary_p_style %]"><strong>Category:</strong> [% report.category | html %]</p> + <p style="[% secondary_p_style %]">[% report.detail | html %]</p> + <p style="[% secondary_p_style %]"> + <strong>Location:</strong> + <br>Easting/Northing + [%~ " (IE)" IF coordsyst == "I" ~%] + : [% easting %]/[% northing %] + (<a href="[% osm_url %]" title="View OpenStreetMap of this location"> + [%~ report.latitude %], [% report.longitude ~%] + </a>) + [% IF closest_address %]<br>[% closest_address | trim | replace("\n\n", "<br>") %][% END %] + </p> + [% IF report.get_extra_field_value('feature_id') %] + <p style="[% secondary_p_style %]"> + <strong>Asset id:</strong> [% report.get_extra_field_value('feature_id') %] + </p> + [% END %] + [% IF report.get_extra_field_value('column_no') %] + <p style="[% secondary_p_style %]"> + <strong>Column Number:</strong> [% report.get_extra_field_value('column_no') %] + </p> + [% END %] +[% END %] + +[% INCLUDE '_email_bottom.html' %] diff --git a/templates/email/oxfordshire/submit.txt b/templates/email/oxfordshire/submit.txt new file mode 100644 index 000000000..faa39e2b4 --- /dev/null +++ b/templates/email/oxfordshire/submit.txt @@ -0,0 +1,50 @@ +Subject: Problem Report: [% report.title %] + +Dear [% bodies_name %], + +[% missing %][% multiple %]A user of +[% site_name %] has submitted the following report +of a local problem that they believe might require your attention. + +[% fuzzy %], or to provide an update on the problem, +please visit the following link: + + [% url %] + +[% has_photo %]---------- + +Name: [% report.name %] + +Email: [% report.user.email OR 'None provided' %] + +Phone: [% report.user.phone OR 'None provided' %] + +Category: [% report.category %] + +Subject: [% report.title %] + +Details: [% report.detail %] + +[%- IF report.get_extra_field_value('feature_id') %] +Asset id: [% report.get_extra_field_value('feature_id') %] +[%- END %] + +[%- IF report.get_extra_field_value('column_no') %] +Column number: [% report.get_extra_field_value('column_no') %] +[%- END %] + +Easting/Northing +[%- " (IE)" IF coordsyst == "I" -%] +: [% easting %]/[% northing %] + +Latitude: [% report.latitude %] + +Longitude: [% report.longitude %] + +View OpenStreetMap of this location: [% osm_url %] + +[% closest_address %]---------- + +Replies to this email will go to the user who submitted the problem. + +[% signature %] diff --git a/templates/email/tfl/submit.html b/templates/email/tfl/submit.html index a1bd8f134..2bce514d0 100644 --- a/templates/email/tfl/submit.html +++ b/templates/email/tfl/submit.html @@ -58,9 +58,6 @@ of a local problem that they believe might require your attention.</p> <p style="[% secondary_p_style %]"><strong>Signal site number:</strong> [% report.get_extra_field_value('site') | html %]</p> [% END %] <p style="[% secondary_p_style %]">[% report.detail | html %]</p> - [%~ IF additional_information %] - <p style="[% secondary_p_style %]">[% additional_information %]</p> - [%~ END %] <p style="[% secondary_p_style %]"> <strong>Location:</strong> <br>Easting/Northing diff --git a/templates/email/tfl/submit.txt b/templates/email/tfl/submit.txt index b6af867ff..6c1f323b0 100644 --- a/templates/email/tfl/submit.txt +++ b/templates/email/tfl/submit.txt @@ -31,8 +31,6 @@ Subject: [% report.title %] Details: [% report.detail %] -[% additional_information %] - Easting/Northing [%- " (IE)" IF coordsyst == "I" -%] : [% easting %]/[% northing %] diff --git a/templates/email/zurich/problem-confirm.txt b/templates/email/zurich/problem-confirm.txt index f7216ea9c..2a4b29986 100644 --- a/templates/email/zurich/problem-confirm.txt +++ b/templates/email/zurich/problem-confirm.txt @@ -1,8 +1,8 @@ -Subject: Züri wie neu: Meldung #[% report.id %] +Subject: Züri wie neu: Bitte bestätigen Sie Ihre Meldung #[% report.id %] Grüezi [% report.name %] -Besten Dank für Ihre Meldung auf <<Züri wie neu>>. Klicken Sie bitte auf diesen Link, um[% UNLESS email_confirmed %] Ihre E-Mail-Adresse zu bestätigen und[% END %] über den Status der Meldung informiert zu bleiben. Falls der Link nicht funktioniert, kopieren Sie ihn in Ihren Browser: +Besten Dank für Ihre Meldung auf <<Züri wie neu>>. Klicken Sie bitte auf diesen Link, um[% UNLESS email_confirmed %] Ihre Meldung zu bestätigen und[% END %] über den Status ihrer Meldung per E-Mail informiert zu bleiben. Falls der Link nicht funktioniert, kopieren Sie ihn in Ihren Browser: [% token_url %] |