diff options
author | Dave Arter <davea@mysociety.org> | 2018-06-12 14:09:49 +0100 |
---|---|---|
committer | Dave Arter <davea@mysociety.org> | 2018-08-17 09:43:36 +0100 |
commit | 7f95b46a2516a5104c699bd03231a7a7d8f88a1d (patch) | |
tree | 00a6b08a391412b911c90d5e0cefdcfe7ba8a8bd | |
parent | 85f60fef68b3be977a4b8b1dac5ab588144da395 (diff) |
[Lincolnshire] Only show certain district categories on cobrand
-rw-r--r-- | perllib/FixMyStreet/Cobrand/Lincolnshire.pm | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/Cobrand/Lincolnshire.pm b/perllib/FixMyStreet/Cobrand/Lincolnshire.pm index e90cd5af9..1e88ec624 100644 --- a/perllib/FixMyStreet/Cobrand/Lincolnshire.pm +++ b/perllib/FixMyStreet/Cobrand/Lincolnshire.pm @@ -32,4 +32,19 @@ sub open311_config { $row->set_extra_fields(@$extra); } +sub categories_restriction { + my ($self, $rs) = @_; + # Lincolnshire is a two-tier council, but don't want to display + # all district-level categories on their cobrand - just a couple. + return $rs->search( { -or => [ + 'body.name' => "Lincolnshire County Council", + + # District categories: + 'me.category' => { -in => [ + 'Street nameplates', + 'Bench/cycle rack/litter bin/planter', + ] }, + ] } ); +} + 1; |