Commit 4413c840 authored by 赵啸非's avatar 赵啸非

删除人员同步同步删除考勤组人员

parent 9a7134df
......@@ -244,6 +244,7 @@ public class StaffServiceImpl extends AbstractCRUDCacheServiceImpl<StaffDao, Sta
}
}
}
staffEntity.setStatus(StaffSatusEnum.正式.getValue());
staffEntity.setName(personInfo.getPersonName());
staffEntity.setRemarkId(personInfo.getPersonId());
staffEntity.setPicUri(personInfo.getPersonPhoto() == null ? "" : personInfo.getPersonPhoto().getPicUri());
......@@ -255,6 +256,13 @@ public class StaffServiceImpl extends AbstractCRUDCacheServiceImpl<StaffDao, Sta
staffEntity.setUpdateUserId(1L);
staffEntity.setUpdateTime(new Date());
this.update(staffEntity);
StaffLeaveQuery staffLeaveQuery = new StaffLeaveQuery();
staffLeaveQuery.setWorkNum(staffEntity.getWorkNum());
StaffLeaveEntity staffLeaveEntity = staffLeaveService.selectOne(staffLeaveQuery, null);
if (!ObjectUtils.isEmpty(staffEntity)) {
staffLeaveService.remove(staffLeaveEntity.getId(), null);
}
}
}
......@@ -306,10 +314,10 @@ public class StaffServiceImpl extends AbstractCRUDCacheServiceImpl<StaffDao, Sta
// if (!ObjectUtils.isEmpty(attendanceGroupStaffEntities)) {
// attendanceGroupStaffService.removeList(attendanceGroupStaffEntities,context);
// }
Long[] groudStaffIds = attendanceGroupStaffService.find(new AttendanceGroupStaffQuery().staffId(staff.getId())).stream().map(i -> i.getId()).toArray(Long[]::new);
/* Long[] groudStaffIds = attendanceGroupStaffService.find(new AttendanceGroupStaffQuery().staffId(staff.getId())).stream().map(i -> i.getId()).toArray(Long[]::new);
if (!ObjectUtils.isEmpty(groudStaffIds)) {
attendanceGroupStaffService.remove(groudStaffIds, null);
}
}*/
}
});
}
......
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