diff options
Diffstat (limited to 'templates/web/base')
47 files changed, 303 insertions, 294 deletions
diff --git a/templates/web/base/admin/bodies.html b/templates/web/base/admin/bodies.html index a039f8208..4c95423c0 100644 --- a/templates/web/base/admin/bodies.html +++ b/templates/web/base/admin/bodies.html @@ -35,13 +35,13 @@ [% IF c.cobrand.moniker == 'zurich' %] [% FILTER repeat(4*body.api_key) %] [% END %] [% IF admin_type == 'super' %] - <a href="[% c.uri_for( 'body', id ) %]">[% body.name %]</a> + <a href="[% c.uri_for( 'body', id ) %]">[% body.name | html %]</a> [% ELSE %] - [% body.name %] + [% body.name | html %] [% END %] [% ELSE %] [%# not Zurich: all bodies should be links %] - <a href="[% c.uri_for( 'body', id ) %]">[% body.name %]</a> - [%- ', ' _ body.parent.name IF body.parent -%] + <a href="[% c.uri_for( 'body', id ) %]">[% body.name | html%]</a> + [%- IF body.parent %], [% body.parent.name | html %][% END -%] [% END %] </td> [% IF c.cobrand.moniker == 'zurich' %] diff --git a/templates/web/base/admin/body-form.html b/templates/web/base/admin/body-form.html index 608a77dc2..6b103a7cf 100644 --- a/templates/web/base/admin/body-form.html +++ b/templates/web/base/admin/body-form.html @@ -16,7 +16,7 @@ </div> <p> <label for="name">[% loc('Name') %]</label> - <input type="text" name="name" id="name" value="[% body.name %]" size="50"> + <input type="text" name="name" id="name" value="[% body.name | html %]" size="50"> </p> <div class="admin-hint"> @@ -72,17 +72,21 @@ [% SET body_areas = body.areas %] [% FOR area IN areas %] [% SET aid = area.id %] - <option value="[% area.id %]"[% ' selected' IF body_areas.$aid %]>[% area.name %]</option> + <option value="[% area.id %]"[% ' selected' IF body_areas.$aid %]>[% area.name | html %]</option> [% END %] </select> </p> + <p> + <label for="external_url">[% loc('External URL') %]</label> + <input type="text" name="external_url" id="external_url" value="[% body.external_url | html %]" size="50"> + </p> <div class="admin-hint"> <p>[% loc( "You can mark a body as deleted if you do not want it to be active on the site." ) %]</p> </div> <p> - <label for="deleted">[% loc('Flag as deleted') %]</label> <input type="checkbox" name="deleted" id="deleted" value="1"[% ' checked' IF body.deleted %]> + <label for="deleted" class="inline">[% loc('Flag as deleted') %]</label> </p> <div class="admin-hint"> @@ -124,7 +128,7 @@ </div> <p> <label for="endpoint">[% loc('Endpoint') %]</label> - <input type="text" name="endpoint" id="endpoint" value="[% body.endpoint %]" size="50"> + <input type="text" name="endpoint" id="endpoint" value="[% body.endpoint | html %]" size="50"> </p> <div class="admin-hint"> @@ -137,7 +141,7 @@ </div> <p> <label for="jurisdiction">Open311 Jurisdiction</label> - <input type="text" name="jurisdiction" id="jurisdiction" value="[% body.jurisdiction %]" size="50"> + <input type="text" name="jurisdiction" id="jurisdiction" value="[% body.jurisdiction | html %]" size="50"> </p> <div class="admin-hint"> @@ -150,7 +154,7 @@ </div> <p> <label for="api_key">Open311 API Key</label> - <input type="text" name="api_key" id="api_key" value="[% body.api_key %]" size="25"> + <input type="text" name="api_key" id="api_key" value="[% body.api_key | html %]" size="25"> </p> <div class="admin-hint"> @@ -180,6 +184,9 @@ <p> <label for"comment_user_id">User ID to attribute fetched comments to</label> <input type="text" name="comment_user_id" value="[% body.comment_user_id %]"> + [% IF body.comment_user_id %] + <a href="[% c.uri_for('user_edit', body.comment_user_id) %]">[% loc('edit user') %]</a> + [% END %] </p> <div class="admin-hint"> diff --git a/templates/web/base/admin/body.html b/templates/web/base/admin/body.html index cd87a5af8..84ea6840c 100644 --- a/templates/web/base/admin/body.html +++ b/templates/web/base/admin/body.html @@ -13,14 +13,22 @@ [% IF example_pc %] <a href="[% c.uri_for_email( '/around', { pc => example_pc } ) %]" class="admin-offsite-link">[% tprintf( loc('Example postcode %s'), example_pc ) | html %]</a> | [% END %] - [% IF c.cobrand.moniker == 'emptyhomes' %] - <a href="[% c.uri_for( 'reports', search => 'body:' _ body_id ) %]">[% loc('List all reported problems' ) %]</a> | - [% ELSE %] + [% loc('Area covered') %]: + [% SET body_areas = body.areas %] + [% FOR area IN areas %] + [% SET aid = area.id %] + [% IF body_areas.$aid %] + <a href="[% c.config.MAPIT_URL %][% + '/' UNLESS c.config.MAPIT_URL.search('/$') + %]area/[% aid %].html" class="admin-offsite-link">[% area.name | html %]</a> + [% END %] + [% END %] +<br> <a href="[% c.uri_for_email( '/reports/' _ body_id ) %]" class="admin-offsite-link">[% loc('List all reported problems' ) %]</a> | - [% END %] - <a href="[% c.uri_for( 'body', body_id, { text => 1 } ) %]">[% loc('Text only version') %]</a> + <a href="[% c.uri_for( 'body', body_id, { text => 1 } ) %]">[% loc('Text only version') %]</a> </p> + [% IF body.send_method == 'Open311' %] <h2> Council contacts configured via Open311 @@ -65,7 +73,7 @@ </tr> [% WHILE ( cat = contacts.next ) %] <tr [% IF cat.deleted %]class="is-deleted"[% END %]> - <td class="contact-category"><a href="[% c.uri_for( 'body', body_id, cat.category ) %]">[% cat.category %]</a> + <td class="contact-category"><a href="[% c.uri_for( 'body', body_id, cat.category ) %]">[% cat.category | html %]</a> <br>[% cat.email | html %]</td> <td> [% loc('Confirmed') %]: @@ -79,10 +87,10 @@ <br>[% loc('Devolved') %]: [%- IF body.can_be_devolved AND cat.send_method %][% loc('Yes') %][% ELSE %][% loc('No') %][% END %] </td> - <td>[% cat.editor %] + <td>[% cat.editor | html %] <br><small>[% PROCESS format_time time=cat.whenedited %]</small></td> <td>[% cat.note | html %]</td> - <td><input type="checkbox" name="confirmed" value="[% cat.category %]"></td> + <td><input type="checkbox" name="confirmed" value="[% cat.category | html %]"></td> </tr> [% END %] </table> diff --git a/templates/web/base/admin/category_edit.html b/templates/web/base/admin/category_edit.html index ef7a0a11c..b827a4b6d 100644 --- a/templates/web/base/admin/category_edit.html +++ b/templates/web/base/admin/category_edit.html @@ -23,6 +23,11 @@ <p><strong>[% loc('Category:') %] </strong>[% contact.category | html %] <input type="hidden" name="category" value="[% contact.category | html %]" > <input type="hidden" name="token" value="[% token %]" > + [% IF contact.extra %] + <p><strong>[% loc('Extra data:') %] </strong> + [% USE Dumper %] + [% Dumper.dump(contact.extra) | html %]</p> + [% END %] <p><strong>[% loc('Email:') %] </strong> <input type="text" name="email" value="[% contact.email | html %]" size="30"> @@ -48,17 +53,17 @@ <form method="post" action="[% c.uri_for('body', body_id ) %]" enctype="application/x-www-form-urlencoded" accept-charset="utf-8"> <p> <label for="endpoint">Endpoint</label> - <input type="text" name="endpoint" id="endpoint" value="[% contact.endpoint %]" size="50"> + <input type="text" name="endpoint" id="endpoint" value="[% contact.endpoint | html %]" size="50"> </p> <p> <label for="jurisdiction">Jurisdiction</label> - <input type="text" name="jurisdiction" id="jurisdiction" value="[% contact.jurisdiction %]" size="50"> + <input type="text" name="jurisdiction" id="jurisdiction" value="[% contact.jurisdiction | html %]" size="50"> </p> <p> <label for="api_key">Api Key</label> - <input type="text" name="api_key" id="api_key" value="[% contact.api_key %]" size="25"> + <input type="text" name="api_key" id="api_key" value="[% contact.api_key | html %]" size="25"> </p> <p> @@ -93,7 +98,7 @@ <td>[% PROCESS highlightchanged old=prev new=contact value='email' %]</td> <td>[% PROCESS highlightchanged_yesno old=prev new=contact value='confirmed' %]</td> <td>[% PROCESS highlightchanged_yesno old=prev new=contact value='deleted' %]</td> - <td>[% contact.editor %]</td> + <td>[% contact.editor | html %]</td> <td>[% contact.note | html %]</td> </tr> [%- prev = contact %] diff --git a/templates/web/base/admin/config_page.html b/templates/web/base/admin/config_page.html index 211d41f31..7c9b5e317 100644 --- a/templates/web/base/admin/config_page.html +++ b/templates/web/base/admin/config_page.html @@ -37,6 +37,7 @@ running version <strong>[% git_version || 'unknown' %]</strong>. [% INCLUDE subsection heading="URLs" %] [% INCLUDE with_cobrand value="BASE_URL" cob=c.cobrand.base_url %] [% INCLUDE with_cobrand value="ADMIN_BASE_URL" cob=c.cobrand.admin_base_url %] +[% INCLUDE just_value value="SECURE_PROXY_SSL_HEADER" %] [% INCLUDE subsection heading="Display" %] <tr> @@ -84,10 +85,20 @@ running version <strong>[% git_version || 'unknown' %]</strong>. cob = discob %] [% INCLUDE subsection heading="MapIt" %] -[% INCLUDE just_value value="MAPIT_URL" %] +[% INCLUDE just_value value="MAPIT_URL" + conf = "<a href='" _ c.config.MAPIT_URL _ "'>" _ c.config.MAPIT_URL _ "</a>" %] [% INCLUDE with_cobrand value="MAPIT_TYPES" cob = c.cobrand.area_types %] -[% INCLUDE just_value value="MAPIT_ID_WHITELIST" %] +<tr> + <td>MAPIT_ID_WHITELIST</td> + <td colspan=2> + [% FOR id IN c.config.MAPIT_ID_WHITELIST %] + <a href="[% c.config.MAPIT_URL %][% + '/' UNLESS c.config.MAPIT_URL.search('/$') + %]area/[% id %].html">[% id %]</a>[% ',' UNLESS loop.last %] + [% END %] + </td> +</tr> [% INCLUDE just_value value="MAPIT_GENERATION" %] [% INCLUDE with_cobrand value="MAPIT_TYPES_CHILDREN" cob = c.cobrand.area_types_children %] diff --git a/templates/web/base/admin/header.html b/templates/web/base/admin/header.html index 9f3503e20..6282bf383 100644 --- a/templates/web/base/admin/header.html +++ b/templates/web/base/admin/header.html @@ -1,4 +1,4 @@ -[% INCLUDE 'header.html' admin = 1, bodyclass = 'fullwidthpage admin show-admin-notes' %] +[% INCLUDE 'header.html' admin = 1, bodyclass = 'fullwidthpage admin' %] <style type="text/css"> dt { clear: left; float: left; font-weight: bold; } dd { margin-left: 8em; } diff --git a/templates/web/base/admin/report_edit.html b/templates/web/base/admin/report_edit.html index 12560fdf3..d488dcadc 100644 --- a/templates/web/base/admin/report_edit.html +++ b/templates/web/base/admin/report_edit.html @@ -20,14 +20,27 @@ <li><label for='detail'>[% loc('Details:') %]</label> <textarea name='detail' id='detail' cols=60 rows=10>[% problem.detail | html %]</textarea></li> -<li>[% loc('Co-ordinates:') %] [% problem.latitude %], [% problem.longitude %] +<li>[% loc('Co-ordinates:') %] +<a href="[% c.config.MAPIT_URL %][% + '/' UNLESS c.config.MAPIT_URL.search('/$') +%]point/4326/[% problem.longitude %],[% problem.latitude %].html" +class="admin-offsite-link">[% problem.latitude %], [% problem.longitude %]</a> ( [% SET postcode_safe = problem.postcode | html; tprintf( loc('originally entered: “%s”'), postcode_safe ) %], [% IF problem.used_map %][% loc('used map') %][% ELSE %][% loc("didn't use map") %][% END %])</li> -<li>[% loc('For council(s):') %] [% IF problem.bodies_str %][% problem.bodies_str %][% ELSE %]<em>[% loc('None' ) %]</em>[% END %] ([% loc('other areas:') %] [% problem.areas | remove('^,') | remove( ',$' ) %])</li> +<li>[% loc('Body:') %] + [% IF problem.bodies_str %] + [% FOREACH body IN problem.bodies.values %] + <a href="[% c.uri_for('body', body.id) %]">[% body.name | html %]</a> + [%- ',' IF NOT loop.last %] + [% END %] + [% ELSE %] + <em>[% loc('None' ) %]</em> + [% END %] + ([% loc('other areas:') %] [% problem.areas | remove('^,') | remove( ',$' ) %])</li> [% IF problem.extra.address %] <li>[% loc('Property address:') %] [% problem.extra.address | html %]</li> [% END %] @@ -68,7 +81,10 @@ <li>[% loc('Phone:') %] [% problem.user.phone | html %]</li> <li>[% loc('Created:') %] [% PROCESS format_time time=problem.created %]</li> <li>[% loc('Confirmed:') %] [% PROCESS format_time time=problem.confirmed no_time='-' %]</li> -<li>[% loc('Sent:') %] [% PROCESS format_time time=problem.whensent %] [% IF problem.state == 'confirmed' %]<input onclick="return confirm('[% loc('You really want to resend?') %]')" type="submit" name="resend" value="[% loc('Resend report') %]">[% END %]</li> +<li>[% loc('Sent:') %] [% PROCESS format_time time=problem.whensent %] +[% IF problem.state == 'confirmed' AND problem.whensent %]<input onclick="return confirm('[% loc('You really want to resend?') %]')" type="submit" name="resend" value="[% loc('Resend report') %]">[% END %] +[% IF NOT problem.whensent %]<input type="submit" name="mark_sent" value="[% loc('Mark as sent') %]">[% END %] +</li> <li>[% loc('Last update:') %] [% PROCESS format_time time=problem.lastupdate %]</li> <li>[% loc('Service:') %] [% problem.service %]</li> <li>[% loc('Cobrand:') %] [% problem.cobrand %]</li> diff --git a/templates/web/base/admin/user-form.html b/templates/web/base/admin/user-form.html index 4a57b05a0..3956e8533 100644 --- a/templates/web/base/admin/user-form.html +++ b/templates/web/base/admin/user-form.html @@ -34,8 +34,9 @@ [% FOR body IN bodies %] <option value="[% body.id %]"[% ' selected' IF body.id == user.from_body.id %]>[% body.name %]</option> [% END %] - </li> </select> + [% IF user.from_body AND user.has_permission_to('moderate', user.from_body.id) %]*[% END %] + </li> [% IF c.cobrand.moniker != 'zurich' %] <li> <div class="admin-hint"> diff --git a/templates/web/base/admin/users.html b/templates/web/base/admin/users.html index db97c7d59..19a3de03c 100644 --- a/templates/web/base/admin/users.html +++ b/templates/web/base/admin/users.html @@ -24,7 +24,9 @@ <tr> <td>[% PROCESS value_or_nbsp value=user.name %]</td> <td><a href="[% c.uri_for( 'reports', search => user.email ) %]">[% PROCESS value_or_nbsp value=user.email %]</a></td> - <td>[% PROCESS value_or_nbsp value=user.from_body.name %]</td> + <td>[% PROCESS value_or_nbsp value=user.from_body.name %] + [% IF user.from_body AND user.has_permission_to('moderate', user.from_body.id) %] * [% END %] + </td> [% IF c.cobrand.moniker != 'zurich' %] <td>[% user.flagged == 2 ? loc('(Email in abuse table)') : user.flagged ? loc('Yes') : ' ' %]</td> [% END %] diff --git a/templates/web/base/alert/index.html b/templates/web/base/alert/index.html index e3dead34a..314008846 100644 --- a/templates/web/base/alert/index.html +++ b/templates/web/base/alert/index.html @@ -1,4 +1,4 @@ -[% INCLUDE 'header.html', title = loc('Local RSS feeds and email alerts'), bodyclass = 'twothirdswidthpage alertindex' %] +[% INCLUDE 'header.html', title = loc('Local RSS feeds and email alerts'), bodyclass = 'twothirdswidthpage' %] <h1>[% loc('Local RSS feeds and email alerts') %]</h1> @@ -37,7 +37,7 @@ To find out what local alerts we have for you, please enter your [% c.cobrand.co </form> [% IF photos.size %] -<div class="sticky-sidebar" id="alert_recent"> +<div id="alert_recent"> <aside> <h2>[% loc('Some photos of recent reports') %]</h2> [% FOREACH p IN photos; diff --git a/templates/web/base/alert/list.html b/templates/web/base/alert/list.html index 447bfcd76..7b262f9e7 100644 --- a/templates/web/base/alert/list.html +++ b/templates/web/base/alert/list.html @@ -21,7 +21,7 @@ <form id="alerts" name="alerts" method="post" action="/alert/subscribe"> [% IF photos.size %] - <div id="alert_photos" class="sticky-sidebar"> + <div id="alert_photos"> <aside> <h2>[% loc('Photos of recent nearby reports') %]</h2> [% FOREACH p IN photos; diff --git a/templates/web/base/around/display_location.html b/templates/web/base/around/display_location.html index 804be9603..3f4ec8881 100755 --- a/templates/web/base/around/display_location.html +++ b/templates/web/base/around/display_location.html @@ -6,14 +6,14 @@ rss_url = pc ? c.uri_for( "/rss/pc", pc ) - : c.uri_for( "/rss/l/$short_latitude,$short_longitude" ); + : c.uri_for( "/rss/l/$latitude,$longitude" ); email_url = c.uri_for( '/alert/list', { - lat => short_latitude, - lon => short_longitude, - feed => "local:$short_latitude:$short_longitude", + lat => latitude, + lon => longitude, + feed => "local:$latitude:$longitude", } ); @@ -21,8 +21,8 @@ '/report/new', { pc => pc - latitude => short_latitude, - longitude => short_longitude, + latitude => latitude, + longitude => longitude, skipped => 1, } ); @@ -45,8 +45,8 @@ [% END %] <input type="hidden" name="pc" value="[% pc | html %]"> - <input type="hidden" name="latitude" id="fixmystreet.latitude" value="[% short_latitude | html %]"> - <input type="hidden" name="longitude" id="fixmystreet.longitude" value="[% short_longitude | html %]"> + <input type="hidden" name="latitude" id="fixmystreet.latitude" value="[% latitude | html %]"> + <input type="hidden" name="longitude" id="fixmystreet.longitude" value="[% longitude | html %]"> [% END %] [% map_html %] diff --git a/templates/web/base/auth/sign_out.html b/templates/web/base/auth/sign_out.html index 571e13f9f..c95efacf5 100644 --- a/templates/web/base/auth/sign_out.html +++ b/templates/web/base/auth/sign_out.html @@ -1,7 +1,10 @@ [% INCLUDE 'header.html', title = loc('Sign out'), bodyclass = 'fullwidthpage' %] -<h1>[% loc('You have been signed out') %]</h1> +<div class="confirmation-header"> + <h1>[% loc('You have been signed out') %]</h1> + <p>[% tprintf( loc('Please feel free to <a href="%s">sign in again</a>, or go back to the <a href="/">front page</a>.'), c.uri_for('/auth') ) %]</p> +</div> -<p>[% tprintf( loc('Please feel free to <a href="%s">sign in again</a>, or go back to the <a href="/">front page</a>.'), c.uri_for('/auth') ) %]</p> +[% INCLUDE next_steps.html %] [% INCLUDE 'footer.html' %] diff --git a/templates/web/base/contact/submit.html b/templates/web/base/contact/submit.html index fc416c2d7..5adb87e2d 100644 --- a/templates/web/base/contact/submit.html +++ b/templates/web/base/contact/submit.html @@ -1,20 +1,21 @@ -[% INCLUDE 'header.html', title = loc('Contact Us'), bodyclass = 'fullwidthpage' %] +[% INCLUDE 'header.html', bodyclass = 'fullwidthpage', title = loc('Contact Us') %] -<h1>[% loc('Contact the team') %]</h1> - [% IF success %] - <p> - [% loc("Thanks for your feedback. We'll get back to you as soon as we can!") %] - </p> - [% display_crosssell_advert( em, form_name, 'emailunvalidated', 1 ) %] + <div class="confirmation-header"> + <h1>[% loc('Thank you for your feedback') %]</h1> + <p>[% loc('We’ll get back to you as soon as we can.') %]</p> + </div> [% ELSE %] - <p> - [% tprintf( loc('Failed to send message. Please try again, or <a href="mailto:%s">email us</a>.'), contact_email ) %] - </p> + <div class="confirmation-header confirmation-header--failure"> + <h1>[% loc('Failed to send message') %]</h1> + <p>[% loc('Try emailing us directly:') %] <a href="mailto:[% contact_email %]">[% contact_email %]</a></p> + </div> [% END %] +[% INCLUDE next_steps.html %] + [% INCLUDE 'footer.html' %] diff --git a/templates/web/base/index-steps.html b/templates/web/base/index-steps.html index fac84faba..431791c20 100644 --- a/templates/web/base/index-steps.html +++ b/templates/web/base/index-steps.html @@ -21,15 +21,8 @@ <li>Or visit the Barangay Center in person</li> <li>Staff? <a href="/auth">Sign in</a> and click on the map! [% ELSE %] - [% IF c.cobrand.moniker == 'makemyisland' %] - <li> - Locate the problem on the - <a href="/around?pc=Fonadhoo">map of the island</a> - </li> - [% ELSE %] - <li>[% question %]</li> - <li>[% loc('Locate the problem on a map of the area') %]</li> - [% END %] + <li>[% question %]</li> + <li>[% loc('Locate the problem on a map of the area') %]</li> <li>[% loc('Enter details of the problem') %]</li> [% IF c.cobrand.is_council %] <li>Confirm the report and [% c.cobrand.council_name %] will investigate</li> diff --git a/templates/web/base/maps/bing.html b/templates/web/base/maps/bing.html new file mode 100644 index 000000000..1747f1bbe --- /dev/null +++ b/templates/web/base/maps/bing.html @@ -0,0 +1,12 @@ +[% map_js = BLOCK %] +<!-- <script type="text/javascript" src="http://ecn.dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=7.0&mkt=en-GB"></script> --> +<script type="text/javascript" src="[% version('/js/OpenLayers.fixmystreet.js') %]"></script> +<script type="text/javascript" src="[% version('/js/map-OpenLayers.js') %]"></script> +<script type="text/javascript" src="[% version('/js/map-bing-ol.js') %]"></script> +<script type="text/javascript" src="[% version('/js/jquery.ba-hashchange.min.js') %]"></script> +<!--[if lte IE 6]> + <link rel="stylesheet" href="/js/OpenLayers-2.13.1/theme/default/ie6-style.css" type="text/css"> +<![endif]--> +[% END %] + +[% map_html = INCLUDE maps/openlayers.html %] diff --git a/templates/web/base/maps/fms.html b/templates/web/base/maps/fms.html index 1cdfc0b35..31e050ba1 100644 --- a/templates/web/base/maps/fms.html +++ b/templates/web/base/maps/fms.html @@ -3,13 +3,11 @@ <script type="text/javascript" src="[% version('/js/OpenLayers.fixmystreet.js') %]"></script> <script type="text/javascript" src="[% version('/js/map-OpenLayers.js') %]"></script> <script type="text/javascript" src="[% version('/js/map-bing-ol.js') %]"></script> +<script type="text/javascript" src="[% version('/js/map-fms.js') %]"></script> <script type="text/javascript" src="[% version('/js/jquery.ba-hashchange.min.js') %]"></script> <!--[if lte IE 6]> <link rel="stylesheet" href="/js/OpenLayers-2.13.1/theme/default/ie6-style.css" type="text/css"> <![endif]--> [% END %] -[% map_html = BLOCK %] -[% INCLUDE maps/openlayers.html %] -[% END %] - +[% map_html = INCLUDE maps/openlayers.html include_key = 1 %] diff --git a/templates/web/base/maps/google-ol.html b/templates/web/base/maps/google-ol.html index 919ae073f..ce22fc94c 100644 --- a/templates/web/base/maps/google-ol.html +++ b/templates/web/base/maps/google-ol.html @@ -10,7 +10,7 @@ [% END %] [% map_sub_links = BLOCK %] -<a class="hidden-nojs" id="map_layer_toggle" href="">[% loc('Satellite') %]</a> +<a class="hidden-nojs" id="map_layer_toggle" href="">[% loc('Map') %]</a> [% END %] [% map_html = BLOCK %] diff --git a/templates/web/base/maps/mapquest-attribution.html b/templates/web/base/maps/mapquest-attribution.html index 60aa1b000..804710ad1 100644 --- a/templates/web/base/maps/mapquest-attribution.html +++ b/templates/web/base/maps/mapquest-attribution.html @@ -10,5 +10,4 @@ [% map_html = BLOCK %] [% INCLUDE maps/openlayers.html %] -<div class="olControlAttribution" style="position: absolute;">Data, imagery and map information provided by <a href="http://www.mapquest.com/">MapQuest</a> <img src="http://developer.mapquest.com/content/osm/mq_logo.png" />, <a href="http://openstreetmap.org/">Open Street Map</a> and contributors, <a href="http://opendatacommons.org/licenses/odbl/">ODbL</a></div> [% END %] diff --git a/templates/web/base/maps/openlayers.html b/templates/web/base/maps/openlayers.html index d01e98138..27c71f42f 100644 --- a/templates/web/base/maps/openlayers.html +++ b/templates/web/base/maps/openlayers.html @@ -22,6 +22,9 @@ var fixmystreet = { 'numZoomLevels': [% map.numZoomLevels %], 'zoomOffset': [% map.zoomOffset %], 'map_type': [% map.map_type %], +[% IF include_key -%] + 'key': '[% c.config.BING_MAPS_API_KEY %]', +[%- END %] 'pins': [% INCLUDE maps/pins_js.html %] } </script> @@ -49,7 +52,7 @@ var fixmystreet = { [% INCLUDE compass %] </noscript></div> [% IF map.copyright %] - <p id="copyright">[% map.copyright %]</p> + <div class="olControlAttribution" style="position: absolute;">[% map.copyright %]</div> [% END %] diff --git a/templates/web/base/maps/osm-toner-lite.html b/templates/web/base/maps/osm-toner-lite.html new file mode 100644 index 000000000..64fa91937 --- /dev/null +++ b/templates/web/base/maps/osm-toner-lite.html @@ -0,0 +1,14 @@ +[% map_js = BLOCK %] +<script type="text/javascript" src="[% version('/js/OpenLayers.fixmystreet.js') %]"></script> +<script type="text/javascript" src="https://stamen-maps.a.ssl.fastly.net/js/tile.stamen.js?v1.3.0"></script> +<script type="text/javascript" src="[% version('/js/map-OpenLayers.js') %]"></script> +<script type="text/javascript" src="[% version('/js/map-toner-lite.js') %]"></script> +<script type="text/javascript" src="[% version('/js/jquery.ba-hashchange.min.js') %]"></script> +<!--[if lte IE 6]> + <link rel="stylesheet" href="/js/OpenLayers-2.13.1/theme/default/ie6-style.css" type="text/css"> +<![endif]--> +[% END %] + +[% map_html = BLOCK %] +[% INCLUDE maps/openlayers.html %] +[% END %] diff --git a/templates/web/base/maps/osm.html b/templates/web/base/maps/osm.html index 3e1e1aec8..0b2db1a53 100644 --- a/templates/web/base/maps/osm.html +++ b/templates/web/base/maps/osm.html @@ -10,5 +10,4 @@ [% map_html = BLOCK %] [% INCLUDE maps/openlayers.html %] -<div class="olControlAttribution" style="position: absolute;">© <a href="http://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors</div> [% END %] diff --git a/templates/web/base/next_steps.html b/templates/web/base/next_steps.html new file mode 100644 index 000000000..9d5b22c80 --- /dev/null +++ b/templates/web/base/next_steps.html @@ -0,0 +1,5 @@ +[%# +Override this file in your cobrand to show promotions or suggested next steps +to your users after they perform major interactions like confirming or updating +problem reports, setting up local area alerts, or signing out. +%] diff --git a/templates/web/base/open311/index.html b/templates/web/base/open311/index.html index df36bcfc9..502b1a69a 100644 --- a/templates/web/base/open311/index.html +++ b/templates/web/base/open311/index.html @@ -95,7 +95,7 @@ for council problem-reporting systems.</p> <ul> -[% jurisdiction_id = 'fiksgatami.no' %] +[% jurisdiction_id = c.cobrand.jurisdiction_id_example %] [% examples = [ { url = c.cobrand.base_url _ "/open311/v2/discovery.xml?jurisdiction_id=$jurisdiction_id", diff --git a/templates/web/base/questionnaire/completed-open.html b/templates/web/base/questionnaire/completed-open.html index c860b7341..0be40ac86 100644 --- a/templates/web/base/questionnaire/completed-open.html +++ b/templates/web/base/questionnaire/completed-open.html @@ -1,11 +1,3 @@ -[% IF c.cobrand.is_council %] -<p style="font-size: 150%"> -Thank you very much for filling in our questionnaire. -</p> -[% ELSE %] -[% loc('<p style="font-size:150%">We’re sorry to hear that. We have two -suggestions: why not try writing to your local representatives or, if -it’s a problem that could be fixed by local people working together, why -not <a href="http://www.pledgebank.com/new">make and publicise a pledge</a>? -</p>') %] +[% IF ! c.cobrand.is_council %] + <p>[% loc('We’re sorry to hear the problem’s not fixed. Why not try writing to your local representatives?') %]</p> [% END %] diff --git a/templates/web/base/questionnaire/completed.html b/templates/web/base/questionnaire/completed.html index 4d848a63c..32aa8bd68 100644 --- a/templates/web/base/questionnaire/completed.html +++ b/templates/web/base/questionnaire/completed.html @@ -1,28 +1,21 @@ -[% - INCLUDE 'header.html', title = loc('Questionnaire') -%] +[% INCLUDE 'header.html', bodyclass = 'fullwidthpage', title = loc('Questionnaire') %] -[% advert_outcome = 1 %] +<div class="confirmation-header"> -[% IF been_fixed == 'Unknown' %] + <h1>[% loc('Thank you for your feedback') %]</h1> -[% loc('<p>Thank you very much for filling in our questionnaire; if you -get some more information about the status of your problem, please come back to the -site and leave an update.</p>') %] + [% IF been_fixed == 'Unknown' %] + <p>[% loc('If you get some more information about the status of your problem, please come back to the site and leave an update.') %]</p> -[% ELSIF new_state == 'confirmed' OR (!new_state AND problem.is_open) OR (!new_state AND problem.is_closed) %] + [% ELSIF new_state == 'confirmed' OR (!new_state AND problem.is_open) OR (!new_state AND problem.is_closed) %] + [% INCLUDE 'questionnaire/completed-open.html' %] -[% INCLUDE 'questionnaire/completed-open.html' %] -[% advert_outcome = 0 %] + [% ELSIF been_fixed == 'Yes' %] + <p>[% loc('Glad to hear it’s been fixed!') %]</p> -[% ELSIF been_fixed == 'Yes' %] + [% END %] -[% loc('<p style="font-size:150%">Thank you very much for filling in our questionnaire; glad to hear it’s been fixed.</p>') %] - -[% END %] - -[% IF advert_outcome %] - [% display_crosssell_advert( problem.user.email, problem.name, 'council', problem.bodies_str ) %] -[% END %] +</div> +[% INCLUDE next_steps.html %] [% INCLUDE 'footer.html' %] diff --git a/templates/web/base/report/_council_sent_info.html b/templates/web/base/report/_council_sent_info.html index 958562dc2..4496611e0 100644 --- a/templates/web/base/report/_council_sent_info.html +++ b/templates/web/base/report/_council_sent_info.html @@ -1,5 +1,5 @@ [% IF problem.whensent || problem.can_display_external_id %] - <small class="council_sent_info"><br> + <p class="council_sent_info"> [% problem.processed_summary_string(c) %] - </small> + </p> [% END %] diff --git a/templates/web/base/report/_main.html b/templates/web/base/report/_main.html index 00b0188af..a7aafb6d0 100644 --- a/templates/web/base/report/_main.html +++ b/templates/web/base/report/_main.html @@ -52,18 +52,19 @@ </div> [% END %] - <p><em> - [% problem.meta_line(c) | html %] - [%- IF !problem.used_map AND c.cobrand.moniker != 'emptyhomes' %]; <strong>[% loc('there is no pin shown as the user did not use the map') %]</strong>[% END %] + <p class="report_meta_info"> + [% problem.meta_line(c) | html %] + [%- IF !problem.used_map AND c.cobrand.moniker != 'emptyhomes' %]; <strong>([% loc('there is no pin shown as the user did not use the map') %])</strong>[% END %] + </p> [% IF problem.bodies_str %] [% INCLUDE 'report/_council_sent_info.html' %] [% ELSE %] - <br><small>[% loc('Not reported to council') %]</small> + <p class="council_sent_info">[% loc('Not reported to council') %]</p> [% END %] [% mlog = problem.latest_moderation_log_entry(); IF mlog %] - <br /> Moderated by [% mlog.user.from_body.name %] at [% prettify_dt(mlog.whenedited) %] + <p>Moderated by [% mlog.user.from_body.name %] at [% prettify_dt(mlog.whenedited) %]</p> [% END %] - </em></p> + [% INCLUDE 'report/_support.html' %] [% INCLUDE 'report/photo.html' object=problem %] diff --git a/templates/web/base/report/display.html b/templates/web/base/report/display.html index a7181942f..0731d9f0e 100644 --- a/templates/web/base/report/display.html +++ b/templates/web/base/report/display.html @@ -31,7 +31,7 @@ [% IF c.cobrand.moniker != 'emptyhomes' %] <p style="padding-bottom: 0.5em; border-bottom: dotted 1px #999999;" align="right"> - <a href="[% c.uri_for( '/around', { lat => short_latitude, lon => short_longitude } ) %]">[% loc( 'More problems nearby' ) %]</a> + <a href="[% c.uri_for( '/around', { lat => latitude, lon => longitude } ) %]">[% loc( 'More problems nearby' ) %]</a> </p> <div id="alert_links"> diff --git a/templates/web/base/report/new/category.html b/templates/web/base/report/new/category.html index ee47adc9e..f640c548c 100644 --- a/templates/web/base/report/new/category.html +++ b/templates/web/base/report/new/category.html @@ -9,7 +9,7 @@ [%- ELSE %] [%- loc('Category') %] [%- END -%]</label> - <select name='category' id='form_category'[% ' onchange="form_category_onchange()"' IF category_extras.size %]> + <select name='category' id='form_category'> [% FOREACH cat_op IN category_options %] [% cat_op_lc = cat_op | lower %] <option value='[% cat_op | html %]'[% ' selected' IF report.category == cat_op || category == cat_op_lc || (category_options.size == 2 AND loop.last) -%] diff --git a/templates/web/base/report/new/category_extras.html b/templates/web/base/report/new/category_extras.html index 6b15cbef9..c0f6a7bae 100644 --- a/templates/web/base/report/new/category_extras.html +++ b/templates/web/base/report/new/category_extras.html @@ -1,28 +1,30 @@ <div id="category_meta"> + [%- category = report.category -%] + + [%- IF unresponsive.$category %] + [% INCLUDE "report/new/unresponsive_body.html" body_id = unresponsive.$category %] + [%- END %] + [%- IF report_meta %] - [%- category = report.category %] <h4>Additional Information</h4> [%- FOR meta IN category_extras.$category %] [%- meta_name = meta.code -%] -[% IF field_errors.$meta_name %] - <div class='form-error'>[% field_errors.$meta_name %]</div> -[% END -%] - - <div class="form-field"> - <label for="form_[% meta_name %]">[% meta.description _ ':' %]</label> - [% IF meta.variable != 'false' %] - [% IF meta.exists('values') - <select name="[% meta_name %]" id="form_[% meta_name %]"[% meta.required == 'true' ? ' required' : '' %]> - [% FOR option IN meta.values.value.value %] - <option value="[% option.key.0 %]"[% IF option.key.0 == report_meta.$meta_name.value %] selected[% END %]>[% option.name.0 %]</option> + <label for="form_[% meta_name %]">[% meta.description _ ':' %]</label> + [% IF field_errors.$meta_name %] + <p class='form-error'>[% field_errors.$meta_name %]</p> + [% END -%] + [% IF meta.variable != 'false' %] + [% IF meta.exists('values') %] + <select name="[% meta_name %]" id="form_[% meta_name %]"[% meta.required == 'true' ? ' required' : '' %]> + [% FOR option IN meta.values.value %] + <option value="[% option.key.0 %]"[% IF option.key.0 == report_meta.$meta_name.value %] selected[% END %]>[% option.name.0 %]</option> + [% END %] + </select> + [% ELSE %] + <input type="text" value="[% report_meta.$meta_name.value | html %]" name="[% meta_name %]" id="form_[% meta_name %]"[% meta.required == 'true' ? ' required' : '' %]> [% END %] - </select> - [% ELSE %] - <input type="text" value="[% report_meta.$meta_name | html %]" name="[% meta_name %]" id="form_[% meta_name %]"[% meta.required == 'true' ? ' required' : '' %]> [% END %] - [% END %] - </div> [%- END %] [%- END %] </div> diff --git a/templates/web/base/report/new/category_wrapper.html b/templates/web/base/report/new/category_wrapper.html new file mode 100644 index 000000000..f6bb618f0 --- /dev/null +++ b/templates/web/base/report/new/category_wrapper.html @@ -0,0 +1,17 @@ +[% IF js %] + <div id="form_category_row"> + <label for="form_category">[% loc('Category') %]</label> + <select name="category" id="form_category" required><option>[% loc('Loading...') %]</option></select> + </div> +[% ELSE %] + [% IF category_options.size %] + [% IF field_errors.category %] + <p class='form-error'>[% field_errors.category %]</p> + [% END %] + [% PROCESS "report/new/category.html" %] + [% END %] +[% END %] + +[%- IF category_extras %] + [% PROCESS "report/new/category_extras.html" %] +[%- END %] diff --git a/templates/web/base/report/new/councils_text.html b/templates/web/base/report/new/councils_text.html index f526beb28..65e41f0d1 100644 --- a/templates/web/base/report/new/councils_text.html +++ b/templates/web/base/report/new/councils_text.html @@ -1,5 +1,7 @@ [% FILTER collapse %] -[% IF bodies_to_list.size == 0 %] +[% IF unresponsive.ALL %] + [% PROCESS 'report/new/unresponsive_body.html' body_id = unresponsive.ALL %] +[% ELSIF bodies_to_list.size == 0 %] [% PROCESS 'report/new/councils_text_none.html' %] [% ELSIF bodies_to_list.size == bodies.size %] [% PROCESS 'report/new/councils_text_all.html' %] diff --git a/templates/web/base/report/new/councils_text_all.html b/templates/web/base/report/new/councils_text_all.html index e9a008e90..9947625a5 100644 --- a/templates/web/base/report/new/councils_text_all.html +++ b/templates/web/base/report/new/councils_text_all.html @@ -1,27 +1,10 @@ -[%# XXX The below type checking is assuming that a body ID can be used to look up a mapit type. %] <p> -[% IF bodies_to_list.0 != 2489 && bodies_to_list.0 != 2482 && all_areas.${bodies_to_list.0}.type == 'LBO' %] -[% - tprintf( - loc('All the information you provide here will be sent to <strong>%s</strong> or a relevant local body such as <strong>TfL</strong>, via the London Report-It system.'), - all_body_names.join( '</strong>' _ loc(' or ') _ '<strong>' ) - ); -%] -[% ELSIF all_areas.${bodies_to_list.0}.type == 'LGD' %] -[% - tprintf( - loc('All the information you provide here will be sent to <strong>%s</strong> or <strong>Roads Service</strong>.'), - all_body_names.join( '</strong>' _ loc(' or ') _ '<strong>' ) - ); -%] -[% ELSE %] [% tprintf( loc('All the information you provide here will be sent to <strong>%s</strong>.'), all_body_names.join( '</strong>' _ loc(' or ') _ '<strong>' ) ); %] -[% END %] [% INCLUDE 'report/new/councils_extra_text.html' %] </p> diff --git a/templates/web/base/report/new/councils_text_none.html b/templates/web/base/report/new/councils_text_none.html index 9293c03a7..684879590 100644 --- a/templates/web/base/report/new/councils_text_none.html +++ b/templates/web/base/report/new/councils_text_none.html @@ -1,28 +1,16 @@ -<p>[% +<p> +[% nget( "We do not yet have details for the council that covers this location.", "We do not yet have details for the councils that cover this location.", missing_details_bodies.size || all_areas.size ); -%] -[% loc("If you submit a problem here the subject and details of the problem will be public, but the problem will <strong>not</strong> be reported to the council."); -%] -[% IF c.cobrand.moniker == 'fixamingata' AND all_body_names.size == 1 %] -[% - tprintf( - "Du kan istället kontakta %s via <a href='%s'>deras webbsida</a>.", - all_body_names.first, all_body_urls.first); -%] -[% ELSE %] -[% tprintf( loc("You can help us by finding a contact email address for local problems for %s and emailing it to us at <a href='mailto:%s'>%s</a>."), missing_details_body_names.join( loc(' or ') ) || all_area_names.join( loc(' or ') ), c.cobrand.contact_email, c.cobrand.contact_email ); - %] -[% END %] </p> diff --git a/templates/web/base/report/new/fill_in_details.html b/templates/web/base/report/new/fill_in_details.html index 1b8a866fc..9d3f52041 100644 --- a/templates/web/base/report/new/fill_in_details.html +++ b/templates/web/base/report/new/fill_in_details.html @@ -22,8 +22,8 @@ [% END %] - <input type="hidden" name="latitude" id="fixmystreet.latitude" value="[% short_latitude | html %]"> - <input type="hidden" name="longitude" id="fixmystreet.longitude" value="[% short_longitude | html %]"> + <input type="hidden" name="latitude" id="fixmystreet.latitude" value="[% latitude | html %]"> + <input type="hidden" name="longitude" id="fixmystreet.longitude" value="[% longitude | html %]"> [% IF report.used_map %] [% map_html %] diff --git a/templates/web/base/report/new/fill_in_details_form.html b/templates/web/base/report/new/fill_in_details_form.html index cee0244c7..d1431ffd3 100644 --- a/templates/web/base/report/new/fill_in_details_form.html +++ b/templates/web/base/report/new/fill_in_details_form.html @@ -63,26 +63,7 @@ <textarea name="detail" id="form_detail" rows="7" cols="26" required>[% report.detail | html %]</textarea> </div> -[% IF js %] - <div class="form-field" id="form_category_row"> - <label for="form_category">[% loc('Category:') %]</label> - <select name="category" id="form_category" required><option>[% loc('Loading...') %]</option></select> - </div> -[% ELSE %] - [% IF category_options.size %] - [% IF field_errors.category %] - <div class='form-error'>[% field_errors.category %]</div> - [% END %] - - <div class="form-field"> - [% PROCESS "report/new/category.html" %] - </div> - [% END %] -[% END %] - -[%- IF category_extras %] -[% PROCESS "report/new/category_extras.html" %] -[%- END %] +[% PROCESS "report/new/category_wrapper.html" %] [% IF c.cobrand.allow_photo_upload %] [% IF field_errors.photo %] diff --git a/templates/web/base/report/update-form.html b/templates/web/base/report/update-form.html index 50bc2906c..4e762a9a5 100644 --- a/templates/web/base/report/update-form.html +++ b/templates/web/base/report/update-form.html @@ -37,7 +37,7 @@ </select> </div> [% ELSE %] - [% IF problem.is_fixed AND c.user_exists AND c.user.id == problem.user_id %] + [% IF problem.is_fixed AND ((c.user_exists AND c.user.id == problem.user_id) OR alert_to_reporter) %] <div class="checkbox"> <input type="checkbox" name="reopen" id="form_reopen" value="1"[% ' checked' IF update.mark_open %]> <label class="inline" for="form_reopen">[% loc('This problem has not been fixed') %]</label> diff --git a/templates/web/base/report/update.html b/templates/web/base/report/update.html index 048968eae..a5fd97870 100644 --- a/templates/web/base/report/update.html +++ b/templates/web/base/report/update.html @@ -6,17 +6,19 @@ [% INCLUDE meta_line %] </em></p></div> [% IF NOT update.whenanswered %] + + [% INCLUDE 'report/photo.html' object=update %] + <div class="update-text"> [% add_links( update.text ) | html_para %] - [% INCLUDE 'report/photo.html' object=update %] - [% IF c.cobrand.allow_update_reporting %] <p align="right"> <small><a rel="nofollow" class="unsuitable-problem" href="[% c.uri_for( '/contact', { id => update.problem_id, update_id => update.id } ) %]">[% loc('Offensive? Unsuitable? Tell us') %]</a></small> </p> [% END %] </div> + [% END %] </div> [% '</div>' IF loop.last %] diff --git a/templates/web/base/report_created.html b/templates/web/base/report_created.html deleted file mode 100644 index 81083654b..000000000 --- a/templates/web/base/report_created.html +++ /dev/null @@ -1,9 +0,0 @@ -[% INCLUDE 'header.html', title => loc('Report created') %] - -<h1>[% loc("Report created") %]</h1> - -<p> -[% loc('Your report has been created and will shortly be sent.') %] -</p> - -[% INCLUDE 'footer.html' %] diff --git a/templates/web/base/reports/_list-filters.html b/templates/web/base/reports/_list-filters.html new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/templates/web/base/reports/_list-filters.html diff --git a/templates/web/base/reports/_problem-list.html b/templates/web/base/reports/_problem-list.html new file mode 100644 index 000000000..45746e309 --- /dev/null +++ b/templates/web/base/reports/_problem-list.html @@ -0,0 +1,19 @@ +<section class="full-width"> + [% INCLUDE column + problems = problems.${body.id} + %] +</section> + +[% BLOCK column %] + <ul class="issue-list-a"> + [% IF problems %] + [% FOREACH problem IN problems %] + [% INCLUDE 'reports/_list-entry.html' %] + [% END %] + [% ELSE %] + <li class="empty"> + <p>[% loc('There are no reports to show.') %]</p> + </li> + [% END %] + </ul> +[% END %] diff --git a/templates/web/base/reports/body.html b/templates/web/base/reports/body.html index e1d1b359e..b98c5bec6 100755 --- a/templates/web/base/reports/body.html +++ b/templates/web/base/reports/body.html @@ -43,32 +43,8 @@ [% INCLUDE '_hart_hants_note.html' %] [% END %] -[% IF NOT body.areas.size AND c.cobrand.country == 'GB' %] - <p id="unknown" class="alert">This council no longer exists. - [% IF body.name.match('Penwith|Kerrier|Carrick|Restormel|Caradon|North Cornwall') %] - Its area is now covered by <a href="/reports/Cornwall">Cornwall Council</a>. - [% ELSIF body.name.match('Durham|Easington|Sedgefield|Teesdale|Wear Valley|Derwentside|Chester le Street') %] - Its area is now covered by <a href="/reports/Durham+County">Durham County Council</a>. - [% ELSIF body.name.match('Blyth Valley|Wansbeck|Castle Morpeth|Tynedale|Alnwick|Berwick upon Tweed') %] - Its area is now covered by <a href="/reports/Northumberland">Northumberland County Council</a>. - [% ELSIF body.name.match('North Shropshire|Oswestry|Shrewsbury and Atcham|South Shropshire|Bridgnorth') %] - Its area is now covered by <a href="/reports/Shropshire">Shropshire Council</a>. - [% ELSIF body.name.match('Salisbury|West Wiltshire|Kennet|North Wiltshire') %] - Its area is now covered by <a href="/reports/Wiltshire">Wiltshire Council</a>. - [% ELSIF body.name.match('Ellesmere Port and Neston|Vale Royal|Chester') %] - Its area is now covered by <a href="/reports/Cheshire+West+and+Chester">Cheshire West and Chester Council</a>. - [% ELSIF body.name.match('Macclesfield|Congleton|Crewe and Nantwich') %] - Its area is now covered by <a href="/reports/Cheshire+East">Cheshire East Council</a>. - [% ELSIF body.name.match('Mid Bedfordshire|South Bedfordshire') %] - Its area is now covered by <a href="/reports/Central+Bedfordshire">Central Bedfordshire Council</a>. - [% ELSIF body.name.match('Cheshire') %] - Its area is now covered by <a href="/reports/Cheshire+West+and+Chester">Cheshire West and Chester Council</a> or - <a href="/reports/Cheshire+East">Cheshire East Council</a>. - [% ELSIF body.name.match('Bedfordshire') %] - Its area is now covered by <a href="/reports/Bedford">Bedford Borough Council</a> or - <a href="/reports/Central+Bedfordshire">Central Bedfordshire Council</a>. - [% END %] - </p> +[% IF NOT body.areas.size AND c.cobrand.moniker == 'fixmystreet' %] + [% INCLUDE 'reports/_body_gone.html' %] [% ELSE %] [% INCLUDE 'reports/_rss.html' %] [% END %] @@ -84,28 +60,13 @@ </p> [% END %] +[% INCLUDE "reports/_list-filters.html", use_section_wrapper = 1 %] + [% INCLUDE 'pagination.html', param = 'p' %] -<section class="full-width"> - [% INCLUDE column - problems = problems.${body.id} - %] -</section> +[% INCLUDE 'reports/_problem-list.html' %] [% INCLUDE 'pagination.html', param = 'p' %] </div> [% INCLUDE 'footer.html' %] - -[% BLOCK column %] -[% IF problems %] - -<ul class="issue-list-a"> -[% FOREACH problem IN problems %] - [% INCLUDE 'reports/_list-entry.html' %] -[% END %] -</ul> - -[% END %] -[% END %] - diff --git a/templates/web/base/reports/index.html b/templates/web/base/reports/index.html index 7f8d7fbf6..4b8c27b92 100755 --- a/templates/web/base/reports/index.html +++ b/templates/web/base/reports/index.html @@ -18,11 +18,11 @@ <thead> <tr> <th class="title">[% loc('Name') %]</th> -<th class="data">[% loc('New <br>problems') %]</th> -<th class="data">[% loc('Older <br>problems') %]</th> -<th class="data">[% loc('Old / unknown <br>problems') %]</th> -<th class="data">[% loc('Recently <br>fixed') %]</th> -<th class="data">[% loc('Older <br>fixed') %]</th> +<th title="[% loc('Reported within the last four weeks') %]" class="data">[% loc('New <br>problems') %]</th> +<th title="[% loc('Open for more than four weeks, with an update within the past eight weeks') %]" class="data">[% loc('Older <br>problems') %]</th> +<th title="[% loc('Open, but not had any update in eight weeks') %]" class="data">[% loc('Old / unknown <br>problems') %]</th> +<th title="[% loc('Marked fixed/closed in the past eight weeks') %]" class="data">[% loc('Recently <br>fixed') %]</th> +<th title="[% loc('Marked fixed/closed more than eight weeks ago') %]" class="data">[% loc('Older <br>fixed') %]</th> </tr> </thead> @@ -44,4 +44,11 @@ </tbody> </table> +<script type="text/javascript" src="[% version('/js/jquery.fixedthead.js') %]"></script> +<script type="text/javascript"> +$(function(){ + $('.nicetable thead').fixedThead(); +}); +</script> + [% INCLUDE 'footer.html', pagefooter = 'yes' %] diff --git a/templates/web/base/tokens/confirm_alert.html b/templates/web/base/tokens/confirm_alert.html index a33f7e92a..f0ad12ff8 100644 --- a/templates/web/base/tokens/confirm_alert.html +++ b/templates/web/base/tokens/confirm_alert.html @@ -1,20 +1,19 @@ [% INCLUDE 'header.html', bodyclass = 'fullwidthpage', title => loc('Local RSS feeds and email alerts') %] <div class="confirmation-header"> - <h1>[% loc('Local RSS feeds and email alerts') %]</h1> -<p> -[% IF confirm_type == 'subscribe' %] - [% loc('You have successfully confirmed your alert.') %] -[% ELSIF confirm_type == 'unsubscribe' %] - [% loc('You have successfully deleted your alert.') %] -[% ELSIF confirm_type == 'created' %] - [% loc('You have successfully created your alert.') %] -[% END %] -</p> + [% IF confirm_type == 'subscribe' || confirm_type == 'created' %] + <h1>[% loc('Email alert created') %]</h1> + <p>[% loc('Why stop there? <a href="/alert">Set up more alerts</a> for free.') %]</p> + + [% ELSIF confirm_type == 'unsubscribe' %] + <h1>[% loc('Email alert deleted') %]</h1> + <p>[% loc('Inbox zero, here we come!') %]</p> + + [% END %] </div> -[% display_crosssell_advert( alert.user.email, alert.user.name ) %] +[% INCLUDE next_steps.html %] [% INCLUDE 'footer.html' %] diff --git a/templates/web/base/tokens/confirm_problem.html b/templates/web/base/tokens/confirm_problem.html index 217fb0a72..5892d0f9e 100644 --- a/templates/web/base/tokens/confirm_problem.html +++ b/templates/web/base/tokens/confirm_problem.html @@ -1,38 +1,30 @@ [% INCLUDE 'header.html', bodyclass = 'fullwidthpage', title = loc('Confirmation') %] <div class="confirmation-header"> - <h1>[% loc('Your problem has been confirmed!') %]</h1> -[% IF c.cobrand.is_council %] + <h1><a href="[% c.cobrand.base_url_for_report( report ) %][% report.url %]">[% report.title %]</a></h1> - <p> - Thank you. You have successfully confirmed your report - and this will now be investigated by the council. - You can <a href="[% c.cobrand.base_url_for_report( problem ) %][% problem.url %]">view the problem on this site</a>. - </p> - <p>Your reference for this problem is [% problem.id %], please quote it in any enquiries.</p> + [% IF c.cobrand.is_council %] + <h2>Your issue is on its way to the council.</h2> + <p>Your reference for this report is [% report.id %], please quote it in any enquiries.</p> -[% ELSE %] + [% ELSE %] + <h2>[% loc('Thank you for reporting this issue!') %]</h2> + [% IF report.bodies_str %] + <p>[% loc('It’s on its way to the council right now.') %]</p> + [% END %] - <p> - [% loc('Thank you for reporting this issue') %]. - [% IF problem.bodies_str; - loc('<strong>We will now send it to the council</strong>.'); - END; %] - </p> + [% END %] - <p> - [% tprintf( - loc( 'You can <a href="%s%s">view the problem on this site</a>.' ), - c.cobrand.base_url_for_report( problem ), - problem.url - ); %] - </p> - -[% END %] +[% TRY %][% INCLUDE 'tokens/_extras_confirm.html' %][% CATCH file %][% END %] </div> -[% display_crosssell_advert( problem.user.email, problem.name ) %] +[% INCLUDE + next_steps.html, + just_interacted = 1, + share_url = c.cobrand.base_url_for_report(report) _ report.url, + twitter_comment = loc('I just reported a problem on @fixmystreet') +%] [% INCLUDE 'footer.html' %] diff --git a/templates/web/base/tokens/confirm_update.html b/templates/web/base/tokens/confirm_update.html index 21fcfc4ff..01ac992ab 100644 --- a/templates/web/base/tokens/confirm_update.html +++ b/templates/web/base/tokens/confirm_update.html @@ -1,24 +1,26 @@ -[% INCLUDE 'header.html', bodyclass = 'fullwidthpage', title => loc('Confirmation') %] +[% INCLUDE 'header.html', bodyclass = 'fullwidthpage', title = loc('Confirmation'); -<div class="confirmation-header"> - <h1>[% loc('Your update has been confirmed!') %]</h1> +DEFAULT problem = update.problem; +SET problem_url = c.uri_for('/report', problem.id); +IF update; + problem_url = problem_url _ '#update_' _ update.id; +END; -<p class="confirmed"> -[% IF creator_fixed %] -[% - tprintf(loc('Thank you — you can <a href="%s">view your updated problem</a> on the site.'), - c.uri_for( '/report', problem_id ) ); -%] -[% ELSE %] -[% - tprintf( loc('You have successfully confirmed your update and you can now <a href="%s">view it on the site</a>.'), - c.uri_for( '/report', update.problem.id ) _ '#update_' _ update.id ); %] -[% END %] -</p> + +<div class="confirmation-header"> + + <h1><a href="[% problem_url %]">[% problem.title %]</a></h1> + + <h2>[% loc('Thank you for updating this issue!') %]</h2> </div> -[% display_crosssell_advert( update.user.email, update.name ) %] +[% INCLUDE + next_steps.html, + just_interacted = 1, + share_url = c.cobrand.base_url_for_report(problem) _ problem.url, + twitter_comment = loc('I just updated a problem on @fixmystreet') +%] [% INCLUDE 'footer.html' %] |