From 6eed001b1af4472ed9212dbd8eb6afd1760f58d5 Mon Sep 17 00:00:00 2001 From: xiepeng Date: Thu, 23 May 2024 15:56:56 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96BUG=20=20=E4=BA=BA=E5=91=98?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B=E4=B8=8D=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../OperatingVehiclesController.java | 3 --- .../controller/system/UsersController.java | 22 ++++++++++++++----- 2 files changed, 17 insertions(+), 8 deletions(-) diff --git a/src/main/java/com/zcloud/controller/operatingvehicles/OperatingVehiclesController.java b/src/main/java/com/zcloud/controller/operatingvehicles/OperatingVehiclesController.java index fa221a8..33b488e 100644 --- a/src/main/java/com/zcloud/controller/operatingvehicles/OperatingVehiclesController.java +++ b/src/main/java/com/zcloud/controller/operatingvehicles/OperatingVehiclesController.java @@ -221,9 +221,6 @@ public class OperatingVehiclesController extends BaseController { pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //企业ID page.setPd(pd); List varList = operatingVehiclesService.list(page); //列出Question列表 - - List dataInfo = new ArrayList<>(); - map.put("varList", varList); map.put("page", page); map.put("result", errInfo); diff --git a/src/main/java/com/zcloud/controller/system/UsersController.java b/src/main/java/com/zcloud/controller/system/UsersController.java index 7dea56c..80093e8 100644 --- a/src/main/java/com/zcloud/controller/system/UsersController.java +++ b/src/main/java/com/zcloud/controller/system/UsersController.java @@ -760,12 +760,14 @@ public class UsersController extends BaseController { @RequestMapping(value = "/hasEmail") @ResponseBody public Object hasEmail() throws Exception { - Map map = new HashMap(); + Map map = new HashMap(); String errInfo = "success"; PageData pd = new PageData(); pd = this.getPageData(); - if (usersService.findByEmail(pd) != null) { - errInfo = "fail"; + PageData byEmail = usersService.findByEmail(pd); + if (!ObjectUtil.isEmpty(byEmail)) { + map.put("pd", byEmail); + map.put("result", errInfo); } map.put("result", errInfo); //返回结果 return map; @@ -2767,6 +2769,12 @@ public class UsersController extends BaseController { if (pd.getString("PASSWORD") != null && !"".equals(pd.getString("PASSWORD"))) { pd.put("PASSWORD", new SimpleHash("SHA-1", pd.getString("USERNAME"), pd.getString("PASSWORD")).toString()); } + if(!StringUtils.isEmpty(pd.getString("periodStr"))) { + String[] periodStrs = pd.getString("periodStr").split(","); + pd.put("DURATION", periodStrs[0]); + pd.put("WORKSTATUS", periodStrs[1]); + pd.put("WORKPERIOD", periodStrs[2]); + } usersService.editUser(pd); //执行修改 if ("true".equals(pd.getString("ISSTUDENT"))) { /*if (!IdcardUtils.validateCard(pd.getString("USER_ID_CARD"))) { @@ -3028,8 +3036,12 @@ public class UsersController extends BaseController { userCorpList.get(0).put("ENTRY_DATE", pd.getString("ENTRY_DATE")); userCorpList.get(0).put("SHIFTDUTYONE", pd.getString("SHIFTDUTYONE")); userCorpList.get(0).put("SHIFTDUTYTWO", pd.getString("SHIFTDUTYTWO")); - - + if(!StringUtils.isEmpty(pd.getString("periodStr"))) { + String[] periodStrs = pd.getString("periodStr").split(","); + userCorpList.get(0).put("DURATION", periodStrs[0]); + userCorpList.get(0).put("WORKSTATUS", periodStrs[1]); + userCorpList.get(0).put("WORKPERIOD", periodStrs[2]); + } } } userCorpService.edit(userCorpList.get(0));