diff options
Diffstat (limited to 'templates')
-rw-r--r-- | templates/web/base/auth/general.html | 3 | ||||
-rw-r--r-- | templates/web/base/common_footer_tags.html | 9 | ||||
-rw-r--r-- | templates/web/base/common_scripts.html | 17 | ||||
-rw-r--r-- | templates/web/borsetshire/auth/_general_top.html | 47 | ||||
-rw-r--r-- | templates/web/borsetshire/front/footer-marketing.html | 6 | ||||
-rw-r--r-- | templates/web/bristol/footer_extra_js.html | 2 | ||||
-rw-r--r-- | templates/web/bromley/footer_extra_js.html | 1 | ||||
-rw-r--r-- | templates/web/fixmystreet.com/report/updates-sidebar-notes.html | 2 | ||||
-rw-r--r-- | templates/web/zurich/footer.html | 3 | ||||
-rw-r--r-- | templates/web/zurich/footer_extra_js.html | 6 |
10 files changed, 46 insertions, 50 deletions
diff --git a/templates/web/base/auth/general.html b/templates/web/base/auth/general.html index 76426f5d8..8fc5578c1 100644 --- a/templates/web/base/auth/general.html +++ b/templates/web/base/auth/general.html @@ -50,7 +50,8 @@ [% ELSIF sign_in_error %] <div class="form-error">[% loc('There was a problem with your login information. If you cannot remember your password, or do not have one, please fill in the ‘No’ section of the form.') %]</div> [% END %] - <input type="text" class="form-control required" id="username" name="username" value="[% username | html %]" autofocus> + <input type="text" class="form-control required" id="username" name="username" value="[% username | html %]" + [%~ IF c.cobrand.moniker != 'borsetshire' %] autofocus[% END %]> <div id="form_sign_in"> <h3>[% tprintf(loc("Do you have a %s password?", "%s is the site name"), site_name) %]</h3> diff --git a/templates/web/base/common_footer_tags.html b/templates/web/base/common_footer_tags.html index 915751802..a5be06df5 100644 --- a/templates/web/base/common_footer_tags.html +++ b/templates/web/base/common_footer_tags.html @@ -5,8 +5,13 @@ <!--[if lte IE 9]> <script src="[% version('/vendor/history.polyfill.min.js') %]"></script> <![endif]--> -[% FOR script IN scripts ~%] - [% script = script.0 ? script : [ script ] ~%] +[% +scripts_seen = {}; +FOR script IN scripts; + script = script.0 ? script : [ script ]; + NEXT IF scripts_seen.${script.0}; + scripts_seen.${script.0} = 1; + ~%] <script src="[% script.0 %]" [%~ FOR attr IN script.1 %] [% attr.key %]="[% attr.value %]"[% END ~%] ></script> diff --git a/templates/web/base/common_scripts.html b/templates/web/base/common_scripts.html index 4c8fcfe74..86e826b18 100644 --- a/templates/web/base/common_scripts.html +++ b/templates/web/base/common_scripts.html @@ -9,21 +9,16 @@ scripts.push( start _ "/js/translation_strings." _ lang_code _ ".js?" _ Math.int( date.now / 3600 ), ); -SET jquery_loaded = 0; -SET geolocation_loaded = 0; IF bodyclass.match('frontpage'); - SET geolocation_loaded = 1; scripts.push( version('/js/front.js'), version('/js/geolocation.js'), ); ELSIF bodyclass.match('alertpage'); - SET geolocation_loaded = 1; scripts.push( version('/js/geolocation.js'), ); ELSE; - SET jquery_loaded = 1; scripts.push( version('/js/validation_rules.js'), version('/jslib/jquery-1.7.2.min.js'), @@ -38,17 +33,9 @@ FOR script IN extra_js; END; IF c.user_exists AND (c.user.from_body OR c.user.is_superuser); - IF NOT geolocation_loaded; - scripts.push( - version('/js/geolocation.js'), - ); - END; - IF NOT jquery_loaded; - scripts.push( - version('/jslib/jquery-1.7.2.min.js'), - ); - END; scripts.push( + version('/js/geolocation.js'), + version('/jslib/jquery-1.7.2.min.js'), version('/cobrands/fixmystreet/staff.js') ); IF c.user.has_body_permission_to('planned_reports'); diff --git a/templates/web/borsetshire/auth/_general_top.html b/templates/web/borsetshire/auth/_general_top.html index 6e65bf90b..0af3737e8 100644 --- a/templates/web/borsetshire/auth/_general_top.html +++ b/templates/web/borsetshire/auth/_general_top.html @@ -1,28 +1,23 @@ -<p>The following users exist, all with password <kbd>password</kbd> -(click them to quickly log in):</p> -<style> -#demo-user-list dt { - padding: 0 0.5em; -} -#demo-user-list dd { - color: #666; - font-size: 87.5%; - padding: 0 0.5em; -} -.js #demo-user-list dt:hover { - background-color: #faebac; - cursor: pointer; -} -</style> +<p> +Click on one of the buttons below to log in as one of the four +different types of user we’ve set up on this demo site: +</p> -<dl id='demo-user-list'> - <dt>inspector@example.org</dt> - <dd>an inspector, who can shortlist and inspect reports.</dd> - <dt>cs@example.org</dt> - <dd>a customer service rep, who can create reports as the council or another user, and moderate reports.</dd> - <dt>super@example.org</dt> - <dd>a council super user, who can do all the above, plus also edit users, templates, priorities, and more.</dd> - <dt>user@example.org</dt> - <dd>a normal user, who has created the example reports on the site.</dd> -</dl> +<ul id='demo-user-list' class="clearfix"> + <li> +<button class="btn" data-email="user@example.org">Normal user</button> +<span>A local resident who has created reports and updates on the site.</span> + <li> +<button class="btn" data-email="cs@example.org">Customer service</button> +<span>A customer service staff member, who can create and moderate existing reports.</span> + <li> +<button class="btn" data-email="inspector@example.org">Inspector</button> +<span>An inspector staff member, who can inspect reports and create shortlists.</span> + <li> +<button class="btn" data-email="super@example.org">Super user</button> +<span>A superuser staff member, who can do all the above, plus also edit users, templates, and priorities in the Admin screen.</span> +</ul> +<p> +Or sign in as normal, with an email address and password: +</p> diff --git a/templates/web/borsetshire/front/footer-marketing.html b/templates/web/borsetshire/front/footer-marketing.html new file mode 100644 index 000000000..78b4fa89b --- /dev/null +++ b/templates/web/borsetshire/front/footer-marketing.html @@ -0,0 +1,6 @@ +<div class="fms-pro-promo"> + <h2>FixMyStreet Professional</h2> + <p class="lead">The one-stop street reporting service for councils.</p> + <p>Integrate FixMyStreet with your council system for smooth, end-to-end report fullfilment.</p> + <p><a href="/about/professional" class="btn--borsetshire">Learn more</a></p> +</div> diff --git a/templates/web/bristol/footer_extra_js.html b/templates/web/bristol/footer_extra_js.html index 2f54083a0..218607498 100644 --- a/templates/web/bristol/footer_extra_js.html +++ b/templates/web/bristol/footer_extra_js.html @@ -1,6 +1,4 @@ [% scripts.push( version('/vendor/OpenLayers.Projection.OrdnanceSurvey.js') version('/cobrands/fixmystreet-uk-councils/js.js'), - version('/cobrands/fixmystreet/assets.js'), - version('/cobrands/bristol/js.js'), ) %] diff --git a/templates/web/bromley/footer_extra_js.html b/templates/web/bromley/footer_extra_js.html index ac03496a8..0b69cf5ad 100644 --- a/templates/web/bromley/footer_extra_js.html +++ b/templates/web/bromley/footer_extra_js.html @@ -1,3 +1,4 @@ [% scripts.push( + version('/jslib/jquery-1.7.2.min.js'), version('/cobrands/bromley/a-z-nav.js'), ) %] diff --git a/templates/web/fixmystreet.com/report/updates-sidebar-notes.html b/templates/web/fixmystreet.com/report/updates-sidebar-notes.html index 90e88d86c..17e3ade62 100644 --- a/templates/web/fixmystreet.com/report/updates-sidebar-notes.html +++ b/templates/web/fixmystreet.com/report/updates-sidebar-notes.html @@ -1,5 +1,5 @@ <p> - [% IF problem.send_method_used != 'Open311' OR NOT problem.to_body_named('Bromley|Stevenage') %] + [% IF NOT problem.send_method_used.match('Open311') OR NOT problem.to_body_named('Bromley|Stevenage') %] [% loc( 'Please note that updates are not sent to the council.' ) %] [% END %] [% loc( 'Your information will only be used in accordance with our <a href="/privacy">privacy policy</a>' ) %] diff --git a/templates/web/zurich/footer.html b/templates/web/zurich/footer.html index 0164dbcab..f68f80aea 100644 --- a/templates/web/zurich/footer.html +++ b/templates/web/zurich/footer.html @@ -34,10 +34,7 @@ </div> </div> - <script src="[% version('/cobrands/zurich/validation_rules.js') %]"></script> [% INCLUDE 'common_footer_tags.html' %] - <script src="//ajax.googleapis.com/ajax/libs/jqueryui/1.9.2/jquery-ui.min.js" charset="utf-8"></script> - <script src="[% version('/cobrands/zurich/js.js') %]"></script> </body> </html> diff --git a/templates/web/zurich/footer_extra_js.html b/templates/web/zurich/footer_extra_js.html new file mode 100644 index 000000000..a98457363 --- /dev/null +++ b/templates/web/zurich/footer_extra_js.html @@ -0,0 +1,6 @@ +[% scripts.push( + version('/jslib/jquery-1.7.2.min.js'), + version('/cobrands/zurich/validation_rules.js'), + '//ajax.googleapis.com/ajax/libs/jqueryui/1.9.2/jquery-ui.min.js', + version('/cobrands/zurich/js.js'), +) %] |