|
@@ -67,12 +67,13 @@ class WebSettingLogic extends BaseLogic |
|
@@ -67,12 +67,13 @@ class WebSettingLogic extends BaseLogic |
|
67
|
public function sendNotifyMessage(){
|
67
|
public function sendNotifyMessage(){
|
|
68
|
//获取当前项目所有未处理的更新并更换为1:处理中 2:处理完成
|
68
|
//获取当前项目所有未处理的更新并更换为1:处理中 2:处理完成
|
|
69
|
$updateNotifyModel = new UpdateNotify();
|
69
|
$updateNotifyModel = new UpdateNotify();
|
|
70
|
- $info = $updateNotifyModel->read(['project_id'=>$this->user['project_id'],'status'=>0]);
|
|
|
|
71
|
- if($info !== false){
|
|
|
|
72
|
- $this->fail('当前页面正在生成中,请勿重复点击');
|
70
|
+ $list = $updateNotifyModel->list(['project_id'=>$this->user['project_id'],'status'=>1]);
|
|
|
|
71
|
+ if(!empty($list)){
|
|
|
|
72
|
+ return $this->success($list);
|
|
73
|
}
|
73
|
}
|
|
74
|
$updateNotifyModel->edit(['status'=>1],['project_id'=>$this->user['project_id'],'status'=>0]);
|
74
|
$updateNotifyModel->edit(['status'=>1],['project_id'=>$this->user['project_id'],'status'=>0]);
|
|
75
|
$urlStr = $this->user['domain'].'api/updateHtmlNotify?project_id='.$this->user['project_id'];
|
75
|
$urlStr = $this->user['domain'].'api/updateHtmlNotify?project_id='.$this->user['project_id'];
|
|
76
|
- return $urlStr;
|
76
|
+ http_get($urlStr);
|
|
|
|
77
|
+ return $this->success();
|
|
77
|
}
|
78
|
}
|
|
78
|
} |
79
|
} |