diff options
Diffstat (limited to 'bin/fixmystreet.com/fixture')
-rwxr-xr-x | bin/fixmystreet.com/fixture | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/bin/fixmystreet.com/fixture b/bin/fixmystreet.com/fixture index 1062eb16b..082fc6309 100755 --- a/bin/fixmystreet.com/fixture +++ b/bin/fixmystreet.com/fixture @@ -100,7 +100,7 @@ if ($opt->test_fixtures) { { area_id => 2397, categories => [ 'Graffiti' ], name => 'Northampton Borough Council' }, { area_id => 2483, categories => [ 'Potholes', 'Other' ], name => 'Hounslow Borough Council' }, { area_id => 2636, categories => [ 'Potholes', 'Private', 'Extra' ], name => 'Isle of Wight Council' }, - { area_id => 2566, categories => [ 'Fallen branch' ], name => 'Peterborough City Council' }, + { area_id => 2566, categories => [ 'Fallen branch', 'Light Out', 'Light Dim', 'Fallen Tree', 'Damaged Tree' ], name => 'Peterborough City Council' }, { area_id => 2498, categories => [ 'Incorrect timetable', 'Glass broken', 'Mobile Crane Operation' ], name => 'TfL' }, ) { $bodies->{$_->{area_id}} = FixMyStreet::DB::Factory::Body->find_or_create($_); @@ -108,6 +108,24 @@ if ($opt->test_fixtures) { say "Created body $_->{name} for MapIt area ID $_->{area_id}, categories $cats"; } + for my $cat_name ('Fallen Tree', 'Damaged Tree') { + my $cat = FixMyStreet::DB->resultset('Contact')->find({ + body => $bodies->{2566}, + category => $cat_name, + }); + $cat->set_extra_metadata( group => 'Trees' ); + $cat->update; + } + + for my $cat_name ('Light Out', 'Light Dim') { + my $cat = FixMyStreet::DB->resultset('Contact')->find({ + body => $bodies->{2566}, + category => $cat_name, + }); + $cat->set_extra_metadata( group => 'Street lighting' ); + $cat->update; + } + my $child_cat = FixMyStreet::DB->resultset("Contact")->find({ body => $bodies->{2234}, category => 'Very Urgent', |