|
@@ -18,6 +18,17 @@ class DeviceStatistics extends Auth {
|
|
|
$this->assign('end',$end);
|
|
|
return $this->fetch();
|
|
|
}
|
|
|
+ public function device1(){
|
|
|
+ $cur = date('Y-m-d');
|
|
|
+ $start = input('start',date('Y-m-d', strtotime(''.$cur.' -1 week')));
|
|
|
+ $end = input('end',date('Y-m-d'));
|
|
|
+ $start1 = $start.' 00:00:00';
|
|
|
+ $end1 = $end.' 23:59:59';
|
|
|
+
|
|
|
+ $this->assign('start',$start);
|
|
|
+ $this->assign('end',$end);
|
|
|
+ return $this->fetch();
|
|
|
+ }
|
|
|
public function deviceData($start1,$end1){
|
|
|
$map1[] = ['create_time','>=',$start1];
|
|
|
$map1[] = ['create_time','<=',$end1];
|