Commit 294bdfc7 authored by 赵啸非's avatar 赵啸非

整理代码

parent 122588ea
......@@ -465,16 +465,18 @@ public class FixWorkOtherAttendance extends AttendanceWorkAbstract {
private void deleteErrorRecordCache(Long staffId, Context context) {
//删除当前员工当日未处理的异常后,重新添加
List<AttendanceRecordErrorEntity> attendanceRecordErrorEntities = commonData.getErrorGroupStaffMap().get(staffId);
Long[] errorIds = attendanceRecordErrorEntities.stream()
.filter(f -> YesNoEnum.NO.getValue() == f.getProcessStatus())
.map(i -> i.getId()).toArray(Long[]::new);
if (!ObjectUtils.isEmpty(errorIds)) {
//log.info("删除 {} 人员:{} 异常记录:{}",dateStr,staffId, JSON.toJSONString(attendanceRecordErrorEntities));
StopWatch stopWatch = new StopWatch();
stopWatch.start("删除异常记录耗时");
errorService.remove(errorIds, context);
stopWatch.stop();
log.info("删除异常记录耗时:{}ms", stopWatch.getLastTaskTimeMillis());
if (!ObjectUtils.isEmpty(attendanceRecordErrorEntities)) {
Long[] errorIds = attendanceRecordErrorEntities.stream()
.filter(f -> YesNoEnum.NO.getValue() == f.getProcessStatus())
.map(i -> i.getId()).toArray(Long[]::new);
if (!ObjectUtils.isEmpty(errorIds)) {
//log.info("删除 {} 人员:{} 异常记录:{}",dateStr,staffId, JSON.toJSONString(attendanceRecordErrorEntities));
StopWatch stopWatch = new StopWatch();
stopWatch.start("删除异常记录耗时");
errorService.remove(errorIds, context);
stopWatch.stop();
log.info("删除异常记录耗时:{}ms", stopWatch.getLastTaskTimeMillis());
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment