Browse Source

获取年各场馆统计数据接口 月份已key排序

master
wanghongjun 2 years ago
parent
commit
2c47c924a8
  1. 4
      source/application/api/controller/pass/Statistics.php

4
source/application/api/controller/pass/Statistics.php

@ -67,7 +67,7 @@ class Statistics extends Controller
'year' => $monthData['sum_year'], 'year' => $monthData['sum_year'],
'monthDate' => [] 'monthDate' => []
]; ];
ksort($monthData['month']);
foreach ($monthData['month'] as $month => $value) { foreach ($monthData['month'] as $month => $value) {
$tempData['monthDate'][] = [ $tempData['monthDate'][] = [
'month' => $month, 'month' => $month,
@ -109,7 +109,7 @@ class Statistics extends Controller
'year' => $monthData['sum_year'], 'year' => $monthData['sum_year'],
'monthDate' => [] 'monthDate' => []
]; ];
ksort($monthData['month']);
foreach ($monthData['month'] as $month => $value) { foreach ($monthData['month'] as $month => $value) {
$tempData['monthDate'][] = [ $tempData['monthDate'][] = [
'month' => $month, 'month' => $month,

Loading…
Cancel
Save