| | |
| | | Result<SysUser> result = new Result<SysUser>(); |
| | | String selectedRoles = jsonObject.getString("selectedroles"); |
| | | String selectedDeparts = jsonObject.getString("selecteddeparts"); |
| | | String selectedProductions = jsonObject.getString("selectedProduction"); |
| | | String selectedProductions = jsonObject.getString("selectedFactorys"); |
| | | try { |
| | | SysUser user = JSON.parseObject(jsonObject.toJSONString(), SysUser.class); |
| | | user.setCreateTime(new Date());//设置创建时间 |
| | |
| | | user.setPassword(sysUser.getPassword()); |
| | | String roles = jsonObject.getString("selectedroles"); |
| | | String departs = jsonObject.getString("selecteddeparts"); |
| | | String productions = jsonObject.getString("selectedProduction"); |
| | | String productions = jsonObject.getString("selectedFactorys"); |
| | | if (oConvertUtils.isEmpty(departs)) { |
| | | //vue3.0前端只传递了departIds |
| | | departs = user.getDepartIds(); |
| | |
| | | |
| | | } |
| | | |
| | | @AutoLog(value = "用户表-查询指定用户和产线关联的数据") |
| | | @ApiOperation(value = "用户表-查询指定用户和产线关联的数据", notes = "用户表-查询指定用户和产线关联的数据") |
| | | @GetMapping(value = "/userProductionList") |
| | | public Result<List<ProductionIdModel>> getUserProductionsList(@RequestParam(name = "userId", required = true) String userId) { |
| | | Result<List<ProductionIdModel>> result = new Result<>(); |
| | | @AutoLog(value = "用户表-查询指定用户和工厂建模关联的数据") |
| | | @ApiOperation(value = "用户表-查询指定用户和工厂建模关联的数据", notes = "用户表-查询指定用户和工厂建模关联的数据") |
| | | @GetMapping(value = "/userFactorysList") |
| | | public Result<List<FactoryIdModel>> getUserFactorysList(@RequestParam(name = "userId", required = true) String userId) { |
| | | Result<List<FactoryIdModel>> result = new Result<>(); |
| | | try { |
| | | List<ProductionIdModel> proIdModelList = this.userProductionService.queryProductionIdsOfUser(userId); |
| | | if (proIdModelList != null && !proIdModelList.isEmpty()) { |
| | | List<FactoryIdModel> facIdModelList = this.userFactoryService.queryFactoryIdsOfUser(userId); |
| | | if (facIdModelList != null && !facIdModelList.isEmpty()) { |
| | | result.setSuccess(true); |
| | | result.setMessage("查找成功"); |
| | | result.setResult(proIdModelList); |
| | | result.setResult(facIdModelList); |
| | | } else { |
| | | result.setSuccess(false); |
| | | result.setMessage("查找失败"); |