From eec8e82f315113023d223f124cd10ff76107e8d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8E=E8=82=96=E7=A3=8A?= <18851179580@163.com> Date: Fri, 13 Feb 2026 10:23:01 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=88=A0=E9=99=A4=E8=AF=84?= =?UTF-8?q?=E8=AE=BA=E4=B9=8B=E5=90=8E=E7=9A=84=E6=98=BE=E7=A4=BA=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/plugins/video/detail/detail.vue | 15 ++++++++++++--- pages/plugins/video/index/index.vue | 2 +- pages/plugins/video/search/search.vue | 2 +- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/pages/plugins/video/detail/detail.vue b/pages/plugins/video/detail/detail.vue index cf1d387b..bd589cbf 100644 --- a/pages/plugins/video/detail/detail.vue +++ b/pages/plugins/video/detail/detail.vue @@ -1390,16 +1390,25 @@ // 更新子评论数组 comment.sub_comments = filteredSubComments; filteredComments.push(comment); - } + } + comment.comments_count = filteredSubComments.length; // 如果没有子评论且没有内容,则不添加这个父级评论 } else { // 没有子评论的情况,直接保留父级评论 filteredComments.push(comment); } } - + // 删除之后更新评论数据 + this.video_data_list.forEach(item => { + if (item.id == this.current_video_id) { + item.comments_count = filteredComments.length; + } + }) // 更新active_comments - this.active_comments = filteredComments; + this.setData({ + active_comments: filteredComments, + video_data_list: this.video_data_list + }) } }, // 处理全局点击事件 diff --git a/pages/plugins/video/index/index.vue b/pages/plugins/video/index/index.vue index 5d241464..c5bd22ea 100644 --- a/pages/plugins/video/index/index.vue +++ b/pages/plugins/video/index/index.vue @@ -36,7 +36,7 @@ {{ item.add_time_date }} - {{ item.access_count }} + {{ item.give_thumbs_count }} diff --git a/pages/plugins/video/search/search.vue b/pages/plugins/video/search/search.vue index 6da1777b..2b2b9ad3 100644 --- a/pages/plugins/video/search/search.vue +++ b/pages/plugins/video/search/search.vue @@ -40,7 +40,7 @@ {{ item.add_time_date }} - {{ item.access_count }} + {{ item.give_thumbs_count }}