aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2012-02-22 14:58:06 +0000
committerMatthew Somerville <matthew@mysociety.org>2012-02-22 14:58:06 +0000
commite2882fa4558c0ff341749dce7a0faeca562a46c2 (patch)
tree2d7962403b9bd13007eb7e560e5732afc65d7908
parentac5c28bf63bbe41fb73c8d65124caa3c012e32f9 (diff)
Fix pin display when JS is disabled.
-rw-r--r--perllib/FixMyStreet/App/Controller/Report/New.pm2
-rw-r--r--templates/web/default/maps/openlayers.html8
2 files changed, 3 insertions, 7 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Report/New.pm b/perllib/FixMyStreet/App/Controller/Report/New.pm
index 1e5825460..ee471499c 100644
--- a/perllib/FixMyStreet/App/Controller/Report/New.pm
+++ b/perllib/FixMyStreet/App/Controller/Report/New.pm
@@ -1031,7 +1031,7 @@ sub generate_map : Private {
pins => [ {
latitude => $latitude,
longitude => $longitude,
- colour => 'purple',
+ colour => 'yellow',
} ],
);
}
diff --git a/templates/web/default/maps/openlayers.html b/templates/web/default/maps/openlayers.html
index 1c0a32278..24b23d55e 100644
--- a/templates/web/default/maps/openlayers.html
+++ b/templates/web/default/maps/openlayers.html
@@ -78,15 +78,11 @@ var fixmystreet = {
[% BLOCK pin %]
-[% cols = {
- red = 'R', green = 'G', blue = 'B', purple = 'P',
- }
-%]
[% IF pin.id %]
<a title="[% pin.title | html %]" href="[% c.uri_for('/report/' _ pin.id) %]">
[%- END -%]
-<img border="0" class="pin" src="[% c.uri_for('/i/pin' _ cols.${pin.colour} _ '.png') %]"
- alt="[% loc('Problem') %]" style="top:[% pin.py - 58 %]px; left:[% pin.px - 22 %]px; position: absolute;">
+<img border="0" class="pin" src="[% c.uri_for('/i/pin-' _ pin.colour _ '.png') %]"
+ alt="[% loc('Problem') %]" style="top:[% pin.py - 64 %]px; left:[% pin.px - 24 %]px; position: absolute;">
[%- IF pin.id -%]
</a>
[% END %]