无关风月
2025-04-03 1c842d5a1880469bf1af7067a5c194ae26c3f80d
cloud-server-activity/src/main/resources/mapper/PayHuiminMapper.xml
@@ -10,20 +10,16 @@
        thc.huiMinType,
        thc.salesMoney,
        thc.operatorId,
        thc.storeId,
        thc.storeIds,
        tph.appUserId,
        tph.paymentTime,
        thc.endTime,
        tph.studentId,
        tph.status,
        CASE
        WHEN tph.id IS NULL THEN NULL
        ELSE COALESCE(COUNT(thr.id), 0)
        END AS useTimes
        thc.id as carId,
        tph.status
        FROM
        t_pay_huimin tph
        LEFT JOIN t_huimin_card thc ON tph.cardId = thc.id
        LEFT JOIN t_huimin_record thr ON tph.appUserId= thr.appUserId AND tph.cardId= thr.huiminCardId
        <where>
            tph.id IS NOT NULL
            <if test="query.huiMinName !=null and query.huiMinName != ''">
@@ -63,7 +59,9 @@
                    </when>
                </choose>
            </if>
        and tph.status!=1
        </where>
        ORDER BY tph.insertTime DESC
    </select>
    <select id="getStaticsData" resultType="java.util.Map"