正在显示
1 个修改的文件
包含
2 行增加
和
2 行删除
| @@ -268,10 +268,10 @@ class ProductController extends BaseController | @@ -268,10 +268,10 @@ class ProductController extends BaseController | ||
| 268 | $this->response('关键词不能为空', Code::SYSTEM_ERROR); | 268 | $this->response('关键词不能为空', Code::SYSTEM_ERROR); |
| 269 | } | 269 | } |
| 270 | $project_id = ProjectAiSetting::where('mch_id', $mch_id)->where('key', $key)->value('project_id'); | 270 | $project_id = ProjectAiSetting::where('mch_id', $mch_id)->where('key', $key)->value('project_id'); |
| 271 | - if($project_id){ | 271 | + if(!$project_id){ |
| 272 | $this->response('项目不存在', Code::SYSTEM_ERROR); | 272 | $this->response('项目不存在', Code::SYSTEM_ERROR); |
| 273 | } | 273 | } |
| 274 | - | 274 | + |
| 275 | ProjectServer::useProject($project_id); | 275 | ProjectServer::useProject($project_id); |
| 276 | 276 | ||
| 277 | $product = Product::whereFullText('title', $keyword)->inRandomOrder()->select(['title', 'intro', 'thumb'])->first(); | 277 | $product = Product::whereFullText('title', $keyword)->inRandomOrder()->select(['title', 'intro', 'thumb'])->first(); |
-
请 注册 或 登录 后发表评论