wupengfei 2 年之前
父节点
当前提交
40002fd372
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      application/api/controller/Video.php

+ 2 - 1
application/api/controller/Video.php

@@ -444,11 +444,12 @@ class Video extends Base
         unset($comment['id']);
         unset($comment['create_at']);
         $comment['pid'] = input('post.id');
+        $comment['user_id'] = $this->user_id;
         $comment['content'] = input('post.content');
         $comment['lev']++;
         if(!$comment['source_id']) $comment['source_id'] = input('post.id');
         $res = VideoComment::create($comment);
-        $detail  =VideoComment::where('c.id',$res->id)
+        $detail  = VideoComment::where('c.id',$res->id)
             ->alias('c')
             ->field('c.id,c.content,c.create_at,u.name,u.headimg')
             ->leftJoin('store_member u','u.id = c.user_id')