aboutsummaryrefslogtreecommitdiffstats
path: root/perllib
diff options
context:
space:
mode:
Diffstat (limited to 'perllib')
-rw-r--r--perllib/FixMyStreet/Cobrand/TfL.pm14
1 files changed, 14 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/Cobrand/TfL.pm b/perllib/FixMyStreet/Cobrand/TfL.pm
index b20c2c938..6f5cec730 100644
--- a/perllib/FixMyStreet/Cobrand/TfL.pm
+++ b/perllib/FixMyStreet/Cobrand/TfL.pm
@@ -4,6 +4,10 @@ use parent 'FixMyStreet::Cobrand::Whitelabel';
use strict;
use warnings;
+use POSIX qw(strcoll);
+
+use FixMyStreet::MapIt;
+
sub council_area_id { return [
2511, 2489, 2494, 2488, 2482, 2505, 2512, 2481, 2484, 2495,
2493, 2508, 2502, 2509, 2487, 2485, 2486, 2483, 2507, 2503,
@@ -96,4 +100,14 @@ sub admin_allow_user {
return $user->from_body->name eq 'TfL';
}
+sub fetch_area_children {
+ my $self = shift;
+
+ my $areas = FixMyStreet::MapIt::call('areas', $self->area_types);
+ foreach (keys %$areas) {
+ $areas->{$_}->{name} =~ s/\s*(Borough|City|District|County) Council$//;
+ }
+ return $areas;
+}
+
1;