Skip to content

Commit 8f0ac6c

Browse files
daveadracos
authored andcommitted
[Shropshire] Custom pin colours.
1 parent 3a16b67 commit 8f0ac6c

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

perllib/FixMyStreet/Cobrand/Shropshire.pm

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,4 +205,21 @@ sub dashboard_export_problems_add_columns {
205205
});
206206
}
207207

208+
=head2 pin_colour
209+
210+
Green for completed or closed, yellow for open,
211+
blue for anything else (in progress, action scheduled, etc)
212+
213+
=cut
214+
215+
sub pin_colour {
216+
my ( $self, $p ) = @_;
217+
218+
return 'green-tick' if $p->is_fixed || $p->is_closed;
219+
return 'yellow-cone' if $p->state eq 'confirmed';
220+
return 'blue-work';
221+
}
222+
223+
sub path_to_pin_icons { '/i/pins/whole-shadow-cone-spot/' }
224+
208225
1;

0 commit comments

Comments
 (0)