合并分支 'zhl' 到 'master'
处理bug 查看合并请求 !2817
正在显示
1 个修改的文件
包含
2 行增加
和
0 行删除
| @@ -608,6 +608,8 @@ class PrivateController extends BaseController | @@ -608,6 +608,8 @@ class PrivateController extends BaseController | ||
| 608 | public function getExternalLink(Request $request) | 608 | public function getExternalLink(Request $request) |
| 609 | { | 609 | { |
| 610 | $max_id = DB::table('gl_project_external_link_make')->where(['status' => 0])->max('id'); | 610 | $max_id = DB::table('gl_project_external_link_make')->where(['status' => 0])->max('id'); |
| 611 | + if (empty($max_id)) | ||
| 612 | + return $this->success(); | ||
| 611 | $links = DB::table('gl_project_external_link_make')->where(['status' => 0])->where('id', '<=', $max_id)->pluck('external_link')->toArray(); | 613 | $links = DB::table('gl_project_external_link_make')->where(['status' => 0])->where('id', '<=', $max_id)->pluck('external_link')->toArray(); |
| 612 | DB::table('gl_project_external_link_make')->where(['status' => 0])->where('id', '<=', $max_id)->update(['status' => 1, 'updated_at' => date('Y-m-d H:i;s')]); | 614 | DB::table('gl_project_external_link_make')->where(['status' => 0])->where('id', '<=', $max_id)->update(['status' => 1, 'updated_at' => date('Y-m-d H:i;s')]); |
| 613 | return $this->success($links); | 615 | return $this->success($links); |
-
请 注册 或 登录 后发表评论