diff options
author | Struan Donald <struan@exo.org.uk> | 2013-06-27 12:16:46 +0100 |
---|---|---|
committer | Struan Donald <struan@exo.org.uk> | 2013-06-28 09:44:02 +0100 |
commit | aaada04f334c23a0b91ec3feab1825a23f7224c7 (patch) | |
tree | 7e28cdfb2031141877b51bc300206cc9d86f2ed8 | |
parent | 5d62b493baf8579c3351cb84e3f2dbff1c979763 (diff) |
if cancel locating then make sure map buttons are in correct state and also display help message
-rw-r--r-- | www/js/strings.js | 1 | ||||
-rw-r--r-- | www/js/views/around.js | 7 |
2 files changed, 8 insertions, 0 deletions
diff --git a/www/js/strings.js b/www/js/strings.js index 9f2b3c5..40b3835 100644 --- a/www/js/strings.js +++ b/www/js/strings.js @@ -31,6 +31,7 @@ report_send_error: 'There was a problem submitting your report. Please try again', missing_location: 'Please enter a location', location_check_failed: 'Could not check your location', + locate_dismissed: 'Please search for a street name and area, or postcode.', geolocation_failed: 'Could not determine your location, please search for a street name and area, or postcode instead.', geolocation_denied: 'Could not access location services. Please check permissions.', select_category: '-- Pick a categoy --', diff --git a/www/js/views/around.js b/www/js/views/around.js index 34f93db..fc9a7e6 100644 --- a/www/js/views/around.js +++ b/www/js/views/around.js @@ -257,6 +257,7 @@ fixmystreet.map.panTo(this.projectCoords( coords )); } else { this.setMapPosition(info); + this.displayButtons(false); } }, @@ -314,6 +315,12 @@ goSearch: function(e) { e.preventDefault(); + if ( !fixmystreet.map ) { + this.$('#mark-here').hide(); + this.$('#relocate').hide(); + $('#front-howto').html('<p>' + FMS.strings.locate_dismissed + '</msg>'); + $('#front-howto').show(); + } this.finishedLocating(); }, |