|
|
@@ -53,12 +53,13 @@ public class ProjectStaffServiceImpl implements ProjectStaffService {
|
|
|
if (sum > 0) {
|
|
|
return AjaxResult.error("已存在打卡,请不要删除人员.");
|
|
|
}
|
|
|
- userMapper.updateUserProjectSum(in.getAid(),1);
|
|
|
+ ProjectStaff projectStaff = projectStaffMapper.selectByPrimaryKey(in.getId());
|
|
|
int i = projectStaffMapper.deleteByPrimaryKey(in.getId());
|
|
|
if (i>0){
|
|
|
- projectTaskMapper.updateStaffName(in.getPid());
|
|
|
+ projectTaskMapper.updateStaffName(projectStaff.getPid());
|
|
|
return AjaxResult.success();
|
|
|
}
|
|
|
+ userMapper.updateUserProjectSum(in.getAid(),1);
|
|
|
return AjaxResult.error("编号不存在");
|
|
|
}
|
|
|
|