diff options
author | Matthew Somerville <matthew@mysociety.org> | 2019-08-19 12:07:23 +0100 |
---|---|---|
committer | Matthew Somerville <matthew@mysociety.org> | 2019-09-30 12:44:57 +0100 |
commit | deb188a725a70ae175e0d85f37359bdff066ce3d (patch) | |
tree | 3f05d945a3401fb9fa5282f50255cccc4203c2b1 | |
parent | a5ad498457e92ba37b43a84331c3924e43b40bba (diff) |
[Zurich] Fix category dropdown on /reports.
-rw-r--r-- | perllib/FixMyStreet/Cobrand/Zurich.pm | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/Cobrand/Zurich.pm b/perllib/FixMyStreet/Cobrand/Zurich.pm index d33e45fbd..4409cfd7b 100644 --- a/perllib/FixMyStreet/Cobrand/Zurich.pm +++ b/perllib/FixMyStreet/Cobrand/Zurich.pm @@ -331,6 +331,14 @@ sub report_page_data { $c->detach('ajax', [ 'reports/_problem-list.html' ]); } + my @categories = $c->model('DB::Contact')->not_deleted->search(undef, { + columns => [ 'category', 'extra' ], + order_by => [ 'category' ], + distinct => 1 + })->all; + $c->stash->{filter_categories} = \@categories; + $c->stash->{filter_category} = { map { $_ => 1 } $c->get_param_list('filter_category', 1) }; + my $pins = $c->stash->{pins}; FixMyStreet::Map::display_map( $c, |