server/src/main/java/doumeemes/biz/system/impl/SystemUserBizImpl.java
@@ -541,6 +541,14 @@ CompanyUser cu = new CompanyUser(); cu.setDeleted(Constants.ZERO); cu.setRootDepartId(loginUser.getRootDepartment().getId()); //限制人数 int limitUserNum = Constants.formatIntegerNum(loginUser.getCompany().getOpenUserNum()); if(limitUserNum > 0){ //人数限制输入0,表示不限制人数 if(companyUserExtMapper.selectCount(new QueryWrapper<>(cu)) +1 > limitUserNum ){ throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"用户数量超过购买数量,请联系业务经理续购!"); } } if(user ==null){ //如果用户账号不存在,新增用户 // 生成密码盐