aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/App/Controller/Admin
diff options
context:
space:
mode:
authorMatthew Somerville <matthew-github@dracos.co.uk>2018-09-24 13:06:44 +0100
committerMatthew Somerville <matthew-github@dracos.co.uk>2018-09-25 10:57:12 +0100
commitcdd94a3de1445d0aea4dfc8c18cbae9e315bdda9 (patch)
tree86e5f23db56e5d632d00b812af8988a158997472 /perllib/FixMyStreet/App/Controller/Admin
parent785c6cebec327ebf1518c08f1447dbd12224b952 (diff)
Speed up fetching lists of bodies.
Use a HashRefInflator wherever all_sorted is used, with consequential changes to deal with it now not being an object (e.g. add some with_* functions for manual fetching of extra data).
Diffstat (limited to 'perllib/FixMyStreet/App/Controller/Admin')
-rw-r--r--perllib/FixMyStreet/App/Controller/Admin/DefectTypes.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Admin/DefectTypes.pm b/perllib/FixMyStreet/App/Controller/Admin/DefectTypes.pm
index 5dab1da2c..ed9b40fd0 100644
--- a/perllib/FixMyStreet/App/Controller/Admin/DefectTypes.pm
+++ b/perllib/FixMyStreet/App/Controller/Admin/DefectTypes.pm
@@ -12,6 +12,7 @@ sub index : Path : Args(0) {
my $user = $c->user;
if ($user->is_superuser) {
+ $c->stash->{with_defect_type_count} = 1;
$c->forward('/admin/fetch_all_bodies');
} elsif ( $user->from_body ) {
$c->forward('load_user_body', [ $user->from_body->id ]);