From f44b0f0b22f5b343753678f3a33fc56cc5d447d6 Mon Sep 17 00:00:00 2001 From: zhangyu Date: Thu, 16 Feb 2023 15:30:52 +0800 Subject: [PATCH] =?UTF-8?q?=E6=99=BA=E6=85=A7=E5=AE=89=E7=9B=91=E6=9C=8D?= =?UTF-8?q?=E5=8A=A1=E6=95=B4=E6=94=B9=E5=8F=8A=E4=BB=A3=E7=A0=81=E6=8F=90?= =?UTF-8?q?=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hbt-ep/src/main/resources/banner.txt | 8 - .../hbt-safety-supervision-api.iml | 121 ++++++++ .../hbt-safety-supervision-api/pom.xml | 33 +++ .../hbt-safety-supervision-biz}/.gitignore | 0 .../hbt-safety-supervision-biz}/Dockerfile | 2 +- .../hbt-safety-supervision-biz.iml | 92 +++--- .../hbt-safety-supervision-biz}/pom.xml | 11 +- .../SafetySupervisionApplication.java | 8 +- .../controller/CommonController.java | 2 +- .../EnterpriseInfomationController.java | 93 ++++++ .../EscalateHiddenDangerController.java | 82 ++++++ .../controller/EscalateRiskController.java | 82 ++++++ .../HazardousChemicalsController.java | 28 ++ .../HazardousOperationController.java | 91 ++++++ .../controller/HiddenDangerController.java | 91 ++++++ .../LawEnforcementInspectionController.java | 91 ++++++ .../MajorHazardSourcesController.java | 89 ++++++ .../controller/PersionController.java | 82 ++++++ .../controller/RiskAreaController.java | 83 ++++++ .../controller/RiskController.java | 91 ++++++ .../mapper/EnterpriseInfomationMapper.java | 76 +++++ .../mapper/EscalateHiddenDangerMapper.java | 66 +++++ .../mapper/EscalateRiskMapper.java | 63 ++++ .../mapper/HazardousOperationMapper.java | 69 +++++ .../mapper/HiddenDangerMapper.java | 64 +++++ .../LawEnforcementInspectionMapper.java | 65 +++++ .../mapper/MajorHazardSourcesMapper.java | 64 +++++ .../supervision/mapper/PersionMapper.java | 64 +++++ .../supervision/mapper/RiskAreaMapper.java | 61 ++++ .../safety/supervision/mapper/RiskMapper.java | 69 +++++ .../pojo/EnterpriseInfomation.java | 205 +++++++++++++ .../pojo/EscalateHiddenDanger.java | 65 +++++ .../safety/supervision/pojo/EscalateRisk.java | 65 +++++ .../supervision/pojo/HazardousOperation.java | 165 +++++++++++ .../safety/supervision/pojo/HiddenDanger.java | 220 ++++++++++++++ .../pojo/LawEnforcementInspection.java | 96 +++++++ .../supervision/pojo/MajorHazardSources.java | 270 ++++++++++++++++++ .../hbt/safety/supervision/pojo/Persion.java | 46 +++ .../com/hbt/safety/supervision/pojo/Risk.java | 180 ++++++++++++ .../hbt/safety/supervision/pojo/RiskArea.java | 79 +++++ .../vo/LawEnforcementInspectionStatics.java | 57 ++++ .../pojo/vo/LawEnforcementInspectionVo.java | 36 +++ .../service/IEnterpriseInfomationService.java | 64 +++++ .../service/IEscalateHiddenDangerService.java | 62 ++++ .../service/IEscalateRiskService.java | 62 ++++ .../service/IHazardousOperationService.java | 64 +++++ .../service/IHiddenDangerService.java | 64 +++++ .../ILawEnforcementInspectionService.java | 64 +++++ .../service/IMajorHazardSourcesService.java | 63 ++++ .../supervision/service/IPersionService.java | 62 ++++ .../supervision/service/IRiskAreaService.java | 61 ++++ .../supervision/service/IRiskService.java | 64 +++++ .../impl/EnterpriseInfomationServiceImpl.java | 120 ++++++++ .../impl/EscalateHiddenDangerServiceImpl.java | 94 ++++++ .../service/impl/EscalateRiskServiceImpl.java | 94 ++++++ .../impl/HazardousOperationServiceImpl.java | 147 ++++++++++ .../service/impl/HiddenDangerServiceImpl.java | 115 ++++++++ .../LawEnforcementInspectionServiceImpl.java | 160 +++++++++++ .../impl/MajorHazardSourcesServiceImpl.java | 130 +++++++++ .../service/impl/PersionServiceImpl.java | 94 ++++++ .../service/impl/RiskAreaServiceImpl.java | 94 ++++++ .../service/impl/RiskServiceImpl.java | 101 +++++++ .../src/main/resources/banner.txt | 8 + .../src/main/resources/bootstrap-dev.yml | 0 .../src/main/resources/bootstrap.yml | 2 +- .../mapper/EnterpriseInfomationMapper.xml | 118 ++++++++ .../mapper/EscalateHiddenDangerMapper.xml | 69 +++++ .../resources/mapper/EscalateRiskMapper.xml | 65 +++++ .../mapper/HazardousOperationMapper.xml | 94 ++++++ .../resources/mapper/HiddenDangerMapper.xml | 109 +++++++ .../mapper/LawEnforcementInspectionMapper.xml | 73 +++++ .../mapper/MajorHazardSourcesMapper.xml | 119 ++++++++ .../main/resources/mapper/PersionMapper.xml | 90 ++++++ .../main/resources/mapper/RiskAreaMapper.xml | 63 ++++ .../src/main/resources/mapper/RiskMapper.xml | 97 +++++++ .../hbt-safety-supervision.iml | 12 + hbt-safety-supervision/pom.xml | 23 ++ pom.xml | 2 +- 78 files changed, 5982 insertions(+), 66 deletions(-) delete mode 100644 hbt-ep/src/main/resources/banner.txt create mode 100644 hbt-safety-supervision/hbt-safety-supervision-api/hbt-safety-supervision-api.iml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-api/pom.xml rename {hbt-ep => hbt-safety-supervision/hbt-safety-supervision-biz}/.gitignore (100%) rename {hbt-ep => hbt-safety-supervision/hbt-safety-supervision-biz}/Dockerfile (62%) rename hbt-ep/hbt-ep.iml => hbt-safety-supervision/hbt-safety-supervision-biz/hbt-safety-supervision-biz.iml (98%) rename {hbt-ep => hbt-safety-supervision/hbt-safety-supervision-biz}/pom.xml (90%) rename hbt-ep/src/main/java/com/hbt/wit/park/backend/ep/EpApplication.java => hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/SafetySupervisionApplication.java (66%) rename {hbt-ep/src/main/java/com/hbt/wit/park/backend/ep => hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision}/controller/CommonController.java (93%) create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EnterpriseInfomationController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EscalateHiddenDangerController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EscalateRiskController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HazardousChemicalsController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HazardousOperationController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HiddenDangerController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/LawEnforcementInspectionController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/MajorHazardSourcesController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/PersionController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/RiskAreaController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/RiskController.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EnterpriseInfomationMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EscalateHiddenDangerMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EscalateRiskMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/HazardousOperationMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/HiddenDangerMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/LawEnforcementInspectionMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/MajorHazardSourcesMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/PersionMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/RiskAreaMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/RiskMapper.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EnterpriseInfomation.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EscalateHiddenDanger.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EscalateRisk.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/HazardousOperation.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/HiddenDanger.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/LawEnforcementInspection.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/MajorHazardSources.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/Persion.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/Risk.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/RiskArea.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/vo/LawEnforcementInspectionStatics.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/vo/LawEnforcementInspectionVo.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEnterpriseInfomationService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEscalateHiddenDangerService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEscalateRiskService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IHazardousOperationService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IHiddenDangerService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/ILawEnforcementInspectionService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IMajorHazardSourcesService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IPersionService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IRiskAreaService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IRiskService.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EnterpriseInfomationServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EscalateHiddenDangerServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EscalateRiskServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/HazardousOperationServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/HiddenDangerServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/LawEnforcementInspectionServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/MajorHazardSourcesServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/PersionServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/RiskAreaServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/RiskServiceImpl.java create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/banner.txt rename {hbt-ep => hbt-safety-supervision/hbt-safety-supervision-biz}/src/main/resources/bootstrap-dev.yml (100%) rename {hbt-ep => hbt-safety-supervision/hbt-safety-supervision-biz}/src/main/resources/bootstrap.yml (82%) create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EnterpriseInfomationMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EscalateHiddenDangerMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EscalateRiskMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/HazardousOperationMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/HiddenDangerMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/LawEnforcementInspectionMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/MajorHazardSourcesMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/PersionMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/RiskAreaMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/RiskMapper.xml create mode 100644 hbt-safety-supervision/hbt-safety-supervision.iml create mode 100644 hbt-safety-supervision/pom.xml diff --git a/hbt-ep/src/main/resources/banner.txt b/hbt-ep/src/main/resources/banner.txt deleted file mode 100644 index 33e2030..0000000 --- a/hbt-ep/src/main/resources/banner.txt +++ /dev/null @@ -1,8 +0,0 @@ -Spring Boot Version: ${spring-boot.version} -Spring Application Name: ${spring.application.name} - __ __ __ - / /_ / /_ / /_ ___ ____ - / __ \/ __ \/ __/_____/ _ \/ __ \ - / / / / /_/ / /_/_____/ __/ /_/ / -/_/ /_/_.___/\__/ \___/ .___/ - /_/ \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-api/hbt-safety-supervision-api.iml b/hbt-safety-supervision/hbt-safety-supervision-api/hbt-safety-supervision-api.iml new file mode 100644 index 0000000..8d83195 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-api/hbt-safety-supervision-api.iml @@ -0,0 +1,121 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-api/pom.xml b/hbt-safety-supervision/hbt-safety-supervision-api/pom.xml new file mode 100644 index 0000000..5e460f6 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-api/pom.xml @@ -0,0 +1,33 @@ + + + + com.hbt + hbt-safety-supervision + 1.0-SNAPSHOT + + 4.0.0 + + hbt-safety-supervision-api + + + hbt-safety-supervision-api系统接口模块 + + + + + + com.hbt + hbt-common-security + + + + + joda-time + joda-time + + + + + \ No newline at end of file diff --git a/hbt-ep/.gitignore b/hbt-safety-supervision/hbt-safety-supervision-biz/.gitignore similarity index 100% rename from hbt-ep/.gitignore rename to hbt-safety-supervision/hbt-safety-supervision-biz/.gitignore diff --git a/hbt-ep/Dockerfile b/hbt-safety-supervision/hbt-safety-supervision-biz/Dockerfile similarity index 62% rename from hbt-ep/Dockerfile rename to hbt-safety-supervision/hbt-safety-supervision-biz/Dockerfile index e0394be..bec67b9 100644 --- a/hbt-ep/Dockerfile +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/Dockerfile @@ -1,4 +1,4 @@ FROM 119.45.158.12:5000/mini-java8:latest -COPY target/hbt-ep-1.0-SNAPSHOT.jar /app/app.jar +COPY target/hbt-safety-supervision-biz-1.0-SNAPSHOT.jar /app/app.jar ENV NACOSIP="" ENTRYPOINT ["sh","-c","java -Dnacos.ip=$NACOSIP -jar /app/app.jar"] \ No newline at end of file diff --git a/hbt-ep/hbt-ep.iml b/hbt-safety-supervision/hbt-safety-supervision-biz/hbt-safety-supervision-biz.iml similarity index 98% rename from hbt-ep/hbt-ep.iml rename to hbt-safety-supervision/hbt-safety-supervision-biz/hbt-safety-supervision-biz.iml index 31ef613..f0dbc4b 100644 --- a/hbt-ep/hbt-ep.iml +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/hbt-safety-supervision-biz.iml @@ -4,10 +4,6 @@ - - - - @@ -20,7 +16,6 @@ - @@ -100,49 +95,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -227,5 +179,49 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/hbt-ep/pom.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/pom.xml similarity index 90% rename from hbt-ep/pom.xml rename to hbt-safety-supervision/hbt-safety-supervision-biz/pom.xml index 7d9a62c..ac42b53 100644 --- a/hbt-ep/pom.xml +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/pom.xml @@ -3,13 +3,13 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - wit-park-backend + hbt-safety-supervision com.hbt 1.0-SNAPSHOT 4.0.0 - hbt-ep + hbt-safety-supervision-biz @@ -81,8 +81,15 @@ org.projectlombok lombok + + + com.hbt + hbt-msds-api + 1.0-SNAPSHOT + + ${project.artifactId} org.springframework.boot diff --git a/hbt-ep/src/main/java/com/hbt/wit/park/backend/ep/EpApplication.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/SafetySupervisionApplication.java similarity index 66% rename from hbt-ep/src/main/java/com/hbt/wit/park/backend/ep/EpApplication.java rename to hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/SafetySupervisionApplication.java index f2cdecc..296570f 100644 --- a/hbt-ep/src/main/java/com/hbt/wit/park/backend/ep/EpApplication.java +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/SafetySupervisionApplication.java @@ -1,4 +1,4 @@ -package com.hbt.wit.park.backend.ep; +package com.hbt.safety.supervision; import com.hbt.common.security.annotation.EnableCustomConfig; import com.hbt.common.security.annotation.EnableRyFeignClients; @@ -13,11 +13,11 @@ import org.springframework.cloud.client.SpringCloudApplication; @SpringCloudApplication @EnableCustomSwagger2 @EnableRyFeignClients -public class EpApplication { +public class SafetySupervisionApplication { public static void main(String[] args) { - SpringApplication.run(com.hbt.wit.park.backend.ep.EpApplication.class, args); - System.out.println("(♥◠‿◠)ノ゙ 智慧环保知识server启动成功 ლ(´ڡ`ლ)゙ "); + SpringApplication.run(SafetySupervisionApplication.class, args); + System.out.println("(♥◠‿◠)ノ゙ 智慧安监server启动成功 ლ(´ڡ`ლ)゙ "); } } diff --git a/hbt-ep/src/main/java/com/hbt/wit/park/backend/ep/controller/CommonController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/CommonController.java similarity index 93% rename from hbt-ep/src/main/java/com/hbt/wit/park/backend/ep/controller/CommonController.java rename to hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/CommonController.java index 9b1eddd..d4c980d 100644 --- a/hbt-ep/src/main/java/com/hbt/wit/park/backend/ep/controller/CommonController.java +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/CommonController.java @@ -1,4 +1,4 @@ -package com.hbt.wit.park.backend.ep.controller; +package com.hbt.safety.supervision.controller; import com.hbt.common.core.domain.R; import com.hbt.common.core.web.controller.BaseController; diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EnterpriseInfomationController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EnterpriseInfomationController.java new file mode 100644 index 0000000..b8e01ff --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EnterpriseInfomationController.java @@ -0,0 +1,93 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.EnterpriseInfomation; +import com.hbt.safety.supervision.service.IEnterpriseInfomationService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.common.security.annotation.RequiresPermissions; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; +import com.hbt.common.core.web.page.TableDataInfo; + +/** + * 企业信息Controller + * + * @author zhangyu + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/infomation") +public class EnterpriseInfomationController extends BaseController +{ + @Autowired + private IEnterpriseInfomationService enterpriseInfomationService; + + /** + * 查询企业信息列表 + */ + @GetMapping("/list") + public String list(EnterpriseInfomation enterpriseInfomation) + { + startPage(); + List list = enterpriseInfomationService.selectEnterpriseInfomationList(enterpriseInfomation); + TableDataInfo tableDataInfo = getDataTable(list); + return JSONObject.toJSONString(tableDataInfo); + } + + /** + * 获取企业信息详细信息 + */ + @RequiresPermissions("ep:infomation:query") + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + AjaxResult ajaxResult = success(enterpriseInfomationService.selectEnterpriseInfomationById(id)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 新增企业信息 + */ + @GetMapping("/add") + public String add(@RequestBody EnterpriseInfomation enterpriseInfomation) + { + AjaxResult ajaxResult = toAjax(enterpriseInfomationService.insertEnterpriseInfomation(enterpriseInfomation)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改企业信息 + */ + @GetMapping("/edit") + public String edit(@RequestBody EnterpriseInfomation enterpriseInfomation) + { + AjaxResult ajaxResult = toAjax(enterpriseInfomationService.updateEnterpriseInfomation(enterpriseInfomation)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除企业信息 + */ + @GetMapping("/remove") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(enterpriseInfomationService.deleteEnterpriseInfomationByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 在管企业分类统计 + */ + @GetMapping("/enterpriseStatistics") + public String enterpriseStatistics() + { + return enterpriseInfomationService.enterpriseStatistics(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EscalateHiddenDangerController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EscalateHiddenDangerController.java new file mode 100644 index 0000000..3e3d8ed --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EscalateHiddenDangerController.java @@ -0,0 +1,82 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.EscalateHiddenDanger; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.safety.supervision.service.IEscalateHiddenDangerService; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; +import com.hbt.common.core.web.page.TableDataInfo; + +/** + * 上报隐患Controller + * + * @author 张雨 + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/danger") +public class EscalateHiddenDangerController extends BaseController +{ + @Autowired + private IEscalateHiddenDangerService escalateHiddenDangerService; + + /** + * 查询上报隐患列表 + */ + @GetMapping("/list") + public String list(EscalateHiddenDanger escalateHiddenDanger) + { + startPage(); + List list = escalateHiddenDangerService.selectEscalateHiddenDangerList(escalateHiddenDanger); + TableDataInfo tableDataInfo = getDataTable(list); + return JSONObject.toJSONString(tableDataInfo); + } + + /** + * 获取上报隐患详细信息 + */ + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + AjaxResult ajaxResult = success(escalateHiddenDangerService.selectEscalateHiddenDangerById(id)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 新增上报隐患 + */ + @GetMapping(value = "/add") + public String add(@RequestBody EscalateHiddenDanger escalateHiddenDanger) + { + AjaxResult ajaxResult = toAjax(escalateHiddenDangerService.insertEscalateHiddenDanger(escalateHiddenDanger)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改上报隐患 + */ + @GetMapping(value = "/edit") + public String edit(@RequestBody EscalateHiddenDanger escalateHiddenDanger) + { + AjaxResult ajaxResult = toAjax(escalateHiddenDangerService.updateEscalateHiddenDanger(escalateHiddenDanger)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除上报隐患 + */ + @GetMapping(value = "/remove") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(escalateHiddenDangerService.deleteEscalateHiddenDangerByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EscalateRiskController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EscalateRiskController.java new file mode 100644 index 0000000..18f8063 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/EscalateRiskController.java @@ -0,0 +1,82 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.EscalateRisk; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.safety.supervision.service.IEscalateRiskService; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; +import com.hbt.common.core.web.page.TableDataInfo; + +/** + * 上报风险Controller + * + * @author 张雨 + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/escalateRisk") +public class EscalateRiskController extends BaseController +{ + @Autowired + private IEscalateRiskService escalateRiskService; + + /** + * 查询上报风险列表 + */ + @GetMapping("/list") + public String list(EscalateRisk escalateRisk) + { + startPage(); + List list = escalateRiskService.selectEscalateRiskList(escalateRisk); + TableDataInfo tableDataInfo = getDataTable(list); + return JSONObject.toJSONString(tableDataInfo); + } + + /** + * 获取上报风险详细信息 + */ + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + AjaxResult ajaxResult = success(escalateRiskService.selectEscalateRiskById(id)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 新增上报风险 + */ + @GetMapping(value = "/add") + public String add(@RequestBody EscalateRisk escalateRisk) + { + AjaxResult ajaxResult = toAjax(escalateRiskService.insertEscalateRisk(escalateRisk)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改上报风险 + */ + @GetMapping(value = "/edit") + public String edit(@RequestBody EscalateRisk escalateRisk) + { + AjaxResult ajaxResult = toAjax(escalateRiskService.updateEscalateRisk(escalateRisk)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除上报风险 + */ + @GetMapping(value = "/remove") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(escalateRiskService.deleteEscalateRiskByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HazardousChemicalsController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HazardousChemicalsController.java new file mode 100644 index 0000000..05e5f47 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HazardousChemicalsController.java @@ -0,0 +1,28 @@ +package com.hbt.safety.supervision.controller; + +import com.hbt.common.core.constant.SecurityConstants; +import com.hbt.common.core.domain.R; +import com.hbt.msds.api.RemoteMsdsService; +import com.hbt.msds.api.domain.Msds; +import org.apache.ibatis.annotations.Param; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; + +/** + * 危化品controller + * 调用msds服务 + */ +@RestController +@RequestMapping("/chemicals") +public class HazardousChemicalsController { + @Autowired + private RemoteMsdsService remoteMsdsService; + + @GetMapping("/getHazardousChemicals") + public R getHazardousChemicals(@Param("name") String name) { + return remoteMsdsService.getInfo(name, SecurityConstants.INNER); + } + +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HazardousOperationController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HazardousOperationController.java new file mode 100644 index 0000000..1c1eefc --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HazardousOperationController.java @@ -0,0 +1,91 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.HazardousOperation; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.safety.supervision.service.IHazardousOperationService; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; +import com.hbt.common.core.web.page.TableDataInfo; + +/** + * 危险作业Controller + * + * @author zhangyu + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/operation") +public class HazardousOperationController extends BaseController +{ + @Autowired + private IHazardousOperationService hazardousOperationService; + + /** + * 查询危险作业列表 + */ + @GetMapping("/list") + public String list(HazardousOperation hazardousOperation) + { + startPage(); + List list = hazardousOperationService.selectHazardousOperationList(hazardousOperation); + TableDataInfo tableDataInfo = getDataTable(list); + return JSONObject.toJSONString(tableDataInfo); + } + + /** + * 获取危险作业详细信息 + */ + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + AjaxResult ajaxResult = success(hazardousOperationService.selectHazardousOperationById(id)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 新增危险作业 + */ + @GetMapping(value = "/add") + public String add(@RequestBody HazardousOperation hazardousOperation) + { + AjaxResult ajaxResult = toAjax(hazardousOperationService.insertHazardousOperation(hazardousOperation)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改危险作业 + */ + @GetMapping(value = "/edit") + public String edit(@RequestBody HazardousOperation hazardousOperation) + { + AjaxResult ajaxResult = toAjax(hazardousOperationService.updateHazardousOperation(hazardousOperation)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除危险作业 + */ + @GetMapping(value = "/remove") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(hazardousOperationService.deleteHazardousOperationByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 危险作业统计 + */ + @GetMapping(value = "/hazardousOperationStatistics") + public String hazardousOperationStatistics() + { + return hazardousOperationService.hazardousOperationStatistics(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HiddenDangerController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HiddenDangerController.java new file mode 100644 index 0000000..512de1c --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/HiddenDangerController.java @@ -0,0 +1,91 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.HiddenDanger; +import com.hbt.safety.supervision.service.IHiddenDangerService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; +import com.hbt.common.core.web.page.TableDataInfo; + +/** + * 隐患Controller + * + * @author hbt + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/hiddenDanger") +public class HiddenDangerController extends BaseController +{ + @Autowired + private IHiddenDangerService hiddenDangerService; + + /** + * 查询隐患列表 + */ + @GetMapping("/list") + public String list(HiddenDanger hiddenDanger) + { + startPage(); + List list = hiddenDangerService.selectHiddenDangerList(hiddenDanger); + TableDataInfo tableDataInfo = getDataTable(list); + return JSONObject.toJSONString(tableDataInfo); + } + + /** + * 获取隐患详细信息 + */ + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + AjaxResult ajaxResult = success(hiddenDangerService.selectHiddenDangerById(id)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 新增隐患 + */ + @GetMapping(value = "/add") + public String add(@RequestBody HiddenDanger hiddenDanger) + { + AjaxResult ajaxResult = toAjax(hiddenDangerService.insertHiddenDanger(hiddenDanger)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改隐患 + */ + @GetMapping(value = "/edit") + public String edit(@RequestBody HiddenDanger hiddenDanger) + { + AjaxResult ajaxResult = toAjax(hiddenDangerService.updateHiddenDanger(hiddenDanger)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除隐患 + */ + @GetMapping(value = "/remove") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(hiddenDangerService.deleteHiddenDangerByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 隐患统计信息 + */ + @GetMapping(value = "/hiddenDangerStatistics") + public String hiddenDangerStatistics() + { + return hiddenDangerService.hiddenDangerStatistics(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/LawEnforcementInspectionController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/LawEnforcementInspectionController.java new file mode 100644 index 0000000..8f4fff0 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/LawEnforcementInspectionController.java @@ -0,0 +1,91 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.LawEnforcementInspection; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.safety.supervision.service.ILawEnforcementInspectionService; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; +import com.hbt.common.core.web.page.TableDataInfo; + +/** + * 执法巡查Controller + * + * @author zhangyu + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/inspection") +public class LawEnforcementInspectionController extends BaseController +{ + @Autowired + private ILawEnforcementInspectionService lawEnforcementInspectionService; + + /** + * 查询执法巡查列表 + */ + @GetMapping("/list") + public String list(LawEnforcementInspection lawEnforcementInspection) + { + startPage(); + List list = lawEnforcementInspectionService.selectLawEnforcementInspectionList(lawEnforcementInspection); + TableDataInfo tableDataInfo = getDataTable(list); + return JSONObject.toJSONString(tableDataInfo); + } + + /** + * 获取执法巡查详细信息 + */ + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + AjaxResult ajaxResult = success(lawEnforcementInspectionService.selectLawEnforcementInspectionById(id)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 新增执法巡查 + */ + @GetMapping(value = "/add") + public String add(@RequestBody LawEnforcementInspection lawEnforcementInspection) + { + AjaxResult ajaxResult = toAjax(lawEnforcementInspectionService.insertLawEnforcementInspection(lawEnforcementInspection)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改执法巡查 + */ + @GetMapping(value = "/edit") + public String edit(@RequestBody LawEnforcementInspection lawEnforcementInspection) + { + AjaxResult ajaxResult = toAjax(lawEnforcementInspectionService.updateLawEnforcementInspection(lawEnforcementInspection)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除执法巡查 + */ + @GetMapping(value = "/remove") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(lawEnforcementInspectionService.deleteLawEnforcementInspectionByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 按月统计巡查信息 + */ + @GetMapping(value = "/monthStatistics") + public String monthStatistics() + { + return lawEnforcementInspectionService.monthStatistics(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/MajorHazardSourcesController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/MajorHazardSourcesController.java new file mode 100644 index 0000000..069f968 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/MajorHazardSourcesController.java @@ -0,0 +1,89 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.MajorHazardSources; +import com.hbt.safety.supervision.service.IMajorHazardSourcesService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; + +/** + * 重大危险源Controller + * + * @author zhangyu + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/sources") +public class MajorHazardSourcesController extends BaseController +{ + @Autowired + private IMajorHazardSourcesService majorHazardSourcesService; + + /** + * 查询重大危险源列表 + */ + @GetMapping("/list") + public String list(MajorHazardSources majorHazardSources) + { + List list = majorHazardSourcesService.selectMajorHazardSourcesList(majorHazardSources); + return JSONObject.toJSONString(list); + } + + /** + * 获取重大危险源详细信息 + */ + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + MajorHazardSources majorHazardSources = majorHazardSourcesService.selectMajorHazardSourcesById(id); + return JSONObject.toJSONString(majorHazardSources); + } + + /** + * 新增重大危险源 + */ + @GetMapping(value = "/add") + public String add(@RequestBody MajorHazardSources majorHazardSources) + { + AjaxResult ajaxResult = toAjax(majorHazardSourcesService.insertMajorHazardSources(majorHazardSources)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改重大危险源 + */ + @GetMapping(value = "/edit") + public String edit(@RequestBody MajorHazardSources majorHazardSources) + { + AjaxResult ajaxResult = toAjax(majorHazardSourcesService.updateMajorHazardSources(majorHazardSources)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除重大危险源 + */ + @GetMapping(value = "/remove") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(majorHazardSourcesService.deleteMajorHazardSourcesByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 重大危险源统计 + */ + @GetMapping(value = "/majorHazardSourcesStatistics") + public String majorHazardSourcesStatistics() + { + return majorHazardSourcesService.majorHazardSourcesStatistics(); + } + +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/PersionController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/PersionController.java new file mode 100644 index 0000000..65b7eea --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/PersionController.java @@ -0,0 +1,82 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.Persion; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.safety.supervision.service.IPersionService; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; +import com.hbt.common.core.web.page.TableDataInfo; + +/** + * 人员信息Controller + * + * @author 张雨 + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/persion") +public class PersionController extends BaseController +{ + @Autowired + private IPersionService persionService; + + /** + * 查询人员信息列表 + */ + @GetMapping("/list") + public String list(Persion persion) + { + startPage(); + List list = persionService.selectPersionList(persion); + TableDataInfo tableDataInfo = getDataTable(list); + return JSONObject.toJSONString(tableDataInfo); + } + + /** + * 获取人员信息详细信息 + */ + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + Persion persion = persionService.selectPersionById(id); + return JSONObject.toJSONString(persion); + } + + /** + * 新增人员信息 + */ + @GetMapping(value = "/add") + public String add(@RequestBody Persion persion) + { + AjaxResult ajaxResult = toAjax(persionService.insertPersion(persion)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改人员信息 + */ + @GetMapping(value = "/edit") + public String edit(@RequestBody Persion persion) + { + AjaxResult ajaxResult = toAjax(persionService.updatePersion(persion)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除人员信息 + */ + @GetMapping(value = "/remove") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(persionService.deletePersionByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/RiskAreaController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/RiskAreaController.java new file mode 100644 index 0000000..bf8162a --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/RiskAreaController.java @@ -0,0 +1,83 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.RiskArea; +import com.hbt.safety.supervision.service.IRiskAreaService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; +import com.hbt.common.core.web.page.TableDataInfo; + +/** + * 风险区域Controller + * + * @author 张雨 + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/area") +public class RiskAreaController extends BaseController +{ + @Autowired + private IRiskAreaService riskAreaService; + + /** + * 查询风险区域列表 + */ + @GetMapping("/list") + public String list(RiskArea riskArea) + { + startPage(); + List list = riskAreaService.selectRiskAreaList(riskArea); + TableDataInfo tableDataInfo = getDataTable(list); + return JSONObject.toJSONString(tableDataInfo); + } + + + /** + * 获取风险区域详细信息 + */ + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + AjaxResult ajaxResult = success(riskAreaService.selectRiskAreaById(id)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 新增风险区域 + */ + @GetMapping(value = "/add") + public String add(@RequestBody RiskArea riskArea) + { + AjaxResult ajaxResult = toAjax(riskAreaService.insertRiskArea(riskArea)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改风险区域 + */ + @GetMapping(value = "/edit") + public String edit(@RequestBody RiskArea riskArea) + { + AjaxResult ajaxResult = toAjax(riskAreaService.updateRiskArea(riskArea)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除风险区域 + */ + @GetMapping(value = "/remove") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(riskAreaService.deleteRiskAreaByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/RiskController.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/RiskController.java new file mode 100644 index 0000000..906a2a1 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/controller/RiskController.java @@ -0,0 +1,91 @@ +package com.hbt.safety.supervision.controller; + +import java.util.List; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.Risk; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.hbt.safety.supervision.service.IRiskService; +import com.hbt.common.core.web.controller.BaseController; +import com.hbt.common.core.web.domain.AjaxResult; +import com.hbt.common.core.web.page.TableDataInfo; + +/** + * 风险Controller + * + * @author 张雨 + * @date 2023-02-14 + */ +@RestController +@RequestMapping("/risk") +public class RiskController extends BaseController +{ + @Autowired + private IRiskService riskService; + + /** + * 查询风险列表 + */ + @GetMapping("/list") + public String list(Risk risk) + { + startPage(); + List list = riskService.selectRiskList(risk); + TableDataInfo tableDataInfo = getDataTable(list); + return JSONObject.toJSONString(tableDataInfo); + } + + /** + * 获取风险详细信息 + */ + @GetMapping(value = "/{id}") + public String getInfo(@PathVariable("id") int id) + { + AjaxResult ajaxResult = success(riskService.selectRiskById(id)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 新增风险 + */ + @GetMapping("/add") + public String add(@RequestBody Risk risk) + { + AjaxResult ajaxResult = toAjax(riskService.insertRisk(risk)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 修改风险 + */ + @GetMapping("/edit") + public String edit(@RequestBody Risk risk) + { + AjaxResult ajaxResult = toAjax(riskService.updateRisk(risk)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 删除风险 + */ + @GetMapping("/{ids}") + public String remove(@PathVariable int[] ids) + { + AjaxResult ajaxResult = toAjax(riskService.deleteRiskByIds(ids)); + return JSONObject.toJSONString(ajaxResult); + } + + /** + * 风险统计 + * @return + */ + @GetMapping("/riskStatistics") + public String riskStatistics() { + return riskService.riskStatistics(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EnterpriseInfomationMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EnterpriseInfomationMapper.java new file mode 100644 index 0000000..403e2d7 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EnterpriseInfomationMapper.java @@ -0,0 +1,76 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; +import java.util.Map; + +import com.hbt.safety.supervision.pojo.EnterpriseInfomation; + +/** + * 企业信息Mapper接口 + * + * @author zhangyu + * @date 2023-02-14 + */ +public interface EnterpriseInfomationMapper +{ + /** + * 查询企业信息 + * + * @param id 企业信息主键 + * @return 企业信息 + */ + EnterpriseInfomation selectEnterpriseInfomationById(int id); + + /** + * 查询企业信息列表 + * + * @param enterpriseInfomation 企业信息 + * @return 企业信息集合 + */ + List selectEnterpriseInfomationList(EnterpriseInfomation enterpriseInfomation); + + /** + * 新增企业信息 + * + * @param enterpriseInfomation 企业信息 + * @return 结果 + */ + int insertEnterpriseInfomation(EnterpriseInfomation enterpriseInfomation); + + /** + * 修改企业信息 + * + * @param enterpriseInfomation 企业信息 + * @return 结果 + */ + int updateEnterpriseInfomation(EnterpriseInfomation enterpriseInfomation); + + /** + * 删除企业信息 + * + * @param id 企业信息主键 + * @return 结果 + */ + int deleteEnterpriseInfomationById(int id); + + /** + * 批量删除企业信息 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteEnterpriseInfomationByIds(int[] ids); + + /** + * 查询企业信息列表 + * + * @return 企业信息集合 + */ + List selectEnterpriseInfomations(); + + List> enterpriseStatistics(); + + int getEnterpriseCount(); + + int getCarCount(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EscalateHiddenDangerMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EscalateHiddenDangerMapper.java new file mode 100644 index 0000000..cae3c50 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EscalateHiddenDangerMapper.java @@ -0,0 +1,66 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.EscalateHiddenDanger; + +/** + * 上报隐患Mapper接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +public interface EscalateHiddenDangerMapper +{ + /** + * 查询上报隐患 + * + * @param id 上报隐患主键 + * @return 上报隐患 + */ + EscalateHiddenDanger selectEscalateHiddenDangerById(int id); + + /** + * 查询上报隐患列表 + * + * @param escalateHiddenDanger 上报隐患 + * @return 上报隐患集合 + */ + List selectEscalateHiddenDangerList(EscalateHiddenDanger escalateHiddenDanger); + + /** + * 新增上报隐患 + * + * @param escalateHiddenDanger 上报隐患 + * @return 结果 + */ + int insertEscalateHiddenDanger(EscalateHiddenDanger escalateHiddenDanger); + + /** + * 修改上报隐患 + * + * @param escalateHiddenDanger 上报隐患 + * @return 结果 + */ + int updateEscalateHiddenDanger(EscalateHiddenDanger escalateHiddenDanger); + + /** + * 删除上报隐患 + * + * @param id 上报隐患主键 + * @return 结果 + */ + int deleteEscalateHiddenDangerById(int id); + + /** + * 批量删除上报隐患 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteEscalateHiddenDangerByIds(int[] ids); + + int getTotalEscalateHiddenDanger(); + + List getEscalateHiddenDangerIds(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EscalateRiskMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EscalateRiskMapper.java new file mode 100644 index 0000000..6162674 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/EscalateRiskMapper.java @@ -0,0 +1,63 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; +import com.hbt.safety.supervision.pojo.EscalateRisk; + +/** + * 上报风险Mapper接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +public interface EscalateRiskMapper +{ + /** + * 查询上报风险 + * + * @param id 上报风险主键 + * @return 上报风险 + */ + EscalateRisk selectEscalateRiskById(int id); + + /** + * 查询上报风险列表 + * + * @param escalateRisk 上报风险 + * @return 上报风险集合 + */ + List selectEscalateRiskList(EscalateRisk escalateRisk); + + /** + * 新增上报风险 + * + * @param escalateRisk 上报风险 + * @return 结果 + */ + int insertEscalateRisk(EscalateRisk escalateRisk); + + /** + * 修改上报风险 + * + * @param escalateRisk 上报风险 + * @return 结果 + */ + int updateEscalateRisk(EscalateRisk escalateRisk); + + /** + * 删除上报风险 + * + * @param id 上报风险主键 + * @return 结果 + */ + int deleteEscalateRiskById(int id); + + /** + * 批量删除上报风险 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteEscalateRiskByIds(int[] ids); + + List getEscalateRiskIds(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/HazardousOperationMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/HazardousOperationMapper.java new file mode 100644 index 0000000..d89cff7 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/HazardousOperationMapper.java @@ -0,0 +1,69 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.HazardousOperation; + +/** + * 危险作业Mapper接口 + * + * @author zhangyu + * @date 2023-02-14 + */ +public interface HazardousOperationMapper +{ + /** + * 查询危险作业 + * + * @param id 危险作业主键 + * @return 危险作业 + */ + HazardousOperation selectHazardousOperationById(int id); + + /** + * 查询危险作业列表 + * + * @param hazardousOperation 危险作业 + * @return 危险作业集合 + */ + List selectHazardousOperationList(HazardousOperation hazardousOperation); + + /** + * 新增危险作业 + * + * @param hazardousOperation 危险作业 + * @return 结果 + */ + int insertHazardousOperation(HazardousOperation hazardousOperation); + + /** + * 修改危险作业 + * + * @param hazardousOperation 危险作业 + * @return 结果 + */ + int updateHazardousOperation(HazardousOperation hazardousOperation); + + /** + * 删除危险作业 + * + * @param id 危险作业主键 + * @return 结果 + */ + int deleteHazardousOperationById(int id); + + /** + * 批量删除危险作业 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteHazardousOperationByIds(int[] ids); + + /** + * 查询统计所需数据 + * @return + */ + + List selectHazardousOperations(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/HiddenDangerMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/HiddenDangerMapper.java new file mode 100644 index 0000000..b6d9fed --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/HiddenDangerMapper.java @@ -0,0 +1,64 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.HiddenDanger; + +/** + * 隐患Mapper接口 + * + * @author hbt + * @date 2023-02-14 + */ +public interface HiddenDangerMapper +{ + /** + * 查询隐患 + * + * @param id 隐患主键 + * @return 隐患 + */ + HiddenDanger selectHiddenDangerById(int id); + + /** + * 查询隐患列表 + * + * @param hiddenDanger 隐患 + * @return 隐患集合 + */ + List selectHiddenDangerList(HiddenDanger hiddenDanger); + + /** + * 新增隐患 + * + * @param hiddenDanger 隐患 + * @return 结果 + */ + int insertHiddenDanger(HiddenDanger hiddenDanger); + + /** + * 修改隐患 + * + * @param hiddenDanger 隐患 + * @return 结果 + */ + int updateHiddenDanger(HiddenDanger hiddenDanger); + + /** + * 删除隐患 + * + * @param id 隐患主键 + * @return 结果 + */ + int deleteHiddenDangerById(int id); + + /** + * 批量删除隐患 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteHiddenDangerByIds(int[] ids); + + List selectHiddenDangers(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/LawEnforcementInspectionMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/LawEnforcementInspectionMapper.java new file mode 100644 index 0000000..b3df12a --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/LawEnforcementInspectionMapper.java @@ -0,0 +1,65 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.LawEnforcementInspection; +import com.hbt.safety.supervision.pojo.vo.LawEnforcementInspectionVo; + +/** + * 执法巡查Mapper接口 + * + * @author zhangyu + * @date 2023-02-14 + */ +public interface LawEnforcementInspectionMapper +{ + /** + * 查询执法巡查 + * + * @param id 执法巡查主键 + * @return 执法巡查 + */ + LawEnforcementInspection selectLawEnforcementInspectionById(int id); + + /** + * 查询执法巡查列表 + * + * @param lawEnforcementInspection 执法巡查 + * @return 执法巡查集合 + */ + List selectLawEnforcementInspectionList(LawEnforcementInspection lawEnforcementInspection); + + /** + * 新增执法巡查 + * + * @param lawEnforcementInspection 执法巡查 + * @return 结果 + */ + int insertLawEnforcementInspection(LawEnforcementInspection lawEnforcementInspection); + + /** + * 修改执法巡查 + * + * @param lawEnforcementInspection 执法巡查 + * @return 结果 + */ + int updateLawEnforcementInspection(LawEnforcementInspection lawEnforcementInspection); + + /** + * 删除执法巡查 + * + * @param id 执法巡查主键 + * @return 结果 + */ + int deleteLawEnforcementInspectionById(int id); + + /** + * 批量删除执法巡查 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteLawEnforcementInspectionByIds(int[] ids); + + List selectLawEnforcementInspections(int year); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/MajorHazardSourcesMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/MajorHazardSourcesMapper.java new file mode 100644 index 0000000..35dc2bb --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/MajorHazardSourcesMapper.java @@ -0,0 +1,64 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.MajorHazardSources; + +/** + * 重大危险源Mapper接口 + * + * @author zhangyu + * @date 2023-02-14 + */ +public interface MajorHazardSourcesMapper +{ + /** + * 查询重大危险源 + * + * @param id 重大危险源主键 + * @return 重大危险源 + */ + MajorHazardSources selectMajorHazardSourcesById(int id); + + /** + * 查询重大危险源列表 + * + * @param majorHazardSources 重大危险源 + * @return 重大危险源集合 + */ + List selectMajorHazardSourcesList(MajorHazardSources majorHazardSources); + + /** + * 新增重大危险源 + * + * @param majorHazardSources 重大危险源 + * @return 结果 + */ + int insertMajorHazardSources(MajorHazardSources majorHazardSources); + + /** + * 修改重大危险源 + * + * @param majorHazardSources 重大危险源 + * @return 结果 + */ + int updateMajorHazardSources(MajorHazardSources majorHazardSources); + + /** + * 删除重大危险源 + * + * @param id 重大危险源主键 + * @return 结果 + */ + int deleteMajorHazardSourcesById(int id); + + /** + * 批量删除重大危险源 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteMajorHazardSourcesByIds(int[] ids); + + List majorHazardSourcesStatistics(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/PersionMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/PersionMapper.java new file mode 100644 index 0000000..834c97f --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/PersionMapper.java @@ -0,0 +1,64 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.Persion; + +/** + * 人员信息Mapper接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +public interface PersionMapper +{ + /** + * 查询人员信息 + * + * @param id 人员信息主键 + * @return 人员信息 + */ + Persion selectPersionById(int id); + + /** + * 查询人员信息列表 + * + * @param persion 人员信息 + * @return 人员信息集合 + */ + List selectPersionList(Persion persion); + + /** + * 新增人员信息 + * + * @param persion 人员信息 + * @return 结果 + */ + int insertPersion(Persion persion); + + /** + * 修改人员信息 + * + * @param persion 人员信息 + * @return 结果 + */ + int updatePersion(Persion persion); + + /** + * 删除人员信息 + * + * @param id 人员信息主键 + * @return 结果 + */ + int deletePersionById(int id); + + /** + * 批量删除人员信息 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deletePersionByIds(int[] ids); + + int getPersionCount(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/RiskAreaMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/RiskAreaMapper.java new file mode 100644 index 0000000..d5ebf1b --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/RiskAreaMapper.java @@ -0,0 +1,61 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; +import com.hbt.safety.supervision.pojo.RiskArea; + +/** + * 风险区域Mapper接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +public interface RiskAreaMapper +{ + /** + * 查询风险区域 + * + * @param id 风险区域主键 + * @return 风险区域 + */ + RiskArea selectRiskAreaById(int id); + + /** + * 查询风险区域列表 + * + * @param riskArea 风险区域 + * @return 风险区域集合 + */ + List selectRiskAreaList(RiskArea riskArea); + + /** + * 新增风险区域 + * + * @param riskArea 风险区域 + * @return 结果 + */ + int insertRiskArea(RiskArea riskArea); + + /** + * 修改风险区域 + * + * @param riskArea 风险区域 + * @return 结果 + */ + int updateRiskArea(RiskArea riskArea); + + /** + * 删除风险区域 + * + * @param id 风险区域主键 + * @return 结果 + */ + int deleteRiskAreaById(int id); + + /** + * 批量删除风险区域 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteRiskAreaByIds(int[] ids); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/RiskMapper.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/RiskMapper.java new file mode 100644 index 0000000..7f44418 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/mapper/RiskMapper.java @@ -0,0 +1,69 @@ +package com.hbt.safety.supervision.mapper; + +import java.util.List; +import java.util.Map; + +import com.hbt.safety.supervision.pojo.Risk; +import org.apache.ibatis.annotations.Mapper; + +/** + * 风险Mapper接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +@Mapper +public interface RiskMapper +{ + /** + * 查询风险 + * + * @param id 风险主键 + * @return 风险 + */ + Risk selectRiskById(int id); + + /** + * 查询风险列表 + * + * @param risk 风险 + * @return 风险集合 + */ + List selectRiskList(Risk risk); + + /** + * 新增风险 + * + * @param risk 风险 + * @return 结果 + */ + int insertRisk(Risk risk); + + /** + * 修改风险 + * + * @param risk 风险 + * @return 结果 + */ + int updateRisk(Risk risk); + + /** + * 删除风险 + * + * @param id 风险主键 + * @return 结果 + */ + int deleteRiskById(int id); + + /** + * 批量删除风险 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + int deleteRiskByIds(int[] ids); + + List> riskStatistics(); + + +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EnterpriseInfomation.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EnterpriseInfomation.java new file mode 100644 index 0000000..98e7ec6 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EnterpriseInfomation.java @@ -0,0 +1,205 @@ +package com.hbt.safety.supervision.pojo; + +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 企业信息对象 enterprise_infomation + * + * @author zhangyu + * @date 2023-02-14 + */ +public class EnterpriseInfomation extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 企业id */ + private int id; + + /** 统一社会信用代码 */ + @Excel(name = "统一社会信用代码") + private String unifySocialCreditCode; + + /** 企业名称 */ + @Excel(name = "企业名称") + private String name; + + /** 注册号 */ + @Excel(name = "注册号") + private String registrationNumber; + + /** 法定代表人 */ + @Excel(name = "法定代表人") + private String legalRepresentative; + + /** 类型 */ + @Excel(name = "类型") + private String type; + + /** 成立日期 */ + @Excel(name = "成立日期") + private String establishmentDate; + + /** 出资额 */ + @Excel(name = "出资额") + private String fundAmount; + + /** 核准日期 */ + @Excel(name = "核准日期") + private String approvalDate; + + /** 登记机关 */ + @Excel(name = "登记机关") + private String registrationAuthority; + + /** 等级状态 */ + @Excel(name = "等级状态") + private String registrationStatus; + + /** 住所 */ + @Excel(name = "住所") + private String dwellingPlace; + + /** 经营范围 */ + @Excel(name = "经营范围") + private String businessScope; + + public void setId(int id) + { + this.id = id; + } + + public int getId() + { + return id; + } + public void setUnifySocialCreditCode(String unifySocialCreditCode) + { + this.unifySocialCreditCode = unifySocialCreditCode; + } + + public String getUnifySocialCreditCode() + { + return unifySocialCreditCode; + } + public void setName(String name) + { + this.name = name; + } + + public String getName() + { + return name; + } + public void setRegistrationNumber(String registrationNumber) + { + this.registrationNumber = registrationNumber; + } + + public String getRegistrationNumber() + { + return registrationNumber; + } + public void setLegalRepresentative(String legalRepresentative) + { + this.legalRepresentative = legalRepresentative; + } + + public String getLegalRepresentative() + { + return legalRepresentative; + } + public void setType(String type) + { + this.type = type; + } + + public String getType() + { + return type; + } + public void setEstablishmentDate(String establishmentDate) + { + this.establishmentDate = establishmentDate; + } + + public String getEstablishmentDate() + { + return establishmentDate; + } + public void setFundAmount(String fundAmount) + { + this.fundAmount = fundAmount; + } + + public String getFundAmount() + { + return fundAmount; + } + public void setApprovalDate(String approvalDate) + { + this.approvalDate = approvalDate; + } + + public String getApprovalDate() + { + return approvalDate; + } + public void setRegistrationAuthority(String registrationAuthority) + { + this.registrationAuthority = registrationAuthority; + } + + public String getRegistrationAuthority() + { + return registrationAuthority; + } + public void setRegistrationStatus(String registrationStatus) + { + this.registrationStatus = registrationStatus; + } + + public String getRegistrationStatus() + { + return registrationStatus; + } + public void setDwellingPlace(String dwellingPlace) + { + this.dwellingPlace = dwellingPlace; + } + + public String getDwellingPlace() + { + return dwellingPlace; + } + public void setBusinessScope(String businessScope) + { + this.businessScope = businessScope; + } + + public String getBusinessScope() + { + return businessScope; + } + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("unifySocialCreditCode", getUnifySocialCreditCode()) + .append("name", getName()) + .append("registrationNumber", getRegistrationNumber()) + .append("legalRepresentative", getLegalRepresentative()) + .append("type", getType()) + .append("establishmentDate", getEstablishmentDate()) + .append("fundAmount", getFundAmount()) + .append("approvalDate", getApprovalDate()) + .append("registrationAuthority", getRegistrationAuthority()) + .append("registrationStatus", getRegistrationStatus()) + .append("dwellingPlace", getDwellingPlace()) + .append("businessScope", getBusinessScope()) + .toString(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EscalateHiddenDanger.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EscalateHiddenDanger.java new file mode 100644 index 0000000..4adb2ef --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EscalateHiddenDanger.java @@ -0,0 +1,65 @@ +package com.hbt.safety.supervision.pojo; + +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 上报隐患对象 escalate_hidden_danger + * + * @author 张雨 + * @date 2023-02-14 + */ +public class EscalateHiddenDanger extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 上报风险主键 */ + private int id; + + /** 巡检执法id */ + @Excel(name = "巡检执法id") + private int enforcementId; + + /** 隐患表id */ + @Excel(name = "隐患表id") + private int hiddenDangerId; + + public void setId(int id) + { + this.id = id; + } + + public int getId() + { + return id; + } + public void setEnforcementId(int enforcementId) + { + this.enforcementId = enforcementId; + } + + public int getEnforcementId() + { + return enforcementId; + } + public void setHiddenDangerId(int hiddenDangerId) + { + this.hiddenDangerId = hiddenDangerId; + } + + public int getHiddenDangerId() + { + return hiddenDangerId; + } + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("enforcementId", getEnforcementId()) + .append("hiddenDangerId", getHiddenDangerId()) + .toString(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EscalateRisk.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EscalateRisk.java new file mode 100644 index 0000000..d004dab --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/EscalateRisk.java @@ -0,0 +1,65 @@ +package com.hbt.safety.supervision.pojo; + +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 上报风险对象 escalate_risk + * + * @author 张雨 + * @date 2023-02-14 + */ +public class EscalateRisk extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 上报风险id */ + private int id; + + /** 执法巡检id */ + @Excel(name = "执法巡检id") + private int enforcementId; + + /** 风险表id */ + @Excel(name = "风险表id") + private int riskId; + + public void setId(int id) + { + this.id = id; + } + + public int getId() + { + return id; + } + public void setEnforcementId(int enforcementId) + { + this.enforcementId = enforcementId; + } + + public int getEnforcementId() + { + return enforcementId; + } + public void setRiskId(int riskId) + { + this.riskId = riskId; + } + + public int getRiskId() + { + return riskId; + } + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("enforcementId", getEnforcementId()) + .append("riskId", getRiskId()) + .toString(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/HazardousOperation.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/HazardousOperation.java new file mode 100644 index 0000000..1eaafe3 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/HazardousOperation.java @@ -0,0 +1,165 @@ +package com.hbt.safety.supervision.pojo; + +import java.util.Date; +import com.fasterxml.jackson.annotation.JsonFormat; +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 危险作业对象 hazardous_operation + * + * @author zhangyu + * @date 2023-02-14 + */ +public class HazardousOperation extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 危险作业id */ + private int id; + + /** 危险作业名称 */ + @Excel(name = "危险作业名称") + private String name; + + /** 危险作业等级 */ + private String operationLevel; + + /** 企业id */ + @Excel(name = "企业id") + private Long enterpriseId; + + /** 作业内容 */ + @Excel(name = "作业内容") + private String operationContent; + + /** 作业经度 */ + @Excel(name = "作业经度") + private String operationLongitude; + + /** 作业纬度 */ + @Excel(name = "作业纬度") + private String operationLatitude; + + /** 作业类型 */ + @Excel(name = "作业类型") + private Long operationType; + + /** 作业开始时间 */ + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "作业开始时间", width = 30, dateFormat = "yyyy-MM-dd") + private Date operationStart; + + /** 作业结束时间 */ + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "作业结束时间", width = 30, dateFormat = "yyyy-MM-dd") + private Date operationEnd; + + public void setId(int id) + { + this.id = id; + } + + public int getId() + { + return id; + } + public void setName(String name) + { + this.name = name; + } + + public String getName() + { + return name; + } + public void setEnterpriseId(Long enterpriseId) + { + this.enterpriseId = enterpriseId; + } + + public Long getEnterpriseId() + { + return enterpriseId; + } + public void setOperationContent(String operationContent) + { + this.operationContent = operationContent; + } + + public String getOperationContent() + { + return operationContent; + } + public void setOperationLongitude(String operationLongitude) + { + this.operationLongitude = operationLongitude; + } + + public String getOperationLongitude() + { + return operationLongitude; + } + public void setOperationLatitude(String operationLatitude) + { + this.operationLatitude = operationLatitude; + } + + public String getOperationLatitude() + { + return operationLatitude; + } + public void setOperationType(Long operationType) + { + this.operationType = operationType; + } + + public Long getOperationType() + { + return operationType; + } + public void setOperationStart(Date operationStart) + { + this.operationStart = operationStart; + } + + public Date getOperationStart() + { + return operationStart; + } + public void setOperationEnd(Date operationEnd) + { + this.operationEnd = operationEnd; + } + + public Date getOperationEnd() + { + return operationEnd; + } + + public String getOperationLevel() { + return operationLevel; + } + + public void setOperationLevel(String operationLevel) { + this.operationLevel = operationLevel; + } + + @Override + public String toString() { + return "HazardousOperation{" + + "id=" + id + + ", name='" + name + '\'' + + ", operationLevel='" + operationLevel + '\'' + + ", enterpriseId=" + enterpriseId + + ", operationContent='" + operationContent + '\'' + + ", operationLongitude='" + operationLongitude + '\'' + + ", operationLatitude='" + operationLatitude + '\'' + + ", operationType=" + operationType + + ", operationStart=" + operationStart + + ", operationEnd=" + operationEnd + + '}'; + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/HiddenDanger.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/HiddenDanger.java new file mode 100644 index 0000000..63d11ff --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/HiddenDanger.java @@ -0,0 +1,220 @@ +package com.hbt.safety.supervision.pojo; + +import java.util.Date; +import com.fasterxml.jackson.annotation.JsonFormat; +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 隐患对象 hidden_danger + * + * @author hbt + * @date 2023-02-14 + */ +public class HiddenDanger extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键id */ + private int id; + + /** 隐患名称 */ + @Excel(name = "隐患名称") + private String name; + + /** 隐患详情 */ + @Excel(name = "隐患详情") + private String details; + + /** 风险表id */ + @Excel(name = "风险表id") + private int riskId; + + /** 上报日期 */ + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "上报日期", width = 30, dateFormat = "yyyy-MM-dd") + private Date submitDate; + + /** 上报人id */ + @Excel(name = "上报人id") + private int submitPersonId; + + @Excel(name = "上报企业id") + private int submitEnterpriseId; + + /** 隐患整改措施 */ + @Excel(name = "隐患整改措施") + private String reformMeasures; + + /** 隐患状态 */ + @Excel(name = "隐患状态") + private String reformStatus; + + /** 超期状态 0-正常 1-超期 */ + @Excel(name = "超期状态") + private int exceedTimeLimitStatus; + + /** 企业id */ + @Excel(name = "企业id") + private int enterpriseId; + + /** 责任人id */ + @Excel(name = "责任人id") + private int personId; + + /** 备注 */ + @Excel(name = "备注") + private String remarks; + + /** 整改期限 */ + @Excel(name = "整改期限") + private String rectificationPeriod; + + public void setId(int id) + { + this.id = id; + } + + public int getId() + { + return id; + } + public void setName(String name) + { + this.name = name; + } + + public String getName() + { + return name; + } + public void setDetails(String details) + { + this.details = details; + } + + public String getDetails() + { + return details; + } + public void setRiskId(int riskId) + { + this.riskId = riskId; + } + + public int getRiskId() + { + return riskId; + } + public void setSubmitDate(Date submitDate) + { + this.submitDate = submitDate; + } + + public Date getSubmitDate() + { + return submitDate; + } + public void setSubmitPersonId(int submitPersonId) + { + this.submitPersonId = submitPersonId; + } + + public int getSubmitPersonId() + { + return submitPersonId; + } + public void setReformMeasures(String reformMeasures) + { + this.reformMeasures = reformMeasures; + } + + public String getReformMeasures() + { + return reformMeasures; + } + public void setReformStatus(String reformStatus) + { + this.reformStatus = reformStatus; + } + + public String getReformStatus() + { + return reformStatus; + } + public void setExceedTimeLimitStatus(int exceedTimeLimitStatus) + { + this.exceedTimeLimitStatus = exceedTimeLimitStatus; + } + + public int getExceedTimeLimitStatus() + { + return exceedTimeLimitStatus; + } + public void setEnterpriseId(int enterpriseId) + { + this.enterpriseId = enterpriseId; + } + + public int getEnterpriseId() + { + return enterpriseId; + } + public void setPersonId(int personId) + { + this.personId = personId; + } + + public int getPersonId() + { + return personId; + } + public void setRemarks(String remarks) + { + this.remarks = remarks; + } + + public String getRemarks() + { + return remarks; + } + public void setRectificationPeriod(String rectificationPeriod) + { + this.rectificationPeriod = rectificationPeriod; + } + + public String getRectificationPeriod() + { + return rectificationPeriod; + } + + public int getSubmitEnterpriseId() { + return submitEnterpriseId; + } + + public void setSubmitEnterpriseId(int submitEnterpriseId) { + this.submitEnterpriseId = submitEnterpriseId; + } + + @Override + public String toString() { + return "HiddenDanger{" + + "id=" + id + + ", name='" + name + '\'' + + ", details='" + details + '\'' + + ", riskId=" + riskId + + ", submitDate=" + submitDate + + ", submitPersonId=" + submitPersonId + + ", submitEnterpriseId=" + submitEnterpriseId + + ", reformMeasures='" + reformMeasures + '\'' + + ", reformStatus=" + reformStatus + + ", exceedTimeLimitStatus=" + exceedTimeLimitStatus + + ", enterpriseId=" + enterpriseId + + ", personId=" + personId + + ", remarks='" + remarks + '\'' + + ", rectificationPeriod='" + rectificationPeriod + '\'' + + '}'; + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/LawEnforcementInspection.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/LawEnforcementInspection.java new file mode 100644 index 0000000..67aded8 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/LawEnforcementInspection.java @@ -0,0 +1,96 @@ +package com.hbt.safety.supervision.pojo; + +import java.util.Date; +import com.fasterxml.jackson.annotation.JsonFormat; +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 执法巡查对象 law_enforcement_inspection + * + * @author zhangyu + * @date 2023-02-14 + */ +public class LawEnforcementInspection extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** $column.columnComment */ + private int id; + + /** 巡查日期 */ + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "巡查日期", width = 30, dateFormat = "yyyy-MM-dd") + private Date inspectionDate; + + /** 巡查人员id */ + @Excel(name = "巡查人员id") + private int persionId; + + /** 巡查名称 */ + @Excel(name = "巡查名称") + private String name; + + /** 备注 */ + @Excel(name = "备注") + private String remarks; + + public void setId(int id) + { + this.id = id; + } + + public int getId() + { + return id; + } + public void setInspectionDate(Date inspectionDate) + { + this.inspectionDate = inspectionDate; + } + + public Date getInspectionDate() + { + return inspectionDate; + } + public void setPersionId(int persionId) + { + this.persionId = persionId; + } + + public int getPersionId() + { + return persionId; + } + public void setName(String name) + { + this.name = name; + } + + public String getName() + { + return name; + } + public void setRemarks(String remarks) + { + this.remarks = remarks; + } + + public String getRemarks() + { + return remarks; + } + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("inspectionDate", getInspectionDate()) + .append("persionId", getPersionId()) + .append("name", getName()) + .append("remarks", getRemarks()) + .toString(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/MajorHazardSources.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/MajorHazardSources.java new file mode 100644 index 0000000..1963b32 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/MajorHazardSources.java @@ -0,0 +1,270 @@ +package com.hbt.safety.supervision.pojo; + +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import lombok.Data; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 重大危险源对象 major_hazard_sources + * + * @author zhangyu + * @date 2023-02-14 + */ +public class MajorHazardSources extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键id */ + private int id; + + /** 主要负责人id */ + private int mainResponsiblePersonId; + + /** 主要负责人 */ + private String mainResponsiblePerson; + + /** 技术负责人id */ + private int technologyResponsiblePersonId; + + /** 技术负责人id */ + private String technologyResponsiblePerson; + + /** 操作负责人id */ + private int operateResponsiblePersonId; + + /** 操作负责人id */ + private String operateResponsiblePerson; + + /** 危险源名称 */ + @Excel(name = "危险源名称") + private String name; + + /** 危险因素 */ + @Excel(name = "危险因素") + private String riskFactor; + + /** 可能导致后果 */ + @Excel(name = "可能导致后果") + private String consequence; + + /** 风险等级 */ + @Excel(name = "风险等级") + private Integer dangerLevel; + + /** 管控措施 */ + @Excel(name = "管控措施") + private String controlMeasures; + + /** 危险源统一编码 */ + @Excel(name = "危险源统一编码") + private String unifiedCoding; + + /** 单元类型 */ + private String unitType; + + /** 当前存储量 */ + private String memorySpace; + + /** 经度 */ + private String longitude; + + /** 纬度 */ + private String latitude; + + /** 责任公司id */ + private int enterpriseId; + + /** 责任公司 */ + private String enterprise; + + /** 管理危化品名称 */ + private String hazardousChemicalsName; + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getMainResponsiblePersonId() { + return mainResponsiblePersonId; + } + + public void setMainResponsiblePersonId(int mainResponsiblePersonId) { + this.mainResponsiblePersonId = mainResponsiblePersonId; + } + + public String getMainResponsiblePerson() { + return mainResponsiblePerson; + } + + public void setMainResponsiblePerson(String mainResponsiblePerson) { + this.mainResponsiblePerson = mainResponsiblePerson; + } + + public int getTechnologyResponsiblePersonId() { + return technologyResponsiblePersonId; + } + + public void setTechnologyResponsiblePersonId(int technologyResponsiblePersonId) { + this.technologyResponsiblePersonId = technologyResponsiblePersonId; + } + + public String getTechnologyResponsiblePerson() { + return technologyResponsiblePerson; + } + + public void setTechnologyResponsiblePerson(String technologyResponsiblePerson) { + this.technologyResponsiblePerson = technologyResponsiblePerson; + } + + public int getOperateResponsiblePersonId() { + return operateResponsiblePersonId; + } + + public void setOperateResponsiblePersonId(int operateResponsiblePersonId) { + this.operateResponsiblePersonId = operateResponsiblePersonId; + } + + public String getOperateResponsiblePerson() { + return operateResponsiblePerson; + } + + public void setOperateResponsiblePerson(String operateResponsiblePerson) { + this.operateResponsiblePerson = operateResponsiblePerson; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getRiskFactor() { + return riskFactor; + } + + public void setRiskFactor(String riskFactor) { + this.riskFactor = riskFactor; + } + + public String getConsequence() { + return consequence; + } + + public void setConsequence(String consequence) { + this.consequence = consequence; + } + + public Integer getDangerLevel() { + return dangerLevel; + } + + public void setDangerLevel(Integer dangerLevel) { + this.dangerLevel = dangerLevel; + } + + public String getControlMeasures() { + return controlMeasures; + } + + public void setControlMeasures(String controlMeasures) { + this.controlMeasures = controlMeasures; + } + + public String getUnifiedCoding() { + return unifiedCoding; + } + + public void setUnifiedCoding(String unifiedCoding) { + this.unifiedCoding = unifiedCoding; + } + + public String getUnitType() { + return unitType; + } + + public void setUnitType(String unitType) { + this.unitType = unitType; + } + + public String getMemorySpace() { + return memorySpace; + } + + public void setMemorySpace(String memorySpace) { + this.memorySpace = memorySpace; + } + + public String getLongitude() { + return longitude; + } + + public void setLongitude(String longitude) { + this.longitude = longitude; + } + + public String getLatitude() { + return latitude; + } + + public void setLatitude(String latitude) { + this.latitude = latitude; + } + + public int getEnterpriseId() { + return enterpriseId; + } + + public void setEnterpriseId(int enterpriseId) { + this.enterpriseId = enterpriseId; + } + + public String getEnterprise() { + return enterprise; + } + + public void setEnterprise(String enterprise) { + this.enterprise = enterprise; + } + + public String getHazardousChemicalsName() { + return hazardousChemicalsName; + } + + public void setHazardousChemicalsName(String hazardousChemicalsName) { + this.hazardousChemicalsName = hazardousChemicalsName; + } + + @Override + public String toString() { + return "MajorHazardSources{" + + "id=" + id + + ", mainResponsiblePersonId=" + mainResponsiblePersonId + + ", mainResponsiblePerson='" + mainResponsiblePerson + '\'' + + ", technologyResponsiblePersonId=" + technologyResponsiblePersonId + + ", technologyResponsiblePerson='" + technologyResponsiblePerson + '\'' + + ", operateResponsiblePersonId=" + operateResponsiblePersonId + + ", operateResponsiblePerson='" + operateResponsiblePerson + '\'' + + ", name='" + name + '\'' + + ", riskFactor='" + riskFactor + '\'' + + ", consequence='" + consequence + '\'' + + ", dangerLevel=" + dangerLevel + + ", controlMeasures='" + controlMeasures + '\'' + + ", unifiedCoding='" + unifiedCoding + '\'' + + ", unitType='" + unitType + '\'' + + ", memorySpace='" + memorySpace + '\'' + + ", longitude='" + longitude + '\'' + + ", latitude='" + latitude + '\'' + + ", enterpriseId=" + enterpriseId + + ", enterprise='" + enterprise + '\'' + + ", hazardousChemicalsName='" + hazardousChemicalsName + '\'' + + '}'; + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/Persion.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/Persion.java new file mode 100644 index 0000000..4b62d00 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/Persion.java @@ -0,0 +1,46 @@ +package com.hbt.safety.supervision.pojo; + +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import lombok.Data; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 人员信息对象 persion + * + * @author 张雨 + * @date 2023-02-14 + */ +@Data +public class Persion extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 人员信息表id */ + private int id; + + /** 人员名称 */ + private String name; + + /** 性别 */ + private Integer sex; + + /** 年龄 */ + private Integer age; + + /** 身份证号 */ + private String identityCard; + + /** 企业id */ + private int enterpriseId; + + /** 联系电话 */ + private String phone; + + /** 备注 */ + private String remarks; + + /** 联系地址 */ + private String addr; +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/Risk.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/Risk.java new file mode 100644 index 0000000..8a66811 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/Risk.java @@ -0,0 +1,180 @@ +package com.hbt.safety.supervision.pojo; + +import java.util.Date; +import com.fasterxml.jackson.annotation.JsonFormat; +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 风险对象 risk + * + * @author 张雨 + * @date 2023-02-14 + */ +public class Risk extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键 */ + private int id; + + /** 风险名称 */ + @Excel(name = "风险名称") + private String name; + + /** 风险概率 */ + @Excel(name = "风险概率") + private String riskProbability; + + /** 风险因素 */ + @Excel(name = "风险因素") + private String riskFactor; + + /** 影响后果 */ + @Excel(name = "影响后果") + private String affectConsequences; + + /** 风险等级 */ + @Excel(name = "风险等级") + private int level; + + /** 企业id */ + @Excel(name = "企业id") + private int enterpriseId; + + /** 责任人id */ + @Excel(name = "责任人id") + private int responsiblePersonId; + + /** 风险管控措施 */ + @Excel(name = "风险管控措施") + private String riskControlMeasures; + + /** 最后一次审查日期 */ + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "最后一次审查日期", width = 30, dateFormat = "yyyy-MM-dd") + private Date lastReviewDate; + + /** 重大危险源id */ + @Excel(name = "重大危险源id") + private int majorHazardSourcesId; + + public void setId(int id) + { + this.id = id; + } + + public int getId() + { + return id; + } + public void setName(String name) + { + this.name = name; + } + + public String getName() + { + return name; + } + public void setRiskProbability(String riskProbability) + { + this.riskProbability = riskProbability; + } + + public String getRiskProbability() + { + return riskProbability; + } + public void setRiskFactor(String riskFactor) + { + this.riskFactor = riskFactor; + } + + public String getRiskFactor() + { + return riskFactor; + } + public void setAffectConsequences(String affectConsequences) + { + this.affectConsequences = affectConsequences; + } + + public String getAffectConsequences() + { + return affectConsequences; + } + public void setLevel(int level) + { + this.level = level; + } + + public int getLevel() + { + return level; + } + public void setEnterpriseId(int enterpriseId) + { + this.enterpriseId = enterpriseId; + } + + public int getEnterpriseId() + { + return enterpriseId; + } + public void setResponsiblePersonId(int responsiblePersonId) + { + this.responsiblePersonId = responsiblePersonId; + } + + public int getResponsiblePersonId() + { + return responsiblePersonId; + } + public void setRiskControlMeasures(String riskControlMeasures) + { + this.riskControlMeasures = riskControlMeasures; + } + + public String getRiskControlMeasures() + { + return riskControlMeasures; + } + public void setLastReviewDate(Date lastReviewDate) + { + this.lastReviewDate = lastReviewDate; + } + + public Date getLastReviewDate() + { + return lastReviewDate; + } + public void setMajorHazardSourcesId(int majorHazardSourcesId) + { + this.majorHazardSourcesId = majorHazardSourcesId; + } + + public int getMajorHazardSourcesId() + { + return majorHazardSourcesId; + } + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("name", getName()) + .append("riskProbability", getRiskProbability()) + .append("riskFactor", getRiskFactor()) + .append("affectConsequences", getAffectConsequences()) + .append("level", getLevel()) + .append("enterpriseId", getEnterpriseId()) + .append("responsiblePersonId", getResponsiblePersonId()) + .append("riskControlMeasures", getRiskControlMeasures()) + .append("lastReviewDate", getLastReviewDate()) + .append("majorHazardSourcesId", getMajorHazardSourcesId()) + .toString(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/RiskArea.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/RiskArea.java new file mode 100644 index 0000000..626a98f --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/RiskArea.java @@ -0,0 +1,79 @@ +package com.hbt.safety.supervision.pojo; + +import com.hbt.common.core.annotation.Excel; +import com.hbt.common.core.web.domain.BaseEntity; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +/** + * 风险区域对象 risk_area + * + * @author 张雨 + * @date 2023-02-14 + */ +public class RiskArea extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键id */ + private int id; + + /** 风险区域名称 */ + @Excel(name = "风险区域名称") + private String name; + + /** 风险区域polgyn */ + @Excel(name = "风险区域polgyn") + private String polgyn; + + /** 风险等级 */ + @Excel(name = "风险等级") + private Integer riskLevel; + + public void setId(int id) + { + this.id = id; + } + + public int getId() + { + return id; + } + public void setName(String name) + { + this.name = name; + } + + public String getName() + { + return name; + } + public void setPolgyn(String polgyn) + { + this.polgyn = polgyn; + } + + public String getPolgyn() + { + return polgyn; + } + public void setRiskLevel(Integer riskLevel) + { + this.riskLevel = riskLevel; + } + + public Integer getRiskLevel() + { + return riskLevel; + } + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("name", getName()) + .append("polgyn", getPolgyn()) + .append("riskLevel", getRiskLevel()) + .toString(); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/vo/LawEnforcementInspectionStatics.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/vo/LawEnforcementInspectionStatics.java new file mode 100644 index 0000000..f8a1642 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/vo/LawEnforcementInspectionStatics.java @@ -0,0 +1,57 @@ +package com.hbt.safety.supervision.pojo.vo; + + +/** + * 执法法巡同 + */ +public class LawEnforcementInspectionStatics { + private Object month; // 月份 + + private int inspectionCount; // 巡查次数 + + private int hiddenTroubleCount; // 发现隐患数 + + private int riskCount; // 发现风险数 + + public Object getMonth() { + return month; + } + + public void setMonth(Object month) { + this.month = month; + } + + public int getInspectionCount() { + return inspectionCount; + } + + public void setInspectionCount(int inspectionCount) { + this.inspectionCount = inspectionCount; + } + + public int getHiddenTroubleCount() { + return hiddenTroubleCount; + } + + public void setHiddenTroubleCount(int hiddenTroubleCount) { + this.hiddenTroubleCount = hiddenTroubleCount; + } + + public int getRiskCount() { + return riskCount; + } + + public void setRiskCount(int riskCount) { + this.riskCount = riskCount; + } + + @Override + public String toString() { + return "LawEnforcementInspectionStatics{" + + "month=" + month + + ", inspectionCount=" + inspectionCount + + ", hiddenTroubleCount=" + hiddenTroubleCount + + ", riskCount=" + riskCount + + '}'; + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/vo/LawEnforcementInspectionVo.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/vo/LawEnforcementInspectionVo.java new file mode 100644 index 0000000..ddf2497 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/pojo/vo/LawEnforcementInspectionVo.java @@ -0,0 +1,36 @@ +package com.hbt.safety.supervision.pojo.vo; + +import lombok.Data; + +/** + * 执法巡查表vo + */ +public class LawEnforcementInspectionVo { + private String id; // 主键 + + private int inspectionDate; // 月份 + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public int getInspectionDate() { + return inspectionDate; + } + + public void setInspectionDate(int inspectionDate) { + this.inspectionDate = inspectionDate; + } + + @Override + public String toString() { + return "LawEnforcementInspectionVo{" + + "id='" + id + '\'' + + ", inspectionDate=" + inspectionDate + + '}'; + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEnterpriseInfomationService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEnterpriseInfomationService.java new file mode 100644 index 0000000..3ac5df3 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEnterpriseInfomationService.java @@ -0,0 +1,64 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.EnterpriseInfomation; + +/** + * 企业信息Service接口 + * + * @author zhangyu + * @date 2023-02-14 + */ +public interface IEnterpriseInfomationService +{ + /** + * 查询企业信息 + * + * @param id 企业信息主键 + * @return 企业信息 + */ + EnterpriseInfomation selectEnterpriseInfomationById(int id); + + /** + * 查询企业信息列表 + * + * @param enterpriseInfomation 企业信息 + * @return 企业信息集合 + */ + List selectEnterpriseInfomationList(EnterpriseInfomation enterpriseInfomation); + + /** + * 新增企业信息 + * + * @param enterpriseInfomation 企业信息 + * @return 结果 + */ + int insertEnterpriseInfomation(EnterpriseInfomation enterpriseInfomation); + + /** + * 修改企业信息 + * + * @param enterpriseInfomation 企业信息 + * @return 结果 + */ + int updateEnterpriseInfomation(EnterpriseInfomation enterpriseInfomation); + + /** + * 批量删除企业信息 + * + * @param ids 需要删除的企业信息主键集合 + * @return 结果 + */ + int deleteEnterpriseInfomationByIds(int[] ids); + + /** + * 删除企业信息信息 + * + * @param id 企业信息主键 + * @return 结果 + */ + int deleteEnterpriseInfomationById(int id); + + String enterpriseStatistics(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEscalateHiddenDangerService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEscalateHiddenDangerService.java new file mode 100644 index 0000000..efdcdf8 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEscalateHiddenDangerService.java @@ -0,0 +1,62 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.EscalateHiddenDanger; + +/** + * 上报隐患Service接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +public interface IEscalateHiddenDangerService +{ + /** + * 查询上报隐患 + * + * @param id 上报隐患主键 + * @return 上报隐患 + */ + EscalateHiddenDanger selectEscalateHiddenDangerById(int id); + + /** + * 查询上报隐患列表 + * + * @param escalateHiddenDanger 上报隐患 + * @return 上报隐患集合 + */ + List selectEscalateHiddenDangerList(EscalateHiddenDanger escalateHiddenDanger); + + /** + * 新增上报隐患 + * + * @param escalateHiddenDanger 上报隐患 + * @return 结果 + */ + int insertEscalateHiddenDanger(EscalateHiddenDanger escalateHiddenDanger); + + /** + * 修改上报隐患 + * + * @param escalateHiddenDanger 上报隐患 + * @return 结果 + */ + int updateEscalateHiddenDanger(EscalateHiddenDanger escalateHiddenDanger); + + /** + * 批量删除上报隐患 + * + * @param ids 需要删除的上报隐患主键集合 + * @return 结果 + */ + int deleteEscalateHiddenDangerByIds(int[] ids); + + /** + * 删除上报隐患信息 + * + * @param id 上报隐患主键 + * @return 结果 + */ + int deleteEscalateHiddenDangerById(int id); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEscalateRiskService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEscalateRiskService.java new file mode 100644 index 0000000..61b060a --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IEscalateRiskService.java @@ -0,0 +1,62 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.EscalateRisk; + +/** + * 上报风险Service接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +public interface IEscalateRiskService +{ + /** + * 查询上报风险 + * + * @param id 上报风险主键 + * @return 上报风险 + */ + EscalateRisk selectEscalateRiskById(int id); + + /** + * 查询上报风险列表 + * + * @param escalateRisk 上报风险 + * @return 上报风险集合 + */ + List selectEscalateRiskList(EscalateRisk escalateRisk); + + /** + * 新增上报风险 + * + * @param escalateRisk 上报风险 + * @return 结果 + */ + int insertEscalateRisk(EscalateRisk escalateRisk); + + /** + * 修改上报风险 + * + * @param escalateRisk 上报风险 + * @return 结果 + */ + int updateEscalateRisk(EscalateRisk escalateRisk); + + /** + * 批量删除上报风险 + * + * @param ids 需要删除的上报风险主键集合 + * @return 结果 + */ + int deleteEscalateRiskByIds(int[] ids); + + /** + * 删除上报风险信息 + * + * @param id 上报风险主键 + * @return 结果 + */ + int deleteEscalateRiskById(int id); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IHazardousOperationService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IHazardousOperationService.java new file mode 100644 index 0000000..3618033 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IHazardousOperationService.java @@ -0,0 +1,64 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.HazardousOperation; + +/** + * 危险作业Service接口 + * + * @author zhangyu + * @date 2023-02-14 + */ +public interface IHazardousOperationService +{ + /** + * 查询危险作业 + * + * @param id 危险作业主键 + * @return 危险作业 + */ + HazardousOperation selectHazardousOperationById(int id); + + /** + * 查询危险作业列表 + * + * @param hazardousOperation 危险作业 + * @return 危险作业集合 + */ + List selectHazardousOperationList(HazardousOperation hazardousOperation); + + /** + * 新增危险作业 + * + * @param hazardousOperation 危险作业 + * @return 结果 + */ + int insertHazardousOperation(HazardousOperation hazardousOperation); + + /** + * 修改危险作业 + * + * @param hazardousOperation 危险作业 + * @return 结果 + */ + int updateHazardousOperation(HazardousOperation hazardousOperation); + + /** + * 批量删除危险作业 + * + * @param ids 需要删除的危险作业主键集合 + * @return 结果 + */ + int deleteHazardousOperationByIds(int[] ids); + + /** + * 删除危险作业信息 + * + * @param id 危险作业主键 + * @return 结果 + */ + int deleteHazardousOperationById(int id); + + String hazardousOperationStatistics(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IHiddenDangerService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IHiddenDangerService.java new file mode 100644 index 0000000..e418ab8 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IHiddenDangerService.java @@ -0,0 +1,64 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.HiddenDanger; + +/** + * 隐患Service接口 + * + * @author hbt + * @date 2023-02-14 + */ +public interface IHiddenDangerService +{ + /** + * 查询隐患 + * + * @param id 隐患主键 + * @return 隐患 + */ + HiddenDanger selectHiddenDangerById(int id); + + /** + * 查询隐患列表 + * + * @param hiddenDanger 隐患 + * @return 隐患集合 + */ + List selectHiddenDangerList(HiddenDanger hiddenDanger); + + /** + * 新增隐患 + * + * @param hiddenDanger 隐患 + * @return 结果 + */ + int insertHiddenDanger(HiddenDanger hiddenDanger); + + /** + * 修改隐患 + * + * @param hiddenDanger 隐患 + * @return 结果 + */ + int updateHiddenDanger(HiddenDanger hiddenDanger); + + /** + * 批量删除隐患 + * + * @param ids 需要删除的隐患主键集合 + * @return 结果 + */ + int deleteHiddenDangerByIds(int[] ids); + + /** + * 删除隐患信息 + * + * @param id 隐患主键 + * @return 结果 + */ + int deleteHiddenDangerById(int id); + + String hiddenDangerStatistics(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/ILawEnforcementInspectionService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/ILawEnforcementInspectionService.java new file mode 100644 index 0000000..1dd81c4 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/ILawEnforcementInspectionService.java @@ -0,0 +1,64 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.LawEnforcementInspection; + +/** + * 执法巡查Service接口 + * + * @author zhangyu + * @date 2023-02-14 + */ +public interface ILawEnforcementInspectionService +{ + /** + * 查询执法巡查 + * + * @param id 执法巡查主键 + * @return 执法巡查 + */ + LawEnforcementInspection selectLawEnforcementInspectionById(int id); + + /** + * 查询执法巡查列表 + * + * @param lawEnforcementInspection 执法巡查 + * @return 执法巡查集合 + */ + List selectLawEnforcementInspectionList(LawEnforcementInspection lawEnforcementInspection); + + /** + * 新增执法巡查 + * + * @param lawEnforcementInspection 执法巡查 + * @return 结果 + */ + int insertLawEnforcementInspection(LawEnforcementInspection lawEnforcementInspection); + + /** + * 修改执法巡查 + * + * @param lawEnforcementInspection 执法巡查 + * @return 结果 + */ + int updateLawEnforcementInspection(LawEnforcementInspection lawEnforcementInspection); + + /** + * 批量删除执法巡查 + * + * @param ids 需要删除的执法巡查主键集合 + * @return 结果 + */ + int deleteLawEnforcementInspectionByIds(int[] ids); + + /** + * 删除执法巡查信息 + * + * @param id 执法巡查主键 + * @return 结果 + */ + int deleteLawEnforcementInspectionById(int id); + + String monthStatistics(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IMajorHazardSourcesService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IMajorHazardSourcesService.java new file mode 100644 index 0000000..ff5d33d --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IMajorHazardSourcesService.java @@ -0,0 +1,63 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; +import com.hbt.safety.supervision.pojo.MajorHazardSources; + +/** + * 重大危险源Service接口 + * + * @author zhangyu + * @date 2023-02-14 + */ +public interface IMajorHazardSourcesService +{ + /** + * 查询重大危险源 + * + * @param id 重大危险源主键 + * @return 重大危险源 + */ + MajorHazardSources selectMajorHazardSourcesById(int id); + + /** + * 查询重大危险源列表 + * + * @param majorHazardSources 重大危险源 + * @return 重大危险源集合 + */ + List selectMajorHazardSourcesList(MajorHazardSources majorHazardSources); + + /** + * 新增重大危险源 + * + * @param majorHazardSources 重大危险源 + * @return 结果 + */ + int insertMajorHazardSources(MajorHazardSources majorHazardSources); + + /** + * 修改重大危险源 + * + * @param majorHazardSources 重大危险源 + * @return 结果 + */ + int updateMajorHazardSources(MajorHazardSources majorHazardSources); + + /** + * 批量删除重大危险源 + * + * @param ids 需要删除的重大危险源主键集合 + * @return 结果 + */ + int deleteMajorHazardSourcesByIds(int[] ids); + + /** + * 删除重大危险源信息 + * + * @param id 重大危险源主键 + * @return 结果 + */ + int deleteMajorHazardSourcesById(int id); + + String majorHazardSourcesStatistics(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IPersionService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IPersionService.java new file mode 100644 index 0000000..72fefca --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IPersionService.java @@ -0,0 +1,62 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.Persion; + +/** + * 人员信息Service接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +public interface IPersionService +{ + /** + * 查询人员信息 + * + * @param id 人员信息主键 + * @return 人员信息 + */ + Persion selectPersionById(int id); + + /** + * 查询人员信息列表 + * + * @param persion 人员信息 + * @return 人员信息集合 + */ + List selectPersionList(Persion persion); + + /** + * 新增人员信息 + * + * @param persion 人员信息 + * @return 结果 + */ + int insertPersion(Persion persion); + + /** + * 修改人员信息 + * + * @param persion 人员信息 + * @return 结果 + */ + int updatePersion(Persion persion); + + /** + * 批量删除人员信息 + * + * @param ids 需要删除的人员信息主键集合 + * @return 结果 + */ + int deletePersionByIds(int[] ids); + + /** + * 删除人员信息信息 + * + * @param id 人员信息主键 + * @return 结果 + */ + int deletePersionById(int id); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IRiskAreaService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IRiskAreaService.java new file mode 100644 index 0000000..4c20e51 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IRiskAreaService.java @@ -0,0 +1,61 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; +import com.hbt.safety.supervision.pojo.RiskArea; + +/** + * 风险区域Service接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +public interface IRiskAreaService +{ + /** + * 查询风险区域 + * + * @param id 风险区域主键 + * @return 风险区域 + */ + RiskArea selectRiskAreaById(int id); + + /** + * 查询风险区域列表 + * + * @param riskArea 风险区域 + * @return 风险区域集合 + */ + List selectRiskAreaList(RiskArea riskArea); + + /** + * 新增风险区域 + * + * @param riskArea 风险区域 + * @return 结果 + */ + int insertRiskArea(RiskArea riskArea); + + /** + * 修改风险区域 + * + * @param riskArea 风险区域 + * @return 结果 + */ + int updateRiskArea(RiskArea riskArea); + + /** + * 批量删除风险区域 + * + * @param ids 需要删除的风险区域主键集合 + * @return 结果 + */ + int deleteRiskAreaByIds(int[] ids); + + /** + * 删除风险区域信息 + * + * @param id 风险区域主键 + * @return 结果 + */ + int deleteRiskAreaById(int id); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IRiskService.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IRiskService.java new file mode 100644 index 0000000..e5aff9c --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/IRiskService.java @@ -0,0 +1,64 @@ +package com.hbt.safety.supervision.service; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.Risk; + +/** + * 风险Service接口 + * + * @author 张雨 + * @date 2023-02-14 + */ +public interface IRiskService +{ + /** + * 查询风险 + * + * @param id 风险主键 + * @return 风险 + */ + Risk selectRiskById(int id); + + /** + * 查询风险列表 + * + * @param risk 风险 + * @return 风险集合 + */ + List selectRiskList(Risk risk); + + /** + * 新增风险 + * + * @param risk 风险 + * @return 结果 + */ + int insertRisk(Risk risk); + + /** + * 修改风险 + * + * @param risk 风险 + * @return 结果 + */ + int updateRisk(Risk risk); + + /** + * 批量删除风险 + * + * @param ids 需要删除的风险主键集合 + * @return 结果 + */ + int deleteRiskByIds(int[] ids); + + /** + * 删除风险信息 + * + * @param id 风险主键 + * @return 结果 + */ + int deleteRiskById(int id); + + String riskStatistics(); +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EnterpriseInfomationServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EnterpriseInfomationServiceImpl.java new file mode 100644 index 0000000..f179286 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EnterpriseInfomationServiceImpl.java @@ -0,0 +1,120 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.mapper.EnterpriseInfomationMapper; +import com.hbt.safety.supervision.pojo.EnterpriseInfomation; +import com.hbt.safety.supervision.service.IEnterpriseInfomationService; +import com.hbt.safety.supervision.mapper.PersionMapper; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +/** + * 企业信息Service业务层处理 + * + * @author zhangyu + * @date 2023-02-14 + */ +@Service +public class EnterpriseInfomationServiceImpl implements IEnterpriseInfomationService +{ + @Autowired + private EnterpriseInfomationMapper enterpriseInfomationMapper; + + @Autowired + PersionMapper persionMapper; + + /** + * 查询企业信息 + * + * @param id 企业信息主键 + * @return 企业信息 + */ + @Override + public EnterpriseInfomation selectEnterpriseInfomationById(int id) + { + return enterpriseInfomationMapper.selectEnterpriseInfomationById(id); + } + + /** + * 查询企业信息列表 + * + * @param enterpriseInfomation 企业信息 + * @return 企业信息 + */ + @Override + public List selectEnterpriseInfomationList(EnterpriseInfomation enterpriseInfomation) + { + return enterpriseInfomationMapper.selectEnterpriseInfomationList(enterpriseInfomation); + } + + /** + * 新增企业信息 + * + * @param enterpriseInfomation 企业信息 + * @return 结果 + */ + @Override + public int insertEnterpriseInfomation(EnterpriseInfomation enterpriseInfomation) + { + return enterpriseInfomationMapper.insertEnterpriseInfomation(enterpriseInfomation); + } + + /** + * 修改企业信息 + * + * @param enterpriseInfomation 企业信息 + * @return 结果 + */ + @Override + public int updateEnterpriseInfomation(EnterpriseInfomation enterpriseInfomation) + { + return enterpriseInfomationMapper.updateEnterpriseInfomation(enterpriseInfomation); + } + + /** + * 批量删除企业信息 + * + * @param ids 需要删除的企业信息主键 + * @return 结果 + */ + @Override + public int deleteEnterpriseInfomationByIds(int[] ids) + { + return enterpriseInfomationMapper.deleteEnterpriseInfomationByIds(ids); + } + + /** + * 删除企业信息信息 + * + * @param id 企业信息主键 + * @return 结果 + */ + @Override + public int deleteEnterpriseInfomationById(int id) + { + return enterpriseInfomationMapper.deleteEnterpriseInfomationById(id); + } + + @Override + public String enterpriseStatistics() { + Map map = new HashMap<>(); + // 企业分类及数量 + List> list = enterpriseInfomationMapper.enterpriseStatistics(); + // 在管企业数量 + int enterpriseCount = enterpriseInfomationMapper.getEnterpriseCount(); + // 企业员工数 + int persionCount = persionMapper.getPersionCount(); + + // 等级车辆数 + int carCount = enterpriseInfomationMapper.getCarCount(); + map.put("enterpriseClassification", list); + map.put("enterpriseCount", enterpriseCount); + map.put("persionCount", persionCount); + map.put("carCount", carCount); + return JSONObject.toJSONString(map); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EscalateHiddenDangerServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EscalateHiddenDangerServiceImpl.java new file mode 100644 index 0000000..2810cfb --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EscalateHiddenDangerServiceImpl.java @@ -0,0 +1,94 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.List; + +import com.hbt.safety.supervision.mapper.EscalateHiddenDangerMapper; +import com.hbt.safety.supervision.pojo.EscalateHiddenDanger; +import com.hbt.safety.supervision.service.IEscalateHiddenDangerService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +/** + * 上报隐患Service业务层处理 + * + * @author 张雨 + * @date 2023-02-14 + */ +@Service +public class EscalateHiddenDangerServiceImpl implements IEscalateHiddenDangerService +{ + @Autowired + private EscalateHiddenDangerMapper escalateHiddenDangerMapper; + + /** + * 查询上报隐患 + * + * @param id 上报隐患主键 + * @return 上报隐患 + */ + @Override + public EscalateHiddenDanger selectEscalateHiddenDangerById(int id) + { + return escalateHiddenDangerMapper.selectEscalateHiddenDangerById(id); + } + + /** + * 查询上报隐患列表 + * + * @param escalateHiddenDanger 上报隐患 + * @return 上报隐患 + */ + @Override + public List selectEscalateHiddenDangerList(EscalateHiddenDanger escalateHiddenDanger) + { + return escalateHiddenDangerMapper.selectEscalateHiddenDangerList(escalateHiddenDanger); + } + + /** + * 新增上报隐患 + * + * @param escalateHiddenDanger 上报隐患 + * @return 结果 + */ + @Override + public int insertEscalateHiddenDanger(EscalateHiddenDanger escalateHiddenDanger) + { + return escalateHiddenDangerMapper.insertEscalateHiddenDanger(escalateHiddenDanger); + } + + /** + * 修改上报隐患 + * + * @param escalateHiddenDanger 上报隐患 + * @return 结果 + */ + @Override + public int updateEscalateHiddenDanger(EscalateHiddenDanger escalateHiddenDanger) + { + return escalateHiddenDangerMapper.updateEscalateHiddenDanger(escalateHiddenDanger); + } + + /** + * 批量删除上报隐患 + * + * @param ids 需要删除的上报隐患主键 + * @return 结果 + */ + @Override + public int deleteEscalateHiddenDangerByIds(int[] ids) + { + return escalateHiddenDangerMapper.deleteEscalateHiddenDangerByIds(ids); + } + + /** + * 删除上报隐患信息 + * + * @param id 上报隐患主键 + * @return 结果 + */ + @Override + public int deleteEscalateHiddenDangerById(int id) + { + return escalateHiddenDangerMapper.deleteEscalateHiddenDangerById(id); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EscalateRiskServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EscalateRiskServiceImpl.java new file mode 100644 index 0000000..f6e4796 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/EscalateRiskServiceImpl.java @@ -0,0 +1,94 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.EscalateRisk; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.hbt.safety.supervision.mapper.EscalateRiskMapper; +import com.hbt.safety.supervision.service.IEscalateRiskService; + +/** + * 上报风险Service业务层处理 + * + * @author 张雨 + * @date 2023-02-14 + */ +@Service +public class EscalateRiskServiceImpl implements IEscalateRiskService +{ + @Autowired + private EscalateRiskMapper escalateRiskMapper; + + /** + * 查询上报风险 + * + * @param id 上报风险主键 + * @return 上报风险 + */ + @Override + public EscalateRisk selectEscalateRiskById(int id) + { + return escalateRiskMapper.selectEscalateRiskById(id); + } + + /** + * 查询上报风险列表 + * + * @param escalateRisk 上报风险 + * @return 上报风险 + */ + @Override + public List selectEscalateRiskList(EscalateRisk escalateRisk) + { + return escalateRiskMapper.selectEscalateRiskList(escalateRisk); + } + + /** + * 新增上报风险 + * + * @param escalateRisk 上报风险 + * @return 结果 + */ + @Override + public int insertEscalateRisk(EscalateRisk escalateRisk) + { + return escalateRiskMapper.insertEscalateRisk(escalateRisk); + } + + /** + * 修改上报风险 + * + * @param escalateRisk 上报风险 + * @return 结果 + */ + @Override + public int updateEscalateRisk(EscalateRisk escalateRisk) + { + return escalateRiskMapper.updateEscalateRisk(escalateRisk); + } + + /** + * 批量删除上报风险 + * + * @param ids 需要删除的上报风险主键 + * @return 结果 + */ + @Override + public int deleteEscalateRiskByIds(int[] ids) + { + return escalateRiskMapper.deleteEscalateRiskByIds(ids); + } + + /** + * 删除上报风险信息 + * + * @param id 上报风险主键 + * @return 结果 + */ + @Override + public int deleteEscalateRiskById(int id) + { + return escalateRiskMapper.deleteEscalateRiskById(id); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/HazardousOperationServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/HazardousOperationServiceImpl.java new file mode 100644 index 0000000..3c4ecf6 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/HazardousOperationServiceImpl.java @@ -0,0 +1,147 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.*; +import java.util.stream.Collectors; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.pojo.HazardousOperation; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.hbt.safety.supervision.mapper.HazardousOperationMapper; +import com.hbt.safety.supervision.service.IHazardousOperationService; + +/** + * 危险作业Service业务层处理 + * + * @author zhangyu + * @date 2023-02-14 + */ +@Service +public class HazardousOperationServiceImpl implements IHazardousOperationService +{ + @Autowired + private HazardousOperationMapper hazardousOperationMapper; + + /** + * 查询危险作业 + * + * @param id 危险作业主键 + * @return 危险作业 + */ + @Override + public HazardousOperation selectHazardousOperationById(int id) + { + return hazardousOperationMapper.selectHazardousOperationById(id); + } + + /** + * 查询危险作业列表 + * + * @param hazardousOperation 危险作业 + * @return 危险作业 + */ + @Override + public List selectHazardousOperationList(HazardousOperation hazardousOperation) + { + return hazardousOperationMapper.selectHazardousOperationList(hazardousOperation); + } + + /** + * 新增危险作业 + * + * @param hazardousOperation 危险作业 + * @return 结果 + */ + @Override + public int insertHazardousOperation(HazardousOperation hazardousOperation) + { + return hazardousOperationMapper.insertHazardousOperation(hazardousOperation); + } + + /** + * 修改危险作业 + * + * @param hazardousOperation 危险作业 + * @return 结果 + */ + @Override + public int updateHazardousOperation(HazardousOperation hazardousOperation) + { + return hazardousOperationMapper.updateHazardousOperation(hazardousOperation); + } + + /** + * 批量删除危险作业 + * + * @param ids 需要删除的危险作业主键 + * @return 结果 + */ + @Override + public int deleteHazardousOperationByIds(int[] ids) + { + return hazardousOperationMapper.deleteHazardousOperationByIds(ids); + } + + /** + * 删除危险作业信息 + * + * @param id 危险作业主键 + * @return 结果 + */ + @Override + public int deleteHazardousOperationById(int id) + { + return hazardousOperationMapper.deleteHazardousOperationById(id); + } + + /** + * 危险作业统计 + * + * @return 统计数据 + */ + @Override + public String hazardousOperationStatistics() { + // 获取当前时间 + Date date = new Date(); + + Map map = new HashMap<>(); + + // 查询危险作业信息 + List list = hazardousOperationMapper.selectHazardousOperations(); + if (list == null) { + return ""; + } + Map> typeList = list.stream() + .collect(Collectors.groupingBy(HazardousOperation::getOperationType)); + // 组装类型统计数据 + Map operationTypeList = new HashMap<>(); + for(Object key : typeList.keySet()) { + operationTypeList.put(key, typeList.get(key).size()); + } + map.put("operationTypeList", operationTypeList); + + // 进行中的危险作业 + List hazardousOperations = list.stream() + .filter(s -> s.getOperationStart().before(date) && s.getOperationEnd().after(date)) + .collect(Collectors.toList()); + map.put("underwayHazardousOperation", hazardousOperations.size()); + + // 进行危险作业企业 + int underwayEnterprise = hazardousOperations.stream().collect( + Collectors.collectingAndThen( + Collectors.toCollection(() -> new TreeSet<> + (Comparator.comparing(HazardousOperation :: getEnterpriseId))), ArrayList:: new)).size(); + map.put("underwayEnterprise", underwayEnterprise); + + // 待开始危险作业 + int toBeStarted = (int) list.stream() + .filter(s -> s.getOperationStart().after(date)).count(); + map.put("toBeStarted", toBeStarted); + + // 历史危险作业 + int historyHazardousOperation = (int) list.stream() + .filter(s -> s.getOperationEnd().before(date)).count(); + map.put("historyHazardousOperation", historyHazardousOperation); + return JSONObject.toJSONString(map); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/HiddenDangerServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/HiddenDangerServiceImpl.java new file mode 100644 index 0000000..9a14915 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/HiddenDangerServiceImpl.java @@ -0,0 +1,115 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.mapper.HiddenDangerMapper; +import com.hbt.safety.supervision.pojo.HiddenDanger; +import com.hbt.safety.supervision.service.IHiddenDangerService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +/** + * 隐患Service业务层处理 + * + * @author hbt + */ +@Service +public class HiddenDangerServiceImpl implements IHiddenDangerService +{ + @Autowired + private HiddenDangerMapper hiddenDangerMapper; + + /** + * 查询隐患 + * + * @param id 隐患主键 + * @return 隐患 + */ + @Override + public HiddenDanger selectHiddenDangerById(int id) + { + return hiddenDangerMapper.selectHiddenDangerById(id); + } + + /** + * 查询隐患列表 + * + * @param hiddenDanger 隐患 + * @return 隐患 + */ + @Override + public List selectHiddenDangerList(HiddenDanger hiddenDanger) + { + return hiddenDangerMapper.selectHiddenDangerList(hiddenDanger); + } + + /** + * 新增隐患 + * + * @param hiddenDanger 隐患 + * @return 结果 + */ + @Override + public int insertHiddenDanger(HiddenDanger hiddenDanger) + { + return hiddenDangerMapper.insertHiddenDanger(hiddenDanger); + } + + /** + * 修改隐患 + * + * @param hiddenDanger 隐患 + * @return 结果 + */ + @Override + public int updateHiddenDanger(HiddenDanger hiddenDanger) + { + return hiddenDangerMapper.updateHiddenDanger(hiddenDanger); + } + + /** + * 批量删除隐患 + * + * @param ids 需要删除的隐患主键 + * @return 结果 + */ + @Override + public int deleteHiddenDangerByIds(int[] ids) + { + return hiddenDangerMapper.deleteHiddenDangerByIds(ids); + } + + /** + * 删除隐患信息 + * + * @param id 隐患主键 + * @return 结果 + */ + @Override + public int deleteHiddenDangerById(int id) + { + return hiddenDangerMapper.deleteHiddenDangerById(id); + } + + public String hiddenDangerStatistics() { + Map map = new HashMap<>(); + + List list = hiddenDangerMapper.selectHiddenDangers(); + if (list == null) { + return ""; + } + Map> hiddenDangerMap = list.stream() + .collect(Collectors.groupingBy(HiddenDanger::getReformStatus)); + // 组装隐患状态统计数据 + Map hiddenDangerList = new HashMap<>(); + for(Object key : hiddenDangerMap.keySet()) { + hiddenDangerList.put(key, hiddenDangerMap.get(key).size()); + } + map.put("hiddenDangerList", hiddenDangerList); + return JSONObject.toJSONString(map); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/LawEnforcementInspectionServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/LawEnforcementInspectionServiceImpl.java new file mode 100644 index 0000000..1652e97 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/LawEnforcementInspectionServiceImpl.java @@ -0,0 +1,160 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.ArrayList; +import java.util.Calendar; +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.mapper.EscalateHiddenDangerMapper; +import com.hbt.safety.supervision.mapper.EscalateRiskMapper; +import com.hbt.safety.supervision.mapper.LawEnforcementInspectionMapper; +import com.hbt.safety.supervision.pojo.LawEnforcementInspection; +import com.hbt.safety.supervision.pojo.vo.LawEnforcementInspectionStatics; +import com.hbt.safety.supervision.pojo.vo.LawEnforcementInspectionVo; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.hbt.safety.supervision.service.ILawEnforcementInspectionService; + +/** + * 执法巡查Service业务层处理 + * + * @author zhangyu + * @date 2023-02-14 + */ +@Service +public class LawEnforcementInspectionServiceImpl implements ILawEnforcementInspectionService +{ + @Autowired + private LawEnforcementInspectionMapper lawEnforcementInspectionMapper; + + @Autowired + EscalateHiddenDangerMapper escalateHiddenDangerMapper; + + @Autowired + EscalateRiskMapper escalateRiskMapper; + + /** + * 查询执法巡查 + * + * @param id 执法巡查主键 + * @return 执法巡查 + */ + @Override + public LawEnforcementInspection selectLawEnforcementInspectionById(int id) + { + return lawEnforcementInspectionMapper.selectLawEnforcementInspectionById(id); + } + + /** + * 查询执法巡查列表 + * + * @param lawEnforcementInspection 执法巡查 + * @return 执法巡查 + */ + @Override + public List selectLawEnforcementInspectionList(LawEnforcementInspection lawEnforcementInspection) + { + return lawEnforcementInspectionMapper.selectLawEnforcementInspectionList(lawEnforcementInspection); + } + + /** + * 新增执法巡查 + * + * @param lawEnforcementInspection 执法巡查 + * @return 结果 + */ + @Override + public int insertLawEnforcementInspection(LawEnforcementInspection lawEnforcementInspection) + { + return lawEnforcementInspectionMapper.insertLawEnforcementInspection(lawEnforcementInspection); + } + + /** + * 修改执法巡查 + * + * @param lawEnforcementInspection 执法巡查 + * @return 结果 + */ + @Override + public int updateLawEnforcementInspection(LawEnforcementInspection lawEnforcementInspection) + { + return lawEnforcementInspectionMapper.updateLawEnforcementInspection(lawEnforcementInspection); + } + + /** + * 批量删除执法巡查 + * + * @param ids 需要删除的执法巡查主键 + * @return 结果 + */ + @Override + public int deleteLawEnforcementInspectionByIds(int[] ids) + { + return lawEnforcementInspectionMapper.deleteLawEnforcementInspectionByIds(ids); + } + + /** + * 删除执法巡查信息 + * + * @param id 执法巡查主键 + * @return 结果 + */ + @Override + public int deleteLawEnforcementInspectionById(int id) + { + return lawEnforcementInspectionMapper.deleteLawEnforcementInspectionById(id); + } + + @Override + public String monthStatistics() { + List list = new ArrayList<>(); + + // 获取当前年份 + Calendar calendar = Calendar.getInstance(); + int year = calendar.get(Calendar.YEAR); + // 查询巡查列表 + List lawList = lawEnforcementInspectionMapper.selectLawEnforcementInspections(year); + if (lawList == null) { + return null; + } + + Map> typeList = lawList.stream() + .collect(Collectors.groupingBy(LawEnforcementInspectionVo::getInspectionDate)); + + // 查询隐患表id + List escalateHiddenDangerIds = escalateHiddenDangerMapper.getEscalateHiddenDangerIds(); + // 查询风险表id + List escalateRiskIds = escalateRiskMapper.getEscalateRiskIds(); + for (Object key : typeList.keySet()) { + LawEnforcementInspectionStatics law = new LawEnforcementInspectionStatics(); + law.setMonth(key); + List lawEnforcementInspections = typeList.get(key); + law.setInspectionCount(lawEnforcementInspections.size()); + + // 获取每月上报隐患数 + if (escalateHiddenDangerIds == null) { + law.setHiddenTroubleCount(0); + } else { + int hiddenTroubleCount = (int) lawEnforcementInspections.stream() + .filter( s -> escalateHiddenDangerIds.stream().anyMatch(f -> f.equals(s.getId()))).count(); + law.setHiddenTroubleCount(hiddenTroubleCount); + } + + // 获取每月上报风险数 + if (escalateRiskIds == null) { + law.setRiskCount(0); + } else { + int riskCount = (int) lawEnforcementInspections.stream() + .filter( s -> escalateRiskIds.stream().anyMatch(f -> f.equals(s.getId()))).count(); + + law.setRiskCount(riskCount); + } + + list.add(law); + } + + return JSONObject.toJSONString(list); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/MajorHazardSourcesServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/MajorHazardSourcesServiceImpl.java new file mode 100644 index 0000000..0e69e33 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/MajorHazardSourcesServiceImpl.java @@ -0,0 +1,130 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.service.IMajorHazardSourcesService; +import com.hbt.safety.supervision.pojo.MajorHazardSources; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.hbt.safety.supervision.mapper.MajorHazardSourcesMapper; + +/** + * 重大危险源Service业务层处理 + * + * @author zhangyu + * @date 2023-02-14 + */ +@Service +public class MajorHazardSourcesServiceImpl implements IMajorHazardSourcesService +{ + @Autowired + private MajorHazardSourcesMapper majorHazardSourcesMapper; + + /** + * 查询重大危险源 + * + * @param id 重大危险源主键 + * @return 重大危险源 + */ + @Override + public MajorHazardSources selectMajorHazardSourcesById(int id) + { + return majorHazardSourcesMapper.selectMajorHazardSourcesById(id); + } + + /** + * 查询重大危险源列表 + * + * @param majorHazardSources 重大危险源 + * @return 重大危险源 + */ + @Override + public List selectMajorHazardSourcesList(MajorHazardSources majorHazardSources) + { + return majorHazardSourcesMapper.selectMajorHazardSourcesList(majorHazardSources); + } + + /** + * 新增重大危险源 + * + * @param majorHazardSources 重大危险源 + * @return 结果 + */ + @Override + public int insertMajorHazardSources(MajorHazardSources majorHazardSources) + { + return majorHazardSourcesMapper.insertMajorHazardSources(majorHazardSources); + } + + /** + * 修改重大危险源 + * + * @param majorHazardSources 重大危险源 + * @return 结果 + */ + @Override + public int updateMajorHazardSources(MajorHazardSources majorHazardSources) + { + return majorHazardSourcesMapper.updateMajorHazardSources(majorHazardSources); + } + + /** + * 批量删除重大危险源 + * + * @param ids 需要删除的重大危险源主键 + * @return 结果 + */ + @Override + public int deleteMajorHazardSourcesByIds(int[] ids) + { + return majorHazardSourcesMapper.deleteMajorHazardSourcesByIds(ids); + } + + /** + * 删除重大危险源信息 + * + * @param id 重大危险源主键 + * @return 结果 + */ + @Override + public int deleteMajorHazardSourcesById(int id) + { + return majorHazardSourcesMapper.deleteMajorHazardSourcesById(id); + } + + public String majorHazardSourcesStatistics() { + Map map = new HashMap<>(); + + // 查询重大危险源信息 + List list = majorHazardSourcesMapper.majorHazardSourcesStatistics(); + if (list == null) { + return ""; + } + + // 根据风险等级分组 + Map> typeList = list.stream() + .collect(Collectors.groupingBy(MajorHazardSources::getDangerLevel)); + // 组装风险等级统计数据 + Map dangerLevelList = new HashMap<>(); + for(Object key : typeList.keySet()) { + dangerLevelList.put(key, typeList.get(key).size()); + } + map.put("dangerLevelList", dangerLevelList); + + // 获取生产单元数量 + int productionUnit = (int) list.stream() + .filter(s -> s.getUnitType().equals("生产单元")).count(); + map.put("productionUnit", productionUnit); + + // 获取存储单元数量 + int storageCell = (int) list.stream() + .filter(s -> s.getUnitType().equals("存储单元")).count(); + map.put("storageCell", storageCell); + + return JSONObject.toJSONString(map); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/PersionServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/PersionServiceImpl.java new file mode 100644 index 0000000..ed1e4a9 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/PersionServiceImpl.java @@ -0,0 +1,94 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.List; + +import com.hbt.safety.supervision.pojo.Persion; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.hbt.safety.supervision.mapper.PersionMapper; +import com.hbt.safety.supervision.service.IPersionService; + +/** + * 人员信息Service业务层处理 + * + * @author 张雨 + * @date 2023-02-14 + */ +@Service +public class PersionServiceImpl implements IPersionService +{ + @Autowired + private PersionMapper persionMapper; + + /** + * 查询人员信息 + * + * @param id 人员信息主键 + * @return 人员信息 + */ + @Override + public Persion selectPersionById(int id) + { + return persionMapper.selectPersionById(id); + } + + /** + * 查询人员信息列表 + * + * @param persion 人员信息 + * @return 人员信息 + */ + @Override + public List selectPersionList(Persion persion) + { + return persionMapper.selectPersionList(persion); + } + + /** + * 新增人员信息 + * + * @param persion 人员信息 + * @return 结果 + */ + @Override + public int insertPersion(Persion persion) + { + return persionMapper.insertPersion(persion); + } + + /** + * 修改人员信息 + * + * @param persion 人员信息 + * @return 结果 + */ + @Override + public int updatePersion(Persion persion) + { + return persionMapper.updatePersion(persion); + } + + /** + * 批量删除人员信息 + * + * @param ids 需要删除的人员信息主键 + * @return 结果 + */ + @Override + public int deletePersionByIds(int[] ids) + { + return persionMapper.deletePersionByIds(ids); + } + + /** + * 删除人员信息信息 + * + * @param id 人员信息主键 + * @return 结果 + */ + @Override + public int deletePersionById(int id) + { + return persionMapper.deletePersionById(id); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/RiskAreaServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/RiskAreaServiceImpl.java new file mode 100644 index 0000000..bfbce94 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/RiskAreaServiceImpl.java @@ -0,0 +1,94 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.List; + +import com.hbt.safety.supervision.mapper.RiskAreaMapper; +import com.hbt.safety.supervision.service.IRiskAreaService; +import com.hbt.safety.supervision.pojo.RiskArea; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +/** + * 风险区域Service业务层处理 + * + * @author 张雨 + * @date 2023-02-14 + */ +@Service +public class RiskAreaServiceImpl implements IRiskAreaService +{ + @Autowired + private RiskAreaMapper riskAreaMapper; + + /** + * 查询风险区域 + * + * @param id 风险区域主键 + * @return 风险区域 + */ + @Override + public RiskArea selectRiskAreaById(int id) + { + return riskAreaMapper.selectRiskAreaById(id); + } + + /** + * 查询风险区域列表 + * + * @param riskArea 风险区域 + * @return 风险区域 + */ + @Override + public List selectRiskAreaList(RiskArea riskArea) + { + return riskAreaMapper.selectRiskAreaList(riskArea); + } + + /** + * 新增风险区域 + * + * @param riskArea 风险区域 + * @return 结果 + */ + @Override + public int insertRiskArea(RiskArea riskArea) + { + return riskAreaMapper.insertRiskArea(riskArea); + } + + /** + * 修改风险区域 + * + * @param riskArea 风险区域 + * @return 结果 + */ + @Override + public int updateRiskArea(RiskArea riskArea) + { + return riskAreaMapper.updateRiskArea(riskArea); + } + + /** + * 批量删除风险区域 + * + * @param ids 需要删除的风险区域主键 + * @return 结果 + */ + @Override + public int deleteRiskAreaByIds(int[] ids) + { + return riskAreaMapper.deleteRiskAreaByIds(ids); + } + + /** + * 删除风险区域信息 + * + * @param id 风险区域主键 + * @return 结果 + */ + @Override + public int deleteRiskAreaById(int id) + { + return riskAreaMapper.deleteRiskAreaById(id); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/RiskServiceImpl.java b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/RiskServiceImpl.java new file mode 100644 index 0000000..fcfccb2 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/java/com/hbt/safety/supervision/service/impl/RiskServiceImpl.java @@ -0,0 +1,101 @@ +package com.hbt.safety.supervision.service.impl; + +import java.util.List; +import java.util.Map; + +import com.alibaba.fastjson.JSONObject; +import com.hbt.safety.supervision.mapper.RiskMapper; +import com.hbt.safety.supervision.pojo.Risk; +import com.hbt.safety.supervision.service.IRiskService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +/** + * 风险Service业务层处理 + * + * @author 张雨 + * @date 2023-02-14 + */ +@Service +public class RiskServiceImpl implements IRiskService +{ + @Autowired + private RiskMapper riskMapper; + + /** + * 查询风险 + * + * @param id 风险主键 + * @return 风险 + */ + @Override + public Risk selectRiskById(int id) + { + return riskMapper.selectRiskById(id); + } + + /** + * 查询风险列表 + * + * @param risk 风险 + * @return 风险 + */ + @Override + public List selectRiskList(Risk risk) + { + return riskMapper.selectRiskList(risk); + } + + /** + * 新增风险 + * + * @param risk 风险 + * @return 结果 + */ + @Override + public int insertRisk(Risk risk) + { + return riskMapper.insertRisk(risk); + } + + /** + * 修改风险 + * + * @param risk 风险 + * @return 结果 + */ + @Override + public int updateRisk(Risk risk) + { + return riskMapper.updateRisk(risk); + } + + /** + * 批量删除风险 + * + * @param ids 需要删除的风险主键 + * @return 结果 + */ + @Override + public int deleteRiskByIds(int[] ids) + { + return riskMapper.deleteRiskByIds(ids); + } + + /** + * 删除风险信息 + * + * @param id 风险主键 + * @return 结果 + */ + @Override + public int deleteRiskById(int id) + { + return riskMapper.deleteRiskById(id); + } + + public String riskStatistics() { + List> map = riskMapper.riskStatistics(); + return JSONObject.toJSONString(map); + } +} diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/banner.txt b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/banner.txt new file mode 100644 index 0000000..6753569 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/banner.txt @@ -0,0 +1,8 @@ +Spring Boot Version: ${spring-boot.version} +Spring Application Name: ${spring.application.name} + __ __ __ ____ __ _ _ + / /_ / /_ / /_ _________ _/ __/__ / /___ __ _______ ______ ___ ______ __(_)____(_)___ ____ + / __ \/ __ \/ __/_____/ ___/ __ `/ /_/ _ \/ __/ / / /_____/ ___/ / / / __ \/ _ \/ ___/ | / / / ___/ / __ \/ __ \ + / / / / /_/ / /_/_____(__ ) /_/ / __/ __/ /_/ /_/ /_____(__ ) /_/ / /_/ / __/ / | |/ / (__ ) / /_/ / / / / +/_/ /_/_.___/\__/ /____/\__,_/_/ \___/\__/\__, / /____/\__,_/ .___/\___/_/ |___/_/____/_/\____/_/ /_/ + /____/ /_/ \ No newline at end of file diff --git a/hbt-ep/src/main/resources/bootstrap-dev.yml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/bootstrap-dev.yml similarity index 100% rename from hbt-ep/src/main/resources/bootstrap-dev.yml rename to hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/bootstrap-dev.yml diff --git a/hbt-ep/src/main/resources/bootstrap.yml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/bootstrap.yml similarity index 82% rename from hbt-ep/src/main/resources/bootstrap.yml rename to hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/bootstrap.yml index 8199fc1..22265d7 100644 --- a/hbt-ep/src/main/resources/bootstrap.yml +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/bootstrap.yml @@ -5,7 +5,7 @@ server: spring: application: # 应用名称 - name: hbt-ep + name: hbt-safety-supervision profiles: # 环境配置 active: dev diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EnterpriseInfomationMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EnterpriseInfomationMapper.xml new file mode 100644 index 0000000..af00583 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EnterpriseInfomationMapper.xml @@ -0,0 +1,118 @@ + + + + + + + + + + + + + + + + + + + + + + select id, unify_social_credit_code, name, registration_number, legal_representative, type, establishment_date, fund_amount, approval_date, registration_authority, registration_status, dwelling_place, business_scope from enterprise_infomation + + + + + + + + insert into enterprise_infomation + + id, + unify_social_credit_code, + name, + registration_number, + legal_representative, + type, + establishment_date, + fund_amount, + approval_date, + registration_authority, + registration_status, + dwelling_place, + business_scope, + + + #{id}, + #{unifySocialCreditCode}, + #{name}, + #{registrationNumber}, + #{legalRepresentative}, + #{type}, + #{establishmentDate}, + #{fundAmount}, + #{approvalDate}, + #{registrationAuthority}, + #{registrationStatus}, + #{dwellingPlace}, + #{businessScope}, + + + + + update enterprise_infomation + + unify_social_credit_code = #{unifySocialCreditCode}, + name = #{name}, + registration_number = #{registrationNumber}, + legal_representative = #{legalRepresentative}, + type = #{type}, + establishment_date = #{establishmentDate}, + fund_amount = #{fundAmount}, + approval_date = #{approvalDate}, + registration_authority = #{registrationAuthority}, + registration_status = #{registrationStatus}, + dwelling_place = #{dwellingPlace}, + business_scope = #{businessScope}, + + where id = #{id} + + + + delete from enterprise_infomation where id = #{id} + + + + delete from enterprise_infomation where id in + + #{id} + + + + + + + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EscalateHiddenDangerMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EscalateHiddenDangerMapper.xml new file mode 100644 index 0000000..deaf361 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EscalateHiddenDangerMapper.xml @@ -0,0 +1,69 @@ + + + + + + + + + + + + select id, enforcement_id, hidden_danger_id from escalate_hidden_danger + + + + + + + + insert into escalate_hidden_danger + + id, + enforcement_id, + hidden_danger_id, + + + #{id}, + #{enforcementId}, + #{hiddenDangerId}, + + + + + update escalate_hidden_danger + + enforcement_id = #{enforcementId}, + hidden_danger_id = #{hiddenDangerId}, + + where id = #{id} + + + + delete from escalate_hidden_danger where id = #{id} + + + + delete from escalate_hidden_danger where id in + + #{id} + + + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EscalateRiskMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EscalateRiskMapper.xml new file mode 100644 index 0000000..1efc553 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/EscalateRiskMapper.xml @@ -0,0 +1,65 @@ + + + + + + + + + + + + select id, enforcement_id, risk_id from escalate_risk + + + + + + + + insert into escalate_risk + + id, + enforcement_id, + risk_id, + + + #{id}, + #{enforcementId}, + #{riskId}, + + + + + update escalate_risk + + enforcement_id = #{enforcementId}, + risk_id = #{riskId}, + + where id = #{id} + + + + delete from escalate_risk where id = #{id} + + + + delete from escalate_risk where id in + + #{id} + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/HazardousOperationMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/HazardousOperationMapper.xml new file mode 100644 index 0000000..2408e89 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/HazardousOperationMapper.xml @@ -0,0 +1,94 @@ + + + + + + + + + + + + + + + + + + + select id, name, operation_level, enterprise_id, operation_content, operation_longitude, operation_latitude, operation_type, operation_start, operation_end from hazardous_operation + + + + + + + + insert into hazardous_operation + + id, + name, + operation_level, + enterprise_id, + operation_content, + operation_longitude, + operation_latitude, + operation_type, + operation_start, + operation_end, + + + #{id}, + #{name}, + #{operationLevel}, + #{enterpriseId}, + #{operationContent}, + #{operationLongitude}, + #{operationLatitude}, + #{operationType}, + #{operationStart}, + #{operationEnd}, + + + + + update hazardous_operation + + name = #{name}, + operation_level = #{operationLevel}, + enterprise_id = #{enterpriseId}, + operation_content = #{operationContent}, + operation_longitude = #{operationLongitude}, + operation_latitude = #{operationLatitude}, + operation_type = #{operationType}, + operation_start = #{operationStart}, + operation_end = #{operationEnd}, + + where id = #{id} + + + + delete from hazardous_operation where id = #{id} + + + + delete from hazardous_operation where id in + + #{id} + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/HiddenDangerMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/HiddenDangerMapper.xml new file mode 100644 index 0000000..a7b788f --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/HiddenDangerMapper.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + select id, name, details, risk_id, submit_date, submit_person_id, submit_enterprise_id, reform_measures, reform_status, exceed_time_limit_status, enterprise_id, person_id, remarks, rectification_period from hidden_danger + + + + + + + + insert into hidden_danger + + id, + name, + details, + risk_id, + submit_date, + submit_person_id, + submit_enterprise_id, + reform_measures, + reform_status, + exceed_time_limit_status, + enterprise_id, + person_id, + remarks, + rectification_period, + + + #{id}, + #{name}, + #{details}, + #{riskId}, + #{submitDate}, + #{submitPersonId}, + #{submitEnterpriseId}, + #{reformMeasures}, + #{reformStatus}, + #{exceedTimeLimitStatus}, + #{enterpriseId}, + #{personId}, + #{remarks}, + #{rectificationPeriod}, + + + + + update hidden_danger + + name = #{name}, + details = #{details}, + risk_id = #{riskId}, + submit_date = #{submitDate}, + submit_person_id = #{submitPersonId}, + submit_enterprise_id = #{submitEnterpriseId}, + reform_measures = #{reformMeasures}, + reform_status = #{reformStatus}, + exceed_time_limit_status = #{exceedTimeLimitStatus}, + enterprise_id = #{enterpriseId}, + person_id = #{personId}, + remarks = #{remarks}, + rectification_period = #{rectificationPeriod}, + + where id = #{id} + + + + delete from hidden_danger where id = #{id} + + + + delete from hidden_danger where id in + + #{id} + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/LawEnforcementInspectionMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/LawEnforcementInspectionMapper.xml new file mode 100644 index 0000000..6a892e4 --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/LawEnforcementInspectionMapper.xml @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + select id, inspection_date, persion_id, name, remarks from law_enforcement_inspection + + + + + + + + insert into law_enforcement_inspection + + id, + inspection_date, + persion_id, + name, + remarks, + + + #{id}, + #{inspectionDate}, + #{persionId}, + #{name}, + #{remarks}, + + + + + update law_enforcement_inspection + + inspection_date = #{inspectionDate}, + persion_id = #{persionId}, + name = #{name}, + remarks = #{remarks}, + + where id = #{id} + + + + delete from law_enforcement_inspection where id = #{id} + + + + delete from law_enforcement_inspection where id in + + #{id} + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/MajorHazardSourcesMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/MajorHazardSourcesMapper.xml new file mode 100644 index 0000000..fa4cecd --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/MajorHazardSourcesMapper.xml @@ -0,0 +1,119 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + select name, danger_level, unified_coding, memory_space, longitude, latitude from major_hazard_sources + + + + + + select id, name, danger_level, unified_coding, hazardous_chemicals_name,risk_factor, consequence ,control_measures ,enterprise, main_responsible_person_id, main_responsible_person ,technology_responsible_person,technology_responsible_person_id,operate_responsible_person_id,operate_responsible_person from major_hazard_sources + + + + + + insert into major_hazard_sources + + id, + main_responsible_person, + technology_responsible_person, + operate_responsible_person, + name, + risk_factor, + consequence, + danger_level, + control_measures, + unified_coding, + unified_coding, + memory_space, + longitude, + latitude, + + + #{id}, + #{mainResponsiblePerson}, + #{technologyResponsiblePerson}, + #{operateResponsiblePerson}, + #{name}, + #{riskFactor}, + #{consequence}, + #{dangerLevel}, + #{controlMeasures}, + #{unifiedCoding}, + #{unitType}, + #{memorySpace}, + #{longitude}, + #{latitude}, + + + + + update major_hazard_sources + + main_responsible_person = #{mainResponsiblePerson}, + technology_responsible_person = #{technologyResponsiblePerson}, + operate_responsible_person = #{operateResponsiblePerson}, + name = #{name}, + risk_factor = #{riskFactor}, + consequence = #{consequence}, + danger_level = #{dangerLevel}, + control_measures = #{controlMeasures}, + unified_coding = #{unifiedCoding}, + unit_type = #{unitType}, + memory_space = #{memorySpace}, + unit_type = #{longitude}, + unit_type = #{latitude}, + + where id = #{id} + + + + delete from major_hazard_sources where id = #{id} + + + + delete from major_hazard_sources where id in + + #{id} + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/PersionMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/PersionMapper.xml new file mode 100644 index 0000000..66bdd6f --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/PersionMapper.xml @@ -0,0 +1,90 @@ + + + + + + + + + + + + + + + + + + select name, phone, addr from persion + + + + + + + + insert into persion + + id, + name, + sex, + age, + identity_card, + enterprise_id, + phone, + remarks, + addr, + + + #{id}, + #{name}, + #{sex}, + #{age}, + #{identityCard}, + #{enterpriseId}, + #{phone}, + #{remarks}, + #{addr}, + + + + + update persion + + name = #{name}, + sex = #{sex}, + age = #{age}, + identity_card = #{identityCard}, + enterprise_id = #{enterpriseId}, + phone = #{phone}, + remarks = #{remarks}, + addr = #{addr}, + + where id = #{id} + + + + delete from persion where id = #{id} + + + + delete from persion where id in + + #{id} + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/RiskAreaMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/RiskAreaMapper.xml new file mode 100644 index 0000000..720f49e --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/RiskAreaMapper.xml @@ -0,0 +1,63 @@ + + + + + + + + + + + + + select id, name, polgyn, risk_level from risk_area + + + + + + + + insert into risk_area + + name, + polgyn, + risk_level, + + + #{name}, + #{polgyn}, + #{riskLevel}, + + + + + update risk_area + + name = #{name}, + polgyn = #{polgyn}, + risk_level = #{riskLevel}, + + where id = #{id} + + + + delete from risk_area where id = #{id} + + + + delete from risk_area where id in + + #{id} + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/RiskMapper.xml b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/RiskMapper.xml new file mode 100644 index 0000000..760f1eb --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision-biz/src/main/resources/mapper/RiskMapper.xml @@ -0,0 +1,97 @@ + + + + + + + + + + + + + + + + + + + + select id, name, risk_probability, risk_factor, affect_consequences, level, enterprise_id, responsible_person_id, risk_control_measures, last_review_date, major_hazard_sources_id from risk + + + + + + + + insert into risk + + id, + name, + risk_probability, + risk_factor, + affect_consequences, + level, + enterprise_id, + responsible_person_id, + risk_control_measures, + last_review_date, + major_hazard_sources_id, + + + #{id}, + #{name}, + #{riskProbability}, + #{riskFactor}, + #{affectConsequences}, + #{level}, + #{enterpriseId}, + #{responsiblePersonId}, + #{riskControlMeasures}, + #{lastReviewDate}, + #{majorHazardSourcesId}, + + + + + update risk + + name = #{name}, + risk_probability = #{riskProbability}, + risk_factor = #{riskFactor}, + affect_consequences = #{affectConsequences}, + level = #{level}, + enterprise_id = #{enterpriseId}, + responsible_person_id = #{responsiblePersonId}, + risk_control_measures = #{riskControlMeasures}, + last_review_date = #{lastReviewDate}, + major_hazard_sources_id = #{majorHazardSourcesId}, + + where id = #{id} + + + + delete from risk where id = #{id} + + + + delete from risk where id in + + #{id} + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/hbt-safety-supervision.iml b/hbt-safety-supervision/hbt-safety-supervision.iml new file mode 100644 index 0000000..f409c0e --- /dev/null +++ b/hbt-safety-supervision/hbt-safety-supervision.iml @@ -0,0 +1,12 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/hbt-safety-supervision/pom.xml b/hbt-safety-supervision/pom.xml new file mode 100644 index 0000000..dd0a25c --- /dev/null +++ b/hbt-safety-supervision/pom.xml @@ -0,0 +1,23 @@ + + + + com.hbt + wit-park-backend + 1.0-SNAPSHOT + + 4.0.0 + + + hbt-safety-supervision-api + hbt-safety-supervision-biz + + + hbt-safety-supervision + pom + + + hbt-safety-supervision智慧安监模块 + + + diff --git a/pom.xml b/pom.xml index 37dce19..3e61a20 100644 --- a/pom.xml +++ b/pom.xml @@ -9,7 +9,7 @@ 1.0-SNAPSHOT 智慧园区体系 - hbt-ep + hbt-safety-supervision pom