Commit 9637d40a authored by hujun's avatar hujun

开盘排序

parent c5dc05fd
......@@ -22,15 +22,17 @@ class BSquareSort extends BaseModel
* @param $data
* @param $id
* @param array $where
* @return mixed
* @return int|string
* @throws \think\Exception
* @throws \think\exception\PDOException
* User HuJun
* Date 19-5-7 下午5:54
* Date 19-5-8 上午10:03
*/
public function updateData($data, $id, $where = []) {
if ($id > 0) {
$where['id'] = $id;
}
return $this->db_->where($where)->upate($data);
return $this->db_->where($where)->update($data);
}
/**
......
......@@ -633,7 +633,7 @@ Route::group('task', [
'moveFollowUpList' => ['task/FollowUpTask/moveFollowUpList', ['method' => 'get']],
'frostAgent' => ['task/FrostAgentTask/frostAgent', ['method' => 'get']],
'squareBackUp' => ['task/squareBackUp/readRedis', ['method' => 'get']],
'squareBackUp' => ['task/SquareTask/squareBackUp', ['method' => 'get']], //redis备份开盘排序
'updateActivityStatus' => ['task/UpdateActivityTask/updateActivityStatus', ['method' => 'get']],
......
......@@ -23,13 +23,17 @@ class SquareTask
$sort_service = new SquareSortService();
$look_num = $sort_service->getLookData(); //看盘数量
foreach ($look_num as $k=>$v) {
$square_id[] = $k;
if ($look_num) {
foreach ($look_num as $k=>$v) {
$square_id[] = $k;
}
}
$comment = $sort_service->getCommentData();//最后评论时间
foreach ($comment as $k=>$v) {
$square_id[] = $k;
if ($comment) {
foreach ($comment as $k=>$v) {
$square_id[] = $k;
}
}
if (empty($square_id)) {
......
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