|
@@ -353,6 +353,34 @@ class Authcompany
|
|
|
];
|
|
|
$userinfo['today_newpre'] = Db::name('pre_order')->where($map)->count();
|
|
|
|
|
|
+ //待处理订单数量
|
|
|
+ $map = [
|
|
|
+ 'company_id' => $this->company_id,
|
|
|
+ 'status' => 2,
|
|
|
+ ];
|
|
|
+ $userinfo['order_unfinish'] = Db::name('order')->where($map)->count();
|
|
|
+
|
|
|
+ //昨日订单数量
|
|
|
+ $starttime = strtotime(date('Y-m-d')) - 86400;
|
|
|
+ $endtime = strtotime(date('Y-m-d')) - 1;
|
|
|
+ $map = [
|
|
|
+ 'company_id' => $this->company_id,
|
|
|
+ 'status' => 3,
|
|
|
+ 'finish_time'=> ['BETWEEN',[$starttime,$endtime]],
|
|
|
+ ];
|
|
|
+ $userinfo['order_zuori'] = Db::name('order')->where($map)->count();
|
|
|
+
|
|
|
+ //7日订单数量
|
|
|
+ $starttime = strtotime(date('Y-m-d')) - 86400*6;
|
|
|
+ $endtime = strtotime(date('Y-m-d')) + 86399;
|
|
|
+ $map = [
|
|
|
+ 'company_id' => $this->company_id,
|
|
|
+ 'status' => 3,
|
|
|
+ 'finish_time'=> ['BETWEEN',[$starttime,$endtime]],
|
|
|
+ ];
|
|
|
+ $userinfo['order_qiri'] = Db::name('order')->where($map)->count();
|
|
|
+
|
|
|
+
|
|
|
return $userinfo;
|
|
|
}
|
|
|
|