aboutsummaryrefslogtreecommitdiffstats
path: root/perllib
diff options
context:
space:
mode:
authorJon Kristensen <info@jonkri.com>2014-08-14 12:07:53 +0200
committerMatthew Somerville <matthew@mysociety.org>2015-02-16 14:55:49 +0000
commit8d531702431d9c07c10ff4aac96584a6c2abf946 (patch)
treee60d71be9a523f301dd05b91637053bbaef5bfb5 /perllib
parentb3e2b0c31aaf376b193cce01508027514152b89c (diff)
[FixaMinGata] Differ pin colours based on state
Diffstat (limited to 'perllib')
-rw-r--r--perllib/FixMyStreet/Cobrand/FixaMinGata.pm9
1 files changed, 9 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/Cobrand/FixaMinGata.pm b/perllib/FixMyStreet/Cobrand/FixaMinGata.pm
index 60f98dd47..7e8942feb 100644
--- a/perllib/FixMyStreet/Cobrand/FixaMinGata.pm
+++ b/perllib/FixMyStreet/Cobrand/FixaMinGata.pm
@@ -236,4 +236,13 @@ sub reports_council_check {
}
}
+# The pin is green is it's fixed, yellow if it's closed (but not fixed), and
+# red otherwise.
+sub pin_colour {
+ my ( $self, $p, $context ) = @_;
+ return 'green' if $p->is_fixed;
+ return 'yellow' if $p->is_closed;
+ return 'red';
+}
+
1;