正在显示
4 个修改的文件
包含
5 行增加
和
2 行删除
| @@ -48,6 +48,7 @@ class AiBlogController extends BaseController | @@ -48,6 +48,7 @@ class AiBlogController extends BaseController | ||
| 48 | 'id.required' => '主键不能为空', | 48 | 'id.required' => '主键不能为空', |
| 49 | ]); | 49 | ]); |
| 50 | $info = $aiBlog->read(['id'=>$this->param['id']]); | 50 | $info = $aiBlog->read(['id'=>$this->param['id']]); |
| 51 | + $info['anchor'] = json_decode($info['anchor'] ?? [],true); | ||
| 51 | $info['image'] = getImageUrl($info['image']); | 52 | $info['image'] = getImageUrl($info['image']); |
| 52 | $this->response('success',Code::SUCCESS,$info); | 53 | $this->response('success',Code::SUCCESS,$info); |
| 53 | } | 54 | } |
| @@ -52,6 +52,8 @@ class AiVideoController extends BaseController | @@ -52,6 +52,8 @@ class AiVideoController extends BaseController | ||
| 52 | 'id.required' => '主键不能为空', | 52 | 'id.required' => '主键不能为空', |
| 53 | ]); | 53 | ]); |
| 54 | $info = $aiVideo->read(['id'=>$this->param['id']]); | 54 | $info = $aiVideo->read(['id'=>$this->param['id']]); |
| 55 | + $info['anchor'] = json_decode($info['anchor'] ?? [],true); | ||
| 56 | + $info['images'] = json_decode($info['images'] ?? [],true); | ||
| 55 | $this->response('success',Code::SUCCESS,$info); | 57 | $this->response('success',Code::SUCCESS,$info); |
| 56 | } | 58 | } |
| 57 | 59 |
| @@ -58,7 +58,7 @@ class AiBlogLogic extends BaseLogic | @@ -58,7 +58,7 @@ class AiBlogLogic extends BaseLogic | ||
| 58 | } | 58 | } |
| 59 | $this->param['route'] = RouteMap::setRoute($this->param['route'], RouteMap::SOURCE_AI_BLOG, $this->param['id'], $this->user['project_id']); | 59 | $this->param['route'] = RouteMap::setRoute($this->param['route'], RouteMap::SOURCE_AI_BLOG, $this->param['id'], $this->user['project_id']); |
| 60 | $anchor = $this->param['anchor'] ?? []; | 60 | $anchor = $this->param['anchor'] ?? []; |
| 61 | - $this->param['anchor'] = json_encode($this->param['anchor'],true); | 61 | + $this->param['anchor'] = json_encode($anchor,true); |
| 62 | $this->model->edit($this->param,['id'=>$this->param['id']]); | 62 | $this->model->edit($this->param,['id'=>$this->param['id']]); |
| 63 | $aiSettingInfo = $this->getProjectAiSetting(); | 63 | $aiSettingInfo = $this->getProjectAiSetting(); |
| 64 | $aiBlogService = new AiBlogService(); | 64 | $aiBlogService = new AiBlogService(); |
| @@ -41,7 +41,7 @@ class AiVideoLogic extends BaseLogic | @@ -41,7 +41,7 @@ class AiVideoLogic extends BaseLogic | ||
| 41 | try { | 41 | try { |
| 42 | $this->param['route'] = RouteMap::setRoute($this->param['route'], RouteMap::SOURCE_AI_VIDEO, $this->param['id'], $this->user['project_id']); | 42 | $this->param['route'] = RouteMap::setRoute($this->param['route'], RouteMap::SOURCE_AI_VIDEO, $this->param['id'], $this->user['project_id']); |
| 43 | $anchor = $this->param['anchor'] ?? []; | 43 | $anchor = $this->param['anchor'] ?? []; |
| 44 | - $this->param['anchor'] = json_encode($this->param['anchor'],true); | 44 | + $this->param['anchor'] = json_encode($anchor,true); |
| 45 | $this->param['images'] = json_encode($this->param['images'],true); | 45 | $this->param['images'] = json_encode($this->param['images'],true); |
| 46 | $this->model->edit($this->param,['id'=>$this->param['id']]); | 46 | $this->model->edit($this->param,['id'=>$this->param['id']]); |
| 47 | $aiVideoService = new AiVideoService($this->user['project_id']); | 47 | $aiVideoService = new AiVideoService($this->user['project_id']); |
-
请 注册 或 登录 后发表评论