mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-16 17:33:45 +00:00
Fix sort.
This commit is contained in:
@@ -166,8 +166,6 @@ class OperationsController extends Controller
|
|||||||
$sum[$accountId] = floatval($row['sum']);
|
$sum[$accountId] = floatval($row['sum']);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Sort the data with volume descending, edition ascending
|
|
||||||
// Add $data as the last parameter, to sort by the common key
|
|
||||||
array_multisort($sum, SORT_ASC, $expenses);
|
array_multisort($sum, SORT_ASC, $expenses);
|
||||||
|
|
||||||
return $expenses;
|
return $expenses;
|
||||||
@@ -211,9 +209,7 @@ class OperationsController extends Controller
|
|||||||
$sum[$accountId] = floatval($row['sum']);
|
$sum[$accountId] = floatval($row['sum']);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Sort the data with volume descending, edition ascending
|
array_multisort($sum, SORT_DESC, $income);
|
||||||
// Add $data as the last parameter, to sort by the common key
|
|
||||||
array_multisort($sum, SORT_ASC, $income);
|
|
||||||
|
|
||||||
return $income;
|
return $income;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user