|
@@ -56,12 +56,21 @@ class Member extends Controller
|
|
|
if($phone = input('get.phone')) $where[] = ['m.phone','like','%'.$phone.'%'];
|
|
|
if($level_id = input('get.level_id')) $where[] = ['m.level_id','=',$level_id];
|
|
|
$field="m.id,m.openid,m.name,m.headimg,m.level_exp,m.phone,m.status,m.create_at,w.growth,w.integral,w.money";
|
|
|
+ $create_at = input('create_at');
|
|
|
+
|
|
|
$query = $this->_query($this->table)
|
|
|
->field($field)
|
|
|
->alias('m')
|
|
|
->leftJoin('UserWallet w','m.id =w.user_id')
|
|
|
->where($where)
|
|
|
- ->dateBetween('create_at')->order('id desc')->page();
|
|
|
+ ->when($create_at,function ($q)use ($create_at){
|
|
|
+ if($create_at){
|
|
|
+ $time = explode(' - ',$_GET['create_at']);
|
|
|
+ $start_date_time = $time[0];
|
|
|
+ $end_date_time = $time[1];
|
|
|
+ $q->whereBetweenTime('m.create_at',$start_date_time,$end_date_time);
|
|
|
+ }
|
|
|
+ })->order('id desc')->page();
|
|
|
}
|
|
|
|
|
|
/**
|