@ -185,6 +185,19 @@ class Message extends ApiCommon
cache('checkBusinessCount' . $userInfo['id'], $data['checkBusiness']);
cache('checkBusinessCount' . $userInfo['id'], $data['checkBusiness']);
cache('checkBusinessTime' . $userInfo['id'], time());
cache('checkBusinessTime' . $userInfo['id'], time());
}
}
# 待审核客户捞取
$checkCustomerCheckTime = cache('$checkCustomerCheckTime' . $userInfo['id']);
$checkCustomerCheckCount = cache('checkCustomerCheckCount' . $userInfo['id']);
if (time() < = $checkCustomerCheckTime) {
$data['checkCustomerCheck'] = (int)$checkCustomerCheckCount;
} else {
$checkCustomerCheck = $this->checkCustomerCheck(true);
$data['checkCustomerCheck'] = $checkCustomerCheck['dataCount'] ?: 0;
cache('checkCustomerCheckCount' . $userInfo['id'], $data['checkCustomerCheck']);
cache('$checkCustomerCheckTime' . $userInfo['id'], time());
}
# 待回款提醒
# 待回款提醒
$remindReceivablesPlanTime = cache('remindReceivablesPlanTime' . $userInfo['id']);
$remindReceivablesPlanTime = cache('remindReceivablesPlanTime' . $userInfo['id']);
$remindReceivablesPlanCount = cache('remindReceivablesPlanCount' . $userInfo['id']);
$remindReceivablesPlanCount = cache('remindReceivablesPlanCount' . $userInfo['id']);
@ -461,6 +474,29 @@ class Message extends ApiCommon
return $data;
return $data;
}
}
/**
* 待审核客户捞取
*
* @return array|\think\response\Json
* @throws \think\exception\DbException
*/
public function checkCustomerCheck($getCount = false)
{
$param = $this->param;
$userId = $this->userInfo['id'];
$types = $param['types'];
if ($getCount == true) $param['getCount'] = 1;
# 清除与模型无关的数据
unset($param['types']);
$param['user_id'] = $userId;
$messageLogic = new MessageLogic();
$data = $messageLogic->checkCustomerCheck($param);
if ($types == 'list') return resultArray(['data' => $data]);
return $data;
}
/**
/**
* 待回款提醒
* 待回款提醒
* @return
* @return