From ac31436a8da76a5388ff1700a34ea9247b8ec3d4 Mon Sep 17 00:00:00 2001 From: fengjin <1435304038@qq.com> Date: 星期四, 13 十月 2022 16:51:34 +0800 Subject: [PATCH] 1.修改bug 2.修改小程序修改相关代码 --- flower_city/src/main/java/com/dg/core/controller/GuideDoController.java | 36 +++++++++++++++++++++++++++++++++++- 1 files changed, 35 insertions(+), 1 deletions(-) diff --git a/flower_city/src/main/java/com/dg/core/controller/GuideDoController.java b/flower_city/src/main/java/com/dg/core/controller/GuideDoController.java index b61c89d..db3cc08 100644 --- a/flower_city/src/main/java/com/dg/core/controller/GuideDoController.java +++ b/flower_city/src/main/java/com/dg/core/controller/GuideDoController.java @@ -4,6 +4,7 @@ import com.dg.core.ResultData; import com.dg.core.annotation.Authorization; import com.dg.core.db.gen.entity.SysUser; +import com.dg.core.service.IGuideRepairOrderService; import com.dg.core.service.ISysUserService; import com.dg.core.util.Snowflake; import com.dg.core.util.TableDataInfo; @@ -11,6 +12,7 @@ import io.swagger.annotations.ApiOperation; import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.data.repository.query.Param; import org.springframework.util.Assert; import org.springframework.web.bind.annotation.*; @@ -27,6 +29,9 @@ @Autowired ISysUserService IUserService; + + @Autowired + IGuideRepairOrderService iGuideRepairOrderService; /** * 查询列表 @@ -72,6 +77,11 @@ return error("密码不能为空"); } + if(StringUtils.isEmpty(config.getPhonenumber())) + { + return error("手机号不能为空"); + } + if(StringUtils.isEmpty(config.getUserName())) { return error("昵称不能为空"); @@ -107,6 +117,12 @@ return error("userId不能为空"); } + if(StringUtils.isEmpty(config.getPhonenumber())) + { + return error("手机号不能为空"); + } + + if(StringUtils.isEmpty(config.getLoginName())) { return error("账户不能为空"); @@ -131,6 +147,13 @@ { return error("userId不能为空"); } + + int a=iGuideRepairOrderService.countUser(userId,"2"); + if(a>0) + { + return error("该人员有工单未处理完不能删除"); + } + return toAjax(IUserService.deleteConfigById(userId)); } @@ -167,8 +190,19 @@ @GetMapping("/selectListByDepartmentId") @Authorization public ResultData selectListByDepartmentId(@RequestParam("departmentId") String departmentId, - @RequestParam("classifyId") String classifyId){ + @RequestParam(value = "classifyId",required = false) String classifyId){ return ResultData.success(IUserService.selectListByDepartmentId(departmentId,classifyId)); } + /** + * 查询导办用户列表(不分页) + * @return 结果 + */ + @ApiOperation(" 查询导办用户列表(不分页)") + @GetMapping("/queryList") + @Authorization + public ResultData queryList(){ + return ResultData.success(IUserService.queryList(2)); + } + } -- Gitblit v1.7.1