aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/Map.pm
diff options
context:
space:
mode:
authorMatthew Somerville <matthew-github@dracos.co.uk>2016-11-01 16:56:08 +0000
committerMatthew Somerville <matthew-github@dracos.co.uk>2016-11-04 17:24:46 +0000
commit051093f803444d99c48d130d59dcfe2ba9759c90 (patch)
tree7407d9616442dc5bc9c81f29532b9a5b7704b6f5 /perllib/FixMyStreet/Map.pm
parentb3bb51dab4f620463c551e7bbe6814d415ebf227 (diff)
Add sort order options to list pages.
Includes newest, oldest, least/most recently updated, and most comments. The default remains the same, which is last updated on /reports, and newest on /my and /around (the latter plus not-in-view sorted-by-distance ones).
Diffstat (limited to 'perllib/FixMyStreet/Map.pm')
-rw-r--r--perllib/FixMyStreet/Map.pm5
1 files changed, 2 insertions, 3 deletions
diff --git a/perllib/FixMyStreet/Map.pm b/perllib/FixMyStreet/Map.pm
index f7caf51d7..b6b618efb 100644
--- a/perllib/FixMyStreet/Map.pm
+++ b/perllib/FixMyStreet/Map.pm
@@ -91,10 +91,9 @@ sub map_features {
# list of problems around map can be limited, but should show all pins
my $around_limit = $c->cobrand->on_map_list_limit || undef;
- my @around_args = @p{"min_lat", "max_lat", "min_lon", "max_lon", "interval"};
- my $on_map_all = $c->cobrand->problems_on_map->around_map( @around_args, undef, $p{categories}, $p{states} );
+ my $on_map_all = $c->cobrand->problems_on_map->around_map( undef, %p );
my $on_map_list = $around_limit
- ? $c->cobrand->problems_on_map->around_map( @around_args, $around_limit, $p{categories}, $p{states} )
+ ? $c->cobrand->problems_on_map->around_map( $around_limit, %p )
: $on_map_all;
my $dist = FixMyStreet::Gaze::get_radius_containing_population( $p{latitude}, $p{longitude} );