| | |
| | | /** |
| | | * 新增用户 |
| | | * |
| | | * @param config 参数配置信息 |
| | | * @param config 参数配置信息- |
| | | * @return 结果 |
| | | */ |
| | | @ApiOperation("新增导办用户接口") |
| | |
| | | if(StringUtils.equals("1",config.getIsDivisionHead())) |
| | | { |
| | | user.setRoleIds("13"); |
| | | if(StringUtils.isEmpty(config.getDataPermission())) { |
| | | user.setDataPermission(config.getMoreDepartmentIds()); |
| | | } |
| | | } |
| | | else |
| | | { |
| | | if(StringUtils.isEmpty(config.getDataPermission())) { |
| | | user.setDataPermission(config.getDepartmentId()); |
| | | } |
| | | user.setRoleIds("2"); |
| | | } |
| | | user.setUserType("2"); |
| | |
| | | if(StringUtils.equals("1",config.getIsDivisionHead())) |
| | | { |
| | | config.setRoleIds("13"); |
| | | if(StringUtils.isEmpty(config.getDataPermission())) { |
| | | config.setDataPermission(config.getMoreDepartmentIds()); |
| | | } |
| | | } |
| | | else |
| | | { |
| | | if(StringUtils.isEmpty(config.getDataPermission())) { |
| | | config.setDataPermission(config.getDepartmentId()); |
| | | } |
| | | config.setRoleIds("2"); |
| | | } |
| | | config.setCreateBy(sysUser.getUserId()); |
| | |
| | | if (config.getMoreDepartmentIds()!=null&&config.getMoreDepartmentIds().indexOf(",")>0) |
| | | config.setDataPermission(config.getMoreDepartmentIds().substring(config.getMoreDepartmentIds().indexOf(",")+1)); |
| | | else |
| | | { |
| | | config.setDataPermission("0"); |
| | | } |
| | | |
| | | config.setRoleIds("13"); |
| | | } |
| | | else |
| | | { |
| | | if(StringUtils.isEmpty(config.getDataPermission())) { |
| | | config.setDataPermission(config.getDepartmentId()); |
| | | } |
| | | config.setRoleIds("2"); |
| | | } |
| | | |