diff options
Diffstat (limited to 'perllib/FixMyStreet/App/Controller')
-rw-r--r-- | perllib/FixMyStreet/App/Controller/Report.pm | 2 | ||||
-rw-r--r-- | perllib/FixMyStreet/App/Controller/Report/New.pm | 4 | ||||
-rw-r--r-- | perllib/FixMyStreet/App/Controller/Reports.pm | 3 |
3 files changed, 5 insertions, 4 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Report.pm b/perllib/FixMyStreet/App/Controller/Report.pm index a7a3328dc..12f6ec1d1 100644 --- a/perllib/FixMyStreet/App/Controller/Report.pm +++ b/perllib/FixMyStreet/App/Controller/Report.pm @@ -373,7 +373,7 @@ sub inspect : Private { my $permissions = $c->stash->{_permissions}; $c->forward('/admin/categories_for_point'); - $c->stash->{report_meta} = { map { $_->{name} => $_ } @{ $c->stash->{problem}->get_extra_fields() } }; + $c->stash->{report_meta} = { map { 'x' . $_->{name} => $_ } @{ $c->stash->{problem}->get_extra_fields() } }; if ($c->cobrand->can('council_area_id')) { my $priorities_by_category = FixMyStreet::App->model('DB::ResponsePriority')->by_categories($c->cobrand->council_area_id, @{$c->stash->{contacts}}); diff --git a/perllib/FixMyStreet/App/Controller/Report/New.pm b/perllib/FixMyStreet/App/Controller/Report/New.pm index e6c4fe50d..2de1d8551 100644 --- a/perllib/FixMyStreet/App/Controller/Report/New.pm +++ b/perllib/FixMyStreet/App/Controller/Report/New.pm @@ -1078,7 +1078,7 @@ sub set_report_extras : Private { foreach my $field ( @$metas ) { if ( lc( $field->{required} ) eq 'true' && !$c->cobrand->category_extra_hidden($field)) { unless ( $c->get_param($param_prefix . $field->{code}) ) { - $c->stash->{field_errors}->{ $field->{code} } = _('This information is required'); + $c->stash->{field_errors}->{ 'x' . $field->{code} } = _('This information is required'); } } push @extra, { @@ -1093,7 +1093,7 @@ sub set_report_extras : Private { if ( scalar @$contacts ); if ( @extra ) { - $c->stash->{report_meta} = { map { $_->{name} => $_ } @extra }; + $c->stash->{report_meta} = { map { 'x' . $_->{name} => $_ } @extra }; $c->stash->{report}->set_extra_fields( @extra ); } } diff --git a/perllib/FixMyStreet/App/Controller/Reports.pm b/perllib/FixMyStreet/App/Controller/Reports.pm index 42f5ea288..975b2fdd5 100644 --- a/perllib/FixMyStreet/App/Controller/Reports.pm +++ b/perllib/FixMyStreet/App/Controller/Reports.pm @@ -74,7 +74,8 @@ sub index : Path : Args(0) { } # Down here so that error pages aren't cached. - $c->response->header('Cache-Control' => 'max-age=3600'); + my $max_age = FixMyStreet->config('CACHE_TIMEOUT') // 3600; + $c->response->header('Cache-Control' => 'max-age=' . $max_age); } =head2 display_body_stats |