linwe
2024-09-03 764d883b5ea3bdc06abbec548b6df0511e567978
src/main/java/org/springblade/modules/nursingCheckIn/mapper/NursingCheckInMapper.xml
@@ -9,6 +9,21 @@
    <select id="selectNursingCheckInPage" resultMap="nursingCheckInResultMap">
        select * from jczz_nursing_check_in
        <where>
            <if test="nursingCheckIn.id != null ">and id = #{nursingCheckIn.id}</if>
            <if test="nursingCheckIn.createUser != null ">and create_user = #{nursingCheckIn.createUser}</if>
            <if test="nursingCheckIn.location != null  and nursingCheckIn.location != ''">and location = #{nursingCheckIn.location}</if>
            <if test="nursingCheckIn.name != null  and nursingCheckIn.name != ''">and name like concat('%',#{nursingCheckIn.name},'%')</if>
            <if test="nursingCheckIn.phone != null  and nursingCheckIn.phone != ''">and phone like concat('%',#{nursingCheckIn.phone},'%')</if>
            <if test="nursingCheckIn.gradeAndClass != null  and nursingCheckIn.gradeAndClass != ''">and grade_and_class = #{nursingCheckIn.gradeAndClass}</if>
            <if test="nursingCheckIn.images != null  and nursingCheckIn.images != ''">and images = #{nursingCheckIn.images}</if>
            <if test="nursingCheckIn.placeId != null ">and place_id = #{nursingCheckIn.placeId}</if>
            <if test="nursingCheckIn.type != null  and nursingCheckIn.type != ''">and type = #{nursingCheckIn.type}</if>
            <if test="nursingCheckIn.startTime != null and nursingCheckIn.startTime != '' and nursingCheckIn.endTime != null and nursingCheckIn.endTime != '' ">
                AND create_time BETWEEN #{nursingCheckIn.startTime} and #{nursingCheckIn.endTime}
            </if>
        </where>
        order by id desc
    </select>