aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/App/Controller/Report.pm
diff options
context:
space:
mode:
Diffstat (limited to 'perllib/FixMyStreet/App/Controller/Report.pm')
-rw-r--r--perllib/FixMyStreet/App/Controller/Report.pm15
1 files changed, 3 insertions, 12 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Report.pm b/perllib/FixMyStreet/App/Controller/Report.pm
index 7f1132117..6a7a14b5c 100644
--- a/perllib/FixMyStreet/App/Controller/Report.pm
+++ b/perllib/FixMyStreet/App/Controller/Report.pm
@@ -307,21 +307,10 @@ sub inspect : Private {
$c->stash->{categories} = $c->forward('/admin/categories_for_point');
- # The available priorities for this problem are dependent on the cobrand it
- # was reported to, not necessarily the active cobrand (e.g. inspecting a
- # report on fms.com that was sent to Oxfordshire), so make sure the correct
- # priorities are available for selection.
- if ( $c->cobrand->can('get_body_handler_for_problem') ) {
- my $handler = $c->cobrand->get_body_handler_for_problem($c->stash->{problem});
- if ( $handler->can('problem_response_priorities') ) {
- $c->stash->{priorities} = $handler->problem_response_priorities;
- }
- }
-
if ( $c->get_param('save') || $c->get_param('save_inspected') ) {
$c->forward('/auth/check_csrf_token');
- foreach (qw/priority detailed_location detailed_information traffic_information/) {
+ foreach (qw/detailed_location detailed_information traffic_information/) {
$problem->set_extra_metadata( $_ => $c->get_param($_) );
}
@@ -342,6 +331,8 @@ sub inspect : Private {
$c->forward( '/admin/log_edit', [ $id, 'problem', 'state_change' ] );
}
+ $problem->response_priority( $problem->response_priorities->find({ id => $c->get_param('priority') }) );
+
my $valid = 1;
if ( !$c->forward( '/admin/report_edit_location', [ $problem ] ) ) {
# New lat/lon isn't valid, show an error