正在显示
1 个修改的文件
包含
1 行增加
和
0 行删除
@@ -304,6 +304,7 @@ class Article extends BaseApi | @@ -304,6 +304,7 @@ class Article extends BaseApi | ||
304 | $data['user_id'] = $this->auth->id; | 304 | $data['user_id'] = $this->auth->id; |
305 | $data['zan_num'] = 0; | 305 | $data['zan_num'] = 0; |
306 | $res = model('article_comment')->create($data); | 306 | $res = model('article_comment')->create($data); |
307 | + $res = model('article_comment')->with(['user'])->where('id',$res)->find(); | ||
307 | //3.增加动态评论数据 | 308 | //3.增加动态评论数据 |
308 | model('article')->where('id',$data['article_id'])->setInc('ping_num'); | 309 | model('article')->where('id',$data['article_id'])->setInc('ping_num'); |
309 | Db::commit(); | 310 | Db::commit(); |
-
请 注册 或 登录 后发表评论