南昌市物联网技防平台-后台
zengh
2021-06-01 cd2cfd37366002f790a2ed1435962d4eff7d5cec
blade-service/blade-jfpts/src/main/java/org/springblade/jfpt/attendance/mapper/AttendanceMapper.xml
@@ -55,5 +55,29 @@
        </if>
    </select>
    <!--查询当前考勤人员当天的考勤信息-->
    <select id="selAttendanceListNow" resultType="org.springblade.jfpt.attendance.entity.Attendance">
        select * from sys_attendance
            where
        number = #{number}
            and
        to_days(now())=to_days(clockTime)
            and
        is_deleted=0
    </select>
    <!--查询当前时间之前最新的一条数据-->
    <select id="selAttendanceNewNow" resultType="org.springblade.jfpt.attendance.entity.Attendance">
        select * from sys_attendance
            where
        number = #{number}
                    and
        to_days(now())=to_days(clockTime)
            and
        is_deleted=0
         order by clockTime desc
      limit 1
    </select>
</mapper>