puzhibing
2023-12-04 3ad6b6ba2ba56fc0bcd2130e47190779c6e15acc
cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml
@@ -96,6 +96,7 @@
        WHEN laveClassHours < 3 THEN 0
        ELSE 1
        END, insertTime DESC
    </select>
    <select id="queryRegistrationRecord1" resultType="map">
@@ -254,6 +255,20 @@
                LEFT JOIN t_competition  tc on pc.competitionId = tc.id
        WHERE pc.code=#{code}
    </select>
    <select id="queryRegistrationRecord3" resultType="java.util.Map">
        SELECT        CAST(id AS CHAR(20)) as id,
                      appUserId, studentId,
                      DATE_FORMAT(classDate, '%Y-%m-%d %H:%i') as insertTime,
                      DATE_FORMAT(DATE(MIN(classDate)), '%Y-%m-%d') AS totalClassHours,
                      DATE_FORMAT( DATE(MAX(endDate)), '%Y-%m-%d') AS laveClassHours,
            '' as absencesNumber,
            7 as status,
            3 as type
        FROM t_course_package_scheduling where type = 3
        GROUP BY coursePackageId, studentId;
    </select>
    <update id="updateBytime">
        update  t_course_package_payment