正在显示
1 个修改的文件
包含
6 行增加
和
5 行删除
| @@ -40,9 +40,10 @@ class CNoticeController extends BaseController | @@ -40,9 +40,10 @@ class CNoticeController extends BaseController | ||
| 40 | if (FALSE == in_array($type, [UpdateNotify::PAGE_ALL, UpdateNotify::PAGE_SINGLE])){ | 40 | if (FALSE == in_array($type, [UpdateNotify::PAGE_ALL, UpdateNotify::PAGE_SINGLE])){ |
| 41 | $this->response('非法参数!', Code::USER_ERROR); | 41 | $this->response('非法参数!', Code::USER_ERROR); |
| 42 | } | 42 | } |
| 43 | - $list = $this->sendNotifyMessage($type,$page); | ||
| 44 | - if(!empty($list)){ | ||
| 45 | - $this->response('当前页面正在生成了,请完成后再点击',Code::USER_ERROR,$list); | 43 | + $data = $this->sendNotifyMessage($type,$page); |
| 44 | + @file_put_contents(storage_path('logs/lyh_error.log'), var_export($data, true) . PHP_EOL, FILE_APPEND); | ||
| 45 | + if(!empty($data)){ | ||
| 46 | + $this->response('当前页面正在生成了,请完成后再点击',Code::USER_ERROR,$data); | ||
| 46 | } | 47 | } |
| 47 | $this->response('success'); | 48 | $this->response('success'); |
| 48 | } | 49 | } |
| @@ -73,7 +74,7 @@ class CNoticeController extends BaseController | @@ -73,7 +74,7 @@ class CNoticeController extends BaseController | ||
| 73 | if($count == 0){ | 74 | if($count == 0){ |
| 74 | return $this->success(); | 75 | return $this->success(); |
| 75 | } | 76 | } |
| 76 | - $this->addProgress($count,$type); | 77 | +// $this->addProgress($count,$type); |
| 77 | $updateNotifyModel->edit([$field => 1], ['project_id' => $this->user['project_id'], $field => 0]); | 78 | $updateNotifyModel->edit([$field => 1], ['project_id' => $this->user['project_id'], $field => 0]); |
| 78 | $urlStr = $this->getString($type,$page); | 79 | $urlStr = $this->getString($type,$page); |
| 79 | $this->curlGet($urlStr); | 80 | $this->curlGet($urlStr); |
| @@ -119,7 +120,7 @@ class CNoticeController extends BaseController | @@ -119,7 +120,7 @@ class CNoticeController extends BaseController | ||
| 119 | 'created_at'=>date('Y-m-d H;i:s') | 120 | 'created_at'=>date('Y-m-d H;i:s') |
| 120 | ]; | 121 | ]; |
| 121 | $updateProgressModel = new UpdateProgress(); | 122 | $updateProgressModel = new UpdateProgress(); |
| 122 | - $updateProgressModel->insert($data); | 123 | + return $updateProgressModel->insert($data); |
| 123 | } | 124 | } |
| 124 | 125 | ||
| 125 | /** | 126 | /** |
-
请 注册 或 登录 后发表评论