Commit 438ce87f authored by 廖旭伟's avatar 廖旭伟

修改bug

parent ec8f173b
...@@ -86,17 +86,18 @@ public class ApproverServiceImpl extends AbstractCRUDServiceImpl<ApproverDao, Ap ...@@ -86,17 +86,18 @@ public class ApproverServiceImpl extends AbstractCRUDServiceImpl<ApproverDao, Ap
@Override @Override
public String getDeptCodeByUser(Long userId) throws AppException { public String getDeptCodeByUser(Long userId) throws AppException {
UserEntity userEntity = userService.get(userId); // UserEntity userEntity = userService.get(userId);
if(userEntity==null){ // if(userEntity==null){
throw new AppException("用户id不正确,找不到对应的用户信息"); // throw new AppException("用户id不正确,找不到对应的用户信息");
} // }
ApproverEntity approverEntity = this.selectOne(new ApproverQuery().loginName(userEntity.getLoginName())); // ApproverEntity approverEntity = this.selectOne(new ApproverQuery().loginName(userEntity.getLoginName()));
if(approverEntity==null){ // if(approverEntity==null){
throw new AppException("该用户不是预审工作人员"); // throw new AppException("该用户不是预审工作人员");
} // }
if(StringUtils.isEmpty(approverEntity.getDeptCode())){ // if(StringUtils.isEmpty(approverEntity.getDeptCode())){
throw new AppException("该工作人员没有配置管辖部门"); // throw new AppException("该工作人员没有配置管辖部门");
} // }
return approverEntity.getDeptCode(); // return approverEntity.getDeptCode();
return null;
} }
} }
\ No newline at end of file
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