From c45dffa0a0071ca3049efecd353d6fb95825840e Mon Sep 17 00:00:00 2001
From: Jerry Yan <792602257@qq.com>
Date: Wed, 30 Apr 2025 18:28:36 +0800
Subject: [PATCH] =?UTF-8?q?=E7=BB=9F=E8=AE=A1=E4=BF=AE=E4=B8=80=E4=BF=AE?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 src/main/resources/mapper/StatisticsMapper.xml | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/src/main/resources/mapper/StatisticsMapper.xml b/src/main/resources/mapper/StatisticsMapper.xml
index 5796f90..a149fa8 100644
--- a/src/main/resources/mapper/StatisticsMapper.xml
+++ b/src/main/resources/mapper/StatisticsMapper.xml
@@ -165,16 +165,17 @@
         select ifnull(count(1),0) as count
         from(
             select 1
-            from member_video mv
-            left join face f on f.id = mv.face_id
+            from video v
+            left join task t on v.task_id = t.id
+            left join face f on f.id = t.face_id
             where f.scenic_id = #{scenicId}
             <if test="startTime!= null">
-                and mv.create_time >= #{startTime}
+                and v.create_time >= #{startTime}
             </if>
             <if test="endTime!= null">
-                and mv.create_time &lt;= #{endTime}
+                and v.create_time &lt;= #{endTime}
             </if>
-            group by mv.member_id
+            group by f.member_id
         )a
     </select>
     <select id="countTotalVisitorOfMember" resultType="java.lang.Integer">