aboutsummaryrefslogtreecommitdiffstats
path: root/perllib
diff options
context:
space:
mode:
authorStruan Donald <struan@exo.org.uk>2017-09-06 18:04:00 +0100
committerStruan Donald <struan@exo.org.uk>2017-09-07 16:09:34 +0100
commit12013d397d981efbc90d5fed1a7bb25eae23eb91 (patch)
treee706232145f08b96858782d22410dd832636b207 /perllib
parentf57adcb38568a0321f349cd823fbd2578eacb2ef (diff)
sort body dashboard CSV export by report confirmed time
And update the tests to avoid a random failure caused by inconsistent ordering.
Diffstat (limited to 'perllib')
-rw-r--r--perllib/FixMyStreet/App/Controller/Dashboard.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Dashboard.pm b/perllib/FixMyStreet/App/Controller/Dashboard.pm
index 867d0659b..f961660c0 100644
--- a/perllib/FixMyStreet/App/Controller/Dashboard.pm
+++ b/perllib/FixMyStreet/App/Controller/Dashboard.pm
@@ -181,7 +181,7 @@ sub export_as_csv {
my ($self, $c, $problems_rs, $body) = @_;
require Text::CSV;
my $problems = $problems_rs->search(
- {}, { prefetch => 'comments' });
+ {}, { prefetch => 'comments', order_by => 'me.confirmed' });
my $filename = do {
my %where = (