diff --git a/src/main/java/com/msdw/tms/controller/SystemSettingController.java b/src/main/java/com/msdw/tms/controller/SystemSettingController.java index 0949acd..8ce92a7 100644 --- a/src/main/java/com/msdw/tms/controller/SystemSettingController.java +++ b/src/main/java/com/msdw/tms/controller/SystemSettingController.java @@ -106,7 +106,9 @@ public class SystemSettingController implements SystemSetttingApi { public R dalStaffByStaffGradeId(@RequestParam("staffGradeId") Integer staffGradeId){ //根据staffGradeId查询staff表中的userId,然后调用批量删除员工信息接口 List userIds = systemSetttingService.queryUserIdsByGradeId(staffGradeId); - systemSetttingService.daleteBatchStaff(userIds); + if(userIds.size()>0){ + systemSetttingService.daleteBatchStaff(userIds); + } return R.ok(); } @@ -118,7 +120,9 @@ public class SystemSettingController implements SystemSetttingApi { public R dalStaffByProfessionalId(@RequestParam("staffProfessionalArchitectureId") Integer staffProfessionalArchitectureId){ //根据staffGradeId查询staff表中的userId,然后调用批量删除员工信息接口 List userIds = systemSetttingService.queryUserIdsByProfessionalId(staffProfessionalArchitectureId); - systemSetttingService.daleteBatchStaff(userIds); + if(userIds.size()>0){ + systemSetttingService.daleteBatchStaff(userIds); + } return R.ok(); }