| | |
| | | if(coursePhase.getCompanyId()!=null&&!currentUser.getCompanyId().equals(coursePhase.getCompanyId())){ |
| | | throw new ApiException("没有权限操作其他企业批次"); |
| | | } |
| | | int level=coursePhase.getLevel(); |
| | | if((level==1 ||level==4) && currentUser.getUserType()>UserTypeEnum.COMPANY_USER.getCode()){ |
| | | throw new ApiException("当前账户无权限新增公司级批次"); |
| | | } |
| | | if(level==2 && currentUser.getUserType()>UserTypeEnum.DEPART_USER.getCode()){ |
| | | throw new ApiException("当前账户无权限新增事业部级级批次"); |
| | | } |
| | | // int level=coursePhase.getLevel(); |
| | | // if((level==1 ||level==4) && (currentUser.getUserType().equals(UserTypeEnum.COMPANY_USER.getCode()) |
| | | // || currentUser.getUserType().equals(UserTypeEnum.COMPANY_ADMIN.getCode()) |
| | | // || currentUser.getUserType().equals(UserTypeEnum.SYSTEM_USER.getCode()) ) ){ |
| | | // throw new ApiException("当前账户无权限新增公司级批次"); |
| | | // } |
| | | // if(level==2 && currentUser.getUserType()>UserTypeEnum.DEPART_USER.getCode()){ |
| | | // throw new ApiException("当前账户无权限新增事业部级级批次"); |
| | | // } |
| | | } |
| | | |
| | | |