Commit ff8c366d authored by zhuwei's avatar zhuwei

bug

parent 3a7f3506
......@@ -161,18 +161,18 @@ class User extends Basic
if($app_request_source_type == 1){
//'全部客户列表' 需要排除排除纯房东客户
$conditions['user_label'] = array( "neq", 2 );
if (!isset($conditions['create_time'])){//不存在$conditions['create_time']说明非精确搜索
if(!$is_search){
//1.全部客户列表、非精确搜索 需要排除排除保护期内的客户
$time_now = date('Y-m-d H:i:s');//当前时间
//protect_time 将截止日期大于当前时间的数据排除掉
$conditions['protect_time'] = array('lt',$time_now);
if(!$is_search){
$conditions['site_ids'] = [ 'LIKE', '%' . $this->siteId . '%' ];//默认显示经纪人所在站点的客户
}
$conditions['site_ids'] = [ 'LIKE', '%' . $this->siteId . '%' ];//默认显示经纪人所在站点的客户
}
}
}
/*if (!$is_search) {
$conditions['user_label'] = array( "neq", 2 );
}*/
......
......@@ -14,6 +14,7 @@ use app\model\OReportModel;
use app\model\TAgentTotalModel;
use app\model\UPhoneFollowPp;
use app\model\Users;
use think\Log;
/**
* Created by PhpStorm.
......@@ -710,6 +711,7 @@ class PerformanceService
$params = $this->getAgentIdPcInfo($id, $type, $start_time, $end_time);
//dump($params);
Log::write($params, 'marchInListPcInfo'); //记录日志
if (!$params)
return [ "code" => 101, "date" => "传入的参数错误" ];
$field = "a.id,c.user_name,c.user_phone,c.predict_see_time,c.report_agent_name,b.house_title,b.create_time,e.store_name,b.id as order_id";
......
......@@ -61,6 +61,13 @@ class Member extends Basic{
$type = 0;
$if_search_user = false;
//客方ID
$can_vip = true;
if (!empty($params['agent_id'])) {
$where['a.agent_id'] = $params['agent_id'];
$can_vip = false;
}
//APP状态
if (!empty($params['activate']) && $params['activate'] != -1) {
if ($params['activate'] == 1) {
......@@ -105,14 +112,17 @@ class Member extends Basic{
$where['a.create_time'] = ['between time', [$params['start_date']. ' 00:00:00', $params['end_date'] . ' 23:59:59']];
}else{
if (empty($params['id']) && empty($params['phone'])) {
//$time_ = date('Y-m-d H:i:s', strtotime("-1 day"));//根据create_time排除保护期客户-废弃
//$where['a.create_time'] = array( 'lt', $time_ );//根据create_time排除保护期客户-废弃
//排除排除保护期内的客户
$time_now = date('Y-m-d H:i:s');//当前时间
//protect_time 将截止日期大于当前时间的数据排除掉
$where['a.protect_time'] = array('lt',$time_now);
$where['a.site_ids'] = [ 'LIKE', '%' . $this->siteId . '%' ];//默认显示经纪人所在站点的客户
if($can_vip) {
//$time_ = date('Y-m-d H:i:s', strtotime("-1 day"));//根据create_time排除保护期客户-废弃
//$where['a.create_time'] = array( 'lt', $time_ );//根据create_time排除保护期客户-废弃
//排除排除保护期内的客户
$time_now = date('Y-m-d H:i:s');//当前时间
//protect_time 将截止日期大于当前时间的数据排除掉
$where['a.protect_time'] = array( 'lt', $time_now );
$where['a.site_ids'] = [ 'LIKE', '%' . $this->siteId . '%' ];//默认显示经纪人所在站点的客户
}
}
}
//是否登录过
......@@ -234,10 +244,7 @@ class Member extends Basic{
}
//客方ID
if (!empty($params['agent_id'])) {
$where['a.agent_id'] = $params['agent_id'];
}
if (!empty($params['first_login_start'])) {
$where['a.first_login_time'] = $params['first_login_start'] . ' 00:00:00';
......@@ -255,7 +262,9 @@ class Member extends Basic{
if ($params['vip'] == 1) {
$where['a.vip'] = 1;
} else {
$where['a.vip'] = 0;
if($can_vip){
$where['a.vip'] = 0;
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment