作者 董瑞恩
1 个管道 的构建 通过 耗费 0 秒

order

@@ -46,15 +46,15 @@ class AdminStatisticsController extends AdminBaseController{ @@ -46,15 +46,15 @@ class AdminStatisticsController extends AdminBaseController{
46 46
47 //周统计 47 //周统计
48 $week=array(); 48 $week=array();
49 - for ($i = 0; $i <= 15; $i++){ 49 + for ($i = 0; $i <= 30; $i++){
50 $week[15-$i]=strtotime(date('Ymd',strtotime("-$i week"))); 50 $week[15-$i]=strtotime(date('Ymd',strtotime("-$i week")));
51 } 51 }
52 $Week=array(); 52 $Week=array();
53 - for ($i = 0; $i<15; $i++){ 53 + for ($i = 0; $i<30; $i++){
54 $Week[$i]=[$week[$i],$week[$i+1]]; 54 $Week[$i]=[$week[$i],$week[$i+1]];
55 } 55 }
56 $Week_statistics=array(); 56 $Week_statistics=array();
57 - for ($i = 0; $i<15; $i++){ 57 + for ($i = 0; $i<30; $i++){
58 $Week_statistics[]=Db::name('order')->where('start_time','between',$Week[$i])->count(); 58 $Week_statistics[]=Db::name('order')->where('start_time','between',$Week[$i])->count();
59 } 59 }
60 $this->assign('weekData',json_encode($Week_statistics)); 60 $this->assign('weekData',json_encode($Week_statistics));
@@ -432,7 +432,7 @@ @@ -432,7 +432,7 @@
432 realtime: true, 432 realtime: true,
433 y : 220, 433 y : 220,
434 height: 20, 434 height: 20,
435 - start : 0, 435 + start : 50,
436 end : 100 436 end : 100
437 }, 437 },
438 438