...
|
...
|
@@ -391,8 +391,8 @@ class Business extends Base |
|
|
->field('a.*,b.address,b.name,b.phone')
|
|
|
->where($where)->find();
|
|
|
//验证
|
|
|
$r1 = Db::name('_verification_staff')->where(['user_id'=>$user_id,'type'=>'0','verification_store_id'=>$store_id])->find();
|
|
|
if(empty($r1)){ return $this->error('仅店长可查自己店铺信息'); }
|
|
|
//$r1 = Db::name('_verification_staff')->where(['user_id'=>$user_id,'type'=>'0','verification_store_id'=>$store_id])->find();
|
|
|
//if(empty($r1)){ return $this->error('仅店长可查自己店铺信息'); }
|
|
|
//当前店铺下的代理人,及代理人的推广数量
|
|
|
$rows = Db::name('_verification_staff')->where(['verification_store_id'=>$store_id,'type'=>['in',['0','1','3']]])->field("name,0 as count,user_id")->paginate(20)->each(function($item){
|
|
|
$item['count'] = Db::name('user')->where(['pid'=>$item['user_id']])->count();
|
...
|
...
|
@@ -424,8 +424,8 @@ class Business extends Base |
|
|
//参数
|
|
|
$param = request()->param();
|
|
|
//验证
|
|
|
if(empty($param['date'])){$param['date'] = date("Y-m-d"); }
|
|
|
$dates = [strtotime($param['date']." 00:00:00"),strtotime($param['date']." 23:59:59")];
|
|
|
//if(empty($param['date'])){$param['date'] = date("Y-m-d"); }
|
|
|
//$dates = [strtotime($param['date']." 00:00:00"),strtotime($param['date']." 23:59:59")];
|
|
|
$r1 = Db::name('_verification_staff')->where(['user_id'=>$user_id,'type'=>'0','verification_store_id'=>$store_id])->find();
|
|
|
if(empty($r1)){ return $this->error('仅店长可查自己店铺信息'); }
|
|
|
//当前店铺下的代理人,及代理人的推广数量
|
...
|
...
|
|