From 038b07af21f18b9ab428cef7381d1680495b0925 Mon Sep 17 00:00:00 2001 From: limingyu Date: Wed, 3 Apr 2024 16:34:03 +0800 Subject: [PATCH 01/26] =?UTF-8?q?=E6=95=B4=E5=90=88app=E7=99=BB=E5=BD=95?= =?UTF-8?q?=E5=90=8E=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/resources/application-master.properties | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/resources/application-master.properties b/src/main/resources/application-master.properties index b0c2ac96..8cb8b781 100644 --- a/src/main/resources/application-master.properties +++ b/src/main/resources/application-master.properties @@ -85,8 +85,8 @@ mq.group.info=scheduled_tasks mq.group.eightWork=scheduled_tasks_eightWork -corp.default.pic-path=http://192.168.192.201:8991/file/ -corp.default.back-end-path=https://skqhdg.porthebei.com:9004/file/ +corp.default.pic-path=https://skqhdg.porthebei.com:9004/file/ +corp.default.back-end-path=https://skqhdg.porthebei.com:9004/qa-prevention-gwj/ #数据同步topic mq.gwj.data.topic=czks_docking mq.gwj.file.topic=czks_dockingPicture From 0ca31180b38a63d624a1f21b5b8a1198a7114401 Mon Sep 17 00:00:00 2001 From: limingyu Date: Tue, 9 Apr 2024 15:28:46 +0800 Subject: [PATCH 02/26] =?UTF-8?q?=E6=B6=88=E9=98=B2=E5=99=A8=E6=9D=90?= =?UTF-8?q?=E6=89=B9=E9=87=8F=E5=AF=BC=E5=85=A5=E6=97=B6=E6=B6=88=E9=98=B2?= =?UTF-8?q?=E5=8C=BA=E5=9F=9F=E7=85=A7=E7=89=87=E4=B8=8A=E4=BC=A0=E6=96=B9?= =?UTF-8?q?=E5=BC=8F=E9=BB=98=E8=AE=A4=E4=B8=BA=E7=9B=B8=E6=9C=BA=E4=B8=8A?= =?UTF-8?q?=E4=BC=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../zcloud/service/firemanager/impl/FireRegionServiceImpl.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/com/zcloud/service/firemanager/impl/FireRegionServiceImpl.java b/src/main/java/com/zcloud/service/firemanager/impl/FireRegionServiceImpl.java index a3f4b2b2..ad2cf45b 100644 --- a/src/main/java/com/zcloud/service/firemanager/impl/FireRegionServiceImpl.java +++ b/src/main/java/com/zcloud/service/firemanager/impl/FireRegionServiceImpl.java @@ -182,6 +182,7 @@ public class FireRegionServiceImpl implements FireRegionService { pd.put("FIRE_REGION_NAME", name); pd.put("FIRE_REGION_CODE", bianma); pd.put("DEPARTMENT_ID", departId); + pd.put("PHOTO_UPLOAD_METHOD", "1"); // 默认上传照片方式为相机 pd.put("ISDELETE", 0); this.saveInfo(pd); return pd; From 2208a7cef992e9ed14ff28feee99e63fd9d887a3 Mon Sep 17 00:00:00 2001 From: liujun Date: Tue, 9 Apr 2024 16:05:37 +0800 Subject: [PATCH 03/26] =?UTF-8?q?=E5=85=B6=E4=BB=96=E5=AE=89=E5=85=A8?= =?UTF-8?q?=E6=8E=AA=E6=96=BD=E4=B8=8D=E6=98=BE=E7=A4=BAbug=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/highriskwork/AppHotworkCfdController.java | 3 ++- .../highriskwork/impl/HotworkCfdServiceImpl.java | 3 +++ .../highriskwork/BusHotworkCfdExamineMapper.xml | 12 ++++++++---- 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java index c2c6713a..df7e3489 100644 --- a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java +++ b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java @@ -895,7 +895,7 @@ public class AppHotworkCfdController extends BaseController { pd2.put("CONFIRM_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName); pd2.put("CONFIRM_USER_SIGNER_TIME", pd.get("SIGNER_TIME")); - pd2.put("CONFIRM_CONTENT", pd.get("CONTENT")); + pd2.put("CONFIRM_CONTENT", pd.get("APPROVAL_CONTENT")); pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS")); hotworkCfdService.edit(pd2); log.put("ACTION", "作业单位通过"); @@ -925,6 +925,7 @@ public class AppHotworkCfdController extends BaseController { condition.put("APPROVAL_SIGNATURE",Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName); condition.put("APPROVAL_SIGNATURE_TIME",pd.get("SIGNER_TIME")); condition.put("APPROVAL_STATUS",pd.getString("APPROVAL_STATUS")); + condition.put("APPROVAL_CONTENT",pd.getString("APPROVAL_CONTENT")); hotworkCfdService.approval(condition); } break; diff --git a/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java b/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java index 7a6b91ba..2916c7c2 100644 --- a/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java +++ b/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java @@ -154,6 +154,7 @@ public class HotworkCfdServiceImpl implements HotworkCfdService { entity.put("APPROVAL_SIGNATURE", info.getString("APPROVAL_SIGNATURE")); entity.put("APPROVAL_SIGNATURE_TIME", info.getString("APPROVAL_SIGNATURE_TIME")); entity.put("APPROVAL_STATUS", info.getString("APPROVAL_STATUS")); + entity.put("APPROVAL_CONTENT",info.getString("APPROVAL_CONTENT")); busHotworkCfdExamineMapper.edit(entity); } @@ -466,6 +467,7 @@ public class HotworkCfdServiceImpl implements HotworkCfdService { pd.put("BELONGING_OPINIONS", belong.getString("APPROVAL_OPINIONS")); pd.put("BELONGING_SIGNATURE", belong.getString("APPROVAL_SIGNATURE")); pd.put("BELONGING_SIGNATURE_TIME", belong.getString("APPROVAL_SIGNATURE_TIME")); + pd.put("BELONGING_USER_MEASURES", belong.getString("APPROVAL_CONTENT")); // 安全项检查人 PageData safety = approvalInfos.stream().filter(x -> "2".equals(x.getString("TYPE"))).findFirst().orElse(null); pd.put("SAFETY_USER_ID", safety.getString("USER_ID")); @@ -474,6 +476,7 @@ public class HotworkCfdServiceImpl implements HotworkCfdService { pd.put("SAFETY_DEPARTMENT_NAME", safety.getString("DEPARTMENT_NAME")); pd.put("SAFETY_SIGNATURE", safety.getString("APPROVAL_SIGNATURE")); pd.put("SAFETY_SIGNATURE_TIME", safety.getString("APPROVAL_SIGNATURE_TIME")); + pd.put("SAFETY_USER_MEASURES",safety.getString("APPROVAL_CONTENT")); } } diff --git a/src/main/resources/mybatis/datasource/highriskwork/BusHotworkCfdExamineMapper.xml b/src/main/resources/mybatis/datasource/highriskwork/BusHotworkCfdExamineMapper.xml index 99a86266..7df5eee7 100644 --- a/src/main/resources/mybatis/datasource/highriskwork/BusHotworkCfdExamineMapper.xml +++ b/src/main/resources/mybatis/datasource/highriskwork/BusHotworkCfdExamineMapper.xml @@ -25,7 +25,8 @@ f.APPROVAL_STATUS, f.IS_DELETE, f.CREATE_TIME, - f.REMARK + f.REMARK, + f.APPROVAL_CONTENT @@ -47,7 +48,8 @@ APPROVAL_STATUS, IS_DELETE, CREATE_TIME, - REMARK + REMARK, + APPROVAL_CONTENT @@ -69,7 +71,8 @@ #{APPROVAL_STATUS}, #{IS_DELETE}, #{CREATE_TIME}, - #{REMARK} + #{REMARK}, + #{APPROVAL_CONTENT} @@ -103,7 +106,8 @@ APPROVAL_STATUS = #{APPROVAL_STATUS}, IS_DELETE = #{IS_DELETE}, CREATE_TIME = #{CREATE_TIME}, - REMARK = #{REMARK} + REMARK = #{REMARK}, + APPROVAL_CONTENT = #{APPROVAL_CONTENT} where HOTWORK_EXAMINE_ID = #{HOTWORK_EXAMINE_ID} From e129c80e5dcd520c839944a32871348da591917a Mon Sep 17 00:00:00 2001 From: liujun Date: Tue, 9 Apr 2024 20:39:05 +0800 Subject: [PATCH 04/26] =?UTF-8?q?15050=20=E7=9B=91=E6=8A=A4=E4=BA=BA?= =?UTF-8?q?=E7=AD=BE=E5=AD=97=E5=88=97=E8=A1=A8=20=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E7=BC=BA=E5=B0=91=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/highriskwork/AppHotworkCfdController.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java index df7e3489..dc795311 100644 --- a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java +++ b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java @@ -1543,6 +1543,10 @@ public class AppHotworkCfdController extends BaseController { if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim()); page.setPd(pd); List varList = hotworkCfdService.jhlist(page); //列出confinedspace列表 + // created by liu jun 2024/02/03 description: 拼接动火交底人、项目主管部门、安全项检查人 + for(PageData dto: varList){ + hotworkCfdService.addInfo(dto); + } map.put("varList", varList); map.put("page", page); map.put("result", errInfo); @@ -1564,6 +1568,10 @@ public class AppHotworkCfdController extends BaseController { if(Tools.notEmpty(KEYWORDS))pd.put("KEYWORDS", KEYWORDS.trim()); page.setPd(pd); List varList = hotworkCfdService.aqlist(page); //列出confinedspace列表 + // created by liu jun 2024/02/03 description: 拼接动火交底人、项目主管部门、安全项检查人 + for(PageData dto: varList){ + hotworkCfdService.addInfo(dto); + } map.put("varList", varList); map.put("page", page); map.put("result", errInfo); From fadc082584a69af45e72aa4d3a942e5bd2bc7b3e Mon Sep 17 00:00:00 2001 From: liujun Date: Tue, 9 Apr 2024 22:26:06 +0800 Subject: [PATCH 05/26] =?UTF-8?q?1=E3=80=81pom=E5=8E=BB=E6=8E=89=E6=97=A0?= =?UTF-8?q?=E6=95=88=E5=BC=95=E7=94=A8=202=E3=80=81=E6=96=87=E4=BB=B6?= =?UTF-8?q?=E6=9C=8D=E5=8A=A1=E5=99=A8=E5=AF=86=E7=A0=81=E6=9B=B4=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/resources/application-master.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/resources/application-master.properties b/src/main/resources/application-master.properties index 8cb8b781..a6dcf33c 100644 --- a/src/main/resources/application-master.properties +++ b/src/main/resources/application-master.properties @@ -62,7 +62,7 @@ qa-regulatory-gwj.api.url=http://192.168.192.201:8092/qa-regulatory-gwj/ smb.host=192.168.192.201 smb.port=22 smb.user=root -smb.password=SJSKAQHBGLXT@20220311 +smb.password=SJSKaqhb@20240131 smb.basePath=/mnt/qask/file/ #Mq\u914D\u7F6E rocketmq.consumer.group2=edu-admin-edit From c2a4f2a47520aaa1e34cbc97d216d46d87e70f3b Mon Sep 17 00:00:00 2001 From: liujun Date: Wed, 10 Apr 2024 11:19:03 +0800 Subject: [PATCH 06/26] =?UTF-8?q?=E4=B8=80=E5=85=AC=E5=8F=B8app=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/highriskwork/AppHotworkCfdController.java | 3 ++- .../datasource/highriskwork/HotworkCfdMapper.xml | 11 ++++++++--- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java index dc795311..5fd4678a 100644 --- a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java +++ b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java @@ -895,7 +895,8 @@ public class AppHotworkCfdController extends BaseController { pd2.put("CONFIRM_USER_SIGNER_PATH", Const.FILEPATHFILE + pd.getString("CORPINFO_ID") + "/" + ffile + "/" + fileName); pd2.put("CONFIRM_USER_SIGNER_TIME", pd.get("SIGNER_TIME")); - pd2.put("CONFIRM_CONTENT", pd.get("APPROVAL_CONTENT")); + pd2.put("CONFIRM_CONTENT", pd.get("CONTENT")); + pd2.put("CONFIRM_OTHER_CONTENT", pd.get("APPROVAL_CONTENT")); pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS")); hotworkCfdService.edit(pd2); log.put("ACTION", "作业单位通过"); diff --git a/src/main/resources/mybatis/datasource/highriskwork/HotworkCfdMapper.xml b/src/main/resources/mybatis/datasource/highriskwork/HotworkCfdMapper.xml index 34b7d9de..a4f28db3 100644 --- a/src/main/resources/mybatis/datasource/highriskwork/HotworkCfdMapper.xml +++ b/src/main/resources/mybatis/datasource/highriskwork/HotworkCfdMapper.xml @@ -88,7 +88,8 @@ f.ACCEPT_CONFESS_USER_ID, f.ACCEPT_CONFESS_USER_SIGNER_PATH, f.ACCEPT_CONFESS_USER_SIGNER_TIME, - f.ANALYZE_TIME + f.ANALYZE_TIME, + f.CONFIRM_OTHER_CONTENT @@ -167,7 +168,8 @@ ACCEPT_CONFESS_USER_ID, ACCEPT_CONFESS_USER_SIGNER_PATH, ACCEPT_CONFESS_USER_SIGNER_TIME, - ANALYZE_TIME + ANALYZE_TIME, + CONFIRM_OTHER_CONTENT @@ -246,7 +248,8 @@ #{ACCEPT_CONFESS_USER_ID}, #{ACCEPT_CONFESS_USER_SIGNER_PATH}, #{ACCEPT_CONFESS_USER_SIGNER_TIME}, - #{ANALYZE_TIME} + #{ANALYZE_TIME}, + #{CONFIRM_OTHER_CONTENT} @@ -355,6 +358,7 @@ ACCEPT_CONFESS_USER_ID = #{ACCEPT_CONFESS_USER_ID}, ACCEPT_CONFESS_USER_SIGNER_PATH = #{ACCEPT_CONFESS_USER_SIGNER_PATH}, ACCEPT_CONFESS_USER_SIGNER_TIME = #{ACCEPT_CONFESS_USER_SIGNER_TIME}, + CONFIRM_OTHER_CONTENT = #{CONFIRM_OTHER_CONTENT}, HOTWORK_ID = HOTWORK_ID where HOTWORK_ID = #{HOTWORK_ID} @@ -542,6 +546,7 @@ f.ACCEPT_CONFESS_USER_SIGNER_PATH, f.ACCEPT_CONFESS_USER_SIGNER_TIME, f.HOTWORK_ID, + f.CONFIRM_OTHER_CONTENT, ad.NAME as APPLY_DEPARTMENT_NAME, au.NAME as APPLY_USER_NAME, From fb98f35b2421e726d11feead0f86342200ba307c Mon Sep 17 00:00:00 2001 From: liujun Date: Wed, 10 Apr 2024 13:10:03 +0800 Subject: [PATCH 07/26] =?UTF-8?q?15061=20=E5=8A=A8=E7=81=AB=E5=89=8D?= =?UTF-8?q?=E9=AA=8C=E7=A5=A8=E7=A1=AE=E8=AE=A4=E5=89=8D=20=E6=8E=A5?= =?UTF-8?q?=E5=8F=97=E4=BA=A4=E5=BA=95=E4=BA=BA=E5=BF=85=E9=A1=BB=E7=AD=BE?= =?UTF-8?q?=E5=AD=97=20=E7=8E=B0=E5=9C=A8=E6=B2=A1=E6=9C=89=E9=99=90?= =?UTF-8?q?=E5=88=B6=20=E6=8E=A5=E5=8F=97=E4=BA=A4=E5=BA=95=E4=BA=BA?= =?UTF-8?q?=E7=8E=B0=E5=9C=A8=E4=B8=8D=E7=AD=BE=E5=AD=97=E4=B9=9F=E8=83=BD?= =?UTF-8?q?=E8=B5=B0=E5=AE=8C=E6=B5=81=E7=A8=8B=E4=BA=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/highriskwork/AppHotworkCfdController.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java index 5fd4678a..5bb9fc6a 100644 --- a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java +++ b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java @@ -1097,6 +1097,14 @@ public class AppHotworkCfdController extends BaseController { case "7"://班长 if (files != null && files.length > 0) { + PageData condition = new PageData(); + condition.put("HOTWORK_ID",pd2.getString("HOTWORK_ID")); + List acceptUsers = hotworkAcceptUserCfdService.listAll(condition); + if (acceptUsers.size() <= 0){ + map.put("code","9999"); + map.put("errorMessage","接受交底人未签字"); + return map; + } MultipartFile file = files[0]; String ffile = DateUtil.getDays(); From 60bfb26030d0672a50a92777e67c883633afdd8b Mon Sep 17 00:00:00 2001 From: limingyu Date: Wed, 10 Apr 2024 15:21:12 +0800 Subject: [PATCH 08/26] =?UTF-8?q?15066=E5=87=BA=E7=8E=B0=E4=BA=86=E5=AE=89?= =?UTF-8?q?=E5=85=A8=E6=8E=AA=E6=96=BD=E7=A1=AE=E8=AE=A4=E4=BA=BA=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E4=B8=A2=E5=A4=B1=E7=9A=84=E6=83=85=E5=86=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../datasource/highriskwork/BusHotworkCfdExamineMapper.java | 2 ++ .../service/highriskwork/impl/HotworkCfdServiceImpl.java | 3 ++- .../datasource/highriskwork/BusHotworkCfdExamineMapper.xml | 4 ++++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/zcloud/mapper/datasource/highriskwork/BusHotworkCfdExamineMapper.java b/src/main/java/com/zcloud/mapper/datasource/highriskwork/BusHotworkCfdExamineMapper.java index 523de699..b1c821aa 100644 --- a/src/main/java/com/zcloud/mapper/datasource/highriskwork/BusHotworkCfdExamineMapper.java +++ b/src/main/java/com/zcloud/mapper/datasource/highriskwork/BusHotworkCfdExamineMapper.java @@ -26,5 +26,7 @@ public interface BusHotworkCfdExamineMapper { List findByCondition(PageData condition); List safetylistPage(Page page); + + List listAllByHotWorkId(PageData condition); } diff --git a/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java b/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java index 2916c7c2..3d6e88f4 100644 --- a/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java +++ b/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java @@ -284,7 +284,8 @@ public class HotworkCfdServiceImpl implements HotworkCfdService { hotworkCfdMapper.delete(pd); PageData condition = new PageData(); condition.put("HOTWORK_ID", pd.getString("HOTWORK_ID")); - List oldEntity = busHotworkCfdExamineMapper.listAll(condition); +// List oldEntity = busHotworkCfdExamineMapper.listAll(condition); + List oldEntity = busHotworkCfdExamineMapper.listAllByHotWorkId(condition); for (PageData entity : oldEntity) { entity.put("IS_DELETE", "1"); busHotworkCfdExamineMapper.edit(entity); diff --git a/src/main/resources/mybatis/datasource/highriskwork/BusHotworkCfdExamineMapper.xml b/src/main/resources/mybatis/datasource/highriskwork/BusHotworkCfdExamineMapper.xml index 7df5eee7..820319df 100644 --- a/src/main/resources/mybatis/datasource/highriskwork/BusHotworkCfdExamineMapper.xml +++ b/src/main/resources/mybatis/datasource/highriskwork/BusHotworkCfdExamineMapper.xml @@ -308,5 +308,9 @@ ORDER BY f.APPLY_STATUS,f.CREATTIME DESC + + From 03ebdabc6d34397ce4af9451a1e97196f5172315 Mon Sep 17 00:00:00 2001 From: liujun Date: Wed, 10 Apr 2024 16:43:37 +0800 Subject: [PATCH 09/26] =?UTF-8?q?15050=20=E7=9B=91=E6=8A=A4=E4=BA=BA?= =?UTF-8?q?=E7=AD=BE=E5=AD=97=E5=88=97=E8=A1=A8=20=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E7=BC=BA=E5=B0=91=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/highriskwork/AppHotworkCfdController.java | 10 ++++++++++ .../highriskwork/impl/HotworkCfdServiceImpl.java | 1 + 2 files changed, 11 insertions(+) diff --git a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java index 5bb9fc6a..e7250d05 100644 --- a/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java +++ b/src/main/java/com/zcloud/controller/app/highriskwork/AppHotworkCfdController.java @@ -1207,6 +1207,13 @@ public class AppHotworkCfdController extends BaseController { //sendMessageUtil.sendMessages(mes, paramsList); } break; + case "-1.5": {//确认 + log.put("ACTION", "作业负责人打回"); + pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS")); + pd2.put("AUDIT_CONTENT", pd.get("CONTENT")); + hotworkCfdService.edit(pd2); + break; + } case "-2": {//确认打回 log.put("ACTION", "作业单位打回"); pd2.put("APPLY_STATUS", pd.get("APPLY_STATUS")); @@ -1856,6 +1863,7 @@ public class AppHotworkCfdController extends BaseController { condition.put("CORPINFO_ID",request.get("CORPINFO_ID")); condition.put("TYPE","2"); condition.put("APPROVAL_STATUS","1"); + condition.put("APPROVAL_CONTENT", request.getString("APPROVAL_CONTENT")); hotworkCfdService.confessApproval(condition, files); // 保存安全项信息 @@ -1877,6 +1885,8 @@ public class AppHotworkCfdController extends BaseController { measures.put("CONFIRM_NAME", request.get("ACTION_USER")); hotworkToMeasuresCfdService.save(measures); } + + // 保存其他审批意见 response.put("result", "success"); return response; } catch (Exception e) { diff --git a/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java b/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java index 3d6e88f4..96918bc1 100644 --- a/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java +++ b/src/main/java/com/zcloud/service/highriskwork/impl/HotworkCfdServiceImpl.java @@ -232,6 +232,7 @@ public class HotworkCfdServiceImpl implements HotworkCfdService { entity.put("APPROVAL_STATUS", request.getString("APPROVAL_STATUS")); entity.put("APPROVAL_SIGNATURE", Warden.saveFile(files,request.getString("CORPINFO_ID"))); entity.put("APPROVAL_SIGNATURE_TIME", DateUtil.getTime()); + entity.put("APPROVAL_CONTENT",request.getString("APPROVAL_CONTENT")); busHotworkCfdExamineMapper.edit(entity); } From ba98786e94ed5f440931d1af167129980a592395 Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 08:51:23 +0800 Subject: [PATCH 10/26] =?UTF-8?q?=E4=B8=80=E5=85=AC=E5=8F=B8=E8=8E=B7?= =?UTF-8?q?=E5=8F=96=E4=BA=BA=E5=91=98=E5=AE=9A=E4=BD=8D=E7=B3=BB=E7=BB=9F?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../zcloud/controller/dw/DwController.java | 54 +++++++++++++++++++ .../java/com/zcloud/service/dw/DwService.java | 12 +++++ .../com/zcloud/service/dw/dto/AlarmGet.java | 13 +++++ .../zcloud/service/dw/dto/AlarmManageDto.java | 12 +++++ .../com/zcloud/service/dw/dto/MapGet.java | 15 ++++++ .../com/zcloud/service/dw/dto/MapInfo.java | 14 +++++ .../zcloud/service/dw/dto/MapRequired.java | 39 ++++++++++++++ .../java/com/zcloud/service/dw/dto/Page.java | 10 ++++ .../com/zcloud/service/dw/dto/TraceGet.java | 10 ++++ .../zcloud/service/dw/impl/DwServiceImpl.java | 40 ++++++++++++++ src/main/java/com/zcloud/util/HttpUtil.java | 44 +++++++++++++++ 11 files changed, 263 insertions(+) create mode 100644 src/main/java/com/zcloud/controller/dw/DwController.java create mode 100644 src/main/java/com/zcloud/service/dw/DwService.java create mode 100644 src/main/java/com/zcloud/service/dw/dto/AlarmGet.java create mode 100644 src/main/java/com/zcloud/service/dw/dto/AlarmManageDto.java create mode 100644 src/main/java/com/zcloud/service/dw/dto/MapGet.java create mode 100644 src/main/java/com/zcloud/service/dw/dto/MapInfo.java create mode 100644 src/main/java/com/zcloud/service/dw/dto/MapRequired.java create mode 100644 src/main/java/com/zcloud/service/dw/dto/Page.java create mode 100644 src/main/java/com/zcloud/service/dw/dto/TraceGet.java create mode 100644 src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java create mode 100644 src/main/java/com/zcloud/util/HttpUtil.java diff --git a/src/main/java/com/zcloud/controller/dw/DwController.java b/src/main/java/com/zcloud/controller/dw/DwController.java new file mode 100644 index 00000000..d8f4e3e2 --- /dev/null +++ b/src/main/java/com/zcloud/controller/dw/DwController.java @@ -0,0 +1,54 @@ +package com.zcloud.controller.dw; + +import com.alibaba.fastjson.JSONObject; +import com.zcloud.controller.base.BaseController; +import com.zcloud.entity.PageData; +import com.zcloud.service.dw.DwService; +import com.zcloud.service.dw.dto.*; +import org.springframework.stereotype.Controller; +import org.springframework.web.bind.annotation.RequestMapping; + +import javax.annotation.Resource; + +@Controller +@RequestMapping(value = "/dw") +public class DwController extends BaseController { + + @Resource + private DwService dwService; + + @RequestMapping(value = "getTrace") + public Object getTrace() throws Exception { + PageData pd = this.getPageData(); + TraceGet traceGet = JSONObject.parseObject(JSONObject.toJSONString(pd), TraceGet.class); + return dwService.getTrace(traceGet); + } + + @RequestMapping(value = "getMapList") + public Object getMapList() throws Exception { + PageData pd = this.getPageData(); + MapGet mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), MapGet.class); + return dwService.getMapList(mapGet); + } + + @RequestMapping(value = "saveOrUpdateMap") + public Object saveOrUpdateMap() throws Exception { + PageData pd = this.getPageData(); + MapInfo mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), MapInfo.class); + return dwService.saveOrUpdateMap(mapGet); + } + + @RequestMapping(value = "getAlarmList") + public Object getAlarmList() throws Exception { + PageData pd = this.getPageData(); + AlarmGet mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), AlarmGet.class); + return dwService.getAlarmList(mapGet); + } + + @RequestMapping(value = "manageAlarm") + public Object manageAlarm() throws Exception { + PageData pd = this.getPageData(); + AlarmManageDto mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), AlarmManageDto.class); + return dwService.manageAlarm(mapGet); + } +} diff --git a/src/main/java/com/zcloud/service/dw/DwService.java b/src/main/java/com/zcloud/service/dw/DwService.java new file mode 100644 index 00000000..74567380 --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/DwService.java @@ -0,0 +1,12 @@ +package com.zcloud.service.dw; + +import com.zcloud.service.dw.dto.*; + +public interface DwService { + + Object getMapList(MapGet param) throws Exception; + Object saveOrUpdateMap(MapInfo param) throws Exception; + Object getTrace(TraceGet param) throws Exception; + Object getAlarmList(AlarmGet param) throws Exception; + Object manageAlarm(AlarmManageDto param) throws Exception; +} diff --git a/src/main/java/com/zcloud/service/dw/dto/AlarmGet.java b/src/main/java/com/zcloud/service/dw/dto/AlarmGet.java new file mode 100644 index 00000000..a79155f2 --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/dto/AlarmGet.java @@ -0,0 +1,13 @@ +package com.zcloud.service.dw.dto; + +import lombok.Data; + +@Data +public class AlarmGet { + + private String startTime; + private String endTime; + private String status; + private Page page; + +} diff --git a/src/main/java/com/zcloud/service/dw/dto/AlarmManageDto.java b/src/main/java/com/zcloud/service/dw/dto/AlarmManageDto.java new file mode 100644 index 00000000..bb2a718d --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/dto/AlarmManageDto.java @@ -0,0 +1,12 @@ +package com.zcloud.service.dw.dto; + +import lombok.Data; + +@Data +public class AlarmManageDto { + private String status; + private String alarmId; + private String opinion; + private String operator; + private String operatorName; +} diff --git a/src/main/java/com/zcloud/service/dw/dto/MapGet.java b/src/main/java/com/zcloud/service/dw/dto/MapGet.java new file mode 100644 index 00000000..39c08c48 --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/dto/MapGet.java @@ -0,0 +1,15 @@ +package com.zcloud.service.dw.dto; + +import lombok.Data; + +@Data +public class MapGet { + private String departmentId; + private String userId; + private String userCardId; + private String userPhone; + private String deviceId; + private String deviceName; + private String type; + private Page page; +} diff --git a/src/main/java/com/zcloud/service/dw/dto/MapInfo.java b/src/main/java/com/zcloud/service/dw/dto/MapInfo.java new file mode 100644 index 00000000..0697540a --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/dto/MapInfo.java @@ -0,0 +1,14 @@ +package com.zcloud.service.dw.dto; + +import lombok.Data; + +@Data +public class MapInfo { + + private MapRequired required; + //其他系统备注 + private String idRemark; + //备注 + private String remark; + private String dwUserMapId; +} diff --git a/src/main/java/com/zcloud/service/dw/dto/MapRequired.java b/src/main/java/com/zcloud/service/dw/dto/MapRequired.java new file mode 100644 index 00000000..1f141dca --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/dto/MapRequired.java @@ -0,0 +1,39 @@ +package com.zcloud.service.dw.dto; + +import lombok.Data; + +@Data +public class MapRequired { + //映射类型(0-人员,1-设备) + private String type; + //人员id + private String userId; + //人员姓名 + private String userName; + //身份证号 + private String userCardId; + //手机号 + private String userPhone; + //设备id + private String deviceId; + //设备名称 + private String deviceName; + //部门id + private String departmentId; + //部门名称 + private String departmentName; + //企业id名称 + private String corpId; + //企业名称 + private String corpName; + //其他系统id + private String id; + //数据创建人id + private String creatorId; + //数据创建人名称 + private String creatorName; + //数据更新时间 + private String operatorId; + //数据更新人id + private String operatorName; +} diff --git a/src/main/java/com/zcloud/service/dw/dto/Page.java b/src/main/java/com/zcloud/service/dw/dto/Page.java new file mode 100644 index 00000000..f10fcc0b --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/dto/Page.java @@ -0,0 +1,10 @@ +package com.zcloud.service.dw.dto; + +import lombok.Data; + +@Data +public class Page { + private String page; + private String size; + private String current; +} diff --git a/src/main/java/com/zcloud/service/dw/dto/TraceGet.java b/src/main/java/com/zcloud/service/dw/dto/TraceGet.java new file mode 100644 index 00000000..e3215fb3 --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/dto/TraceGet.java @@ -0,0 +1,10 @@ +package com.zcloud.service.dw.dto; + +import lombok.Data; + +@Data +public class TraceGet { + private String user_id; + private String startTime; + private String endTime; +} diff --git a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java new file mode 100644 index 00000000..d774d53d --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java @@ -0,0 +1,40 @@ +package com.zcloud.service.dw.impl; + +import com.zcloud.service.dw.DwService; +import com.zcloud.service.dw.dto.*; +import com.zcloud.util.HttpUtil; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.stereotype.Service; + +@Service +public class DwServiceImpl implements DwService { + + @Value("dw.url") + private String url; + + + @Override + public Object getMapList(MapGet param) throws Exception { + return HttpUtil.post(url + "dw/getMapList", param); + } + + @Override + public Object saveOrUpdateMap(MapInfo param) throws Exception { + return HttpUtil.post(url + "dw/saveOrUpdateMap", param); + } + + @Override + public Object getTrace(TraceGet param) throws Exception { + return HttpUtil.post(url + "dw/getTrace", param); + } + + @Override + public Object getAlarmList(AlarmGet param) throws Exception { + return HttpUtil.post(url + "dw/getAlarmList", param); + } + + @Override + public Object manageAlarm(AlarmManageDto param) throws Exception { + return HttpUtil.post(url + "dw/manageAlarm", param); + } +} diff --git a/src/main/java/com/zcloud/util/HttpUtil.java b/src/main/java/com/zcloud/util/HttpUtil.java new file mode 100644 index 00000000..96527907 --- /dev/null +++ b/src/main/java/com/zcloud/util/HttpUtil.java @@ -0,0 +1,44 @@ +package com.zcloud.util; + +import com.alibaba.fastjson.JSONObject; +import com.alibaba.fastjson.TypeReference; +import org.apache.poi.ss.formula.functions.T; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.springframework.web.client.RestTemplate; + +import java.util.HashMap; +import java.util.Map; + +public class HttpUtil { + + private static final Logger LOGGER = LoggerFactory.getLogger(HttpUtil.class); + /** + * 返回成功状态码 + */ + private static final int SUCCESS_CODE = 200; + + public HashMap doPost(String url, HashMap info) { + RestTemplate restTemplate = new RestTemplate(); + String result = restTemplate.postForEntity(url, info, String.class).getBody(); + return JSONObject.parseObject(result, new TypeReference>() {}); + } + + public HashMap doPost(String url, Object info) { + RestTemplate restTemplate = new RestTemplate(); + String result = restTemplate.postForEntity(url, info, String.class).getBody(); + return JSONObject.parseObject(result, new TypeReference>() {}); + } + + public T doPost(String url, Object info, Class tClass) { + RestTemplate restTemplate = new RestTemplate(); + String result = restTemplate.postForEntity(url, info, String.class).getBody(); + return JSONObject.parseObject(result, tClass); + } + + public static Object post(String url, Object info) { + RestTemplate restTemplate = new RestTemplate(); + String result = restTemplate.postForEntity(url, info, String.class).getBody(); + return JSONObject.parseObject(result, Map.class); + } +} From 7136bb9a3708d5b526c40cc1616002890305854a Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 10:27:30 +0800 Subject: [PATCH 11/26] =?UTF-8?q?=E4=BA=BA=E5=91=98=E5=AE=9A=E4=BD=8D?= =?UTF-8?q?=E6=96=B0=E6=A8=A1=E5=9D=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/zcloud/controller/dw/DwController.java | 5 +++++ src/main/java/com/zcloud/service/dw/DwService.java | 1 + src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java | 5 +++++ 3 files changed, 11 insertions(+) diff --git a/src/main/java/com/zcloud/controller/dw/DwController.java b/src/main/java/com/zcloud/controller/dw/DwController.java index d8f4e3e2..e0fe2f7d 100644 --- a/src/main/java/com/zcloud/controller/dw/DwController.java +++ b/src/main/java/com/zcloud/controller/dw/DwController.java @@ -51,4 +51,9 @@ public class DwController extends BaseController { AlarmManageDto mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), AlarmManageDto.class); return dwService.manageAlarm(mapGet); } + + @RequestMapping(value = "getDictionary") + public Object getDictionary() throws Exception { + return dwService.getDictionary(); + } } diff --git a/src/main/java/com/zcloud/service/dw/DwService.java b/src/main/java/com/zcloud/service/dw/DwService.java index 74567380..51a85d42 100644 --- a/src/main/java/com/zcloud/service/dw/DwService.java +++ b/src/main/java/com/zcloud/service/dw/DwService.java @@ -9,4 +9,5 @@ public interface DwService { Object getTrace(TraceGet param) throws Exception; Object getAlarmList(AlarmGet param) throws Exception; Object manageAlarm(AlarmManageDto param) throws Exception; + Object getDictionary() throws Exception; } diff --git a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java index d774d53d..9c10106a 100644 --- a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java +++ b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java @@ -37,4 +37,9 @@ public class DwServiceImpl implements DwService { public Object manageAlarm(AlarmManageDto param) throws Exception { return HttpUtil.post(url + "dw/manageAlarm", param); } + + @Override + public Object getDictionary() throws Exception { + return HttpUtil.post(url + "dw/getDictionary", ""); + } } From 92dabf2a7c428b435467921d26c32026495eb8b0 Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 10:59:30 +0800 Subject: [PATCH 12/26] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=88=86=E9=A1=B5?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/zcloud/controller/dw/DwController.java | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/zcloud/controller/dw/DwController.java b/src/main/java/com/zcloud/controller/dw/DwController.java index e0fe2f7d..a8428c27 100644 --- a/src/main/java/com/zcloud/controller/dw/DwController.java +++ b/src/main/java/com/zcloud/controller/dw/DwController.java @@ -25,9 +25,12 @@ public class DwController extends BaseController { } @RequestMapping(value = "getMapList") - public Object getMapList() throws Exception { + public Object getMapList(Page page) throws Exception { PageData pd = this.getPageData(); MapGet mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), MapGet.class); + mapGet.getPage().setPage(page.getPage()); + mapGet.getPage().setCurrent(page.getCurrent()); + mapGet.getPage().setSize(page.getSize()); return dwService.getMapList(mapGet); } @@ -39,9 +42,12 @@ public class DwController extends BaseController { } @RequestMapping(value = "getAlarmList") - public Object getAlarmList() throws Exception { + public Object getAlarmList(Page page) throws Exception { PageData pd = this.getPageData(); AlarmGet mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), AlarmGet.class); + mapGet.getPage().setPage(page.getPage()); + mapGet.getPage().setCurrent(page.getCurrent()); + mapGet.getPage().setSize(page.getSize()); return dwService.getAlarmList(mapGet); } From b1dd0eb5533f37fe5b8e3d8f883e81b57d782686 Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 11:03:47 +0800 Subject: [PATCH 13/26] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=88=86=E9=A1=B5?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java index 9c10106a..3f8589ae 100644 --- a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java +++ b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java @@ -9,7 +9,7 @@ import org.springframework.stereotype.Service; @Service public class DwServiceImpl implements DwService { - @Value("dw.url") + @Value("${dw.url}") private String url; @@ -40,6 +40,7 @@ public class DwServiceImpl implements DwService { @Override public Object getDictionary() throws Exception { + System.out.println(url + "dw/getDictionary"); return HttpUtil.post(url + "dw/getDictionary", ""); } } From c7abd55db79517ccb91c421b7a153781c8f1c2cc Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 12:33:30 +0800 Subject: [PATCH 14/26] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=88=86=E9=A1=B5?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pom.xml | 2 +- .../zcloud/controller/dw/DwController.java | 24 ++++++++++++------- src/main/java/com/zcloud/util/HttpUtil.java | 6 +++++ 3 files changed, 22 insertions(+), 10 deletions(-) diff --git a/pom.xml b/pom.xml index 31ef9d76..235ecb1e 100644 --- a/pom.xml +++ b/pom.xml @@ -67,7 +67,7 @@ javax.servlet javax.servlet-api - 3.1.0 + 4.0.1 provided diff --git a/src/main/java/com/zcloud/controller/dw/DwController.java b/src/main/java/com/zcloud/controller/dw/DwController.java index a8428c27..b520591d 100644 --- a/src/main/java/com/zcloud/controller/dw/DwController.java +++ b/src/main/java/com/zcloud/controller/dw/DwController.java @@ -3,15 +3,16 @@ package com.zcloud.controller.dw; import com.alibaba.fastjson.JSONObject; import com.zcloud.controller.base.BaseController; import com.zcloud.entity.PageData; +import com.zcloud.entity.Page; import com.zcloud.service.dw.DwService; import com.zcloud.service.dw.dto.*; -import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; import javax.annotation.Resource; -@Controller -@RequestMapping(value = "/dw") +@RestController +@RequestMapping(value = "/dingWei") public class DwController extends BaseController { @Resource @@ -28,9 +29,11 @@ public class DwController extends BaseController { public Object getMapList(Page page) throws Exception { PageData pd = this.getPageData(); MapGet mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), MapGet.class); - mapGet.getPage().setPage(page.getPage()); - mapGet.getPage().setCurrent(page.getCurrent()); - mapGet.getPage().setSize(page.getSize()); + if (mapGet.getPage() == null){ + mapGet.setPage(new com.zcloud.service.dw.dto.Page()); + } + mapGet.getPage().setCurrent(String.valueOf(page.getCurrentPage())); + mapGet.getPage().setSize(String.valueOf(page.getShowCount())); return dwService.getMapList(mapGet); } @@ -45,9 +48,11 @@ public class DwController extends BaseController { public Object getAlarmList(Page page) throws Exception { PageData pd = this.getPageData(); AlarmGet mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), AlarmGet.class); - mapGet.getPage().setPage(page.getPage()); - mapGet.getPage().setCurrent(page.getCurrent()); - mapGet.getPage().setSize(page.getSize()); + if (mapGet.getPage() == null){ + mapGet.setPage(new com.zcloud.service.dw.dto.Page()); + } + mapGet.getPage().setCurrent(String.valueOf(page.getCurrentPage())); + mapGet.getPage().setSize(String.valueOf(page.getShowCount())); return dwService.getAlarmList(mapGet); } @@ -62,4 +67,5 @@ public class DwController extends BaseController { public Object getDictionary() throws Exception { return dwService.getDictionary(); } + } diff --git a/src/main/java/com/zcloud/util/HttpUtil.java b/src/main/java/com/zcloud/util/HttpUtil.java index 96527907..2cac2b63 100644 --- a/src/main/java/com/zcloud/util/HttpUtil.java +++ b/src/main/java/com/zcloud/util/HttpUtil.java @@ -41,4 +41,10 @@ public class HttpUtil { String result = restTemplate.postForEntity(url, info, String.class).getBody(); return JSONObject.parseObject(result, Map.class); } + + public static Object post(String url) { + RestTemplate restTemplate = new RestTemplate(); + String result = restTemplate.getForObject(url, String.class); + return JSONObject.parseObject(result, Map.class); + } } From 9eecfecf44daa5df81c80866b83edbfc5792a3f7 Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 14:44:17 +0800 Subject: [PATCH 15/26] =?UTF-8?q?=E6=9C=AA=E5=88=86=E9=A1=B5bug=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/zcloud/controller/dw/DwController.java | 2 +- .../zcloud/service/dw/impl/DwServiceImpl.java | 16 ++++++++++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/zcloud/controller/dw/DwController.java b/src/main/java/com/zcloud/controller/dw/DwController.java index b520591d..9dfb6123 100644 --- a/src/main/java/com/zcloud/controller/dw/DwController.java +++ b/src/main/java/com/zcloud/controller/dw/DwController.java @@ -40,7 +40,7 @@ public class DwController extends BaseController { @RequestMapping(value = "saveOrUpdateMap") public Object saveOrUpdateMap() throws Exception { PageData pd = this.getPageData(); - MapInfo mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), MapInfo.class); + MapInfo mapGet = JSONObject.parseObject(pd.getString("data"), MapInfo.class); return dwService.saveOrUpdateMap(mapGet); } diff --git a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java index 3f8589ae..287f843d 100644 --- a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java +++ b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java @@ -1,17 +1,25 @@ package com.zcloud.service.dw.impl; +import com.zcloud.entity.PageData; +import com.zcloud.service.bus.CorpInfoService; import com.zcloud.service.dw.DwService; import com.zcloud.service.dw.dto.*; import com.zcloud.util.HttpUtil; +import com.zcloud.util.Jurisdiction; import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Service; +import javax.annotation.Resource; + @Service public class DwServiceImpl implements DwService { @Value("${dw.url}") private String url; + @Resource + private CorpInfoService corpInfoService; + @Override public Object getMapList(MapGet param) throws Exception { @@ -20,6 +28,14 @@ public class DwServiceImpl implements DwService { @Override public Object saveOrUpdateMap(MapInfo param) throws Exception { + param.getRequired().setCreatorId(Jurisdiction.getUSER_ID()); + param.getRequired().setCreatorName(Jurisdiction.getName()); + param.getRequired().setOperatorId(Jurisdiction.getUSER_ID()); + param.getRequired().setOperatorName(Jurisdiction.getName()); + param.getRequired().setCorpId(Jurisdiction.getCORPINFO_ID()); + PageData condition = new PageData(); + condition.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); + param.getRequired().setCorpName(corpInfoService.findById(condition).getString("CORP_NAME")); return HttpUtil.post(url + "dw/saveOrUpdateMap", param); } From 057ac23f9f7961bd31721706548e670988c4ac53 Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 15:16:59 +0800 Subject: [PATCH 16/26] =?UTF-8?q?=E6=98=A0=E5=B0=84=E4=BF=9D=E5=AD=98?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/zcloud/service/dw/dto/MapRequired.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/java/com/zcloud/service/dw/dto/MapRequired.java b/src/main/java/com/zcloud/service/dw/dto/MapRequired.java index 1f141dca..cb8332af 100644 --- a/src/main/java/com/zcloud/service/dw/dto/MapRequired.java +++ b/src/main/java/com/zcloud/service/dw/dto/MapRequired.java @@ -6,6 +6,8 @@ import lombok.Data; public class MapRequired { //映射类型(0-人员,1-设备) private String type; + // 设备名称 + private String typeName; //人员id private String userId; //人员姓名 From a24889aabfe386e52e8dbb33259d94e2de2b6858 Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 16:12:38 +0800 Subject: [PATCH 17/26] =?UTF-8?q?=E6=98=A0=E5=B0=84=E4=BF=9D=E5=AD=98?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/zcloud/controller/dw/DwController.java | 11 +++++++++++ src/main/java/com/zcloud/service/dw/DwService.java | 2 ++ .../java/com/zcloud/service/dw/dto/DeleteDto.java | 14 ++++++++++++++ .../com/zcloud/service/dw/impl/DwServiceImpl.java | 6 +++++- 4 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 src/main/java/com/zcloud/service/dw/dto/DeleteDto.java diff --git a/src/main/java/com/zcloud/controller/dw/DwController.java b/src/main/java/com/zcloud/controller/dw/DwController.java index 9dfb6123..30ba3527 100644 --- a/src/main/java/com/zcloud/controller/dw/DwController.java +++ b/src/main/java/com/zcloud/controller/dw/DwController.java @@ -6,6 +6,7 @@ import com.zcloud.entity.PageData; import com.zcloud.entity.Page; import com.zcloud.service.dw.DwService; import com.zcloud.service.dw.dto.*; +import com.zcloud.util.Jurisdiction; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; @@ -44,6 +45,16 @@ public class DwController extends BaseController { return dwService.saveOrUpdateMap(mapGet); } + @RequestMapping(value = "deleteMap") + public Object deleteMap() throws Exception { + PageData pd = this.getPageData(); + DeleteDto deleteDto = new DeleteDto(); + deleteDto.setId(pd.getString("id")); + deleteDto.setOperatorId(Jurisdiction.getUSER_ID()); + deleteDto.setOperatorName(Jurisdiction.getName()); + return dwService.deleteMap(deleteDto); + } + @RequestMapping(value = "getAlarmList") public Object getAlarmList(Page page) throws Exception { PageData pd = this.getPageData(); diff --git a/src/main/java/com/zcloud/service/dw/DwService.java b/src/main/java/com/zcloud/service/dw/DwService.java index 51a85d42..fde31036 100644 --- a/src/main/java/com/zcloud/service/dw/DwService.java +++ b/src/main/java/com/zcloud/service/dw/DwService.java @@ -10,4 +10,6 @@ public interface DwService { Object getAlarmList(AlarmGet param) throws Exception; Object manageAlarm(AlarmManageDto param) throws Exception; Object getDictionary() throws Exception; + + Object deleteMap(DeleteDto deleteDto); } diff --git a/src/main/java/com/zcloud/service/dw/dto/DeleteDto.java b/src/main/java/com/zcloud/service/dw/dto/DeleteDto.java new file mode 100644 index 00000000..97badd5f --- /dev/null +++ b/src/main/java/com/zcloud/service/dw/dto/DeleteDto.java @@ -0,0 +1,14 @@ +package com.zcloud.service.dw.dto; + +import lombok.Data; + +import java.util.List; + +@Data +public class DeleteDto { + + private String id; + private List ids; + private String operatorId; + private String operatorName; +} diff --git a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java index 287f843d..3b1ba7a3 100644 --- a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java +++ b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java @@ -56,7 +56,11 @@ public class DwServiceImpl implements DwService { @Override public Object getDictionary() throws Exception { - System.out.println(url + "dw/getDictionary"); return HttpUtil.post(url + "dw/getDictionary", ""); } + + @Override + public Object deleteMap(DeleteDto deleteDto) { + return HttpUtil.post(url + "dw/deleteMap", deleteDto); + } } From f7b28773d6fd2690b1e195c7fee1f64f39cdbf4b Mon Sep 17 00:00:00 2001 From: limingyu Date: Sat, 13 Apr 2024 16:15:29 +0800 Subject: [PATCH 18/26] =?UTF-8?q?1=E3=80=81=E6=8A=A5=E8=AD=A6=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E9=A1=B5=E9=9D=A2=E6=98=BE=E7=A4=BA=E6=89=80=E6=9C=89?= =?UTF-8?q?=E6=95=B0=E6=8D=AEbug=E4=BF=AE=E5=A4=8D=EF=BC=9B2=E3=80=81?= =?UTF-8?q?=E5=BF=BD=E7=95=A5=E5=92=8C=E7=A1=AE=E8=AE=A4=E6=97=B6=E6=8A=A5?= =?UTF-8?q?=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/zcloud/controller/dw/DwController.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/zcloud/controller/dw/DwController.java b/src/main/java/com/zcloud/controller/dw/DwController.java index 9dfb6123..4327780d 100644 --- a/src/main/java/com/zcloud/controller/dw/DwController.java +++ b/src/main/java/com/zcloud/controller/dw/DwController.java @@ -51,7 +51,7 @@ public class DwController extends BaseController { if (mapGet.getPage() == null){ mapGet.setPage(new com.zcloud.service.dw.dto.Page()); } - mapGet.getPage().setCurrent(String.valueOf(page.getCurrentPage())); + mapGet.getPage().setCurrent(String.valueOf(page.getUrlCurrentPage())); mapGet.getPage().setSize(String.valueOf(page.getShowCount())); return dwService.getAlarmList(mapGet); } @@ -60,6 +60,7 @@ public class DwController extends BaseController { public Object manageAlarm() throws Exception { PageData pd = this.getPageData(); AlarmManageDto mapGet = JSONObject.parseObject(JSONObject.toJSONString(pd), AlarmManageDto.class); + mapGet.setAlarmId(pd.getString("DW_ALARM_ID")); return dwService.manageAlarm(mapGet); } From e84b612073edacf9e475cd3af4184525b8d66217 Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 16:53:00 +0800 Subject: [PATCH 19/26] =?UTF-8?q?=E5=AE=8C=E5=96=84=E4=BF=9D=E5=AD=98?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/zcloud/service/dw/dto/MapGet.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/com/zcloud/service/dw/dto/MapGet.java b/src/main/java/com/zcloud/service/dw/dto/MapGet.java index 39c08c48..e0a8cae1 100644 --- a/src/main/java/com/zcloud/service/dw/dto/MapGet.java +++ b/src/main/java/com/zcloud/service/dw/dto/MapGet.java @@ -6,6 +6,7 @@ import lombok.Data; public class MapGet { private String departmentId; private String userId; + private String userName; private String userCardId; private String userPhone; private String deviceId; From ff4be346ffad81fc346719bec0656c5e235b2ba1 Mon Sep 17 00:00:00 2001 From: liujun Date: Sat, 13 Apr 2024 17:11:13 +0800 Subject: [PATCH 20/26] =?UTF-8?q?=E6=9F=A5=E8=AF=A2bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/zcloud/controller/dw/DwController.java | 1 + src/main/java/com/zcloud/service/dw/dto/MapGet.java | 1 + 2 files changed, 2 insertions(+) diff --git a/src/main/java/com/zcloud/controller/dw/DwController.java b/src/main/java/com/zcloud/controller/dw/DwController.java index 44fcde9f..d722fb43 100644 --- a/src/main/java/com/zcloud/controller/dw/DwController.java +++ b/src/main/java/com/zcloud/controller/dw/DwController.java @@ -33,6 +33,7 @@ public class DwController extends BaseController { if (mapGet.getPage() == null){ mapGet.setPage(new com.zcloud.service.dw.dto.Page()); } + mapGet.setCorpId(Jurisdiction.getCORPINFO_ID()); mapGet.getPage().setCurrent(String.valueOf(page.getCurrentPage())); mapGet.getPage().setSize(String.valueOf(page.getShowCount())); return dwService.getMapList(mapGet); diff --git a/src/main/java/com/zcloud/service/dw/dto/MapGet.java b/src/main/java/com/zcloud/service/dw/dto/MapGet.java index e0a8cae1..af7c1213 100644 --- a/src/main/java/com/zcloud/service/dw/dto/MapGet.java +++ b/src/main/java/com/zcloud/service/dw/dto/MapGet.java @@ -8,6 +8,7 @@ public class MapGet { private String userId; private String userName; private String userCardId; + private String corpId; private String userPhone; private String deviceId; private String deviceName; From 1da764000c6ba32ccd361fdad2a92e60897557aa Mon Sep 17 00:00:00 2001 From: liujun Date: Tue, 16 Apr 2024 17:22:44 +0800 Subject: [PATCH 21/26] =?UTF-8?q?=E4=B8=80=E5=85=AC=E5=8F=B8=E4=BA=BA?= =?UTF-8?q?=E5=91=98=E5=AE=9A=E4=BD=8D=E5=9C=B0=E5=9B=BE=E5=8A=9F=E8=83=BD?= =?UTF-8?q?=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../zcloud/controller/map/MapController.java | 41 +++++++++++++++++-- .../java/com/zcloud/service/dw/DwService.java | 1 + .../com/zcloud/service/dw/dto/MapGet.java | 3 +- .../zcloud/service/dw/dto/MapRequired.java | 1 - .../com/zcloud/service/dw/dto/TraceGet.java | 1 + .../zcloud/service/dw/impl/DwServiceImpl.java | 4 ++ 6 files changed, 45 insertions(+), 6 deletions(-) diff --git a/src/main/java/com/zcloud/controller/map/MapController.java b/src/main/java/com/zcloud/controller/map/MapController.java index 24459ab8..c6369ffd 100644 --- a/src/main/java/com/zcloud/controller/map/MapController.java +++ b/src/main/java/com/zcloud/controller/map/MapController.java @@ -4,6 +4,9 @@ import com.zcloud.controller.base.BaseController; import com.zcloud.entity.Page; import com.zcloud.entity.PageData; import com.zcloud.service.bus.CorpInfoService; +import com.zcloud.service.dw.DwService; +import com.zcloud.service.dw.dto.MapGet; +import com.zcloud.service.dw.dto.TraceGet; import com.zcloud.service.keyProjects.VideoManagerService; import com.zcloud.service.map.*; import com.zcloud.service.map.util.ReturnMap; @@ -24,6 +27,7 @@ import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.client.RestTemplate; +import javax.annotation.Resource; import java.util.*; /** @@ -73,6 +77,8 @@ public class MapController extends BaseController { @Autowired private WeatherUtil weatherUtil; + @Resource + private DwService dwService; @ResponseBody @RequestMapping("/getCorpInfo") @@ -864,12 +870,39 @@ public class MapController extends BaseController { public Object getPersonByCardNo() throws Exception { Map map = new HashMap(); PageData pd = this.getPageData(); - PageData value = usersService.getPersonByCardNo(pd); - map.put("result", "success"); - map.put("pd", value); - return map; + // TODO 判断是否是公司人员定位 + if (true){ + MapGet mapInfo = new MapGet(); + mapInfo.setId(pd.getString("CARDNO")); + return dwService.getMapInfo(mapInfo); + }else { + PageData value = usersService.getPersonByCardNo(pd); + map.put("result", "success"); + map.put("pd", value); + return map; + } } + @RequestMapping(value = "/getPersonTrace") + @ResponseBody + public Object getPersonTrace() throws Exception { + Map map = new HashMap(); + PageData pd = this.getPageData(); + // TODO 判断是否是公司人员定位 + if (true){ + TraceGet mapInfo = new TraceGet(); + mapInfo.setId(pd.getString("id")); + return dwService.getTrace(mapInfo); + }else { + PageData value = usersService.getPersonByCardNo(pd); + map.put("result", "success"); + map.put("pd", value); + return map; + } + } + + + /** * 获取摄像头播放路径(曹妃甸使用) * diff --git a/src/main/java/com/zcloud/service/dw/DwService.java b/src/main/java/com/zcloud/service/dw/DwService.java index fde31036..ca17590f 100644 --- a/src/main/java/com/zcloud/service/dw/DwService.java +++ b/src/main/java/com/zcloud/service/dw/DwService.java @@ -4,6 +4,7 @@ import com.zcloud.service.dw.dto.*; public interface DwService { + Object getMapInfo(MapGet param) throws Exception; Object getMapList(MapGet param) throws Exception; Object saveOrUpdateMap(MapInfo param) throws Exception; Object getTrace(TraceGet param) throws Exception; diff --git a/src/main/java/com/zcloud/service/dw/dto/MapGet.java b/src/main/java/com/zcloud/service/dw/dto/MapGet.java index af7c1213..3a5293fe 100644 --- a/src/main/java/com/zcloud/service/dw/dto/MapGet.java +++ b/src/main/java/com/zcloud/service/dw/dto/MapGet.java @@ -7,11 +7,12 @@ public class MapGet { private String departmentId; private String userId; private String userName; - private String userCardId; private String corpId; + private String userCardId; private String userPhone; private String deviceId; private String deviceName; private String type; + private String id; private Page page; } diff --git a/src/main/java/com/zcloud/service/dw/dto/MapRequired.java b/src/main/java/com/zcloud/service/dw/dto/MapRequired.java index cb8332af..7a9ed604 100644 --- a/src/main/java/com/zcloud/service/dw/dto/MapRequired.java +++ b/src/main/java/com/zcloud/service/dw/dto/MapRequired.java @@ -6,7 +6,6 @@ import lombok.Data; public class MapRequired { //映射类型(0-人员,1-设备) private String type; - // 设备名称 private String typeName; //人员id private String userId; diff --git a/src/main/java/com/zcloud/service/dw/dto/TraceGet.java b/src/main/java/com/zcloud/service/dw/dto/TraceGet.java index e3215fb3..acf50478 100644 --- a/src/main/java/com/zcloud/service/dw/dto/TraceGet.java +++ b/src/main/java/com/zcloud/service/dw/dto/TraceGet.java @@ -5,6 +5,7 @@ import lombok.Data; @Data public class TraceGet { private String user_id; + private String id; private String startTime; private String endTime; } diff --git a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java index 3b1ba7a3..edf9433c 100644 --- a/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java +++ b/src/main/java/com/zcloud/service/dw/impl/DwServiceImpl.java @@ -20,6 +20,10 @@ public class DwServiceImpl implements DwService { @Resource private CorpInfoService corpInfoService; + @Override + public Object getMapInfo(MapGet param) throws Exception { + return HttpUtil.post(url + "dw/getMapInfo", param); + } @Override public Object getMapList(MapGet param) throws Exception { From ca299d110d087e1bf5b8ce1476097bbf7784de93 Mon Sep 17 00:00:00 2001 From: liujun Date: Wed, 17 Apr 2024 08:57:44 +0800 Subject: [PATCH 22/26] =?UTF-8?q?=E4=B8=80=E5=85=AC=E5=8F=B8=E4=BA=BA?= =?UTF-8?q?=E5=91=98=E5=AE=9A=E4=BD=8D=E5=9C=B0=E5=9B=BE=E5=8A=9F=E8=83=BD?= =?UTF-8?q?=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../zcloud/controller/map/MapController.java | 28 +++++++++++++++---- src/main/java/com/zcloud/util/HttpUtil.java | 9 ++++-- 2 files changed, 30 insertions(+), 7 deletions(-) diff --git a/src/main/java/com/zcloud/controller/map/MapController.java b/src/main/java/com/zcloud/controller/map/MapController.java index c6369ffd..ed9544f0 100644 --- a/src/main/java/com/zcloud/controller/map/MapController.java +++ b/src/main/java/com/zcloud/controller/map/MapController.java @@ -1,11 +1,14 @@ package com.zcloud.controller.map; +import com.alibaba.fastjson.JSONObject; +import com.alibaba.fastjson.TypeReference; import com.zcloud.controller.base.BaseController; import com.zcloud.entity.Page; import com.zcloud.entity.PageData; import com.zcloud.service.bus.CorpInfoService; import com.zcloud.service.dw.DwService; import com.zcloud.service.dw.dto.MapGet; +import com.zcloud.service.dw.dto.MapInfo; import com.zcloud.service.dw.dto.TraceGet; import com.zcloud.service.keyProjects.VideoManagerService; import com.zcloud.service.map.*; @@ -871,11 +874,26 @@ public class MapController extends BaseController { Map map = new HashMap(); PageData pd = this.getPageData(); // TODO 判断是否是公司人员定位 - if (true){ - MapGet mapInfo = new MapGet(); - mapInfo.setId(pd.getString("CARDNO")); - return dwService.getMapInfo(mapInfo); - }else { + if (pd.get("corpId") != null && "035958e685cf4850bc40151c5e0617a6".equals(pd.getString("corpId"))) { + MapGet mapGet = new MapGet(); + mapGet.setId(pd.getString("CARDNO")); + Object message = dwService.getMapInfo(mapGet); + map = JSONObject.parseObject(JSONObject.toJSONString(message), new TypeReference>() { + }); + if (map.get("code") == null || 200 != Integer.parseInt(map.get("code").toString())) { + return map; + } else { + MapInfo info = JSONObject.parseObject(JSONObject.toJSONString(map.get("info")), MapInfo.class); + PageData condition = new PageData(); + condition.put("USER_ID", info.getRequired().getUserId()); + PageData userInfo = usersService.findById(condition); + HashMap otherInfo = new HashMap<>(); + otherInfo.put("postName", userInfo.getString("postName")); + otherInfo.put("personnelTypeName", userInfo.getString("personnelTypeName")); + map.put("otherInfo", otherInfo); + return map; + } + } else { PageData value = usersService.getPersonByCardNo(pd); map.put("result", "success"); map.put("pd", value); diff --git a/src/main/java/com/zcloud/util/HttpUtil.java b/src/main/java/com/zcloud/util/HttpUtil.java index 2cac2b63..ba804ad4 100644 --- a/src/main/java/com/zcloud/util/HttpUtil.java +++ b/src/main/java/com/zcloud/util/HttpUtil.java @@ -30,10 +30,15 @@ public class HttpUtil { return JSONObject.parseObject(result, new TypeReference>() {}); } - public T doPost(String url, Object info, Class tClass) { + public T doPost(String url, Object info, Class responseType) { RestTemplate restTemplate = new RestTemplate(); String result = restTemplate.postForEntity(url, info, String.class).getBody(); - return JSONObject.parseObject(result, tClass); + return JSONObject.parseObject(result, responseType); + } + + public static T post(String url, Object info, Class responseType) { + RestTemplate restTemplate = new RestTemplate(); + return restTemplate.postForEntity(url, info, responseType).getBody(); } public static Object post(String url, Object info) { From 086632290b91ac7c0eb5b40d944dccb87e7368f9 Mon Sep 17 00:00:00 2001 From: liujun Date: Wed, 17 Apr 2024 11:21:46 +0800 Subject: [PATCH 23/26] =?UTF-8?q?=E4=B8=80=E5=85=AC=E5=8F=B8=E4=BC=81?= =?UTF-8?q?=E4=B8=9A=E7=AB=AF=E5=9C=B0=E5=9B=BE=E5=8A=9F=E8=83=BD=E5=90=8C?= =?UTF-8?q?=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../zcloud/controller/map/MapController.java | 22 +++++++++++++++++++ .../com/zcloud/service/dw/dto/AlarmGet.java | 1 + 2 files changed, 23 insertions(+) diff --git a/src/main/java/com/zcloud/controller/map/MapController.java b/src/main/java/com/zcloud/controller/map/MapController.java index ed9544f0..068f9ed0 100644 --- a/src/main/java/com/zcloud/controller/map/MapController.java +++ b/src/main/java/com/zcloud/controller/map/MapController.java @@ -7,6 +7,7 @@ import com.zcloud.entity.Page; import com.zcloud.entity.PageData; import com.zcloud.service.bus.CorpInfoService; import com.zcloud.service.dw.DwService; +import com.zcloud.service.dw.dto.AlarmGet; import com.zcloud.service.dw.dto.MapGet; import com.zcloud.service.dw.dto.MapInfo; import com.zcloud.service.dw.dto.TraceGet; @@ -919,6 +920,27 @@ public class MapController extends BaseController { } } + @RequestMapping(value = "/getAlarmList") + @ResponseBody + public Object getAlarmList() throws Exception { + Map map = new HashMap(); + PageData pd = this.getPageData(); + // TODO 判断是否是公司人员定位 + if (pd.get("corpId") != null && "035958e685cf4850bc40151c5e0617a6".equals(pd.getString("corpId"))) { + AlarmGet alarmGet = new AlarmGet(); + alarmGet.setPage(new com.zcloud.service.dw.dto.Page()); + alarmGet.getPage().setCurrent("1"); + alarmGet.getPage().setSize("20"); + alarmGet.setCorpId(pd.getString("corpId")); + return dwService.getAlarmList(alarmGet); + }else { + PageData value = usersService.getPersonByCardNo(pd); + map.put("result", "success"); + map.put("pd", value); + return map; + } + } + /** diff --git a/src/main/java/com/zcloud/service/dw/dto/AlarmGet.java b/src/main/java/com/zcloud/service/dw/dto/AlarmGet.java index a79155f2..e4c5044a 100644 --- a/src/main/java/com/zcloud/service/dw/dto/AlarmGet.java +++ b/src/main/java/com/zcloud/service/dw/dto/AlarmGet.java @@ -8,6 +8,7 @@ public class AlarmGet { private String startTime; private String endTime; private String status; + private String corpId; private Page page; } From 3dd180d33325967bac4211141cdf235ab566c45c Mon Sep 17 00:00:00 2001 From: liujun Date: Wed, 17 Apr 2024 14:22:06 +0800 Subject: [PATCH 24/26] =?UTF-8?q?=E4=B8=80=E5=85=AC=E5=8F=B8=E5=9C=B0?= =?UTF-8?q?=E5=9B=BEbug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/MeteorologicalinfoServiceImpl.java | 6 ++-- .../dsno2/map/MeteorologicalinfoMapper.xml | 31 ++++++++++--------- 2 files changed, 19 insertions(+), 18 deletions(-) diff --git a/src/main/java/com/zcloud/service/map/impl/MeteorologicalinfoServiceImpl.java b/src/main/java/com/zcloud/service/map/impl/MeteorologicalinfoServiceImpl.java index df1a3c83..2cbba617 100644 --- a/src/main/java/com/zcloud/service/map/impl/MeteorologicalinfoServiceImpl.java +++ b/src/main/java/com/zcloud/service/map/impl/MeteorologicalinfoServiceImpl.java @@ -234,12 +234,10 @@ public class MeteorologicalinfoServiceImpl implements MeteorologicalinfoService pd.put("OUTSOURCED_ID",pd.getString("CORPINFO_ID")); List getListByCorpinfoId = meteorologicalMapper.listAll(pd); if(getListByCorpinfoId.size() > 0){ - String codes = ""; + List codes = new ArrayList(); for (PageData met : getListByCorpinfoId){ - codes += "'" + met.getString("CODE")+"',"; + codes.add(met.getString("CODE")); } - System.out.println(); - codes = codes.substring(0,codes.length()-1); pd.put("codes",codes); return meteorologicalinfoMapper.listbymeteorologicalByCodes(pd); } diff --git a/src/main/resources/mybatis/dsno2/map/MeteorologicalinfoMapper.xml b/src/main/resources/mybatis/dsno2/map/MeteorologicalinfoMapper.xml index a2b3204c..f878c94d 100644 --- a/src/main/resources/mybatis/dsno2/map/MeteorologicalinfoMapper.xml +++ b/src/main/resources/mybatis/dsno2/map/MeteorologicalinfoMapper.xml @@ -512,22 +512,25 @@ From a3f1eb97493f9dec82183a2462080a3ee62f7c57 Mon Sep 17 00:00:00 2001 From: liujun Date: Thu, 18 Apr 2024 18:30:15 +0800 Subject: [PATCH 25/26] =?UTF-8?q?=E4=BA=BA=E5=91=98=E7=B1=BB=E5=9E=8B?= =?UTF-8?q?=E6=9C=AA=E6=98=BE=E7=A4=BAbug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/zcloud/controller/map/MapController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/zcloud/controller/map/MapController.java b/src/main/java/com/zcloud/controller/map/MapController.java index 068f9ed0..4998f895 100644 --- a/src/main/java/com/zcloud/controller/map/MapController.java +++ b/src/main/java/com/zcloud/controller/map/MapController.java @@ -890,7 +890,7 @@ public class MapController extends BaseController { PageData userInfo = usersService.findById(condition); HashMap otherInfo = new HashMap<>(); otherInfo.put("postName", userInfo.getString("postName")); - otherInfo.put("personnelTypeName", userInfo.getString("personnelTypeName")); + otherInfo.put("personType", userInfo.getString("PERSON_TYPE")); map.put("otherInfo", otherInfo); return map; } From 2be4c2a38a864eec0ce3c0c10ad5775656ab5959 Mon Sep 17 00:00:00 2001 From: limingyu Date: Fri, 19 Apr 2024 13:59:30 +0800 Subject: [PATCH 26/26] =?UTF-8?q?=E5=85=B3=E6=8E=89=E6=B6=88=E9=98=B2?= =?UTF-8?q?=E5=8D=8A=E6=9C=88=E6=A3=80=E6=9F=A5=E8=A1=A8=E5=AE=9A=E6=97=B6?= =?UTF-8?q?=E5=99=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/zcloud/util/RecordHalfMonthScheduled.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/java/com/zcloud/util/RecordHalfMonthScheduled.java b/src/main/java/com/zcloud/util/RecordHalfMonthScheduled.java index 4a152fb8..86bf19f0 100644 --- a/src/main/java/com/zcloud/util/RecordHalfMonthScheduled.java +++ b/src/main/java/com/zcloud/util/RecordHalfMonthScheduled.java @@ -57,7 +57,7 @@ public class RecordHalfMonthScheduled { } } - @Scheduled(cron ="0 0 1 1,16 1-12 ?") //每月1号、16号 01:00 +// @Scheduled(cron ="0 0 1 1,16 1-12 ?") //每月1号、16号 01:00 // @Scheduled(cron ="*/20 * * * * ?")//测试 public void equipmentNotChecked(){ System.out.println("============每半月定时增加超期未检查消防设备记录=========="); @@ -91,7 +91,6 @@ public class RecordHalfMonthScheduled { pageData.put("CORPINFO_ID", corpinfoId); pageData.put("PERIODSTART", finalStartTime); pageData.put("PERIODEND", finalEndTime); - pageData.put("PHONE_REPEAT", "1"); //'添加人''添加时间''修改人''修改时间' pageData.put("CREATOR", "adminTask"); pageData.put("CREATTIME", DateUtil.date2Str(new Date()));