From ff0f7dd9e95ee1997f27c6cefe3284fdf0a9052c Mon Sep 17 00:00:00 2001 From: 16639036659 <577530412@qq.com> Date: 星期二, 21 三月 2023 16:23:08 +0800 Subject: [PATCH] 临时提交 --- src/main/java/com/ruoyi/doublePrevention/entity/dto/req/RiskOldInfoQueryReqDTO.java | 56 + src/main/java/com/ruoyi/doublePrevention/vo/ResultVO.java | 20 src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/controller/RiskEvaluationController.java | 261 ++++++-- src/main/java/com/ruoyi/doublePrevention/repository/RiskOldInfoRepository.java | 20 src/main/java/com/ruoyi/doublePrevention/entity/RiskOldInfo.java | 609 +++++++++++++++++++++ src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/domain/dto/RiskEvaluationDTO.java | 6 src/main/java/com/ruoyi/doublePrevention/controller/RiskOldInfoController.java | 42 + src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/domain/dto/RiskEvaluationDTO_old.java | 315 ++++++++++ src/main/java/com/ruoyi/doublePrevention/service/baseService/RiskOldInfoService.java | 14 src/main/java/com/ruoyi/doublePrevention/service/baseService/impl/RiskOldInfoServiceImpl.java | 81 ++ src/main/java/com/ruoyi/doublePrevention/entity/dto/resp/RiskOldInfoQueryRespDTO.java | 216 +++++++ src/main/resources/mybatis/doublePrevention/RiskOldInfoMapper.xml | 90 +++ 12 files changed, 1,643 insertions(+), 87 deletions(-) diff --git a/src/main/java/com/ruoyi/doublePrevention/controller/RiskOldInfoController.java b/src/main/java/com/ruoyi/doublePrevention/controller/RiskOldInfoController.java new file mode 100644 index 0000000..a692dc2 --- /dev/null +++ b/src/main/java/com/ruoyi/doublePrevention/controller/RiskOldInfoController.java @@ -0,0 +1,42 @@ +package com.ruoyi.doublePrevention.controller; + +import com.ruoyi.doublePrevention.entity.RiskOldInfo; +import com.ruoyi.doublePrevention.entity.dto.req.RiskOldInfoQueryReqDTO; +import com.ruoyi.doublePrevention.entity.dto.resp.RiskOldInfoQueryRespDTO; +import com.ruoyi.doublePrevention.enums.ResultCodes; +import com.ruoyi.doublePrevention.service.baseService.RiskOldInfoService; +import com.ruoyi.doublePrevention.vo.ResultVO; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; + +import java.util.List; + +@RestController +@RequestMapping("/info") +public class RiskOldInfoController { + + @Autowired + private RiskOldInfoService riskOldInfoService; + + @PostMapping("/selectOldRiskInfoPage") + public ResultVO<RiskOldInfoQueryRespDTO> selectOldRiskInfoPage(@RequestBody RiskOldInfoQueryReqDTO queryReqDTO){ + + ResultVO resultVO = new ResultVO<>(); + resultVO.setCode(ResultCodes.OK.getCode()); + resultVO.setMsg("查询成功"); + + ResultVO<RiskOldInfoQueryRespDTO> respDTOResultVO = riskOldInfoService.selectOldRiskInfoPage(queryReqDTO); + + resultVO.setData(respDTOResultVO.getData()); + resultVO.setCount(respDTOResultVO.getCount()); + resultVO.setPageIndex(respDTOResultVO.getPageIndex()); + resultVO.setPageSize(respDTOResultVO.getPageSize()); + + return resultVO; + } + + +} diff --git a/src/main/java/com/ruoyi/doublePrevention/entity/RiskOldInfo.java b/src/main/java/com/ruoyi/doublePrevention/entity/RiskOldInfo.java new file mode 100644 index 0000000..31efd85 --- /dev/null +++ b/src/main/java/com/ruoyi/doublePrevention/entity/RiskOldInfo.java @@ -0,0 +1,609 @@ +package com.ruoyi.doublePrevention.entity; + +import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableId; +import com.baomidou.mybatisplus.annotation.TableName; +import lombok.Data; + +import java.util.Date; +import java.io.Serializable; + +/** + * (RiskOldInfo)实体类 + * + * @author makejava + * @since 2023-03-20 15:33:46 + */ +@TableName("risk_old_info") +public class RiskOldInfo implements Serializable { + private static final long serialVersionUID = -61793617513430361L; + + @TableId(value = "id" , type = IdType.AUTO) + private Long id; + /** + * 2上报人部门 + */ + private String reportDep; + /** + * 3上报人职务 + */ + private String reportPeopleJob; + /** + * 4上报人 + */ + private String reportPeople; + /** + * 5发现人 + */ + private String findPeople; + /** + * 6发现时间 + */ + private Date findTime; + /** + * 7隐患内容 + */ + private String riskDesc; + /** + * 8隐患位置 + */ + private String riskSite; + /** + * 9隐患类型 + */ + private String riskType; + /** + * 10隐患级别 + */ + private String riskLevel; + /** + * 11隐患所在部门 + */ + private String riskDep; + /** + * 12检查类型 + */ + private String checkType; + /** + * 13专业 + */ + private String major; + /** + * 14责任人部门 + */ + private String liabilityDep; + /** + * 15责任人 + */ + private String liabilityPeople; + /** + * 16责任人职务 + */ + private String liabilityPeopleJob; + /** + * 17整改时间 + */ + private Date rectifyTime; + /** + * 18允许延期时间 + */ + private Date rectifyTimeout; + /** + * 19负责人部门 + */ + private String leadDep; + /** + * 20负责人职务 + */ + private String leadJob; + /** + * 21整改人部门 + */ + private String rectifyDep; + /** + * 22整改人职务 + */ + private String rectifyPeopleJob; + /** + * 23整改人 + */ + private String rectifyPeople; + /** + * 24整改措施 + */ + private String rectifyMeasure; + /** + * 25整改开始时间 + */ + private Date rectifyStartTime; + /** + * 26整改完成时间 + */ + private Date rectifyFinishTime; + /** + * 27整改情况 + */ + private String rectifyDesc; + /** + * 28资金 + */ + private Double cost; + /** + * 29预案 + */ + private String plan; + /** + * 30防范措施 + */ + private String precautionMeasure; + /** + * 31验收时间 + */ + private Date acceptTime; + /** + * 32验收说明 + */ + private String acceptDesc; + /** + * 33验收部门 + */ + private String acceptDep; + /** + * 34验收人 + */ + private String acceptPeople; + /** + * 35验收人职务 + */ + private String acceptPeopleJob; + /** + * 36销号人部门 + */ + private String cancelDep; + /** + * 37销号人 + */ + private String cancelPeople; + /** + * 38销号人职务 + */ + private String cancelPeopleJob; + /** + * 39延期申请人 + */ + private String applyPeople; + /** + * 40申请时间 + */ + private Date applyTime; + /** + * 41申请理由 + */ + private String applyDesc; + /** + * 42申请-备注 + */ + private String applyNote; + /** + * 43申请延期时间 + */ + private Date applyTimeoutTime; + /** + * 44申请处理人 + */ + private String applyDealPeople; + /** + * 45申请处理时间 + */ + private Date appleDealTime; + /** + * 46流转责任部门 + */ + private String exchangeLeadDep; + /** + * 47流转责任人 + */ + private String exchangeLeadPeople; + /** + * 48流转责任人职务 + */ + private String exchangeLeadPeopleJob; + /** + * 49流转备注 + */ + private String exchangeDesc; + + + public Long getId() { + return id; + } + + public void setId(Long id) { + this.id = id; + } + + public String getReportDep() { + return reportDep; + } + + public void setReportDep(String reportDep) { + this.reportDep = reportDep; + } + + public String getReportPeopleJob() { + return reportPeopleJob; + } + + public void setReportPeopleJob(String reportPeopleJob) { + this.reportPeopleJob = reportPeopleJob; + } + + public String getReportPeople() { + return reportPeople; + } + + public void setReportPeople(String reportPeople) { + this.reportPeople = reportPeople; + } + + public String getFindPeople() { + return findPeople; + } + + public void setFindPeople(String findPeople) { + this.findPeople = findPeople; + } + + public Date getFindTime() { + return findTime; + } + + public void setFindTime(Date findTime) { + this.findTime = findTime; + } + + public String getRiskDesc() { + return riskDesc; + } + + public void setRiskDesc(String riskDesc) { + this.riskDesc = riskDesc; + } + + public String getRiskSite() { + return riskSite; + } + + public void setRiskSite(String riskSite) { + this.riskSite = riskSite; + } + + public String getRiskType() { + return riskType; + } + + public void setRiskType(String riskType) { + this.riskType = riskType; + } + + public String getRiskLevel() { + return riskLevel; + } + + public void setRiskLevel(String riskLevel) { + this.riskLevel = riskLevel; + } + + public String getRiskDep() { + return riskDep; + } + + public void setRiskDep(String riskDep) { + this.riskDep = riskDep; + } + + public String getCheckType() { + return checkType; + } + + public void setCheckType(String checkType) { + this.checkType = checkType; + } + + public String getMajor() { + return major; + } + + public void setMajor(String major) { + this.major = major; + } + + public String getLiabilityDep() { + return liabilityDep; + } + + public void setLiabilityDep(String liabilityDep) { + this.liabilityDep = liabilityDep; + } + + public String getLiabilityPeople() { + return liabilityPeople; + } + + public void setLiabilityPeople(String liabilityPeople) { + this.liabilityPeople = liabilityPeople; + } + + public String getLiabilityPeopleJob() { + return liabilityPeopleJob; + } + + public void setLiabilityPeopleJob(String liabilityPeopleJob) { + this.liabilityPeopleJob = liabilityPeopleJob; + } + + public Date getRectifyTime() { + return rectifyTime; + } + + public void setRectifyTime(Date rectifyTime) { + this.rectifyTime = rectifyTime; + } + + public Date getRectifyTimeout() { + return rectifyTimeout; + } + + public void setRectifyTimeout(Date rectifyTimeout) { + this.rectifyTimeout = rectifyTimeout; + } + + public String getLeadDep() { + return leadDep; + } + + public void setLeadDep(String leadDep) { + this.leadDep = leadDep; + } + + public String getLeadJob() { + return leadJob; + } + + public void setLeadJob(String leadJob) { + this.leadJob = leadJob; + } + + public String getRectifyDep() { + return rectifyDep; + } + + public void setRectifyDep(String rectifyDep) { + this.rectifyDep = rectifyDep; + } + + public String getRectifyPeopleJob() { + return rectifyPeopleJob; + } + + public void setRectifyPeopleJob(String rectifyPeopleJob) { + this.rectifyPeopleJob = rectifyPeopleJob; + } + + public String getRectifyPeople() { + return rectifyPeople; + } + + public void setRectifyPeople(String rectifyPeople) { + this.rectifyPeople = rectifyPeople; + } + + public String getRectifyMeasure() { + return rectifyMeasure; + } + + public void setRectifyMeasure(String rectifyMeasure) { + this.rectifyMeasure = rectifyMeasure; + } + + public Date getRectifyStartTime() { + return rectifyStartTime; + } + + public void setRectifyStartTime(Date rectifyStartTime) { + this.rectifyStartTime = rectifyStartTime; + } + + public Date getRectifyFinishTime() { + return rectifyFinishTime; + } + + public void setRectifyFinishTime(Date rectifyFinishTime) { + this.rectifyFinishTime = rectifyFinishTime; + } + + public String getRectifyDesc() { + return rectifyDesc; + } + + public void setRectifyDesc(String rectifyDesc) { + this.rectifyDesc = rectifyDesc; + } + + public Double getCost() { + return cost; + } + + public void setCost(Double cost) { + this.cost = cost; + } + + public String getPlan() { + return plan; + } + + public void setPlan(String plan) { + this.plan = plan; + } + + public String getPrecautionMeasure() { + return precautionMeasure; + } + + public void setPrecautionMeasure(String precautionMeasure) { + this.precautionMeasure = precautionMeasure; + } + + public Date getAcceptTime() { + return acceptTime; + } + + public void setAcceptTime(Date acceptTime) { + this.acceptTime = acceptTime; + } + + public String getAcceptDesc() { + return acceptDesc; + } + + public void setAcceptDesc(String acceptDesc) { + this.acceptDesc = acceptDesc; + } + + public String getAcceptDep() { + return acceptDep; + } + + public void setAcceptDep(String acceptDep) { + this.acceptDep = acceptDep; + } + + public String getAcceptPeople() { + return acceptPeople; + } + + public void setAcceptPeople(String acceptPeople) { + this.acceptPeople = acceptPeople; + } + + public String getAcceptPeopleJob() { + return acceptPeopleJob; + } + + public void setAcceptPeopleJob(String acceptPeopleJob) { + this.acceptPeopleJob = acceptPeopleJob; + } + + public String getCancelDep() { + return cancelDep; + } + + public void setCancelDep(String cancelDep) { + this.cancelDep = cancelDep; + } + + public String getCancelPeople() { + return cancelPeople; + } + + public void setCancelPeople(String cancelPeople) { + this.cancelPeople = cancelPeople; + } + + public String getCancelPeopleJob() { + return cancelPeopleJob; + } + + public void setCancelPeopleJob(String cancelPeopleJob) { + this.cancelPeopleJob = cancelPeopleJob; + } + + public String getApplyPeople() { + return applyPeople; + } + + public void setApplyPeople(String applyPeople) { + this.applyPeople = applyPeople; + } + + public Date getApplyTime() { + return applyTime; + } + + public void setApplyTime(Date applyTime) { + this.applyTime = applyTime; + } + + public String getApplyDesc() { + return applyDesc; + } + + public void setApplyDesc(String applyDesc) { + this.applyDesc = applyDesc; + } + + public String getApplyNote() { + return applyNote; + } + + public void setApplyNote(String applyNote) { + this.applyNote = applyNote; + } + + public Date getApplyTimeoutTime() { + return applyTimeoutTime; + } + + public void setApplyTimeoutTime(Date applyTimeoutTime) { + this.applyTimeoutTime = applyTimeoutTime; + } + + public String getApplyDealPeople() { + return applyDealPeople; + } + + public void setApplyDealPeople(String applyDealPeople) { + this.applyDealPeople = applyDealPeople; + } + + public Date getAppleDealTime() { + return appleDealTime; + } + + public void setAppleDealTime(Date appleDealTime) { + this.appleDealTime = appleDealTime; + } + + public String getExchangeLeadDep() { + return exchangeLeadDep; + } + + public void setExchangeLeadDep(String exchangeLeadDep) { + this.exchangeLeadDep = exchangeLeadDep; + } + + public String getExchangeLeadPeople() { + return exchangeLeadPeople; + } + + public void setExchangeLeadPeople(String exchangeLeadPeople) { + this.exchangeLeadPeople = exchangeLeadPeople; + } + + public String getExchangeLeadPeopleJob() { + return exchangeLeadPeopleJob; + } + + public void setExchangeLeadPeopleJob(String exchangeLeadPeopleJob) { + this.exchangeLeadPeopleJob = exchangeLeadPeopleJob; + } + + public String getExchangeDesc() { + return exchangeDesc; + } + + public void setExchangeDesc(String exchangeDesc) { + this.exchangeDesc = exchangeDesc; + } +} + diff --git a/src/main/java/com/ruoyi/doublePrevention/entity/dto/req/RiskOldInfoQueryReqDTO.java b/src/main/java/com/ruoyi/doublePrevention/entity/dto/req/RiskOldInfoQueryReqDTO.java new file mode 100644 index 0000000..5267b97 --- /dev/null +++ b/src/main/java/com/ruoyi/doublePrevention/entity/dto/req/RiskOldInfoQueryReqDTO.java @@ -0,0 +1,56 @@ +package com.ruoyi.doublePrevention.entity.dto.req; + +import lombok.Data; + +import java.util.Date; + +/** + * (RiskOldInfo)实体类 + * + * @author makejava + * @since 2023-03-20 15:33:46 + */ + +@Data +public class RiskOldInfoQueryReqDTO { + + private Integer pageIndex; + + private Integer pageSize; + + /** + * 4上报人 -- + */ + private String reportPeople; + /** + * 5发现人 -- + */ + private String findPeople; + /** + * 6发现时间 -- + */ + private Date startTime; + /** + * 6发现时间 -- + */ + private Date endTime; + /** + * 10隐患级别 -- + */ + private String riskLevel; + /** + * 11隐患所在部门 -- + */ + private String riskDep; + /** + * 13专业 -- + */ + private String major; + /** + * 34验收人 -- + */ + private String acceptPeople; + + +} + diff --git a/src/main/java/com/ruoyi/doublePrevention/entity/dto/resp/RiskOldInfoQueryRespDTO.java b/src/main/java/com/ruoyi/doublePrevention/entity/dto/resp/RiskOldInfoQueryRespDTO.java new file mode 100644 index 0000000..acfe8e3 --- /dev/null +++ b/src/main/java/com/ruoyi/doublePrevention/entity/dto/resp/RiskOldInfoQueryRespDTO.java @@ -0,0 +1,216 @@ +package com.ruoyi.doublePrevention.entity.dto.resp; + +import lombok.Data; + +import java.util.Date; + +/** + * (RiskOldInfo)实体类 + * + * @author makejava + * @since 2023-03-20 15:33:46 + */ +@Data +public class RiskOldInfoQueryRespDTO { + + + private Long id; + /** + * 2上报人部门 + */ + private String reportDep; + /** + * 3上报人职务 + */ + private String reportPeopleJob; + /** + * 4上报人 + */ + private String reportPeople; + /** + * 5发现人 + */ + private String findPeople; + /** + * 6发现时间 + */ + private Date findTime; + /** + * 7隐患内容 + */ + private String riskDesc; + /** + * 8隐患位置 + */ + private String riskSite; + /** + * 9隐患类型 + */ + private String riskType; + /** + * 10隐患级别 + */ + private String riskLevel; + /** + * 11隐患所在部门 + */ + private String riskDep; + /** + * 12检查类型 + */ + private String checkType; + /** + * 13专业 + */ + private String major; + /** + * 14责任人部门 + */ + private String liabilityDep; + /** + * 15责任人 + */ + private String liabilityPeople; + /** + * 16责任人职务 + */ + private String liabilityPeopleJob; + /** + * 17整改时间 + */ + private Date rectifyTime; + /** + * 18允许延期时间 + */ + private Date rectifyTimeout; + /** + * 19负责人部门 + */ + private String leadDep; + /** + * 20负责人职务 + */ + private String leadJob; + /** + * 21整改人部门 + */ + private String rectifyDep; + /** + * 22整改人职务 + */ + private String rectifyPeopleJob; + /** + * 23整改人 + */ + private String rectifyPeople; + /** + * 24整改措施 + */ + private String rectifyMeasure; + /** + * 25整改开始时间 + */ + private Date rectifyStartTime; + /** + * 26整改完成时间 + */ + private Date rectifyFinishTime; + /** + * 27整改情况 + */ + private String rectifyDesc; + /** + * 28资金 + */ + private Double cost; + /** + * 29预案 + */ + private String plan; + /** + * 30防范措施 + */ + private String precautionMeasure; + /** + * 31验收时间 + */ + private Date acceptTime; + /** + * 32验收说明 + */ + private String acceptDesc; + /** + * 33验收部门 + */ + private String acceptDep; + /** + * 34验收人 + */ + private String acceptPeople; + /** + * 35验收人职务 + */ + private String acceptPeopleJob; + /** + * 36销号人部门 + */ + private String cancelDep; + /** + * 37销号人 + */ + private String cancelPeople; + /** + * 38销号人职务 + */ + private String cancelPeopleJob; + /** + * 39延期申请人 + */ + private String applyPeople; + /** + * 40申请时间 + */ + private Date applyTime; + /** + * 41申请理由 + */ + private String applyDesc; + /** + * 42申请-备注 + */ + private String applyNote; + /** + * 43申请延期时间 + */ + private Date applyTimeoutTime; + /** + * 44申请处理人 + */ + private String applyDealPeople; + /** + * 45申请处理时间 + */ + private Date appleDealTime; + /** + * 46流转责任部门 + */ + private String exchangeLeadDep; + /** + * 47流转责任人 + */ + private String exchangeLeadPeople; + /** + * 48流转责任人职务 + */ + private String exchangeLeadPeopleJob; + /** + * 49流转备注 + */ + private String exchangeDesc; + + + private long tag; + + +} + diff --git a/src/main/java/com/ruoyi/doublePrevention/repository/RiskOldInfoRepository.java b/src/main/java/com/ruoyi/doublePrevention/repository/RiskOldInfoRepository.java new file mode 100644 index 0000000..b9b35ce --- /dev/null +++ b/src/main/java/com/ruoyi/doublePrevention/repository/RiskOldInfoRepository.java @@ -0,0 +1,20 @@ +package com.ruoyi.doublePrevention.repository; + + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.ruoyi.doublePrevention.entity.RiskOldInfo; +import com.ruoyi.doublePrevention.entity.dto.req.RiskOldInfoQueryReqDTO; +import org.apache.ibatis.annotations.Param; +import org.springframework.stereotype.Repository; + +import java.util.List; + + +@Repository +public interface RiskOldInfoRepository extends BaseMapper<RiskOldInfo> { + + + List<RiskOldInfo> selectOldRiskInfoPage(@Param("queryReqDTO") RiskOldInfoQueryReqDTO queryReqDTO); + + +} diff --git a/src/main/java/com/ruoyi/doublePrevention/service/baseService/RiskOldInfoService.java b/src/main/java/com/ruoyi/doublePrevention/service/baseService/RiskOldInfoService.java new file mode 100644 index 0000000..25cb9a3 --- /dev/null +++ b/src/main/java/com/ruoyi/doublePrevention/service/baseService/RiskOldInfoService.java @@ -0,0 +1,14 @@ +package com.ruoyi.doublePrevention.service.baseService; + + +import com.ruoyi.doublePrevention.entity.dto.req.RiskOldInfoQueryReqDTO; +import com.ruoyi.doublePrevention.entity.dto.resp.RiskOldInfoQueryRespDTO; +import com.ruoyi.doublePrevention.vo.ResultVO; + +import java.util.List; + +public interface RiskOldInfoService { + + ResultVO<RiskOldInfoQueryRespDTO> selectOldRiskInfoPage(RiskOldInfoQueryReqDTO queryReqDTO); + +} diff --git a/src/main/java/com/ruoyi/doublePrevention/service/baseService/impl/RiskOldInfoServiceImpl.java b/src/main/java/com/ruoyi/doublePrevention/service/baseService/impl/RiskOldInfoServiceImpl.java new file mode 100644 index 0000000..fc55604 --- /dev/null +++ b/src/main/java/com/ruoyi/doublePrevention/service/baseService/impl/RiskOldInfoServiceImpl.java @@ -0,0 +1,81 @@ +package com.ruoyi.doublePrevention.service.baseService.impl; + + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.github.pagehelper.Page; +import com.github.pagehelper.PageHelper; +import com.ruoyi.common.exception.BusinessException; +import com.ruoyi.common.utils.BeanCopyUtils; +import com.ruoyi.doublePrevention.entity.PreventRiskEvent; +import com.ruoyi.doublePrevention.entity.RiskOldInfo; +import com.ruoyi.doublePrevention.entity.dto.req.RiskOldInfoQueryReqDTO; +import com.ruoyi.doublePrevention.entity.dto.resp.RiskOldInfoQueryRespDTO; +import com.ruoyi.doublePrevention.enums.ErrorCodes; +import com.ruoyi.doublePrevention.repository.RiskOldInfoRepository; +import com.ruoyi.doublePrevention.service.baseService.RiskOldInfoService; +import com.ruoyi.doublePrevention.vo.ResultVO; +import com.ruoyi.project.system.user.mapper.UserMapper; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.util.ObjectUtils; + +import javax.annotation.Resource; +import java.util.ArrayList; +import java.util.List; + +@Service +public class RiskOldInfoServiceImpl implements RiskOldInfoService { + + @Autowired + private RiskOldInfoRepository repository; + + + @Override + public ResultVO<RiskOldInfoQueryRespDTO> selectOldRiskInfoPage(RiskOldInfoQueryReqDTO queryReqDTO) { + + ResultVO resultVO = new ResultVO<>(); + + if (ObjectUtils.isEmpty(queryReqDTO.getPageSize())){ + throw new BusinessException("分页信息不能为空"); + } + if (ObjectUtils.isEmpty(queryReqDTO.getPageIndex())){ + throw new BusinessException("分页信息不能为空"); + } + + if (queryReqDTO.getReportPeople() == "" ){ + queryReqDTO.setReportPeople(null); + } + if (queryReqDTO.getFindPeople() == "" ){ + queryReqDTO.setFindPeople(null); + } + if (queryReqDTO.getAcceptPeople() == "" ){ + queryReqDTO.setAcceptPeople(null); + } + if (queryReqDTO.getRiskLevel() == "" ){ + queryReqDTO.setRiskLevel(null); + } + if (queryReqDTO.getRiskDep() == "" ){ + queryReqDTO.setRiskDep(null); + } + if (queryReqDTO.getMajor() == "" ){ + queryReqDTO.setMajor(null); + } + + Integer pageIndex = queryReqDTO.getPageIndex(); + Integer pageSize = queryReqDTO.getPageSize(); + + Page<RiskOldInfo> page = PageHelper.startPage(pageIndex, pageSize); + + List<RiskOldInfo> riskOldInfo = repository.selectOldRiskInfoPage(queryReqDTO); + List<RiskOldInfo> result = page.getResult(); + + resultVO.setData(result); + resultVO.setCount((int) page.getTotal()); + resultVO.setPageIndex(page.getPageNum()); + resultVO.setPageSize(page.getPageSize()); + + return resultVO; + } + +} diff --git a/src/main/java/com/ruoyi/doublePrevention/vo/ResultVO.java b/src/main/java/com/ruoyi/doublePrevention/vo/ResultVO.java index 6c5c95d..29947af 100644 --- a/src/main/java/com/ruoyi/doublePrevention/vo/ResultVO.java +++ b/src/main/java/com/ruoyi/doublePrevention/vo/ResultVO.java @@ -13,7 +13,12 @@ private String msg; + private int pageIndex; + + private int pageSize; + private T data; + public static ResultVO success(){ ResultVO resultVO = new ResultVO(); @@ -43,6 +48,21 @@ } + public int getPageIndex() { + return pageIndex; + } + + public void setPageIndex(int pageIndex) { + this.pageIndex = pageIndex; + } + + public int getPageSize() { + return pageSize; + } + + public void setPageSize(int pageSize) { + this.pageSize = pageSize; + } public String getCode() { return code; diff --git a/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/controller/RiskEvaluationController.java b/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/controller/RiskEvaluationController.java index bc659d5..3e60c40 100644 --- a/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/controller/RiskEvaluationController.java +++ b/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/controller/RiskEvaluationController.java @@ -72,6 +72,183 @@ private ICriterionDetailService criterionDetailService; +// /** +// * 用于设备设施计划的导入 +// * @param file +// * @return +// * @throws Exception +// */ +// @Log(title = "设备设施计划导入", businessType = BusinessType.IMPORT) +// @PostMapping("/deviceImportData") +// @ResponseBody +// @Transactional +// public AjaxResult deviceImportData(MultipartFile file) throws Exception { +// User user = ShiroUtils.getSysUser(); +// +// //查询各个评分所用的准则明细 +// List<CriterionDetail> LS_L = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LS_L.getCriterionId()); +// List<CriterionDetail> LS_S = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LS_S.getCriterionId()); +// +// List<CriterionDetail> LEC_L = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LEC_L.getCriterionId()); +// List<CriterionDetail> LEC_E = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LEC_E.getCriterionId()); +// List<CriterionDetail> LEC_C = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LEC_C.getCriterionId()); +// +// List<CriterionDetail> MES_M = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.MES_M.getCriterionId()); +// List<CriterionDetail> MES_E = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.MES_E.getCriterionId()); +// List<CriterionDetail> MES_S = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.MES_S.getCriterionId()); +// +// List<CriterionDetail> RS_R = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.RS_R.getCriterionId()); +// List<CriterionDetail> RS_S = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.RS_S.getCriterionId()); +// +// +// +// ExcelUtil<RiskEvaluationDTO> util = new ExcelUtil<RiskEvaluationDTO>(RiskEvaluationDTO.class); +// List<RiskEvaluationDTO> deviceList = util.importExcel(file.getInputStream()); +// +// RiskList risk = new RiskList(); +// +// RiskEvaluationPlan plan = new RiskEvaluationPlan(); +// //首先添加设备 +// for (RiskEvaluationDTO riskEvaluationDTO :deviceList){ +// +// //如果不为空,就新增设备 +// if (StringUtils.isNotEmpty(riskEvaluationDTO.getRiskListName())) { +// BeanUtils.copyProperties(riskEvaluationDTO, risk); +// risk.setCompanyId(user.getCompanyId()); +// risk.setUserId(user.getUserId()); +// risk.setCreateBy(user.getUserName()); +// risk.setRiskType(TrRiskTypeEnum.DEVICE.getCode()); +// //根据名称,替换成对应ID +// +// //设备设施类型 +// String riskType = riskEvaluationDTO.getRiskListDeviceType(); +// if (StringUtils.isNotEmpty(riskType)) { +// List<RiskType> riskTypeList = typeService.selectRiskTypeListByCompanyId(user.getCompanyId(), 1); +// for (RiskType r : riskTypeList) { +// if (riskType.equals(r.getRiskTypeName())) { +// risk.setRiskListDeviceType(r.getRiskTypeId()); +// break; +// } +// } +// if (risk.getRiskListDeviceType()==null){ +// return AjaxResult.error("{"+riskType+"},该[设备设施类型]未找到"); +// } +// } else { +// return AjaxResult.error("[设备设施类型]不能为空"); +// } +// +// //区域/位置 +// String region = riskEvaluationDTO.getRegionName(); +// if (StringUtils.isNotEmpty(region)) { +// List<Region> regionList = regionService.selectRegionListByCompanyId(user.getCompanyId()); +// for (Region r : regionList) { +// if (region.equals(r.getRegionName())) { +// risk.setRegionId(r.getRegionId()); +// break; +// } +// } +// if (risk.getRegionId()==null){ +// return AjaxResult.error("{"+region+"},该[区域/位置]未找到"); +// } +// } else { +// return AjaxResult.error("[区域/位置]不能为空"); +// } +// +// //管辖部门/单位 +// String dept = riskEvaluationDTO.getDeptName(); +// if (StringUtils.isNotEmpty(dept)) { +// List<Dept> deptList = deptService.selectDeptListByCompanyId(user.getCompanyId()); +// for (Dept d : deptList) { +// if (dept.equals(d.getDeptName())) { +// risk.setDeptId(d.getDeptId()); +// break; +// } +// } +// if (risk.getDeptId()==null){ +// return AjaxResult.error("{"+dept+"},该[管辖部门/单位]未找到"); +// } +// } else { +// return AjaxResult.error("[管辖部门/单位]不能为空"); +// } +// +// //保存复制过的对象 +// int addNum = riskListService.insertRiskList(risk); +// if (addNum<= 0){ +// throw new Exception("设备导入失败!"); +// } +// } +// +// //新增设备后继续新增计划,评价计划是否存在 +// if (StringUtils.isNotEmpty(riskEvaluationDTO.getEvaluationPlanName())){ +// BeanUtils.copyProperties(riskEvaluationDTO,plan); +// //保存复制过的对象 +// plan.setEvaluationRiskId(risk.getRiskListId()); +// plan.setCompanyId(user.getCompanyId()); +// plan.setPlanUserId(user.getUserId()); +// plan.setIdentifyUserId(user.getUserId()); +// plan.setPlanStatus(2); +// plan.setStageStatus(4); +// plan.setIdentifyStatus(2); +// plan.setEvaluationType(1); +// plan.setRiskIdentifyMethod(1); +// +// int addNum = riskEvaluationPlanService.insertRiskEvaluationPlan(plan); +// if (addNum<=0){ +// throw new Exception("计划导入失败!"); +// } +// } +// System.out.println(plan); +// +// //新增过计划后,增加检查点, +// RiskCheckPoint checkPoint = new RiskCheckPoint(); +// BeanUtils.copyProperties(riskEvaluationDTO,checkPoint); +// checkPoint.setPlanId(plan.getPlanId()); +// checkPoint.setEvaluationUserId(user.getUserId()); +// checkPoint.setReviewUserId(user.getUserId()); +// checkPoint.setEvaluationStatus(2); +// checkPoint.setReviewStatus(2); +// checkPoint.setCompanyId(user.getCompanyId()); +// +// //根据分数信息,和选择评分类型,查找用户选择的分级 +// if (TrEvaluationMethodTypeEnum.LS.getMethodId().equals(checkPoint.getEvaluationMethodType())){ +// checkPoint.setEvaluationNowLsL(getScoreId(LS_L,riskEvaluationDTO.getEvaluationNowLsL())); +// checkPoint.setEvaluationNowLsS(getScoreId(LS_S,riskEvaluationDTO.getEvaluationNowLsS())); +// +// checkPoint.setEvaluationAfterLsL(getScoreId(LS_L,riskEvaluationDTO.getEvaluationAfterLsL())); +// checkPoint.setEvaluationAfterLsS(getScoreId(LS_S,riskEvaluationDTO.getEvaluationAfterLsS())); +// }else if(TrEvaluationMethodTypeEnum.LEC.getMethodId().equals(checkPoint.getEvaluationMethodType())){ +// checkPoint.setEvaluationNowLecL(getScoreId(LEC_L,riskEvaluationDTO.getEvaluationNowLecL())); +// checkPoint.setEvaluationNowLecE(getScoreId(LEC_E,riskEvaluationDTO.getEvaluationNowLecE())); +// checkPoint.setEvaluationNowLecC(getScoreId(LEC_C,riskEvaluationDTO.getEvaluationNowLecC())); +// +// checkPoint.setEvaluationAfterLecL(getScoreId(LEC_L,riskEvaluationDTO.getEvaluationAfterLecL())); +// checkPoint.setEvaluationAfterLecE(getScoreId(LEC_E,riskEvaluationDTO.getEvaluationAfterLecE())); +// checkPoint.setEvaluationAfterLecC(getScoreId(LEC_C,riskEvaluationDTO.getEvaluationAfterLecC())); +// }else if(TrEvaluationMethodTypeEnum.MES.getMethodId().equals(checkPoint.getEvaluationMethodType())){ +// checkPoint.setEvaluationNowMesM(getScoreId(MES_M,riskEvaluationDTO.getEvaluationNowMesM())); +// checkPoint.setEvaluationNowMesE(getScoreId(MES_E,riskEvaluationDTO.getEvaluationNowMesE())); +// checkPoint.setEvaluationNowMesS(getScoreId(MES_S,riskEvaluationDTO.getEvaluationNowMesS())); +// +// checkPoint.setEvaluationAfterMesM(getScoreId(MES_M,riskEvaluationDTO.getEvaluationAfterMesM())); +// checkPoint.setEvaluationAfterMesE(getScoreId(MES_E,riskEvaluationDTO.getEvaluationAfterMesE())); +// checkPoint.setEvaluationAfterMesS(getScoreId(MES_S,riskEvaluationDTO.getEvaluationAfterMesS())); +// }else if(TrEvaluationMethodTypeEnum.RS.getMethodId().equals(checkPoint.getEvaluationMethodType())){ +// checkPoint.setEvaluationNowRsR(getScoreIdByRsR(RS_R,riskEvaluationDTO.getEvaluationNowRsR())); +// checkPoint.setEvaluationNowRsS(getScoreIdByRsS(RS_S,riskEvaluationDTO.getEvaluationNowRsS())); +// +// checkPoint.setEvaluationAfterRsR(getScoreIdByRsR(RS_R,riskEvaluationDTO.getEvaluationAfterRsR())); +// checkPoint.setEvaluationAfterRsS(getScoreIdByRsS(RS_S,riskEvaluationDTO.getEvaluationAfterRsS())); +// } +// +// //计算分值 +// pingFen(checkPoint); +// +// riskCheckPointService.insertRiskCheckPoint(checkPoint); +// } +// +// return AjaxResult.success("导入成功!"); +// } + /** * 用于设备设施计划的导入 * @param file @@ -84,23 +261,6 @@ @Transactional public AjaxResult deviceImportData(MultipartFile file) throws Exception { User user = ShiroUtils.getSysUser(); - - //查询各个评分所用的准则明细 - List<CriterionDetail> LS_L = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LS_L.getCriterionId()); - List<CriterionDetail> LS_S = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LS_S.getCriterionId()); - - List<CriterionDetail> LEC_L = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LEC_L.getCriterionId()); - List<CriterionDetail> LEC_E = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LEC_E.getCriterionId()); - List<CriterionDetail> LEC_C = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.LEC_C.getCriterionId()); - - List<CriterionDetail> MES_M = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.MES_M.getCriterionId()); - List<CriterionDetail> MES_E = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.MES_E.getCriterionId()); - List<CriterionDetail> MES_S = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.MES_S.getCriterionId()); - - List<CriterionDetail> RS_R = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.RS_R.getCriterionId()); - List<CriterionDetail> RS_S = criterionDetailService.selectCriterionDetailListByCriterionId(TrEvaluationMethodDetailsEnum.RS_S.getCriterionId()); - - ExcelUtil<RiskEvaluationDTO> util = new ExcelUtil<RiskEvaluationDTO>(RiskEvaluationDTO.class); List<RiskEvaluationDTO> deviceList = util.importExcel(file.getInputStream()); @@ -177,73 +337,6 @@ throw new Exception("设备导入失败!"); } } - - //新增设备后继续新增计划,评价计划是否存在 - if (StringUtils.isNotEmpty(riskEvaluationDTO.getEvaluationPlanName())){ - BeanUtils.copyProperties(riskEvaluationDTO,plan); - //保存复制过的对象 - plan.setEvaluationRiskId(risk.getRiskListId()); - plan.setCompanyId(user.getCompanyId()); - plan.setPlanUserId(user.getUserId()); - plan.setIdentifyUserId(user.getUserId()); - plan.setPlanStatus(2); - plan.setStageStatus(4); - plan.setIdentifyStatus(2); - plan.setEvaluationType(1); - plan.setRiskIdentifyMethod(1); - - int addNum = riskEvaluationPlanService.insertRiskEvaluationPlan(plan); - if (addNum<=0){ - throw new Exception("计划导入失败!"); - } - } - System.out.println(plan); - - //新增过计划后,增加检查点, - RiskCheckPoint checkPoint = new RiskCheckPoint(); - BeanUtils.copyProperties(riskEvaluationDTO,checkPoint); - checkPoint.setPlanId(plan.getPlanId()); - checkPoint.setEvaluationUserId(user.getUserId()); - checkPoint.setReviewUserId(user.getUserId()); - checkPoint.setEvaluationStatus(2); - checkPoint.setReviewStatus(2); - checkPoint.setCompanyId(user.getCompanyId()); - - //根据分数信息,和选择评分类型,查找用户选择的分级 - if (TrEvaluationMethodTypeEnum.LS.getMethodId().equals(checkPoint.getEvaluationMethodType())){ - checkPoint.setEvaluationNowLsL(getScoreId(LS_L,riskEvaluationDTO.getEvaluationNowLsL())); - checkPoint.setEvaluationNowLsS(getScoreId(LS_S,riskEvaluationDTO.getEvaluationNowLsS())); - - checkPoint.setEvaluationAfterLsL(getScoreId(LS_L,riskEvaluationDTO.getEvaluationAfterLsL())); - checkPoint.setEvaluationAfterLsS(getScoreId(LS_S,riskEvaluationDTO.getEvaluationAfterLsS())); - }else if(TrEvaluationMethodTypeEnum.LEC.getMethodId().equals(checkPoint.getEvaluationMethodType())){ - checkPoint.setEvaluationNowLecL(getScoreId(LEC_L,riskEvaluationDTO.getEvaluationNowLecL())); - checkPoint.setEvaluationNowLecE(getScoreId(LEC_E,riskEvaluationDTO.getEvaluationNowLecE())); - checkPoint.setEvaluationNowLecC(getScoreId(LEC_C,riskEvaluationDTO.getEvaluationNowLecC())); - - checkPoint.setEvaluationAfterLecL(getScoreId(LEC_L,riskEvaluationDTO.getEvaluationAfterLecL())); - checkPoint.setEvaluationAfterLecE(getScoreId(LEC_E,riskEvaluationDTO.getEvaluationAfterLecE())); - checkPoint.setEvaluationAfterLecC(getScoreId(LEC_C,riskEvaluationDTO.getEvaluationAfterLecC())); - }else if(TrEvaluationMethodTypeEnum.MES.getMethodId().equals(checkPoint.getEvaluationMethodType())){ - checkPoint.setEvaluationNowMesM(getScoreId(MES_M,riskEvaluationDTO.getEvaluationNowMesM())); - checkPoint.setEvaluationNowMesE(getScoreId(MES_E,riskEvaluationDTO.getEvaluationNowMesE())); - checkPoint.setEvaluationNowMesS(getScoreId(MES_S,riskEvaluationDTO.getEvaluationNowMesS())); - - checkPoint.setEvaluationAfterMesM(getScoreId(MES_M,riskEvaluationDTO.getEvaluationAfterMesM())); - checkPoint.setEvaluationAfterMesE(getScoreId(MES_E,riskEvaluationDTO.getEvaluationAfterMesE())); - checkPoint.setEvaluationAfterMesS(getScoreId(MES_S,riskEvaluationDTO.getEvaluationAfterMesS())); - }else if(TrEvaluationMethodTypeEnum.RS.getMethodId().equals(checkPoint.getEvaluationMethodType())){ - checkPoint.setEvaluationNowRsR(getScoreIdByRsR(RS_R,riskEvaluationDTO.getEvaluationNowRsR())); - checkPoint.setEvaluationNowRsS(getScoreIdByRsS(RS_S,riskEvaluationDTO.getEvaluationNowRsS())); - - checkPoint.setEvaluationAfterRsR(getScoreIdByRsR(RS_R,riskEvaluationDTO.getEvaluationAfterRsR())); - checkPoint.setEvaluationAfterRsS(getScoreIdByRsS(RS_S,riskEvaluationDTO.getEvaluationAfterRsS())); - } - - //计算分值 - pingFen(checkPoint); - - riskCheckPointService.insertRiskCheckPoint(checkPoint); } return AjaxResult.success("导入成功!"); diff --git a/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/domain/dto/RiskEvaluationDTO.java b/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/domain/dto/RiskEvaluationDTO.java index 5e13482..2b74f7f 100644 --- a/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/domain/dto/RiskEvaluationDTO.java +++ b/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/domain/dto/RiskEvaluationDTO.java @@ -21,15 +21,15 @@ //风险单元相关字段********************************************************************************************************** /** 风险单元编号 */ - @Excel(name = "风险单元编号") + @Excel(name = "设备编号") private String riskListNum; /** 风险单元名称 */ - @Excel(name = "风险单元名称") + @Excel(name = "设备名称") private String riskListName; /** 是否特种(1否,2是) */ - @Excel(name = "是否特种(1否,2是)") + @Excel(name = "是否特种") private Long riskListIsSpecial; /** 图片 */ diff --git a/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/domain/dto/RiskEvaluationDTO_old.java b/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/domain/dto/RiskEvaluationDTO_old.java new file mode 100644 index 0000000..06ff8f1 --- /dev/null +++ b/src/main/java/com/ruoyi/project/tr/riskEvaluationPlan/domain/dto/RiskEvaluationDTO_old.java @@ -0,0 +1,315 @@ +package com.ruoyi.project.tr.riskEvaluationPlan.domain.dto; + +import com.ruoyi.framework.aspectj.lang.annotation.Excel; +import com.ruoyi.framework.web.domain.BaseEntity; +import lombok.Data; + +import java.math.BigDecimal; +import java.util.Date; + +/** + * 评价计划对象 tr_risk_evaluation_plan + * + * @author wm + * @date 2020-05-09 + */ +@Data +public class RiskEvaluationDTO_old extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + //风险单元相关字段********************************************************************************************************** + + /** 风险单元编号 */ + @Excel(name = "风险单元编号") + private String riskListNum; + + /** 风险单元名称 */ + @Excel(name = "风险单元名称") + private String riskListName; + + /** 是否特种(1否,2是) */ + @Excel(name = "是否特种(1否,2是)") + private Long riskListIsSpecial; + + /** 图片 */ + @Excel(name = "图片") + private String riskListImgUrl; + + /** 设备设施类型 */ + @Excel(name = "设备设施类型") + private String riskListDeviceType; + + /** 规格/型号 */ + @Excel(name = "规格/型号") + private String riskListDeviceModel; + + /** 作业活动类型 */ + @Excel(name = "作业活动类型") + private String riskListWorkType; + + /** 作业频率 */ + @Excel(name = "作业频率") + private String riskListWorkFrequency; + + /** 工艺作业类型 */ + @Excel(name = "工艺作业类型") + private String riskListCraftsType; + + /** 节点描述 */ + @Excel(name = "节点描述") + private String riskListCraftsDescription; + + + //****实际对应区域表 + /** 区域/位置 */ + @Excel(name = "区域/位置") + private String regionName; + + + /** 管辖单位/部门 */ + @Excel(name = "管辖单位/部门") + private String deptName; + + + /** 风险单元类型(1设备设置,2作业活动,3工艺节点) */ + @Excel(name = "风险单元类型(1设备设置,2作业活动,3工艺节点)") + private Integer riskType; + + + + //计划相关字段*********************************************************************************************************** + + /** 风险评价计划名称 */ + @Excel(name = "风险评价计划名称") + private String evaluationPlanName; + + /** 评价开始时间 */ + @Excel(name = "评价开始时间", width = 30, dateFormat = "yyyy-MM-dd") + private Date evaluationBeginTime; + + /** 评价结束时间 */ + @Excel(name = "评价结束时间", width = 30, dateFormat = "yyyy-MM-dd") + private Date evaluationEndTime; + + /** 评价类型 */ + @Excel(name = "评价类型" ,readConverterExp = "1=设备设施,2=作业活动,3=工艺节点") + private Integer evaluationType; + /** 辨识方法 */ + @Excel(name = "辨识方法" ,readConverterExp = "1=SCL,2=JHA,3=HAZOP") + private Integer riskIdentifyMethod; + + /** 阶段状态 1,计划阶段 2,辨识阶段 3,评价阶段 4,审核阶段 */ + @Excel(name = "阶段状态",readConverterExp = "1=计划阶段,2=辨识阶段,3=评价阶段,4=审核阶段") + private Integer stageStatus; + + /** 计划状态 */ + @Excel(name = "计划状态" ,readConverterExp = "1=未派发,2=已派发") + private Integer planStatus; + /** 辨识状态 */ + @Excel(name = "辨识状态" ,readConverterExp = "1=未辨识,2=已辨识") + private Integer identifyStatus; + + + + + //检查点关联字段********************************************************************************************** + /** SCL_检查项目 */ + @Excel(name = "SCL_检查项目") + private String sclJianchaXiangmu; + + /** SCL_检查标准 */ + @Excel(name = "SCL_检查标准") + private String sclJianchaMubiao; + + /** SCL_不符合标准情况 */ + @Excel(name = "SCL_不符合标准情况") + private String sclQingkuang; + + /** SCL_主要后果 */ + @Excel(name = "SCL_主要后果") + private String sclZhuyaoHouguo; + + /** JHA_作业步骤 */ + @Excel(name = "JHA_作业步骤") + private String jhaZuoyeBuzhou; + + /** JHA_危险源或潜在事件 */ + @Excel(name = "JHA_危险源或潜在事件") + private String jhaWeixianyuan; + + /** JHA_可能发生的事故类型及后果 */ + @Excel(name = "JHA_可能发生的事故类型及后果") + private String jhaShiguLeixing; + + /** HAZOP_节点 */ + @Excel(name = "HAZOP_节点") + private String hazopJiedian; + + /** HAZOP_参数 */ + @Excel(name = "HAZOP_参数") + private String hazopCanshu; + + /** HAZOP_参数描述 */ + @Excel(name = "HAZOP_参数描述") + private String hazopCanshuMiaoshu; + + /** HAZOP_引导词 */ + @Excel(name = "HAZOP_引导词") + private String hazopYindaoci; + + /** HAZOP_偏差 */ + @Excel(name = "HAZOP_偏差") + private String hazopPiancha; + + /** HAZOP_可能原因 */ + @Excel(name = "HAZOP_可能原因") + private String hazopYuanyin; + + /** HAZOP_主要后果 */ + @Excel(name = "HAZOP_主要后果") + private String hazopHouguo; + + /** 评价方法 */ + @Excel(name = "评价方法",readConverterExp = "1=LS,2=LEC,3=MES,4=RS") + private Integer evaluationMethodType; + + + /** 现有技术措施 */ + @Excel(name = "现有技术措施") + private String evaluationNowJishu; + + /** 现有管理措施 */ + @Excel(name = "现有管理措施") + private String evaluationNowGuanli; + + /** 现有教育措施 */ + @Excel(name = "现有教育措施") + private String evaluationNowJiaoyu; + + /** 现有个体防护措施 */ + @Excel(name = "现有个体防护措施") + private String evaluationNowFanghu; + + /** 现有应急措施 */ + @Excel(name = "现有应急措施") + private String evaluationNowYingji; + + /** LS_L的数值 */ + @Excel(name = "现有LS_L的数值") + private BigDecimal evaluationNowLsL; + + /** LS_S的数值 */ + @Excel(name = "现有LS_S的数值") + private BigDecimal evaluationNowLsS; + + /** LEC_L的数值 */ + @Excel(name = "现有LEC_L的数值") + private BigDecimal evaluationNowLecL; + + /** LEC_E的数值 */ + @Excel(name = "现有LEC_E的数值") + private BigDecimal evaluationNowLecE; + + /** LEC_C的数值 */ + @Excel(name = "现有LEC_C的数值") + private BigDecimal evaluationNowLecC; + + /** MES_M的数值 */ + @Excel(name = "现有MES_M的数值") + private BigDecimal evaluationNowMesM; + + /** MES_E的数值 */ + @Excel(name = "现有MES_E的数值") + private BigDecimal evaluationNowMesE; + + /** MES_S的数值 */ + @Excel(name = "现有MES_S的数值") + private BigDecimal evaluationNowMesS; + + /** RS_R的数值 */ + @Excel(name = "现有RS_R的数值") + private String evaluationNowRsR; + + /** RS_S的数值 */ + @Excel(name = "现有RS_S的数值") + private String evaluationNowRsS; + + + + + + + /** 建议技术措施 */ + @Excel(name = "建议技术措施") + private String evaluationAfterJishu; + + /** 建议管理措施 */ + @Excel(name = "建议管理措施") + private String evaluationAfterGuanli; + + /** 建议培训教育措施 */ + @Excel(name = "建议培训教育措施") + private String evaluationAfterJiaoyu; + + /** 建议个体防护措施 */ + @Excel(name = "建议个体防护措施") + private String evaluationAfterFanghu; + + /** 建议应急处置措施 */ + @Excel(name = "建议应急处置措施") + private String evaluationAfterYingji; + + /** LS_L的数值 */ + @Excel(name = "建议LS_L的数值") + private BigDecimal evaluationAfterLsL; + + /** LS_S的数值 */ + @Excel(name = "建议LS_S的数值") + private BigDecimal evaluationAfterLsS; + + /** LEC_L的数值 */ + @Excel(name = "建议LEC_L的数值") + private BigDecimal evaluationAfterLecL; + + /** LEC_E的数值 */ + @Excel(name = "建议LEC_E的数值") + private BigDecimal evaluationAfterLecE; + + /** LEC_C的数值 */ + @Excel(name = "建议LEC_C的数值") + private BigDecimal evaluationAfterLecC; + + /** MES_M的数值 */ + @Excel(name = "建议MES_M的数值") + private BigDecimal evaluationAfterMesM; + + /** MES_E的数值 */ + @Excel(name = "建议MES_E的数值") + private BigDecimal evaluationAfterMesE; + + /** MES_S的数值 */ + @Excel(name = "建议MES_S的数值") + private BigDecimal evaluationAfterMesS; + + /** RS_R的数值 */ + @Excel(name = "建议RS_R的数值") + private String evaluationAfterRsR; + + /** RS_S的数值 */ + @Excel(name = "建议RS_S的数值") + private String evaluationAfterRsS; + + + /** 审核意见 */ + @Excel(name = "审核意见") + private String reviewOpinion; + + /** 审核时间 */ + @Excel(name = "审核时间", width = 30, dateFormat = "yyyy-MM-dd") + private Date reviewTime; + + + + +} diff --git a/src/main/resources/mybatis/doublePrevention/RiskOldInfoMapper.xml b/src/main/resources/mybatis/doublePrevention/RiskOldInfoMapper.xml new file mode 100644 index 0000000..e1ab0d9 --- /dev/null +++ b/src/main/resources/mybatis/doublePrevention/RiskOldInfoMapper.xml @@ -0,0 +1,90 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > +<mapper namespace="com.ruoyi.doublePrevention.repository.RiskOldInfoRepository"> + + <resultMap type="com.ruoyi.doublePrevention.entity.RiskOldInfo" id="Result"> + <id property="id" column="id"/> + <result property="reportDep" column="report_dep"/> + <result property="reportPeopleJob" column="report_people_job"/> + <result property="reportPeople" column="report_people"/> + <result property="findPeople" column="find_people"/> + <result property="findTime" column="find_time"/> + <result property="riskDesc" column="risk_desc"/> + <result property="riskSite" column="risk_site"/> + <result property="riskType" column="risk_type"/> + <result property="riskLevel" column="risk_level"/> + <result property="riskDep" column="risk_dep"/> + <result property="checkType" column="check_type" /> + <result property="major" column="major" /> + <result property="liabilityDep" column="liability_dep" /> + <result property="liabilityPeople" column="liability_people"/> + <result property="liabilityPeopleJob" column="liability_people_job" /> + <result property="rectifyTime" column="rectify_time" /> + <result property="rectifyTimeout" column="rectify_timeout" /> + <result property="leadDep" column="lead_dep"/> + <result property="leadJob" column="lead_job" /> + <result property="rectifyDep" column="rectify_dep" /> + <result property="rectifyPeopleJob" column="rectify_people_job" /> + <result property="rectifyPeople" column="rectify_people"/> + <result property="rectifyMeasure" column="rectify_measure" /> + <result property="rectifyStartTime" column="rectify_start_time" /> + <result property="rectifyFinishTime" column="rectify_finish_time" /> + <result property="rectifyDesc" column="rectify_desc"/> + <result property="cost" column="cost" /> + <result property="plan" column="cost" /> + <result property="precautionMeasure" column="precaution_measure" /> + <result property="acceptTime" column="accept_time" /> + <result property="acceptDesc" column="accept_desc"/> + <result property="acceptDep" column="accept_dep" /> + <result property="acceptPeople" column="accept_people" /> + <result property="acceptPeopleJob" column="accept_people_job" /> + <result property="cancelDep" column="cancel_dep"/> + <result property="cancelPeople" column="cancel_people" /> + <result property="cancelPeopleJob" column="cancel_people_job" /> + <result property="applyPeople" column="apply_people" /> + <result property="applyTime" column="apply_time"/> + <result property="applyDesc" column="apply_desc" /> + <result property="applyNote" column="apply_note" /> + <result property="applyTimeoutTime" column="apply_timeout_time" /> + <result property="applyDealPeople" column="apply_deal_people"/> + <result property="appleDealTime" column="apple_deal_time" /> + <result property="exchangeLeadDep" column="exchange_lead_dep" /> + <result property="exchangeLeadPeople" column="exchange_lead_people"/> + <result property="exchangeLeadPeopleJob" column="exchange_lead_people_job" /> + <result property="exchangeDesc" column="exchange_desc" /> + </resultMap> + + <select id="selectOldRiskInfoPage" resultMap="Result" > + select * from risk_old_info + <where> + 1 = 1 + <if test="queryReqDTO.reportPeople != null"> + and report_people = #{queryReqDTO.reportPeople} + </if> + <if test="queryReqDTO.findPeople != null"> + and find_people = #{queryReqDTO.findPeople} + </if> + <if test="queryReqDTO.acceptPeople != null "> + and accept_people = #{queryReqDTO.acceptPeople} + </if> + <if test="queryReqDTO.riskDep != null "> + and risk_dep = #{queryReqDTO.riskDep} + </if> + <if test="queryReqDTO.major != null "> + and report_people = #{queryReqDTO.major} + </if> + <if test="queryReqDTO.riskLevel != null "> + and risk_level = #{queryReqDTO.riskLevel} + </if> + <if test="queryReqDTO.startTime != null "> + and find_time > #{queryReqDTO.startTime} + </if> + <if test="queryReqDTO.endTime != null "> + and #{queryReqDTO.endTime} > find_time + </if> + </where> + order by find_time desc + </select> + + +</mapper> \ No newline at end of file -- Gitblit v1.9.2