diff options
author | Dave Arter <davea@mysociety.org> | 2015-03-02 16:42:57 +0000 |
---|---|---|
committer | Steven Day <steve@mysociety.org> | 2015-06-29 12:43:00 +0100 |
commit | d9435467362a52bd23739c56e9a4996685e7eb28 (patch) | |
tree | 11e9b7cfc2a1191e6c7edf5bf60605a564061a63 /perllib | |
parent | 09f94956ecd20a7aa861d0f7254189fd9373b813 (diff) |
Filter initial pins by category on /around
Diffstat (limited to 'perllib')
-rw-r--r-- | perllib/FixMyStreet/App/Controller/Around.pm | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Around.pm b/perllib/FixMyStreet/App/Controller/Around.pm index 413af814f..858cbb5af 100644 --- a/perllib/FixMyStreet/App/Controller/Around.pm +++ b/perllib/FixMyStreet/App/Controller/Around.pm @@ -165,10 +165,13 @@ sub display_location : Private { $c->stash->{all_pins} = $all_pins; my $interval = $all_pins ? undef : $c->cobrand->on_map_default_max_pin_age; + # Filter by report category + my $category = $c->req->param('category'); + # get the map features my ( $on_map_all, $on_map, $around_map, $distance ) = FixMyStreet::Map::map_features( $c, $latitude, $longitude, - $interval ); + $interval, $category ); # copy the found reports to the stash $c->stash->{on_map} = $on_map; |