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

+ 1 - 1
.idea/workspace.xml

@@ -201,7 +201,7 @@
       <workItem from="1670461023846" duration="27678000" />
       <workItem from="1670547445908" duration="12147000" />
       <workItem from="1670633686675" duration="15717000" />
-      <workItem from="1670719843429" duration="3135000" />
+      <workItem from="1670719843429" duration="3207000" />
     </task>
     <servers />
   </component>

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

@@ -928,9 +928,9 @@ class Video extends Base
     {
         // 回复我的
         $all_comment = VideoComment::where(['user_id'=>$this->user_id,'is_deleted'=>0])->column('id');
-        $reply_num =  VideoComment::where([['t.is_deleted','=',0],['t.lev','>=',2],['is_read'=>0],['t.pid','in',implode(',',$all_comment)]])->alias('t')->count();
+        $reply_num =  VideoComment::where([['t.is_deleted','=',0],['t.lev','>=',2],['is_read','=',0],['t.pid','in',implode(',',$all_comment)]])->alias('t')->count();
         // 评论我的
-        $comment_num = VideoComment::where([['t.is_deleted','=',0],['i.user_id','=',$this->user_id],['is_read'=>0]])
+        $comment_num = VideoComment::where([['t.is_deleted','=',0],['i.user_id','=',$this->user_id],['is_read','=',0]])
             ->leftJoin('VideoUrl i','t.url_id = i.id')
             ->alias('t')->count();
         $this->success('ok',compact(['reply_num','comment_num']));