统计换回

This commit is contained in:
2025-07-27 19:56:49 +08:00
parent 136445802d
commit 79906fbdef

View File

@@ -61,20 +61,17 @@
SELECT
IFNULL(count(1), 0) AS count
FROM (
select 1
FROM `t_stats_record` r
left join `t_stats` s on r.trace_id=s.trace_id
where r.trace_id in (select trace_id from `t_stats_record` where action = 'ENTER_SCENIC' and `identifier`=#{scenicId})
and action = 'PAYMENT'
and (identifier = 'PAY_REQ' or identifier = 'PAY_BATCH_REQ' or identifier = 'PAY_SOURCE_REQ' or identifier = 'PAY_BATCH_REQ')
select count(1) as count
from `order`
where scenic_id = #{scenicId}
<if test="startTime!= null">
and s.create_time >= #{startTime}
and create_at >= #{startTime}
</if>
<if test="endTime!= null">
and s.create_time &lt;= #{endTime}
and create_at &lt;= #{endTime}
</if>
group by s.member_id
) AS subquery;
group by member_id
)a
</select>
<select id="countPayOfMember" resultType="java.lang.Integer">
SELECT