aboutsummaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorMatthew Somerville <matthew-github@dracos.co.uk>2018-08-07 16:59:16 +0100
committerMatthew Somerville <matthew-github@dracos.co.uk>2018-08-07 16:59:16 +0100
commit6d5f59c50e77e5825a6a7893039405df5c30d7e5 (patch)
tree172b9a561a772f7b63b87379e70e19e974972c19 /templates
parentf49a9529dce092e702213778eaa56faa0afefd5f (diff)
parent4e8e8d3b4912ec6552ae5290dbf47cf1d5968107 (diff)
Merge remote-tracking branch 'origin/2012-new-report-near-here'
Diffstat (limited to 'templates')
-rw-r--r--templates/web/base/js/translation_strings.html6
-rw-r--r--templates/web/base/main_nav_items.html10
2 files changed, 15 insertions, 1 deletions
diff --git a/templates/web/base/js/translation_strings.html b/templates/web/base/js/translation_strings.html
index a2e3c16c5..f6e1e580b 100644
--- a/templates/web/base/js/translation_strings.html
+++ b/templates/web/base/js/translation_strings.html
@@ -71,6 +71,12 @@ fixmystreet.password_minimum_length = [% c.cobrand.password_minimum_length %];
login_with_email: '[% loc('Log in with email') | replace("'", "\\'") %]',
[% END ~%]
+ report_a_problem_btn: {
+ default: '[% loc('Report a problem') | replace("'", "\\'") %]',
+ here: '[% loc('Report a problem here') | replace("'", "\\'") %]',
+ another: '[% loc('Report another problem here') | replace("'", "\\'") %]'
+ },
+
offline: {
your_reports: '[% loc('Your offline reports') | replace("'", "\\'") %]',
update_saved: '[% loc('Your update has been saved offline for submission when back online.') | replace("'", "\\'") %]',
diff --git a/templates/web/base/main_nav_items.html b/templates/web/base/main_nav_items.html
index 618aa8328..3940052a3 100644
--- a/templates/web/base/main_nav_items.html
+++ b/templates/web/base/main_nav_items.html
@@ -1,4 +1,12 @@
-[%~ INCLUDE navitem uri=(homepage_template ? '/report' : '/') label=loc('Report a problem') attrs='class="report-a-problem-btn"' ~%]
+[%~ IF problem ~%]
+ [%~ INCLUDE navitem uri='/report/new?longitude=' _ problem.longitude _ '&amp;latitude=' _ problem.latitude label=loc('Report another problem here') attrs='class="report-a-problem-btn"' ~%]
+[%~ ELSIF latitude AND longitude ~%]
+ [%~ INCLUDE navitem uri='/report/new?longitude=' _ longitude _ '&amp;latitude=' _ latitude label=loc('Report a problem here') attrs='class="report-a-problem-btn"' ~%]
+[%~ ELSIF homepage_template ~%]
+ [%~ INCLUDE navitem uri='/report' label=loc('Report a problem') attrs='class="report-a-problem-btn"' ~%]
+[%~ ELSE ~%]
+ [%~ INCLUDE navitem uri='/' label=loc('Report a problem') attrs='class="report-a-problem-btn"' ~%]
+[%~ END ~%]
[%~ IF c.user_exists ~%]
[%~ INCLUDE navitem uri='/my' label=loc('Your account') ~%]