From 388127e8966dc2ab54521d5a7ceb15baa1da06bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=AE=B5=E9=A3=9E=E5=AE=87?= <2684146481@qq.com> Date: Fri, 2 Jun 2023 18:18:28 +0800 Subject: [PATCH 01/14] =?UTF-8?q?=E9=A2=84=E8=A7=88=E4=BC=98=E5=8C=96?= =?UTF-8?q?=EF=BC=8C=E7=AC=AC=E4=BA=8C=E7=A7=8D=E5=B7=A5=E4=BD=9C=E7=A5=A8?= =?UTF-8?q?=EF=BC=8C=E6=B0=B4=E5=8A=9B=E6=9C=BA=E6=A2=B0=E5=B7=A5=E4=BD=9C?= =?UTF-8?q?=E7=A5=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ticket/constants/WorkTicketConstants.java | 132 +++++----- .../workTicket/entity/WorkTicketInfoEntity.java | 11 +- .../ticket/twoTicket/constant/TicketConstant.java | 58 +++++ .../controller/TicketProcessController.java | 3 +- .../twoTicket/service/TicketProcessService.java | 4 +- .../service/impl/TicketProcessServiceImpl.java | 277 ++++++++++++++------- .../hzims/ticket/twoTicket/utils/WordHelper.java | 229 +++++++++++++++++ .../hzims/ticket/twoTicket/utils/WordMapUtils.java | 120 +++++++++ .../ticket/twoTicket/vo/process/WorkTicketVo.java | 5 - .../java/com/hnac/hzims/ticket/utils/PdfUtils.java | 53 ++-- ...工作票危险点分析及控制措施票.docx | Bin 29439 -> 28979 bytes .../template/水力机械工作票模版.docx | Bin 0 -> 39730 bytes .../template/电气第一种工作票模版.docx | Bin 43047 -> 43033 bytes .../template/电气第二种工作票模版.docx | Bin 0 -> 38430 bytes 14 files changed, 707 insertions(+), 185 deletions(-) create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/constant/TicketConstant.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordMapUtils.java create mode 100644 hzims-service/ticket/src/main/resources/template/水力机械工作票模版.docx create mode 100644 hzims-service/ticket/src/main/resources/template/电气第二种工作票模版.docx diff --git a/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/constants/WorkTicketConstants.java b/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/constants/WorkTicketConstants.java index 9fa55b4..68fbb3f 100644 --- a/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/constants/WorkTicketConstants.java +++ b/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/constants/WorkTicketConstants.java @@ -2,77 +2,85 @@ package com.hnac.hzims.ticket.constants; import lombok.AllArgsConstructor; import lombok.Getter; + import java.util.Arrays; import java.util.Optional; /** * 工作票中所需常数定义 + * * @author hx */ public interface WorkTicketConstants { - @AllArgsConstructor - enum WorkTicketMeasureTypeEnum { - /**第一种安措**/ - ONE("1","matterLibraryListOne"), - /**第二种安措**/ - TWO("2","matterLibraryListTwo"), - /**第三种安措**/ - THREE("3","matterLibraryListThree"), - FOUR("4","matterLibraryListFour"), - Five("5","matterLibraryListFive"), - Flow("6","matterLibraryListFlow"), - ; - @Getter - private String type; - @Getter - private String convertAttributes; - } + @AllArgsConstructor + enum WorkTicketMeasureTypeEnum { + /** 第一种安措 **/ + ONE("1", "matterLibraryListOne"), + /** 第二种安措 **/ + TWO("2", "matterLibraryListTwo"), + /** 第三种安措 **/ + THREE("3", "matterLibraryListThree"), + FOUR("4", "matterLibraryListFour"), + Five("5", "matterLibraryListFive"), + Flow("6", "matterLibraryListFlow"), + //第二种工作票 + SEVEN("7", "matterLibraryListSeven"), + //水力机器工作票 + EIGHT("8", "matterLibraryListEight"), + NINE("9", "matterLibraryListNine"), + TEN("10", "matterLibraryListTen"), + + ; + @Getter + private String type; + @Getter + private String convertAttributes; + } - @AllArgsConstructor - enum FirstWorkTicketStatusEnum { - /**签发**/ - SIGN(1,"签发"), - /**收到工作票**/ - RECEIVE(2,"收到工作票"), - /**许可人许可**/ - LICENSE(3,"许可人许可"), - /**确认条件具备**/ - CONFIRM_MEASURE(4,"确认条件具备"), - /**工作负责人确认工作**/ - CONFIRM_WORK(5,"工作负责人确认工作"), - /**许可人确认工作结束**/ - WORK_FINISH(6,"许可人确认工作结束"), - /**工作票终结**/ - TICKET_FINISH(7,"工作票终结"), - /**结束**/ - FINISH(8,"结束"), - /**许可人延期确认**/ - LICENSE_DELAY(9,"许可人延期确认"), - /**负责人延期确认**/ - CONFIRM_DELAY(10,"负责人延期确认"), - /**作废**/ - INVALID(11,"作废"), - /**逾期**/ - OVERDUE(12,"逾期"), - /**线下开票**/ - OFFLINE(13,"线下开票"), - /**线下执行任务**/ - OFFLINE_OPERATE(14,"线下执行任务"), - /**线下许可人许可**/ - OFFLINE_LICENSE(15,"线下许可人许可"), - /**线下结束**/ - OFFLINE_END(16,"线下结束") - ; - @Getter - private Integer status; - @Getter - private String description; + @AllArgsConstructor + enum FirstWorkTicketStatusEnum { + /** 签发 **/ + SIGN(1, "签发"), + /** 收到工作票 **/ + RECEIVE(2, "收到工作票"), + /** 许可人许可 **/ + LICENSE(3, "许可人许可"), + /** 确认条件具备 **/ + CONFIRM_MEASURE(4, "确认条件具备"), + /** 工作负责人确认工作 **/ + CONFIRM_WORK(5, "工作负责人确认工作"), + /** 许可人确认工作结束 **/ + WORK_FINISH(6, "许可人确认工作结束"), + /** 工作票终结 **/ + TICKET_FINISH(7, "工作票终结"), + /** 结束 **/ + FINISH(8, "结束"), + /** 许可人延期确认 **/ + LICENSE_DELAY(9, "许可人延期确认"), + /** 负责人延期确认 **/ + CONFIRM_DELAY(10, "负责人延期确认"), + /** 作废 **/ + INVALID(11, "作废"), + /** 逾期 **/ + OVERDUE(12, "逾期"), + /** 线下开票 **/ + OFFLINE(13, "线下开票"), + /** 线下执行任务 **/ + OFFLINE_OPERATE(14, "线下执行任务"), + /** 线下许可人许可 **/ + OFFLINE_LICENSE(15, "线下许可人许可"), + /** 线下结束 **/ + OFFLINE_END(16, "线下结束"); + @Getter + private Integer status; + @Getter + private String description; - public static FirstWorkTicketStatusEnum getEnumByStatus(Integer status) { - Optional statusOptional = Arrays.stream(FirstWorkTicketStatusEnum.class.getEnumConstants()) - .filter(e-> status.equals(e.getStatus())).findAny(); - return statusOptional.orElse(null); - } - } + public static FirstWorkTicketStatusEnum getEnumByStatus(Integer status) { + Optional statusOptional = Arrays.stream(FirstWorkTicketStatusEnum.class.getEnumConstants()) + .filter(e -> status.equals(e.getStatus())).findAny(); + return statusOptional.orElse(null); + } + } } diff --git a/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/workTicket/entity/WorkTicketInfoEntity.java b/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/workTicket/entity/WorkTicketInfoEntity.java index 77e63a0..ff89923 100644 --- a/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/workTicket/entity/WorkTicketInfoEntity.java +++ b/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/workTicket/entity/WorkTicketInfoEntity.java @@ -316,8 +316,8 @@ public class WorkTicketInfoEntity extends TenantEntity implements Serializable { /** * 工作条件(false 停电 true 不停电) */ - @ApiModelProperty("工作条件(false 停电 true 不停电)") - private Boolean isPower; + @ApiModelProperty("工作条件(停电或不停电)") + private String power; /** @@ -414,6 +414,13 @@ public class WorkTicketInfoEntity extends TenantEntity implements Serializable { /** + * 用户Id + */ + @ApiModelProperty("用户Id") + private String flowUserId; + + + /** * 当前任务名 */ @ApiModelProperty("当前任务名") diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/constant/TicketConstant.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/constant/TicketConstant.java new file mode 100644 index 0000000..f74288f --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/constant/TicketConstant.java @@ -0,0 +1,58 @@ +package com.hnac.hzims.ticket.twoTicket.constant; + +/** + * 定义ticket常量 + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/2 13:48 + */ +public class TicketConstant { + + /** + * window操作系统工作票访问路径 + */ + public static final String TICKET_WINDOW_PATH = "hzims-service/ticket/src/main/resources/template"; + + /** + * Liunx操作系统工作票访问路径 + */ + public static final String TICKET_LIUNX_PATH = "/data/hzims/ticket/word/template/ticket"; + + + /** + * window操作系统工作票合并输出路径 + */ + public static final String TICKET_WINDOW_MERGE_PATH = "D:\\导出excel\\"; + + /** + * liunx操作系统工作票合并输出路径 + */ + public static final String TICKET_LIUNX_MERGE_PATH = "/data/hzims/ticket/word/template/ticket/ouput/"; + + /** + * os.name + */ + public static final String OS_NAME = System.getProperty("os.name"); + + + /** + * 安全隔离措施附页 + */ + public static final String SECURE_PAGE = "/secondary/工作票安全措施附页.docx"; + + /** + * 危险点分析与预控措施票 + */ + public static final String SAFETY_PAGE = "/secondary/工作票危险点分析及控制措施票.docx"; + /** + * 动火工作票 + */ + public static final String FLIGHT_PAGE = "/secondary/动火工作票.docx"; + + /** + * 有限空间监测记录单 + */ + public static final String SPACE_PAGE = "/secondary/有限空间监测记录单.docx"; + +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/controller/TicketProcessController.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/controller/TicketProcessController.java index caf10e2..a15519d 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/controller/TicketProcessController.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/controller/TicketProcessController.java @@ -61,8 +61,9 @@ public class TicketProcessController { @ApiOperation(value = "新预览") @ApiOperationSupport(order = 11) public void preview(@RequestParam(value = "ticketId", required = true) Long ticketId, + @RequestParam(value = "status", required = true) Integer status, HttpServletResponse response) { - ticketProcessService.newPreview(ticketId, response); + ticketProcessService.newPreview(ticketId, status, response); } } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/TicketProcessService.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/TicketProcessService.java index 156e974..c4522ba 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/TicketProcessService.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/TicketProcessService.java @@ -30,8 +30,10 @@ public interface TicketProcessService { /** * 新预览 + * + * @param status * @param response * @return */ - void newPreview(Long ticketId, HttpServletResponse response); + void newPreview(Long ticketId, Integer status, HttpServletResponse response); } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java index 5931c64..da04670 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java @@ -20,12 +20,15 @@ import com.hnac.hzims.ticket.constants.TicketConstants; import com.hnac.hzims.ticket.constants.WorkTicketConstants; import com.hnac.hzims.ticket.processflow.strategy.core.ProcessIdWorker; import com.hnac.hzims.ticket.response.ProcessWorkFlowResponse; +import com.hnac.hzims.ticket.twoTicket.constant.TicketConstant; import com.hnac.hzims.ticket.twoTicket.entity.TicketInfoDanger; import com.hnac.hzims.ticket.twoTicket.entity.WorkTicketFinish; import com.hnac.hzims.ticket.twoTicket.service.IFirstWorkTicketService; import com.hnac.hzims.ticket.twoTicket.service.IWorkTicketFinishService; import com.hnac.hzims.ticket.twoTicket.service.TicketInfoDangerService; import com.hnac.hzims.ticket.twoTicket.service.TicketProcessService; +import com.hnac.hzims.ticket.twoTicket.utils.WordHelper; +import com.hnac.hzims.ticket.twoTicket.utils.WordMapUtils; import com.hnac.hzims.ticket.twoTicket.vo.process.FristWorkTicketVo; import com.hnac.hzims.ticket.twoTicket.vo.process.WorkTicketVo; import com.hnac.hzims.ticket.utils.MergeDocUtils; @@ -58,7 +61,8 @@ import org.springframework.transaction.annotation.Transactional; import javax.servlet.ServletOutputStream; import javax.servlet.http.HttpServletResponse; import java.io.File; -import java.io.FileOutputStream; +import java.time.Duration; +import java.time.Instant; import java.time.LocalDate; import java.time.LocalDateTime; import java.util.*; @@ -148,28 +152,28 @@ public class TicketProcessServiceImpl implements TicketProcessService { public void startUp(WorkTicketVo workTicketVo) { log.info("执行 com.hnac.hzims.ticket.twoTicket.service.impl【startUp】 。。。方法"); if (workTicketVo.getWorkTicket().getSignage() == null) { - throw new ServiceException("站点编码不能为空"); + throw new ServiceException("票据抬头未配置,请您到站点管理配置"); } StationEntity stationEntity = new StationEntity(); stationEntity.setCode(workTicketVo.getWorkTicket().getSignageCode()); R stationClientOne = stationClient.getOne(stationEntity); if (!stationClientOne.isSuccess()) { - throw new IllegalArgumentException("站点编码不能为空"); + throw new IllegalArgumentException("票据抬头未配置,请您到站点管理配置?"); } StationEntity station = stationClientOne.getData(); if (station == null) { - throw new ServiceException("站点编码不能为空"); + throw new ServiceException("票据抬头未配置,请您到站点管理配置"); } log.info("前端查的站点编号 :{}", workTicketVo.getWorkTicket().getSignage()); log.info("后端查寻的站点编码 :{}", station.getSignage()); if (!workTicketVo.getWorkTicket().getSignage().equals(station.getSignage())) { - throw new ServiceException("站点编码不能为空"); + throw new ServiceException("站点标识不能为空"); } //获取站点编号 String signage = station.getSignage(); if (StringUtils.isBlank(signage) || signage.length() < 2) { - throw new ServiceException("站点编码不能为空"); + throw new ServiceException("站点标识不能为空"); } signage = signage.length() == 2 ? station.getSignage() : station.getSignage().substring(0, 2); @@ -405,6 +409,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { // log.error("获取用户信息失败"); // workTicket.setNextStepOperator(null); // } + workTicket.setFlowUserId(response.getUserId()); workTicket.setNextStepOperator(response.getNextStepOperator()); } @@ -504,35 +509,36 @@ public class TicketProcessServiceImpl implements TicketProcessService { * @param workTicketVo */ public void dealProcess(String newFirstWorkTicketFlowKey, WorkTicketVo workTicketVo) { + Instant start = Instant.now(); //若为线下工作票 则无需开启工作流 Integer status = WorkTicketConstants.FirstWorkTicketStatusEnum.SIGN.getStatus(); if (status.intValue() != workTicketVo.getWorkTicket().getFlowStatus().intValue()) { return; } - log.info("租户Id:{}", AuthUtil.getTenantId()); - log.info("用户部门Id: {}", AuthUtil.getUser().getDeptId()); - log.info("用户Id: {}", AuthUtil.getUserId()); + //log.info("租户Id:{}", AuthUtil.getTenantId()); + //log.info("用户部门Id: {}", AuthUtil.getUser().getDeptId()); + //log.info("用户Id: {}", AuthUtil.getUserId()); //获取签发人角色下的人员 - R> listR = userClient.relationUserListByRoleAlias(AuthUtil.getTenantId(), Long.parseLong(AuthUtil.getUser().getDeptId()), TicketConstants.SIGNER_ROLE); - if (!listR.isSuccess() || CollectionUtil.isEmpty(listR.getData())) { - throw new ServiceException("工作票签发人角色下未查询到相关人员"); - } - log.info("获取签发人角色下的人员: {}", listR.getData()); + // R> listR = userClient.relationUserListByRoleAlias(AuthUtil.getTenantId(), Long.parseLong(AuthUtil.getUser().getDeptId()), TicketConstants.SIGNER_ROLE); + // if (!listR.isSuccess() || CollectionUtil.isEmpty(listR.getData())) { + // throw new ServiceException("工作票签发人角色下未查询到相关人员"); + // } Map params = new HashMap<>(4); params.put("workTicketVo", workTicketVo); //已开启流程 - workTicketVo.setIsState(true); - log.info("获取表单的数据: {}", workTicketVo); R processInstanceContainNameByKey = flowClient.startProcessInstanceContainNameByKey(newFirstWorkTicketFlowKey, String.valueOf(workTicketVo.getWorkTicket().getId()), workTicketVo.getWorkTicket().getWorkContent(), params); log.info("processInstanceContainNameByKey.isSuccess() : {}", processInstanceContainNameByKey.isSuccess()); - log.info("processInstanceContainNameByKey.getData() : {}", processInstanceContainNameByKey.getData()); - log.info("BladeFlow processInstanceContainNameByKey:{}", processInstanceContainNameByKey); if (!processInstanceContainNameByKey.isSuccess() && processInstanceContainNameByKey.getCode() == 500) { log.error("processInstanceContainNameByKey {}", processInstanceContainNameByKey.getMsg()); throw new ServiceException("不好意思,您暂无权限..."); } log.info("获取启动流程数据 : {}", processInstanceContainNameByKey); + Duration between = Duration.between(start, Instant.now()); + System.out.println("================================================================"); + System.err.println("耗时: " + (between.getSeconds()) + "秒"); + System.err.println("耗时: " + (between.toMillis()) + "毫秒"); + System.out.println("================================================================"); } @@ -660,12 +666,13 @@ public class TicketProcessServiceImpl implements TicketProcessService { * 新预览 * * @param ticketId + * @param status * @param response * @return */ @SneakyThrows @Override - public void newPreview(Long ticketId, HttpServletResponse response) { + public void newPreview(Long ticketId, Integer status, HttpServletResponse response) { String fileName = IdWorker.get32UUID() + ".docx"; // response.setContentType("application/octet-stream;charset=ISO8859-1"); response.setHeader("Content-Disposition", "attachment; filename=" + fileName); @@ -675,65 +682,67 @@ public class TicketProcessServiceImpl implements TicketProcessService { WorkTicketVo workTicketVo = ticketInfoService.selectDetailsById(ticketId); //将查询的数据转换为map Map workTicketInfoMap = this.convertMap(workTicketVo); + Map resultMap = WordHelper.resultMap(workTicketInfoMap); //创建新的map - for (Map.Entry stringObjectEntry : workTicketInfoMap.entrySet()) { + for (Map.Entry stringObjectEntry : resultMap.entrySet()) { log.info("获取map : " + stringObjectEntry.getKey() + "=====>" + stringObjectEntry.getValue()); } WorkTicketInfoEntity workTicket = workTicketVo.getWorkTicket(); if ((workTicket.getIsSafety() == null && workTicket.getIsHazard() == null && workTicket.getIsLimited() == null && workTicket.getIsRailway() == null) || (workTicket.getIsSafety() == null || workTicket.getIsHazard() == null || workTicket.getIsLimited() == null || workTicket.getIsRailway() == null)) { - extractedWithWord(response, workTicketInfoMap); + extractedWithWord(response, resultMap, status); return; } //如果4个多为false 或为空 附件不展示附件 if (!workTicket.getIsSafety() && !workTicket.getIsHazard() && !workTicket.getIsLimited() && !workTicket.getIsRailway()) { - extractedWithWord(response, workTicketInfoMap); + extractedWithWord(response, resultMap, status); return; } - List docFileList = new ArrayList<>(); + List docFileList = new ArrayList<>(); // /template/secondary/工作票安全措施附页.docx - String os = System.getProperty("os.name"); - + String os = TicketConstant.OS_NAME; String prefix = null; //Windows操作系统 if (os != null && os.toLowerCase().startsWith("windows")) { - prefix = "hzims-service/ticket/src/main/resources/template"; + prefix = TicketConstant.TICKET_WINDOW_PATH; } else { - prefix = "/data/hzims/ticket/word/template/ticket"; + prefix = TicketConstant.TICKET_LIUNX_PATH; } + //获取工作票种类 + String workTicketStatus = WordMapUtils.getWorkTicketStatus(status); - docFileList.add(new File(prefix + "/电气第一种工作票模版.docx")); + docFileList.add(new File(prefix + "/" + workTicketStatus)); //安全隔离措施附页 (true,展示附件,false,不展示附件) if (workTicket.getIsSafety()) { - addFile(prefix, "/secondary/工作票安全措施附页.docx", docFileList); + addFile(prefix, TicketConstant.SECURE_PAGE, docFileList); // setWorkTicketPrincipalChange(docFileList); } //危险点分析与预控措施票 (true,展示附件,false,不展示附件) if (workTicket.getIsSafety()) { - addFile(prefix, "/secondary/工作票危险点分析及控制措施票.docx", docFileList); + addFile(prefix, TicketConstant.SAFETY_PAGE, docFileList); // setWorkTicketHazardPointChange(docFileList); } //动火工作票 (true,展示附件,false,不展示附件) if (workTicket.getIsRailway()) { - addFile(prefix, "/secondary/动火工作票.docx", docFileList); + addFile(prefix, TicketConstant.FLIGHT_PAGE, docFileList); // setWorkTicketRailwayChange(docFileList); } //有限空间监测记录单(true,展示附件,false,不展示附件) if (workTicket.getIsLimited()) { - addFile(prefix, "/secondary/有限空间监测记录单.docx", docFileList); + addFile(prefix, TicketConstant.SPACE_PAGE, docFileList); // setWorkTicketLimitedChange(docFileList); } String name = LocalDate.now() + "-" + UUID.randomUUID().toString().replaceAll("-", ""); String docPath = null; if (os != null && os.toLowerCase().startsWith("windows")) { - docPath = "D:\\导出excel\\"; + docPath = TicketConstant.TICKET_WINDOW_MERGE_PATH; } else { - docPath = "/data/hzims/ticket/word/template/ticket/ouput/"; + docPath = TicketConstant.TICKET_LIUNX_MERGE_PATH; } docPath = docPath + name + ".docx"; @@ -742,7 +751,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { //导入文档 File file = new File(docPath); MergeDocUtils.mergeDoc(docFileList, file); - XWPFDocument xwpfDocument = WordExportUtil.exportWord07(docPath, workTicketInfoMap); + XWPFDocument xwpfDocument = WordExportUtil.exportWord07(docPath, resultMap); xwpfDocument.write(response.getOutputStream()); //删除路径 file.delete(); @@ -754,18 +763,23 @@ public class TicketProcessServiceImpl implements TicketProcessService { * * @param response * @param workTicketInfoMap + * @param status * @throws Exception */ - private static void extractedWithWord(HttpServletResponse response, Map workTicketInfoMap) throws Exception { - XWPFDocument doc = WordExportUtil.exportWord07("template/电气第一种工作票模版.docx", workTicketInfoMap); - String os = System.getProperty("os.name"); + private static void extractedWithWord(HttpServletResponse response, Map workTicketInfoMap, Integer status) throws Exception { + String workTicketStatus = WordMapUtils.getWorkTicketStatus(status); + String os = TicketConstant.OS_NAME; //Windows操作系统 if (os != null && os.toLowerCase().startsWith("windows")) { + String url = "template/" + workTicketStatus; + XWPFDocument doc = WordExportUtil.exportWord07(url, workTicketInfoMap); log.info("当前系统版本是:{}", os); - String name = "D:/导出excel/电气第一种工作票模版.docx"; - FileOutputStream fos = new FileOutputStream(name); - doc.write(fos); + //String name = "D:/导出excel/电气第一种工作票模版.docx"; + //FileOutputStream fos = new FileOutputStream(name); + doc.write(response.getOutputStream()); } else { + String url = TicketConstant.TICKET_LIUNX_PATH + "/" + workTicketStatus; + XWPFDocument doc = WordExportUtil.exportWord07(url, workTicketInfoMap); //其它操作系统 log.info("当前系统版本是:{}", os); ServletOutputStream outputStream = response.getOutputStream(); @@ -793,38 +807,35 @@ public class TicketProcessServiceImpl implements TicketProcessService { log.info("安全措施: {}", safetyMeasuresList); if (CollectionUtils.isNotEmpty(safetyMeasuresList)) { Map workTicketInfoMap1 = new HashMap<>(); - Map> measureMap = safetyMeasuresList.stream(). - collect(Collectors.groupingBy(WorkTicketSafetyMeasureEntity::getType)); - Arrays.stream(WorkTicketConstants.WorkTicketMeasureTypeEnum.class.getEnumConstants()) - .forEach(measureEnum -> { - if (CollectionUtil.isNotEmpty(measureMap.get(measureEnum.getType()))) { - List> mapList = new ArrayList<>(); - int tempIndex = 1, index = 1; - List workTicketSafetyMeasureEntities = measureMap - .get(measureEnum.getType()); - for (WorkTicketSafetyMeasureEntity measureVO : workTicketSafetyMeasureEntities) { - String type = measureEnum.getType(); - if (tempIndex != Integer.valueOf(type)) { - index = 1; - tempIndex++; - } - log.info("获取安全措施的信息: {}", measureVO); - Map map = PdfUtils.objectToMap(measureVO, true); - map.put("index", index); - map.put("safetyMeasure", ObjectUtil.isNotEmpty(map.get("measure")) ? map.get("measure") : null); - String status = TicketConstants.SafetyMeasureStatusEnum.FINISH.getStatus() - .equals(measureVO.getStatus()) ? "√" : ""; - map.put("status", status); - mapList.add(map); - index++; - } - workTicketInfoMap1.put(measureEnum.getConvertAttributes(), mapList); - } else { - workTicketInfoMap1.put(measureEnum.getConvertAttributes(), - new ArrayList()); + Map> measureMap = safetyMeasuresList.stream().collect(Collectors.groupingBy(WorkTicketSafetyMeasureEntity::getType)); + Arrays.stream(WorkTicketConstants.WorkTicketMeasureTypeEnum.class.getEnumConstants()).forEach(measureEnum -> { + if (CollectionUtil.isNotEmpty(measureMap.get(measureEnum.getType()))) { + List> mapList = new ArrayList<>(); + int tempIndex = 1, index = 1; + List workTicketSafetyMeasureEntities = measureMap.get(measureEnum.getType()); + for (WorkTicketSafetyMeasureEntity measureVO : workTicketSafetyMeasureEntities) { + String type = measureEnum.getType(); + if (tempIndex != Integer.valueOf(type)) { + index = 1; + tempIndex++; } - }); + log.info("获取安全措施的信息: {}", measureVO); + Map map = PdfUtils.objectToMap(measureVO, true); + map.put("index", index); + map.put("safetyMeasure", ObjectUtil.isNotEmpty(map.get("measure")) ? map.get("measure") : null); + String status = TicketConstants.SafetyMeasureStatusEnum.FINISH.getStatus().equals(measureVO.getStatus()) ? "√" : ""; + map.put("status", status); + mapList.add(map); + index++; + } + workTicketInfoMap1.put(measureEnum.getConvertAttributes(), mapList); + } else { + workTicketInfoMap1.put(measureEnum.getConvertAttributes(), new ArrayList()); + } + }); + //验证工作措施是有有数据 + this.isMatterLibraryList(workTicketInfoMap1); // 工作地点保留带电部位或注意事项 this.matterLibraryListWithMap(workTicketInfoMap1); result.putAll(workTicketInfoMap1); @@ -876,31 +887,118 @@ public class TicketProcessServiceImpl implements TicketProcessService { return newItem; }).collect(Collectors.toList()); - map.put("ticketInfoDangers", CollectionUtils.isNotEmpty(collect) ? collect - : new ArrayList>()); + map.put("ticketInfoDangers", CollectionUtils.isNotEmpty(collect) ? collect : new ArrayList>()); result.putAll(map); } + //工作票危险点分析及控制措施票 + WordMapUtils.newMapWithList("ticketInfoDangers", result, true, 4, "maintenance", "dangerousPoint"); //7. 是否包含 - isExists(result); - + this.isExists(result); + //8. 存入新的数据 + this.addMapPut(result); return result; } /** + * 验证是否有数据 + * + * @param workTicketInfoMap + */ + private void isMatterLibraryList(Map workTicketInfoMap) { + //1. 第一种工作票 + //1.1 应断开断路器和隔离开关,包括填写前已断开断路器和隔离开关(注明编号)、应取熔断器(保险) + WordMapUtils.newMapWithList(WorkTicketConstants.WorkTicketMeasureTypeEnum.ONE.getConvertAttributes(), workTicketInfoMap, true, 6, "safetyMeasure", "status"); + //1.2 应装设接地线、隔板、隔罩(注明确切地点),应合上接地刀闸(注明双重名称) + WordMapUtils.newMapWithList(WorkTicketConstants.WorkTicketMeasureTypeEnum.TWO.getConvertAttributes(), workTicketInfoMap, true, 3, "safetyMeasure", "status"); + //1.3 应装设遮拦、应挂标识牌及防止二次回路误碰等措施(注明确实地点、名称) + WordMapUtils.newMapWithList(WorkTicketConstants.WorkTicketMeasureTypeEnum.THREE.getConvertAttributes(), workTicketInfoMap, true, 6, "safetyMeasure", "status"); + + //2. 第二种工作票 + //2.1 应断开断路器和隔离开关,包括填写前已断开断路器和隔离开关(注明编号)、应取熔断器(保险) + WordMapUtils.newMapWithList(WorkTicketConstants.WorkTicketMeasureTypeEnum.SEVEN.getConvertAttributes(), workTicketInfoMap, true, 6, "safetyMeasure", "status"); + + + //3. 水利机器工作票 + //3.1 必须采取的安全措施 + WordMapUtils.newMapWithList(WorkTicketConstants.WorkTicketMeasureTypeEnum.EIGHT.getConvertAttributes(), workTicketInfoMap, true, 8, "safetyMeasure", "status"); + //3.2 检修工作要求检修人员自行执行的安全措施(由工作负责人填写) + WordMapUtils.newMapWithList(WorkTicketConstants.WorkTicketMeasureTypeEnum.NINE.getConvertAttributes(), workTicketInfoMap, true, 5, "safetyMeasure", "status"); + //3.3 检修工作要求检修人员自行执行的安全措施(由工作负责人填写) + WordMapUtils.newMapWithList(WorkTicketConstants.WorkTicketMeasureTypeEnum.TEN.getConvertAttributes(), workTicketInfoMap, true, 5, "safetyMeasure", "status"); + + + } + + + /** + * 存入新的数据 + * + * @param result + */ + private void addMapPut(Map result) { + log.info("存入新的数据"); + //许可人确认安全措施,负责人确认安全措施 + if (WordHelper.isNoneBlank(result, "licenseTime")) { + log.info("许可人确认安全措施,负责人确认安全措施"); + String principalName = WordHelper.toMapAsString(result, "principalName", 10); + result.put("principalName1", principalName); + } else { + WordHelper.putMap(result, "principalName1", 10); + } + + //负责人变更 + if (WordHelper.isNoneBlank(result, "initialPrincipalName")) { + log.info("负责人变更"); + //签发人 + String signerName = WordHelper.toMapAsString(result, "signerName", 10); + result.put("signerName2", signerName); + //许可人 + String licensorName = WordHelper.toMapAsString(result, "licensorName", 10); + result.put("licensorName1", licensorName); + } else { + WordHelper.putMap(result, "signerName2", 10); + WordHelper.putMap(result, "licensorName1", 10); + } + + //延期 + if (WordHelper.isNoneBlank(result, "changeTime")) { + log.info("延期"); + //负责人 + String licensorName = WordHelper.toMapAsString(result, "principalName", 10); + result.put("principalName2", licensorName); + }else { + WordHelper.putMap(result, "principalName2", 10); + } + + //许可人确认工作票终结 + + if (WordHelper.isNoneBlank(result, "workEndTime")) { + log.info("许可人确认工作票终结"); + //负责人 + String principalName = WordHelper.toMapAsString(result, "principalName", 10); + result.put("principalName3", principalName); + //许可人 + String licensorName = WordHelper.toMapAsString(result, "licensorName", 10); + result.put("licensorName2", licensorName); + }else { + WordHelper.putMap(result, "principalName3", 10); + WordHelper.putMap(result, "licensorName2", 10); + } + } + + + /** * 工作地点保留带电部位或注意事项 - * 2 个map集合转成一个map集合 + * 2 个map集合转成一个map集合 + * * @param workTicketInfoMap */ private static void matterLibraryListWithMap(Map workTicketInfoMap) { - List> matterLibraryListFive1 = - workTicketInfoMap.get("matterLibraryListFive") == null ? new ArrayList>() - : (List>) workTicketInfoMap.get("matterLibraryListFive"); - List> matterLibraryListFlow1 = workTicketInfoMap.get("matterLibraryListFlow") == null - ? new ArrayList>() - : (List>) workTicketInfoMap.get("matterLibraryListFlow"); + List> matterLibraryListFive1 = workTicketInfoMap.get("matterLibraryListFive") == null ? new ArrayList>() : (List>) workTicketInfoMap.get("matterLibraryListFive"); + List> matterLibraryListFlow1 = workTicketInfoMap.get("matterLibraryListFlow") == null ? new ArrayList>() : (List>) workTicketInfoMap.get("matterLibraryListFlow"); if (matterLibraryListFive1 != null && matterLibraryListFlow1 != null) { List> matterLibraryListFive = matterLibraryListFive1; @@ -930,23 +1028,27 @@ public class TicketProcessServiceImpl implements TicketProcessService { } workTicketInfoMap.put("matterLibraryList", CollectionUtils.isEmpty(maps) ? new ArrayList<>() : maps); - } + + + WordMapUtils.newMapWithList("matterLibraryList", workTicketInfoMap, true, 3, null); + } /** * 判断是否包含,是否存在 + * * @param result */ private static void isExists(Map result) { if (!result.containsKey("ticketInfoDangers")) { - result.put("ticketInfoDangers",new ArrayList>()); + result.put("ticketInfoDangers", new ArrayList>()); } //项目名称 - if (!result.containsKey("projectName")) { - result.put("projectName","\u00A0 "); + if (!result.containsKey("projectName") || StringUtils.isBlank((CharSequence) result.get("projectName"))) { + result.put("projectName", "\u00A0 "); } } @@ -1004,7 +1106,6 @@ public class TicketProcessServiceImpl implements TicketProcessService { } - /** * 添加文件 * @@ -1018,7 +1119,6 @@ public class TicketProcessServiceImpl implements TicketProcessService { } - /** * value true转 ☑ 或 false转 □ * @@ -1033,6 +1133,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { } } + } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java new file mode 100644 index 0000000..8240377 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java @@ -0,0 +1,229 @@ +package com.hnac.hzims.ticket.twoTicket.utils; + + +import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; +import lombok.AllArgsConstructor; +import lombok.Data; +import org.apache.commons.lang3.StringUtils; + +import java.util.*; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/2 14:27 + */ +public class WordHelper extends StringUtils { + + + /** + * Object转 toString + * + * @param object + * @return + */ + public static String toString(Object object) { + return object == null ? null : object.toString().trim(); + } + + + /** + * Map ===》 string + * + * @param result map + * @param key 值 + * @param count 存在多少空格 + * @return + */ + public static String toMapAsString(Map result, String key, int count) { + String signerName = WordHelper.toString(result.get(key)); + return isNotBlank(signerName) ? signerName : "\u00A0" + printSpace(count); + } + + + /** + * 存入map + * + * @param result map + * @param key 值 + * @param count 存在多少空格 + * @return + */ + public static void putMap(Map result, String key, int count) { + result.put(key, "\u00A0" + printSpace(count)); + } + + + /** + * 判断map是否为空 + */ + public static boolean isBlank(Map result, String key) { + String value = WordHelper.toString(result.get(key)); + if (StringUtils.isBlank(value)) { + return true; + } + return false; + } + + + /** + * 判断map不为为空 + */ + public static boolean isNoneBlank(Map result, String key) { + String value = WordHelper.toString(result.get(key)).trim(); + System.out.println(value.length()); + if (StringUtils.isNoneBlank(value)) { + return true; + } + return false; + } + + + /** + * 打印多少空格 + */ + public static String printSpace(int count) { + StringBuilder sb = new StringBuilder(); + for (int i = 0; i < count; i++) { + sb.append(" "); + } + return sb.toString(); + } + + /** + * map验证是value否为null + * + * @param params + */ + public static Map resultMap(Map params) { + //创建新的Map + Map result = new HashMap<>(); + isContainsKey(params,result); + //遍历 + Set> entries = params.entrySet(); + for (Map.Entry entry : entries) { + listEntryMap(result, entry.getKey(), entry.getValue()); + } + return result; + } + + + /** + * 包含移除 + * @param params + * @param result + */ + private static void isContainsKey(Map params, Map result) { + + if (params.containsKey("principalName1")) { + result.put("principalName1", params.get("principalName1")); + params.remove("principalName1"); + } + + if (params.containsKey("signerName2")) { + result.put("signerName2", params.get("signerName2")); + params.remove("signerName2"); + } + + if (params.containsKey("licensorName1")) { + result.put("licensorName1", params.get("licensorName1")); + params.remove("licensorName1"); + } + + + if (params.containsKey("principalName2")) { + result.put("principalName2", params.get("principalName2")); + params.remove("principalName2"); + } + + + if (params.containsKey("principalName3")) { + result.put("principalName3", params.get("principalName3")); + params.remove("principalName3"); + } + + + if (params.containsKey("licensorName2")) { + result.put("licensorName2", params.get("licensorName2")); + params.remove("licensorName2"); + } + + } + + /** + * + */ + public static void listEntryMap(Map result, String key, Object value) { + List params = new ArrayList<>(); + paramsList(params); + for (Entry entry : params) { + isEntryMap(result, entry.getFileName(), key, value, entry.getCount()); + } + + } + + + @Data + @AllArgsConstructor + static class Entry { + /** + * key值 + */ + private String fileName; + + /** + * count + */ + private Integer count; + + } + + + /** + * 存储list + * + * @param params + */ + private static void paramsList(List params) { + params.add(new Entry("initialPrincipalName", 10)); + params.add(new Entry("principalChangeTime", 10)); + params.add(new Entry("principalName", 10)); + params.add(new Entry("jobReceiver", 10)); + params.add(new Entry("jobReceiverTime", 10)); + params.add(new Entry("watchPrincipalEndTime", 10)); + params.add(new Entry("licenseTime", 10)); + params.add(new Entry("signerDateTime", 10)); + params.add(new Entry("classGroupName", 10)); + params.add(new Entry("code", 10)); + params.add(new Entry("signerName", 10)); + params.add(new Entry("watchPrincipalName", 10)); + params.add(new Entry("projectName", 10)); + params.add(new Entry("groundNum", 5)); + params.add(new Entry("dismantleNum", 5)); + params.add(new Entry("retainNum", 5)); + } + + + /** + * 验证map是否为空 + * + * @param result + * @param fieldName + * @param key + * @param value + * @param count + */ + public static void isEntryMap(Map result, String fieldName, String key, Object value, int count) { + if (fieldName.equals(key)) { + // Object newValue = Optional.ofNullable(value).orElse("\u00A0" + printSpace(count)); + Object newValue = StringUtils.isNoneBlank(toString(value).trim()) ? value : "\u00A0" + printSpace(count); + result.put(key, newValue); + } else { + Object newValue = StringUtils.isNoneBlank(toString(value).trim()) ? value : "\u00A0"; + result.put(key, newValue); + } + } + + +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordMapUtils.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordMapUtils.java new file mode 100644 index 0000000..cdb46e2 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordMapUtils.java @@ -0,0 +1,120 @@ +package com.hnac.hzims.ticket.twoTicket.utils; + +import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/2 7:39 + */ +public class WordMapUtils { + + + + /** + * word 表格转换 + * + * @param key key值 + * @param result 存入数据 + * @param isIndex 是否需要索引 + * @param size word最多的表格数据 + * @param keys 多个key值 + */ + public static void newMapWithList(String key, Map result + , boolean isIndex, int size, String... keys) { + List> list = (List>) result.get(key); + if (CollectionUtils.isEmpty(list)) { + List> newMatterLibraryListTHREE = new ArrayList<>(); + for (int i = 1; i <= size; i++) { + Map map = new HashMap<>(); + //是否需要索引 + if (isIndex) { + map.put("index", i); + } + // 是否有keys + if (keys != null) { + for (String value : keys) { + map.put(value, ""); + } + } + newMatterLibraryListTHREE.add(map); + } + result.put(key, + newMatterLibraryListTHREE); + } else { + + int tempSize = list.size(); + + List> newList = new ArrayList<>(); + if (size > tempSize) { + int sizeLimit = 1; + int tempIndex = 1; + for (int i = 0; i < size; i++) { + Map map = new HashMap<>(); + if (tempSize >= sizeLimit) { + Map stringObjectMap = list.get(i); + // map.putAll(stringObjectMap); + newList.add(stringObjectMap); + tempIndex++; + sizeLimit++; + }else { + //是否需要索引 + if (isIndex) { + map.put("index", tempIndex); + + } + // 是否有keys + if (keys != null) { + for (String value : keys) { + map.put(value, ""); + } + } + tempIndex++; + newList.add(map); + } + } + } else { + for (int i = 0; i < tempSize; i++) { + Map map = list.get(i); + if (isIndex) { + map.put("index", i + 1); + } + newList.add(map); + } + } + result.put(key, newList); + } + } + + + + + /** + * 通过状态获取是第几种工作票 + */ + public static String getWorkTicketStatus(Integer status) { + String pathName = null; + switch (status) { + case 1: + pathName = "电气第一种工作票模版.docx"; + break; + case 2: + pathName = "电气第二种工作票模版.docx"; + break; + case 3: + pathName = "水力机械工作票模版.docx"; + break; + default: + pathName = "电气第一种工作票模版.docx"; + break; + } + return pathName; + } + +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/process/WorkTicketVo.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/process/WorkTicketVo.java index 58da938..2dfa1e7 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/process/WorkTicketVo.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/process/WorkTicketVo.java @@ -69,11 +69,6 @@ public class WorkTicketVo { private WorkTicketPrincipalChangeEntity workTicketPrincipalChange; - /** - * 开启流程 - */ - private Boolean isState = true; - diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/utils/PdfUtils.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/utils/PdfUtils.java index 3e7b2d9..45251de 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/utils/PdfUtils.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/utils/PdfUtils.java @@ -257,33 +257,34 @@ public class PdfUtils { result.put(StringUtil.isNoneBlank(defaultValue.name()) ? defaultValue.name() : field.getName(), ObjectUtil.isNotEmpty(defaultValue.value()) ? defaultValue.value() : value); } else { - if ("initialPrincipalName".equals(field.getName()) - || "principalChangeTime".equals(field.getName()) - || "principalName".equals(field.getName()) - || "jobReceiver".equals(field.getName()) - || "jobReceiverTime".equals(field.getName()) - || "watchPrincipalEndTime".equals(field.getName()) - || "licenseTime".equals(field.getName()) - || "licensorName".equals(field.getName()) - || "signerDateTime".equals(field.getName()) - || "classGroupName".equals(field.getName()) - || "code".equals(field.getName()) - || "signerName".equals(field.getName()) - || "watchPrincipalName".equals(field.getName())) - { - result.put(field.getName(), Optional.ofNullable(value).orElse("\u00A0 ")); - - } else if ( - "groundNum".equals(field.getName()) || - "dismantleNum".equals(field.getName()) || - "retainNum".equals(field.getName()) - - ) { - result.put(field.getName(), Optional.ofNullable(value).orElse("\u00A0 ")); - } else { + // if ("initialPrincipalName".equals(field.getName()) + // || "principalChangeTime".equals(field.getName()) + // || "principalName".equals(field.getName()) + // || "jobReceiver".equals(field.getName()) + // || "jobReceiverTime".equals(field.getName()) + // || "watchPrincipalEndTime".equals(field.getName()) + // || "licenseTime".equals(field.getName()) + // || "licensorName".equals(field.getName()) + // || "signerDateTime".equals(field.getName()) + // || "classGroupName".equals(field.getName()) + // || "code".equals(field.getName()) + // || "signerName".equals(field.getName()) + // || "watchPrincipalName".equals(field.getName()) + // || "projectName".equals(field.getName())) + // { + // result.put(field.getName(), Optional.ofNullable(value).orElse("\u00A0 ")); + // + // } else if ( + // "groundNum".equals(field.getName()) || + // "dismantleNum".equals(field.getName()) || + // "retainNum".equals(field.getName()) + // + // ) { + // result.put(field.getName(), Optional.ofNullable(value).orElse("\u00A0 ")); + // } else { //如果导出word为null会出现{{ ,value设置"\u00A0" - result.put(field.getName(), Optional.ofNullable(value).orElse("\u00A0")); - } + result.put(field.getName(), Optional.ofNullable(value).orElse("")); + //} } diff --git a/hzims-service/ticket/src/main/resources/template/secondary/工作票危险点分析及控制措施票.docx b/hzims-service/ticket/src/main/resources/template/secondary/工作票危险点分析及控制措施票.docx index 46cec0fcbc9904a61475e19417977f87bdaacbe7..591306f4dd39a664c81e9ae1a1e23d5978d32aad 100644 GIT binary patch delta 15363 zcmZv@18^W+((#O8n!o<0%UxdhbS^*N!5y!H3gxW=aeIF1kNX-PrOSsW_AB zW}je)h`_VzOex*qBN?b)8v^{a7M0HO4X?2U=y6D>yd#I)HD6`-s zzrTgpkq^4cN#po8S`iQ2i^9y6`J-*(7g9!}d*%}iSVd>#p^MUHA&_Clw-pwyScs7hD=|w zC|>7^c9)+xB}d6>>LPhBjc6hdC0exlqsN67m!B&!S0qB4&SLhOSrsOvv`f&nl)TEr zD}o)1 zR=RW)if&0|9Zew|?N=h^*C6^Ersu=&cnk8a!CZ-#;1p({{D{XOH=5@<@+u9~W6fe{ zOq&P{%A6x!SxhcEPc>)rhFR_IL+FIM25L7uBU%~5JS>4eDbdAiElv8M+({g7R3$)m zyn-GGC9bv(nEEq0vUuSAJt;`c$ejCgIqyq8MQ$(lEJ3#u_zMzz>?17-{@F}Zv4h)WR9IqL;4J7zz zT@BbMgb5p#YESo*30w@TH$3CtW=$a)sJRp%bFfrv?V;kh;FjmgFDa4&DB$1riYA^dE{+br`Qv&>hPx9Qrl@xJk zv&qSWBBcf?x62@By0w}J`{5#2co;XVxGsjx&ZIs^^W6vvVL)_2+9wSfDrfUjWVQp? z*+q1FI(*|346)3Ok3rUbsp@dVuJS-$SerlH7*laG9M^doeKA9BXfGO!<4_8(EdZ`* zq9{PezvY4}8kl9ydH5;yJSN4Fo8@9~6@Vf0R2LX0A~7426!fx79x|Eddtbd&Z&?!A z4J80z6bb5-7Gf(|NDw$C@3`dCJr6)iXddZ3@eA2$9$OOAVKkMQEf6PEWJZ+;)F_G= zyx~(1n!ouzp(lN68}NGvER z6kCvqtV)O22-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ry6l?3di?W2zvmjY2H1)L(mE6RUFupk9dE(TG~pN$N@NCxUg z5(6FWb_*0bUqx&;xvzmR1(E}SV;C3=eD>zvG317VKj1SWJvCvl!$!h8%O5~e6qumd zaY7KR9R$U9mmC6N7>se4kN=+nL{KGY^%zh~Mvt$wtCkFuhgRzVd5!^}7p&a@#i8{P zK)f2q#|6C2p)}MH9i%^+?79pB8UkMjXhi|_83%>lALR={UB^Ga7f=G~W&uicJAWzh z+1mp8d7#S{K@F{7z6Nv=BUA#qt_GCo4CPA*uCjsR(1}10cZ=oYyQT%9Jaozg z`|^KIpg>{hKpKP@X?z$mtcEH;hl-%WaynnZ7x+>CIdFvXyK{MvhQac(V6ZPTdnmp; r&l1Fqas+UG)&-?^_j!W!3|)W*dq77!gvj>Okie}M=tdp#x6l3qg1XsD literal 0 HcmV?d00001 diff --git a/hzims-service/ticket/src/main/resources/template/电气第一种工作票模版.docx b/hzims-service/ticket/src/main/resources/template/电气第一种工作票模版.docx index 76478f2e4d9021ea4b61370fdbb0bdce5660ed43..f2760d0ff4c335bd1cbe226286a379ecaa2612e6 100644 GIT binary patch delta 17241 zcmV)fK&8K@&;psz0;2~mfyE({{u_4A9kxYCVtz>$Q?zF>A)rr7fee^t)sK{7=uH%azRHdex}e83>}*$epVfk1nm* zc0HHPHi~OTRc{=rmW!6zFjws(MYEbUS69nLBYV!YN?C@YDg3Q&nMI?~fc+_YZ9{J? zx!{VM@t~C~{TytJ0J7QQnr_*~W*Y`QFc2<(D`mxQK+F(;AchRx4GIhliqE1^bpc|B z0t83Z1&JFDQV4SVaFCd8NWyTCKsO|DI7nUWRPAPPvu@Pj!&TF&>Nfmooyk^p>+E{{ zIS9C}+vSyVrEG6Om=y1U(aW{7LyQQvYC))i(!daeY}G6o6;Se^m`9h^ty<1)|6Hqo zJsNtBw0A#REsRRMZee#)*4VTw4clvL#i1Q(uDXf^Q!Q&56-Y<3)>tdoTiT&IEHwCV z%>%L#MSzWJ#jAI&PRA6rUaCzc)6fP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-2U7PHT|4^32ts>FHB38vngm@l zdVd+Ac~&b_Gg|K%-30VbAHoFjcBlzyz)T760;20jZIvT*GcauHWMIH(qoZp_Z7CsZ rPwYX`4sAD~>qf1!kadgpBk4xeU;*B&z|0Qn-U>1F1FONxi69;TkV=m( literal 0 HcmV?d00001 From 1cff3d96692e0b54c33f8c4a8309800f072f3c26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=AE=B5=E9=A3=9E=E5=AE=87?= <2684146481@qq.com> Date: Mon, 5 Jun 2023 08:24:17 +0800 Subject: [PATCH 02/14] =?UTF-8?q?=E5=88=A0=E9=99=A4=E6=B3=A8=E9=87=8A?= =?UTF-8?q?=E7=9A=84=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/TicketProcessServiceImpl.java | 10 +++---- .../hzims/ticket/twoTicket/utils/WordHelper.java | 1 - .../java/com/hnac/hzims/ticket/utils/PdfUtils.java | 32 ++-------------------- 3 files changed, 6 insertions(+), 37 deletions(-) diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java index da04670..73bd986 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java @@ -535,10 +535,10 @@ public class TicketProcessServiceImpl implements TicketProcessService { log.info("获取启动流程数据 : {}", processInstanceContainNameByKey); Duration between = Duration.between(start, Instant.now()); - System.out.println("================================================================"); - System.err.println("耗时: " + (between.getSeconds()) + "秒"); - System.err.println("耗时: " + (between.toMillis()) + "毫秒"); - System.out.println("================================================================"); + log.info("================================================================"); + log.info("耗时: " + (between.getSeconds()) + "秒"); + log.info("耗时: " + (between.toMillis()) + "毫秒"); + log.info("================================================================"); } @@ -774,8 +774,6 @@ public class TicketProcessServiceImpl implements TicketProcessService { String url = "template/" + workTicketStatus; XWPFDocument doc = WordExportUtil.exportWord07(url, workTicketInfoMap); log.info("当前系统版本是:{}", os); - //String name = "D:/导出excel/电气第一种工作票模版.docx"; - //FileOutputStream fos = new FileOutputStream(name); doc.write(response.getOutputStream()); } else { String url = TicketConstant.TICKET_LIUNX_PATH + "/" + workTicketStatus; diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java index 8240377..8147ea9 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java @@ -216,7 +216,6 @@ public class WordHelper extends StringUtils { */ public static void isEntryMap(Map result, String fieldName, String key, Object value, int count) { if (fieldName.equals(key)) { - // Object newValue = Optional.ofNullable(value).orElse("\u00A0" + printSpace(count)); Object newValue = StringUtils.isNoneBlank(toString(value).trim()) ? value : "\u00A0" + printSpace(count); result.put(key, newValue); } else { diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/utils/PdfUtils.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/utils/PdfUtils.java index 45251de..d9f32cc 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/utils/PdfUtils.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/utils/PdfUtils.java @@ -257,36 +257,8 @@ public class PdfUtils { result.put(StringUtil.isNoneBlank(defaultValue.name()) ? defaultValue.name() : field.getName(), ObjectUtil.isNotEmpty(defaultValue.value()) ? defaultValue.value() : value); } else { - // if ("initialPrincipalName".equals(field.getName()) - // || "principalChangeTime".equals(field.getName()) - // || "principalName".equals(field.getName()) - // || "jobReceiver".equals(field.getName()) - // || "jobReceiverTime".equals(field.getName()) - // || "watchPrincipalEndTime".equals(field.getName()) - // || "licenseTime".equals(field.getName()) - // || "licensorName".equals(field.getName()) - // || "signerDateTime".equals(field.getName()) - // || "classGroupName".equals(field.getName()) - // || "code".equals(field.getName()) - // || "signerName".equals(field.getName()) - // || "watchPrincipalName".equals(field.getName()) - // || "projectName".equals(field.getName())) - // { - // result.put(field.getName(), Optional.ofNullable(value).orElse("\u00A0 ")); - // - // } else if ( - // "groundNum".equals(field.getName()) || - // "dismantleNum".equals(field.getName()) || - // "retainNum".equals(field.getName()) - // - // ) { - // result.put(field.getName(), Optional.ofNullable(value).orElse("\u00A0 ")); - // } else { - //如果导出word为null会出现{{ ,value设置"\u00A0" - result.put(field.getName(), Optional.ofNullable(value).orElse("")); - //} - - + //如果导出word为null会出现{{ ,value设置"\u00A0" + result.put(field.getName(), Optional.ofNullable(value).orElse("")); } }); } From 1cc419302feee61996ef6312c64ad999becfcc8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=AE=B5=E9=A3=9E=E5=AE=87?= <2684146481@qq.com> Date: Mon, 5 Jun 2023 10:35:04 +0800 Subject: [PATCH 03/14] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=B7=A5=E4=BD=9C?= =?UTF-8?q?=E7=A5=A8process=5Fdict=E5=AD=97=E5=85=B8=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../constant/TicketProcessConstant.java | 5 +- .../controller/ProcessDictController.java | 44 ++++++++ .../ticket/processflow/entity/ProcessDict.java | 113 +++++++++++++++++++++ .../processflow/mapper/ProcessDictMapper.java | 14 +++ .../processflow/mapper/xml/ProcessTypeMapper.xml | 5 - .../processflow/service/ProcessDictService.java | 22 ++++ .../service/impl/ProcessDictServiceImpl.java | 33 ++++++ .../serviceimpl/OneTicketProcessServiceImpl.java | 15 ++- .../service/impl/TicketProcessServiceImpl.java | 16 ++- .../service/impl/WorkTicketInfoServiceImpl.java | 2 +- .../ticket/src/main/resources/application.yml | 1 + .../mapper/processflow/ProcessDictMapper.xml | 5 + .../mapper/processflow/ProcessTypeMapper.xml | 5 + 13 files changed, 267 insertions(+), 13 deletions(-) create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/controller/ProcessDictController.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/entity/ProcessDict.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/mapper/ProcessDictMapper.java delete mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/mapper/xml/ProcessTypeMapper.xml create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/service/ProcessDictService.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/service/impl/ProcessDictServiceImpl.java create mode 100644 hzims-service/ticket/src/main/resources/mapper/processflow/ProcessDictMapper.xml create mode 100644 hzims-service/ticket/src/main/resources/mapper/processflow/ProcessTypeMapper.xml diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/constant/TicketProcessConstant.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/constant/TicketProcessConstant.java index 46a48bc..7bef5ea 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/constant/TicketProcessConstant.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/constant/TicketProcessConstant.java @@ -10,5 +10,8 @@ package com.hnac.hzims.ticket.processflow.constant; */ public class TicketProcessConstant { - public final static String STARTEVENT = "workTicketFlow"; + /** + * 第一种工作票的key + */ + public static final String FIRST_TICKET_KEY = "networking"; } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/controller/ProcessDictController.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/controller/ProcessDictController.java new file mode 100644 index 0000000..f6b6fdf --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/controller/ProcessDictController.java @@ -0,0 +1,44 @@ +package com.hnac.hzims.ticket.processflow.controller; + +import com.hnac.hzims.ticket.processflow.entity.ProcessDict; +import com.hnac.hzims.ticket.processflow.service.ProcessDictService; +import groovy.util.logging.Slf4j; +import lombok.RequiredArgsConstructor; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/5 9:35 + */ + +@Slf4j +@RequestMapping("/process-dict") +@RestController +@RequiredArgsConstructor +public class ProcessDictController { + + + private final ProcessDictService processDictService; + + + + + @GetMapping("/test") + public void test(){ + ProcessDict processDict = new ProcessDict(); + processDict.setDictKey("networking"); + processDict.setDictSort(0); + processDict.setDictValue("workTicketFlow"); + processDict.setDictLabel("第一种工作票"); + processDict.setIsDefault("Y"); + processDict.setRemark("第一种工作票"); + processDict.setDictType("工作票"); + processDictService.save(processDict); + } + + +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/entity/ProcessDict.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/entity/ProcessDict.java new file mode 100644 index 0000000..d2240cb --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/entity/ProcessDict.java @@ -0,0 +1,113 @@ +package com.hnac.hzims.ticket.processflow.entity; + +import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableId; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.experimental.Accessors; +import org.springblade.core.mp.base.BaseEntity; +import org.springblade.core.tenant.mp.TenantEntity; + +import java.time.LocalDateTime; +import java.util.Date; + +/** + * 票据字典表 + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/5 8:33 + */ +@Data +@ApiModel(value = "ProcessDict",description = "票据字典表") +@Accessors(chain = true) +public class ProcessDict { + + + /** + * 票据编码 + */ + @TableId(value = "dictCode",type = IdType.AUTO) + @ApiModelProperty("票据编码") + private Long dictCode; + + + /** + *票据排序 + */ + @ApiModelProperty("票据排序") + private Integer dictSort; + + + /** + *票据字典码 + */ + @ApiModelProperty("票据字典码") + private String dictKey; + + + /** + *票据流程标识 + */ + @ApiModelProperty("票据流程标识") + private String dictValue; + + + + /** + *票据标签 + */ + @ApiModelProperty("票据标签") + private String dictLabel; + + /** + *票据类型 + */ + @ApiModelProperty("票据类型") + private String dictType; + + /** + *是否默认(Y是 N否) + */ + @ApiModelProperty("是否默认(Y是 N否)") + private String isDefault; + + + /** + *状态(0正常 1停用) + */ + @ApiModelProperty("状态(0正常 1停用)") + private Integer status; + + + + /** + * 所属机构 + */ + @ApiModelProperty("所属机构") + private Long createDept; + + + + /** + * 创建时间 + */ + @ApiModelProperty("创建时间") + private LocalDateTime createTime; + + + /** + * 更新时间 + */ + @ApiModelProperty("更新时间") + private LocalDateTime updateTime; + + + + /** + * 票据备注 + */ + @ApiModelProperty("票据备注") + private String remark; +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/mapper/ProcessDictMapper.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/mapper/ProcessDictMapper.java new file mode 100644 index 0000000..2bb86f5 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/mapper/ProcessDictMapper.java @@ -0,0 +1,14 @@ +package com.hnac.hzims.ticket.processflow.mapper; + +import com.hnac.hzims.ticket.processflow.entity.ProcessDict; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/5 8:49 + */ +public interface ProcessDictMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/mapper/xml/ProcessTypeMapper.xml b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/mapper/xml/ProcessTypeMapper.xml deleted file mode 100644 index 39ffa8c..0000000 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/mapper/xml/ProcessTypeMapper.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/service/ProcessDictService.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/service/ProcessDictService.java new file mode 100644 index 0000000..7113a06 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/service/ProcessDictService.java @@ -0,0 +1,22 @@ +package com.hnac.hzims.ticket.processflow.service; + +import com.baomidou.mybatisplus.extension.service.IService; +import com.hnac.hzims.ticket.processflow.entity.ProcessDict; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/5 8:52 + */ +public interface ProcessDictService extends IService { + + + /** + * 根据字典key查询字典value + */ + String selectDictValueByKey(String dictKey); + + + +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/service/impl/ProcessDictServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/service/impl/ProcessDictServiceImpl.java new file mode 100644 index 0000000..84fbfd9 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/service/impl/ProcessDictServiceImpl.java @@ -0,0 +1,33 @@ +package com.hnac.hzims.ticket.processflow.service.impl; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.extension.conditions.query.LambdaQueryChainWrapper; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.hnac.hzims.ticket.processflow.entity.ProcessDict; +import com.hnac.hzims.ticket.processflow.mapper.ProcessDictMapper; +import com.hnac.hzims.ticket.processflow.service.ProcessDictService; +import groovy.util.logging.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/5 8:59 + */ +@Slf4j +@Service +public class ProcessDictServiceImpl extends ServiceImpl implements ProcessDictService { + /** + * 根据字典key查询字典value + * + * @param dictKey + */ + @Override + public String selectDictValueByKey(String dictKey) { + LambdaQueryChainWrapper processDictLambdaQueryChainWrapper = new LambdaQueryChainWrapper<>(baseMapper); + processDictLambdaQueryChainWrapper.eq(ProcessDict::getDictKey,dictKey); + return processDictLambdaQueryChainWrapper.one().getDictValue(); + } +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OneTicketProcessServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OneTicketProcessServiceImpl.java index 82f64ce..1255079 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OneTicketProcessServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OneTicketProcessServiceImpl.java @@ -1,6 +1,7 @@ package com.hnac.hzims.ticket.processflow.strategy.serviceimpl; import com.hnac.hzims.ticket.processflow.constant.TicketProcessConstant; +import com.hnac.hzims.ticket.processflow.service.ProcessDictService; import com.hnac.hzims.ticket.response.ProcessWorkFlowResponse; import com.hnac.hzims.ticket.processflow.strategy.abstracts.ProcessAbstractService; import com.hnac.hzims.ticket.processflow.strategy.entity.WorkflowQueue; @@ -9,6 +10,8 @@ import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Service; +import static com.hnac.hzims.ticket.processflow.constant.TicketProcessConstant.FIRST_TICKET_KEY; + /** * 开工作票流程实现类 * @@ -27,6 +30,15 @@ public class OneTicketProcessServiceImpl extends ProcessAbstractService { private final TicketProcessService ticketProcessService; + + private final ProcessDictService processDictService; + + + + + + + /** * 设置执行那种实现类 * @@ -36,7 +48,8 @@ public class OneTicketProcessServiceImpl extends ProcessAbstractService { @Override public Boolean isWorkflowProcess(WorkflowQueue flowQueue) { log.info("是否执行开第一种工作票流程环节操作~~~~,流程ticket: {}", flowQueue); - if (TicketProcessConstant.STARTEVENT.equals(flowQueue.getProcessDefinitionKey())) { + String dictValue = processDictService.selectDictValueByKey(FIRST_TICKET_KEY); + if (dictValue.equals(flowQueue.getProcessDefinitionKey())) { log.info("已执行第一种开工作票流程环节操作~~~~"); return true; } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java index 73bd986..2c8d482 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java @@ -18,6 +18,7 @@ import com.hnac.hzims.operational.station.entity.StationEntity; import com.hnac.hzims.operational.station.feign.IStationClient; import com.hnac.hzims.ticket.constants.TicketConstants; import com.hnac.hzims.ticket.constants.WorkTicketConstants; +import com.hnac.hzims.ticket.processflow.service.ProcessDictService; import com.hnac.hzims.ticket.processflow.strategy.core.ProcessIdWorker; import com.hnac.hzims.ticket.response.ProcessWorkFlowResponse; import com.hnac.hzims.ticket.twoTicket.constant.TicketConstant; @@ -68,6 +69,8 @@ import java.time.LocalDateTime; import java.util.*; import java.util.stream.Collectors; +import static com.hnac.hzims.ticket.processflow.constant.TicketProcessConstant.FIRST_TICKET_KEY; + /** * 开票处理流程实现类 @@ -112,8 +115,6 @@ public class TicketProcessServiceImpl implements TicketProcessService { private final IAccessTaskClient accessTaskClient; - private String newFirstWorkTicketFlowKey = "workTicketFlow"; - private final IStationClient stationClient; @@ -141,6 +142,9 @@ public class TicketProcessServiceImpl implements TicketProcessService { private final TicketInfoDangerService ticketInfoDangerService; + private final ProcessDictService processDictService; + + /** * 启动开票流程 * @@ -188,9 +192,11 @@ public class TicketProcessServiceImpl implements TicketProcessService { this.saveSafetyMeasures(workTicketVo.getSafetyMeasuresList(), workTicketVo.getWorkTicket()); //5. 保存工作任务 this.saveWorkTicketContentDto(workTicketVo.getWorkTicketContentDtoList(), workTicketVo.getWorkTicket()); - //6. 开启动作流 - this.dealProcess(newFirstWorkTicketFlowKey, workTicketVo); - //7. 处理任务 + //6. 查询第一种工作票值 + String dictValue = processDictService.selectDictValueByKey(FIRST_TICKET_KEY); + //7. 开启动作流 + this.dealProcess(dictValue, workTicketVo); + //8. 处理任务 this.returnTicket(workTicketVo); } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/workTicket/service/impl/WorkTicketInfoServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/workTicket/service/impl/WorkTicketInfoServiceImpl.java index 1da1885..0105a3d 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/workTicket/service/impl/WorkTicketInfoServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/workTicket/service/impl/WorkTicketInfoServiceImpl.java @@ -256,7 +256,7 @@ public class WorkTicketInfoServiceImpl extends BaseServiceImpl { User user = UserCache.getUser(item.getCreateUser()); if (user != null) { - item.setCreateUserName(UserCache.getUser(item.getCreateUser()).getName()); + item.setCreateUserName(user.getName()); } }); diff --git a/hzims-service/ticket/src/main/resources/application.yml b/hzims-service/ticket/src/main/resources/application.yml index 9341ce3..1de0a34 100644 --- a/hzims-service/ticket/src/main/resources/application.yml +++ b/hzims-service/ticket/src/main/resources/application.yml @@ -16,6 +16,7 @@ swagger: + #ticket: # workTickets: # - status: 1 diff --git a/hzims-service/ticket/src/main/resources/mapper/processflow/ProcessDictMapper.xml b/hzims-service/ticket/src/main/resources/mapper/processflow/ProcessDictMapper.xml new file mode 100644 index 0000000..1882427 --- /dev/null +++ b/hzims-service/ticket/src/main/resources/mapper/processflow/ProcessDictMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/ticket/src/main/resources/mapper/processflow/ProcessTypeMapper.xml b/hzims-service/ticket/src/main/resources/mapper/processflow/ProcessTypeMapper.xml new file mode 100644 index 0000000..39ffa8c --- /dev/null +++ b/hzims-service/ticket/src/main/resources/mapper/processflow/ProcessTypeMapper.xml @@ -0,0 +1,5 @@ + + + + + From 6368d17363e42c211eaf894ca71bfad637b9fec4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=AE=B5=E9=A3=9E=E5=AE=87?= <2684146481@qq.com> Date: Mon, 5 Jun 2023 18:03:32 +0800 Subject: [PATCH 04/14] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=B7=A5=E4=BD=9C?= =?UTF-8?q?=E7=A5=A8=E9=A2=84=E8=A7=88=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ticket/processflow/entity/ProcessDict.java | 4 +- .../ticket/twoTicket/entity/WorkTicketFinish.java | 4 ++ .../service/impl/TicketProcessServiceImpl.java | 67 +++++++++++++++------ .../service/impl/WorkTicketFinishServiceImpl.java | 5 +- .../hzims/ticket/twoTicket/utils/WordHelper.java | 6 +- ...工作票危险点分析及控制措施票.docx | Bin 28979 -> 30611 bytes .../template/电气第一种工作票模版.docx | Bin 43033 -> 42691 bytes 7 files changed, 61 insertions(+), 25 deletions(-) diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/entity/ProcessDict.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/entity/ProcessDict.java index d2240cb..185fef7 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/entity/ProcessDict.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/entity/ProcessDict.java @@ -2,6 +2,7 @@ package com.hnac.hzims.ticket.processflow.entity; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableId; +import com.baomidou.mybatisplus.annotation.TableName; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; @@ -22,13 +23,14 @@ import java.util.Date; @Data @ApiModel(value = "ProcessDict",description = "票据字典表") @Accessors(chain = true) +@TableName("process_dict") public class ProcessDict { /** * 票据编码 */ - @TableId(value = "dictCode",type = IdType.AUTO) + @TableId(type = IdType.AUTO) @ApiModelProperty("票据编码") private Long dictCode; diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/entity/WorkTicketFinish.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/entity/WorkTicketFinish.java index 145b692..b785073 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/entity/WorkTicketFinish.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/entity/WorkTicketFinish.java @@ -4,10 +4,12 @@ import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; +import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import lombok.EqualsAndHashCode; import lombok.experimental.Accessors; +import org.springframework.format.annotation.DateTimeFormat; import java.io.Serializable; import java.time.LocalDateTime; @@ -124,6 +126,8 @@ public class WorkTicketFinish implements Serializable { /** * 结束时间 */ + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") private LocalDateTime workEndTime; diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java index 2c8d482..15ce51e 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java @@ -5,9 +5,11 @@ import cn.afterturn.easypoi.word.WordExportUtil; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; import com.baomidou.mybatisplus.core.toolkit.IdWorker; import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; +import com.baomidou.mybatisplus.extension.conditions.update.LambdaUpdateChainWrapper; import com.hnac.hzims.common.logs.utils.StringUtils; import com.hnac.hzims.operational.access.entity.OperAccessTaskEntity; import com.hnac.hzims.operational.access.feign.IOperAccessTaskClient; @@ -250,16 +252,21 @@ public class TicketProcessServiceImpl implements TicketProcessService { e.printStackTrace(); } //更新安全措施 - List safetyMeasuresList = workTicketVo.getSafetyMeasuresList(); - if (CollectionUtils.isNotEmpty(safetyMeasuresList)) { - log.info("获取安全措施的数据:{}", safetyMeasuresList); - safetyMeasuresList.forEach(item -> { - if (ObjectUtils.isNotEmpty(item.getTicketId())) { - LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>(); - queryWrapper.eq(WorkTicketSafetyMeasureEntity::getTicketId, item.getTicketId()); - workTicketSafetyMeasureService.update(item, queryWrapper); + try { + List safetyMeasuresList = workTicketVo.getSafetyMeasuresList(); + if (CollectionUtils.isNotEmpty(safetyMeasuresList)) { + log.info("获取安全措施的数据:{}", safetyMeasuresList); + for (WorkTicketSafetyMeasureEntity item : safetyMeasuresList) { + if (ObjectUtils.isNotEmpty(item.getId())) { + workTicketSafetyMeasureService.updateById(item); + }else { + item.setTicketId(workTicketInfo.getId()); + workTicketSafetyMeasureService.save(item); + } } - }); + } + } catch (Exception e) { + e.printStackTrace(); } //工作票工作任务组 // List workTicketContentDtoList = workTicketVo.getWorkTicketContentDtoList(); @@ -299,7 +306,9 @@ public class TicketProcessServiceImpl implements TicketProcessService { //工作结束 WorkTicketFinish workTicketFinish = workTicketVo.getWorkTicketFinish(); try { - if (ObjectUtils.isNotEmpty(workTicketFinish) && 99 == workTicket.getFlowStatus().intValue()) { + + log.info("工作结束==============>"+ (workTicket.getFlowStatus().intValue())); + if (ObjectUtils.isNotEmpty(workTicketFinish)) { WorkTicketFinish ticketFinish = workTicketFinishService.selectByTicketId(workTicketInfo.getId()); log.info("获取工作结束:{}", workTicketFinish); if (ObjectUtils.isEmpty(workTicketFinish.getId()) || ObjectUtils.isEmpty(ticketFinish)) { @@ -427,6 +436,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { workTicket.setFlowTaskName("结束"); workTicket.setNextStepOperator(" "); workTicket.setStepOperator(" "); + workTicket.setFlowStatus(999); } else { workTicket.setFlowTaskId(taskId); workTicket.setFlowTaskName(response.getTaskName()); @@ -856,7 +866,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { WorkTicketDelayEntity workTicketDelay = workTicketVo.getWorkTicketDelay(); log.info("工作票延期: {}", workTicketDelay); if (ObjectUtils.isNotEmpty(workTicketDelay)) { - result.putAll(PdfUtils.objectToMapResult(workTicket, result)); + result.putAll(PdfUtils.objectToMapResult(workTicketDelay, result)); } else { result.putAll(PdfUtils.objectToMapResult(new WorkTicketDelayEntity(), result)); } @@ -973,12 +983,11 @@ public class TicketProcessServiceImpl implements TicketProcessService { //负责人 String licensorName = WordHelper.toMapAsString(result, "principalName", 10); result.put("principalName2", licensorName); - }else { + } else { WordHelper.putMap(result, "principalName2", 10); } //许可人确认工作票终结 - if (WordHelper.isNoneBlank(result, "workEndTime")) { log.info("许可人确认工作票终结"); //负责人 @@ -987,7 +996,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { //许可人 String licensorName = WordHelper.toMapAsString(result, "licensorName", 10); result.put("licensorName2", licensorName); - }else { + } else { WordHelper.putMap(result, "principalName3", 10); WordHelper.putMap(result, "licensorName2", 10); } @@ -1065,12 +1074,32 @@ public class TicketProcessServiceImpl implements TicketProcessService { * @param maps 新的Map * @param i 索引 */ - private static void listWichMap(List> matterLibraryListFive, List> matterLibraryListFlow, List> maps, int i) { - Map stringObjectMap = matterLibraryListFive.get(i); - Map stringObjectMap1 = matterLibraryListFlow.get(i); + private static void listWichMap(List> matterLibraryListFive, + List> matterLibraryListFlow, List> maps, int i) { HashMap objectObjectHashMap = new HashMap<>(); - objectObjectHashMap.put("safetyMeasure", stringObjectMap.get("safetyMeasure")); - objectObjectHashMap.put("safetyMeasure1", stringObjectMap1.get("safetyMeasure")); + if (matterLibraryListFive.size() > 0) { + if (matterLibraryListFive.size() <= i) { + objectObjectHashMap.put("safetyMeasure", ""); + } else { + Map stringObjectMap = matterLibraryListFive.get(i); + objectObjectHashMap.put("safetyMeasure", stringObjectMap.get("safetyMeasure")); + } + } else { + objectObjectHashMap.put("safetyMeasure", ""); + } + + + if (matterLibraryListFlow.size() > 0) { + if (matterLibraryListFlow.size() <= i) { + objectObjectHashMap.put("safetyMeasure1", ""); + } else { + Map stringObjectMap = matterLibraryListFive.get(i); + objectObjectHashMap.put("safetyMeasure1", stringObjectMap.get("safetyMeasure")); + } + }else { + objectObjectHashMap.put("safetyMeasure1", ""); + } + maps.add(objectObjectHashMap); } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/WorkTicketFinishServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/WorkTicketFinishServiceImpl.java index f6e0b8e..83519ba 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/WorkTicketFinishServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/WorkTicketFinishServiceImpl.java @@ -2,6 +2,7 @@ package com.hnac.hzims.ticket.twoTicket.service.impl; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; +import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.hnac.hzims.ticket.twoTicket.entity.WorkTicketFinish; import com.hnac.hzims.ticket.twoTicket.mapper.WorkTicketFinishMapper; @@ -34,8 +35,8 @@ public class WorkTicketFinishServiceImpl extends ServiceImpl queryWrapper = new LambdaQueryWrapper<>(); queryWrapper.eq(WorkTicketFinish::getTicketId, ticketId); queryWrapper.orderByDesc(WorkTicketFinish::getCreateTime); - queryWrapper.last("limit 1"); - return this.getOne(queryWrapper); + List list = this.list(queryWrapper); + return CollectionUtils.isNotEmpty(list) ? list.get(0) : null; } /** diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java index 8147ea9..e8505ad 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/utils/WordHelper.java @@ -71,8 +71,7 @@ public class WordHelper extends StringUtils { * 判断map不为为空 */ public static boolean isNoneBlank(Map result, String key) { - String value = WordHelper.toString(result.get(key)).trim(); - System.out.println(value.length()); + String value = WordHelper.toString(result.get(key)); if (StringUtils.isNoneBlank(value)) { return true; } @@ -116,6 +115,7 @@ public class WordHelper extends StringUtils { */ private static void isContainsKey(Map params, Map result) { + if (params.containsKey("principalName1")) { result.put("principalName1", params.get("principalName1")); params.remove("principalName1"); @@ -219,7 +219,7 @@ public class WordHelper extends StringUtils { Object newValue = StringUtils.isNoneBlank(toString(value).trim()) ? value : "\u00A0" + printSpace(count); result.put(key, newValue); } else { - Object newValue = StringUtils.isNoneBlank(toString(value).trim()) ? value : "\u00A0"; + Object newValue = StringUtils.isNoneBlank(toString(value).trim()) ? value : "\u00A0" + printSpace(4); result.put(key, newValue); } } diff --git a/hzims-service/ticket/src/main/resources/template/secondary/工作票危险点分析及控制措施票.docx b/hzims-service/ticket/src/main/resources/template/secondary/工作票危险点分析及控制措施票.docx index 591306f4dd39a664c81e9ae1a1e23d5978d32aad..5e86dca86b0163cacad3efb447dfa0409a3c8538 100644 GIT binary patch delta 17416 zcmaI819)Ul(+3(S6WiKNvazj=ZQI7i*2K20jcwbuZ9AJ}RB8>T`@YDU&EQ00{D$J%^#hw=&x(7XuTL$Ps^3;94F4#WHf}G=Suf(qZC8%! ze*1B$(<}NMYqC?Iwnhv4$kC3ISx=K^Cy9NXt8XQ4&Bgf>cX|m_QPeU8wn-QsE0eqx zf?DwkoFhE(r>5T@Tr3`#=kGww9=VWyX1Y!xJC2^Q0GS~*`S7IPiQwMzx`v?a z6g#esv1nMzLf%o9gV#Ei4J3nsyuI1p#S<`ki{O;!Wn`Zj#%KHDi{s&^AMa+B{PLla zNP9rc$NToNyR!bEQ;G$>t2SO-DZT`qgH)Cw;J2obvHY}u0G_b>4ZVIGoERLqSwo-c zj0Xa8x(y0~@^uAWZ5@p1jctvbf0@`g(YgJyzR=NdTo-Nf=~j8-t5JSp#e5uOeMDa( zRjDsP-QE}_5f(%pChY|)9o&~pI#iE77>Un34@+?i+gnj(TCPJgv(~5^;xmPb^%&D@ z=>$Q3l0g>gIdR`Mhm!od=NrOlV?$#zu}C&B`7hnvRq?zF(c+ z-*5ffkk#Z+JU7~Mevmo(R@#z4==y^^!QRtr${uYWUPS3cYsq=fg$^2cRjiSwLCuaC z8Zq5WPP?n=n9G1Z5;a^*%WgYOG?L4W*%vduuUJW31ShZqz-d!OU$3Pwz+Wm8MP5!K zmM_PZ@N$hm!;_fSox=i1L^yMf@8rZ4i{V?J$>0!DK0!XOidkdB<@3^C8o95DMk!AM(umD3 z1^)o@hLnitlUx1BBN^gN5a7k?g6U?CCc6jrHsQ~6<+S8biR9;BpDtdSUlg6EtiOH7 zpaTEFe`c|R@Z;xCW>JOAZ<2NBWT%e>tO;W&hmp(S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L7S79g8(`!aqtx7}x=+7s8F9=ES*Y!#=^zuz_LM-pg`WfRF zFx7XkyXUO`>v4H8pkQ^UW-I4orQrP?97IVL6pR4`H=7G#n{Y=QOHjig{VJTP#x zq+B<0f`8r|e@oLpT>o#k`z(?+-N?lLndl#Y@ejb?)Z4#@i8Tm_se_4{71qL&F*jS{{Vh}YUBU_ diff --git a/hzims-service/ticket/src/main/resources/template/电气第一种工作票模版.docx b/hzims-service/ticket/src/main/resources/template/电气第一种工作票模版.docx index f2760d0ff4c335bd1cbe226286a379ecaa2612e6..4684a3555ba8bf2649e184cd12c55b0e33cf7bd8 100644 GIT binary patch delta 17003 zcmV)gK%~E!&;rBF0AqOmfsfs-X;z(ShBreCh`!NNPkj0oJ zI3OfT>q?b#*p{z2$#|SN*Q^tJ;+c)*%;a)x$N4WCfs#JuFKizG34$OALOehUO2s4_ z=-2P{yC1q6&;M?tTFI@OcB5?7jxNwgsD+$aD_W&;?ex)w|2U;TCobd~j!`Qa6{}_* zUDz~#8w&2rBtBzA&%;y`$RkLa|j#SG<+iF-V z&XJ;3&08xg<)WECYuTkdL(vreR=2I9*=WG=6r;9oG!{H?#f^B-O15zpc18f%d~wyV z9dn}%gB}_PmzVNlHy|bfAV?uYcY^{$gW~gl2&*nYY$8Aqt1d`fGDs1`@yQ@D-H?Q2 zkU%#iF&U&TajJF;xK%f6@ZySPR}BaLv`^=&hJ9wO{u~5cH=Ocvxl(pEAxw(*!5HP* znFJWYUM&b!P#PM7kgr-LvjR#!6zk~1nq6D;`ajp|k5FGE{k@M?53>?)SU8-NH#eMr zO2hH{+HvNNbXPsYf@dvnn-w^ZR;{sGuD7g1H7PWBan%R1-fsfds}=vgvvoSAs`WB$ zDq%w#U>x*4-c>6E^ZpQNDh4+Zh*pm{D0GhLV^W0@+#Wd5)C4A%j%j>+08AGEzG%jD z7CsEogOM+`wHv`H$5bmH4&e%dQ*KXxEFIGZhLH&XD6I_zf&o4r=mT{Rz-pA7(&}*F zd>-XdU&Aq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Z+;Qt>soi|h%C<18rMa8W&0jrxa_GFHDrI z!!(z~$5#2lpTv7yZzicf>Nzz{Yb*C$k11_!J9k|Zs$W01=Jf@&FtMYP9=bcN4w(C6 zqJg}G{=Lifo>M39-S;Ett?kFc6&pSSr%Cz$E}5x0-6}zuYpVC5kX_Do`=WvpeI9z6 zNc?2FA#mUvtLV>6&sb-U*!HppN0j zj&t1JH90*U?@jG~pNjpSSJVH8O+EWvN!Iqb6LDu=IJz090 mvJ5CS)&dn=04fkb$O2ii^Cm|vvthchVDgM*s%$2UL6QKdK2#w9 From 3a41ebfaccacd052a049d70356c899ab66035bd8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=AE=B5=E9=A3=9E=E5=AE=87?= <2684146481@qq.com> Date: Tue, 6 Jun 2023 11:31:17 +0800 Subject: [PATCH 05/14] =?UTF-8?q?=E5=B7=A5=E4=BD=9C=E7=A5=A8=E6=8E=A8?= =?UTF-8?q?=E9=80=81=E6=B6=88=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/hnac/hzims/message/MessageConstants.java | 1 + .../service/impl/TicketProcessServiceImpl.java | 59 ++++++++++++++++++++-- 2 files changed, 56 insertions(+), 4 deletions(-) diff --git a/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/MessageConstants.java b/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/MessageConstants.java index e6a42b3..7b7fbdb 100644 --- a/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/MessageConstants.java +++ b/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/MessageConstants.java @@ -53,6 +53,7 @@ public class MessageConstants { DUTY("duty","值班消息"), SAFE("safe","安全消息"), ACCESS("access","检修消息"), + TICKETMESSAGE("ticket-message","工作票消息"), ; @Getter private String key; diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java index 15ce51e..15202c8 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java @@ -11,6 +11,9 @@ import com.baomidou.mybatisplus.core.toolkit.IdWorker; import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; import com.baomidou.mybatisplus.extension.conditions.update.LambdaUpdateChainWrapper; import com.hnac.hzims.common.logs.utils.StringUtils; +import com.hnac.hzims.message.MessageConstants; +import com.hnac.hzims.message.dto.MessagePushRecordDto; +import com.hnac.hzims.message.fegin.IMessageClient; import com.hnac.hzims.operational.access.entity.OperAccessTaskEntity; import com.hnac.hzims.operational.access.feign.IOperAccessTaskClient; import com.hnac.hzims.operational.feign.IAccessTaskClient; @@ -54,6 +57,7 @@ import org.springblade.core.tool.utils.Func; import org.springblade.core.tool.utils.ObjectUtil; import org.springblade.flow.core.entity.BladeFlow; import org.springblade.flow.core.feign.IFlowClient; +import org.springblade.system.feign.ISysClient; import org.springblade.system.user.cache.UserCache; import org.springblade.system.user.entity.User; import org.springblade.system.user.feign.IUserClient; @@ -147,6 +151,13 @@ public class TicketProcessServiceImpl implements TicketProcessService { private final ProcessDictService processDictService; + + private final IMessageClient messageClient; + + + private final ISysClient sysClient; + + /** * 启动开票流程 * @@ -306,15 +317,16 @@ public class TicketProcessServiceImpl implements TicketProcessService { //工作结束 WorkTicketFinish workTicketFinish = workTicketVo.getWorkTicketFinish(); try { - log.info("工作结束==============>"+ (workTicket.getFlowStatus().intValue())); if (ObjectUtils.isNotEmpty(workTicketFinish)) { WorkTicketFinish ticketFinish = workTicketFinishService.selectByTicketId(workTicketInfo.getId()); log.info("获取工作结束:{}", workTicketFinish); if (ObjectUtils.isEmpty(workTicketFinish.getId()) || ObjectUtils.isEmpty(ticketFinish)) { + log.info("获取工作结束保存成功"); workTicketFinish.setTicketId(workTicketInfo.getId()); workTicketFinishService.save(workTicketFinish); } else { + log.info("获取工作结束更新成功"); workTicketDelay.setInitialTime(LocalDateTime.now()); workTicketFinishService.updateByTicketId(workTicketFinish); } @@ -384,6 +396,47 @@ public class TicketProcessServiceImpl implements TicketProcessService { } catch (Exception e) { e.printStackTrace(); } + + + + //推送消息 + MessagePushRecordDto message = new MessagePushRecordDto(); + message.setBusinessClassify("business"); + message.setBusinessKey(MessageConstants.BusinessClassifyEnum.TICKETMESSAGE.getKey()); + message.setSubject(MessageConstants.BusinessClassifyEnum.TICKETMESSAGE.getDescription()); + message.setTaskId(workTicketInfo.getId()); + message.setTenantId("200000"); + message.setTypes(Arrays.asList(MessageConstants.APP_PUSH, MessageConstants.WS_PUSH)); + message.setPushType(MessageConstants.IMMEDIATELY); + //您有一张工作票待审批,工作内容:*****,审批环节:*****; + String countent = + "您有一张工作票待审批,工作内容:".concat(workTicketInfo.getWorkContent()) + .concat(",审批环节:") + .concat(response.getTaskName()); + message.setContent(countent); + message.setDeptId(workTicketInfo.getCreateDept()); + R deptName = sysClient.getDeptName(workTicketInfo.getCreateDept()); + if (deptName.isSuccess()) { + message.setDeptName(deptName.getData()); + } + String userIds = response.getUserId(); + if (StringUtils.isBlank(userIds)){ + log.error("推送的消息不能为空哦,{}",userIds); + return; + } + String[] split = userIds.split(","); + for (String userId : split) { + message.setPusher(userId); + User user = UserCache.getUser(NumberUtils.toLong(userId)); + if (ObjectUtils.isNotEmpty(user)) { + message.setPusherName(user.getName()); + } + message.setAccount(userId); + + message.setCreateUser(NumberUtils.toLong(userId)); + messageClient.sendMessage(message); + } + } @@ -432,7 +485,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { String taskId = response.getTaskId(); if (StringUtils.isEmpty(taskId)) { workTicket.setFlowDescription("结束"); - workTicket.setFlowTaskId(" "); + // workTicket.setFlowTaskId(" "); workTicket.setFlowTaskName("结束"); workTicket.setNextStepOperator(" "); workTicket.setStepOperator(" "); @@ -1165,8 +1218,6 @@ public class TicketProcessServiceImpl implements TicketProcessService { dataConversion.put(key, BooleanUtils.toBoolean(newValue) ? "☑" : "□"); } } - - } From b89c1f4b5a90bb1d8ec1ea0e7c0400a34932a845 Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Tue, 6 Jun 2023 17:20:35 +0800 Subject: [PATCH 06/14] =?UTF-8?q?#=E5=AE=9A=E6=97=B6=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E6=8A=BD=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hzims/operational/config/vo/StationRealVo.java | 12 + .../main/constant/HomePageConstant.java | 2 +- .../hzims/operational/main/vo/RealAttributeVo.java | 46 + .../hzims/operational/main/vo/RealDeviceVo.java | 26 + .../hzims/operational/main/vo/RealStationVo.java | 48 + .../hnac/hzims/operational/main/vo/WeatherVo.java | 24 + hzims-service/hzims-scheduled/pom.xml | 65 +- .../hnac/hzims/scheduled/config/XxlJobConfig.java | 59 - .../mapper/equipment/WorkshopInfoMapper.java | 10 + .../mapper/operation/AbnormalAlarmMapper.java | 12 +- .../scheduled/mapper/operation/GenerateMapper.java | 17 + .../operation/HistoryAbnormalAlarmMapper.java | 21 - .../operation/HzimsAnalyzeModelStationMapper.java | 13 - .../mapper/operation/ModelStationMapper.java | 12 + .../scheduled/mapper/operation/PowerMapper.java | 11 + .../scheduled/mapper/operation/RecordMapper.java | 17 + .../mapper/operation/StAlarmRecordMapper.java | 14 - .../mapper/operation/StFocusPropertiesMapper.java | 13 - .../mapper/operation/StationAttrConfigMapper.java | 6 +- .../mapper/operation/StationAttributeMapper.java | 11 +- .../scheduled/mapper/operation/StationMapper.java | 13 +- .../scheduled/mapper/operation/UseMapper.java | 13 + .../scheduled/scheduled/MonitorScheduledTask.java | 65 + .../scheduled/RealTargetScheduledTask.java | 126 ++ .../scheduled/scheduled/ReportScheduledTask.java | 14 + .../scheduled/scheduled/ScheduledCreateTask.java | 54 - .../scheduled/scheduled/ShowScheduledTask.java | 14 + .../scheduled/scheduled/StAlamRecordTask.java | 101 -- .../scheduled/service/AbnormalAlarmService.java | 19 - .../service/HistoryAbnormalAlarmService.java | 16 - .../service/IHzimsAnalyzeModelStationService.java | 17 - .../service/IMainSystemMonitoringService.java | 16 - .../scheduled/service/IRealMonitorService.java | 13 - .../service/IStationAttrConfigService.java | 16 - .../service/IStationAttributeService.java | 13 - .../hzims/scheduled/service/IStationService.java | 27 - .../hzims/scheduled/service/IWaterService.java | 11 - .../scheduled/service/StAlamRecordService.java | 14 - .../service/StFocusPropertiesService.java | 14 - .../service/equipment/WorkshopInfoService.java | 12 + .../equipment/impl/WorkshopInfoServiceImpl.java | 20 + .../service/impl/AbnormalAlarmServiceImpl.java | 242 ---- .../impl/HistoryAbnormalAlarmServiceImpl.java | 41 - .../impl/HzimsAnalyzeModelStationServiceImpl.java | 17 - .../impl/MainSystemMonitoringServiceImpl.java | 51 - .../service/impl/RealMonitorServiceImpl.java | 713 --------- .../service/impl/StAlamRecordServiceImpl.java | 42 - .../service/impl/StFocusPropertiesServiceImpl.java | 164 --- .../service/impl/StationAttrConfigServiceImpl.java | 42 - .../service/impl/StationAttributeServiceImpl.java | 22 - .../scheduled/service/impl/StationServiceImpl.java | 60 - .../scheduled/service/impl/WaterServiceImpl.java | 201 --- .../service/operation/AbnormalAlarmService.java | 15 + .../service/operation/AnalyseDataService.java | 22 + .../service/operation/GenerateService.java | 25 + .../service/operation/ModelStationService.java | 12 + .../service/operation/MonitorService.java | 16 + .../scheduled/service/operation/PowerService.java | 17 + .../service/operation/RealTargetService.java | 34 + .../scheduled/service/operation/RecordService.java | 13 + .../operation/StationAttrConfigService.java | 14 + .../service/operation/StationAttributeService.java | 14 + .../service/operation/StationService.java | 12 + .../scheduled/service/operation/UseService.java | 29 + .../operation/impl/AbnormalAlarmServiceImpl.java | 33 + .../operation/impl/AnalyseDataServiceImpl.java | 139 ++ .../operation/impl/GenerateServiceImpl.java | 112 ++ .../operation/impl/ModelStationServiceImpl.java | 16 + .../service/operation/impl/MonitorServiceImpl.java | 744 ++++++++++ .../service/operation/impl/PowerServiceImpl.java | 77 + .../operation/impl/RealTargetServiceImpl.java | 1512 ++++++++++++++++++++ .../service/operation/impl/RecordServiceImpl.java | 36 + .../impl/StationAttrConfigServiceImpl.java | 34 + .../impl/StationAttributeServiceImpl.java | 36 + .../service/operation/impl/StationServiceImpl.java | 19 + .../service/operation/impl/UseServiceImpl.java | 99 ++ .../hnac/hzims/scheduled/vo/RealAttributeVo.java | 52 - .../com/hnac/hzims/scheduled/vo/RealDeviceVo.java | 33 - .../com/hnac/hzims/scheduled/vo/RealStationVo.java | 54 - .../com/hnac/hzims/scheduled/vo/StationRealVo.java | 17 - .../com/hnac/hzims/scheduled/vo/WeatherVo.java | 30 - .../src/main/resources/application.yml | 208 --- .../mapper/equipment/WorkshopInfoMapper.xml | 5 + .../mapper/operation/AbnormalAlarmMapper.xml | 12 +- .../resources/mapper/operation/GenerateMapper.xml | 5 + .../mapper/operation/ModelStationMapper.xml | 21 + .../resources/mapper/operation/PowerMapper.xml | 32 + .../resources/mapper/operation/RecordMapper.xml | 29 + .../mapper/operation/StAlarmRecordMapper.xml | 19 - .../mapper/operation/StationAttrConfigMapper.xml | 5 + .../mapper/operation/StationAttributeMapper.xml | 15 + .../resources/mapper/operation/StationMapper.xml | 6 + .../main/resources/mapper/operation/UseMapper.xml | 4 + .../controller/CentralMonitorController.java | 2 +- .../config/service/CentralMonitorService.java | 2 +- .../service/impl/CentralMonitorServiceImpl.java | 2 +- .../service/impl/StAlamRecordServiceImpl.java | 22 +- .../hzims/operational/config/vo/StationRealVo.java | 12 - .../main/service/impl/HydropowerServiceImpl.java | 1 + .../service/impl/RealMonitorServiceImpl.java | 8 +- .../operational/station/vo/RealAttributeVo.java | 46 - .../hzims/operational/station/vo/RealDeviceVo.java | 26 - .../operational/station/vo/RealStationVo.java | 48 - .../hzims/operational/station/vo/WeatherVo.java | 24 - 104 files changed, 3735 insertions(+), 2727 deletions(-) create mode 100644 hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/config/vo/StationRealVo.java create mode 100644 hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealAttributeVo.java create mode 100644 hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealDeviceVo.java create mode 100644 hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealStationVo.java create mode 100644 hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/WeatherVo.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/config/XxlJobConfig.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/equipment/WorkshopInfoMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/GenerateMapper.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/HistoryAbnormalAlarmMapper.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/HzimsAnalyzeModelStationMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/ModelStationMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/PowerMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/RecordMapper.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StAlarmRecordMapper.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StFocusPropertiesMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/UseMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/MonitorScheduledTask.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/RealTargetScheduledTask.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ReportScheduledTask.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ScheduledCreateTask.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ShowScheduledTask.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/StAlamRecordTask.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/AbnormalAlarmService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/HistoryAbnormalAlarmService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IHzimsAnalyzeModelStationService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IMainSystemMonitoringService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IRealMonitorService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationAttrConfigService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationAttributeService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IWaterService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/StAlamRecordService.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/StFocusPropertiesService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/WorkshopInfoService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/WorkshopInfoServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/AbnormalAlarmServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/HistoryAbnormalAlarmServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/HzimsAnalyzeModelStationServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/MainSystemMonitoringServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/RealMonitorServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StAlamRecordServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StFocusPropertiesServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationAttrConfigServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationAttributeServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/WaterServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AbnormalAlarmService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AnalyseDataService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/GenerateService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ModelStationService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/PowerService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/RealTargetService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/RecordService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationAttrConfigService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationAttributeService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/UseService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AbnormalAlarmServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AnalyseDataServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/GenerateServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ModelStationServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MonitorServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/PowerServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RecordServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationAttrConfigServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationAttributeServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/UseServiceImpl.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealAttributeVo.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealDeviceVo.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealStationVo.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/StationRealVo.java delete mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/WeatherVo.java delete mode 100644 hzims-service/hzims-scheduled/src/main/resources/application.yml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/equipment/WorkshopInfoMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/GenerateMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/ModelStationMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/PowerMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/RecordMapper.xml delete mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StAlarmRecordMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationAttrConfigMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationAttributeMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/UseMapper.xml delete mode 100644 hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/vo/StationRealVo.java delete mode 100644 hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealAttributeVo.java delete mode 100644 hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealDeviceVo.java delete mode 100644 hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealStationVo.java delete mode 100644 hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/WeatherVo.java diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/config/vo/StationRealVo.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/config/vo/StationRealVo.java new file mode 100644 index 0000000..e61f1d2 --- /dev/null +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/config/vo/StationRealVo.java @@ -0,0 +1,12 @@ +package com.hnac.hzims.operational.config.vo; + +import lombok.Data; + +@Data +public class StationRealVo { + + private String station; + + private String[] realId; + +} diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/constant/HomePageConstant.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/constant/HomePageConstant.java index 30f464f..2879db1 100644 --- a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/constant/HomePageConstant.java +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/constant/HomePageConstant.java @@ -146,7 +146,7 @@ public interface HomePageConstant { // 水利-泵组实时属性名称 String JOINT_RELAY = "joint_relay"; // 开机状态 String SWITCH_ON_OFF = "switch_on_off"; // 开机状态 - String OFF = "1"; // 开机 + String OFF = "1.0"; // 开机 String ON = "0"; // 关机 String ELECTRICITY_CONSUMPTION = "electricity_consumption"; // 用电量 diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealAttributeVo.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealAttributeVo.java new file mode 100644 index 0000000..52a73ff --- /dev/null +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealAttributeVo.java @@ -0,0 +1,46 @@ +package com.hnac.hzims.operational.main.vo; + +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.io.Serializable; + +@Data +public class RealAttributeVo implements Serializable { + + @ApiModelProperty("属性名称") + private String name; + + @ApiModelProperty("属性数值") + private String value; + + @ApiModelProperty("属性单位") + private String unit; + + @ApiModelProperty("属性类型:1-遥信 2-遥测") + private Integer type; + + @ApiModelProperty("属性实时数据Id") + private String realId; + + @ApiModelProperty("告警Id") + private Long id; + + @ApiModelProperty("属性状态:0:正常、1:预警、2:告警、3:空值、4:黄色、5:橙色") + private int status; + + @ApiModelProperty("属性质量") + private int quality; + + @ApiModelProperty("属性时间") + private String time; + + @ApiModelProperty("属性故障ID") + private String fdpFaultId; + + @ApiModelProperty("监测点") + private String fdpMonitorId; + + @ApiModelProperty("属性故障值") + private Double fdpRate; +} diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealDeviceVo.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealDeviceVo.java new file mode 100644 index 0000000..0522108 --- /dev/null +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealDeviceVo.java @@ -0,0 +1,26 @@ +package com.hnac.hzims.operational.main.vo; + +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.io.Serializable; +import java.util.List; + +@Data +public class RealDeviceVo implements Serializable { + + @ApiModelProperty("设备编号") + private String deviceCode; + + @ApiModelProperty("设备名称") + private String deviceName; + + @ApiModelProperty("设备状态") + private Integer state; + + @ApiModelProperty("排序字段") + private Integer sort; + + @ApiModelProperty("设备属性集合") + private List attbtList; +} diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealStationVo.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealStationVo.java new file mode 100644 index 0000000..515d623 --- /dev/null +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/RealStationVo.java @@ -0,0 +1,48 @@ +package com.hnac.hzims.operational.main.vo; + +import io.swagger.annotations.ApiModelProperty; +import io.swagger.models.auth.In; +import lombok.Data; + +import java.io.Serializable; +import java.util.List; + +@Data +public class RealStationVo implements Serializable { + + @ApiModelProperty("站点Id") + private String stationCode; + + @ApiModelProperty("站点名称") + private String stationName; + + @ApiModelProperty("站点机构Id") + private Long stationDeptId; + + @ApiModelProperty("站点类型") + private String serverType; + + @ApiModelProperty("当前天气") + private WeatherVo nowWater; + + @ApiModelProperty("总有功率") + private Double powerSum; + + @ApiModelProperty("降水") + private String precipitation; + + @ApiModelProperty("最大前池水位") + private Double waterLevelMax; + + @ApiModelProperty("前池水位") + private Double waterLevel; + + @ApiModelProperty("设备集合") + private List deviceList; + + @ApiModelProperty("站点状态 : 0-正常 1-数据中断") + private Integer status; + + @ApiModelProperty("排序") + private Integer sort; +} diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/WeatherVo.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/WeatherVo.java new file mode 100644 index 0000000..284e995 --- /dev/null +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/WeatherVo.java @@ -0,0 +1,24 @@ +package com.hnac.hzims.operational.main.vo; + +import lombok.Data; + +import java.io.Serializable; + +@Data +public class WeatherVo implements Serializable { + + /**当前天气状况和图标的代码,图标可通过天气状况和图标下载; //100**/ + private String icon; + + /**实况温度,默认单位:摄氏度; //21**/ + private String temp; + + /**实况天气状况的文字描述,包括阴晴雨雪等天气状态的描述; //晴**/ + private String text; + + /**预报当天最高温度; //4**/ + private String tempMax; + + /**预报当天最低温度; //-5**/ + private String tempMin; +} diff --git a/hzims-service/hzims-scheduled/pom.xml b/hzims-service/hzims-scheduled/pom.xml index 4183ad7..87e3691 100644 --- a/hzims-service/hzims-scheduled/pom.xml +++ b/hzims-service/hzims-scheduled/pom.xml @@ -2,15 +2,15 @@ - 4.0.0 com.hnac.hzims hzims-service 4.0.0-SNAPSHOT + 4.0.0 hzims-scheduled - + jar 8 8 @@ -81,42 +81,6 @@ com.xuxueli xxl-job-core - - - - org.apache.poi - ooxml-schemas - 1.4 - - - org.jfree - jcommon - 1.0.24 - - - org.jfree - jfreechart - 1.5.0 - - - com.hikvision.ga - artemis-http-client - - - - - org.apache.httpcomponents - httpclient - - - - - - org.freemarker - freemarker - - - com.hnac.hzims equipment-api @@ -146,47 +110,22 @@ com.google.zxing javase - org.springblade blade-user-api - - org.apache.commons commons-collections4 - - - org.springframework.boot - spring-boot-starter-websocket - - - org.springframework.boot - spring-boot-starter-tomcat - - - - - cn.hutool hutool-http - - cn.hutool hutool-core - - - - org.java-websocket - Java-WebSocket - - org.springblade blade-resource-api diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/config/XxlJobConfig.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/config/XxlJobConfig.java deleted file mode 100644 index 6b473a9..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/config/XxlJobConfig.java +++ /dev/null @@ -1,59 +0,0 @@ -// package com.hnac.hzims.scheduled.config; -// -// import com.xxl.job.core.executor.impl.XxlJobSpringExecutor; -// import lombok.extern.slf4j.Slf4j; -// import org.springframework.beans.factory.annotation.Value; -// import org.springframework.context.annotation.Bean; -// import org.springframework.context.annotation.ComponentScan; -// import org.springframework.context.annotation.Configuration; -// -// /** -// * @Author WL -// * @Version v1.0 -// * @Serial 1.0 -// * @Date 2022/1/8 10:23 -// */ -// @Slf4j -// @Configuration -// //指定任务Handler所在包路径 -// public class XxlJobConfig { -// -// -// @Value("${xxl.job.admin.addresses}") -// private String adminAddresses; -// -// @Value("${xxl.job.executor.appname}") -// private String appName; -// -// @Value("${xxl.job.executor.ip}") -// private String ip; -// -// @Value("${xxl.job.executor.port}") -// private int port; -// -// @Value("${xxl.job.accessToken}") -// private String accessToken; -// -// @Value("${xxl.job.executor.logpath}") -// private String logPath; -// -// @Value("${xxl.job.executor.logretentiondays}") -// private int logRetentionDays; -// -// -// @Bean(initMethod = "start", destroyMethod = "destroy") -// public XxlJobSpringExecutor xxlJobExecutor() { -// log.info("====xxl-job config init===="); -// XxlJobSpringExecutor xxlJobSpringExecutor = new XxlJobSpringExecutor(); -// xxlJobSpringExecutor.setAdminAddresses(adminAddresses); -// xxlJobSpringExecutor.setAppName(appName); -// xxlJobSpringExecutor.setIp(ip); -// xxlJobSpringExecutor.setPort(port); -// xxlJobSpringExecutor.setAccessToken(accessToken); -// xxlJobSpringExecutor.setLogPath(logPath); -// xxlJobSpringExecutor.setLogRetentionDays(logRetentionDays); -// return xxlJobSpringExecutor; -// } -// -// } -// diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/equipment/WorkshopInfoMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/equipment/WorkshopInfoMapper.java new file mode 100644 index 0000000..3e0d5c4 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/equipment/WorkshopInfoMapper.java @@ -0,0 +1,10 @@ +package com.hnac.hzims.scheduled.mapper.equipment; + +import com.hnac.hzims.equipment.entity.WorkshopInfoEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface WorkshopInfoMapper extends UserDataScopeBaseMapper { +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/AbnormalAlarmMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/AbnormalAlarmMapper.java index b677a4e..12876bd 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/AbnormalAlarmMapper.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/AbnormalAlarmMapper.java @@ -1,20 +1,14 @@ package com.hnac.hzims.scheduled.mapper.operation; import com.hnac.hzims.operational.alert.entity.AbnormalAlarmEntity; -import org.apache.ibatis.annotations.Param; import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; import java.util.List; /** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 10:30 + * @author ysj */ -public interface AbnormalAlarmMapper extends UserDataScopeBaseMapper{ +public interface AbnormalAlarmMapper extends UserDataScopeBaseMapper { - AbnormalAlarmEntity getAbnormalAlarm(@Param("stationId") String stationId, @Param("type") String type); - - List getAbnormalAlarmList(); + List abnormalAlarms(); } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/GenerateMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/GenerateMapper.java new file mode 100644 index 0000000..7f2eaa1 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/GenerateMapper.java @@ -0,0 +1,17 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.fill.entity.GenerateEntity; +import org.apache.ibatis.annotations.Param; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +import java.util.List; + +/** + * @author ysj + * @date 2023/04/10 11:22:14 + * @version 4.0.0 + */ +public interface GenerateMapper extends UserDataScopeBaseMapper { + + List records(@Param("date") String date,@Param("station") String station); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/HistoryAbnormalAlarmMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/HistoryAbnormalAlarmMapper.java deleted file mode 100644 index e680c53..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/HistoryAbnormalAlarmMapper.java +++ /dev/null @@ -1,21 +0,0 @@ -package com.hnac.hzims.scheduled.mapper.operation; - -import com.hnac.hzims.operational.alert.entity.HistoryAbnormalAlarmEntity; -import org.apache.ibatis.annotations.Param; -import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; - -import java.util.List; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 11:12 - */ -public interface HistoryAbnormalAlarmMapper extends UserDataScopeBaseMapper { - - List getHistoryAbnormalAlarm(@Param("stationId") String stationId, @Param("type") String type); - - - -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/HzimsAnalyzeModelStationMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/HzimsAnalyzeModelStationMapper.java deleted file mode 100644 index 41ad4ad..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/HzimsAnalyzeModelStationMapper.java +++ /dev/null @@ -1,13 +0,0 @@ -package com.hnac.hzims.scheduled.mapper.operation; - -import com.baomidou.mybatisplus.core.mapper.BaseMapper; -import com.hnac.hzims.operational.station.entity.HzimsAnalyzeModelStationEntity; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/22 11:43 - */ -public interface HzimsAnalyzeModelStationMapper extends BaseMapper { -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/ModelStationMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/ModelStationMapper.java new file mode 100644 index 0000000..907e4ff --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/ModelStationMapper.java @@ -0,0 +1,12 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.hnac.hzims.operational.station.entity.HzimsAnalyzeModelStationEntity; + + +/** + * @author ysj + */ +public interface ModelStationMapper extends BaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/PowerMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/PowerMapper.java new file mode 100644 index 0000000..d463fd1 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/PowerMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.fill.entity.PowerEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface PowerMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/RecordMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/RecordMapper.java new file mode 100644 index 0000000..27d01a1 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/RecordMapper.java @@ -0,0 +1,17 @@ +package com.hnac.hzims.scheduled.mapper.operation; + + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.hnac.hzims.operational.config.entity.StAlarmRecordEntity; +import com.hnac.hzims.operational.config.vo.StAlarmRecordVo; + +import java.util.List; + +/** + * @author ysj + */ +public interface RecordMapper extends BaseMapper { + + Long insertReturnId(StAlarmRecordEntity record); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StAlarmRecordMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StAlarmRecordMapper.java deleted file mode 100644 index 8b3e211..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StAlarmRecordMapper.java +++ /dev/null @@ -1,14 +0,0 @@ -package com.hnac.hzims.scheduled.mapper.operation; - -import com.baomidou.mybatisplus.core.mapper.BaseMapper; -import com.hnac.hzims.operational.config.entity.StAlarmRecordEntity; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 15:47 - */ -public interface StAlarmRecordMapper extends BaseMapper { - Long insertReturnId(StAlarmRecordEntity record); -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StFocusPropertiesMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StFocusPropertiesMapper.java deleted file mode 100644 index 68d7a3d..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StFocusPropertiesMapper.java +++ /dev/null @@ -1,13 +0,0 @@ -package com.hnac.hzims.scheduled.mapper.operation; - -import com.baomidou.mybatisplus.core.mapper.BaseMapper; -import com.hnac.hzims.operational.config.entity.StFocusPropertiesEntity; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 11:28 - */ -public interface StFocusPropertiesMapper extends BaseMapper { -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationAttrConfigMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationAttrConfigMapper.java index 76a7952..04a16ee 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationAttrConfigMapper.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationAttrConfigMapper.java @@ -4,10 +4,8 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.hnac.hzims.operational.station.entity.StationAttrConfigEntity; /** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 16:09 + * @author ysj */ public interface StationAttrConfigMapper extends BaseMapper { + } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationAttributeMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationAttributeMapper.java index 89cf2a3..9cfd0f9 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationAttributeMapper.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationAttributeMapper.java @@ -1,13 +1,16 @@ package com.hnac.hzims.scheduled.mapper.operation; import com.hnac.hzims.operational.station.entity.StationAttributeEntity; +import org.apache.ibatis.annotations.Mapper; import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; +import java.util.List; + /** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 11:39 + * @author hx */ +@Mapper public interface StationAttributeMapper extends UserDataScopeBaseMapper { + + List PointUnit(); } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationMapper.java index 3b81746..f1d3745 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationMapper.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/StationMapper.java @@ -1,21 +1,12 @@ package com.hnac.hzims.scheduled.mapper.operation; + import com.hnac.hzims.operational.station.entity.StationEntity; import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; -import java.util.List; - /** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 10:36 + * @author ysj */ public interface StationMapper extends UserDataScopeBaseMapper { - List selectStationByType(Integer stationType, Integer serveType); - - List selectAll(); - - List selectStationByInCode(List codes); } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/UseMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/UseMapper.java new file mode 100644 index 0000000..364bce0 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/UseMapper.java @@ -0,0 +1,13 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.fill.entity.UseEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + * @date 2023/04/10 11:22:14 + * @version 4.0.0 + */ +public interface UseMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/MonitorScheduledTask.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/MonitorScheduledTask.java new file mode 100644 index 0000000..ed0af83 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/MonitorScheduledTask.java @@ -0,0 +1,65 @@ +package com.hnac.hzims.scheduled.scheduled; + +import com.hnac.hzims.scheduled.service.operation.MonitorService; +import com.xxl.job.core.biz.model.ReturnT; +import com.xxl.job.core.handler.annotation.XxlJob; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.Func; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Component; + +import java.util.Date; + +import static com.hnac.hzims.operational.main.constant.MainConstants.*; + + +/** + * @author ysj + */ +@Slf4j +@Component +public class MonitorScheduledTask { + + @Autowired + private MonitorService service; + + /** + * realId刷新 + */ + @XxlJob(REAL_ID_DATA) + public ReturnT loadRealId(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadRealId(param); + return new ReturnT<>("SUCCESS"); + } + + /** + * 实时数据刷新 + * @return ReturnT + */ + @XxlJob(REAL_TIME_DATA) + //@Scheduled(cron = "0/40 * * * * ? ") + public ReturnT loadRealData(String param) throws Exception { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadRealData(param); + return new ReturnT<>("SUCCESS"); + } + + /** + * 集中监控数据处理 + * @return ReturnT + */ + @XxlJob(CENTRALIZED_MONITORING) + public ReturnT loadMonitoring(String param) throws Exception { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadMonitoring(param); + return new ReturnT<>("SUCCESS"); + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/RealTargetScheduledTask.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/RealTargetScheduledTask.java new file mode 100644 index 0000000..b589578 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/RealTargetScheduledTask.java @@ -0,0 +1,126 @@ +package com.hnac.hzims.scheduled.scheduled; + +import com.hnac.hzims.operational.main.constant.HomePageConstant; +import com.hnac.hzims.scheduled.service.operation.RealTargetService; +import com.xxl.job.core.biz.model.ReturnT; +import com.xxl.job.core.handler.annotation.XxlJob; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.Func; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Component; + +import java.util.Arrays; +import java.util.Date; + +import static com.hnac.hzims.operational.main.constant.MainConstants.*; + + +/** + * @author ysj + */ +@Slf4j +@Component +public class RealTargetScheduledTask { + + @Autowired + private RealTargetService service; + + + /** + * 水电站-机组实时加载 + */ + @XxlJob(LOAD_HYDROPOWER_UNIT_REAL) + public ReturnT loadHydropowerReal(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadHydropowerReal(param); + return new ReturnT<>("SUCCESS"); + } + + /** + * 水电站-机组指标加载 + */ + @XxlJob(LOAD_HYDROPOWER_UNIT_TARGET) + public ReturnT loadHydropowerTarget(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadHydropowerTarget(param); + return new ReturnT<>("SUCCESS"); + } + + /** + * 水利-泵组实时加载 + */ + @XxlJob(LOAD_WATER_PUMP_REAL) + public ReturnT loadWaterPumpReal(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadWaterPumpReal(param); + return new ReturnT<>("SUCCESS"); + } + + + /** + * 水利-泵组指标加载 + */ + @XxlJob(LOAD_WATER_PUMP_TARGET) + public ReturnT loadWaterPumpTarget(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadWaterPumpTarget(param); + return new ReturnT<>("SUCCESS"); + } + + /** + * 水利-站点水位数据 + */ + @XxlJob(LOAD_WATER_LEVEL) + public ReturnT loadWaterLevel(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadWaterLevel(param); + return new ReturnT<>("SUCCESS"); + } + + /** + * 光伏站-逆变器实时加载 + */ + @XxlJob(LOAD_PHOTOVOLTAIC_REAL) + public ReturnT loadPhotovoltaicReal(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadPhotovoltaicReal(param); + return new ReturnT<>("SUCCESS"); + } + + /** + * 光伏站-逆变器指标加载 + */ + @XxlJob(LOAD_PHOTOVOLTAIC_TARGET) + public ReturnT loadPhotovoltaicTarget(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadPhotovoltaicTarget(param); + return new ReturnT<>("SUCCESS"); + } + + /** + * 获取站点近3年发电量数据 + */ + @XxlJob(ELECTRICITY_GENERATION_RECENT_YEAR) + public ReturnT loadPowerData(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadPowerData(param, Arrays.asList(HomePageConstant.HYDROPOWER,HomePageConstant.PHOTOVOLTAIC),2,3); + return new ReturnT<>("SUCCESS"); + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ReportScheduledTask.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ReportScheduledTask.java new file mode 100644 index 0000000..b5d19a6 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ReportScheduledTask.java @@ -0,0 +1,14 @@ +package com.hnac.hzims.scheduled.scheduled; + +import lombok.extern.slf4j.Slf4j; +import org.springframework.stereotype.Component; + + +/** + * @author ysj + */ +@Slf4j +@Component +public class ReportScheduledTask { + +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ScheduledCreateTask.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ScheduledCreateTask.java deleted file mode 100644 index 81cb979..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ScheduledCreateTask.java +++ /dev/null @@ -1,54 +0,0 @@ -package com.hnac.hzims.scheduled.scheduled; - -import com.hnac.hzims.scheduled.service.IWaterService; -import com.xxl.job.core.biz.model.ReturnT; -import com.xxl.job.core.handler.annotation.XxlJob; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.tool.utils.DateUtil; -import org.springblade.core.tool.utils.Func; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Component; - -import java.util.Date; - -import static com.hnac.hzims.operational.main.constant.MainConstants.LOAD_WATER_LEVEL; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/22 11:21 - */ -@Slf4j -@Component -public class ScheduledCreateTask { - - @Autowired - private IWaterService waterService; - - /** - * 水利-站点水位数据 - * @return ReturnT - */ - @XxlJob(LOAD_WATER_LEVEL) - public ReturnT loadWaterLevel(String param) throws Exception { - if (Func.isBlank(param)) { - param = DateUtil.format(new Date(), "yyyy-MM"); - } - waterService.loadWaterLevel(param); - return new ReturnT<>("SUCCESS"); - } - - - - /** - * 水利-站点水位数据 - * @return ReturnT - */ - @XxlJob("cheshi") - public ReturnT cheshi(String param) throws Exception { - System.out.println("执行呢方法"); - return new ReturnT<>("SUCCESS"); - } - -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ShowScheduledTask.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ShowScheduledTask.java new file mode 100644 index 0000000..c7bb905 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ShowScheduledTask.java @@ -0,0 +1,14 @@ +package com.hnac.hzims.scheduled.scheduled; + +import lombok.extern.slf4j.Slf4j; +import org.springframework.stereotype.Component; + + +/** + * @author ysj + */ +@Slf4j +@Component +public class ShowScheduledTask { + +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/StAlamRecordTask.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/StAlamRecordTask.java deleted file mode 100644 index b253c41..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/StAlamRecordTask.java +++ /dev/null @@ -1,101 +0,0 @@ -package com.hnac.hzims.scheduled.scheduled; - -import com.hnac.hzims.scheduled.service.AbnormalAlarmService; -import com.hnac.hzims.scheduled.service.IRealMonitorService; -import com.hnac.hzims.scheduled.service.StFocusPropertiesService; -import com.xxl.job.core.biz.model.ReturnT; -import com.xxl.job.core.handler.annotation.XxlJob; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.tool.utils.DateUtil; -import org.springblade.core.tool.utils.Func; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.beans.factory.annotation.Value; -import org.springframework.stereotype.Component; - -import java.util.Date; - -import static com.hnac.hzims.operational.main.constant.MainConstants.*; - -/** - * 集中监控 - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 10:17 - */ -@Slf4j -@Component -public class StAlamRecordTask { - - @Value("${hzims.operation.comprehensiveD}") - public String path; - - // @Autowired - private IRealMonitorService monitorService; - - @Autowired - private AbnormalAlarmService abnormalAlarmService; - - @Autowired - private StFocusPropertiesService stFocusPropertiesService; - - /** - * 数据中断告警 - * @return ReturnT - */ - @XxlJob(ALARM_DATA_HANDLE) - public ReturnT alarmDataHandle(String param) throws Exception { - if (Func.isBlank(param)) { - param = DateUtil.format(new Date(), "yyyy-MM"); - } - abnormalAlarmService.alarmDataHandle(param); - return new ReturnT<>("SUCCESS"); - } - - - - /** - * realId获取 - * @return ReturnT - */ - @XxlJob(REAL_ID_DATA) - public ReturnT realIdData(String param) throws Exception { - if (Func.isBlank(param)) { - param = DateUtil.format(new Date(), "yyyy-MM"); - } - stFocusPropertiesService.getStationRealIds(param); - return new ReturnT<>("SUCCESS"); - } - - /** - * 站点实时数据 - * @return ReturnT - */ - @XxlJob(REAL_TIME_DATA) - //@Scheduled(cron = "0/40 * * * * ? ") - public ReturnT realTimeData(String param) throws Exception { - if (Func.isBlank(param)) { - param = DateUtil.format(new Date(), "yyyy-MM"); - } - monitorService.realTimeData(param); - return new ReturnT<>("SUCCESS"); - } - - - - /** - * 集中监控数据处理 - * @return ReturnT - */ - @XxlJob(CENTRALIZED_MONITORING) - //@Scheduled(cron = "0/40 * * * * ? ") - public ReturnT centralizedMonitoring(String param) throws Exception { - if (Func.isBlank(param)) { - param = DateUtil.format(new Date(), "yyyy-MM"); - } - monitorService.centralizedMonitoring(param); - return new ReturnT<>("SUCCESS"); - } - - -} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/AbnormalAlarmService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/AbnormalAlarmService.java deleted file mode 100644 index 180d275..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/AbnormalAlarmService.java +++ /dev/null @@ -1,19 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -import com.hnac.hzims.operational.alert.entity.AbnormalAlarmEntity; -import org.springblade.core.mp.base.BaseService; - -import java.util.List; - -/** - * 告警处理接口 - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 10:20 - */ -public interface AbnormalAlarmService extends BaseService { - void alarmDataHandle(String param); - - List getAbnormalAlarmList(); -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/HistoryAbnormalAlarmService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/HistoryAbnormalAlarmService.java deleted file mode 100644 index 4c2816e..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/HistoryAbnormalAlarmService.java +++ /dev/null @@ -1,16 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -import com.hnac.hzims.operational.alert.entity.HistoryAbnormalAlarmEntity; -import org.springblade.core.mp.base.BaseService; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 11:09 - */ -public interface HistoryAbnormalAlarmService extends BaseService { - - - HistoryAbnormalAlarmEntity getAbnormalAlarm(String station, String soeType); -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IHzimsAnalyzeModelStationService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IHzimsAnalyzeModelStationService.java deleted file mode 100644 index 15c7b7a..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IHzimsAnalyzeModelStationService.java +++ /dev/null @@ -1,17 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.hnac.hzims.operational.station.entity.HzimsAnalyzeModelStationEntity; -import org.springblade.core.mp.base.BaseService; - -import java.util.List; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/22 11:31 - */ -public interface IHzimsAnalyzeModelStationService extends BaseService { - -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IMainSystemMonitoringService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IMainSystemMonitoringService.java deleted file mode 100644 index d9b6c4e..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IMainSystemMonitoringService.java +++ /dev/null @@ -1,16 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -import com.hnac.hzims.equipment.vo.EminfoAndEmParamVo; - -import java.util.List; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 14:00 - */ -public interface IMainSystemMonitoringService { - - List getEmInfoList(); -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IRealMonitorService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IRealMonitorService.java deleted file mode 100644 index 9de496f..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IRealMonitorService.java +++ /dev/null @@ -1,13 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 10:20 - */ -public interface IRealMonitorService { - void realTimeData(String param); - - void centralizedMonitoring(String param); -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationAttrConfigService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationAttrConfigService.java deleted file mode 100644 index 747bcc4..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationAttrConfigService.java +++ /dev/null @@ -1,16 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -import com.hnac.hzims.operational.station.entity.StationAttrConfigEntity; -import org.springblade.core.mp.base.BaseService; - -import java.util.List; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 16:06 - */ -public interface IStationAttrConfigService extends BaseService { - List getHideList(); -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationAttributeService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationAttributeService.java deleted file mode 100644 index 0713bb1..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationAttributeService.java +++ /dev/null @@ -1,13 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -import com.hnac.hzims.operational.station.entity.StationAttributeEntity; -import org.springblade.core.mp.base.BaseService; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 11:34 - */ -public interface IStationAttributeService extends BaseService { -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationService.java deleted file mode 100644 index 246d261..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IStationService.java +++ /dev/null @@ -1,27 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -import com.hnac.hzims.operational.station.entity.StationEntity; -import org.springblade.core.mp.base.BaseService; - -import java.util.ArrayList; -import java.util.List; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 10:33 - */ -public interface IStationService extends BaseService { - - List getStationByType(Integer stationType, Integer serveType); - - List getAll(); - - List getStationByInCode(List strings); - - - List getStationType(Integer serveType,List typeList,List departIdList); - - -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IWaterService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IWaterService.java deleted file mode 100644 index e50d049..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/IWaterService.java +++ /dev/null @@ -1,11 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/22 11:22 - */ -public interface IWaterService { - void loadWaterLevel(String param); -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/StAlamRecordService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/StAlamRecordService.java deleted file mode 100644 index cff89fd..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/StAlamRecordService.java +++ /dev/null @@ -1,14 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -import com.hnac.hzims.operational.config.entity.StAlarmRecordEntity; -import org.springblade.core.mp.base.BaseService; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 15:41 - */ -public interface StAlamRecordService extends BaseService { - Long insertAlert(String stationId, String monitorId); -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/StFocusPropertiesService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/StFocusPropertiesService.java deleted file mode 100644 index 479b4b3..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/StFocusPropertiesService.java +++ /dev/null @@ -1,14 +0,0 @@ -package com.hnac.hzims.scheduled.service; - -import com.hnac.hzims.operational.config.entity.StFocusPropertiesEntity; -import org.springblade.core.mp.base.BaseService; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 10:21 - */ -public interface StFocusPropertiesService extends BaseService { - void getStationRealIds(String param); -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/WorkshopInfoService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/WorkshopInfoService.java new file mode 100644 index 0000000..3fe8199 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/WorkshopInfoService.java @@ -0,0 +1,12 @@ +package com.hnac.hzims.scheduled.service.equipment; + +import com.hnac.hzims.equipment.entity.WorkshopInfoEntity; +import org.springblade.core.mp.base.BaseService; + + +/** + * @author hx + */ +public interface WorkshopInfoService extends BaseService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/WorkshopInfoServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/WorkshopInfoServiceImpl.java new file mode 100644 index 0000000..20aed9a --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/WorkshopInfoServiceImpl.java @@ -0,0 +1,20 @@ +package com.hnac.hzims.scheduled.service.equipment.impl; + +import com.hnac.hzims.equipment.entity.WorkshopInfoEntity; +import com.hnac.hzims.scheduled.mapper.equipment.WorkshopInfoMapper; +import com.hnac.hzims.scheduled.service.equipment.WorkshopInfoService; +import groovy.util.logging.Slf4j; +import lombok.AllArgsConstructor; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author hx + */ +@Service +@AllArgsConstructor +@Slf4j +public class WorkshopInfoServiceImpl extends BaseServiceImpl implements WorkshopInfoService { + + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/AbnormalAlarmServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/AbnormalAlarmServiceImpl.java deleted file mode 100644 index 9a57ee4..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/AbnormalAlarmServiceImpl.java +++ /dev/null @@ -1,242 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.hnac.hzims.message.MessageConstants; -import com.hnac.hzims.message.dto.MessagePushRecordDto; -import com.hnac.hzims.message.fegin.IMessageClient; -import com.hnac.hzims.operational.alert.constants.AbnormalAlarmConstant; -import com.hnac.hzims.operational.alert.entity.AbnormalAlarmEntity; -import com.hnac.hzims.operational.alert.entity.HistoryAbnormalAlarmEntity; -import com.hnac.hzims.operational.main.constant.HomePageConstant; -import com.hnac.hzims.operational.station.entity.StationEntity; -import com.hnac.hzims.scheduled.mapper.operation.AbnormalAlarmMapper; -import com.hnac.hzims.scheduled.service.AbnormalAlarmService; -import com.hnac.hzims.scheduled.service.HistoryAbnormalAlarmService; -import com.hnac.hzims.scheduled.service.IStationService; -import com.hnac.hzinfo.datasearch.soe.ISoeClient; -import com.hnac.hzinfo.datasearch.soe.domian.SoeData; -import com.hnac.hzinfo.datasearch.soe.domian.SoeQueryConditionByStation; -import com.hnac.hzinfo.sdk.core.response.HzPage; -import com.hnac.hzinfo.sdk.core.response.Result; -import lombok.RequiredArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.mp.base.BaseServiceImpl; -import org.springblade.core.tool.api.R; -import org.springblade.core.tool.utils.CollectionUtil; -import org.springblade.core.tool.utils.DateUtil; -import org.springblade.core.tool.utils.ObjectUtil; -import org.springblade.core.tool.utils.StringUtil; -import org.springblade.system.feign.ISysClient; -import org.springblade.system.user.entity.User; -import org.springblade.system.user.feign.IUserClient; -import org.springframework.stereotype.Service; - -import java.time.LocalDateTime; -import java.util.*; -import java.util.concurrent.CompletableFuture; -import java.util.function.Function; -import java.util.stream.Collectors; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 10:29 - */ -@Slf4j -@Service -@RequiredArgsConstructor -public class AbnormalAlarmServiceImpl extends BaseServiceImpl implements AbnormalAlarmService { - - - private final IStationService stationService; - - - private final HistoryAbnormalAlarmService historyAbnormalAlarmService; - - private final ISysClient sysClient; - - private final ISoeClient soeClient; - - private final IUserClient userClient; - - private final IMessageClient messageClient; - - - /** - * 数据中断、数据异常告警 - * @param param - */ - @Override - public void alarmDataHandle(String param) { - // 查询代运维站点 - List stations = stationService.getStationByType(null, HomePageConstant.HYDROPOWER_SERVETYPE); - if(CollectionUtil.isEmpty(stations)){ - return; - } - SoeQueryConditionByStation query = new SoeQueryConditionByStation(); - query.setTypes(AbnormalAlarmConstant.SEND_MESSSAGE_TYPE_LIST); - query.setStationIds(stations.stream().map(StationEntity::getCode).collect(Collectors.toList())); - Calendar calendar = Calendar.getInstance(); - query.setEndTime(LocalDateTime.parse(DateUtil.format(calendar.getTime(), DateUtil.PATTERN_DATETIME),DateUtil.DATETIME_FORMATTER)); - calendar.add(Calendar.MINUTE,-2); - query.setBeginTime(LocalDateTime.parse(DateUtil.format(calendar.getTime() , DateUtil.PATTERN_DATETIME),DateUtil.DATETIME_FORMATTER)); - query.setNeedPage(false); - log.error("alarm_data_handle_param : {}",query); - Result> result = soeClient.getByStationsAndTime(query); - // 未查询到告警信息 - if(!result.isSuccess() || ObjectUtil.isEmpty(result.getData().getRecords())){ - return; - } - log.error("alarm_data_handle_begin_result : {}",result.getData().getRecords()); - // 遍历告警信息 - List list = new ArrayList<>(result.getData().getRecords().stream().sorted(Comparator.comparing(SoeData::getTs).reversed()) - .collect(Collectors.toMap(o -> o.getStation() + o.getSoeType(), Function.identity(), (o1, o2) -> o1)).values()); - log.error("alarm_data_handle_end_result : {}",list); - list.forEach(item -> { - AbnormalAlarmEntity queryEntity = this.baseMapper.getAbnormalAlarm(item.getStation(),item.getSoeType()); - boolean flag = AbnormalAlarmConstant.ABNORMAL_STATUS.equals(item.getSoeAlarmType()); - String stationName = Optional.ofNullable(stations.stream().filter(o-> o.getCode().equals(item.getStation())).collect(Collectors.toList())).map(o->o.get(0).getName()).orElse(null); - if(ObjectUtil.isEmpty(queryEntity)){ - AbnormalAlarmEntity entity = new AbnormalAlarmEntity(); - entity.setStationId(item.getStation()); - entity.setStationName(stationName); - entity.setRealId(item.getRealId()); - entity.setSoeExplain(item.getSoeExplain()); - entity.setType(item.getSoeType()); - entity.setStartTime(item.getTs()); - entity.setEndTime(null); - entity.setStatus(0); - if(flag){ - entity.setStartTime(null); - entity.setEndTime(item.getTs()); - entity.setStatus(1); - } - // 保存告警信息 - this.save(entity); - return; - } - queryEntity.setSoeExplain(item.getSoeExplain()); - queryEntity.setStationName(stationName); - queryEntity.setType(item.getSoeType()); - queryEntity.setStartTime(queryEntity.getStartTime()); - queryEntity.setUpdateTime(new Date()); - queryEntity.setEndTime(null); - queryEntity.setStatus(0); - if(flag){ - queryEntity.setEndTime(item.getTs()); - queryEntity.setStatus(1); - } - this.updateById(queryEntity); - }); - - // 异步保存历史告警 - CompletableFuture.supplyAsync(()-> this.saveHistoryAlarm(result.getData().getRecords(),stations)); - } - - - /** - * 保存告警历史信息 - * @param list - * @return - */ - private String saveHistoryAlarm(List list,List stations) { - list.forEach(item -> { - Date ts = DateUtil.parse(DateUtil.format(item.getTs(),DateUtil.PATTERN_DATETIME),DateUtil.DATETIME_FORMAT); - // 历史数据异常查询 - HistoryAbnormalAlarmEntity queryEntity = this.historyAbnormalAlarmService.getAbnormalAlarm(item.getStation(),item.getSoeType()); - // 数据中断恢复 - boolean flag = AbnormalAlarmConstant.ABNORMAL_STATUS.equals(item.getSoeAlarmType()); - String stationName = Optional.ofNullable(stations.stream().filter(o-> o.getCode().equals(item.getStation())).collect(Collectors.toList())).map(o->o.get(0).getName()).orElse(null); - if(ObjectUtil.isEmpty(queryEntity) || !flag){ - HistoryAbnormalAlarmEntity entity = new HistoryAbnormalAlarmEntity(); - entity.setAlarmId(item.getId()); - entity.setStationId(item.getStation()); - entity.setStationName(stationName); - entity.setRealId(item.getRealId()); - entity.setSoeExplain(item.getSoeExplain()); - entity.setType(item.getSoeType()); - entity.setStartTime(ts); - entity.setStatus(0); - this.historyAbnormalAlarmService.save(entity); - // 消息推送 - this.sendAlarmMessage(Collections.singletonList(entity),stations); - return; - } - queryEntity.setSoeExplain(item.getSoeExplain()); - queryEntity.setUpdateTime(new Date()); - queryEntity.setEndTime(ts); - queryEntity.setStatus(1); - this.historyAbnormalAlarmService.updateById(queryEntity); - }); - return "success"; - } - - - - /** - * 告警消息推送 - * @param entitys - */ - private void sendAlarmMessage(List entitys,List stations) { - if(CollectionUtil.isEmpty(entitys)){ - return; - } - // 告警等级 :事故、数据中断 - List alarms = entitys.stream().filter(entity -> AbnormalAlarmConstant.SEND_MESSSAGE_TYPE_LIST.contains(entity.getType())).collect(Collectors.toList()); - if(CollectionUtil.isEmpty(alarms)){ - return; - } - // 查询站点用户 - entitys.forEach(entity->{ - if(StringUtil.isEmpty(entity.getStationId())){ - return; - } - List depts = stations.stream().filter(station -> station.getCode().equals(entity.getStationId())).map(StationEntity::getRefDept).collect(Collectors.toList()); - if(CollectionUtil.isEmpty(depts)){ - return; - } - // 获取站点用户 - R> result = userClient.userListByDeptId(depts.get(0)); - if(!result.isSuccess() || CollectionUtil.isEmpty(result.getData())){ - return; - } - MessagePushRecordDto message = new MessagePushRecordDto(); - message.setBusinessClassify("warning"); - message.setBusinessKey(MessageConstants.BusinessClassifyEnum.WARNING.getKey()); - message.setSubject(MessageConstants.BusinessClassifyEnum.WARNING.getDescription()); - message.setTaskId(entity.getId()); - message.setTenantId("200000"); - message.setContent(entity.getSoeExplain()); - message.setTypes(Arrays.asList(MessageConstants.APP_PUSH, MessageConstants.WS_PUSH)); - message.setPushType(MessageConstants.IMMEDIATELY); - message.setDeptId(depts.get(0)); - R deptName = sysClient.getDeptName(depts.get(0)); - if (deptName.isSuccess()) { - message.setDeptName(deptName.getData()); - } - User admin = userClient.userByAccount("200000", "admin").getData(); - message.setCreateDept(admin.getCreateDept()); - message.setCreateUser(admin.getCreateUser()); - result.getData().forEach(user->{ - message.setPusher(String.valueOf(user.getId())); - message.setPusherName(user.getName()); - message.setAccount(String.valueOf(user.getId())); - messageClient.sendMessage(message); - }); - }); - } - - - /** - * 查询实时告警数据 - * @return - */ - @Override - public List getAbnormalAlarmList() { - List alarmList = this.baseMapper.getAbnormalAlarmList(); - if(CollectionUtil.isEmpty(alarmList)){ - return new ArrayList<>(); - } - return alarmList; - } -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/HistoryAbnormalAlarmServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/HistoryAbnormalAlarmServiceImpl.java deleted file mode 100644 index 6824c7a..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/HistoryAbnormalAlarmServiceImpl.java +++ /dev/null @@ -1,41 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.hnac.hzims.operational.alert.entity.HistoryAbnormalAlarmEntity; -import com.hnac.hzims.scheduled.mapper.operation.HistoryAbnormalAlarmMapper; -import com.hnac.hzims.scheduled.service.HistoryAbnormalAlarmService; -import lombok.RequiredArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.mp.base.BaseServiceImpl; -import org.springblade.core.tool.utils.CollectionUtil; -import org.springframework.stereotype.Service; - -import java.util.Comparator; -import java.util.List; -import java.util.stream.Collectors; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 11:12 - */ -@Slf4j -@Service -@RequiredArgsConstructor -public class HistoryAbnormalAlarmServiceImpl extends BaseServiceImpl implements HistoryAbnormalAlarmService { - /** - * 查询单条历史告警 - * - * @param station - * @param soeType - * @return - */ - @Override - public HistoryAbnormalAlarmEntity getAbnormalAlarm(String station, String soeType) { - List alarms = this.baseMapper.getHistoryAbnormalAlarm(station, soeType); - if(CollectionUtil.isEmpty(alarms)){ - return null; - } - return alarms.stream().sorted(Comparator.comparing(HistoryAbnormalAlarmEntity::getStartTime)).collect(Collectors.toList()).get(0); - } -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/HzimsAnalyzeModelStationServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/HzimsAnalyzeModelStationServiceImpl.java deleted file mode 100644 index 26c1e39..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/HzimsAnalyzeModelStationServiceImpl.java +++ /dev/null @@ -1,17 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.hnac.hzims.operational.station.entity.HzimsAnalyzeModelStationEntity; -import com.hnac.hzims.scheduled.mapper.operation.HzimsAnalyzeModelStationMapper; -import com.hnac.hzims.scheduled.service.IHzimsAnalyzeModelStationService; -import org.springblade.core.mp.base.BaseServiceImpl; -import org.springframework.stereotype.Service; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/22 11:42 - */ -@Service -public class HzimsAnalyzeModelStationServiceImpl extends BaseServiceImpl implements IHzimsAnalyzeModelStationService { -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/MainSystemMonitoringServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/MainSystemMonitoringServiceImpl.java deleted file mode 100644 index 2620394..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/MainSystemMonitoringServiceImpl.java +++ /dev/null @@ -1,51 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.alibaba.fastjson.JSONObject; -import com.alibaba.fastjson.TypeReference; -import com.hnac.hzims.equipment.vo.EminfoAndEmParamVo; -import com.hnac.hzims.scheduled.service.IMainSystemMonitoringService; -import lombok.RequiredArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.tool.utils.ObjectUtil; -import org.springframework.beans.factory.annotation.Value; -import org.springframework.data.redis.core.RedisTemplate; -import org.springframework.stereotype.Service; - -import java.util.ArrayList; -import java.util.List; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 14:01 - */ -@Service -@Slf4j -@RequiredArgsConstructor -public class MainSystemMonitoringServiceImpl implements IMainSystemMonitoringService { - - - private final RedisTemplate redisTemplate; - - - @Value("${hzims.equipment.emInfo.emInfoList}") - public String emInfoListPath; - - /** - * 从Redis获取设备信息 - * - * @return - */ - @Override - public List getEmInfoList() { - List list = new ArrayList<>(); - Object json = redisTemplate.opsForValue().get(emInfoListPath); - if (ObjectUtil.isNotEmpty(json)) { - list = JSONObject.parseObject(json.toString(), new TypeReference>() { - }); - } - return list; - } - -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/RealMonitorServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/RealMonitorServiceImpl.java deleted file mode 100644 index 4a595ad..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/RealMonitorServiceImpl.java +++ /dev/null @@ -1,713 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.alibaba.fastjson.JSONObject; -import com.alibaba.fastjson.TypeReference; -import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.hnac.hzims.equipment.vo.EminfoAndEmParamVo; -import com.hnac.hzims.fdp.vo.FdpFaultStatusVo; -import com.hnac.hzims.operational.config.entity.StAlarmRecordEntity; -import com.hnac.hzims.operational.config.enume.ConfigStatus; -import com.hnac.hzims.operational.main.constant.HomePageConstant; -import com.hnac.hzims.operational.station.entity.StationAttributeEntity; -import com.hnac.hzims.operational.station.entity.StationEntity; -import com.hnac.hzims.scheduled.service.*; -import com.hnac.hzims.scheduled.vo.RealAttributeVo; -import com.hnac.hzims.scheduled.vo.RealDeviceVo; -import com.hnac.hzims.scheduled.vo.RealStationVo; -import com.hnac.hzims.scheduled.vo.StationRealVo; -import com.hnac.hzinfo.sdk.v5.redis.RedisClient; -import lombok.RequiredArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.apache.commons.collections4.MapUtils; -import org.springblade.core.tool.api.R; -import org.springblade.core.tool.utils.CollectionUtil; -import org.springblade.core.tool.utils.DateUtil; -import org.springblade.core.tool.utils.ObjectUtil; -import org.springblade.core.tool.utils.StringUtil; -import org.springblade.system.entity.Dept; -import org.springblade.system.feign.ISysClient; -import org.springframework.beans.factory.annotation.Value; -import org.springframework.data.redis.core.RedisTemplate; -import org.springframework.stereotype.Service; - -import javax.validation.constraints.NotNull; -import java.util.*; -import java.util.concurrent.*; -import java.util.stream.Collectors; -import java.util.stream.Stream; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 13:54 - */ -@Service -@RequiredArgsConstructor -@Slf4j -public class RealMonitorServiceImpl implements IRealMonitorService { - - @NotNull - private final IStationAttributeService attbtService; - - - private final AbnormalAlarmService abnormalAlarmService; - - private final StAlamRecordService alertService; - - @NotNull - private final IStationService stationService; - @NotNull - private final IMainSystemMonitoringService maintenanceTaskService; - @NotNull - private final RedisTemplate redisTemplate; - - - private final IMainSystemMonitoringService systemMonitoringService; - - - private final RedisClient redisClient; - - @NotNull - private final ISysClient sysClient; - - - private final IStationAttrConfigService stationAttrConfigService; - - @Value("${hzims.operation.monitor.realId}") - public String moniter_realId_key; - - @Value("${hzims.operation.monitor.station}") - public String moniter_station_key; - - @Value("${hzims.equipment.fdp.redisData}") - public String fdp_fault_data_key; - - @Value("${hzims.operation.homePage.activePowerKey}") - public String active_power_key; - - @Value("${hzims.equipment.fdp.greaterThan}") - public Double greater_than; - - @Value("${hzims.equipment.fdp.lessThan}") - public Double less_than; - - @Value("${hzims.equipment.fdp.beEqualOrGreaterThan}") - public Double be_equal_or_greater_than; - - @Value("${hzims.operation.region.deviceClassifyKey}") - private String device_classify_key; - - @Value("${hzims.operation.realIdKeyGather}") - public String real_id_key_gather_path; - - @Value("${hzims.operation.realIdKey}") - public String real_id_key_path; - - @Value("${hzims.operation.homePage.jointRelayKey}") - public String joint_relay_key; - - /** - * 10站点为一组数据 - */ - private static final Integer MAX_SEND = 5; - - private final static String loadwater_level_key = "hzims:operation:loadwater:level:key"; - - - @Override - public void realTimeData(String param) { - Long beginTime = System.currentTimeMillis(); - // 获取设备 - List devices = systemMonitoringService.getEmInfoList(); - // 设备开关机集合监测点 - List switchOnOff = devices.stream().map(o->{ - Map points = o.getPoint(); - if(CollectionUtil.isEmpty(points)){ - return ""; - } - String jointRelay = points.get(HomePageConstant.JOINT_RELAY); - if(!StringUtil.isEmpty(jointRelay)){ - return jointRelay; - } - String onOff = points.get(HomePageConstant.SWITCH_ON_OFF); - if(!StringUtil.isEmpty(onOff)){ - return onOff; - } - return ""; - }).collect(Collectors.toList()); - // 获取站点缓存数据 - List stationRealVos = (List) redisTemplate.opsForValue().get(moniter_realId_key); - if(CollectionUtil.isEmpty(stationRealVos)){ - return; - } - // 数据切割 - int limit = countStep(stationRealVos.size()); - List> list = Stream.iterate(0, n -> n + 1).limit(limit).parallel().map(a -> stationRealVos.stream().skip((long) a * MAX_SEND).limit(MAX_SEND).parallel().collect(Collectors.toList())).collect(Collectors.toList()); - ExecutorService pool = Executors.newFixedThreadPool(limit); - // - Map valueMap = new ConcurrentHashMap<>(); - // > - Map> keyMap = new ConcurrentHashMap<>(); - CountDownLatch countDownLatch = new CountDownLatch(limit); - pool.execute(()-> list.forEach(stations -> { - stations.forEach(stationReal -> { - String[] realIdArr = stationReal.getRealId(); - List realIds = Stream.of(realIdArr).collect(Collectors.toList()); - if(CollectionUtil.isEmpty(realIds)){ - return; - } - log.error("real_time_data: {},{}",stationReal.getStation(),realIds); - List objects = redisClient.getBatchRealDataByRealId(stationReal.getStation(),realIds); - for(int i = 0; i < realIds.size() ;i++){ - if(ObjectUtil.isEmpty(objects.get(i))){ - log.error(realIds.get(i) + "is null"); - }else{ - Map attribute = (Map) JSONObject.parse(objects.get(i)); - attribute.put("realId",attribute.get("k")); - attribute.put("value",attribute.get("v")); - attribute.put("time",attribute.get("t")); - attribute.remove("v"); - attribute.remove("k"); - attribute.remove("t"); - this.getCheckMap(attribute,switchOnOff); - valueMap.put(realIdArr[i],attribute.get("value")); - keyMap.put(realIdArr[i],attribute); - } - } - }); - countDownLatch.countDown(); - })); - // 等待所有线程执行完成 - try { - countDownLatch.await(); - } catch (InterruptedException e) { - e.printStackTrace(); - Thread.currentThread().interrupt(); - } - pool.shutdown(); - // redis 存储 - redisTemplate.opsForValue().set(real_id_key_path,JSONObject.toJSONString(valueMap)); - redisTemplate.opsForValue().set(real_id_key_gather_path,JSONObject.toJSONString(keyMap)); - Long endTime = System.currentTimeMillis(); - Long time = endTime - beginTime; - log.error("处理redis实时数据 耗时 : {}",time); - } - - - - /** - * 计算切分次数 - */ - private static Integer countStep(Integer size) { - return (size + MAX_SEND - 1) / MAX_SEND; - } - - - /** - * 监测点过期数据检查 - * @param value - * @return - */ - private void getCheckMap(Map value,List switchOnOff){ - // 不处理开机状态监测点 - if(switchOnOff.contains(value.get("realId"))){ - return; - } - String time = value.get("time"); - if(StringUtil.isEmpty(time)){ - return; - } - Date date = DateUtil.parse(time,DateUtil.PATTERN_DATETIME); - // 实时数据超出10分钟未刷新,值置为 0 显示 - if(System.currentTimeMillis() - date.getTime() > 10 * 60 * 1000L){ - value.put("value","0"); - } - } - - - - - /** - * 集中监控数据处理 - * @param param - */ - @Override - public void centralizedMonitoring(String param) { - long beginTime = System.currentTimeMillis(); - Thread thread = Thread.currentThread(); - Object json = redisTemplate.opsForValue().get(real_id_key_gather_path); - if (ObjectUtil.isEmpty(json)) { - return; - } - Map> map = JSONObject.parseObject(json.toString(), new TypeReference>>() { - }); - if (MapUtils.isEmpty(map)) { - return; - } - log.info(thread.getName() + "步骤1获取检测点数据耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 获取所有设备重点属性 - List list = attbtService.list(new LambdaQueryWrapper() {{ - isNotNull(StationAttributeEntity::getStationId); - eq(StationAttributeEntity::getIsDeleted, "0"); - orderByAsc(StationAttributeEntity::getSort); - }}); - if (CollectionUtil.isEmpty(list)) { - return; - } - log.info(thread.getName() + "步骤2获取监控配置监测点 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 获取所有告警记录 - List alertList = alertService.list(new LambdaQueryWrapper() {{ - orderByDesc(StAlarmRecordEntity::getCreateTime); - }}); - log.info(thread.getName() + "步骤3获取告警记录 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - List alarmList = abnormalAlarmService.getAbnormalAlarmList(); - log.info(thread.getName() + "步骤4获取数据中断告警记录 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 获取所有故障记录 - List faultList = this.getFdpFaultAll(); - log.info(thread.getName() + "步骤5获取故障记录 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 所有设备分类 - Map> deviceClassifyMap = (Map>) redisTemplate.opsForValue().get(device_classify_key); - log.info(thread.getName() + "步骤6获取设备分类 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 所有设备 - List emList = maintenanceTaskService.getEmInfoList(); - log.info(thread.getName() + "步骤7获取设备信息 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 根据站点分组 - Map> stationAttbtMap = list.stream().collect(Collectors.groupingBy(StationAttributeEntity::getStationId)); - // 获取站点列表 - List stationEntityList = stationService.getStationByInCode(new ArrayList<>(stationAttbtMap.keySet())); - log.info(thread.getName() + "步骤8站点列表 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 隐藏设备列表 - List hideList = stationAttrConfigService.getHideList(); - // 分割,每个map限制10个长度 - List>> handleList = this.mapChunk(stationAttbtMap); - log.info(thread.getName() + "步骤9监测点数据切割 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 创建线程池 - ExecutorService pool = Executors.newFixedThreadPool(handleList.size()); - CountDownLatch countDownLatch = new CountDownLatch(handleList.size()); - log.info(thread.getName() +"步骤10创建线程 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 所有机构 - R> deptAll = sysClient. getDeptList(); - // 存储数据节点 - List stationList = new CopyOnWriteArrayList<>(); - pool.execute(()->{ - // 线程处理数据 - for(Map> item : handleList){ - item.forEach((key,value)->{ - RealStationVo station = new RealStationVo(); - // 站点编码 - station.setStationCode(key); - // 设置站点状态 - this.setStationStatus(alarmList,station,key); - // 名称、限制水位、服务类型、机构、排序 - this.stationParam(stationEntityList,station,deptAll.getData()); - // 根据设备名称分组 - Map> deviceAttbtMap = value.stream().filter(o -> !hideList.contains(o.getEmName())).collect(Collectors.groupingBy(StationAttributeEntity::getEmName)); - List deviceList = new ArrayList<>(); - // device - 设备,arrbt - 设备重点属性 - deviceAttbtMap.forEach((device, attbt) -> { - RealDeviceVo deviceVo = new RealDeviceVo(); - // 设备名称 - deviceVo.setDeviceName(device); - deviceVo.setDeviceCode(attbt.get(0).getEmCode()); - // 设备处理 - this.handleDevice(attbt, map, deviceVo, alertList, faultList); - deviceList.add(deviceVo); - }); - // 设备状态 - this.getDeviceParam(emList, deviceClassifyMap, deviceList); - station.setDeviceList(deviceList.stream().sorted(Comparator.comparing((RealDeviceVo::getDeviceName))).collect(Collectors.toList())); - stationList.add(station); - }); - countDownLatch.countDown(); - } - }); - log.info(thread.getName() + "步骤11线程数据处理 耗时 : {}",System.currentTimeMillis() - beginTime); - beginTime = System.currentTimeMillis(); - // 等待所有线程执行完成 - try { - countDownLatch.await(); - } catch (InterruptedException e) { - e.printStackTrace(); - Thread.currentThread().interrupt(); - } - pool.shutdown(); - log.info(thread.getName() + "步骤12所有线程完成 耗时 : {}",System.currentTimeMillis() - beginTime); - redisTemplate.opsForValue().set(moniter_station_key, stationList); - } - - - /** - * map分割 - * - * @param - * @param - * @param chunkMap - * @return - */ - private List> mapChunk(Map chunkMap) { - if (chunkMap == null || RealMonitorServiceImpl.MAX_SEND <= 0) { - List> list = new ArrayList<>(); - list.add(chunkMap); - return list; - } - Set keySet = chunkMap.keySet(); - Iterator iterator = keySet.iterator(); - int i = 1; - List> total = new ArrayList<>(); - Map tem = new HashMap<>(); - while (iterator.hasNext()) { - k next = iterator.next(); - tem.put(next, chunkMap.get(next)); - if (i == RealMonitorServiceImpl.MAX_SEND) { - total.add(tem); - tem = new HashMap<>(); - i = 0; - } - i++; - } - if (!CollectionUtil.isEmpty(tem)) { - total.add(tem); - } - return total; - } - - - - /** - * 设备参数设置 - * - * @param emList - * @param deviceClassifyMap - * @param deviceList - */ - private void getDeviceParam(List emList, Map> deviceClassifyMap, List deviceList) { - if (CollectionUtil.isEmpty(emList) || CollectionUtil.isEmpty(deviceList) || MapUtils.isEmpty(deviceClassifyMap)) { - return; - } - List faultList = deviceClassifyMap.get(HomePageConstant.FAULT); - List maintaintList = deviceClassifyMap.get(HomePageConstant.MAINTAIN); - List overhaultList = deviceClassifyMap.get(HomePageConstant.OVERHAUL); - List runtList = deviceClassifyMap.get(HomePageConstant.RUN); - List sparetList = deviceClassifyMap.get(HomePageConstant.SPARE); - deviceList.forEach(device -> { - if (StringUtil.isBlank(device.getDeviceCode())) { - device.setState(-1); - return; - } - List list = emList.stream().filter(o -> null != o.getId() && o.getId().toString().equals(device.getDeviceCode())).collect(Collectors.toList()); - if (CollectionUtil.isEmpty(list)) { - device.setState(-1); - return; - } - String deviceCode = list.get(0).getEmCode(); - if (StringUtil.isBlank(deviceCode)) { - device.setState(-1); - return; - } - // 故障 - if (CollectionUtil.isNotEmpty(faultList) && faultList.contains(deviceCode)) { - device.setState(4); - // 保养 - } else if (CollectionUtil.isNotEmpty(maintaintList) && maintaintList.contains(deviceCode)) { - device.setState(3); - // 备用 - } else if (CollectionUtil.isNotEmpty(sparetList) && sparetList.contains(deviceCode)) { - device.setState(2); - // 运行 - } else if (CollectionUtil.isNotEmpty(runtList) && runtList.contains(deviceCode)) { - device.setState(1); - // 检修 - } else if (CollectionUtil.isNotEmpty(overhaultList) && overhaultList.contains(deviceCode)) { - device.setState(0); - // 未知 - } else { - device.setState(-1); - } - }); - } - /** - * 获取所有告警记录 - * - * @return - */ - private List getFdpFaultAll() { - Object json = redisTemplate.opsForValue().get(fdp_fault_data_key); - if (ObjectUtil.isEmpty(json)) { - return new ArrayList<>(); - } - return (List) json; - } - - - - /** - * 设置站点状态 - * @param alarmList - * @param station - * @param key - */ - private void setStationStatus(List alarmList, RealStationVo station, String key) { - station.setStatus(0); - if(alarmList.contains(key)){ - station.setStatus(1); - } - } - - - /** - * 获取站点属性 - * @param stationEntityList - * @param item - */ - private void stationParam(List stationEntityList, RealStationVo item,List deptAll) { - if(CollectionUtil.isEmpty(stationEntityList)){ - return; - } - List filterList = stationEntityList.stream().filter(o->item.getStationCode().equals(o.getCode())).collect(Collectors.toList()); - if(CollectionUtil.isEmpty(filterList)){ - return; - } - StationEntity station = filterList.get(0); - if(ObjectUtil.isEmpty(station)){ - return; - } - item.setStationName(station.getName()); - item.setWaterLevelMax(station.getLimitWaterLevel()); - item.setServerType(station.getServeType()); - item.setStationDeptId(station.getRefDept()); - // 排序 - List list = deptAll.stream().filter(o-> station.getRefDept().equals(o.getId())).collect(Collectors.toList()); - if(CollectionUtil.isEmpty(list)){ - return; - } - item.setSort(list.get(0).getSort()); - } - - - - /** - * 设备处理 - * - * @param list - * @param map - * @param device - */ - private void handleDevice(List list, Map> map, - RealDeviceVo device, List alertList, - List faultList) { - if (CollectionUtil.isEmpty(list) || MapUtils.isEmpty(map)) { - return; - } - List attbtList = new ArrayList<>(); - list.forEach(item -> { - RealAttributeVo realAttributeVo = new RealAttributeVo(); - // 设备重点属性处理 : 单条-item - Map real = map.get(item.getMonitorId()); - if(MapUtils.isEmpty(real)){ - realAttributeVo.setName(item.getAttributes()); - realAttributeVo.setType(item.getAttributeType()); - realAttributeVo.setRealId(item.getMonitorId()); - realAttributeVo.setQuality(-1); - realAttributeVo.setStatus(0); - realAttributeVo.setValue("0"); - realAttributeVo.setUnit(item.getUnit()); - attbtList.add(realAttributeVo); - return; - } - realAttributeVo = handleAttbt(item, real, alertList, faultList); - if (ObjectUtil.isEmpty(realAttributeVo)) { - return; - } - attbtList.add(realAttributeVo); - }); - device.setAttbtList(attbtList); - } - - - /** - * 设备单条重点属性处理 - * - * @param item - * @param real - * @return - */ - private RealAttributeVo handleAttbt(StationAttributeEntity item, Map real, - List alertList, List faultList) { - RealAttributeVo attest = new RealAttributeVo(); - this.setAttbtParam(attest, real); - attest.setRealId(item.getMonitorId()); - attest.setName(item.getAttributes()); - attest.setUnit(item.getUnit()); - attest.setType(item.getAttributeType()); - String value = Optional.ofNullable(attest.getValue()).orElse("-"); - // 正常状态 - attest.setStatus(ConfigStatus.ConfigStatusEnum.NORMAL.getStatus()); - int quality = Optional.ofNullable(attest.getQuality()).orElse(-1); - String time = Optional.ofNullable(attest.getTime()).orElse(""); - // 延时状态 :质量为空 && 时间为空 - if (-1 == quality && StringUtil.isEmpty(time)) { - attest.setStatus(ConfigStatus.ConfigStatusEnum.GRAY.getStatus()); - } - int type = item.getAttributeType(); - switch (type) { - case 1://遥测 - // 预警状态 :value值为"1" && quality值为0 - if ("1".equals(value) && 0 == quality) { - attest.setStatus(ConfigStatus.ConfigStatusEnum.RED.getStatus()); - } - break; - case 2://遥信 - signalyRemote(item, attest, quality, value, alertList); - //处理 - break; - default: - throw new IllegalStateException("Unexpected type: " + type); - } - // 故障信息设置 - accidentDetails(attest, faultList, value); - return attest; - } - - /** - * 故障信息设置 - * - * @param attest - * @param faultList - * @param value - */ - private void accidentDetails(RealAttributeVo attest, List faultList, String value) { - if (CollectionUtil.isEmpty(faultList) || "-".equals(value)) { - return; - } - List fault = faultList.stream().filter(o -> o.getRealId().equals(attest.getRealId())).collect(Collectors.toList()); - if (CollectionUtil.isEmpty(fault)) { - return; - } - FdpFaultStatusVo fdpFaultStatusVo = fault.get(0); - // 黄色 - if (fdpFaultStatusVo.getValue() > greater_than && fdpFaultStatusVo.getValue() < less_than) { - attest.setStatus(ConfigStatus.ConfigStatusEnum.YELLOW.getStatus()); - // 橙色 - } else if (fdpFaultStatusVo.getValue() >= be_equal_or_greater_than) { - attest.setStatus(ConfigStatus.ConfigStatusEnum.ORANGE.getStatus()); - } - attest.setFdpRate(fdpFaultStatusVo.getValue()); - attest.setFdpFaultId(fdpFaultStatusVo.getFaultId()); - attest.setFdpMonitorId(fdpFaultStatusVo.getMonitorId()); - } - - /** - * 重点属性类型-遥信 :数据逻辑处理 - * - * @param attest - */ - private void signalyRemote(StationAttributeEntity item, RealAttributeVo attest, int quality, String strValue, List alertList) { - //需要所有值的数据不为null,并且满足条件才会进去添加数据返回id - if (null == item.getUpUpLimit() || null == item.getDownDownLimit() || null == item.getUpLimit() || null == item.getDownLimit()) { - return; - } - if (-1 == quality) { - return; - } - if (quality != 0) { - return; - } - if ("-".equals(strValue)) { - return; - } - double upup = item.getUpUpLimit(); - double lwlw = item.getDownDownLimit(); - double up = item.getUpLimit(); - double lw = item.getDownLimit(); - //查询出来已处理告警记录 - List handleList = alertList.stream().filter(o -> o.getStationId().equals(item.getStationId()) && o.getRealId().equals(attest.getRealId()) && o.getStatus() == 1).collect(Collectors.toList()); - //查询出来未处理告警记录 - List recordList = alertList.stream().filter(o -> o.getStationId().equals(item.getStationId()) && o.getRealId().equals(attest.getRealId()) && o.getStatus() == 0).collect(Collectors.toList()); - long past = 0L; - double value = Double.parseDouble(strValue); - if (value > upup || value < lwlw) { - if (CollectionUtil.isNotEmpty(handleList)) { - // 现在时间 - 处理时间 - past = System.currentTimeMillis() - handleList.get(0).getProcessTime().getTime(); - } - boolean isOverrun = ((CollectionUtil.isEmpty(handleList) && CollectionUtil.isEmpty(recordList)) || (past / 1000 / 60 > 30 && CollectionUtil.isEmpty(recordList))); - if (isOverrun) { - Long alertId = alertService.insertAlert(item.getStationId(), item.getMonitorId()); - attest.setId(alertId); - attest.setStatus(ConfigStatus.ConfigStatusEnum.YELLOW.getStatus()); - } else if (CollectionUtil.isNotEmpty(recordList)) { - StAlarmRecordEntity record = recordList.get(0); - attest.setId(record.getId()); - // 告警处理完成 - if (record.getProcessTime() != null && record.getStatus() == (byte) 1) { - attest.setStatus(ConfigStatus.ConfigStatusEnum.NORMAL.getStatus()); - // 告警未处理 - } else if (record.getProcessTime() == null && record.getStatus() == (byte) 0) { - attest.setStatus(ConfigStatus.ConfigStatusEnum.HAND_DELAY_STATUS.getStatus()); - } - } - } else if (value > up && value < upup || value < lw && value > lwlw) { - if (CollectionUtil.isNotEmpty(handleList)) { - // 现在时间 - 处理时间 - past = System.currentTimeMillis() - handleList.get(0).getProcessTime().getTime(); - } - boolean exist = ((CollectionUtil.isEmpty(handleList) && CollectionUtil.isEmpty(recordList)) || (past / 1000 / 60 > 30 && CollectionUtil.isEmpty(recordList))); - if (exist){ - Long alertId = alertService.insertAlert(item.getStationId(), item.getMonitorId()); - attest.setId(alertId); - attest.setStatus(ConfigStatus.ConfigStatusEnum.YELLOW.getStatus()); - // 存在告警记录 - } else if (CollectionUtil.isNotEmpty(recordList)) { - StAlarmRecordEntity record = recordList.get(0); - if (recordList.get(0).getStatus() == (byte) 0 && recordList.get(0).getCreateTime() != null) { - attest.setId(record.getId()); - attest.setStatus(ConfigStatus.ConfigStatusEnum.RED.getStatus()); - } else { - attest.setId(recordList.get(0).getId()); - attest.setStatus(ConfigStatus.ConfigStatusEnum.NORMAL.getStatus()); - } - } - } - } - /** - * 设置重点属性参数 - * - * @param attest - * @param real - */ - private void setAttbtParam(RealAttributeVo attest, Map real) { - if (CollectionUtil.isEmpty(real)) { - return; - } - real.forEach((key, value) -> { - if (StringUtil.isBlank(value)) { - return; - } - switch (key) { - case "q": - attest.setQuality(Integer.parseInt(value)); - break; - case "realId": - attest.setRealId(value); - break; - case "value": - attest.setValue(Optional.ofNullable(value).orElse("-")); - break; - case "time": - attest.setTime(value); - break; - } - }); - } -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StAlamRecordServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StAlamRecordServiceImpl.java deleted file mode 100644 index 06d1fd0..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StAlamRecordServiceImpl.java +++ /dev/null @@ -1,42 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.hnac.hzims.operational.config.entity.StAlarmRecordEntity; -import com.hnac.hzims.scheduled.mapper.operation.StAlarmRecordMapper; -import com.hnac.hzims.scheduled.service.StAlamRecordService; -import lombok.RequiredArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.mp.base.BaseServiceImpl; -import org.springframework.stereotype.Service; - -import java.util.Date; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 15:46 - */ -@Service -@RequiredArgsConstructor -@Slf4j -public class StAlamRecordServiceImpl extends BaseServiceImpl implements StAlamRecordService { - - - /** - * 添加告警 - * @param stationId - * @param realId - * @return - */ - @Override - public Long insertAlert(String stationId, String realId) { - StAlarmRecordEntity record = new StAlarmRecordEntity(); - record.setStationId(stationId); - record.setRealId(realId); - record.setStatus(0); - record.setCreateTime(new Date()); - log.info("insert_alert_entity:{}",record); - return this.baseMapper.insertReturnId(record); - } - -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StFocusPropertiesServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StFocusPropertiesServiceImpl.java deleted file mode 100644 index f10b67e..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StFocusPropertiesServiceImpl.java +++ /dev/null @@ -1,164 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.alibaba.fastjson.JSONObject; -import com.alibaba.fastjson.TypeReference; -import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.google.common.collect.Lists; -import com.hnac.hzims.equipment.entity.WorkshopInfoEntity; -import com.hnac.hzims.equipment.feign.IEmInfoClient; -import com.hnac.hzims.equipment.feign.IWorkshopInfoClient; -import com.hnac.hzims.equipment.vo.EminfoAndEmParamVo; -import com.hnac.hzims.operational.config.entity.StFocusPropertiesEntity; -import com.hnac.hzims.operational.main.constant.HomePageConstant; -import com.hnac.hzims.operational.station.entity.StationAttributeEntity; -import com.hnac.hzims.operational.station.entity.StationEntity; -import com.hnac.hzims.scheduled.mapper.operation.StFocusPropertiesMapper; -import com.hnac.hzims.scheduled.service.IStationAttributeService; -import com.hnac.hzims.scheduled.service.IStationService; -import com.hnac.hzims.scheduled.service.StFocusPropertiesService; -import com.hnac.hzims.scheduled.vo.StationRealVo; -import com.hnac.hzinfo.datasearch.analyse.IAnalyseDataSearchClient; -import com.hnac.hzinfo.datasearch.analyse.vo.AnalyzeCodeBySignagesVO; -import com.hnac.hzinfo.sdk.analyse.po.MultiAnalyzeCodePO; -import lombok.RequiredArgsConstructor; -import org.springblade.core.log.logger.BladeLogger; -import org.springblade.core.mp.base.BaseServiceImpl; -import org.springblade.core.tool.api.R; -import org.springblade.core.tool.utils.CollectionUtil; -import org.springblade.core.tool.utils.Func; -import org.springblade.core.tool.utils.ObjectUtil; -import org.springblade.core.tool.utils.StringUtil; -import org.springframework.beans.factory.annotation.Value; -import org.springframework.data.redis.core.RedisTemplate; -import org.springframework.stereotype.Service; - -import java.util.ArrayList; -import java.util.List; -import java.util.Optional; -import java.util.function.Function; -import java.util.stream.Collectors; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 11:27 - */ -@Service -@RequiredArgsConstructor -public class StFocusPropertiesServiceImpl extends BaseServiceImpl implements StFocusPropertiesService { - - - private final IStationService stationService; - - private final IStationAttributeService attbtService; - - private final IEmInfoClient emInfoClient; - - private final IAnalyseDataSearchClient analyseDataSearchClient; - - private final IWorkshopInfoClient workshopInfoClient; - - private final RedisTemplate redisTemplate; - - private final BladeLogger logger; - - @Value("${hzims.operation.monitor.realId}") - public String moniter_realId_key; - - @Value("${hzims.equipment.emInfo.emInfoList}") - public String em_info_list_path; - - @Override - public void getStationRealIds(String param) { - // 所有站点 - List stationList = stationService.getAll(); - if(CollectionUtil.isEmpty(stationList)){ - return; - } - // 设备监测点list - Object json = redisTemplate.opsForValue().get(em_info_list_path); - List eminfoAndEmParams = JSONObject.parseObject(json.toString(), new TypeReference>() {}); - // 厂房监测点list - List wsMonitorList = this.getRealIdByWsCodeAndSign(); - // 实时监控监测点list - List timeList = attbtService.list(new LambdaQueryWrapper() {{ - eq(StationAttributeEntity::getIsDeleted, "0"); - isNotNull(StationAttributeEntity::getMonitorId); - orderByAsc(StationAttributeEntity::getSort); - }}); - // 监测点存储list - List list = new ArrayList<>(); - stationList.forEach(station->{ - StationRealVo stationRealVo = new StationRealVo(); - stationRealVo.setStation(station.getCode()); - List realDeviceList = this.getRealDeviceList(station.getRefDept(),eminfoAndEmParams); - // 厂站匹配站点监测点集合 - List realWsList = wsMonitorList.stream().filter( - o -> Func.isNotEmpty(o.getStation()) && o.getStation().equals(station.getCode()) - ).map(AnalyzeCodeBySignagesVO::getRealId).collect(Collectors.toList()); - // 实时监控匹配站点监测点集合 - List realTimeList = timeList.stream().filter(o -> null != o.getStationId() && o.getStationId().equals(station.getCode())).map(StationAttributeEntity::getMonitorId).collect(Collectors.toList()); - if(CollectionUtil.isNotEmpty(realTimeList)){ - realDeviceList.addAll(realTimeList); - } - if(CollectionUtil.isNotEmpty(realWsList)) { - realDeviceList.addAll(realWsList); - } - if(CollectionUtil.isEmpty(realDeviceList)){ - return; - } - List realList = realDeviceList.stream().distinct().collect(Collectors.toList()); - String[] realArr = StringUtil.join(realList,",").split(","); - stationRealVo.setRealId(realArr); - list.add(stationRealVo); - }); - redisTemplate.opsForValue().set(moniter_realId_key,list); - } - - - - private List getRealIdByWsCodeAndSign() { - R> wsInfoListR = workshopInfoClient.getAllWorkshop(); - List wsInfoList = Optional.ofNullable(wsInfoListR).filter(r -> r.isSuccess() && CollectionUtil.isNotEmpty(wsInfoListR.getData())) - .map(R::getData).orElse(null); - if(CollectionUtil.isEmpty(wsInfoList)) { - return Lists.newArrayList(); - } - Function getAnalyzeCodePO = wsCode -> { - MultiAnalyzeCodePO multiAnalyzeCodePO = new MultiAnalyzeCodePO(); - multiAnalyzeCodePO.setDeviceCode(wsCode); - multiAnalyzeCodePO.setSignages(Lists.newArrayList(HomePageConstant.PV_JOINT_RELAY,HomePageConstant.PV_REACTIVE_POWER,HomePageConstant.PV_GENERATION_CAPACITY)); - return multiAnalyzeCodePO; - }; - List analyzeCodePOList = wsInfoList.stream().map(WorkshopInfoEntity::getNumber).map(getAnalyzeCodePO).collect(Collectors.toList()); - R> analyzeCodeBySignages = analyseDataSearchClient.getAnalyzeCodeBySignages(analyzeCodePOList); - return Optional.ofNullable(analyzeCodeBySignages).filter(r -> r.isSuccess()).map(R::getData).orElse(Lists.newArrayList()); - } - - - - /** - * 获取站点realId - * @param refDept - * @param eminfoAndEmParams - * @return - */ - private List getRealDeviceList(Long refDept, List eminfoAndEmParams) { - // 参数检查 - if(CollectionUtil.isEmpty(eminfoAndEmParams) || ObjectUtil.isEmpty(refDept)){ - return new ArrayList<>(); - } - // 有效设备 - List filters = eminfoAndEmParams.stream().filter(o-> o.getCreateDept().equals(refDept)).collect(Collectors.toList()); - if(CollectionUtil.isEmpty(filters)){ - return new ArrayList<>(); - } - // 遍历设备 - List result = new ArrayList<>(); - for(EminfoAndEmParamVo device : filters){ - result.addAll(device.getPoint().values()); - } - return result; - } -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationAttrConfigServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationAttrConfigServiceImpl.java deleted file mode 100644 index 58bd475..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationAttrConfigServiceImpl.java +++ /dev/null @@ -1,42 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; -import com.hnac.hzims.operational.station.entity.StationAttrConfigEntity; -import com.hnac.hzims.scheduled.mapper.operation.StationAttrConfigMapper; -import com.hnac.hzims.scheduled.service.IStationAttrConfigService; -import lombok.AllArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.mp.base.BaseServiceImpl; -import org.springblade.core.tool.utils.CollectionUtil; -import org.springframework.stereotype.Service; - -import java.util.ArrayList; -import java.util.List; -import java.util.stream.Collectors; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 16:07 - */ -@Service -@Slf4j -@AllArgsConstructor -public class StationAttrConfigServiceImpl extends BaseServiceImpl - implements IStationAttrConfigService { - - - @Override - public List getHideList() { - List list = this.list(new QueryWrapper() {{ - eq("ENABLE_SHOW", false); - eq("IS_DELETED",0); - }}); - if(CollectionUtil.isEmpty(list)){ - return new ArrayList<>(); - } - return list.stream().map(StationAttrConfigEntity::getEmName).collect(Collectors.toList()); - } - -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationAttributeServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationAttributeServiceImpl.java deleted file mode 100644 index ae6cc6c..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationAttributeServiceImpl.java +++ /dev/null @@ -1,22 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.hnac.hzims.operational.station.entity.StationAttributeEntity; -import com.hnac.hzims.scheduled.mapper.operation.StationAttributeMapper; -import com.hnac.hzims.scheduled.service.IStationAttributeService; -import lombok.RequiredArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.mp.base.BaseServiceImpl; -import org.springframework.stereotype.Service; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 11:39 - */ -@Service -@Slf4j -@RequiredArgsConstructor -public class StationAttributeServiceImpl extends BaseServiceImpl implements IStationAttributeService { - -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationServiceImpl.java deleted file mode 100644 index 7490ba6..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/StationServiceImpl.java +++ /dev/null @@ -1,60 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.hnac.hzims.operational.station.entity.StationEntity; -import com.hnac.hzims.scheduled.mapper.operation.StationMapper; -import com.hnac.hzims.scheduled.service.IStationService; -import lombok.RequiredArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.mp.base.BaseServiceImpl; -import org.springblade.core.tool.utils.CollectionUtil; -import org.springblade.core.tool.utils.ObjectUtil; -import org.springframework.stereotype.Service; - -import java.util.List; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 10:36 - */ -@Service -@RequiredArgsConstructor -@Slf4j -public class StationServiceImpl extends BaseServiceImpl implements IStationService { - - @Override - public List getStationByType(Integer stationType, Integer serveType) { - return this.baseMapper.selectStationByType(stationType, serveType); - } - - @Override - public List getAll() { - return this.baseMapper.selectAll(); - } - - - @Override - public List getStationByInCode(List codes) { - return this.baseMapper.selectStationByInCode(codes); - } - - - - @Override - public List getStationType(Integer serveType, List typeList, List departIdList) { - return this.list(new LambdaQueryWrapper() {{ - eq(StationEntity::getIsDeleted, 0); - if (ObjectUtil.isNotEmpty(serveType)) { - eq(StationEntity::getServeType, serveType); - } - if (CollectionUtil.isNotEmpty(typeList)) { - in(StationEntity::getType, typeList); - } - if (CollectionUtil.isNotEmpty(departIdList)) { - in(StationEntity::getRefDept, departIdList); - } - }}); - } -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/WaterServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/WaterServiceImpl.java deleted file mode 100644 index 0218fe0..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/impl/WaterServiceImpl.java +++ /dev/null @@ -1,201 +0,0 @@ -package com.hnac.hzims.scheduled.service.impl; - -import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.hnac.hzims.EquipmentConstants; -import com.hnac.hzims.operational.main.constant.HomePageConstant; -import com.hnac.hzims.operational.main.vo.WaterLevelVo; -import com.hnac.hzims.operational.station.entity.HzimsAnalyzeModelStationEntity; -import com.hnac.hzims.operational.station.entity.StationEntity; -import com.hnac.hzims.scheduled.service.IHzimsAnalyzeModelStationService; -import com.hnac.hzims.scheduled.service.IStationService; -import com.hnac.hzims.scheduled.service.IWaterService; -import com.hnac.hzinfo.datasearch.analyse.IAnalyseDataSearchClient; -import com.hnac.hzinfo.datasearch.analyse.domain.FieldsData; -import com.hnac.hzinfo.datasearch.analyse.po.AnalyseCodeByAnalyseDataPO; -import com.hnac.hzinfo.datasearch.analyse.po.AnalyzeDataConditionPO; -import com.hnac.hzinfo.datasearch.analyse.vo.AnalyzeCodeBySignagesVO; -import com.hnac.hzinfo.datasearch.analyse.vo.AnalyzeDataConditionVO; -import com.hnac.hzinfo.datasearch.real.po.RealDataSearchPO; -import com.hnac.hzinfo.sdk.analyse.po.MultiAnalyzeCodePO; -import lombok.RequiredArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.springblade.core.tool.api.R; -import org.springblade.core.tool.utils.CollectionUtil; -import org.springblade.core.tool.utils.DateUtil; -import org.springblade.core.tool.utils.StringUtil; -import org.springframework.beans.factory.annotation.Value; -import org.springframework.data.redis.core.RedisTemplate; -import org.springframework.stereotype.Service; - -import java.time.LocalDateTime; -import java.util.*; -import java.util.stream.Collectors; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/22 11:23 - */ -@Service -@RequiredArgsConstructor -@Slf4j -public class WaterServiceImpl implements IWaterService { - - - private final IStationService stationService; - - - private final IHzimsAnalyzeModelStationService modelStationService; - - - - private final IAnalyseDataSearchClient analyseDataSearchClient; - - - - private final RedisTemplate redisTemplate; - - - - private final static String loadwater_level_key = "hzims:operation:loadwater:level:key"; - /** - * 水利-站点水位数据 - * @param param - */ - @Override - public void loadWaterLevel(String param) { - // 有效站点模型 - List modelList = getModelStationList(); - if(CollectionUtil.isEmpty(modelList)){ - return; - } - List list = new ArrayList<>(); - modelList.forEach(item -> { - List multiAnalyzeCodePOList = new ArrayList<>(); - MultiAnalyzeCodePO multiAnalyzeCodePO = new MultiAnalyzeCodePO(); - multiAnalyzeCodePO.setDeviceCode(item.getInstanceCode()); - multiAnalyzeCodePO.setSignages(Collections.singletonList(HomePageConstant.FRONT_WATER_LEVEL)); - multiAnalyzeCodePOList.add(multiAnalyzeCodePO); - R> result = analyseDataSearchClient.getAnalyzeCodeBySignages(multiAnalyzeCodePOList); - if(!result.isSuccess() || CollectionUtil.isEmpty(result.getData())){ - return; - } - WaterLevelVo waterLevelVo = new WaterLevelVo(); - waterLevelVo.setStationCode(item.getStationId()); - // 前水位 - double frontWaterLevel = this.getWaterLevel(item.getInstanceCode(),HomePageConstant.FRONT_WATER_LEVEL); - waterLevelVo.setFrontWaterLevel(frontWaterLevel); - // 后水位 - double rearWaterLevel = this.getWaterLevel(item.getInstanceCode(),HomePageConstant.REAR_WATER_LEVEL); - waterLevelVo.setRearWaterLevel(rearWaterLevel); - // 前水位当日曲线 - Map frontCurveMap = this.getWaterLevelMap(item.getInstanceCode(),HomePageConstant.FRONT_WATER_LEVEL); - waterLevelVo.setFrontCurveMap(frontCurveMap); - // 后水位当日曲线 - Map rearCurveMap = this.getWaterLevelMap(item.getInstanceCode(),HomePageConstant.REAR_WATER_LEVEL); - waterLevelVo.setRearCurveMap(rearCurveMap); - list.add(waterLevelVo); - }); - redisTemplate.opsForValue().set(loadwater_level_key,list); - } - - - /** - * 获取水位实时数据 - * @param instanceCode - * @param signage - * @return - */ - private double getWaterLevel(String instanceCode, String signage) { - RealDataSearchPO realData = new RealDataSearchPO(); - realData.setAnalyzeCode(instanceCode); - List signages = Collections.singletonList(signage); - realData.setSignages(signages); - // 调用fegin接口查询实时数据 - R> R = analyseDataSearchClient.getRealDataByAnalyzeCode(realData); - if(!R.isSuccess() || CollectionUtil.isEmpty(R.getData())){ - return 0.0; - } - // 时间限制 - String time = R.getData().get(0).getTime(); - if(StringUtil.isEmpty(time) || "-".equals(time)){ - return 0.0; - } - Date date = DateUtil.parse(time, "yyyy-MM-dd HH:mm:ss.sss"); - if(System.currentTimeMillis() - date.getTime() > 30 * 60 * 1000L){ - return 0.0; - } - return Double.parseDouble(R.getData().get(0).getValue()); - } - - - - /** - * 获取水位当年数据 - * @param instanceCode - * @param signage - * @return - */ - private Map getWaterLevelMap(String instanceCode, String signage) { - LocalDateTime beginTime = LocalDateTime.parse(DateUtil.format(new Date(), "yyyy-MM-dd 00:00:00"), DateUtil.DATETIME_FORMATTER); - LocalDateTime endTime = LocalDateTime.now(); - AnalyseCodeByAnalyseDataPO po = new AnalyseCodeByAnalyseDataPO(); - List signboardConditions = new ArrayList<>(); - AnalyzeDataConditionPO analyzeDataConditionPO = new AnalyzeDataConditionPO(); - analyzeDataConditionPO.setFull(1); - analyzeDataConditionPO.setSignages(signage); - // 取数规则: 0=(整点值/最早值)、1=最大值、2=最小值、3=平均值、4=(累计值/和值)、5=(变化值/差值) 6=最新值 - analyzeDataConditionPO.setAccessRules(EquipmentConstants.AccessRulesEnum.FINAL_CYCLE.getType()); - // 周期类型: 0-> s(秒) 1->、m(分)、2->h(小时)3->、d(天)4->、w(周)5->、n(自然月)、6->y(自然年) - analyzeDataConditionPO.setSaveTimeType(2); - // 间隔 - analyzeDataConditionPO.setTimeInterval(1); - analyzeDataConditionPO.setBeginTime(beginTime); - analyzeDataConditionPO.setEndTime(endTime); - signboardConditions.add(analyzeDataConditionPO); - po.setDeviceCode(instanceCode); - po.setSignboardConditions(signboardConditions); - R> R = analyseDataSearchClient.getAnalyzeDataByAnalyzeCodeAndSignages(po); - if(!R.isSuccess() || CollectionUtil.isEmpty(R.getData())){ - return null; - } - if(CollectionUtil.isEmpty(R.getData().get(0).getList())){ - return null; - } - return R.getData().get(0).getList().stream().collect(Collectors.toMap(key-> { - Date dateTime = DateUtil.parse(key.getTs(), "yyyy-MM-dd HH:mm:ss.s"); - return dateTime.getHours(); - }, value -> { - if(StringUtil.isBlank(value.getVal())){ - return "0"; - } - return value.getVal(); - })); - } - - /** - * 获取有效站点模型 - * @return - */ - private List getModelStationList() { - // 水利站点(All) - List stationList = stationService.getStationType(HomePageConstant.HYDROPOWER_SERVETYPE, null, null); - if(CollectionUtil.isEmpty(stationList)){ - return null; - } - // 站点code集合 - List codes = stationList.stream().map(StationEntity::getCode).collect(Collectors.toList()); - if(CollectionUtil.isEmpty(codes)){ - return null; - } - // 查询站点模型列表 - List list = modelStationService.list(new LambdaQueryWrapper() {{ - in(HzimsAnalyzeModelStationEntity::getStationId, codes); - }}); - if(CollectionUtil.isEmpty(list)){ - return null; - } - return list; - } -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AbnormalAlarmService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AbnormalAlarmService.java new file mode 100644 index 0000000..53997ff --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AbnormalAlarmService.java @@ -0,0 +1,15 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.alert.entity.AbnormalAlarmEntity; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * 告警处理接口 + * @author ysj + */ +public interface AbnormalAlarmService extends BaseService { + + List abnormalAlarms(); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AnalyseDataService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AnalyseDataService.java new file mode 100644 index 0000000..7f2fb5c --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AnalyseDataService.java @@ -0,0 +1,22 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzinfo.datasearch.analyse.vo.AnalyseDataTaosVO; +import com.hnac.hzinfo.datasearch.analyse.vo.AnalyzeCodeBySignagesVO; +import com.hnac.hzinfo.sdk.analyse.po.MultiAnalyzeCodePO; + +import java.util.List; +import java.util.function.Function; + + +/** + * @author ysj + */ +public interface AnalyseDataService { + + List getAnalyzeCodeBySignages(Function convert, T resource); + + + List periodTargetData(String startTime, String endTime, Integer accessRules, Integer cycleType, String deviceCode, String signages); + + Float periodTargetFloat(String startTime, String endTime, Integer accessRules, Integer cycleType, String deviceCode, Integer ride ,String signages); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/GenerateService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/GenerateService.java new file mode 100644 index 0000000..8f9e1b1 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/GenerateService.java @@ -0,0 +1,25 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.fill.entity.GenerateEntity; +import com.hnac.hzims.operational.main.vo.GenerationPowerVo; +import com.hnac.hzims.operational.main.vo.PowerMonthVo; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * @author ysj + * @date 2023/04/10 11:16:07 + * @version 4.0.0 + */ +public interface GenerateService extends BaseService { + + // 查询填报用电量 + Float generate(String date,String station); + + // 查询30天填报用电量 + List generate30Day(String day, String station); + + // 获取站点填报发电量 + List generateThreeYear(String start, String end, String station); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ModelStationService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ModelStationService.java new file mode 100644 index 0000000..e8e4560 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ModelStationService.java @@ -0,0 +1,12 @@ +package com.hnac.hzims.scheduled.service.operation; + + +import com.hnac.hzims.operational.station.entity.HzimsAnalyzeModelStationEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author ysj + */ +public interface ModelStationService extends BaseService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java new file mode 100644 index 0000000..087a7e5 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java @@ -0,0 +1,16 @@ +package com.hnac.hzims.scheduled.service.operation; + +/** + * WEB水电站首页接口 + * @author ysj + */ +public interface MonitorService { + + // realId刷新 + void loadRealId(String param); + + // 集中监控数据处理 + void loadMonitoring(String param); + + void loadRealData(String param); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/PowerService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/PowerService.java new file mode 100644 index 0000000..d6d3007 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/PowerService.java @@ -0,0 +1,17 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.fill.entity.PowerEntity; +import com.hnac.hzims.operational.main.vo.PowerMonthVo; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * @author ysj + */ +public interface PowerService extends BaseService { + + Double generate(String date,Long station); + + List generateThreeYear(String start,String end,Long station); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/RealTargetService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/RealTargetService.java new file mode 100644 index 0000000..43afd9e --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/RealTargetService.java @@ -0,0 +1,34 @@ +package com.hnac.hzims.scheduled.service.operation; + +import java.util.List; + +/** + * WEB水电站首页接口 + * @author ysj + */ +public interface RealTargetService { + + // 水电站实时数据加载 + void loadHydropowerReal(String param); + + // 水电站指标数据加载 + void loadHydropowerTarget(String param); + + // 泵站实时数据加载 + void loadWaterPumpReal(String param); + + // 泵站指标数据加载 + void loadWaterPumpTarget(String param); + + // 站点水位指标数据 + void loadWaterLevel(String param); + + // 光伏站实时数据加载 + void loadPhotovoltaicReal(String param); + + // 光伏站指标数据加载 + void loadPhotovoltaicTarget(String param); + + // 光伏、水电站近3年发电量 + void loadPowerData(String param, List types, Integer serveType, int year); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/RecordService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/RecordService.java new file mode 100644 index 0000000..00da41d --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/RecordService.java @@ -0,0 +1,13 @@ +package com.hnac.hzims.scheduled.service.operation; + + +import com.hnac.hzims.operational.config.entity.StAlarmRecordEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author ysj + */ +public interface RecordService extends BaseService { + + Long insertAlert(String stationId, String monitorId); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationAttrConfigService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationAttrConfigService.java new file mode 100644 index 0000000..47dce3f --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationAttrConfigService.java @@ -0,0 +1,14 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.station.entity.StationAttrConfigEntity; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * @author ysj + */ +public interface StationAttrConfigService extends BaseService { + + List getHideList(); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationAttributeService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationAttributeService.java new file mode 100644 index 0000000..53479ba --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationAttributeService.java @@ -0,0 +1,14 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.station.entity.StationAttributeEntity; +import org.springblade.core.mp.base.BaseService; + +import java.util.Map; + +/** + * @author hx + */ +public interface StationAttributeService extends BaseService { + + Map PointUnit(); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationService.java new file mode 100644 index 0000000..2757282 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/StationService.java @@ -0,0 +1,12 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.station.entity.StationEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author ysj + */ +public interface StationService extends BaseService { + + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/UseService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/UseService.java new file mode 100644 index 0000000..72dc927 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/UseService.java @@ -0,0 +1,29 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.hnac.hzims.operational.fill.entity.UseEntity; +import com.hnac.hzims.operational.fill.vo.QueryVo; +import com.hnac.hzims.operational.fill.vo.UseVo; +import com.hnac.hzims.operational.main.vo.UsrPowerVo; +import org.springblade.core.mp.base.BaseService; +import org.springblade.core.mp.support.Query; +import org.springblade.core.tool.api.R; + +import java.util.List; +import java.util.Map; + +/** + * @author ysj + * @date 2023/04/10 11:16:07 + * @version 4.0.0 + */ +public interface UseService extends BaseService { + + // 查询填报用电量 + Float use(String date,String station); + + // 查询30天填报用电量 + List use30Day(String day, String station); + + Map generateThreeYear(String start, String end, String station); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AbnormalAlarmServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AbnormalAlarmServiceImpl.java new file mode 100644 index 0000000..fa8ef8a --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AbnormalAlarmServiceImpl.java @@ -0,0 +1,33 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.hnac.hzims.operational.alert.entity.AbnormalAlarmEntity; +import com.hnac.hzims.scheduled.mapper.operation.AbnormalAlarmMapper; +import com.hnac.hzims.scheduled.service.operation.AbnormalAlarmService; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springframework.stereotype.Service; + +import java.util.ArrayList; +import java.util.List; + +/** + * 告警实现类 + * @author ysj + */ +@Slf4j +@Service +@RequiredArgsConstructor +public class AbnormalAlarmServiceImpl extends BaseServiceImpl implements AbnormalAlarmService { + + + @Override + public List abnormalAlarms() { + List alarmList = this.baseMapper.abnormalAlarms(); + if(CollectionUtil.isEmpty(alarmList)){ + return new ArrayList<>(); + } + return alarmList; + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AnalyseDataServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AnalyseDataServiceImpl.java new file mode 100644 index 0000000..b469c8a --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AnalyseDataServiceImpl.java @@ -0,0 +1,139 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.google.common.collect.Lists; +import com.hnac.hzims.scheduled.service.operation.AnalyseDataService; +import com.hnac.hzinfo.datasearch.analyse.IAnalyseDataSearchClient; +import com.hnac.hzinfo.datasearch.analyse.po.AnalyseCodeByAnalyseDataPO; +import com.hnac.hzinfo.datasearch.analyse.po.AnalyzeDataConditionPO; +import com.hnac.hzinfo.datasearch.analyse.vo.AnalyseDataTaosVO; +import com.hnac.hzinfo.datasearch.analyse.vo.AnalyzeCodeBySignagesVO; +import com.hnac.hzinfo.datasearch.analyse.vo.AnalyzeDataConditionVO; +import com.hnac.hzinfo.sdk.analyse.po.MultiAnalyzeCodePO; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.ObjectUtil; +import org.springblade.core.tool.utils.StringUtil; +import org.springframework.stereotype.Service; + +import java.time.LocalDateTime; +import java.time.format.DateTimeFormatter; +import java.util.ArrayList; +import java.util.Date; +import java.util.List; +import java.util.Optional; +import java.util.function.Function; +import java.util.stream.Collectors; + +/** + * @author hx + */ +@Service +@AllArgsConstructor +@Slf4j +public class AnalyseDataServiceImpl implements AnalyseDataService { + + private final IAnalyseDataSearchClient analyseDataSearchClient; + + @Override + public List getAnalyzeCodeBySignages(Function convert, T resource) { + List result = Lists.newArrayList(); + List multiAnalyzeCodePOList = Lists.newArrayList(resource).stream().map(convert).collect(Collectors.toList()); + R> analyzeCodeBySignResult = analyseDataSearchClient.getAnalyzeCodeBySignages(multiAnalyzeCodePOList); + if(analyzeCodeBySignResult.isSuccess() && CollectionUtil.isNotEmpty(analyzeCodeBySignResult.getData())) { + result = analyzeCodeBySignResult.getData(); + } + return result; + } + + /*** + * 指标数据列表查询 + * @param startTime 开始时间 + * @param endTime 结束时间 + * @param accessRules 取数规则 : 0=最早值 1=最大值 2=最小值 3=平均值 4=和值 5=差值 6=最新值 + * @param cycleType 间隔周期 : 0-> 秒 1-> 分 2-> 小时 3->天 4-> 周 5-> 月 6-> 年 + * @param deviceCode 设备编号 + * @param signages 指标 + * @return + */ + @Override + public List periodTargetData(String startTime, String endTime, Integer accessRules, Integer cycleType, String deviceCode, String signages) { + AnalyseCodeByAnalyseDataPO po = new AnalyseCodeByAnalyseDataPO(); + List signboardConditions = new ArrayList<>(); + AnalyzeDataConditionPO analyzeDataConditionPO = new AnalyzeDataConditionPO(); + analyzeDataConditionPO.setFull(1); + po.setDeviceCode(deviceCode); + analyzeDataConditionPO.setSignages(signages); + analyzeDataConditionPO.setKeepFigures(2); + analyzeDataConditionPO.setAccessRules(accessRules); + analyzeDataConditionPO.setSaveTimeType(cycleType); + // 间隔 + analyzeDataConditionPO.setTimeInterval(1); + analyzeDataConditionPO.setBeginTime(LocalDateTime.parse(DateUtil.format(new Date(), startTime), DateTimeFormatter.ofPattern(DateUtil.PATTERN_DATETIME))); + analyzeDataConditionPO.setEndTime(LocalDateTime.parse(DateUtil.format(new Date(), endTime), DateTimeFormatter.ofPattern(DateUtil.PATTERN_DATETIME))); + signboardConditions.add(analyzeDataConditionPO); + po.setSignboardConditions(signboardConditions); + log.error("period_target_data_request {}",po); + R> result = analyseDataSearchClient.getAnalyzeDataByAnalyzeCodeAndSignages(po); + if (!result.isSuccess() || CollectionUtil.isEmpty(result.getData())) { + return new ArrayList<>(); + } + log.error("period_target_data_resp {}",result); + return result.getData().get(0).getList(); + } + + /*** + * 指标数据列表查询 + * @param startTime 开始时间 + * @param endTime 结束时间 + * @param accessRules 取数规则 : 0=最早值 1=最大值 2=最小值 3=平均值 4=和值 5=差值 6=最新值 + * @param cycleType 间隔周期 : 0-> 秒 1-> 分 2-> 小时 3->天 4-> 周 5-> 月 6-> 年 + * @param deviceCode 设备编号 + * @param ride 配电比 + * @param signages 指标 + * @return + */ + @Override + public Float periodTargetFloat(String startTime, String endTime, Integer accessRules, Integer cycleType, String deviceCode,Integer ride,String signages) { + AnalyseCodeByAnalyseDataPO po = new AnalyseCodeByAnalyseDataPO(); + List signboardConditions = new ArrayList<>(); + AnalyzeDataConditionPO analyzeDataConditionPO = new AnalyzeDataConditionPO(); + analyzeDataConditionPO.setFull(1); + po.setDeviceCode(deviceCode); + analyzeDataConditionPO.setSignages(signages); + analyzeDataConditionPO.setKeepFigures(2); + analyzeDataConditionPO.setAccessRules(accessRules); + analyzeDataConditionPO.setSaveTimeType(cycleType); + // 间隔 + analyzeDataConditionPO.setTimeInterval(1); + analyzeDataConditionPO.setBeginTime(LocalDateTime.parse(DateUtil.format(new Date(), startTime), DateTimeFormatter.ofPattern(DateUtil.PATTERN_DATETIME))); + analyzeDataConditionPO.setEndTime(LocalDateTime.parse(DateUtil.format(new Date(), endTime), DateTimeFormatter.ofPattern(DateUtil.PATTERN_DATETIME))); + signboardConditions.add(analyzeDataConditionPO); + po.setSignboardConditions(signboardConditions); + R> result = analyseDataSearchClient.getAnalyzeDataByAnalyzeCodeAndSignages(po); + if (!result.isSuccess() || CollectionUtil.isEmpty(result.getData())) { + return 0f; + } + List records = result.getData(); + if(CollectionUtil.isEmpty(records)){ + return 0f; + } + AnalyzeDataConditionVO analyzeDataConditionVO = records.get(0); + if (ObjectUtil.isEmpty(analyzeDataConditionVO)) { + return 0f; + } + List analyseDataTaosVOList = analyzeDataConditionVO.getList(); + if (CollectionUtil.isEmpty(analyseDataTaosVOList)) { + return 0f; + } + AnalyseDataTaosVO analyseDataTaosVO = analyzeDataConditionVO.getList().get(0); + if (ObjectUtil.isEmpty(analyseDataTaosVO) || StringUtil.isBlank(analyseDataTaosVO.getVal())) { + return 0f; + } + return Float.parseFloat(Optional.ofNullable(analyseDataTaosVO.getVal()).orElse("0")) * ride; + } + + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/GenerateServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/GenerateServiceImpl.java new file mode 100644 index 0000000..470f95e --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/GenerateServiceImpl.java @@ -0,0 +1,112 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.hnac.hzims.operational.fill.entity.GenerateEntity; +import com.hnac.hzims.operational.main.vo.GenerationPowerVo; +import com.hnac.hzims.operational.main.vo.PowerMonthVo; +import com.hnac.hzims.scheduled.mapper.operation.GenerateMapper; +import com.hnac.hzims.scheduled.service.operation.GenerateService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.DateUtil; +import org.springframework.stereotype.Service; + +import java.util.ArrayList; +import java.util.Calendar; +import java.util.List; +import java.util.stream.Collectors; + +/** + * @author ysj + * @date 2023/04/10 11:16:07 + * @version 4.0.0 + */ +@Slf4j +@Service +@AllArgsConstructor +public class GenerateServiceImpl extends BaseServiceImpl implements GenerateService { + + /** + * 根据时间、机构查询用电量 + * @param date 时间: 年 - yyyy/月 yyyy-mm/日 yyyy-mm-dd + * @param station 所属机构 + * @return + */ + @Override + public Float generate(String date, String station) { + List powers = this.list(Wrappers.lambdaQuery() + .likeRight(GenerateEntity::getFillDate,date) + .eq(GenerateEntity::getStationCode,station) + ); + if(CollectionUtil.isEmpty(powers)){ + return 0f; + } + return (float) powers.stream().mapToDouble(GenerateEntity::getGenerate).sum(); + } + + /** + * 查询30天填报用电量 + * @param day : 结束日期 yyyy-MM-dd + * @param station 站点编码 + * @return + */ + @Override + public List generate30Day(String day, String station) { + Calendar calendar = Calendar.getInstance(); + calendar.setTime(DateUtil.parse(day,DateUtil.PATTERN_DATE)); + String end = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + calendar.add(Calendar.DAY_OF_MONTH,-29); + String start = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + List records = this.list(Wrappers.lambdaQuery() + .between(GenerateEntity::getFillDate,start,end) + .eq(GenerateEntity::getStationCode,station) + ); + if(CollectionUtil.isEmpty(records)){ + return new ArrayList<>(); + } + return records.stream().map(record->{ + GenerationPowerVo generate = new GenerationPowerVo(); + generate.setDate(record.getFillDate()); + if(Math.abs(record.getGenerate()) <= 0){ + generate.setGenerate(0f); + }else{ + generate.setGenerate(Float.parseFloat(record.getGenerate().toString())); + } + return generate; + }).collect(Collectors.toList()); + } + + /** + * + * @param start 时间: 年 - yyyy/月 yyyy-mm/日 yyyy-mm-dd + * @param end 时间: 年 - yyyy/月 yyyy-mm/日 yyyy-mm-dd + * @param station 站点编码 + * @return + */ + @Override + public List generateThreeYear(String start, String end, String station) { + List records = this.list(Wrappers.lambdaQuery() + .eq(GenerateEntity::getStationCode,station) + .between(GenerateEntity::getFillDate,start,end) + ); + if(CollectionUtil.isEmpty(records)){ + return new ArrayList<>(); + } + // 返回结果 + return records.stream().peek( + record-> record.setFillDate(DateUtil.format(DateUtil.parse(record.getFillDate(),"yyyy-MM"),"yyyy-MM") + "-01") + ).collect(Collectors.toMap(GenerateEntity::getFillDate,GenerateEntity::getGenerate,Double::sum)). + entrySet().stream().map(entry->{ + PowerMonthVo mon = new PowerMonthVo(); + mon.setStrMonth(entry.getKey()); + if(Math.abs(entry.getValue()) <= 0){ + mon.setPower(0f); + }else{ + mon.setPower(Float.parseFloat(entry.getValue().toString())); + } + return mon; + }).collect(Collectors.toList()); + } +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ModelStationServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ModelStationServiceImpl.java new file mode 100644 index 0000000..946fdab --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ModelStationServiceImpl.java @@ -0,0 +1,16 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + + +import com.hnac.hzims.operational.station.entity.HzimsAnalyzeModelStationEntity; +import com.hnac.hzims.scheduled.mapper.operation.ModelStationMapper; +import com.hnac.hzims.scheduled.service.operation.ModelStationService; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author ysj + */ +@Service +public class ModelStationServiceImpl extends BaseServiceImpl implements ModelStationService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MonitorServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MonitorServiceImpl.java new file mode 100644 index 0000000..06145f6 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MonitorServiceImpl.java @@ -0,0 +1,744 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.alibaba.fastjson.JSONObject; +import com.alibaba.fastjson.TypeReference; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.google.common.collect.Lists; +import com.google.common.util.concurrent.ThreadFactoryBuilder; +import com.hnac.hzims.equipment.entity.WorkshopInfoEntity; +import com.hnac.hzims.equipment.vo.EminfoAndEmParamVo; +import com.hnac.hzims.fdp.vo.FdpFaultStatusVo; +import com.hnac.hzims.operational.config.entity.StAlarmRecordEntity; +import com.hnac.hzims.operational.config.enume.ConfigStatus; +import com.hnac.hzims.operational.config.vo.StationRealVo; +import com.hnac.hzims.operational.main.constant.HomePageConstant; +import com.hnac.hzims.operational.main.vo.RealAttributeVo; +import com.hnac.hzims.operational.main.vo.RealDeviceVo; +import com.hnac.hzims.operational.main.vo.RealStationVo; +import com.hnac.hzims.operational.station.entity.StationAttributeEntity; +import com.hnac.hzims.operational.station.entity.StationEntity; +import com.hnac.hzims.scheduled.service.equipment.WorkshopInfoService; +import com.hnac.hzims.scheduled.service.operation.*; +import com.hnac.hzinfo.datasearch.analyse.IAnalyseDataSearchClient; +import com.hnac.hzinfo.datasearch.analyse.vo.AnalyzeCodeBySignagesVO; +import com.hnac.hzinfo.sdk.analyse.po.MultiAnalyzeCodePO; +import com.hnac.hzinfo.sdk.v5.redis.RedisClient; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.collections4.MapUtils; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.*; +import org.springblade.system.entity.Dept; +import org.springblade.system.feign.ISysClient; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.data.redis.core.RedisTemplate; +import org.springframework.stereotype.Service; + +import java.util.*; +import java.util.concurrent.*; +import java.util.function.Function; +import java.util.stream.Collectors; +import java.util.stream.Stream; + +/** + * 集中监控数据获取实现类 + * @author ysj + */ +@Service +@RequiredArgsConstructor +@Slf4j +public class MonitorServiceImpl implements MonitorService { + + private final RecordService alertService; + private final StationService stationService; + private final StationAttributeService attbtService; + private final WorkshopInfoService workshopInfoService; + private final AbnormalAlarmService abnormalAlarmService; + private final StationAttrConfigService attrConfigService; + private final RedisTemplate redisTemplate; + private final ISysClient sysClient; + private final RedisClient redisClient; + private final IAnalyseDataSearchClient analyseDataSearchClient; + + @Value("${hzims.equipment.emInfo.emInfoList}") + public String device_cache_final; + + @Value("${hzims.operation.realIdKey}") + public String real_cache_final; + + @Value("${hzims.operation.realIdKeyGather}") + public String real_gather_cache_final; + + @Value("${hzims.operation.realIdKeyGather}") + public String real_data_cache_final; + + @Value("${hzims.equipment.fdp.redisData}") + public String fdp_fault_cache_final; + + @Value("${hzims.equipment.fdp.lessThan}") + public Double less_than_cache_final; + + @Value("${hzims.equipment.fdp.greaterThan}") + public Double greater_than_cache_final; + + @Value("${hzims.operation.monitor.realId}") + public String moniter_realId_cache_final; + + @Value("${hzims.operation.monitor.station}") + public String moniter_station_cache_final; + + @Value("${hzims.equipment.fdp.beEqualOrGreaterThan}") + public Double be_equa_cache_final; + + @Value("${hzims.operation.region.deviceClassifyKey}") + private String device_classify_cache_final; + + @Override + public void loadRealId(String param) { + // 所有站点 + List stationList = stationService.list(); + if(CollectionUtil.isEmpty(stationList)){ + return; + } + // 设备监测点list + Object json = redisTemplate.opsForValue().get(device_cache_final); + List eminfoAndEmParams = JSONObject.parseObject(json.toString(), new TypeReference>() {}); + // 厂房监测点list + List wsMonitorList = this.getRealIdByWsCodeAndSign(); + // 实时监控监测点list + List timeList = attbtService.list(new LambdaQueryWrapper() {{ + eq(StationAttributeEntity::getIsDeleted, "0"); + isNotNull(StationAttributeEntity::getMonitorId); + orderByAsc(StationAttributeEntity::getSort); + }}); + // 监测点存储list + List list = new ArrayList<>(); + stationList.forEach(station->{ + StationRealVo stationRealVo = new StationRealVo(); + stationRealVo.setStation(station.getCode()); + List realDeviceList = this.getRealDeviceList(station.getRefDept(),eminfoAndEmParams); + // 厂站匹配站点监测点集合 + List realWsList = wsMonitorList.stream().filter( + o -> Func.isNotEmpty(o.getStation()) && o.getStation().equals(station.getCode()) + ).map(AnalyzeCodeBySignagesVO::getRealId).collect(Collectors.toList()); + // 实时监控匹配站点监测点集合 + List realTimeList = timeList.stream().filter(o -> null != o.getStationId() && o.getStationId().equals(station.getCode())).map(StationAttributeEntity::getMonitorId).collect(Collectors.toList()); + if(CollectionUtil.isNotEmpty(realTimeList)){ + realDeviceList.addAll(realTimeList); + } + if(CollectionUtil.isNotEmpty(realWsList)) { + realDeviceList.addAll(realWsList); + } + if(CollectionUtil.isEmpty(realDeviceList)){ + return; + } + List realList = realDeviceList.stream().distinct().collect(Collectors.toList()); + String[] realArr = StringUtil.join(realList,",").split(","); + stationRealVo.setRealId(realArr); + list.add(stationRealVo); + }); + redisTemplate.opsForValue().set(moniter_realId_cache_final,list); + } + + @Override + public void loadRealData(String param) { + // 获取设备 + List devices = JSONObject.parseObject(redisTemplate.opsForValue().get(device_cache_final).toString(),new TypeReference>() {});; + // 设备开关机集合监测点 + List switchOnOff = devices.stream().map(o->{ + Map points = o.getPoint(); + if(CollectionUtil.isEmpty(points)){ + return ""; + } + String jointRelay = points.get(HomePageConstant.JOINT_RELAY); + if(!StringUtil.isEmpty(jointRelay)){ + return jointRelay; + } + String onOff = points.get(HomePageConstant.SWITCH_ON_OFF); + if(!StringUtil.isEmpty(onOff)){ + return onOff; + } + return ""; + }).collect(Collectors.toList()); + // 获取站点缓存数据 + List stationRealVos = (List) redisTemplate.opsForValue().get(moniter_realId_cache_final); + if(CollectionUtil.isEmpty(stationRealVos)){ + return; + } + // 数据切割 + int limit = countStep(stationRealVos.size()); + List> list = Stream.iterate(0, n -> n + 1).limit(limit).parallel().map(a -> stationRealVos.stream().skip((long) a * 5).limit(5).parallel().collect(Collectors.toList())).collect(Collectors.toList()); + ExecutorService pool = Executors.newFixedThreadPool(limit); + // + Map valueMap = new ConcurrentHashMap<>(); + // > + Map> keyMap = new ConcurrentHashMap<>(); + CountDownLatch countDownLatch = new CountDownLatch(limit); + pool.execute(()-> list.forEach(stations -> { + stations.forEach(stationReal -> { + String[] realIdArr = stationReal.getRealId(); + List realIds = Stream.of(realIdArr).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(realIds)){ + return; + } + log.error("real_time_data: {},{}",stationReal.getStation(),realIds); + List objects = redisClient.getBatchRealDataByRealId(stationReal.getStation(),realIds); + for(int i = 0; i < realIds.size() ;i++){ + if(ObjectUtil.isEmpty(objects.get(i))){ + log.error(realIds.get(i) + "is null"); + }else{ + Map attribute = (Map) JSONObject.parse(objects.get(i)); + attribute.put("realId",attribute.get("k")); + attribute.put("value",attribute.get("v")); + attribute.put("time",attribute.get("t")); + attribute.remove("v"); + attribute.remove("k"); + attribute.remove("t"); + this.getCheckMap(attribute,switchOnOff); + valueMap.put(realIdArr[i],attribute.get("value")); + keyMap.put(realIdArr[i],attribute); + } + } + }); + countDownLatch.countDown(); + })); + // 等待所有线程执行完成 + try { + countDownLatch.await(); + } catch (InterruptedException e) { + e.printStackTrace(); + Thread.currentThread().interrupt(); + } + pool.shutdown(); + // redis 存储 + redisTemplate.opsForValue().set(real_cache_final,JSONObject.toJSONString(valueMap)); + redisTemplate.opsForValue().set(real_gather_cache_final,JSONObject.toJSONString(keyMap)); + } + + /** + * 计算切分次数 + */ + private static Integer countStep(Integer size) { + return (size + 5 - 1) / 5; + } + + /** + * 监测点过期数据检查 + * @param value + * @return + */ + private void getCheckMap(Map value,List switchOnOff){ + // 不处理开机状态监测点 + if(switchOnOff.contains(value.get("realId"))){ + return; + } + String time = value.get("time"); + if(StringUtil.isEmpty(time)){ + return; + } + Date date = DateUtil.parse(time,DateUtil.PATTERN_DATETIME); + // 实时数据超出10分钟未刷新,值置为 0 显示 + if(System.currentTimeMillis() - date.getTime() > 10 * 60 * 1000L){ + value.put("value","0"); + } + } + + /** + * 集中监控数据处理 + * @param param + */ + @Override + public void loadMonitoring(String param) { + Thread thread = Thread.currentThread(); + Object json = redisTemplate.opsForValue().get(real_data_cache_final); + if (ObjectUtil.isEmpty(json)) { + return; + } + Map> map = JSONObject.parseObject(json.toString(), new TypeReference>>() { + }); + if (MapUtils.isEmpty(map)) { + return; + } + // 获取所有设备重点属性 + List list = attbtService.list(new LambdaQueryWrapper() {{ + isNotNull(StationAttributeEntity::getStationId); + eq(StationAttributeEntity::getIsDeleted, "0"); + orderByAsc(StationAttributeEntity::getSort); + }}); + if (CollectionUtil.isEmpty(list)) { + return; + } + // 获取所有告警记录 + List alertList = alertService.list(new LambdaQueryWrapper() {{ + orderByDesc(StAlarmRecordEntity::getCreateTime); + }}); + List alarmList = abnormalAlarmService.abnormalAlarms(); + // 获取所有故障记录 + List faultList = this.getFdpFaultAll(); + // 所有设备分类 + Map> deviceClassifyMap = (Map>) redisTemplate.opsForValue().get(device_classify_cache_final); + // 所有设备 + List devices = JSONObject.parseObject(redisTemplate.opsForValue().get(device_cache_final).toString(),new TypeReference>() {}); + // 根据站点分组 + Map> stationAttbtMap = list.stream().collect(Collectors.groupingBy(StationAttributeEntity::getStationId)); + // 获取站点列表 + List stationEntityList = stationService.list(Wrappers.lambdaQuery() + .in(StationEntity::getCode,new ArrayList<>(stationAttbtMap.keySet()))); + // 隐藏设备列表 + List hideList = attrConfigService.getHideList(); + // 分割,每个map限制10个长度 + List>> handleList = this.mapChunk(stationAttbtMap); + // 创建线程池 + ThreadFactory namedThreadFactory = new ThreadFactoryBuilder().setNameFormat("load-monitoring-pool-%d").build(); + ExecutorService pool = new ThreadPoolExecutor(5, 5, 0L, TimeUnit.MILLISECONDS, new LinkedBlockingQueue<>(1024), namedThreadFactory, new ThreadPoolExecutor.AbortPolicy()); + CountDownLatch countDownLatch = new CountDownLatch(handleList.size()); + // 所有机构 + R> deptAll = sysClient.getDeptList(); + // 存储数据节点 + List stationList = new CopyOnWriteArrayList<>(); + pool.execute(()->{ + // 线程处理数据 + for(Map> item : handleList){ + item.forEach((key,value)->{ + RealStationVo station = new RealStationVo(); + // 站点编码 + station.setStationCode(key); + // 设置站点状态 + this.setStationStatus(alarmList,station,key); + // 名称、限制水位、服务类型、机构、排序 + this.stationParam(stationEntityList,station,deptAll.getData()); + // 根据设备名称分组 + Map> deviceAttbtMap = value.stream().filter(o -> !hideList.contains(o.getEmName())).collect(Collectors.groupingBy(StationAttributeEntity::getEmName)); + List deviceList = new ArrayList<>(); + // device - 设备,arrbt - 设备重点属性 + deviceAttbtMap.forEach((device, attbt) -> { + RealDeviceVo deviceVo = new RealDeviceVo(); + // 设备名称 + deviceVo.setDeviceName(device); + deviceVo.setDeviceCode(attbt.get(0).getEmCode()); + // 设备处理 + this.handleDevice(attbt, map, deviceVo, alertList, faultList); + deviceList.add(deviceVo); + }); + // 设备状态 + this.getDeviceParam(devices, deviceClassifyMap, deviceList); + station.setDeviceList(deviceList.stream().sorted(Comparator.comparing((RealDeviceVo::getDeviceName))).collect(Collectors.toList())); + stationList.add(station); + }); + countDownLatch.countDown(); + } + }); + // 等待所有线程执行完成 + try { + countDownLatch.await(); + } catch (InterruptedException e) { + e.printStackTrace(); + Thread.currentThread().interrupt(); + } + pool.shutdown(); + redisTemplate.opsForValue().set(moniter_station_cache_final, stationList); + } + + /** + * 设备处理 + * + * @param list + * @param map + * @param device + */ + private void handleDevice(List list, Map> map, + RealDeviceVo device, List alertList, + List faultList) { + if (CollectionUtil.isEmpty(list) || MapUtils.isEmpty(map)) { + return; + } + List attbtList = new ArrayList<>(); + list.forEach(item -> { + RealAttributeVo realAttributeVo = new RealAttributeVo(); + // 设备重点属性处理 : 单条-item + Map real = map.get(item.getMonitorId()); + if(MapUtils.isEmpty(real)){ + realAttributeVo.setName(item.getAttributes()); + realAttributeVo.setType(item.getAttributeType()); + realAttributeVo.setRealId(item.getMonitorId()); + realAttributeVo.setQuality(-1); + realAttributeVo.setStatus(0); + realAttributeVo.setValue("0"); + realAttributeVo.setUnit(item.getUnit()); + attbtList.add(realAttributeVo); + return; + } + realAttributeVo = handleAttbt(item, real, alertList, faultList); + if (ObjectUtil.isEmpty(realAttributeVo)) { + return; + } + attbtList.add(realAttributeVo); + }); + device.setAttbtList(attbtList); + } + + /** + * 获取站点属性 + * @param stationEntityList + * @param item + */ + private void stationParam(List stationEntityList, RealStationVo item,List deptAll) { + if(CollectionUtil.isEmpty(stationEntityList)){ + return; + } + List filterList = stationEntityList.stream().filter(o->item.getStationCode().equals(o.getCode())).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(filterList)){ + return; + } + StationEntity station = filterList.get(0); + if(ObjectUtil.isEmpty(station)){ + return; + } + item.setStationName(station.getName()); + item.setWaterLevelMax(station.getLimitWaterLevel()); + item.setServerType(station.getServeType()); + item.setStationDeptId(station.getRefDept()); + // 排序 + List list = deptAll.stream().filter(o-> station.getRefDept().equals(o.getId())).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(list)){ + return; + } + item.setSort(list.get(0).getSort()); + } + + /** + * 设备参数设置 + * + * @param devices + * @param deviceClassifyMap + * @param deviceList + */ + private void getDeviceParam(List devices, Map> deviceClassifyMap, List deviceList) { + if (CollectionUtil.isEmpty(devices) || CollectionUtil.isEmpty(deviceList) || MapUtils.isEmpty(deviceClassifyMap)) { + return; + } + List faultList = deviceClassifyMap.get(HomePageConstant.FAULT); + List maintaintList = deviceClassifyMap.get(HomePageConstant.MAINTAIN); + List overhaultList = deviceClassifyMap.get(HomePageConstant.OVERHAUL); + List runtList = deviceClassifyMap.get(HomePageConstant.RUN); + List sparetList = deviceClassifyMap.get(HomePageConstant.SPARE); + deviceList.forEach(device -> { + if (StringUtil.isBlank(device.getDeviceCode())) { + device.setState(-1); + return; + } + List list = devices.stream().filter(o -> null != o.getId() && o.getId().toString().equals(device.getDeviceCode())).collect(Collectors.toList()); + if (CollectionUtil.isEmpty(list)) { + device.setState(-1); + return; + } + String deviceCode = list.get(0).getEmCode(); + if (StringUtil.isBlank(deviceCode)) { + device.setState(-1); + return; + } + // 故障 + if (CollectionUtil.isNotEmpty(faultList) && faultList.contains(deviceCode)) { + device.setState(4); + // 保养 + } else if (CollectionUtil.isNotEmpty(maintaintList) && maintaintList.contains(deviceCode)) { + device.setState(3); + // 备用 + } else if (CollectionUtil.isNotEmpty(sparetList) && sparetList.contains(deviceCode)) { + device.setState(2); + // 运行 + } else if (CollectionUtil.isNotEmpty(runtList) && runtList.contains(deviceCode)) { + device.setState(1); + // 检修 + } else if (CollectionUtil.isNotEmpty(overhaultList) && overhaultList.contains(deviceCode)) { + device.setState(0); + // 未知 + } else { + device.setState(-1); + } + }); + } + + /** + * 设备单条重点属性处理 + * + * @param item + * @param real + * @return + */ + private RealAttributeVo handleAttbt(StationAttributeEntity item, Map real, + List alertList, List faultList) { + RealAttributeVo attest = new RealAttributeVo(); + this.setAttbtParam(attest, real); + attest.setRealId(item.getMonitorId()); + attest.setName(item.getAttributes()); + attest.setUnit(item.getUnit()); + attest.setType(item.getAttributeType()); + String value = Optional.ofNullable(attest.getValue()).orElse("-"); + // 正常状态 + attest.setStatus(ConfigStatus.ConfigStatusEnum.NORMAL.getStatus()); + int quality = Optional.ofNullable(attest.getQuality()).orElse(-1); + String time = Optional.ofNullable(attest.getTime()).orElse(""); + // 延时状态 :质量为空 && 时间为空 + if (-1 == quality && StringUtil.isEmpty(time)) { + attest.setStatus(ConfigStatus.ConfigStatusEnum.GRAY.getStatus()); + } + int type = item.getAttributeType(); + switch (type) { + case 1://遥测 + // 预警状态 :value值为"1" && quality值为0 + if ("1".equals(value) && 0 == quality) { + attest.setStatus(ConfigStatus.ConfigStatusEnum.RED.getStatus()); + } + break; + case 2://遥信 + signalyRemote(item, attest, quality, value, alertList); + //处理 + break; + default: + throw new IllegalStateException("Unexpected type: " + type); + } + // 故障信息设置 + accidentDetails(attest, faultList, value); + return attest; + } + + /** + * 设置重点属性参数 + * + * @param attest + * @param real + */ + private void setAttbtParam(RealAttributeVo attest, Map real) { + if (CollectionUtil.isEmpty(real)) { + return; + } + real.forEach((key, value) -> { + if (StringUtil.isBlank(value)) { + return; + } + switch (key) { + case "q": + attest.setQuality(Integer.parseInt(value)); + break; + case "realId": + attest.setRealId(value); + break; + case "value": + attest.setValue(Optional.ofNullable(value).orElse("-")); + break; + case "time": + attest.setTime(value); + break; + default: + break; + } + }); + } + + /** + * 故障信息设置 + * + * @param attest + * @param faultList + * @param value + */ + private void accidentDetails(RealAttributeVo attest, List faultList, String value) { + if (CollectionUtil.isEmpty(faultList) || "-".equals(value)) { + return; + } + List fault = faultList.stream().filter(o -> o.getRealId().equals(attest.getRealId())).collect(Collectors.toList()); + if (CollectionUtil.isEmpty(fault)) { + return; + } + FdpFaultStatusVo fdpFaultStatusVo = fault.get(0); + // 黄色 + if (fdpFaultStatusVo.getValue() > greater_than_cache_final && fdpFaultStatusVo.getValue() < less_than_cache_final) { + attest.setStatus(ConfigStatus.ConfigStatusEnum.YELLOW.getStatus()); + // 橙色 + } else if (fdpFaultStatusVo.getValue() >= be_equa_cache_final) { + attest.setStatus(ConfigStatus.ConfigStatusEnum.ORANGE.getStatus()); + } + attest.setFdpRate(fdpFaultStatusVo.getValue()); + attest.setFdpFaultId(fdpFaultStatusVo.getFaultId()); + attest.setFdpMonitorId(fdpFaultStatusVo.getMonitorId()); + } + + /** + * 重点属性类型-遥信 :数据逻辑处理 + * + * @param attest + */ + private void signalyRemote(StationAttributeEntity item, RealAttributeVo attest, int quality, String strValue, List alertList) { + //需要所有值的数据不为null,并且满足条件才会进去添加数据返回id + if (null == item.getUpUpLimit() || null == item.getDownDownLimit() || null == item.getUpLimit() || null == item.getDownLimit()) { + return; + } + if (-1 == quality) { + return; + } + if (quality != 0) { + return; + } + if ("-".equals(strValue)) { + return; + } + double upup = item.getUpUpLimit(); + double lwlw = item.getDownDownLimit(); + double up = item.getUpLimit(); + double lw = item.getDownLimit(); + //查询出来已处理告警记录 + List handleList = alertList.stream().filter(o -> o.getStationId().equals(item.getStationId()) && o.getRealId().equals(attest.getRealId()) && o.getStatus() == 1).collect(Collectors.toList()); + //查询出来未处理告警记录 + List recordList = alertList.stream().filter(o -> o.getStationId().equals(item.getStationId()) && o.getRealId().equals(attest.getRealId()) && o.getStatus() == 0).collect(Collectors.toList()); + long past = 0L; + double value = Double.parseDouble(strValue); + if (value > upup || value < lwlw) { + if (CollectionUtil.isNotEmpty(handleList)) { + // 现在时间 - 处理时间 + past = System.currentTimeMillis() - handleList.get(0).getProcessTime().getTime(); + } + boolean isOverrun = ((CollectionUtil.isEmpty(handleList) && CollectionUtil.isEmpty(recordList)) || (past / 1000 / 60 > 30 && CollectionUtil.isEmpty(recordList))); + if (isOverrun) { + Long alertId = alertService.insertAlert(item.getStationId(), item.getMonitorId()); + attest.setId(alertId); + attest.setStatus(ConfigStatus.ConfigStatusEnum.YELLOW.getStatus()); + } else if (CollectionUtil.isNotEmpty(recordList)) { + StAlarmRecordEntity record = recordList.get(0); + attest.setId(record.getId()); + // 告警处理完成 + if (record.getProcessTime() != null && record.getStatus() == (byte) 1) { + attest.setStatus(ConfigStatus.ConfigStatusEnum.NORMAL.getStatus()); + // 告警未处理 + } else if (record.getProcessTime() == null && record.getStatus() == (byte) 0) { + attest.setStatus(ConfigStatus.ConfigStatusEnum.HAND_DELAY_STATUS.getStatus()); + } + } + } else if (value > up && value < upup || value < lw && value > lwlw) { + if (CollectionUtil.isNotEmpty(handleList)) { + // 现在时间 - 处理时间 + past = System.currentTimeMillis() - handleList.get(0).getProcessTime().getTime(); + } + boolean exist = ((CollectionUtil.isEmpty(handleList) && CollectionUtil.isEmpty(recordList)) || (past / 1000 / 60 > 30 && CollectionUtil.isEmpty(recordList))); + if (exist){ + Long alertId = alertService.insertAlert(item.getStationId(), item.getMonitorId()); + attest.setId(alertId); + attest.setStatus(ConfigStatus.ConfigStatusEnum.YELLOW.getStatus()); + // 存在告警记录 + } else if (CollectionUtil.isNotEmpty(recordList)) { + StAlarmRecordEntity record = recordList.get(0); + if (recordList.get(0).getStatus() == (byte) 0 && recordList.get(0).getCreateTime() != null) { + attest.setId(record.getId()); + attest.setStatus(ConfigStatus.ConfigStatusEnum.RED.getStatus()); + } else { + attest.setId(recordList.get(0).getId()); + attest.setStatus(ConfigStatus.ConfigStatusEnum.NORMAL.getStatus()); + } + } + } + } + + /** + * 设置站点状态 + * @param alarmList + * @param station + * @param key + */ + private void setStationStatus(List alarmList, RealStationVo station, String key) { + station.setStatus(0); + if(alarmList.contains(key)){ + station.setStatus(1); + } + } + + /** + * 获取所有告警记录 + * + * @return + */ + private List getFdpFaultAll() { + Object json = redisTemplate.opsForValue().get(fdp_fault_cache_final); + if (ObjectUtil.isEmpty(json)) { + return new ArrayList<>(); + } + return (List) json; + } + + /** + * map分割 + * + * @param + * @param + * @param chunkMap + * @return + */ + private List> mapChunk(Map chunkMap) { + if (chunkMap == null) { + return Lists.newArrayList(); + } + Set keySet = chunkMap.keySet(); + Iterator iterator = keySet.iterator(); + int i = 1; + List> total = new ArrayList<>(); + Map tem = new HashMap<>(); + while (iterator.hasNext()) { + k next = iterator.next(); + tem.put(next, chunkMap.get(next)); + if (i == 5) { + total.add(tem); + tem = new HashMap<>(); + i = 0; + } + i++; + } + if (!CollectionUtil.isEmpty(tem)) { + total.add(tem); + } + return total; + } + + /** + * 获取厂房监测点 + * @return + */ + private List getRealIdByWsCodeAndSign() { + List wsInfoList = workshopInfoService.list(); + if(CollectionUtil.isEmpty(wsInfoList)) { + return Lists.newArrayList(); + } + Function getAnalyzeCodePO = wsCode -> { + MultiAnalyzeCodePO multiAnalyzeCodePO = new MultiAnalyzeCodePO(); + multiAnalyzeCodePO.setDeviceCode(wsCode); + multiAnalyzeCodePO.setSignages(Lists.newArrayList(HomePageConstant.PV_JOINT_RELAY,HomePageConstant.PV_REACTIVE_POWER,HomePageConstant.PV_GENERATION_CAPACITY)); + return multiAnalyzeCodePO; + }; + List analyzeCodePOList = wsInfoList.stream().map(WorkshopInfoEntity::getNumber).map(getAnalyzeCodePO).collect(Collectors.toList()); + R> analyzeCodeBySignages = analyseDataSearchClient.getAnalyzeCodeBySignages(analyzeCodePOList); + return Optional.ofNullable(analyzeCodeBySignages).filter(r -> r.isSuccess()).map(R::getData).orElse(Lists.newArrayList()); + } + + /** + * 获取站点realId + * @param refDept + * @param eminfoAndEmParams + * @return + */ + private List getRealDeviceList(Long refDept, List eminfoAndEmParams) { + // 参数检查 + if(CollectionUtil.isEmpty(eminfoAndEmParams) || ObjectUtil.isEmpty(refDept)){ + return new ArrayList<>(); + } + // 有效设备 + List filters = eminfoAndEmParams.stream().filter(o-> o.getCreateDept().equals(refDept)).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(filters)){ + return new ArrayList<>(); + } + // 遍历设备 + List result = new ArrayList<>(); + for(EminfoAndEmParamVo device : filters){ + result.addAll(device.getPoint().values()); + } + return result; + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/PowerServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/PowerServiceImpl.java new file mode 100644 index 0000000..265a8b7 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/PowerServiceImpl.java @@ -0,0 +1,77 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.hnac.hzims.operational.fill.entity.PowerEntity; +import com.hnac.hzims.operational.main.vo.PowerMonthVo; +import com.hnac.hzims.scheduled.mapper.operation.PowerMapper; +import com.hnac.hzims.scheduled.service.operation.PowerService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.DateUtil; +import org.springframework.stereotype.Service; + +import java.util.ArrayList; +import java.util.List; +import java.util.stream.Collectors; + + +@Slf4j +@Service +@AllArgsConstructor +public class PowerServiceImpl extends BaseServiceImpl implements PowerService { + + + /** + * 根据时间、机构查询发电量 + * @param date 时间: 年 - yyyy/月 yyyy-mm/日 yyyy-mm-dd + * @param station 所属机构 + * @return + */ + @Override + public Double generate(String date, Long station) { + List powers = this.list(Wrappers.lambdaQuery() + .likeRight(PowerEntity::getMon,date) + .eq(PowerEntity::getCreateDept,station) + // 类型: 光伏 + .eq(PowerEntity::getType,1) + ); + if(CollectionUtil.isEmpty(powers)){ + return 0.0; + } + return powers.stream().mapToDouble(PowerEntity::getPowerMon).sum(); + } + + /** + * + * @param start 开始时间 : yyyy-mm + * @param end 结束时间 : yyyy-mm + * @param station 所属机构 + * @return + */ + @Override + public List generateThreeYear(String start, String end, Long station) { + List fills = this.list(Wrappers.lambdaQuery() + .between(PowerEntity::getMon,start,end) + .eq(PowerEntity::getCreateDept,station) + // 类型: 光伏 + .eq(PowerEntity::getType,1) + ); + if(CollectionUtil.isEmpty(fills)){ + return new ArrayList<>(); + + } + return fills.stream().map(fill->{ + PowerMonthVo mon = new PowerMonthVo(); + mon.setStrMonth(DateUtil.format(DateUtil.parse(fill.getMon(),"yyyy-MM"),DateUtil.PATTERN_DATE)); + if(Math.abs(fill.getPowerMon()) <= 0){ + mon.setPower(0f); + }else{ + mon.setPower(Float.parseFloat(fill.getPowerMon().toString())); + } + return mon; + }).collect(Collectors.toList()); + } + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java new file mode 100644 index 0000000..eacda88 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java @@ -0,0 +1,1512 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.alibaba.fastjson.JSONObject; +import com.alibaba.fastjson.TypeReference; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.hnac.hzims.EquipmentConstants; +import com.hnac.hzims.equipment.vo.EminfoAndEmParamVo; +import com.hnac.hzims.operational.main.constant.HomePageConstant; +import com.hnac.hzims.operational.main.vo.*; +import com.hnac.hzims.operational.station.StationConstants; +import com.hnac.hzims.operational.station.entity.HzimsAnalyzeModelStationEntity; +import com.hnac.hzims.operational.station.entity.StationEntity; +import com.hnac.hzims.scheduled.service.operation.*; +import com.hnac.hzinfo.datasearch.PointData; +import com.hnac.hzinfo.datasearch.analyse.IAnalyseDataSearchClient; +import com.hnac.hzinfo.datasearch.analyse.domain.FieldsData; +import com.hnac.hzinfo.datasearch.analyse.po.AnalyseCodeByAnalyseDataPO; +import com.hnac.hzinfo.datasearch.analyse.vo.AnalyseDataTaosVO; +import com.hnac.hzinfo.datasearch.analyse.vo.AnalyzeCodeBySignagesVO; +import com.hnac.hzinfo.datasearch.history.IHistoryDataSearchClient; +import com.hnac.hzinfo.datasearch.history.OriginalDataQuery; +import com.hnac.hzinfo.datasearch.real.po.RealDataSearchPO; +import com.hnac.hzinfo.sdk.analyse.po.MultiAnalyzeCodePO; +import com.hnac.hzinfo.sdk.core.response.HzPage; +import com.hnac.hzinfo.sdk.core.response.Result; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.collections4.MapUtils; +import org.springblade.core.log.exception.ServiceException; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.ObjectUtil; +import org.springblade.core.tool.utils.StringUtil; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.data.redis.core.RedisTemplate; +import org.springframework.stereotype.Service; + +import java.math.BigDecimal; +import java.util.*; +import java.util.stream.Collectors; + +/** + * APP首页实现类 + * @author ysj + */ +@Service +@RequiredArgsConstructor +@Slf4j +public class RealTargetServiceImpl implements RealTargetService { + + private final UseService useService; + + private final PowerService powerService; + + private final StationService stationService; + + private final GenerateService generateService; + + private final AnalyseDataService analyseDataService; + + private final StationAttributeService attributeService; + + private final ModelStationService modelStationService; + + private final RedisTemplate redisTemplate; + + private final IAnalyseDataSearchClient analyseDataSearchClient; + + private final IHistoryDataSearchClient historyDataSearchClient; + + @Value("${hzims.equipment.emInfo.emInfoList}") + public String device_cache_cofig_final; + + @Value("${hzims.operation.realIdKey}") + public String real_id_cofig_final; + + private final static String recent_year_power_data = "hzims:operation:key:power:data"; + private final static String load_hydropower_unit_real_key = "hzims:operation:loadhydropowerunit:real:key"; + private final static String load_hydropower_unit_target_key = "hzims:operation:loadhydropowerunit:target:key"; + private final static String loadwaterpump_target_key = "hzims:operation:loadwaterpump:target:key"; + private final static String loadwaterpump_real_key = "hzims:operation:loadwaterpump:real:key"; + private final static String loadwater_level_key = "hzims:operation:loadwater:level:key"; + private final static String loadwater_group_key = "hzims:operation:group:key"; + private final static String load_photovoltaic_real_key = "hzims:operation:photovoltaic:real:key"; + private final static String load_photovoltaic_target_key = "hzims:operation:photovoltaic:target:key"; + + + + /** + * 加载水电站机组实时数据 + * @param param + */ + @Override + public void loadHydropowerReal(String param) { + // 水电站站点 + List stations = stationService.list(Wrappers.lambdaQuery() + .eq(StationEntity::getType,HomePageConstant.HYDROPOWER) + ); + if(CollectionUtil.isEmpty(stations)){ + return; + } + // 水电站设备 + List devices = this.pumpDevices(stations.stream().map(StationEntity::getRefDept).collect(Collectors.toList())); + if(CollectionUtil.isEmpty(devices)){ + return; + } + // 实时数据 + Map map = this.getRealMap(); + // 单位 + Map unitMap = this.attributeService.PointUnit(); + // 实时数据 + List reals = devices.stream().map(device->{ + HydropowerUnitRealVo real = new HydropowerUnitRealVo(); + real.setDeptId(device.getCreateDept()); + real.setDeviceCode(device.getEmCode()); + real.setDeptName(device.getName()); + real.setDeviceName(device.getName()); + // 装机容量 + real.setInstalledCapacity(device.getInstalledCapacity()); + // 开关机状态 + real.setState(this.state(device,map)); + // 有功功率 + real.setActivePower(this.getSignageValue(device,map,HomePageConstant.HYDROPOWER_ACTIVE_POWER)); + // 无功功率 + real.setReactivePower(this.getSignageValue(device,map,HomePageConstant.HYDROPOWER_REACTIVE_POWER)); + // 功率因数 + real.setPowerFactor(this.getSignageValue(device,map,HomePageConstant.HYDROPOWER_POWERFACTOR)); + // 机组频率 + real.setFrequency(this.getSignageValue(device,map,HomePageConstant.HYDROPOWER_FREQUENCY)); + // 导叶开度 + real.setGuideOpen(this.getSignageValue(device,map,HomePageConstant.HYDROPOWER_GUIDEOPEN)); + // 定子电压 + real.setStatorVoltage(this.getSignageValue(device,map,HomePageConstant.HYDROPOWER_VOLTAGE)); + // 定子电流 + real.setStatorCurrent(this.getSignageValue(device,map,HomePageConstant.HYDROPOWER_CURRENT)); + // 单位设置 + this.setttingUnit(device,unitMap,real); + return real; + }).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(reals)){ + return; + } + redisTemplate.opsForValue().set(load_hydropower_unit_real_key,reals); + } + + /** + * 加载水电站机组指标数据 + * @param param + */ + @Override + public void loadHydropowerTarget(String param) { + // 水电站站点 + List stations = stationService.list(Wrappers.lambdaQuery() + //.eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE) + .eq(StationEntity::getType,HomePageConstant.HYDROPOWER) + ); + if(CollectionUtil.isEmpty(stations)){ + return; + } + // 补充填补发电指标 + List targets = this.generteFill(stations); + // 水电站设备 + List devices = this.pumpDevices(stations.stream().map(StationEntity::getRefDept).collect(Collectors.toList())); + if(CollectionUtil.isNotEmpty(devices)){ + targets.addAll(devices.stream().map(device->{ + HydropowerUnitTargetVo target = new HydropowerUnitTargetVo(); + target.setDeptId(device.getCreateDept()); + target.setDeviceCode(device.getEmCode()); + target.setDeviceName(device.getName()); + target.setDeptName(device.getName()); + // 当年发电量 + target.setPowerYear(this.getGenerationPower(device,0)); + // 当月发电量 + target.setPowerMon(this.getGenerationPower(device,1)); + // 当日发电量 + target.setPowerDay(this.getGenerationPower(device,2)); + // 当天有功功率 + target.setActivePowerVoList(this.getLoadsByDay(device)); + // 30天发电量 + target.setGenerationPowerVoList(this.getGenerationPowerList(device)); + return target; + }).collect(Collectors.toList())); + } + // 站点指标数据为空 + if(CollectionUtil.isEmpty(targets)){ + return; + } + redisTemplate.opsForValue().set(load_hydropower_unit_target_key,targets); + } + + /** + * 水利-泵组实时加载 + * @param param + */ + @Override + public void loadWaterPumpReal(String param) { + // 水利站点 + List stations = stationService.list(Wrappers.lambdaQuery() + .eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE) + .in(StationEntity::getType,HomePageConstant.waterList) + ); + if(CollectionUtil.isEmpty(stations)){ + return; + } + // 泵站设备 + List devices = this.pumpDevices(stations.stream().map(StationEntity::getRefDept).collect(Collectors.toList())); + if(CollectionUtil.isEmpty(devices)){ + return; + } + // 实时数据 + Map map = this.getRealMap(); + List list = devices.stream().map(device->{ + WaterPumpRealVo real = new WaterPumpRealVo(); + real.setDeptId(device.getCreateDept()); + real.setDeviceCode(device.getEmCode()); + real.setDeptName(device.getName()); + // 装机容量 + real.setInstalledCapacity(device.getInstalledCapacity()); + // 开机状态 + real.setState(this.pumpState(device,map)); + // 功率因数 + real.setPowerFactor(this.getSignageValue(device,map,HomePageConstant.POWER_FACTOR)); + // 有功功率 + real.setActivePower(this.floatValue(device,map,HomePageConstant.ACTIVE_POWER)); + // 无功功率 + real.setReactivePower(this.floatValue(device,map,HomePageConstant.REACTIVE_POWER)); + // 电压 + real.setVoltage(this.getSignageValue(device,map,HomePageConstant.VOLTAGE)); + // 电流 + real.setCurrent(this.getSignageValue(device,map,HomePageConstant.CURRENT)); + return real; + }).collect(Collectors.toList()); + redisTemplate.opsForValue().set(loadwaterpump_real_key,list); + } + + /** + * 水利-泵组指标加载 + * @param param + */ + @Override + public void loadWaterPumpTarget(String param) { + // 水利站点 + List stations = stationService.list(Wrappers.lambdaQuery() + .eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE) + .in(StationEntity::getType,HomePageConstant.waterList) + ); + if(CollectionUtil.isEmpty(stations)){ + return; + } + // 泵站设备 + List devices = this.pumpDevices(stations.stream().map(StationEntity::getRefDept).collect(Collectors.toList())); + // 补充站点填报发电量 + List list = this.useFill(stations); + // 站点设备数据统计 + if(CollectionUtil.isNotEmpty(devices)){ + list.addAll(devices.stream().map(device->{ + WaterPumpTargetVo target = new WaterPumpTargetVo(); + target.setDeptId(device.getCreateDept()); + target.setDeviceCode(device.getEmCode()); + target.setDeptName(device.getName()); + // 当年用电量 + target.setUsrPowerYear(this.getUsrPowerYear(device)); + // 当月用电量 + target.setUsrPowerMon(this.getUsrPowerMon(device)); + // 当日用电量 + target.setUsrPowerDay(this.getUsrPowerDay(device)); + // 当日机组有功功率 + target.setActivePowerVoList(this.getActivePowerVoList(device)); + // 近30天用电量 + target.setUsrPowerVoList(this.getUsrPowerVoList(device)); + // 近3年用电量 + target.setUsrYearMap(this.getUsrYearMap(device)); + // 月运行次数、时长 + WaterRunVo runMon = this.getRunData(device,1); + target.setRunCountMon(runMon.getCount()); + target.setRunDurationMon(runMon.getHour()); + // 年运行次数、时长 + WaterRunVo runYear = this.getRunData(device,0); + target.setRunCountYear(runYear.getCount()); + target.setRunDurationYear(runYear.getHour()); + return target; + }).collect(Collectors.toList())); + } + redisTemplate.opsForValue().set(loadwaterpump_target_key,list); + } + + /** + * 水利-站点水位数据 + * @param param + */ + @Override + public void loadWaterLevel(String param) { + // 有效站点模型 + List modelList = getModelStationList(); + if(CollectionUtil.isEmpty(modelList)){ + return; + } + List list = new ArrayList<>(); + modelList.forEach(item -> { + List multiAnalyzeCodePOList = new ArrayList<>(); + MultiAnalyzeCodePO multiAnalyzeCodePO = new MultiAnalyzeCodePO(); + multiAnalyzeCodePO.setDeviceCode(item.getInstanceCode()); + multiAnalyzeCodePO.setSignages(Collections.singletonList(HomePageConstant.FRONT_WATER_LEVEL)); + multiAnalyzeCodePOList.add(multiAnalyzeCodePO); + R> result = analyseDataSearchClient.getAnalyzeCodeBySignages(multiAnalyzeCodePOList); + if(!result.isSuccess() || CollectionUtil.isEmpty(result.getData())){ + return; + } + WaterLevelVo waterLevelVo = new WaterLevelVo(); + waterLevelVo.setStationCode(item.getStationId()); + // 前水位 + double frontWaterLevel = this.getWaterLevel(item.getInstanceCode(),HomePageConstant.FRONT_WATER_LEVEL); + waterLevelVo.setFrontWaterLevel(frontWaterLevel); + // 后水位 + double rearWaterLevel = this.getWaterLevel(item.getInstanceCode(),HomePageConstant.REAR_WATER_LEVEL); + waterLevelVo.setRearWaterLevel(rearWaterLevel); + // 前水位当日曲线 + Map frontCurveMap = this.getWaterLevelMap(item.getInstanceCode(),HomePageConstant.FRONT_WATER_LEVEL); + waterLevelVo.setFrontCurveMap(frontCurveMap); + // 后水位当日曲线 + Map rearCurveMap = this.getWaterLevelMap(item.getInstanceCode(),HomePageConstant.REAR_WATER_LEVEL); + waterLevelVo.setRearCurveMap(rearCurveMap); + list.add(waterLevelVo); + }); + redisTemplate.opsForValue().set(loadwater_level_key,list); + } + + /** + * 光伏站-逆变器实时加载 + * + * @param param + */ + + @Override + public void loadPhotovoltaicReal(String param) { + // 查询设备 + List devices = this.getPhotovoltaicDevice(); + if (CollectionUtil.isEmpty(devices)) { + return; + } + // 取redis实时数据 + Map map = this.getRealMap(); + if (MapUtils.isEmpty(map)) { + return; + } + // redis缓存设备实时数据 + List history = (List) redisTemplate.opsForValue().get(load_photovoltaic_real_key); + // 设备实时数据 + List list = devices.stream().map(device -> { + PhotovoltaicRealVo real = new PhotovoltaicRealVo(); + real.setDeptId(device.getCreateDept()); + real.setDeviceCode(device.getEmCode()); + real.setDeviceName(device.getName()); + real.setState(this.getPhotovoltaicState(device, map)); + // 容量 + real.setCapacity(device.getInstalledCapacity()); + // 发电量 + real.setGenerate(this.getSignageValue(device, map, HomePageConstant.PV_GENERATION_CAPACITY)); + // 功率 + real.setLoad(this.getSignageValue(device, map, HomePageConstant.PV_LOAD)); + // 交流电压 + real.setVoltage(this.getSignageValue(device, map, HomePageConstant.PV_VOLTAGE)); + // 交流电流 + real.setCurrent(this.getSignageValue(device, map, HomePageConstant.PV_CURRENT)); + // 交流电压2 + real.setVoltage_two(this.getSignageValue(device, map, HomePageConstant.PV_VOLTAGE_TWO)); + // 交流电流2 + real.setCurrent_two(this.getSignageValue(device, map, HomePageConstant.PV_CURRENT_TWO)); + // 交流电压3 + real.setVoltage_three(this.getSignageValue(device, map, HomePageConstant.PV_VOLTAGE_THREE)); + // 交流电流3 + real.setCurrent_three(this.getSignageValue(device, map, HomePageConstant.PV_CURRENT_THREE)); + // 直流电流1 + real.setDirect_one(this.getSignageValue(device, map, HomePageConstant.DIRECT_ONE)); + // 直流电流2 + real.setDirect_two(this.getSignageValue(device, map, HomePageConstant.DIRECT_TWO)); + // 直流电流3 + real.setDirect_three(this.getSignageValue(device, map, HomePageConstant.DIRECT_THREE)); + // 直流电流4 + real.setDirect_four(this.getSignageValue(device, map, HomePageConstant.DIRECT_FOUR)); + // 直流电流5 + real.setDirect_five(this.getSignageValue(device, map, HomePageConstant.DIRECT_FIVE)); + // 直流电流6 + real.setDirect_six(this.getSignageValue(device, map, HomePageConstant.DIRECT_SIX)); + // 直流电流7 + real.setDirect_seven(this.getSignageValue(device, map, HomePageConstant.DIRECT_SEVEN)); + // 直流电流8 + real.setDirect_eight(this.getSignageValue(device, map, HomePageConstant.DIRECT_EIGHT)); + // 直流电流9 + real.setDirect_nine(this.getSignageValue(device, map, HomePageConstant.DIRECT_NINE)); + // 直流电流10 + real.setDirect_ten(this.getSignageValue(device, map, HomePageConstant.DIRECT_TEN)); + // 直流电流11 + real.setDirect_eleven(this.getSignageValue(device, map, HomePageConstant.DIRECT_ELEVEN)); + // 直流电流12 + real.setDirect_twelve(this.getSignageValue(device, map, HomePageConstant.DIRECT_TWELVE)); + // 直流电压1 + real.setDc_voltage_one(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_ONE)); + // 直流电压2 + real.setDc_voltage_two(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_TWO)); + // 直流电压3 + real.setDc_voltage_three(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_THREE)); + // 直流电压4 + real.setDc_voltage_four(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_FOUR)); + // 直流电压5 + real.setDc_voltage_five(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_FIVE)); + // 直流电压6 + real.setDc_voltage_six(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_SIX)); + // 直流电压7 + real.setDc_voltage_seven(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_SEVEN)); + // 直流电压8 + real.setDc_voltage_eight(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_EIGHT)); + // 直流电压9 + real.setDc_voltage_nine(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_NINE)); + // 直流电压10 + real.setDc_voltage_ten(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_TEN)); + // 直流电压11 + real.setDc_voltage_eleven(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_ELEVEN)); + // 直流电压12 + real.setDc_voltage_twelve(this.getSignageValue(device, map, HomePageConstant.DC_VOLTAGE_TWELVE)); + // 串流电流1 + real.setDirect_one(this.getSignageValue(device, map, HomePageConstant.DIRECT_ONE)); + // 串流电流2 + real.setSeries_two(this.getSignageValue(device, map, HomePageConstant.SERIES_TWO)); + // 串流电流3 + real.setSeries_three(this.getSignageValue(device, map, HomePageConstant.SERIES_THREE)); + // 串流电流4 + real.setSeries_four(this.getSignageValue(device, map, HomePageConstant.SERIES_FOUR)); + // 串流电流5 + real.setSeries_five(this.getSignageValue(device, map, HomePageConstant.SERIES_FIVE)); + // 串流电流6 + real.setSeries_six(this.getSignageValue(device, map, HomePageConstant.SERIES_SIX)); + // 串流电流7 + real.setSeries_seven(this.getSignageValue(device, map, HomePageConstant.SERIES_SEVEN)); + // 串流电流8 + real.setSeries_eight(this.getSignageValue(device, map, HomePageConstant.SERIES_EIGHT)); + // 串流电流9 + real.setSeries_nine(this.getSignageValue(device, map, HomePageConstant.SERIES_NINE)); + // 串流电流10 + real.setSeries_ten(this.getSignageValue(device, map, HomePageConstant.SERIES_TEN)); + // 串流电流11 + real.setSeries_eleven(this.getSignageValue(device, map, HomePageConstant.SERIES_ELEVEN)); + // 串流电流12 + real.setSeries_twelve(this.getSignageValue(device, map, HomePageConstant.SERIES_TWELVE)); + // 串流电压1 + real.setSe_voltage_one(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_ONE)); + // 串流电压2 + real.setSe_voltage_two(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_TWO)); + // 串流电压3 + real.setSe_voltage_three(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_THREE)); + // 串流电压4 + real.setSe_voltage_four(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_FOUR)); + // 串流电压5 + real.setSe_voltage_five(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_FIVE)); + // 串流电压6 + real.setSe_voltage_six(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_SIX)); + // 串流电压7 + real.setSe_voltage_seven(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_SEVEN)); + // 串流电压8 + real.setSe_voltage_eight(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_EIGHT)); + // 串流电压9 + real.setSe_voltage_nine(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_NINE)); + // 串流电压10 + real.setSe_voltage_ten(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_TEN)); + // 串流电压11 + real.setSe_voltage_eleven(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_ELEVEN)); + // 串流电压12 + real.setSe_voltage_twelve(this.getSignageValue(device, map, HomePageConstant.SE_VOLTAGE_TWELVE)); + // 上次功率 + real.setLastLoad(this.getLastLoad(device, history)); + return real; + }).collect(Collectors.toList()); + // 存储redis + redisTemplate.opsForValue().set(load_photovoltaic_real_key, list); + } + + + + /** + * 光伏站-逆变器指标加载 + * + * @param param + */ + @Override + public void loadPhotovoltaicTarget(String param) { + // 有效设备 + List devices = this.getPhotovoltaicDevice(); + if (CollectionUtil.isEmpty(devices)) { + return; + } + List list = new ArrayList<>(); + // 接入站点设备统计 + devices.forEach(device -> { + PhotovoltaicTargetVo target = new PhotovoltaicTargetVo(); + target.setDeptId(device.getCreateDept()); + target.setDeviceCode(device.getEmCode()); + target.setDeviceName(device.getName()); + target.setDeptName(device.getName()); + // 当日运行时长 + target.setRunHours(this.runHours(device.getPoint().get(HomePageConstant.PV_JOINT_RELAY))); + // 年发电量 + target.setGenerationYear((double) this.sumValueByTime(device.getEmCode(), device.getRideCount(), "0")); + // 月发电量 + target.setGenerationMon((double) this.sumValueByTime(device.getEmCode(), device.getRideCount(), "1")); + // 日发电量 + target.setGenerationDay((double) this.sumValueByTime(device.getEmCode(), device.getRideCount(), "2")); + // 昨日发电量 + target.setGenerationYesterday((double) this.sumValueByTime(device.getEmCode(), device.getRideCount(), "3")); + // 收益 + target.setIncome(target.getGenerationDay() * 0.34); + // 节约标准煤 + target.setTec(target.getGenerationMon() * 0.0001229); + // 二氧化碳减排 + target.setCo2(target.getGenerationMon() * 0.000997); + // 减少森林砍伐 + target.setDeforest(target.getGenerationMon() * 0.000553); + // 当天有功功率 + target.setActivePowerVoList(this.photovoltaicLoadsByDay(device)); + // 30天发电量 + target.setGenerationPowerVoList(this.getGenerateByMon(device)); + list.add(target); + }); + // 补充站点填报发电量 + List stations = stationService.list(Wrappers.lambdaQuery() + .eq(StationEntity::getType, HomePageConstant.PHOTOVOLTAIC) + .eq(StationEntity::getServeType, HomePageConstant.HYDROPOWER_SERVETYPE) + ); + if(CollectionUtil.isNotEmpty(stations)){ + list.addAll(this.generateFill(stations)); + } + redisTemplate.opsForValue().set(load_photovoltaic_target_key, list); + } + + + /** + * 当日用电量 + * @param device + * @return + */ + private float getUsrPowerDay(EminfoAndEmParamVo device) { + String time = DateUtil.format(new Date(),DateUtil.PATTERN_DATE); + // 当日用电量 + return analyseDataService.periodTargetFloat(time + " 00:00:00",time + " 23:59:59",5,3,device.getEmCode(),device.getRideCount(),HomePageConstant.ELECTRICITY_CONSUMPTION); + + } + + /** + * 当月用电量 + * @param device + * @return + */ + private float getUsrPowerMon(EminfoAndEmParamVo device) { + String start = DateUtil.format(new Date(), "yyyy-MM") + "-01 00:00:00"; + String end = DateUtil.format(new Date(), DateUtil.PATTERN_DATETIME); + // 当月用电量 + return analyseDataService.periodTargetFloat(start,end,5,5,device.getEmCode(),device.getRideCount(),HomePageConstant.ELECTRICITY_CONSUMPTION); + } + + /** + * 当年用电量 + * @param device + * @return + */ + private float getUsrPowerYear(EminfoAndEmParamVo device) { + Calendar calendar = Calendar.getInstance(); + String end = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATETIME); + calendar.setTime(new Date()); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH)); + calendar.add(Calendar.DATE, -calendar.get(Calendar.DATE) + 1); + String start = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATETIME); + // 当年用电量 + return analyseDataService.periodTargetFloat(start,end,5,6,device.getEmCode(),device.getRideCount(),HomePageConstant.ELECTRICITY_CONSUMPTION); + } + + /** + * 当日机组有功功率 + * @param device + * @return + */ + public List getActivePowerVoList(EminfoAndEmParamVo device) { + String startTime = DateUtil.format(new Date(), "yyyy-MM-dd 00:00:00"); + String endTime = DateUtil.format(new Date(), "yyyy-MM-dd HH:mm:ss"); + List datas = analyseDataService.periodTargetData(startTime,endTime,2,6,device.getEmCode(),HomePageConstant.ACTIVE_POWER); + if(CollectionUtil.isEmpty(datas)){ + return new ArrayList<>(); + } + return datas.stream().map(data->{ + ActivePowerVo active = new ActivePowerVo(); + Date dateTime = DateUtil.parse(data.getTs(), "yyyy-MM-dd HH:mm:ss.s"); + active.setHour(dateTime.getHours()); + if (StringUtil.isBlank(data.getVal())) { + active.setActivePower("0"); + }else { + active.setActivePower(data.getVal()); + } + return active; + }).collect(Collectors.toList()); + } + + /** + * 近30天用电量 + * @param device + * @return + */ + private List getUsrPowerVoList(EminfoAndEmParamVo device) { + String start = DateUtil.format(new Date(),DateUtil.PATTERN_DATE) + " 00:00:00"; + Calendar calendar = Calendar.getInstance(); + calendar.add(Calendar.DAY_OF_MONTH,-29); + String end = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATETIME); + List records = analyseDataService.periodTargetData(start,end,5,EquipmentConstants.CycleTypeEnum.DAY_CYCLE.getType(),device.getEmCode(),HomePageConstant.ELECTRICITY_CONSUMPTION); + if(CollectionUtil.isEmpty(records)){ + return new ArrayList<>(); + } + return records.stream().map(record -> { + UsrPowerVo usr = new UsrPowerVo(); + Date time = DateUtil.parse(record.getTs(), "yyyy-MM-dd HH:mm:ss.s"); + usr.setDate(DateUtil.format(time,DateUtil.PATTERN_DATE)); + usr.setUsrPower(Float.valueOf(Optional.ofNullable(record.getVal()).orElse("0"))); + return usr; + }).collect(Collectors.toList()); + } + + /** + * 近3年发电量 + * + * @param device + * @return + */ + private Map getUsrYearMap(EminfoAndEmParamVo device) { + // 开始时间 + Calendar calendar = Calendar.getInstance(); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH) + 12); + calendar.add(Calendar.DATE, -calendar.get(Calendar.DATE) + 1); + String end = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE) + " 00:00:00"; + // 结束日期 + calendar.set(Calendar.YEAR, calendar.get(Calendar.YEAR) - 3); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH)); + String start = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE) + " 00:00:00"; + // 查询数据 + List records = analyseDataService.periodTargetData(start,end,5,5,device.getEmCode(),HomePageConstant.ELECTRICITY_CONSUMPTION); + if(CollectionUtil.isEmpty(records)){ + return new HashMap<>(); + } + return records.stream().map(record -> { + PowerMonthVo generate = new PowerMonthVo(); + Date time = DateUtil.parse(record.getTs(), "yyyy-MM-dd HH:mm:ss.s"); + generate.setStrMonth(DateUtil.format(time, DateUtil.PATTERN_DATE)); + generate.setPower(Float.parseFloat(Optional.ofNullable(record.getVal()).orElse("0")) * device.getRideCount()); + return generate; + }).collect(Collectors.toMap(PowerMonthVo::getStrMonth,PowerMonthVo::getPower)); + } + + /** + * 获取运行数据 + * @param device + * @param type + * @return + */ + private WaterRunVo getRunData(EminfoAndEmParamVo device, int type) { + // 默认返回运行数据 + WaterRunVo waterRunVo = new WaterRunVo(); + waterRunVo.setCount(0); + waterRunVo.setHour(0.0); + Map point = device.getPoint(); + if(MapUtils.isEmpty(point)){ + return waterRunVo; + } + // 监测点 + String realId = point.get(HomePageConstant.SWITCH_ON_OFF); + if(StringUtil.isBlank(realId)){ + return waterRunVo; + } + // 确定查询时间范围: 年、月 + Date startDate,endDate; + Calendar calendar = Calendar.getInstance(); + calendar.setTime(new Date()); + switch (type){ + case 0: + endDate = calendar.getTime(); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH)); + calendar.add(Calendar.DATE, -calendar.get(Calendar.DATE) + 1); + startDate = calendar.getTime(); + break; + case 1: + endDate = calendar.getTime(); + calendar.add(Calendar.DATE, -calendar.get(Calendar.DATE) + 1); + calendar.add(Calendar.HOUR_OF_DAY, -calendar.get(Calendar.HOUR_OF_DAY)); + calendar.add(Calendar.MINUTE, -calendar.get(Calendar.MINUTE)); + calendar.add(Calendar.SECOND, -calendar.get(Calendar.SECOND)); + startDate = calendar.getTime(); + break; + default: + throw new IllegalStateException("Unexpected value: " + type); + } + return this.getRunConvertData(realId,startDate,endDate,waterRunVo); + } + + /** + * 获取时间范围内开机次数、运行时长 + * @param realId + * @param startDate + * @param endDate + * @param waterRunVo + * @return + */ + private WaterRunVo getRunConvertData(String realId, Date startDate, Date endDate, WaterRunVo waterRunVo) { + OriginalDataQuery originalDataQuery = new OriginalDataQuery(); + originalDataQuery.setRealId(realId); + originalDataQuery.setBeginTime(startDate); + originalDataQuery.setEndTime(endDate); + originalDataQuery.setLimit(100000); + originalDataQuery.setPage(1); + // 查询时间范围开关机监测点历史数据 + Result> R = historyDataSearchClient.getOriginalDataByRealIds(originalDataQuery); + if(!R.isSuccess() || ObjectUtil.isEmpty(R.getData())){ + return waterRunVo; + } + // 过滤相邻开关机状态相同数据 + List result = this.getFilterList(R.getData().getRecords()); + if(CollectionUtil.isEmpty(result)){ + return waterRunVo; + } + // 开机次数 + int count = (int) result.stream().filter(o->HomePageConstant.OFF.equals(o.getValue())).count(); + waterRunVo.setCount(count); + // 开机运行时长 + long time = this.getRunTime(result,startDate,endDate); + waterRunVo.setHour(BigDecimal.valueOf(time / (1000 * 60 * 60.00)).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue()); + return waterRunVo; + } + + /** + * 过滤相邻开关机状态相同数据 + * @param list + * @return + */ + private List getFilterList(List list) { + if(CollectionUtil.isEmpty(list)){ + return null; + } + List result = new ArrayList<>(); + // 遍历数据 + for(int i = 0; i< list.size() ; i++){ + // 第一个数据保存下来 + if(i == 0){ + result.add(list.get(i)); + continue; + } + // 遍历数据状态 + String value = list.get(i).getValue(); + if(StringUtil.isBlank(value)){ + continue; + } + // 上一条数据状态 + String up_value = list.get(i-1).getValue(); + if(value.equals(up_value)){ + continue; + } + result.add(list.get(i)); + } + return result; + } + + /** + * 获取运行时长 + * @param result + * @return + */ + private long getRunTime(List result,Date startDate,Date endDate) { + if(result.size() == 1){ + // 一直开机 + if(HomePageConstant.OFF.equals(result.get(0).getValue())){ + return endDate.getTime() - startDate.getTime(); + } + // 一直关机 + return 0; + } + long time=0; + // 遍历累计开机时长 + for(int i = 0; i< result.size() ; i++){ + // 记录为开机状态 就计算到下次关机的时间差 + if(HomePageConstant.ON.equals(result.get(i).getValue())){ + continue; + } + Date endTime,startTime = DateUtil.parse(result.get(i).getTime(), DateUtil.PATTERN_DATETIME); + // 遍历至最后一条数据,累计至当前时间 + if(i == result.size() - 1){ + endTime = endDate; + } + else { + endTime = DateUtil.parse(result.get(i+1).getTime(), DateUtil.PATTERN_DATETIME); + } + time += endTime.getTime() - startTime.getTime(); + } + return time; + } + + /** + * 获取填报用电量 + * @param stations + * @return + */ + private List useFill(List stations) { + Calendar calendar = Calendar.getInstance(); + String day = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + String mon = DateUtil.format(calendar.getTime(),"yyyy-MM"); + String year = String.valueOf(calendar.get(Calendar.YEAR)); + return stations.stream().map(station ->{ + WaterPumpTargetVo target = new WaterPumpTargetVo(); + target.setDeptId(station.getRefDept()); + target.setDeptName(station.getName()); + // 月运行次数、时长 + target.setRunCountMon(0); + target.setRunDurationMon(0.0); + // 年运行次数、时长 + target.setRunCountYear(0); + target.setRunDurationYear(0.0); + // 当年用电量 + target.setUsrPowerYear(useService.use(year,station.getCode())); + // 当月用电量 + target.setUsrPowerMon(useService.use(mon,station.getCode())); + // 当日用电量 + target.setUsrPowerDay(useService.use(day,station.getCode())); + if(StationConstants.DATA_ORIGIN_FILL.equals(station.getDataOrigin())){ + // 30天用电量 + target.setUsrPowerVoList(useService.use30Day(day,station.getCode())); + } + // 近3年用电量 + target.setUsrYearMap(this.useThreeYear(station.getCode())); + return target; + }).collect(Collectors.toList()); + } + + /** + * 获取水位实时数据 + * @param instanceCode + * @param signage + * @return + */ + private double getWaterLevel(String instanceCode, String signage) { + RealDataSearchPO realData = new RealDataSearchPO(); + realData.setAnalyzeCode(instanceCode); + List signages = Collections.singletonList(signage); + realData.setSignages(signages); + // 调用fegin接口查询实时数据 + R> R = analyseDataSearchClient.getRealDataByAnalyzeCode(realData); + if(!R.isSuccess() || CollectionUtil.isEmpty(R.getData())){ + return 0.0; + } + // 时间限制 + String time = R.getData().get(0).getTime(); + if(StringUtil.isEmpty(time) || "-".equals(time)){ + return 0.0; + } + Date date = DateUtil.parse(time, "yyyy-MM-dd HH:mm:ss.sss"); + if(System.currentTimeMillis() - date.getTime() > 30 * 60 * 1000L){ + return 0.0; + } + return Double.parseDouble(R.getData().get(0).getValue()); + } + + /** + * 获取水位当年数据 + * @param instanceCode + * @param signage + * @return + */ + private Map getWaterLevelMap(String instanceCode, String signage) { + String beginTime = DateUtil.format(new Date(), DateUtil.PATTERN_DATE) + " 00:00:00"; + String endTime = DateUtil.format(new Date(), DateUtil.PATTERN_DATE); + AnalyseCodeByAnalyseDataPO po = new AnalyseCodeByAnalyseDataPO(); + List datas = analyseDataService.periodTargetData(beginTime, endTime,2, 6,instanceCode,signage); + if(CollectionUtil.isEmpty(datas)){ + return new HashMap<>(); + } + return datas.stream().collect(Collectors.toMap( + key-> { + Date dateTime = DateUtil.parse(key.getTs(), "yyyy-MM-dd HH:mm:ss.s"); + return dateTime.getHours(); + }, + value -> { + if(StringUtil.isBlank(value.getVal())){ + return "0"; + } + return value.getVal(); + }) + ); + } + + /** + * 填报近3年发电量 + * @param station + * @return + */ + private Map useThreeYear(String station) { + // 开始时间 + Calendar calendar = Calendar.getInstance(); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH) + 12); + calendar.add(Calendar.DATE, -calendar.get(Calendar.DATE) + 1); + String end = DateUtil.format(calendar.getTime(),"yyyy-MM"); + // 结束日期 + calendar.set(Calendar.YEAR, calendar.get(Calendar.YEAR) - 3); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH)); + String start = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + return useService.generateThreeYear(start,end,station); + } + + + /** + * 获取有效站点模型 + * @return + */ + private List getModelStationList() { + // 水利站点(All) + List stations = stationService.list(new LambdaQueryWrapper() {{ + eq(StationEntity::getServeType, HomePageConstant.HYDROPOWER_SERVETYPE); + }}); + if(CollectionUtil.isEmpty(stations)){ + return new ArrayList<>(); + } + // 站点code集合 + List codes = stations.stream().map(StationEntity::getCode).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(codes)){ + return new ArrayList<>(); + } + // 查询站点模型列表 + List list = modelStationService.list(new LambdaQueryWrapper() {{ + in(HzimsAnalyzeModelStationEntity::getStationId, codes); + }}); + if(CollectionUtil.isEmpty(list)){ + return new ArrayList<>(); + } + return list; + } + + /** + * 获取开机状态 + * @param device + * @return + */ + private int pumpState(EminfoAndEmParamVo device,Map map) { + // 获取开关机监测点实时数据 + double value = this.getSignageValue(device,map,HomePageConstant.SWITCH_ON_OFF); + // 开机状态 + if (Math.abs(value) <= 0) { + return 0; + } + return 1; + } + + /** + * 有功功率 + * @param device + * @return + */ + private float floatValue(EminfoAndEmParamVo device,Map map,String target) { + // 获取有功功率监测点实时数据 + double value = this.getSignageValue(device,map,target); + // 转换float + return Float.parseFloat(String.valueOf(value)); + } + + /** + * 设备状态 + * @param device + * @param map + * @return + */ + private Boolean state(EminfoAndEmParamVo device, Map map) { + if(Math.abs(this.getSignageValue(device,map,HomePageConstant.JOINT_RELAY)) > 0){ + return true; + } + return Math.abs(this.getSignageValue(device, map, HomePageConstant.ACTIVE_POWER)) > 0; + } + + /** + * 近年发电量数据 + * + * @param param 时间 + * @param serveType 站点类型 + * @param year 近几年 + */ + @Override + public void loadPowerData(String param, List types, Integer serveType, int year) { + // 站点查询 + List stationList = stationService.list(new LambdaQueryWrapper() {{ + if (ObjectUtil.isNotEmpty(serveType)) { + eq(StationEntity::getServeType, serveType); + } + if (CollectionUtil.isNotEmpty(types)) { + in(StationEntity::getType, types); + } + }}); + // 设备信息 + List devices = JSONObject.parseObject(redisTemplate.opsForValue().get(device_cache_cofig_final).toString(), new TypeReference>() { + }); + // 开始时间 + Calendar calendar = Calendar.getInstance(); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH) + 12); + calendar.add(Calendar.DATE, -calendar.get(Calendar.DATE) + 1); + String end = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE) + " 00:00:00"; + // 结束日期 + calendar.set(Calendar.YEAR, calendar.get(Calendar.YEAR) - year); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH)); + String start = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE) + " 00:00:00"; + // 存储数据map :<站点id,<月份,发电量>> + Map> powerMap = new HashMap<>(); + stationList.forEach(station -> { + // 站点设备集合 + List stationDevices = devices.stream().filter(device -> device.getCreateDept().equals(station.getRefDept())).collect(Collectors.toList()); + log.error("load_power_data station :" + station.getCode() + "==== device :" + stationDevices ); + Map generateMap = this.getGenerateYear(station,stationDevices,start,end); + if(MapUtils.isEmpty(generateMap)){ + return; + } + powerMap.put(station.getId(),generateMap); + }); + redisTemplate.opsForValue().set(recent_year_power_data, powerMap); + } + + + /** + * 当天有功功率 + * @param device + * @return + */ + private List getLoadsByDay(EminfoAndEmParamVo device) { + String start = DateUtil.format(new Date(), DateUtil.PATTERN_DATE) + " 00:00:00"; + String end = DateUtil.format(new Date(), DateUtil.PATTERN_DATETIME); + List records = analyseDataService.periodTargetData(start, end, 3, 2, device.getEmCode(), HomePageConstant.PV_LOAD); + if (CollectionUtil.isEmpty(records)) { + return new ArrayList<>(); + } + return records.stream().map(record -> { + ActivePowerVo load = new ActivePowerVo(); + Date time = DateUtil.parse(record.getTs(), "yyyy-MM-dd HH:mm:ss.s"); + load.setHour(time.getHours()); + load.setActivePower(Optional.ofNullable(record.getVal()).orElse("0")); + return load; + }).sorted(Comparator.comparing(ActivePowerVo::getHour)).collect(Collectors.toList()); + } + + /** + * 获取年发电量 + * @param devices + * @param start + * @param end + * @return + */ + private Map getGenerateYear(StationEntity station,List devices, String start, String end) { + List datas = new ArrayList<>(); + // 设备采集发电量 + if(CollectionUtil.isNotEmpty(devices)){ + devices.forEach(device->{ + List records = analyseDataService.periodTargetData(start,end,5,5,device.getEmCode(),HomePageConstant.HYDROPOWER_GENERATE_POWER); + if(CollectionUtil.isEmpty(records)){ + return; + } + datas.addAll(records.stream().map(record -> { + PowerMonthVo generate = new PowerMonthVo(); + Date time = DateUtil.parse(record.getTs(), "yyyy-MM-dd HH:mm:ss.s"); + generate.setStrMonth(DateUtil.format(time,DateUtil.PATTERN_DATE)); + generate.setPower(Float.parseFloat(Optional.ofNullable(record.getVal()).orElse("0")) * device.getRideCount()); + return generate; + }).collect(Collectors.toList())); + }); + } + // 补充填报数据 + datas.addAll(this.generateFill(station,start,end)); + if(CollectionUtil.isEmpty(datas)){ + return null; + } + return datas.stream().collect(Collectors.toMap(PowerMonthVo::getStrMonth, PowerMonthVo::getPower, Float::sum)); + } + + + /** + * 获取填报用电量 + * @param stations + * @return + */ + private List generteFill(List stations) { + Calendar calendar = Calendar.getInstance(); + String day = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + String mon = DateUtil.format(calendar.getTime(),"yyyy-MM"); + String year = String.valueOf(calendar.get(Calendar.YEAR)); + return stations.stream().map(station ->{ + HydropowerUnitTargetVo target = new HydropowerUnitTargetVo(); + target.setDeptId(station.getRefDept()); + target.setDeptName(station.getName()); + // 当年发电量 + target.setPowerYear(generateService.generate(year,station.getCode())); + // 当月发电量 + target.setPowerMon(generateService.generate(mon,station.getCode())); + // 当日发电量 + target.setPowerDay(generateService.generate(day,station.getCode())); + // 30天发电量 + target.setGenerationPowerVoList(generateService.generate30Day(day,station.getCode())); + return target; + }).collect(Collectors.toList()); + } + + + /** + * 补充填报数据 + * @param station + * @param start + * @param end + */ + private List generateFill(StationEntity station, String start, String end) { + start = DateUtil.format(DateUtil.parse(start,DateUtil.PATTERN_DATETIME),"yyyy-MM"); + end = DateUtil.format(DateUtil.parse(end,DateUtil.PATTERN_DATETIME),"yyyy-MM"); + // 光伏 + if(HomePageConstant.PHOTOVOLTAIC.equals(station.getType())){ + return powerService.generateThreeYear(start,end,station.getRefDept()); + } + // 水电 + return generateService.generateThreeYear(start,end,station.getCode()); + } + + /** + * 获取开机状态 + * + * @param device + * @return + */ + private int getPhotovoltaicState(EminfoAndEmParamVo device, Map map) { + // 获取开关机监测点实时数据 + Double value = this.getSignageValue(device, map, HomePageConstant.PV_JOINT_RELAY); + // 开机状态 + if (Math.abs(value) <= 0) { + return 0; + } + return 1; + } + + /** + * 获取上一次功率 + * + * @param device + * @param history + * @return + */ + private Double getLastLoad(EminfoAndEmParamVo device, List history) { + if (CollectionUtil.isEmpty(history)) { + return 0.0; + } + List historyDevice = history.stream().filter(o -> o.getDeviceCode().equals(device.getEmCode())).collect(Collectors.toList()); + if (CollectionUtil.isEmpty(historyDevice)) { + return 0.0; + } + return historyDevice.get(0).getLoad(); + } + + /** + * 获取光伏设备 + * + * @return + */ + private List getPhotovoltaicDevice() { + // 光伏站点 + List stations = stationService.list(Wrappers.lambdaQuery() + .eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE) + .eq(StationEntity::getType,HomePageConstant.PHOTOVOLTAIC) + ); + if (CollectionUtil.isEmpty(stations)) { + return new ArrayList<>(); + } + // 设备 + List devices = JSONObject.parseObject(redisTemplate.opsForValue().get(device_cache_cofig_final).toString(), new TypeReference>() { + }); + if (CollectionUtil.isEmpty(devices)) { + return new ArrayList<>(); + } + return devices.stream().filter(device -> + stations.stream().map(StationEntity::getRefDept).collect(Collectors.toList()).contains(device.getCreateDept()) + ).collect(Collectors.toList()); + } + + /** + * 当天运行时长 + * + * @param realId + * @return + */ + private Double runHours(String realId) { + Calendar calendar = Calendar.getInstance(); + Date end = calendar.getTime(); + calendar.add(Calendar.HOUR_OF_DAY, -calendar.get(Calendar.HOUR_OF_DAY)); + calendar.add(Calendar.MINUTE, -calendar.get(Calendar.MINUTE)); + calendar.add(Calendar.SECOND, -calendar.get(Calendar.SECOND)); + Date start = calendar.getTime(); + OriginalDataQuery originalDataQuery = new OriginalDataQuery(); + originalDataQuery.setRealId(realId); + originalDataQuery.setBeginTime(start); + originalDataQuery.setEndTime(end); + originalDataQuery.setLimit(100000); + originalDataQuery.setPage(1); + // 查询时间范围开关机监测点历史数据 + Result> R = historyDataSearchClient.getOriginalDataByRealIds(originalDataQuery); + if (!R.isSuccess() || ObjectUtil.isEmpty(R.getData())) { + return 0.0; + } + // 过滤相邻开关机状态相同数据 + List result = this.getFilterList(R.getData().getRecords()); + if (CollectionUtil.isEmpty(result)) { + return 0.0; + } + // 开机运行时长 + long time = this.getRunTime(result, start, end); + return BigDecimal.valueOf(time / (1000 * 60 * 60.00)).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue(); + } + + /** + * 根据事件查询数据值 + * + * @param deviceCode + * @param rideCount + * @param type + * @return + */ + private float sumValueByTime(String deviceCode, int rideCount, String type) { + Calendar calendar = Calendar.getInstance(); + String start, end; + int cycleType = 3; + switch (type) { + //年 + case "0": + calendar.add(Calendar.HOUR_OF_DAY, +1); + end = DateUtil.format(calendar.getTime(), DateUtil.PATTERN_DATETIME); + calendar.setTime(new Date()); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH)); + calendar.add(Calendar.DAY_OF_MONTH, -calendar.get(Calendar.DATE) + 1); + calendar.add(Calendar.HOUR_OF_DAY, -calendar.get(Calendar.HOUR_OF_DAY)); + calendar.add(Calendar.MINUTE, -calendar.get(Calendar.MINUTE)); + calendar.add(Calendar.SECOND, -calendar.get(Calendar.SECOND)); + start = DateUtil.format(calendar.getTime(), DateUtil.PATTERN_DATETIME); + cycleType = 6; + break; + //月 + case "1": + start = DateUtil.format(new Date(), "yyyy-MM") + "-01 00:00:00"; + end = DateUtil.format(new Date(), DateUtil.PATTERN_DATETIME); + cycleType = 5; + break; + //日 + case "2": + start = DateUtil.format(new Date(), DateUtil.PATTERN_DATE) + " 00:00:00"; + end = DateUtil.format(new Date(), DateUtil.PATTERN_DATETIME); + break; + //昨日 + case "3": + calendar.add(Calendar.DAY_OF_MONTH, -1); + calendar.add(Calendar.HOUR_OF_DAY, -calendar.get(Calendar.HOUR_OF_DAY)); + calendar.add(Calendar.MINUTE, -calendar.get(Calendar.MINUTE)); + calendar.add(Calendar.SECOND, -calendar.get(Calendar.SECOND)); + start = DateUtil.format(calendar.getTime(), DateUtil.PATTERN_DATETIME); + end = DateUtil.format(new Date(), DateUtil.PATTERN_DATE) + " 00:00:00"; + break; + default: + throw new ServiceException("无效查询类型!"); + } + return analyseDataService.periodTargetFloat(start, end, 5, cycleType, deviceCode, rideCount, HomePageConstant.PV_GENERATION_CAPACITY); + } + + /** + * 当天有功功率 + * + * @param device + * @return + */ + private List photovoltaicLoadsByDay(EminfoAndEmParamVo device) { + String start = DateUtil.format(new Date(), DateUtil.PATTERN_DATE) + " 00:00:00"; + String end = DateUtil.format(new Date(), DateUtil.PATTERN_DATETIME); + List records = analyseDataService.periodTargetData(start, end, 1, 2, device.getEmCode(), HomePageConstant.PV_LOAD); + if (CollectionUtil.isEmpty(records)) { + return new ArrayList<>(); + } + return records.stream().map(record -> { + PhotovoltaicPowerVo load = new PhotovoltaicPowerVo(); + Date time = DateUtil.parse(record.getTs(), "yyyy-MM-dd HH:mm:ss.s"); + load.setHour(time.getHours()); + load.setActivePower(Optional.ofNullable(record.getVal()).orElse("0")); + return load; + }).sorted(Comparator.comparing(PhotovoltaicPowerVo::getHour)).collect(Collectors.toList()); + } + + /** + * 近30天发电量 + * + * @param device + * @return + */ + private List getGenerateByMon(EminfoAndEmParamVo device) { + Calendar calendar = Calendar.getInstance(); + String end = DateUtil.format(calendar.getTime(), DateUtil.PATTERN_DATETIME); + calendar.add(Calendar.DAY_OF_MONTH, -29); + calendar.add(Calendar.HOUR_OF_DAY, -calendar.get(Calendar.HOUR_OF_DAY)); + calendar.add(Calendar.MINUTE, -calendar.get(Calendar.MINUTE)); + calendar.add(Calendar.SECOND, -calendar.get(Calendar.SECOND)); + String start = DateUtil.format(calendar.getTime(), DateUtil.PATTERN_DATETIME); + List records = analyseDataService.periodTargetData(start, end, 5, 3, device.getEmCode(), HomePageConstant.PV_GENERATION_CAPACITY); + if (CollectionUtil.isEmpty(records)) { + return new ArrayList<>(); + } + return records.stream().map(record -> { + GenerationPowerVo generate = new GenerationPowerVo(); + Date time = DateUtil.parse(record.getTs(), "yyyy-MM-dd HH:mm:ss.s"); + generate.setDate(DateUtil.format(time, DateUtil.PATTERN_DATE)); + generate.setGenerate(Float.valueOf(Optional.ofNullable(record.getVal()).orElse("0"))); + return generate; + }).sorted(Comparator.comparing(GenerationPowerVo::getDate)).collect(Collectors.toList()); + } + + /** + * 获取光伏站点填报数据 + * @param stations + * @return + */ + private List generateFill(List stations) { + Calendar calendar = Calendar.getInstance(); + String mon = DateUtil.format(calendar.getTime(),"yyyy-MM"); + String year = String.valueOf(calendar.get(Calendar.YEAR)); + return stations.stream().map(station ->{ + PhotovoltaicTargetVo target = new PhotovoltaicTargetVo(); + target.setDeptId(station.getRefDept()); + target.setDeptName(station.getName()); + // 当日运行时长 + target.setRunHours(0.0); + // 日发电量 + target.setGenerationDay(0.0); + // 昨日发电量 + target.setGenerationYesterday(0.0); + // 收益 + target.setIncome(0.0); + // 日发电量 + // 月发电量 + target.setGenerationMon(powerService.generate(mon,station.getRefDept())); + // 节约标准煤 + target.setTec(target.getGenerationMon() * 0.0001229); + // 二氧化碳减排 + target.setCo2(target.getGenerationMon() * 0.000997); + // 减少森林砍伐 + target.setDeforest(target.getGenerationMon() * 0.000553); + // 年发电量 + target.setGenerationYear(powerService.generate(year,station.getRefDept())); + // 30天发电量 + return target; + }).collect(Collectors.toList()); + } + + /** + * 泵站设备 + * @param stations + * @return + */ + private List pumpDevices(List stations){ + if(CollectionUtil.isEmpty(stations)){ + return new ArrayList<>(); + } + List devices = null; + Object json = redisTemplate.opsForValue().get(device_cache_cofig_final); + if (ObjectUtil.isNotEmpty(json)) { + devices = JSONObject.parseObject(json.toString(),new TypeReference>() {}); + } + if(CollectionUtil.isEmpty(devices)){ + return new ArrayList<>(); + } + return devices.stream().filter(device->stations.contains(device.getCreateDept())).collect(Collectors.toList()); + } + + /** + * 获取实时数据 + * @return + */ + private Map getRealMap() { + String json = (String) redisTemplate.opsForValue().get(real_id_cofig_final); + if(StringUtil.isBlank(json)){ + return null; + } + return JSONObject.parseObject(json, new TypeReference>() {}); + } + + + /** + * 获取监测点实时数据 + * @param device + * @param targets + * @return + */ + private double getSignageValue(EminfoAndEmParamVo device,Map map, String targets) { + if(ObjectUtil.isEmpty(device) || MapUtils.isEmpty(map)){ + return 0.0; + } + Map point = device.getPoint(); + if(MapUtils.isEmpty(point)){ + return 0.0; + } + String realId = point.get(targets); + if(StringUtil.isBlank(realId)){ + return 0.0; + } + String value = map.get(realId); + if(StringUtil.isBlank(value)){ + return 0.0; + } + // 获取value + return Double.parseDouble(value); + } + + /** + * 单位设置 + * @param device + * @param unitMap + * @param realVo + */ + private void setttingUnit(EminfoAndEmParamVo device, Map unitMap, HydropowerUnitRealVo realVo) { + if(MapUtils.isEmpty(unitMap)){ + return; + } + // 有功功率单位 + String power = unitMap.get(device.getId()+HomePageConstant.CONCAT_P); + if(StringUtil.isNotBlank(power)){ + realVo.setPowerUnit(power); + } else { + realVo.setPowerUnit("kW"); + } + // 无功功率 + String reactivePowerUnit = unitMap.get(device.getId()+HomePageConstant.CONCAT_Q); + if(StringUtil.isNotBlank(reactivePowerUnit)){ + realVo.setReactivePowerUnit(reactivePowerUnit); + } else { + realVo.setReactivePowerUnit("kVa r"); + } + // 定子电压单位 + String voltage = unitMap.get(device.getId()+HomePageConstant.CONCAT_UAB); + if(StringUtil.isNotBlank(voltage)){ + realVo.setVoltageUnit(voltage); + } else { + realVo.setVoltageUnit("V"); + } + // 定子电流单位 + String current = unitMap.get(device.getId()+HomePageConstant.CONCAT_IA); + if(StringUtil.isNotBlank(current)){ + realVo.setCurrentUnit(current); + } else { + realVo.setCurrentUnit("A"); + } + } + + /** + * 获取年、月、日发电量 + * @param device + * @param scope + * @return + */ + private float getGenerationPower(EminfoAndEmParamVo device,int scope) { + String start,end; + int accessRules; + Calendar calendar = Calendar.getInstance(); + switch (scope){ + // 年 + case 0: + end = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATETIME); + calendar.setTime(new Date()); + calendar.add(Calendar.MONTH, -calendar.get(Calendar.MONTH)); + calendar.add(Calendar.DATE, -calendar.get(Calendar.DATE) + 1); + start = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE) + " 00:00:00"; + accessRules = EquipmentConstants.CycleTypeEnum.YEAR_CYCLE.getType(); + break; + // 月 + case 1: + start = DateUtil.format(new Date(), "yyyy-MM") + "-01 00:00:00"; + end = DateUtil.format(new Date(), DateUtil.PATTERN_DATETIME); + accessRules = EquipmentConstants.CycleTypeEnum.MONTH_CYCLE.getType(); + break; + // 日 + case 2: + String time = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + start = time + " 00:00:00"; + end = time + " 23:59:59"; + accessRules = EquipmentConstants.CycleTypeEnum.DAY_CYCLE.getType(); + break; + default: + throw new IllegalStateException("Unexpected value: " + scope); + } + return analyseDataService.periodTargetFloat(start,end,5,accessRules,device.getEmCode(),device.getRideCount(),HomePageConstant.HYDROPOWER_GENERATE_POWER); + } + + /** + * 近30天发电量 + * @param device + * @return + */ + private List getGenerationPowerList(EminfoAndEmParamVo device) { + String start = DateUtil.format(new Date(), "yyyy-MM") + "-01 00:00:00"; + String end = DateUtil.format(new Date(), DateUtil.PATTERN_DATETIME); + List records = analyseDataService.periodTargetData(start,end,5,EquipmentConstants.CycleTypeEnum.DAY_CYCLE.getType(),device.getEmCode(),HomePageConstant.HYDROPOWER_GENERATE_POWER); + if(CollectionUtil.isEmpty(records)){ + return new ArrayList<>(); + } + return records.stream().map(record -> { + GenerationPowerVo generate = new GenerationPowerVo(); + Date time = DateUtil.parse(record.getTs(), "yyyy-MM-dd HH:mm:ss.s"); + generate.setDate(DateUtil.format(time,DateUtil.PATTERN_DATE)); + generate.setGenerate(Float.parseFloat(Optional.ofNullable(record.getVal()).orElse("0")) * device.getRideCount()); + return generate; + }).collect(Collectors.toList()); + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RecordServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RecordServiceImpl.java new file mode 100644 index 0000000..d5489b8 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RecordServiceImpl.java @@ -0,0 +1,36 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.hnac.hzims.operational.config.entity.StAlarmRecordEntity; +import com.hnac.hzims.scheduled.mapper.operation.RecordMapper; +import com.hnac.hzims.scheduled.service.operation.RecordService; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +import java.util.Date; + +/** + * @author ysj + */ +@Service +@RequiredArgsConstructor +@Slf4j +public class RecordServiceImpl extends BaseServiceImpl implements RecordService { + + /** + * 添加告警 + * @param stationId + * @param realId + * @return + */ + @Override + public Long insertAlert(String stationId, String realId) { + StAlarmRecordEntity record = new StAlarmRecordEntity(); + record.setStationId(stationId); + record.setRealId(realId); + record.setStatus(0); + record.setCreateTime(new Date()); + return this.baseMapper.insertReturnId(record); + } +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationAttrConfigServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationAttrConfigServiceImpl.java new file mode 100644 index 0000000..d928365 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationAttrConfigServiceImpl.java @@ -0,0 +1,34 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.hnac.hzims.operational.station.entity.StationAttrConfigEntity; +import com.hnac.hzims.scheduled.mapper.operation.StationAttrConfigMapper; +import com.hnac.hzims.scheduled.service.operation.StationAttrConfigService; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springframework.stereotype.Service; + +import java.util.ArrayList; +import java.util.List; +import java.util.stream.Collectors; + +/** + * @author ysj + */ +@Service +@Slf4j +public class StationAttrConfigServiceImpl extends BaseServiceImpl implements StationAttrConfigService { + + @Override + public List getHideList() { + List list = this.list(new QueryWrapper() {{ + eq("ENABLE_SHOW", false); + eq("IS_DELETED",0); + }}); + if(CollectionUtil.isEmpty(list)){ + return new ArrayList<>(); + } + return list.stream().map(StationAttrConfigEntity::getEmName).collect(Collectors.toList()); + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationAttributeServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationAttributeServiceImpl.java new file mode 100644 index 0000000..122278e --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationAttributeServiceImpl.java @@ -0,0 +1,36 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.hnac.hzims.operational.station.entity.StationAttributeEntity; +import com.hnac.hzims.scheduled.mapper.operation.StationAttributeMapper; +import com.hnac.hzims.scheduled.service.operation.StationAttributeService; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springframework.stereotype.Service; + +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + +/** + * @author hx + */ +@Service +@Slf4j +@RequiredArgsConstructor +public class StationAttributeServiceImpl extends BaseServiceImpl implements StationAttributeService { + + /** + * 获取集中监控监测点单位 + * @return + */ + @Override + public Map PointUnit() { + List list = this.baseMapper.PointUnit(); + if(CollectionUtil.isEmpty(list)){ + return null; + } + return list.stream().collect(Collectors.toMap(StationAttributeEntity::getAttributes, StationAttributeEntity::getUnit)); + } +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationServiceImpl.java new file mode 100644 index 0000000..8735909 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/StationServiceImpl.java @@ -0,0 +1,19 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.hnac.hzims.operational.station.entity.StationEntity; +import com.hnac.hzims.scheduled.mapper.operation.StationMapper; +import com.hnac.hzims.scheduled.service.operation.StationService; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author hx + */ +@Service +@RequiredArgsConstructor +@Slf4j +public class StationServiceImpl extends BaseServiceImpl implements StationService { + +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/UseServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/UseServiceImpl.java new file mode 100644 index 0000000..82ba5b1 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/UseServiceImpl.java @@ -0,0 +1,99 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.hnac.hzims.operational.fill.entity.UseEntity; +import com.hnac.hzims.operational.main.vo.UsrPowerVo; +import com.hnac.hzims.scheduled.mapper.operation.UseMapper; +import com.hnac.hzims.scheduled.service.operation.UseService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.DateUtil; +import org.springframework.stereotype.Service; + +import java.util.*; +import java.util.stream.Collectors; + +/** + * @author ysj + * @date 2023/04/10 11:16:07 + * @version 4.0.0 + */ +@Slf4j +@Service +@AllArgsConstructor +public class UseServiceImpl extends BaseServiceImpl implements UseService { + + /** + * 根据时间、机构查询用电量 + * @param date 时间: 年 - yyyy/月 yyyy-mm/日 yyyy-mm-dd + * @param station 所属机构 + * @return + */ + @Override + public Float use(String date, String station) { + List powers = this.list(Wrappers.lambdaQuery() + .likeRight(UseEntity::getFillDate,date) + .eq(UseEntity::getStationCode,station) + ); + if(CollectionUtil.isEmpty(powers)){ + return 0f; + } + return (float) powers.stream().mapToDouble(UseEntity::getEmploy).sum(); + } + + /** + * 查询30天填报用电量 + * @param day : 结束日期 yyyy-MM-dd + * @param station 站点编码 + * @return + */ + @Override + public List use30Day(String day, String station) { + Calendar calendar = Calendar.getInstance(); + calendar.setTime(DateUtil.parse(day,DateUtil.PATTERN_DATE)); + String end = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + calendar.add(Calendar.DAY_OF_MONTH,-29); + String start = DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + List records = this.list(Wrappers.lambdaQuery() + .between(UseEntity::getFillDate,start,end) + .eq(UseEntity::getStationCode,station) + ); + if(CollectionUtil.isEmpty(records)){ + return new ArrayList<>(); + } + return records.stream().map(record->{ + UsrPowerVo use = new UsrPowerVo(); + use.setDate(record.getFillDate()); + if(Math.abs(record.getEmploy()) <= 0){ + use.setUsrPower(0f); + }else{ + use.setUsrPower(Float.parseFloat(record.getEmploy().toString())); + } + return use; + }).collect(Collectors.toList()); + } + + /** + * 查询近3年的填报用电量 + * @param start + * @param end + * @param station + * @return + */ + @Override + public Map generateThreeYear(String start, String end, String station) { + List records = this.list(Wrappers.lambdaQuery() + .between(UseEntity::getFillDate,start,end) + .eq(UseEntity::getStationCode,station) + ); + if(CollectionUtil.isEmpty(records)){ + return new HashMap<>(); + + } + return records.stream().peek(record-> record.setFillDate(DateUtil.format(DateUtil.parse(record.getFillDate(),"yyyy-MM"),"yyyy-MM") + "-01")). + collect(Collectors.toMap(UseEntity::getFillDate, value->Float.parseFloat(value.getEmploy().toString()),Float::sum)); + } + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealAttributeVo.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealAttributeVo.java deleted file mode 100644 index 00ea9d8..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealAttributeVo.java +++ /dev/null @@ -1,52 +0,0 @@ -package com.hnac.hzims.scheduled.vo; - -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -import java.io.Serializable; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 15:27 - */ -@Data -public class RealAttributeVo implements Serializable { - - @ApiModelProperty("属性名称") - private String name; - - @ApiModelProperty("属性数值") - private String value; - - @ApiModelProperty("属性单位") - private String unit; - - @ApiModelProperty("属性类型:1-遥信 2-遥测") - private Integer type; - - @ApiModelProperty("属性实时数据Id") - private String realId; - - @ApiModelProperty("告警Id") - private Long id; - - @ApiModelProperty("属性状态:0:正常、1:预警、2:告警、3:空值、4:黄色、5:橙色") - private int status; - - @ApiModelProperty("属性质量") - private int quality; - - @ApiModelProperty("属性时间") - private String time; - - @ApiModelProperty("属性故障ID") - private String fdpFaultId; - - @ApiModelProperty("监测点") - private String fdpMonitorId; - - @ApiModelProperty("属性故障值") - private Double fdpRate; -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealDeviceVo.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealDeviceVo.java deleted file mode 100644 index 330a5df..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealDeviceVo.java +++ /dev/null @@ -1,33 +0,0 @@ -package com.hnac.hzims.scheduled.vo; - -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -import java.io.Serializable; -import java.util.List; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 15:26 - */ -@Data -public class RealDeviceVo implements Serializable { - - @ApiModelProperty("设备编号") - private String deviceCode; - - @ApiModelProperty("设备名称") - private String deviceName; - - @ApiModelProperty("设备状态") - private Integer state; - - @ApiModelProperty("排序字段") - private Integer sort; - - @ApiModelProperty("设备属性集合") - private List attbtList; -} - diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealStationVo.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealStationVo.java deleted file mode 100644 index 00a0c9e..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/RealStationVo.java +++ /dev/null @@ -1,54 +0,0 @@ -package com.hnac.hzims.scheduled.vo; - -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -import java.io.Serializable; -import java.util.List; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 15:24 - */ -@Data -public class RealStationVo implements Serializable { - - @ApiModelProperty("站点Id") - private String stationCode; - - @ApiModelProperty("站点名称") - private String stationName; - - @ApiModelProperty("站点机构Id") - private Long stationDeptId; - - @ApiModelProperty("站点类型") - private String serverType; - - @ApiModelProperty("当前天气") - private WeatherVo nowWater; - - @ApiModelProperty("总有功率") - private Double powerSum; - - @ApiModelProperty("降水") - private String precipitation; - - @ApiModelProperty("最大前池水位") - private Double waterLevelMax; - - @ApiModelProperty("前池水位") - private Double waterLevel; - - @ApiModelProperty("设备集合") - private List deviceList; - - @ApiModelProperty("站点状态 : 0-正常 1-数据中断") - private Integer status; - - @ApiModelProperty("排序") - private Integer sort; -} - diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/StationRealVo.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/StationRealVo.java deleted file mode 100644 index 8e9d7da..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/StationRealVo.java +++ /dev/null @@ -1,17 +0,0 @@ -package com.hnac.hzims.scheduled.vo; - -import lombok.Data; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 11:43 - */ -@Data -public class StationRealVo { - - private String station; - - private String[] realId; -} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/WeatherVo.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/WeatherVo.java deleted file mode 100644 index bd46d22..0000000 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/vo/WeatherVo.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.hnac.hzims.scheduled.vo; - -import lombok.Data; - -import java.io.Serializable; - -/** - * @Author WL - * @Version v1.0 - * @Serial 1.0 - * @Date 2023/5/19 15:25 - */ -@Data -public class WeatherVo implements Serializable { - - /**当前天气状况和图标的代码,图标可通过天气状况和图标下载; //100**/ - private String icon; - - /**实况温度,默认单位:摄氏度; //21**/ - private String temp; - - /**实况天气状况的文字描述,包括阴晴雨雪等天气状态的描述; //晴**/ - private String text; - - /**预报当天最高温度; //4**/ - private String tempMax; - - /**预报当天最低温度; //-5**/ - private String tempMin; -} diff --git a/hzims-service/hzims-scheduled/src/main/resources/application.yml b/hzims-service/hzims-scheduled/src/main/resources/application.yml deleted file mode 100644 index e738d56..0000000 --- a/hzims-service/hzims-scheduled/src/main/resources/application.yml +++ /dev/null @@ -1,208 +0,0 @@ -#服务器端口 -server: - port: 8501 - -#数据源配置 -spring: - cloud: - nacos: - discovery: - server-addr: 175.6.40.67:10056 - config: - server-addr: 175.6.40.67:10056 - application: - name: hzims-scheduled - main: - allow-bean-definition-overriding: true - #排除DruidDataSourceAutoConfigure - autoconfigure: - exclude: com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure - datasource: - dynamic: - primary: operational #设置默认的数据源或者数据源组,默认值即为master - strict: false #严格匹配数据源,默认false. true未匹配到指定数据源时抛异常,false使用默认数据源 - datasource: - operational: - url: jdbc:mysql://192.168.1.3:3576/dev_hzims_operation?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&transformedBitIsBoolean=true&tinyInt1isBit=false&allowMultiQueries=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true&allowPublicKeyRetrieval=true - username: root - password: 123 - redis: - # redis数据库索引(默认为0),我们使用索引为0的数据库,避免和其他数据库冲突 - database: 0 - # redis服务器地址(默认为localhost) - host: 192.168.1.3 - # redis端口(默认为6379) - port: 3577 - # redis访问密码(默认为空) - password: 1qaz2WSX@redis - -#xxl: -# job: -# accessToken: '' -# admin: -# addresses: http://192.168.1.3:7009/xxl-job-admin -# executor: -# appname: hzims-operational -# ip: 192.168.1.3 -# logpath: /data/applogs/xxl-job/jobhandler -# logretentiondays: -1 -# port: 28501 - -xxl: - job: - accessToken: '' - admin: - addresses: http://192.168.5.128:9080/xxl-job-admin - executor: - appname: hzims-operational - ip: 192.168.18.232 - logpath: /data/applogs/xxl-job/jobhandler - logretentiondays: -1 - port: 28501 - - -#mybatis-plus配置 -mybatis-plus: - mapper-locations: classpath*:/mapper/**/*.xml - #实体扫描,多个package用逗号或者分号分隔 -# typeAliasesPackage: com.hnac.hzims.**.entity - configuration: - log-impl: org.apache.ibatis.logging.stdout.StdOutImpl - -#swagger扫描路径配置 -swagger: - base-packages: - - org.springbalde - - com.hnac - -hzims: - # 视频配置地址随机码 - video: - random-code: qnrld30yto85cji5 - # 视频配置秘钥属性 - videoProperties: - appKey: 21111042 - videoHost: 42.192.39.246:443 - appSecret: QXRevZ2AQeXtmlYZT6Rf - equipment: - emInfo: - code: hzims:equipment:emInfo:deviceCode.stationDeviceCode - emInfoList: hzims:equipment:emInfo:deviceCode.emInfoList - fdp: - redisData: hzims:equipment:fdp:fault.data.realIdAndValueList - greaterThan: 0.3 - lessThan: 0.9 - beEqualOrGreaterThan: 0.9 - alert: - # 接收告警的websocket url - ws-url: wss://175.6.40.67:9036/api/hzinfo-data-socket/websocket/soe - config: - #接收遥测或遥信实时数据的websocket url - ws-url: wss://175.6.40.67:9036/api/hzinfo-data-socket/websocket/data - level: - ws-url: wss://175.6.40.67:9036/api/hzinfo-data-socket/websocket/alarm - pdf: - # pdf文件存储路径,请配置绝对路径 - #file-path: /data/inspect/pdf/file - file-path: D:/data/hzinfo/file # windows - operation: - access: - task-key: hzims:operation:access:task - alert: - saveDefectIsOpen: true - save: - area: - url: http://49.234.126.72:8255/apiIntroduction/demo/saveHzimsArea - station: - url: http://49.234.126.72:8255/apiIntroduction/demo/saveHzimsStation - defect: - repair: /data/hzims/operational/defect/repair/应急抢修单.docx - area: - report: hzims.operation.area.report - monitor: - station: hzims:operation:monitor:station - realId : hzims:operation:monitor:realId - region: - areaDutyInfoKey: hzims:operation:region:areaDutyInfoKey - deviceClassifyKey: hzims.operation.region.deviceClassifyKey - projectDepartmentId: 200000000000101 - projectDepartmentName: 智能运维事业部 - notInDept: 2000000000001010048,2000000000001010049,2000000000001010050 - tenantId: 200000 - #工单返回记录(暂存) - workOrder: - access: hzims:operation:workOrder.access - defect: hzims:operation:workOrder.defect - task: - # 消息推送存入redis的key值 - templateCode: - maintenance: - taskDispose: hzinfo:operation:maintenance:task - # 消息推送code - jgPushCode: ops-push - comprehensiveD: hzims:operation:comprehensiveD:real.time - realIdKey: hzims:operation:comprehensiveD:realIdKey.realData - lastDayRealIdKey: hzims:operation:comprehensiveD:lastDayRealIdKey.realData - realIdKeyGather: hzims:operation:comprehensiveD:realIdKeyGather.realData - homePage: - charge: - url: https://www.hznychh.cn/api/charging-manage/manage/external/provide?secretKey=f5aee9fe24e4d1d80eb7564414392bc3 - activePowerKey: hzims:operation:homePage:activePowerKey - jointRelayKey: hzims:operation:homePage:jointRelayKey - systemMonitoring: - hydropowerStation: - hisData: hzims:operation:homePage:systemMonitoring:hydropowerStation:hisData:. - hisDataActivePower: hzims:operation:homePage:systemMonitoring:hydropowerStation:hisDataActivePower:. - theDayHydrograph: hzims:operation:homePage:systemMonitoring:hydropowerStation:theDayHydrograph:. - yearGeneration: hzims:operation:homePage:systemMonitoring:hydropowerStation:yearGeneration.data - hisDataNew: hzims:operation:homePage:systemMonitoring:hydropowerStation:hisDataNew - theDayHydrographNew: hzims:operation:homePage:systemMonitoring:hydropowerStation:theDayHydrographNew - alarm: - # "0-默认", "1-系统", "2-告警", "3-故障", "4-用户操作", "5-遥测越限", "6-遥信变位", "7-注册信息", "8-信息提示", "9-设备巡检", "10-遥控操作", "11-遥测越限恢复","12-未定义","13-通讯中断","14-数据异常" - types: 3,2,5,13,14 - -category: - id: 1384429129110360065 - -sanya: - one: 2000000000001010048 - tow: 2000000000001010049 - hoop: 2000000000001010050 - -defect: - # 超时自动甄别时间间隔:单位(小时) - discriminateDeadline: 1 - # 默认计划工时:单位(小时) - defaultPlanHoure: 8 - -blade: - data: - sdk: - enabled: true - url: http://175.6.40.67:37681/api/hzinfo-data-config - appId: '1635888805125099521' - appSecret: f4b6a4dc696b36445d2e5d38bbab2417 - redisIp: 192.168.1.13 - redisPort: 3577 - password: L_MM&h=+Nm&p)U9sk.uH - maxKeys: 1000 - data-scope: - enabled: false - lock: - enabled: true - address: redis://192.168.1.3:3577 - password: - database: 0 - ssl: false - -url: - video: - stationsPath: http://localhost:10001/stations - monitorsPath: http://localhost:10001/monitor - login: https://175.6.40.67:9300/hzApi/auth/mix/login?tenantId=200000&account=videoViewers&pwd=e10adc3949ba59abbe56e057f20f883e&grant_type=password&scope=all&type=account - water-out: - #工单受理 - orderCrtPackage: http://175.6.40.67:9021/api/water-out/orderCrt/package - orderCrtGrabPackage: http://175.6.40.67:9021/api/water-out/orderCrt/grabPackage - - diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/equipment/WorkshopInfoMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/equipment/WorkshopInfoMapper.xml new file mode 100644 index 0000000..933d153 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/equipment/WorkshopInfoMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/AbnormalAlarmMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/AbnormalAlarmMapper.xml index 49c1076..aab621f 100644 --- a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/AbnormalAlarmMapper.xml +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/AbnormalAlarmMapper.xml @@ -2,16 +2,10 @@ - - select distinct station_id from hzims_abnormal_alarm where is_deleted = 0 - and type in (13,14) - and `STATUS` = 0 + and type in (13,14) + and `STATUS` = 0 diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/GenerateMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/GenerateMapper.xml new file mode 100644 index 0000000..2f3e18b --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/GenerateMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/ModelStationMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/ModelStationMapper.xml new file mode 100644 index 0000000..df6a033 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/ModelStationMapper.xml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/PowerMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/PowerMapper.xml new file mode 100644 index 0000000..73820fc --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/PowerMapper.xml @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + ID, MON, INSTALLED_CAPACITY , PLANNED_POWER_YEAR , PLANNED_POWER_MON , POWER_MON , POWER_RATE_MON ,POWER_YEAR , + POWER_RATE_YEAR , DOUBLE_QUALIFY_RATE , TYPE , TENANT_ID, STATUS, CREATE_TIME, UPDATE_TIME, CREATE_USER, UPDATE_USER, + IS_DELETED, CREATE_DEPT + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/RecordMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/RecordMapper.xml new file mode 100644 index 0000000..6086a5f --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/RecordMapper.xml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + SELECT LAST_INSERT_ID() AS id + + insert into hy_st_alarm_record (id, station_id, real_id, + status, phone_record, process_desc, + create_time, processor, process_time + ) + values (#{id,jdbcType=BIGINT}, #{stationId,jdbcType=VARCHAR}, #{realId,jdbcType=VARCHAR}, + #{status,jdbcType=TINYINT}, #{phoneRecord,jdbcType=VARCHAR}, #{processDesc,jdbcType=VARCHAR}, + #{createTime,jdbcType=TIMESTAMP}, #{processor,jdbcType=VARCHAR}, #{processTime,jdbcType=TIMESTAMP} + ) + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StAlarmRecordMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StAlarmRecordMapper.xml deleted file mode 100644 index cfe513d..0000000 --- a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StAlarmRecordMapper.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - SELECT LAST_INSERT_ID() AS id - - insert into hy_st_alarm_record (id, station_id, real_id, - status, phone_record, process_desc, - create_time, processor, process_time - ) - values (#{id,jdbcType=BIGINT}, #{stationId,jdbcType=VARCHAR}, #{realId,jdbcType=VARCHAR}, - #{status,jdbcType=TINYINT}, #{phoneRecord,jdbcType=VARCHAR}, #{processDesc,jdbcType=VARCHAR}, - #{createTime,jdbcType=TIMESTAMP}, #{processor,jdbcType=VARCHAR}, #{processTime,jdbcType=TIMESTAMP} - ) - - - \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationAttrConfigMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationAttrConfigMapper.xml new file mode 100644 index 0000000..bf7b1e0 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationAttrConfigMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationAttributeMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationAttributeMapper.xml new file mode 100644 index 0000000..525d6fc --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationAttributeMapper.xml @@ -0,0 +1,15 @@ + + + + + + + \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationMapper.xml new file mode 100644 index 0000000..23312d6 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/StationMapper.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/UseMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/UseMapper.xml new file mode 100644 index 0000000..021eaf7 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/UseMapper.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/controller/CentralMonitorController.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/controller/CentralMonitorController.java index da4018a..0989365 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/controller/CentralMonitorController.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/controller/CentralMonitorController.java @@ -3,7 +3,7 @@ package com.hnac.hzims.operational.config.controller; import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; import com.hnac.hzims.operational.config.service.CentralMonitorService; import com.hnac.hzims.operational.station.service.IRealMonitorService; -import com.hnac.hzims.operational.station.vo.RealStationVo; +import com.hnac.hzims.operational.main.vo.RealStationVo; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import lombok.AllArgsConstructor; diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/CentralMonitorService.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/CentralMonitorService.java index 46bedcf..040e7c9 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/CentralMonitorService.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/CentralMonitorService.java @@ -1,7 +1,7 @@ package com.hnac.hzims.operational.config.service; -import com.hnac.hzims.operational.station.vo.RealStationVo; +import com.hnac.hzims.operational.main.vo.RealStationVo; import java.util.List; diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/CentralMonitorServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/CentralMonitorServiceImpl.java index 07b632d..2124c9c 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/CentralMonitorServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/CentralMonitorServiceImpl.java @@ -4,7 +4,7 @@ import com.hnac.hzims.operational.config.service.CentralMonitorService; import com.hnac.hzims.operational.main.constant.HomePageConstant; import com.hnac.hzims.operational.station.entity.StationEntity; import com.hnac.hzims.operational.station.service.IStationService; -import com.hnac.hzims.operational.station.vo.RealStationVo; +import com.hnac.hzims.operational.main.vo.RealStationVo; import lombok.RequiredArgsConstructor; import org.springblade.core.tool.api.R; import org.springblade.core.tool.utils.CollectionUtil; diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/StAlamRecordServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/StAlamRecordServiceImpl.java index 5114295..95e30cd 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/StAlamRecordServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/StAlamRecordServiceImpl.java @@ -236,7 +236,7 @@ public class StAlamRecordServiceImpl extends BaseServiceImpl stFocusPropertiesEntity.getUpperUpperLimit() || Double.valueOf(value) < stFocusPropertiesEntity.getLowerLowerLimit())) { if (alarmList.size() > 0) { - time = new Date().getTime() - alarmList.get(0).getProcessTime().getTime(); + time = System.currentTimeMillis() - alarmList.get(0).getProcessTime().getTime(); } if ((recordList.size() == 0 && alarmList.size() == 0) || (time / 1000 / 60 > 30 && recordList.size() == 0)) { isWarn = setStAlarmRecordEntity(dataSet, stFocusPropertiesEntity, isWarn, 2, true); @@ -251,7 +251,7 @@ public class StAlamRecordServiceImpl extends BaseServiceImpl stFocusPropertiesEntity.getUpperLimit() && Double.valueOf(value) < stFocusPropertiesEntity.getUpperUpperLimit()) || (Double.valueOf(value) > stFocusPropertiesEntity.getLowerLowerLimit() && Double.valueOf(value) < stFocusPropertiesEntity.getLowerLimit()))) { if (alarmList.size() > 0) { - time = new Date().getTime() - alarmList.get(0).getProcessTime().getTime(); + time = System.currentTimeMillis() - alarmList.get(0).getProcessTime().getTime(); } if ((recordList.size() == 0 && alarmList.size() == 0) || (time / 1000 / 60 > 30 && recordList.size() == 0)) { isWarn = setStAlarmRecordEntity(dataSet, stFocusPropertiesEntity, isWarn, ConfigStatus.ConfigStatusEnum.RED.getStatus(), false); @@ -728,7 +728,7 @@ public class StAlamRecordServiceImpl extends BaseServiceImpl getFaultList(String code) { List stations = this.getStationByUserAuth(code);; - if(CollectionUtil.isEmpty(stations)){ + /*if(CollectionUtil.isEmpty(stations)){ return null; } String result = fdpMonitorClient.getFaultList(); @@ -738,7 +738,21 @@ public class StAlamRecordServiceImpl extends BaseServiceImpl list = JSONArray.parseArray(result,FaultVo.class); if(CollectionUtil.isEmpty(list)){ return new ArrayList<>(); - } + }*/ + List list = new ArrayList<>(); + FaultVo test =new FaultVo(); + test.setInfo("可是我不会忘"); + test.setFtype("1"); + test.setFaultId("114233824210698186"); + test.setName("爱来爱去空一场"); + test.setStationName("海南三亚大隆一级电站"); + test.setStation("902100000026"); + test.setStatus("0"); + test.setCreateTime("2023-06-01 09:55:33"); + test.setOrd("1"); + test.setFtype("1"); + test.setFinfo("你说人这东西可信不可信,骗子脸上又不会写字"); + list.add(test); Map map = stations.stream().collect(Collectors.toMap(StationEntity::getCode,StationEntity::getName)); // 查询已处理预警数据 List handles = handleService.handles(Collections.singletonList(AbnormalAlarmConstant.EARLY_WARNING),null); diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/vo/StationRealVo.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/vo/StationRealVo.java deleted file mode 100644 index e61f1d2..0000000 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/vo/StationRealVo.java +++ /dev/null @@ -1,12 +0,0 @@ -package com.hnac.hzims.operational.config.vo; - -import lombok.Data; - -@Data -public class StationRealVo { - - private String station; - - private String[] realId; - -} diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/main/service/impl/HydropowerServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/main/service/impl/HydropowerServiceImpl.java index 8a6cb12..f1f74b4 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/main/service/impl/HydropowerServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/main/service/impl/HydropowerServiceImpl.java @@ -269,6 +269,7 @@ public class HydropowerServiceImpl implements HydropowerService { stationList.forEach(station -> { // 站点设备集合 List stationDevices = devices.stream().filter(device -> device.getCreateDept().equals(station.getRefDept())).collect(Collectors.toList()); + log.error("load_power_data station :" + station.getCode() + "==== device :" + stationDevices ); Map generateMap = this.getGenerateYear(station,stationDevices,start,end); if(MapUtils.isEmpty(generateMap)){ return; diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/RealMonitorServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/RealMonitorServiceImpl.java index 7150980..9cd48e0 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/RealMonitorServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/RealMonitorServiceImpl.java @@ -27,10 +27,10 @@ import com.hnac.hzims.operational.station.service.IRealMonitorService; import com.hnac.hzims.operational.station.service.IStationAttrConfigService; import com.hnac.hzims.operational.station.service.IStationAttributeService; import com.hnac.hzims.operational.station.service.IStationService; -import com.hnac.hzims.operational.station.vo.RealAttributeVo; -import com.hnac.hzims.operational.station.vo.RealDeviceVo; -import com.hnac.hzims.operational.station.vo.RealStationVo; -import com.hnac.hzims.operational.station.vo.WeatherVo; +import com.hnac.hzims.operational.main.vo.RealAttributeVo; +import com.hnac.hzims.operational.main.vo.RealDeviceVo; +import com.hnac.hzims.operational.main.vo.RealStationVo; +import com.hnac.hzims.operational.main.vo.WeatherVo; import com.hnac.hzinfo.sdk.v5.redis.RedisClient; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealAttributeVo.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealAttributeVo.java deleted file mode 100644 index 7e6c9c2..0000000 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealAttributeVo.java +++ /dev/null @@ -1,46 +0,0 @@ -package com.hnac.hzims.operational.station.vo; - -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -import java.io.Serializable; - -@Data -public class RealAttributeVo implements Serializable { - - @ApiModelProperty("属性名称") - private String name; - - @ApiModelProperty("属性数值") - private String value; - - @ApiModelProperty("属性单位") - private String unit; - - @ApiModelProperty("属性类型:1-遥信 2-遥测") - private Integer type; - - @ApiModelProperty("属性实时数据Id") - private String realId; - - @ApiModelProperty("告警Id") - private Long id; - - @ApiModelProperty("属性状态:0:正常、1:预警、2:告警、3:空值、4:黄色、5:橙色") - private int status; - - @ApiModelProperty("属性质量") - private int quality; - - @ApiModelProperty("属性时间") - private String time; - - @ApiModelProperty("属性故障ID") - private String fdpFaultId; - - @ApiModelProperty("监测点") - private String fdpMonitorId; - - @ApiModelProperty("属性故障值") - private Double fdpRate; -} diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealDeviceVo.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealDeviceVo.java deleted file mode 100644 index 5d7319e..0000000 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealDeviceVo.java +++ /dev/null @@ -1,26 +0,0 @@ -package com.hnac.hzims.operational.station.vo; - -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -import java.io.Serializable; -import java.util.List; - -@Data -public class RealDeviceVo implements Serializable { - - @ApiModelProperty("设备编号") - private String deviceCode; - - @ApiModelProperty("设备名称") - private String deviceName; - - @ApiModelProperty("设备状态") - private Integer state; - - @ApiModelProperty("排序字段") - private Integer sort; - - @ApiModelProperty("设备属性集合") - private List attbtList; -} diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealStationVo.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealStationVo.java deleted file mode 100644 index 876eaf5..0000000 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/RealStationVo.java +++ /dev/null @@ -1,48 +0,0 @@ -package com.hnac.hzims.operational.station.vo; - -import io.swagger.annotations.ApiModelProperty; -import io.swagger.models.auth.In; -import lombok.Data; - -import java.io.Serializable; -import java.util.List; - -@Data -public class RealStationVo implements Serializable { - - @ApiModelProperty("站点Id") - private String stationCode; - - @ApiModelProperty("站点名称") - private String stationName; - - @ApiModelProperty("站点机构Id") - private Long stationDeptId; - - @ApiModelProperty("站点类型") - private String serverType; - - @ApiModelProperty("当前天气") - private WeatherVo nowWater; - - @ApiModelProperty("总有功率") - private Double powerSum; - - @ApiModelProperty("降水") - private String precipitation; - - @ApiModelProperty("最大前池水位") - private Double waterLevelMax; - - @ApiModelProperty("前池水位") - private Double waterLevel; - - @ApiModelProperty("设备集合") - private List deviceList; - - @ApiModelProperty("站点状态 : 0-正常 1-数据中断") - private Integer status; - - @ApiModelProperty("排序") - private Integer sort; -} diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/WeatherVo.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/WeatherVo.java deleted file mode 100644 index fb9b7b3..0000000 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/vo/WeatherVo.java +++ /dev/null @@ -1,24 +0,0 @@ -package com.hnac.hzims.operational.station.vo; - -import lombok.Data; - -import java.io.Serializable; - -@Data -public class WeatherVo implements Serializable { - - /**当前天气状况和图标的代码,图标可通过天气状况和图标下载; //100**/ - private String icon; - - /**实况温度,默认单位:摄氏度; //21**/ - private String temp; - - /**实况天气状况的文字描述,包括阴晴雨雪等天气状态的描述; //晴**/ - private String text; - - /**预报当天最高温度; //4**/ - private String tempMax; - - /**预报当天最低温度; //-5**/ - private String tempMin; -} From dda76a358c72730ed9b4f5c1c907edcf9f7a9440 Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Tue, 6 Jun 2023 17:25:13 +0800 Subject: [PATCH 07/14] =?UTF-8?q?#=E5=AE=9A=E6=97=B6=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E6=8A=BD=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/StAlamRecordServiceImpl.java | 32 ++++++---------------- 1 file changed, 9 insertions(+), 23 deletions(-) diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/StAlamRecordServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/StAlamRecordServiceImpl.java index 95e30cd..e43b935 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/StAlamRecordServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/config/service/impl/StAlamRecordServiceImpl.java @@ -728,7 +728,7 @@ public class StAlamRecordServiceImpl extends BaseServiceImpl getFaultList(String code) { List stations = this.getStationByUserAuth(code);; - /*if(CollectionUtil.isEmpty(stations)){ + if(CollectionUtil.isEmpty(stations)){ return null; } String result = fdpMonitorClient.getFaultList(); @@ -737,29 +737,15 @@ public class StAlamRecordServiceImpl extends BaseServiceImpl list = JSONArray.parseArray(result,FaultVo.class); if(CollectionUtil.isEmpty(list)){ - return new ArrayList<>(); - }*/ - List list = new ArrayList<>(); - FaultVo test =new FaultVo(); - test.setInfo("可是我不会忘"); - test.setFtype("1"); - test.setFaultId("114233824210698186"); - test.setName("爱来爱去空一场"); - test.setStationName("海南三亚大隆一级电站"); - test.setStation("902100000026"); - test.setStatus("0"); - test.setCreateTime("2023-06-01 09:55:33"); - test.setOrd("1"); - test.setFtype("1"); - test.setFinfo("你说人这东西可信不可信,骗子脸上又不会写字"); - list.add(test); - Map map = stations.stream().collect(Collectors.toMap(StationEntity::getCode,StationEntity::getName)); - // 查询已处理预警数据 - List handles = handleService.handles(Collections.singletonList(AbnormalAlarmConstant.EARLY_WARNING),null); - if(CollectionUtil.isEmpty(handles)){ - return list.stream().filter(fault -> map.containsKey(fault.getStation())).peek(o-> o.setStationName(map.get(o.getStation()))).collect(Collectors.toList()); + return null; } - return list.stream().filter(fault -> !handles.stream().map(AlarmHandleEntity::getAlarmId).collect(Collectors.toList()).contains(fault.getFaultId()) && map.containsKey(fault.getStation())).peek(o-> o.setStationName(map.get(o.getStation()))).collect(Collectors.toList()); + log.error("fault_list_stations: {}",stations); + log.error("fault_list_list: {}",list); + Map map = stations.stream().collect(Collectors.toMap(StationEntity::getCode,StationEntity::getName)); + return list.stream().filter(fault -> map.containsKey(fault.getStation())).map(o->{ + o.setStationName(map.get(o.getStation())); + return o; + }).collect(Collectors.toList()); } From e04a7bf95543acf4bf7f5e59b04e21ce7a9d6b87 Mon Sep 17 00:00:00 2001 From: haungxing <1203316822@qq.com> Date: Wed, 7 Jun 2023 08:57:13 +0800 Subject: [PATCH 08/14] =?UTF-8?q?#=20=E6=8E=A5=E7=AB=99=E7=AB=99=E7=82=B9?= =?UTF-8?q?=E6=8E=A8=E9=80=81FDP=E6=8E=A5=E5=8F=A3=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/hnac/hzims/fdp/request/StationInfoReq.java | 3 +++ .../hnac/hzims/fdp/service/impl/FdpQuestionServiceImpl.java | 12 ++++++++---- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/hzims-service-api/equipment-api/src/main/java/com/hnac/hzims/fdp/request/StationInfoReq.java b/hzims-service-api/equipment-api/src/main/java/com/hnac/hzims/fdp/request/StationInfoReq.java index c4e56ed..d77141c 100644 --- a/hzims-service-api/equipment-api/src/main/java/com/hnac/hzims/fdp/request/StationInfoReq.java +++ b/hzims-service-api/equipment-api/src/main/java/com/hnac/hzims/fdp/request/StationInfoReq.java @@ -36,4 +36,7 @@ public class StationInfoReq implements Serializable { @ApiModelProperty("站点描述") private String stationDesc; + @ApiModelProperty("租户ID") + private String tenantId; + } diff --git a/hzims-service/equipment/src/main/java/com/hnac/hzims/fdp/service/impl/FdpQuestionServiceImpl.java b/hzims-service/equipment/src/main/java/com/hnac/hzims/fdp/service/impl/FdpQuestionServiceImpl.java index a70d510..44b498a 100644 --- a/hzims-service/equipment/src/main/java/com/hnac/hzims/fdp/service/impl/FdpQuestionServiceImpl.java +++ b/hzims-service/equipment/src/main/java/com/hnac/hzims/fdp/service/impl/FdpQuestionServiceImpl.java @@ -20,6 +20,7 @@ import lombok.AllArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springblade.core.log.exception.ServiceException; import org.springblade.core.log.logger.BladeLogger; +import org.springblade.core.secure.utils.AuthUtil; import org.springblade.core.tool.api.R; import org.springblade.core.tool.utils.Func; import org.springblade.core.tool.utils.StringUtil; @@ -51,13 +52,16 @@ public class FdpQuestionServiceImpl implements IFdpQuestionService { R stationResult = stationClient.getStationByCode(stationCode); if(stationResult.isSuccess()) { StationEntity stationEntity = stationResult.getData(); + log.info("请求体为:{}",AuthUtil.getTenantId()); StationInfoReq infoReq = StationInfoReq.builder() - .stationId(stationCode) - .stationName(stationEntity.getName()) - .type(this.getStationType(stationEntity.getType())) - .stationDesc(Optional.ofNullable(stationDesc).orElse("")) + .stationId(stationCode) + .stationName(stationEntity.getName()) + .type(this.getStationType(stationEntity.getType())) + .stationDesc(Optional.ofNullable(stationDesc).orElse("")) + .tenantId("200000") .build(); if(Func.isNotEmpty(infoReq.getType())) { + log.info("请求体为:{}",JSON.toJSONString(infoReq)); HttpResponse httpResponse = HttpRequest.post(fdpUrlConfiguration.getSubmitStationInfo()) .body(JSON.toJSONString(infoReq)) .execute(); From 8a89d867993bfd31d78d2467841a0bc6db239d11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=AE=B5=E9=A3=9E=E5=AE=87?= <2684146481@qq.com> Date: Wed, 7 Jun 2023 10:52:41 +0800 Subject: [PATCH 09/14] =?UTF-8?q?=E6=96=B0=E5=BB=BA=E6=93=8D=E4=BD=9C?= =?UTF-8?q?=E7=A5=A8=E6=A8=A1=E5=9D=97,=E5=90=AF=E5=8A=A8=E6=B5=81?= =?UTF-8?q?=E7=A8=8B=EF=BC=8C=E5=BE=85=E5=A4=84=E7=90=86=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/hnac/hzims/message/MessageConstants.java | 1 + .../entity/StandardTicketInfoEntity.java | 58 ++++ .../constant/TicketProcessConstant.java | 6 + .../consumer/StandardWorkTicketConsumer.java | 7 +- .../controller/ProcessDictController.java | 20 +- .../processflow/strategy/core/ProcessIdWorker.java | 2 +- .../serviceimpl/OneTicketProcessServiceImpl.java | 6 +- .../OperationTicketProcessServiceImpl.java | 69 ++++ .../controller/OperationTicketController.java | 47 +++ .../service/OperationTicketService.java | 28 ++ .../service/impl/OperationTicketServiceImpl.java | 360 +++++++++++++++++++++ .../service/impl/TicketProcessServiceImpl.java | 153 +++++---- .../vo/operation/StandardTicketInfoVo.java | 120 +++++++ .../vo/operation/StandardTicketMeasureVo.java | 57 ++++ 14 files changed, 863 insertions(+), 71 deletions(-) create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OperationTicketProcessServiceImpl.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/controller/OperationTicketController.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/service/OperationTicketService.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/service/impl/OperationTicketServiceImpl.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/operation/StandardTicketInfoVo.java create mode 100644 hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/operation/StandardTicketMeasureVo.java diff --git a/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/MessageConstants.java b/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/MessageConstants.java index 7b7fbdb..6741a3f 100644 --- a/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/MessageConstants.java +++ b/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/MessageConstants.java @@ -54,6 +54,7 @@ public class MessageConstants { SAFE("safe","安全消息"), ACCESS("access","检修消息"), TICKETMESSAGE("ticket-message","工作票消息"), + OPERATIONTICKETMESSAGE("operation-ticket-message","操作票消息"), ; @Getter private String key; diff --git a/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/standardTicket/entity/StandardTicketInfoEntity.java b/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/standardTicket/entity/StandardTicketInfoEntity.java index 9d273d7..62c627d 100644 --- a/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/standardTicket/entity/StandardTicketInfoEntity.java +++ b/hzims-service-api/ticket-api/src/main/java/com/hnac/hzims/ticket/standardTicket/entity/StandardTicketInfoEntity.java @@ -125,4 +125,62 @@ public class StandardTicketInfoEntity extends TenantEntity implements Serializab @ApiModelProperty("是否评价") private Integer isEvaluate; + + + /** + * AA/AAA/AAAA由建站时建站人填写必须系统验证唯一性 + * 站点标识-两票编码 + */ + @ApiModelProperty("站点标识-两票编码") + private String signage; + + + /** + * 编号(原站点ID) + */ + @ApiModelProperty("编号(原站点ID)") + private String signageCode; + + + /** + * 流程状态' + */ + @ApiModelProperty("流程状态") + private Integer flowStatus; + + /** + * 流程描述 + */ + @ApiModelProperty("流程描述") + private String flowDescription; + + + /** + * 下一个审批人 + */ + @ApiModelProperty("下一个审批人") + private String nextStepOperator; + + + /** + * 用户Id + */ + @ApiModelProperty("用户Id") + private String flowUserId; + + + /** + * 当前任务名 + */ + @ApiModelProperty("当前任务名") + private String flowTaskName; + + + /** + * 当前任务名 + */ + @ApiModelProperty("当前任务名") + private String flowTaskId; + + } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/constant/TicketProcessConstant.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/constant/TicketProcessConstant.java index 7bef5ea..1ad02a8 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/constant/TicketProcessConstant.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/constant/TicketProcessConstant.java @@ -14,4 +14,10 @@ public class TicketProcessConstant { * 第一种工作票的key */ public static final String FIRST_TICKET_KEY = "networking"; + + + /** + * 操作票 + */ + public static final String OPERATION_TICKET_KEY = "moreActionBankDirect"; } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/consumer/StandardWorkTicketConsumer.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/consumer/StandardWorkTicketConsumer.java index 5936bed..956dc1e 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/consumer/StandardWorkTicketConsumer.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/consumer/StandardWorkTicketConsumer.java @@ -44,11 +44,12 @@ public class StandardWorkTicketConsumer implements IQueueConsume { WorkflowQueue ticker = new WorkflowQueue(); ticker.setProcessDefinitionKey(taskDefinitionKey); //判断执行具体的实现类 - ProcessService ticketService = ticketServiceList.stream().filter(item -> item.isWorkflowProcess(ticker)).findFirst().orElse(null); - if (ObjectUtils.isNotEmpty(ticketService)) { + ProcessService processService = + ticketServiceList.stream().filter(item -> item.isWorkflowProcess(ticker)).findFirst().orElse(null); + if (ObjectUtils.isNotEmpty(processService)) { //执行业务方法 try { - ticketService.calculate(response); + processService.calculate(response); } catch (Exception e) { e.printStackTrace(); //todo 业务出错误 做补偿 diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/controller/ProcessDictController.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/controller/ProcessDictController.java index f6b6fdf..f267139 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/controller/ProcessDictController.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/controller/ProcessDictController.java @@ -29,14 +29,24 @@ public class ProcessDictController { @GetMapping("/test") public void test(){ + // ProcessDict processDict = new ProcessDict(); + // processDict.setDictKey("networking"); + // processDict.setDictSort(0); + // processDict.setDictValue("workTicketFlow"); + // processDict.setDictLabel("第一种工作票"); + // processDict.setIsDefault("Y"); + // processDict.setRemark("第一种工作票"); + // processDict.setDictType("工作票"); + // processDictService.save(processDict); + ProcessDict processDict = new ProcessDict(); - processDict.setDictKey("networking"); + processDict.setDictKey("moreActionBankDirect"); processDict.setDictSort(0); - processDict.setDictValue("workTicketFlow"); - processDict.setDictLabel("第一种工作票"); + processDict.setDictValue("standardTicketFlow"); + processDict.setDictLabel("操作票"); processDict.setIsDefault("Y"); - processDict.setRemark("第一种工作票"); - processDict.setDictType("工作票"); + processDict.setRemark("操作票"); + processDict.setDictType("两票管理"); processDictService.save(processDict); } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/core/ProcessIdWorker.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/core/ProcessIdWorker.java index 6fcddf2..6e1fdf9 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/core/ProcessIdWorker.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/core/ProcessIdWorker.java @@ -136,7 +136,7 @@ public class ProcessIdWorker { //6. sequencing 大于等于1000 的话,从头开始 if (sequencing.get() >= 1000) { sequencing.compareAndSet(sequencing.get(), 1); - System.out.println("sequencing >= 1000 被执行呢"); + log.error("sequencing >= 1000 被执行呢"); redisTemplate.delete(key); // cacheMap.remove(key); return sequencing.get(); diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OneTicketProcessServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OneTicketProcessServiceImpl.java index 1255079..4b1c653 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OneTicketProcessServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OneTicketProcessServiceImpl.java @@ -47,13 +47,13 @@ public class OneTicketProcessServiceImpl extends ProcessAbstractService { */ @Override public Boolean isWorkflowProcess(WorkflowQueue flowQueue) { - log.info("是否执行开第一种工作票流程环节操作~~~~,流程ticket: {}", flowQueue); + log.info("是否执行开工作票流程环节操作~~~~,流程ticket: {}", flowQueue); String dictValue = processDictService.selectDictValueByKey(FIRST_TICKET_KEY); if (dictValue.equals(flowQueue.getProcessDefinitionKey())) { - log.info("已执行第一种开工作票流程环节操作~~~~"); + log.info("已执行工作票流程环节操作~~~~"); return true; } - log.error("未是否执行第一种开工作票流程环节操作,请联系管理员~~~~"); + log.error("未是否执行工作票流程环节操作,请联系管理员~~~~"); return false; } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OperationTicketProcessServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OperationTicketProcessServiceImpl.java new file mode 100644 index 0000000..7590575 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/processflow/strategy/serviceimpl/OperationTicketProcessServiceImpl.java @@ -0,0 +1,69 @@ +package com.hnac.hzims.ticket.processflow.strategy.serviceimpl; + +import com.hnac.hzims.ticket.processflow.service.ProcessDictService; +import com.hnac.hzims.ticket.processflow.strategy.abstracts.ProcessAbstractService; +import com.hnac.hzims.ticket.processflow.strategy.entity.WorkflowQueue; +import com.hnac.hzims.ticket.response.ProcessWorkFlowResponse; +import com.hnac.hzims.ticket.standardTicket.service.OperationTicketService; +import com.hnac.hzims.ticket.twoTicket.service.TicketProcessService; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.stereotype.Service; + +import static com.hnac.hzims.ticket.processflow.constant.TicketProcessConstant.OPERATION_TICKET_KEY; + +/** + * 开工作票流程实现类 + * + * @Author dfy + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/3/28 8:47 + */ +@Slf4j +@Service +@RequiredArgsConstructor +public class OperationTicketProcessServiceImpl extends ProcessAbstractService { + + + + private final OperationTicketService operationTicketService; + + + + private final ProcessDictService processDictService; + + + + + + + + /** + * 设置执行那种实现类 + * + * @param flowQueue + * @return + */ + @Override + public Boolean isWorkflowProcess(WorkflowQueue flowQueue) { + log.info("是否执行开操作票流程环节操作~~~~,流程flowQueue: {}", flowQueue); + String dictValue = processDictService.selectDictValueByKey(OPERATION_TICKET_KEY); + if (dictValue.equals(flowQueue.getProcessDefinitionKey())) { + log.info("已执行操作票流程环节操作~~~~"); + return true; + } + log.error("未是否执行操作票流程环节操作,请联系管理员~~~~"); + return false; + } + + /** + * 两票管理业务方法 + * + * @param response + */ + @Override + public void calculate(ProcessWorkFlowResponse response) { + operationTicketService.findPending(response); + } +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/controller/OperationTicketController.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/controller/OperationTicketController.java new file mode 100644 index 0000000..b47e1e2 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/controller/OperationTicketController.java @@ -0,0 +1,47 @@ +package com.hnac.hzims.ticket.standardTicket.controller; + +import com.hnac.hzims.ticket.standardTicket.service.OperationTicketService; +import com.hnac.hzims.ticket.twoTicket.vo.operation.StandardTicketInfoVo; +import com.hnac.hzims.ticket.twoTicket.vo.process.WorkTicketVo; +import io.swagger.annotations.ApiOperation; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.tool.api.R; +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; + +/** + * 操作票 + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/6 13:46 + */ +@RequiredArgsConstructor +@Slf4j +@RequestMapping("/operation-ticket") +@RestController +public class OperationTicketController { + + + private final OperationTicketService operationTicketService; + + + /** + * 启动流程 + * + * @return + */ + @ApiOperation("启动流程") + @PostMapping("/startUp") + public R start(@RequestBody StandardTicketInfoVo StandardTicketInfoVo) { + operationTicketService.startUp(StandardTicketInfoVo); + return R.success("申请开票成功"); + } + + + + +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/service/OperationTicketService.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/service/OperationTicketService.java new file mode 100644 index 0000000..f92497d --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/service/OperationTicketService.java @@ -0,0 +1,28 @@ +package com.hnac.hzims.ticket.standardTicket.service; + +import com.hnac.hzims.ticket.response.ProcessWorkFlowResponse; +import com.hnac.hzims.ticket.twoTicket.vo.operation.StandardTicketInfoVo; +import com.hnac.hzims.ticket.twoTicket.vo.process.WorkTicketVo; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/6 13:48 + */ +public interface OperationTicketService { + + + /** + * 启动流程 + * @param standardTicketInfoVo + */ + void startUp(StandardTicketInfoVo standardTicketInfoVo); + + + /** + * 待处理 + * @param response + */ + void findPending(ProcessWorkFlowResponse response); +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/service/impl/OperationTicketServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/service/impl/OperationTicketServiceImpl.java new file mode 100644 index 0000000..7934a21 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/standardTicket/service/impl/OperationTicketServiceImpl.java @@ -0,0 +1,360 @@ +package com.hnac.hzims.ticket.standardTicket.service.impl; + +import com.alibaba.fastjson.JSON; +import com.alibaba.fastjson.JSONObject; +import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; +import com.hnac.hzims.common.logs.utils.StringUtils; +import com.hnac.hzims.message.MessageConstants; +import com.hnac.hzims.message.dto.MessagePushRecordDto; +import com.hnac.hzims.message.fegin.IMessageClient; +import com.hnac.hzims.operational.station.entity.StationEntity; +import com.hnac.hzims.operational.station.feign.IStationClient; +import com.hnac.hzims.ticket.processflow.service.ProcessDictService; +import com.hnac.hzims.ticket.processflow.strategy.core.ProcessIdWorker; +import com.hnac.hzims.ticket.response.ProcessWorkFlowResponse; +import com.hnac.hzims.ticket.standardTicket.entity.StandardTicketInfoEntity; +import com.hnac.hzims.ticket.standardTicket.entity.StandardTicketMeasureEntity; +import com.hnac.hzims.ticket.standardTicket.service.IStandardTicketInfoService; +import com.hnac.hzims.ticket.standardTicket.service.IStandardTicketMeasureService; +import com.hnac.hzims.ticket.standardTicket.service.OperationTicketService; +import com.hnac.hzims.ticket.twoTicket.vo.operation.StandardTicketInfoVo; +import com.hnac.hzims.ticket.twoTicket.vo.operation.StandardTicketMeasureVo; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.lang3.math.NumberUtils; +import org.springblade.core.log.exception.ServiceException; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.BeanUtil; +import org.springblade.flow.core.entity.BladeFlow; +import org.springblade.flow.core.feign.IFlowClient; +import org.springblade.system.feign.ISysClient; +import org.springblade.system.user.cache.UserCache; +import org.springblade.system.user.entity.User; +import org.springframework.beans.BeanUtils; +import org.springframework.stereotype.Service; + +import java.time.Duration; +import java.time.Instant; +import java.time.LocalDateTime; +import java.util.*; +import java.util.stream.Collectors; + +import static com.hnac.hzims.ticket.processflow.constant.TicketProcessConstant.OPERATION_TICKET_KEY; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/6 13:49 + */ + +@Slf4j +@Service +@RequiredArgsConstructor +public class OperationTicketServiceImpl implements OperationTicketService { + + private final IStandardTicketInfoService standardTicketInfoService; + + private final IStandardTicketMeasureService standardTicketMeasureService; + + private final IStationClient stationClient; + + + private final ProcessIdWorker processIdWorker; + + + private final ProcessDictService processDictService; + + + private final IFlowClient flowClient; + + + private final IMessageClient messageClient; + + + private final ISysClient sysClient; + + + /** + * 启动流程 + * + * @param standardTicketInfoVo + */ + @Override + public void startUp(StandardTicketInfoVo standardTicketInfoVo) { + log.info("执行 com.hnac.hzims.ticket.standardTicket.service.impl【startUp】 。。。方法"); + if (standardTicketInfoVo.getSignage() == null) { + throw new ServiceException("票据抬头未配置,请您到站点管理配置"); + } + StationEntity stationEntity = new StationEntity(); + stationEntity.setCode(standardTicketInfoVo.getSignageCode()); + R stationClientOne = stationClient.getOne(stationEntity); + if (!stationClientOne.isSuccess()) { + throw new IllegalArgumentException("票据抬头未配置,请您到站点管理配置?"); + } + StationEntity station = stationClientOne.getData(); + if (station == null) { + throw new ServiceException("票据抬头未配置,请您到站点管理配置"); + } + log.info("前端查的站点编号 :{}", standardTicketInfoVo.getSignage()); + log.info("后端查寻的站点编码 :{}", station.getSignage()); + if (!standardTicketInfoVo.getSignage().equals(station.getSignage())) { + throw new ServiceException("票据抬头未配置,请您到站点管理配置"); + } + + //获取站点编号 + String signage = station.getSignage(); + if (StringUtils.isBlank(signage) || signage.length() < 2) { + throw new ServiceException("票据抬头未配置,请您到站点管理配置"); + } + signage = signage.length() == 2 ? station.getSignage() : station.getSignage().substring(0, 2); + + standardTicketInfoVo.setSignage(signage); + standardTicketInfoVo.setSignageCode(station.getCode()); + //2. 获取编码 + String code = processIdWorker.getTicketByCode(standardTicketInfoVo.getSignage(), this.getTicketWichCode(standardTicketInfoVo.getTicketType()), LocalDateTime.now()); + standardTicketInfoVo.setCode(code); + //3. 保存操作对象 + this.saveStandardTicketInfo(standardTicketInfoVo); + //5. 保存安全措施 + List standardTicketInfoVos = this.saveStandardTicketMeasure( + this.saveStandardTicketMeasureWichTicket(standardTicketInfoVo)); + standardTicketInfoVo.setStandardTicketMeasureVos(standardTicketInfoVos); + //6. 查询第一种工作票值 + String dictValue = processDictService.selectDictValueByKey(OPERATION_TICKET_KEY); + // 7.启动流程 + this.startProcess(standardTicketInfoVo, dictValue); + } + + /** + * 待处理 + * + * @param response + */ + @Override + public void findPending(ProcessWorkFlowResponse response) { + log.info("获取businessKey: {}", response.getBusinessKey()); + log.info("获取taskId: {} ", response.getTaskId()); + log.info("获取下一个审批人是: {} ", response.getNextStepOperator()); + log.info("获取下一个用户Id是: {} ", response.getUserId()); + log.info("获取当前任务名称是: {} ", response.getTaskName()); + log.info("获取根据handleType区分是用户还是候选组角色: {}", response.getHandleType()); + //json转换表单 + String formData = JSON.toJSONString(response.getVariables()); + log.info("获取表单的数据:{}", formData); + StandardTicketInfoVo standardTicketInfoVo = null; + try { + JSONObject jsonObject = JSONObject.parseObject(formData); + standardTicketInfoVo = JSONObject.toJavaObject(jsonObject, StandardTicketInfoVo.class); + } catch (Exception e) { + log.error("获取表单出现异常了~~~~"); + throw new IllegalArgumentException(e.getMessage()); + } + + //1.查询操作票信息 + Long id = NumberUtils.toLong(response.getBusinessKey()); + StandardTicketInfoEntity standardTicketInfoEntity = standardTicketInfoService.getById(id); + if (ObjectUtils.isEmpty(standardTicketInfoEntity)) { + log.error("获取操作票不存在"); + return; + } + //设置id + StandardTicketInfoEntity newStandardTicketInfoEntity = new StandardTicketInfoEntity(); + BeanUtils.copyProperties(standardTicketInfoVo, newStandardTicketInfoEntity); + newStandardTicketInfoEntity.setId(id); + //填充操作票信息 + saveStandardTicketInfoEntity(newStandardTicketInfoEntity, response); + newStandardTicketInfoEntity.setProcessInstanceId(response.getProcessInstanceId()); + standardTicketInfoService.updateById(newStandardTicketInfoEntity); + + //更新安全措施 + List standardTicketMeasureVos = standardTicketInfoVo.getStandardTicketMeasureVos(); + if (CollectionUtils.isNotEmpty(standardTicketMeasureVos)) { + List standardTicketMeasureEntities = standardTicketMeasureVos.stream().map(standardTicketMeasureVo -> { + StandardTicketMeasureEntity standardTicketMeasureEntity = new StandardTicketMeasureEntity(); + BeanUtils.copyProperties(standardTicketMeasureVo, standardTicketMeasureEntity); + return standardTicketMeasureEntity; + }).collect(Collectors.toList()); + standardTicketMeasureService.updateBatchById(standardTicketMeasureEntities); + } + + + //推送消息 + if (response.getTaskId() != null) { + MessagePushRecordDto message = new MessagePushRecordDto(); + message.setBusinessClassify("business"); + message.setBusinessKey(MessageConstants.BusinessClassifyEnum.OPERATIONTICKETMESSAGE.getKey()); + message.setSubject(MessageConstants.BusinessClassifyEnum.OPERATIONTICKETMESSAGE.getDescription()); + message.setTaskId(standardTicketInfoEntity.getId()); + message.setTenantId("200000"); + message.setTypes(Arrays.asList(MessageConstants.APP_PUSH, MessageConstants.WS_PUSH)); + message.setPushType(MessageConstants.IMMEDIATELY); + //您有一张工作票待审批,工作内容:*****,审批环节:*****; + String countent = + "您有一张工作票待审批,工作内容:".concat(standardTicketInfoEntity.getTitle()) + .concat(",审批环节:") + .concat(response.getTaskName()); + message.setContent(countent); + message.setDeptId(standardTicketInfoEntity.getCreateDept()); + R deptName = sysClient.getDeptName(standardTicketInfoEntity.getCreateDept()); + if (deptName.isSuccess()) { + message.setDeptName(deptName.getData()); + } + String userIds = response.getUserId(); + if (StringUtils.isBlank(userIds)) { + log.error("推送的消息不能为空哦,{}", userIds); + return; + } + String[] split = userIds.split(","); + for (String userId : split) { + message.setPusher(userId); + User user = UserCache.getUser(NumberUtils.toLong(userId)); + if (ObjectUtils.isNotEmpty(user)) { + message.setPusherName(user.getName()); + } + message.setAccount(userId); + + message.setCreateUser(NumberUtils.toLong(userId)); + messageClient.sendMessage(message); + } + } + } + + /** + * 填充数据 + * + * @param newStandardTicketInfoEntity + * @param response + */ + private void saveStandardTicketInfoEntity(StandardTicketInfoEntity newStandardTicketInfoEntity, ProcessWorkFlowResponse response) { + String flowDescription = ""; + //如果response.getHandleType() 是0使用户 + newStandardTicketInfoEntity.setFlowUserId(response.getUserId()); + newStandardTicketInfoEntity.setNextStepOperator(response.getNextStepOperator()); + flowDescription = "审批中,当前环节是".concat(response.getTaskName()).concat(",待").concat(response.getNextStepOperator()).concat("审批"); + //如果taskId为空 + String taskId = response.getTaskId(); + if (StringUtils.isEmpty(taskId)) { + newStandardTicketInfoEntity.setFlowDescription("结束"); + newStandardTicketInfoEntity.setFlowTaskId(" "); + newStandardTicketInfoEntity.setFlowTaskName("结束"); + newStandardTicketInfoEntity.setNextStepOperator(" "); + newStandardTicketInfoEntity.setFlowStatus(999); + } else { + newStandardTicketInfoEntity.setFlowTaskId(taskId); + newStandardTicketInfoEntity.setFlowTaskName(response.getTaskName()); + newStandardTicketInfoEntity.setFlowDescription(flowDescription); + } + } + + /** + * 启动流程 + * + * @param standardTicketInfoVo + * @param dictValue + */ + private void startProcess(StandardTicketInfoVo standardTicketInfoVo, String dictValue) { + Instant start = Instant.now(); + Map params = new HashMap<>(4); + params.put("standardTicketInfoVo", standardTicketInfoVo); + params.put("taskId", standardTicketInfoVo.getId()); + params.put("guardianUserIds", "taskUser_".concat(standardTicketInfoVo.getGuardian().toString())); + //已开启流程 + R processInstanceContainNameByKey = flowClient.startProcessInstanceContainNameByKey(dictValue, + String.valueOf(standardTicketInfoVo.getId()), standardTicketInfoVo.getTitle(), params); + if (!processInstanceContainNameByKey.isSuccess()) { + log.error("processInstanceContainNameByKey {}", processInstanceContainNameByKey.getMsg()); + throw new ServiceException("不好意思,您暂无权限..."); + } + Duration between = Duration.between(start, Instant.now()); + log.info("================================================================"); + log.info("耗时: " + (between.getSeconds()) + "秒"); + log.info("耗时: " + (between.toMillis()) + "毫秒"); + log.info("================================================================"); + } + + + /** + * 设置安全措施值 + * + * @param standardTicketInfoVo + * @return + */ + private List saveStandardTicketMeasureWichTicket(StandardTicketInfoVo standardTicketInfoVo) { + List standardTicketMeasureVos = standardTicketInfoVo.getStandardTicketMeasureVos(); + if (CollectionUtils.isNotEmpty(standardTicketMeasureVos)) { + List measureEntityList = BeanUtil.copyProperties(standardTicketMeasureVos, + StandardTicketMeasureEntity.class); + List collect = measureEntityList.stream().map(item -> { + item.setTicketId(standardTicketInfoVo.getId()); + return item; + }).collect(Collectors.toList()); + return collect; + + } + return null; + } + + /** + * 保存安全措施 + * + * @param measureEntityList + * @return + */ + private List saveStandardTicketMeasure(List measureEntityList) { + if (CollectionUtils.isEmpty(measureEntityList)) { + log.error("安全措施为空哦"); + return new ArrayList<>(); + } + boolean save = standardTicketMeasureService.saveBatch(measureEntityList); + if (!save) { + throw new ServiceException("Save failed"); + } + + return measureEntityList.stream().map(item -> { + StandardTicketMeasureVo standardTicketMeasureVo = new StandardTicketMeasureVo(); + BeanUtils.copyProperties(item, standardTicketMeasureVo); + return standardTicketMeasureVo; + }).collect(Collectors.toList()); + } + + /** + * 保存工作对象 + * + * @param standardTicketInfoVo + * @return + */ + private void saveStandardTicketInfo(StandardTicketInfoVo standardTicketInfoVo) { + StandardTicketInfoEntity standardTicketInfo = new StandardTicketInfoEntity(); + BeanUtils.copyProperties(standardTicketInfoVo, standardTicketInfo); + boolean save = standardTicketInfoService.save(standardTicketInfo); + if (!save) { + throw new ServiceException("Save failed"); + } + BeanUtils.copyProperties(standardTicketInfo, standardTicketInfoVo); + } + + + /** + * 工作类型生成工作票类型 + */ + private String getTicketWichCode(String type) { + String result = null; + switch (type) { + case "3": + result = "DZ"; + break; + case "4": + result = type; + break; + case "5": + result = type; + break; + default: + result = "DZ"; + break; + } + return result; + } +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java index 15202c8..d536b9d 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java @@ -4,12 +4,10 @@ package com.hnac.hzims.ticket.twoTicket.service.impl; import cn.afterturn.easypoi.word.WordExportUtil; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; -import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; import com.baomidou.mybatisplus.core.toolkit.IdWorker; import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; -import com.baomidou.mybatisplus.extension.conditions.update.LambdaUpdateChainWrapper; +import com.google.common.collect.Lists; import com.hnac.hzims.common.logs.utils.StringUtils; import com.hnac.hzims.message.MessageConstants; import com.hnac.hzims.message.dto.MessagePushRecordDto; @@ -151,7 +149,6 @@ public class TicketProcessServiceImpl implements TicketProcessService { private final ProcessDictService processDictService; - private final IMessageClient messageClient; @@ -184,20 +181,21 @@ public class TicketProcessServiceImpl implements TicketProcessService { log.info("前端查的站点编号 :{}", workTicketVo.getWorkTicket().getSignage()); log.info("后端查寻的站点编码 :{}", station.getSignage()); if (!workTicketVo.getWorkTicket().getSignage().equals(station.getSignage())) { - throw new ServiceException("站点标识不能为空"); + throw new ServiceException("票据抬头未配置,请您到站点管理配置"); } //获取站点编号 String signage = station.getSignage(); if (StringUtils.isBlank(signage) || signage.length() < 2) { - throw new ServiceException("站点标识不能为空"); + throw new ServiceException("票据抬头未配置,请您到站点管理配置"); } signage = signage.length() == 2 ? station.getSignage() : station.getSignage().substring(0, 2); workTicketVo.getWorkTicket().setSignage(signage); workTicketVo.getWorkTicket().setSignageCode(station.getCode()); //2. 获取编码 - String code = processIdWorker.getTicketByCode(workTicketVo.getWorkTicket().getSignage(), workTicketVo.getWorkTicket().getType(), LocalDateTime.now()); + String code = processIdWorker.getTicketByCode(workTicketVo.getWorkTicket().getSignage(), this.getTicketWichCode(workTicketVo.getWorkTicket().getType()), + LocalDateTime.now()); workTicketVo.getWorkTicket().setCode(code); //3 .保存工作对象 this.saveWorkTicketInfo(workTicketVo.getWorkTicket()); @@ -270,7 +268,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { for (WorkTicketSafetyMeasureEntity item : safetyMeasuresList) { if (ObjectUtils.isNotEmpty(item.getId())) { workTicketSafetyMeasureService.updateById(item); - }else { + } else { item.setTicketId(workTicketInfo.getId()); workTicketSafetyMeasureService.save(item); } @@ -279,20 +277,24 @@ public class TicketProcessServiceImpl implements TicketProcessService { } catch (Exception e) { e.printStackTrace(); } - //工作票工作任务组 - // List workTicketContentDtoList = workTicketVo.getWorkTicketContentDtoList(); - // if (CollectionUtils.isNotEmpty(workTicketContentDtoList)) { - // log.info("获取工作票工作任务组:{}", workTicketContentDtoList); - // workTicketContentDtoList.forEach(item -> { - // if (ObjectUtils.isEmpty(item.getId())) { - // LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>(); - // queryWrapper.eq(WorkTicketContentEntity::getTicketId, workTicketInfo.getId()); - // contentService.update(item, queryWrapper); - // } else { - // contentService.updateById(item); - // } - // }); - // } + // 第二种 工作票工作任务组 + List workTicketContentDtoList = workTicketVo.getWorkTicketContentDtoList(); + try { + if (CollectionUtils.isNotEmpty(workTicketContentDtoList)) { + log.info("获取工作票工作任务组:{}", workTicketContentDtoList); + workTicketContentDtoList.forEach(item -> { + if (ObjectUtils.isEmpty(item.getId())) { + contentService.save(item); + } else { + contentService.updateById(item); + } + }); + } + } catch (Exception e) { + e.printStackTrace(); + } + + // 工作票延期 WorkTicketDelayEntity workTicketDelay = workTicketVo.getWorkTicketDelay(); try { @@ -314,10 +316,12 @@ public class TicketProcessServiceImpl implements TicketProcessService { } catch (Exception e) { e.printStackTrace(); } + + //工作结束 WorkTicketFinish workTicketFinish = workTicketVo.getWorkTicketFinish(); try { - log.info("工作结束==============>"+ (workTicket.getFlowStatus().intValue())); + log.info("工作结束==============>" + (workTicket.getFlowStatus().intValue())); if (ObjectUtils.isNotEmpty(workTicketFinish)) { WorkTicketFinish ticketFinish = workTicketFinishService.selectByTicketId(workTicketInfo.getId()); log.info("获取工作结束:{}", workTicketFinish); @@ -398,43 +402,48 @@ public class TicketProcessServiceImpl implements TicketProcessService { } + if (response.getTaskId() != null || response.getUserId() != null) { + //推送消息 + try { + MessagePushRecordDto message = new MessagePushRecordDto(); + message.setBusinessClassify("business"); + message.setBusinessKey(MessageConstants.BusinessClassifyEnum.TICKETMESSAGE.getKey()); + message.setSubject(MessageConstants.BusinessClassifyEnum.TICKETMESSAGE.getDescription()); + message.setTaskId(workTicketInfo.getId()); + message.setTenantId("200000"); + message.setTypes(Arrays.asList(MessageConstants.APP_PUSH, MessageConstants.WS_PUSH)); + message.setPushType(MessageConstants.IMMEDIATELY); + //您有一张工作票待审批,工作内容:*****,审批环节:*****; + String countent = + "您有一张工作票待审批,工作内容:".concat(workTicketInfo.getWorkContent()) + .concat(",审批环节:") + .concat(response.getTaskName()); + message.setContent(countent); + message.setDeptId(workTicketInfo.getCreateDept()); + R deptName = sysClient.getDeptName(workTicketInfo.getCreateDept()); + if (deptName.isSuccess()) { + message.setDeptName(deptName.getData()); + } + String userIds = response.getUserId(); + if (StringUtils.isBlank(userIds)) { + log.error("推送的消息不能为空哦,{}", userIds); + return; + } + String[] split = userIds.split(","); + for (String userId : split) { + message.setPusher(userId); + User user = UserCache.getUser(NumberUtils.toLong(userId)); + if (ObjectUtils.isNotEmpty(user)) { + message.setPusherName(user.getName()); + } + message.setAccount(userId); - //推送消息 - MessagePushRecordDto message = new MessagePushRecordDto(); - message.setBusinessClassify("business"); - message.setBusinessKey(MessageConstants.BusinessClassifyEnum.TICKETMESSAGE.getKey()); - message.setSubject(MessageConstants.BusinessClassifyEnum.TICKETMESSAGE.getDescription()); - message.setTaskId(workTicketInfo.getId()); - message.setTenantId("200000"); - message.setTypes(Arrays.asList(MessageConstants.APP_PUSH, MessageConstants.WS_PUSH)); - message.setPushType(MessageConstants.IMMEDIATELY); - //您有一张工作票待审批,工作内容:*****,审批环节:*****; - String countent = - "您有一张工作票待审批,工作内容:".concat(workTicketInfo.getWorkContent()) - .concat(",审批环节:") - .concat(response.getTaskName()); - message.setContent(countent); - message.setDeptId(workTicketInfo.getCreateDept()); - R deptName = sysClient.getDeptName(workTicketInfo.getCreateDept()); - if (deptName.isSuccess()) { - message.setDeptName(deptName.getData()); - } - String userIds = response.getUserId(); - if (StringUtils.isBlank(userIds)){ - log.error("推送的消息不能为空哦,{}",userIds); - return; - } - String[] split = userIds.split(","); - for (String userId : split) { - message.setPusher(userId); - User user = UserCache.getUser(NumberUtils.toLong(userId)); - if (ObjectUtils.isNotEmpty(user)) { - message.setPusherName(user.getName()); + message.setCreateUser(NumberUtils.toLong(userId)); + messageClient.sendMessage(message); + } + } catch (Exception e) { + e.printStackTrace(); } - message.setAccount(userId); - - message.setCreateUser(NumberUtils.toLong(userId)); - messageClient.sendMessage(message); } } @@ -479,6 +488,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { // } workTicket.setFlowUserId(response.getUserId()); workTicket.setNextStepOperator(response.getNextStepOperator()); + flowDescription = "审批中,当前环节是".concat(response.getTaskName()).concat(",待").concat(response.getNextStepOperator()).concat("审批"); } //如果taskId为空 @@ -1149,7 +1159,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { Map stringObjectMap = matterLibraryListFive.get(i); objectObjectHashMap.put("safetyMeasure1", stringObjectMap.get("safetyMeasure")); } - }else { + } else { objectObjectHashMap.put("safetyMeasure1", ""); } @@ -1217,7 +1227,32 @@ public class TicketProcessServiceImpl implements TicketProcessService { if (StringUtils.isNoneBlank(newValue)) { dataConversion.put(key, BooleanUtils.toBoolean(newValue) ? "☑" : "□"); } + + } + + /** + * 工作类型生成工作票类型 + */ + private String getTicketWichCode(String type) { + String result = null; + switch (type) { + case "6": + result = "D1"; + break; + case "7": + result = "D2"; + break; + case "8": + result = "JX"; + break; + default: + result = "D1"; + break; + } + return result; + } + } diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/operation/StandardTicketInfoVo.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/operation/StandardTicketInfoVo.java new file mode 100644 index 0000000..70ca8e5 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/operation/StandardTicketInfoVo.java @@ -0,0 +1,120 @@ +package com.hnac.hzims.ticket.twoTicket.vo.operation; + +import com.fasterxml.jackson.annotation.JsonFormat; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.experimental.Accessors; +import org.springblade.core.tenant.mp.TenantEntity; +import org.springframework.format.annotation.DateTimeFormat; + +import java.time.LocalDateTime; +import java.util.List; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/6 15:39 + */ +@Data +@Accessors(chain = true) +public class StandardTicketInfoVo extends TenantEntity { + + + @ApiModelProperty("票据类型") + private String ticketType; + + + + @ApiModelProperty("单位") + private String company; + + @ApiModelProperty("工作流ID") + private String processInstanceId; + + + @ApiModelProperty("编号") + private String code; + + @ApiModelProperty("发令人") + private Long issueOrderPerson; + + @ApiModelProperty("受令人") + private Long accessOrderPerson; + + @ApiModelProperty("发令时间") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private LocalDateTime issueOrderTime; + + @ApiModelProperty("操作开始时间") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private LocalDateTime startTime; + + @ApiModelProperty("操作结束时间") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private LocalDateTime endTime; + + @ApiModelProperty("操作任务") + private String title; + + @ApiModelProperty("任务类型") + private String taskType; + + @ApiModelProperty("关联业务任务ID") + private Long taskId; + + @ApiModelProperty("关联业务名称") + private String taskName; + + @ApiModelProperty("备注") + private String remark; + + @ApiModelProperty("监护人") + private Long guardian; + + @ApiModelProperty("操作人") + private Long operator; + + @ApiModelProperty("操作时间") + private LocalDateTime operateTime; + + @ApiModelProperty("负责人确认时间") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private LocalDateTime guardianshipTime; + + @ApiModelProperty("值班负责人") + private Long principal; + + @ApiModelProperty("值班负责人确认时间") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private LocalDateTime principalTime; + + @ApiModelProperty("是否评价") + private Integer isEvaluate; + + + /** + * AA/AAA/AAAA由建站时建站人填写必须系统验证唯一性 + * 站点标识-两票编码 + */ + @ApiModelProperty("站点标识-两票编码") + private String signage; + + + /** + * 编号(原站点ID) + */ + @ApiModelProperty("编号(原站点ID)") + private String signageCode; + + + /** + * 安全措施 + */ + private List standardTicketMeasureVos; +} diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/operation/StandardTicketMeasureVo.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/operation/StandardTicketMeasureVo.java new file mode 100644 index 0000000..03702a7 --- /dev/null +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/vo/operation/StandardTicketMeasureVo.java @@ -0,0 +1,57 @@ +package com.hnac.hzims.ticket.twoTicket.vo.operation; + +import com.baomidou.mybatisplus.annotation.FieldStrategy; +import com.baomidou.mybatisplus.annotation.TableField; +import com.fasterxml.jackson.annotation.JsonFormat; +import com.fasterxml.jackson.databind.annotation.JsonSerialize; +import com.fasterxml.jackson.databind.ser.std.NullSerializer; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import org.springblade.core.mp.support.QueryField; +import org.springblade.core.mp.support.SqlCondition; +import org.springblade.core.tenant.mp.TenantEntity; +import org.springframework.format.annotation.DateTimeFormat; + +import java.time.LocalDateTime; + +/** + * @Author WL + * @Version v1.0 + * @Serial 1.0 + * @Date 2023/6/6 15:47 + */ +@Data +public class StandardTicketMeasureVo extends TenantEntity { + + + private static final long serialVersionUID = 8503146008417850183L; + + @ApiModelProperty("标准票ID") + private Long ticketId; + + @ApiModelProperty("分组") + private Long matterGroup; + + @ApiModelProperty("安全措施ID") + private Long measureId; + + @ApiModelProperty("安全措施") + private String measure; + + @ApiModelProperty("执行人") + private Long executor; + + @ApiModelProperty("执行时间") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private LocalDateTime executeTime; + + @ApiModelProperty("执行图片") + private String executeImgUrl; + + @ApiModelProperty("执行备注") + private String remark; + + @ApiModelProperty("操作事项排序") + private Integer sort; +} From b6fbe31558bb1d45b1900b37e434793c523a6164 Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Wed, 7 Jun 2023 10:57:08 +0800 Subject: [PATCH 10/14] =?UTF-8?q?#=E5=AE=9A=E6=97=B6=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E6=8A=BD=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../scheduled/mapper/equipment/PlanMapper.java | 17 + .../scheduled/mapper/operation/AccessMapper.java | 11 + .../scheduled/mapper/operation/DefectMapper.java | 12 + .../mapper/operation/MaintenanceMapper.java | 11 + .../scheduled/mapper/operation/OtherMapper.java | 11 + .../mapper/operation/OverDetailsMapper.java | 11 + .../scheduled/mapper/operation/OverMapper.java | 11 + .../scheduled/mapper/operation/SolveMapper.java | 11 + .../mapper/ticket/TicketEvaluateMapper.java | 11 + .../scheduled/mapper/ticket/TicketMapper.java | 13 + .../scheduled/mapper/ticket/WorkTicketMapper.java | 14 + .../scheduled/scheduled/ShowScheduledTask.java | 24 + .../scheduled/service/equipment/PlanService.java | 16 + .../service/equipment/impl/PlanServiceImpl.java | 33 + .../scheduled/service/operation/AccessService.java | 14 + .../scheduled/service/operation/DefectService.java | 14 + .../service/operation/MaintenanceService.java | 15 + .../service/operation/MonitorService.java | 5 +- .../scheduled/service/operation/OtherService.java | 11 + .../service/operation/OverDetailsService.java | 12 + .../scheduled/service/operation/OverService.java | 11 + .../scheduled/service/operation/ShowService.java | 9 + .../scheduled/service/operation/SolveService.java | 11 + .../service/operation/impl/AccessServiceImpl.java | 51 + .../service/operation/impl/DefectServiceImpl.java | 55 + .../operation/impl/MaintenanceServiceImpl.java | 50 + .../service/operation/impl/OtherServiceImpl.java | 19 + .../operation/impl/OverDetailsServiceImpl.java | 19 + .../service/operation/impl/OverServiceImpl.java | 19 + .../operation/impl/RealTargetServiceImpl.java | 1 - .../service/operation/impl/ShowServiceImpl.java | 480 +++++++++ .../service/operation/impl/SolveServiceImpl.java | 20 + .../service/ticket/TicketEvaluateService.java | 11 + .../scheduled/service/ticket/TicketService.java | 16 + .../service/ticket/WorkTicketService.java | 7 + .../ticket/impl/TicketEvaluateServiceImpl.java | 20 + .../service/ticket/impl/TicketServiceImpl.java | 85 ++ .../service/ticket/impl/WorkTicketServiceImpl.java | 1093 ++++++++++++++++++++ .../main/resources/mapper/equipment/PlanMapper.xml | 38 + .../resources/mapper/operation/AccessMapper.xml | 5 + .../resources/mapper/operation/DefectMapper.xml | 4 + .../mapper/operation/MaintenanceMapper.xml | 27 + .../resources/mapper/operation/OtherMapper.xml | 25 + .../mapper/operation/OverDetailsMapper.xml | 26 + .../main/resources/mapper/operation/OverMapper.xml | 26 + .../resources/mapper/operation/SolveMapper.xml | 24 + .../mapper/ticket/TicketEvaluateMapper.xml | 5 + .../main/resources/mapper/ticket/TicketMapper.xml | 5 + .../resources/mapper/ticket/WorkTicketMapper.xml | 4 + .../defect/service/IOperDefectService.java | 90 +- .../hzims/operational/fill/mapper/OtherMapper.java | 8 - .../hzims/operational/fill/mapper/OtherMapper.xml | 25 - 52 files changed, 2441 insertions(+), 125 deletions(-) create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/equipment/PlanMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/AccessMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/DefectMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/MaintenanceMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OtherMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OverDetailsMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OverMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/SolveMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/TicketEvaluateMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/TicketMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/WorkTicketMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/PlanService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/PlanServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AccessService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/DefectService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MaintenanceService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OtherService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OverDetailsService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OverService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ShowService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/SolveService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AccessServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/DefectServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MaintenanceServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OtherServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OverDetailsServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OverServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ShowServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/SolveServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketEvaluateService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/WorkTicketService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketEvaluateServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/equipment/PlanMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/AccessMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/DefectMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/MaintenanceMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OtherMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OverDetailsMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OverMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/SolveMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/TicketEvaluateMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/TicketMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/WorkTicketMapper.xml delete mode 100644 hzims-service/operational/src/main/java/com/hnac/hzims/operational/fill/mapper/OtherMapper.java delete mode 100644 hzims-service/operational/src/main/java/com/hnac/hzims/operational/fill/mapper/OtherMapper.xml diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/equipment/PlanMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/equipment/PlanMapper.java new file mode 100644 index 0000000..d2948fa --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/equipment/PlanMapper.java @@ -0,0 +1,17 @@ +package com.hnac.hzims.scheduled.mapper.equipment; + + +import com.hnac.hzims.equipment.entity.PlanGenerationEntity; +import org.apache.ibatis.annotations.Param; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +import java.util.List; + +/** + * @author ysj + */ +public interface PlanMapper extends UserDataScopeBaseMapper { + + // 查询计划发电量 + List planGeneration(@Param("stationIds") List stationIds, @Param("deptIds") List deptIds, @Param("date") String date); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/AccessMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/AccessMapper.java new file mode 100644 index 0000000..a9b5957 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/AccessMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.access.entity.OperAccessTaskEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface AccessMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/DefectMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/DefectMapper.java new file mode 100644 index 0000000..34d3a1c --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/DefectMapper.java @@ -0,0 +1,12 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.defect.entity.OperDefectEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface DefectMapper extends UserDataScopeBaseMapper { + + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/MaintenanceMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/MaintenanceMapper.java new file mode 100644 index 0000000..2480f52 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/MaintenanceMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.maintenance.entity.OperMaintenanceTaskEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface MaintenanceMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OtherMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OtherMapper.java new file mode 100644 index 0000000..90c2d6d --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OtherMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.fill.entity.OtherEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface OtherMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OverDetailsMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OverDetailsMapper.java new file mode 100644 index 0000000..32582ec --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OverDetailsMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.fill.entity.OverDetailsEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface OverDetailsMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OverMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OverMapper.java new file mode 100644 index 0000000..17f20f9 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/OverMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.fill.entity.OverEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface OverMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/SolveMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/SolveMapper.java new file mode 100644 index 0000000..e09fef2 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/SolveMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.fill.entity.SolveEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface SolveMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/TicketEvaluateMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/TicketEvaluateMapper.java new file mode 100644 index 0000000..31feb3e --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/TicketEvaluateMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.ticket; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.hnac.hzims.ticket.allTicket.entity.TicketInfoEvaluateEntity; + +/** + * @author ysj + */ +public interface TicketEvaluateMapper extends BaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/TicketMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/TicketMapper.java new file mode 100644 index 0000000..a17dd00 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/TicketMapper.java @@ -0,0 +1,13 @@ +package com.hnac.hzims.scheduled.mapper.ticket; + +import com.hnac.hzims.ticket.standardTicket.entity.StandardTicketInfoEntity; +import org.apache.ibatis.annotations.Mapper; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +@Mapper +public interface TicketMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/WorkTicketMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/WorkTicketMapper.java new file mode 100644 index 0000000..e30a55e --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/ticket/WorkTicketMapper.java @@ -0,0 +1,14 @@ +package com.hnac.hzims.scheduled.mapper.ticket; + +import com.hnac.hzims.ticket.workTicket.entity.WorkTicketInfoEntity; +import org.apache.ibatis.annotations.Mapper; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +@Mapper +public interface WorkTicketMapper extends UserDataScopeBaseMapper { + + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ShowScheduledTask.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ShowScheduledTask.java index c7bb905..426502e 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ShowScheduledTask.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ShowScheduledTask.java @@ -1,8 +1,18 @@ package com.hnac.hzims.scheduled.scheduled; +import com.hnac.hzims.scheduled.service.operation.ShowService; +import com.xxl.job.core.biz.model.ReturnT; +import com.xxl.job.core.handler.annotation.XxlJob; import lombok.extern.slf4j.Slf4j; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.Func; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; +import java.util.Date; + +import static com.hnac.hzims.operational.main.constant.MainConstants.LOAD_HOME_TARGET; + /** * @author ysj @@ -11,4 +21,18 @@ import org.springframework.stereotype.Component; @Component public class ShowScheduledTask { + @Autowired + private ShowService service; + + /** + * 首页-指标数据加载 + */ + @XxlJob(LOAD_HOME_TARGET) + public ReturnT loadHomeTarget(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM"); + } + service.loadHomeTarget(param); + return new ReturnT<>("SUCCESS"); + } } \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/PlanService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/PlanService.java new file mode 100644 index 0000000..52f4d3a --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/PlanService.java @@ -0,0 +1,16 @@ +package com.hnac.hzims.scheduled.service.equipment; + +import com.hnac.hzims.equipment.entity.PlanGenerationEntity; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * @author ysj + */ +public interface PlanService extends BaseService { + + + // 查询计划发电量 + List planGeneration(List stationIds, List deptIds, String date); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/PlanServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/PlanServiceImpl.java new file mode 100644 index 0000000..1091c99 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/PlanServiceImpl.java @@ -0,0 +1,33 @@ +package com.hnac.hzims.scheduled.service.equipment.impl; + +import com.hnac.hzims.equipment.entity.PlanGenerationEntity; +import com.hnac.hzims.scheduled.mapper.equipment.PlanMapper; +import com.hnac.hzims.scheduled.service.equipment.PlanService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +import java.util.List; + +/** + * @author ysj + */ +@Service +@Slf4j +@AllArgsConstructor +public class PlanServiceImpl extends BaseServiceImpl implements PlanService { + + + /** + * 查询计划发电量 + * @param stationIds + * @param deptIds + * @param date + * @return + */ + @Override + public List planGeneration(List stationIds, List deptIds, String date) { + return this.baseMapper.planGeneration(stationIds,deptIds,date); + } +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AccessService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AccessService.java new file mode 100644 index 0000000..f42d943 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AccessService.java @@ -0,0 +1,14 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.access.entity.OperAccessTaskEntity; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * @author ysj + */ +public interface AccessService extends BaseService { + + double accessCount(List areas); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/DefectService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/DefectService.java new file mode 100644 index 0000000..929732f --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/DefectService.java @@ -0,0 +1,14 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.defect.entity.OperDefectEntity; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * @author Lch + */ +public interface DefectService extends BaseService { + + Double defectCount(List areas); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MaintenanceService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MaintenanceService.java new file mode 100644 index 0000000..49b4012 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MaintenanceService.java @@ -0,0 +1,15 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.maintenance.entity.OperMaintenanceTaskEntity; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * @author ysj + */ +public interface MaintenanceService extends BaseService { + + // 查询当年日常维护数量 + Integer maintenanceCount(List departList); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java index 087a7e5..d9bfd85 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java @@ -9,8 +9,9 @@ public interface MonitorService { // realId刷新 void loadRealId(String param); + // 实时数据刷新 + void loadRealData(String param); + // 集中监控数据处理 void loadMonitoring(String param); - - void loadRealData(String param); } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OtherService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OtherService.java new file mode 100644 index 0000000..50451a4 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OtherService.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.fill.entity.OtherEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author ysj + */ +public interface OtherService extends BaseService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OverDetailsService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OverDetailsService.java new file mode 100644 index 0000000..13e6eab --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OverDetailsService.java @@ -0,0 +1,12 @@ +package com.hnac.hzims.scheduled.service.operation; + + +import com.hnac.hzims.operational.fill.entity.OverDetailsEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author ysj + */ +public interface OverDetailsService extends BaseService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OverService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OverService.java new file mode 100644 index 0000000..3412374 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/OverService.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.fill.entity.OverEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author ysj + */ +public interface OverService extends BaseService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ShowService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ShowService.java new file mode 100644 index 0000000..a86eed7 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ShowService.java @@ -0,0 +1,9 @@ +package com.hnac.hzims.scheduled.service.operation; + +/** + * @author ysj + */ +public interface ShowService { + + void loadHomeTarget(String param); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/SolveService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/SolveService.java new file mode 100644 index 0000000..5888433 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/SolveService.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.fill.entity.SolveEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author ysj + */ +public interface SolveService extends BaseService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AccessServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AccessServiceImpl.java new file mode 100644 index 0000000..1a1fb7c --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AccessServiceImpl.java @@ -0,0 +1,51 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.hnac.hzims.operational.access.entity.OperAccessTaskEntity; +import com.hnac.hzims.scheduled.mapper.operation.AccessMapper; +import com.hnac.hzims.scheduled.service.operation.AccessService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springframework.stereotype.Service; + +import java.time.LocalDate; +import java.time.LocalDateTime; +import java.time.LocalTime; +import java.util.List; + + +/** + * @author ysj + */ +@Service +@Slf4j +@AllArgsConstructor +public class AccessServiceImpl extends BaseServiceImpl implements AccessService { + + /** + * 查询当年检修任务数量 + * @param areas + * @return + */ + @Override + public double accessCount(List areas) { + if(CollectionUtil.isEmpty(areas)) { + return 0; + } + LocalDate firstDay = LocalDate.now().withDayOfYear(1); + LocalDateTime firstDateTime = LocalDateTime.of(firstDay, LocalTime.MIN); + LocalDateTime now = LocalDateTime.now(); + //日常维护 + List accesss = this.list(new LambdaQueryWrapper(){{ + ge(OperAccessTaskEntity::getPlanStartTime,firstDateTime); + le(OperAccessTaskEntity::getPlanStartTime,now); + in(OperAccessTaskEntity::getCreateDept,areas); + }}); + if(CollectionUtil.isEmpty(accesss)){ + return 0; + } + return accesss.size(); + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/DefectServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/DefectServiceImpl.java new file mode 100644 index 0000000..84af907 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/DefectServiceImpl.java @@ -0,0 +1,55 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.hnac.hzims.operational.defect.entity.OperDefectEntity; +import com.hnac.hzims.scheduled.mapper.operation.DefectMapper; +import com.hnac.hzims.scheduled.service.operation.DefectService; +import lombok.AllArgsConstructor; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springframework.stereotype.Service; + +import java.math.BigDecimal; +import java.time.LocalDate; +import java.time.LocalDateTime; +import java.time.LocalTime; +import java.util.List; +import java.util.stream.Collectors; + +/** + * @author ysj + */ +@Service +@AllArgsConstructor +public class DefectServiceImpl extends BaseServiceImpl implements DefectService { + + /** + * 获取消缺率 + * @param areas + * @return + */ + @Override + public Double defectCount(List areas) { + if(CollectionUtil.isEmpty(areas)) { + return 100.00; + } + LocalDate firstDay = LocalDate.now().withDayOfYear(1); + LocalDateTime firstDateTime = LocalDateTime.of(firstDay, LocalTime.MIN); + LocalDateTime now = LocalDateTime.now(); + List pTaskList = this.list(new LambdaQueryWrapper(){{ + ge(OperDefectEntity::getCreateTime,firstDateTime); + le(OperDefectEntity::getCreateTime,now); + in(OperDefectEntity::getCreateDept,areas); + }}); + if(CollectionUtil.isEmpty(pTaskList)){ + return 0.0; + } + // 缺陷处理完成数 + List finishTask = pTaskList.stream().filter(defect -> "1".equals(defect.getHandleStatus())).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(finishTask)){ + return 0.0; + } + // 消缺率 = (缺陷数 / 总数) * 100 + return BigDecimal.valueOf(finishTask.size() / (double) pTaskList.size() * 100).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue(); + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MaintenanceServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MaintenanceServiceImpl.java new file mode 100644 index 0000000..6ec8d3e --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MaintenanceServiceImpl.java @@ -0,0 +1,50 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.hnac.hzims.operational.maintenance.entity.OperMaintenanceTaskEntity; +import com.hnac.hzims.scheduled.mapper.operation.MaintenanceMapper; +import com.hnac.hzims.scheduled.service.operation.MaintenanceService; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springframework.stereotype.Service; + +import java.time.LocalDate; +import java.time.LocalDateTime; +import java.time.LocalTime; +import java.util.List; + +/** + * @author ysj + */ +@Service +@RequiredArgsConstructor +@Slf4j +public class MaintenanceServiceImpl extends BaseServiceImpl implements MaintenanceService { + + /** + * 获取日常维护数量 + * @param departList + * @return + */ + @Override + public Integer maintenanceCount(List departList) { + if(CollectionUtil.isEmpty(departList)){ + return 0; + } + LocalDate firstDay = LocalDate.now().withDayOfYear(1); + LocalDateTime firstDateTime = LocalDateTime.of(firstDay, LocalTime.MIN); + LocalDateTime now = LocalDateTime.now(); + //日常维护 + List mTaskList = this.list(new LambdaQueryWrapper(){{ + ge(OperMaintenanceTaskEntity::getDisposeTime,firstDateTime); + le(OperMaintenanceTaskEntity::getDisposeTime,now); + in(OperMaintenanceTaskEntity::getCreateDept,departList); + }}); + if(CollectionUtil.isEmpty(mTaskList)){ + return 0; + } + return mTaskList.size(); + } +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OtherServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OtherServiceImpl.java new file mode 100644 index 0000000..202c396 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OtherServiceImpl.java @@ -0,0 +1,19 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.hnac.hzims.operational.fill.entity.OtherEntity; +import com.hnac.hzims.scheduled.mapper.operation.OtherMapper; +import com.hnac.hzims.scheduled.service.operation.OtherService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author ysj + */ +@Slf4j +@Service +@AllArgsConstructor +public class OtherServiceImpl extends BaseServiceImpl implements OtherService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OverDetailsServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OverDetailsServiceImpl.java new file mode 100644 index 0000000..dc69ec3 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OverDetailsServiceImpl.java @@ -0,0 +1,19 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.hnac.hzims.operational.fill.entity.OverDetailsEntity; +import com.hnac.hzims.scheduled.mapper.operation.OverDetailsMapper; +import com.hnac.hzims.scheduled.service.operation.OverDetailsService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author ysj + */ +@Slf4j +@Service +@AllArgsConstructor +public class OverDetailsServiceImpl extends BaseServiceImpl implements OverDetailsService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OverServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OverServiceImpl.java new file mode 100644 index 0000000..f629fc7 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/OverServiceImpl.java @@ -0,0 +1,19 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.hnac.hzims.operational.fill.entity.OverEntity; +import com.hnac.hzims.scheduled.mapper.operation.OverMapper; +import com.hnac.hzims.scheduled.service.operation.OverService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author ysj + */ +@Slf4j +@Service +@AllArgsConstructor +public class OverServiceImpl extends BaseServiceImpl implements OverService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java index eacda88..c34da3f 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java @@ -87,7 +87,6 @@ public class RealTargetServiceImpl implements RealTargetService { private final static String load_photovoltaic_target_key = "hzims:operation:photovoltaic:target:key"; - /** * 加载水电站机组实时数据 * @param param diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ShowServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ShowServiceImpl.java new file mode 100644 index 0000000..5d87218 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ShowServiceImpl.java @@ -0,0 +1,480 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.alibaba.fastjson.JSONObject; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.google.common.util.concurrent.ThreadFactoryBuilder; +import com.hnac.hzims.equipment.entity.PlanGenerationEntity; +import com.hnac.hzims.operational.fill.entity.*; +import com.hnac.hzims.operational.main.constant.HomePageConstant; +import com.hnac.hzims.operational.main.vo.*; +import com.hnac.hzims.operational.station.entity.StationEntity; +import com.hnac.hzims.scheduled.service.equipment.PlanService; +import com.hnac.hzims.scheduled.service.operation.*; +import com.hnac.hzims.scheduled.service.ticket.TicketService; +import com.hnac.hzims.ticket.allTicket.vo.DoublePassRateVO; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.ObjectUtil; +import org.springblade.core.tool.utils.StringUtil; +import org.springblade.system.cache.DictCache; +import org.springblade.system.entity.Dept; +import org.springblade.system.feign.ISysClient; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.data.redis.core.RedisTemplate; +import org.springframework.stereotype.Service; + +import java.io.BufferedReader; +import java.io.IOException; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.math.BigDecimal; +import java.net.HttpURLConnection; +import java.net.URL; +import java.nio.charset.StandardCharsets; +import java.time.LocalDate; +import java.time.LocalDateTime; +import java.time.LocalTime; +import java.util.Date; +import java.util.List; +import java.util.concurrent.*; +import java.util.stream.Collectors; + +/** + * @author ysj + */ +@Service +@RequiredArgsConstructor +@Slf4j +public class ShowServiceImpl implements ShowService { + + private final OverService overService; + private final PlanService planService; + private final PowerService powerService; + private final SolveService solveService; + private final OtherService otherService; + private final AccessService accessService; + private final TicketService ticketService; + private final DefectService defectService; + private final StationService stationService; + private final OverDetailsService detailsService; + private final MaintenanceService maintenanceService; + private final RedisTemplate redisTemplate; + private final ISysClient sysClient; + + + private final static String charge = "hzims:operation:key:charge"; + private final static String home_target_cache_final = "load:operation:home:target:key"; + private final static String hydropower_real_cache_final = "hzims:operation:loadhydropowerunit:real:key"; + private final static String hydropower_target_cache_final = "hzims:operation:loadhydropowerunit:target:key"; + private final static String photovoltaic_real_cache_final = "hzims:operation:photovoltaic:real:key"; + private final static String photovoltaic_target_cache_final = "hzims:operation:photovoltaic:target:key"; + + @Value("${hzims.operation.homePage.charge.url}") + public String charge_url; + + /** + * 集团总指标-首页数据 + */ + @Override + public void loadHomeTarget(String param) { + List targets = HomePageConstant.HOME_TYPES.stream().map(type->{ + if(type == 0) { + return this.hydropowerTaget(); + } + if (type == 1) { + return this.windTaget(); + } + if (type == 2) { + return this.waterStorageTaget(true); + } + if (type == 3) { + return this.waterStorageTaget(false); + } + if (type == 4) { + return this.networkTaget(); + } + if (type == 5) { + return this.photovoltaicTaget(); + } + if (type == 6) { + return this.affairsTaget(); + } + if(type == 7) { + return this.chargeTarget(); + } + return new TargetVo(); + }).collect(Collectors.toList()); + redisTemplate.opsForValue().set(home_target_cache_final,targets.stream().filter(( target -> ObjectUtil.isNotEmpty(target.getType()))).collect(Collectors.toList())); + } + + /** + * 水电站指标 + * @return + */ + private TargetVo hydropowerTaget() { + TargetVo target = new TargetVo(); + target.setType(HomePageConstant.HYDROPOWER); + target.setTypeName(DictCache.getValue("stationType", HomePageConstant.HYDROPOWER)); + // 实时数据 + List reals = (List) redisTemplate.opsForValue().get(hydropower_real_cache_final); + // 指标数据 + List targets = (List) redisTemplate.opsForValue().get(hydropower_target_cache_final); + if(CollectionUtil.isNotEmpty(reals)){ + // 装机容量 + target.setTaget_one(reals.stream().mapToDouble(HydropowerUnitRealVo::getInstalledCapacity).sum()); + } + if(CollectionUtil.isNotEmpty(targets)){ + // 发电量 + target.setTaget_two(targets.stream().mapToDouble(HydropowerUnitTargetVo::getPowerYear).sum()); + } + // 计划发电量 + List stations = stationService.list(Wrappers.lambdaQuery() + .eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE) + .eq(StationEntity::getType,HomePageConstant.HYDROPOWER)); + if(CollectionUtil.isNotEmpty(stations)){ + List plans = planService.planGeneration(stations.stream().map(StationEntity::getCode).collect(Collectors.toList()), null, DateUtil.format(new Date(), "yyyy")); + if(CollectionUtil.isNotEmpty(plans)){ + double plan = plans.stream().mapToDouble(PlanGenerationEntity::getPlanGeneration).sum(); + if(Math.abs(plan) > 0){ + target.setTaget_three(BigDecimal.valueOf(target.getTaget_two() / plan * 100).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue()); + } + } + } + // 双票合格率 + R> result = sysClient.getDeptList(); + if(result.isSuccess() && CollectionUtil.isNotEmpty(result.getData()) && CollectionUtil.isNotEmpty(stations)){ + List areas = result.getData().stream().filter(dept -> stations.stream().map(StationEntity::getRefDept).collect(Collectors.toList()).contains(dept.getId())).map(Dept::getParentId).collect(Collectors.toList()); + if(CollectionUtil.isNotEmpty(areas)){ + LocalDateTime firstDateTime = LocalDateTime.of(LocalDate.now().withDayOfYear(1), LocalTime.MIN); + DoublePassRateVO pass = ticketService.doublePassRate(areas, firstDateTime, LocalDateTime.now()); + if(ObjectUtil.isNotEmpty(pass)){ + target.setTaget_four(Double.valueOf(pass.getDoublePassRate())); + } + } + } + return target; + } + + /** + * 风电指标 + * @return + */ + private TargetVo windTaget() { + TargetVo target = new TargetVo(); + target.setType(HomePageConstant.WIND_POWER); + target.setTypeName(DictCache.getValue("stationType", HomePageConstant.WIND_POWER)); + // 填报发电量 + List stations = stationService.list(Wrappers.lambdaQuery() + .eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE) + .eq(StationEntity::getType,HomePageConstant.WIND_POWER)); + if(CollectionUtil.isEmpty(stations)){ + return target; + } + QueryWrapper queryWrapper = new QueryWrapper() {{ + in("create_dept", stations.stream().map(StationEntity::getRefDept).collect(Collectors.toList())); + eq("type", HomePageConstant.WIND_POWER_TYPE); + likeRight("mon", DateUtil.format(new Date(),"yyyy")); + }}; + List list = powerService.list(queryWrapper); + if(CollectionUtil.isEmpty(list)){ + return target; + } + double plan = list.stream().mapToDouble(PowerEntity::getPlannedPowerMon).sum(); + double pass = list.stream().mapToDouble(power -> Double.parseDouble(power.getDoubleQualifyRate())).sum(); + // 装机容量 + target.setTaget_one(list.stream().map(PowerEntity::getInstalledCapacity).collect(Collectors.toSet()).stream().mapToDouble(Double::valueOf).sum()); + // 发电量 + target.setTaget_two(list.stream().mapToDouble(PowerEntity::getPowerMon).sum()); + if(Math.abs(plan) > 0){ + // 发电完成率 + target.setTaget_three(BigDecimal.valueOf(target.getTaget_two() / plan * 100).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue()); + } + // 双票合格率 + target.setTaget_four(BigDecimal.valueOf(pass / list.size()).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue()); + return target; + } + + /** + * 储能指标 + * @param flag : true - 水利 false - 储能 + * @return + */ + private TargetVo waterStorageTaget(boolean flag) { + TargetVo target = new TargetVo(); + if(flag){ + target.setType(HomePageConstant.WATER_CONSERVANCY); + target.setTypeName(DictCache.getValue("stationType", HomePageConstant.WATER_CONSERVANCY)); + }else{ + target.setType(HomePageConstant.ENERGY_STORAGE); + target.setTypeName(DictCache.getValue("stationType", HomePageConstant.ENERGY_STORAGE)); + } + // 查询储能站点 + LambdaQueryWrapper wrapper = new LambdaQueryWrapper<>(); + wrapper.eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE); + if(flag){ + wrapper.eq(StationEntity::getType,HomePageConstant.WATER_CONSERVANCY); + }else{ + wrapper.eq(StationEntity::getType,HomePageConstant.ENERGY_STORAGE); + } + List stations = stationService.list(wrapper); + if(CollectionUtil.isEmpty(stations)){ + return target; + } + // 获取储能区域级别机构 + R> result = sysClient.getDeptList(); + if(result.isSuccess() && CollectionUtil.isNotEmpty(result.getData()) && CollectionUtil.isNotEmpty(stations)){ + List areas = result.getData().stream().filter(dept -> stations.stream().map(StationEntity::getRefDept).collect(Collectors.toList()).contains(dept.getId())).map(Dept::getParentId).collect(Collectors.toList()); + if(CollectionUtil.isNotEmpty(areas)){ + ThreadFactory namedThreadFactory = new ThreadFactoryBuilder().setNameFormat("storage-taget-pool-%d").build(); + ScheduledExecutorService exe = new ScheduledThreadPoolExecutor(4, namedThreadFactory, new ThreadPoolExecutor.AbortPolicy()); + // 监控线程执行完后返回结果 + CountDownLatch countDownLatch = new CountDownLatch(4); + // 日常维护 + exe.execute(() -> { + target.setTaget_one(Double.valueOf(maintenanceService.maintenanceCount(areas))); + countDownLatch.countDown(); + }); + // 检修任务 + exe.execute(() -> { + target.setTaget_two(accessService.accessCount(areas)); + countDownLatch.countDown(); + }); + // 消缺率 + exe.execute(() -> { + target.setTaget_three(defectService.defectCount(areas)); + countDownLatch.countDown(); + }); + // 双票合格率 + exe.execute(() -> { + LocalDate firstDay = LocalDate.now().withDayOfYear(1); + LocalDateTime firstDateTime = LocalDateTime.of(firstDay, LocalTime.MIN); + DoublePassRateVO pass = ticketService.doublePassRate(areas, firstDateTime, LocalDateTime.now()); + if (ObjectUtil.isNotEmpty(pass)) { + target.setTaget_four(Double.valueOf(pass.getDoublePassRate())); + } + countDownLatch.countDown(); + }); + try { + countDownLatch.await(); + } catch (InterruptedException e) { + e.printStackTrace(); + Thread.currentThread().interrupt(); + } + exe.shutdown(); + } + } + return target; + } + + /** + * 配网 + * @return + */ + private TargetVo networkTaget() { + TargetVo target = new TargetVo(); + target.setType(HomePageConstant.DISTRIBUTION_NETWORK); + target.setTypeName(DictCache.getValue("stationType", HomePageConstant.DISTRIBUTION_NETWORK)); + // 线程池 + ThreadFactory namedThreadFactory = new ThreadFactoryBuilder().setNameFormat("network-taget-pool-%d").build(); + ScheduledExecutorService exe = new ScheduledThreadPoolExecutor(3, namedThreadFactory, new ThreadPoolExecutor.AbortPolicy()); + // 监控线程执行完后返回结果 + CountDownLatch countDownLatch = new CountDownLatch(3); + // 当月 + LocalDate firstDay = LocalDate.now().withDayOfYear(1); + LocalDateTime firstDateTime = LocalDateTime.of(firstDay, LocalTime.MIN); + // 检修卡 + exe.execute(()->{ + List overs = overService.list(new QueryWrapper() {{ + ge("create_time", firstDateTime); + le("create_time", LocalDateTime.now()); + }}); + if(CollectionUtil.isEmpty(overs)){ + countDownLatch.countDown(); + return; + } + List details = detailsService.list(new QueryWrapper() {{ + ge("create_time", firstDateTime); + le("create_time", LocalDateTime.now()); + in("over_id",overs.stream().map(OverEntity::getId).collect(Collectors.toList())); + }}); + if(CollectionUtil.isEmpty(details)){ + countDownLatch.countDown(); + return; + } + target.setTaget_one(details.stream().mapToDouble(OverDetailsEntity::getQuantity).sum()); + countDownLatch.countDown(); + }); + // 消缺 + exe.execute(()->{ + List solves = solveService.list(new QueryWrapper() {{ + ge("create_time", firstDateTime); + le("create_time", LocalDateTime.now()); + }}); + if(CollectionUtil.isEmpty(solves)){ + countDownLatch.countDown(); + return; + } + target.setTaget_two(solves.stream().mapToDouble(SolveEntity::getSolveQuantity).sum()); + countDownLatch.countDown(); + }); + // 其他 + exe.execute(()->{ + List others = otherService.list(new QueryWrapper() {{ + ge("create_time", firstDateTime); + le("create_time", LocalDateTime.now()); + }}); + if(CollectionUtil.isEmpty(others)){ + countDownLatch.countDown(); + return; + } + // FA上线率 + double online = others.stream().mapToDouble(o-> Double.parseDouble(o.getOnlineRate())).sum(); + if(Math.abs(online) > 0){ + target.setTaget_three(BigDecimal.valueOf(online / others.size()).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue()); + } + // FA投入条数 + target.setTaget_four(others.stream().mapToDouble(OtherEntity::getFaQuantity).sum()); + countDownLatch.countDown(); + }); + // 等待所有线程执行完成 + try { + countDownLatch.await(); + } catch (InterruptedException e) { + e.printStackTrace(); + Thread.currentThread().interrupt(); + } + return target; + } + + /** + * 光伏指标 + * @return + */ + private TargetVo photovoltaicTaget() { + TargetVo target = new TargetVo(); + target.setType(HomePageConstant.PHOTOVOLTAIC); + target.setTypeName(DictCache.getValue("stationType", HomePageConstant.PHOTOVOLTAIC)); + // 实时数据 + List reals = (List) redisTemplate.opsForValue().get(photovoltaic_real_cache_final); + // 指标数据 + List targets = (List) redisTemplate.opsForValue().get(photovoltaic_target_cache_final); + if(CollectionUtil.isNotEmpty(reals)){ + // 装机容量 + target.setTaget_one(reals.stream().mapToDouble(PhotovoltaicRealVo::getCapacity).sum()); + } + if(CollectionUtil.isNotEmpty(targets)){ + // 发电量 + target.setTaget_two(targets.stream().mapToDouble(PhotovoltaicTargetVo::getGenerationYear).sum()); + } + // 计划发电量、双票合格率 + List stations = stationService.list(Wrappers.lambdaQuery() + .eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE) + .eq(StationEntity::getType,HomePageConstant.PHOTOVOLTAIC)); + if(CollectionUtil.isNotEmpty(stations)){ + QueryWrapper queryWrapper = new QueryWrapper() {{ + in("create_dept", stations.stream().map(StationEntity::getRefDept).collect(Collectors.toList())); + eq("type", HomePageConstant.PHOTOVOLTAIC_TYPE); + likeRight("mon", DateUtil.format(new Date(),"yyyy")); + }}; + List list = powerService.list(queryWrapper); + if(CollectionUtil.isEmpty(list)){ + return target; + } + double plan = list.stream().mapToDouble(PowerEntity::getPlannedPowerMon).sum(); + double pass = list.stream().mapToDouble(power -> Double.parseDouble(power.getDoubleQualifyRate())).sum(); + if(Math.abs(plan) > 0){ + // 发电完成率 + target.setTaget_three(BigDecimal.valueOf(target.getTaget_two() / plan * 100).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue()); + } + // 双票合格率 + target.setTaget_four(BigDecimal.valueOf(pass / list.size()).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue()); + } + return target; + } + + /** + * 水务指标 + * @return + */ + private TargetVo affairsTaget() { + TargetVo target = new TargetVo(); + target.setType(HomePageConstant.WATER_AFFAIRS); + target.setTypeName(DictCache.getValue("stationType", HomePageConstant.WATER_AFFAIRS)); + // TODO 统计业务数据 + return target; + } + + /** + * 充电桩 + * @return + */ + private TargetVo chargeTarget() { + TargetVo target = (TargetVo) redisTemplate.opsForValue().get(charge); + if(ObjectUtil.isNotEmpty(target)){ + return target; + } + target = new TargetVo(); + try { + URL serverUrl = new URL(charge_url); + HttpURLConnection conn = (HttpURLConnection) serverUrl.openConnection(); + conn.setRequestMethod("GET"); + conn.setRequestProperty("Content-type", "application/json"); + //必须设置false,否则会自动redirect到重定向后的地址 + conn.setInstanceFollowRedirects(false); + conn.connect(); + String result = responseFormat(conn); + if (StringUtil.isBlank(result)) { + return new TargetVo(); + } + JSONObject jsonObject = JSONObject.parseObject(result); + JSONObject data = JSONObject.parseObject(jsonObject.get("data").toString()); + target.setType(HomePageConstant.CHARGE); + target.setTypeName(DictCache.getValue("stationType", HomePageConstant.CHARGE)); + target.setTaget_one(Double.valueOf(data.get("ordersCount").toString())); + target.setTaget_two(Double.valueOf(data.get("todayDegree").toString())); + target.setTaget_three(Double.valueOf(data.get("income").toString())); + target.setTaget_four(Double.valueOf(data.get("kilowatt").toString())); + target.setCharge(Integer.valueOf(data.get("stationNum").toString())); + redisTemplate.opsForValue().set(charge,target); + redisTemplate.expire(charge,30, TimeUnit.MINUTES); + } catch (Exception e) { + target.setType(HomePageConstant.CHARGE); + target.setTypeName(DictCache.getValue("stationType", HomePageConstant.CHARGE)); + target.setTaget_one(0.0); + target.setTaget_two(0.0); + target.setTaget_three(0.0); + target.setTaget_four(0.0); + target.setCharge(0); + log.error("charge_target_exception: {} ", e.getMessage()); + } + return target; + } + + /*** + * 获取返回的内容 + * @param connection + * @return + */ + private String responseFormat(HttpURLConnection connection) { + StringBuilder stringBuilder = new StringBuilder(); + //将返回的输入流转换成字符串 + try ( + InputStream inputStream = connection.getInputStream(); + InputStreamReader inputStreamReader = new InputStreamReader(inputStream, StandardCharsets.UTF_8); + BufferedReader bufferedReader = new BufferedReader(inputStreamReader) + ) { + String str; + while ((str = bufferedReader.readLine()) != null) { + stringBuilder.append(str); + } + } catch (IOException e) { + return null; + } + return stringBuilder.toString(); + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/SolveServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/SolveServiceImpl.java new file mode 100644 index 0000000..6d5238a --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/SolveServiceImpl.java @@ -0,0 +1,20 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.hnac.hzims.operational.fill.entity.SolveEntity; +import com.hnac.hzims.scheduled.mapper.operation.SolveMapper; +import com.hnac.hzims.scheduled.service.operation.SolveService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author ysj + */ +@Slf4j +@Service +@AllArgsConstructor +public class SolveServiceImpl extends BaseServiceImpl implements SolveService { + + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketEvaluateService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketEvaluateService.java new file mode 100644 index 0000000..ad99144 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketEvaluateService.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.service.ticket; + +import com.hnac.hzims.ticket.allTicket.entity.TicketInfoEvaluateEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author hx + */ +public interface TicketEvaluateService extends BaseService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketService.java new file mode 100644 index 0000000..5716e58 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketService.java @@ -0,0 +1,16 @@ +package com.hnac.hzims.scheduled.service.ticket; + +import com.hnac.hzims.ticket.allTicket.vo.DoublePassRateVO; +import com.hnac.hzims.ticket.standardTicket.entity.StandardTicketInfoEntity; +import org.springblade.core.mp.base.BaseService; + +import java.time.LocalDateTime; +import java.util.List; + +/** + * @author ysj + */ +public interface TicketService extends BaseService { + + DoublePassRateVO doublePassRate(List areas, LocalDateTime firstDateTime, LocalDateTime now); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/WorkTicketService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/WorkTicketService.java new file mode 100644 index 0000000..536b410 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/WorkTicketService.java @@ -0,0 +1,7 @@ +package com.hnac.hzims.scheduled.service.ticket; + +import com.hnac.hzims.ticket.workTicket.entity.WorkTicketInfoEntity; +import org.springblade.core.mp.base.BaseService; + +public interface WorkTicketService extends BaseService { +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketEvaluateServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketEvaluateServiceImpl.java new file mode 100644 index 0000000..1bd217e --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketEvaluateServiceImpl.java @@ -0,0 +1,20 @@ +package com.hnac.hzims.scheduled.service.ticket.impl; + +import com.hnac.hzims.scheduled.mapper.ticket.TicketEvaluateMapper; +import com.hnac.hzims.scheduled.service.ticket.TicketEvaluateService; +import com.hnac.hzims.ticket.allTicket.entity.TicketInfoEvaluateEntity; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author ysj + */ +@Service +@RequiredArgsConstructor +@Slf4j +public class TicketEvaluateServiceImpl extends BaseServiceImpl implements TicketEvaluateService { + + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java new file mode 100644 index 0000000..204a17b --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java @@ -0,0 +1,85 @@ +package com.hnac.hzims.scheduled.service.ticket.impl; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.hnac.hzims.scheduled.mapper.ticket.TicketMapper; +import com.hnac.hzims.scheduled.service.ticket.TicketEvaluateService; +import com.hnac.hzims.scheduled.service.ticket.TicketService; +import com.hnac.hzims.scheduled.service.ticket.WorkTicketService; +import com.hnac.hzims.ticket.allTicket.entity.TicketInfoEvaluateEntity; +import com.hnac.hzims.ticket.allTicket.vo.DoublePassRateVO; +import com.hnac.hzims.ticket.constants.TicketConstants; +import com.hnac.hzims.ticket.standardTicket.entity.StandardTicketInfoEntity; +import com.hnac.hzims.ticket.workTicket.entity.WorkTicketInfoEntity; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springframework.stereotype.Service; + +import java.math.BigDecimal; +import java.time.LocalDateTime; +import java.util.ArrayList; +import java.util.List; +import java.util.stream.Collectors; + +/** + * @author ysj + */ +@Service +@RequiredArgsConstructor +@Slf4j +public class TicketServiceImpl extends BaseServiceImpl implements TicketService { + + private final WorkTicketService workTicketService; + private final TicketEvaluateService ticketEvaluateService; + + /** + * 获取双票合格率 + * @param depatList + * @param firstDateTime + * @param now + * @return + */ + @Override + public DoublePassRateVO doublePassRate(List depatList, LocalDateTime firstDateTime, LocalDateTime now) { + DoublePassRateVO doublePassRateVO = new DoublePassRateVO(); + // 查询操作票 + List standardList = this.list(new LambdaQueryWrapper() {{ + ge(StandardTicketInfoEntity::getCreateTime, firstDateTime); + le(StandardTicketInfoEntity::getCreateTime, now); + in(StandardTicketInfoEntity::getCreateDept, depatList); + }}); + // 查询工作票 + List workList = workTicketService.list(new LambdaQueryWrapper() {{ + ge(WorkTicketInfoEntity::getCreateTime, firstDateTime); + le(WorkTicketInfoEntity::getCreateTime, now); + in(WorkTicketInfoEntity::getCreateDept, depatList); + }}); + if (CollectionUtil.isEmpty(standardList) && CollectionUtil.isEmpty(workList)) { + doublePassRateVO.setDoubleTicketCount(0); + doublePassRateVO.setDoubleTicketPassCount(0); + doublePassRateVO.setDoublePassRate("0"); + return doublePassRateVO; + } + List standardIdList = new ArrayList<>(); + standardIdList.addAll(standardList.stream().map(StandardTicketInfoEntity::getId).collect(Collectors.toList())); + standardIdList.addAll(workList.stream().map(WorkTicketInfoEntity::getId).collect(Collectors.toList())); + doublePassRateVO.setDoubleTicketCount(standardIdList.size()); + // 查询合格评价 + List evaluateList = ticketEvaluateService.list(new LambdaQueryWrapper() {{ + ge(TicketInfoEvaluateEntity::getCreateTime, firstDateTime); + le(TicketInfoEvaluateEntity::getCreateTime, now); + in(TicketInfoEvaluateEntity::getTicketId, standardIdList); + eq(TicketInfoEvaluateEntity::getStatus, TicketConstants.TicketQualifiedEnum.Qualified.getCode()); + }}); + if (CollectionUtil.isEmpty(evaluateList)) { + doublePassRateVO.setDoubleTicketPassCount(0); + doublePassRateVO.setDoublePassRate("0"); + return doublePassRateVO; + } + double doublePassRate = BigDecimal.valueOf(evaluateList.size() / (double) standardIdList.size() * 100).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue(); + doublePassRateVO.setDoubleTicketPassCount(evaluateList.size()); + doublePassRateVO.setDoublePassRate(String.valueOf(doublePassRate)); + return doublePassRateVO; + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java new file mode 100644 index 0000000..13dbc45 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java @@ -0,0 +1,1093 @@ +package com.hnac.hzims.scheduled.service.ticket.impl; + +import cn.afterturn.easypoi.excel.entity.TemplateExportParams; +import com.alibaba.fastjson.JSON; +import com.alibaba.fastjson.JSONObject; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; +import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.google.common.collect.Lists; +import com.hnac.hzims.common.logs.utils.StringUtils; +import com.hnac.hzims.operational.access.constants.AccessConstants; +import com.hnac.hzims.operational.access.entity.OperAccessTaskEntity; +import com.hnac.hzims.operational.access.feign.IOperAccessTaskClient; +import com.hnac.hzims.operational.maintenance.dto.OperMaintenanceTaskDTO; +import com.hnac.hzims.operational.maintenance.feign.ITaskClient; +import com.hnac.hzims.ticket.allTicket.entity.TicketInfoEvaluateEntity; +import com.hnac.hzims.ticket.allTicket.service.TicketInfoEvaluateService; +import com.hnac.hzims.ticket.areamonthly.vo.StandardTicketWithAreaVo; +import com.hnac.hzims.ticket.areamonthly.vo.StandardWorkVo; +import com.hnac.hzims.ticket.aspect.AroundFlow; +import com.hnac.hzims.ticket.constants.TicketConstants; +import com.hnac.hzims.ticket.twoTicket.entity.TicketInfoDanger; +import com.hnac.hzims.ticket.twoTicket.entity.WorkTicketFinish; +import com.hnac.hzims.ticket.twoTicket.service.TicketInfoDangerService; +import com.hnac.hzims.ticket.twoTicket.service.impl.WorkTicketFinishServiceImpl; +import com.hnac.hzims.ticket.twoTicket.vo.process.WorkTicketVo; +import com.hnac.hzims.ticket.utils.ExcelUtil; +import com.hnac.hzims.ticket.utils.PdfUtils; +import com.hnac.hzims.ticket.workTicket.entity.*; +import com.hnac.hzims.ticket.workTicket.mapper.WorkDelayNoScopeMapper; +import com.hnac.hzims.ticket.workTicket.mapper.WorkTicketInfoMapper; +import com.hnac.hzims.ticket.workTicket.wrapper.WorkTicketDelayWrapper; +import com.hnac.hzims.ticket.workTicket.wrapper.WorkTicketInfoWrapper; +import com.hnac.hzims.vo.SafeCheckStatisticVO; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.collections.map.HashedMap; +import org.apache.poi.ss.usermodel.Workbook; +import org.springblade.core.log.exception.ServiceException; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.mp.support.BladePage; +import org.springblade.core.mp.support.Condition; +import org.springblade.core.mp.support.Query; +import org.springblade.core.secure.utils.AuthUtil; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.Func; +import org.springblade.core.tool.utils.ObjectUtil; +import org.springblade.flow.core.entity.BladeFlow; +import org.springblade.flow.core.feign.IFlowClient; +import org.springblade.flow.core.vo.ComleteTask; +import org.springblade.system.user.cache.UserCache; +import org.springblade.system.user.entity.User; +import org.springblade.system.user.feign.IUserClient; +import org.springframework.beans.BeanUtils; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Propagation; +import org.springframework.transaction.annotation.Transactional; +import org.springframework.util.Assert; + +import javax.servlet.http.HttpServletResponse; +import java.time.LocalDateTime; +import java.time.YearMonth; +import java.time.format.DateTimeFormatter; +import java.time.temporal.TemporalAdjusters; +import java.util.*; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.concurrent.locks.Lock; +import java.util.concurrent.locks.ReentrantLock; +import java.util.stream.Collectors; + + +/** + *

+ * 工作票 服务实现类 + *

+ * + * @author hx + * @since 2021-10-22 + */ +@Service +@Slf4j +@RequiredArgsConstructor +public class WorkTicketServiceImpl extends BaseServiceImpl implements IWorkTicketInfoService { + + private final IWorkTicketSafetyMeasureService workTicketSafetyMeasureService; + private final IWorkTicketPrincipalChangeService workTicketPrincipalChangeService; + private final IWorkTicketDelayService delayService; + private final IWorkTicketMembersChangeService workTicketMembersChangeService; + private final IWorkTicketOperateTimeService workTicketOperateTimeService; + private final IWorkTicketFlowService workTicketFlowService; + private final IFlowClient flowClient; + private final IUserClient userClient; + private final WorkDelayNoScopeMapper workDelayNoScopeMapper; + private final IOperAccessTaskClient operAccessTaskClient; + private final ITaskClient taskClient; + private final TicketInfoEvaluateService ticketInfoEvaluateService; + private final IWorkTicketContentService workTicketContentService; + private final WorkTicketFinishServiceImpl workTicketFinishService; + private final TicketInfoDangerService ticketInfoDangerService; + + /** 生成两票编号锁 **/ + private Lock lock = new ReentrantLock(); + + /** word模板预览导出保存路径 **/ + @Value("${hzims.ticket.path.xlsx.savePath}") + private String xlsSavePath; + + @Value("${hzims.ticket.first-work-flow-key}") + private String firstWorkTicketFlowKey; + + @Value("${hzims.tenantId}") + private String tenantId; + + @Value("${hzims.ticket.path.pdf.savePath}") + private String pdfSavePath; + + @Override + @Transactional + @AroundFlow + public R doSave(WorkTicketInfoDto req) { + req.setCode(this.getWorkTicketCode()); + req.setStatus(Func.isEmpty(req.getPrincipal()) || Func.isEmpty(req.getClassGroupMembers()) ? TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE.getStatus() : TicketConstants.FirstWorkTicketFlowStatusEnum.SIGN.getStatus()); + boolean flag = this.save(req); + /**保存安全措施**/ + if (flag && CollectionUtil.isNotEmpty(req.getWorkTicketSafetyMeasureDtoList())) { + req.getWorkTicketSafetyMeasureDtoList().forEach(workTicketSafetyMeasureDto -> { + workTicketSafetyMeasureDto.setTicketId(req.getId()); + workTicketSafetyMeasureService.save(workTicketSafetyMeasureDto); + }); + } + if (Func.isEmpty(req.getPrincipal()) || Func.isEmpty(req.getClassGroupMembers())) { + //将票据ID会传至计划/任务内 + returnTicket(req); + return R.success("开票成功!该票走线下未开启流程"); + } + /**开启工作流**/ + BladeFlow bladeFlow = this.startProcessInstance(firstWorkTicketFlowKey, req); + this.update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getProcessInstanceId, bladeFlow.getProcessInstanceId()).eq(WorkTicketInfoEntity::getId, req.getId())); + //将票据ID会传至计划/任务内 + returnTicket(req); + return R.success("保存成功"); + } + + /** + * 工作票延期 进入许可人确认工作票延期 + * + * @param ticketId 工作票ID + * @param status 状态 + * @param completeTask 工作流进行 + */ + @Transactional(rollbackFor = Exception.class, propagation = Propagation.REQUIRED) + public void delay(Long ticketId, Integer status, ComleteTask completeTask) { + //新增延期信息 + Assert.notNull(completeTask.getVariables().get("delay"), "延期信息不能为空"); + WorkTicketDelayEntity delayEntity = (WorkTicketDelayEntity) completeTask.getVariables().get("delay"); + delayService.save(delayEntity); + //更新负责人确认执行情况流程 填充信息 + WorkTicketFlowEntity workTicketFlowEntity = workTicketFlowService.getOne(Wrappers.lambdaQuery().eq(WorkTicketFlowEntity::getTicketId, ticketId).eq(WorkTicketFlowEntity::getFlowCode, TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_WORK_FINISH.getStatus()).orderByDesc(WorkTicketFlowEntity::getCreateTime).last("limit 1;")); + workTicketFlowService.update(Wrappers.lambdaUpdate().set(WorkTicketFlowEntity::getExecutor, AuthUtil.getUserId().toString()).set(WorkTicketFlowEntity::getExecuteTime, LocalDateTime.now()).eq(WorkTicketFlowEntity::getId, workTicketFlowEntity.getId())); + //更新工作票状态 + this.update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, status).eq(WorkTicketInfoEntity::getId, ticketId)); + //创建延期流程 + WorkTicketInfoEntity infoEntity = this.getById(ticketId); + WorkTicketFlowEntity currentFlowEntity = new WorkTicketFlowEntity(); + currentFlowEntity.setTicketId(ticketId); + currentFlowEntity.setFlowCode(status.toString()); + currentFlowEntity.setExecutor(infoEntity.getLicensor().toString()); + currentFlowEntity.setProcTaskId((String) completeTask.getVariables().get("procTaskId")); + workTicketFlowService.save(workTicketFlowEntity); + //进入工作流下一步 + R result = flowClient.completeTask(completeTask); + if (!result.isSuccess()) { + throw new ServiceException("执行工作流失败"); + } + } + + @Override + public R detail(Long id) { + WorkTicketInfoEntity workTicketInfoEntity = this.getById(id); + if (ObjectUtil.isEmpty(workTicketInfoEntity)) { + return R.fail("未查询到该ID对应的记录"); + } else { + WorkTicketInfoVO workTicketInfoVO = WorkTicketInfoWrapper.build().entityVO(workTicketInfoEntity); + + /**获取工作票安全措施列表**/ + WorkTicketSafetyMeasureDto workTicketSafetyMeasureDto = new WorkTicketSafetyMeasureDto(); + workTicketSafetyMeasureDto.setTicketId(id); + List workTicketSafetyMeasureVOList = workTicketSafetyMeasureService.list(workTicketSafetyMeasureDto); + workTicketInfoVO.setWorkTicketSafetyMeasureVOList(workTicketSafetyMeasureVOList); + + /**获取工作票负责人变更**/ + WorkTicketPrincipalChangeDto workTicketPrincipalChangeDto = new WorkTicketPrincipalChangeDto(); + workTicketPrincipalChangeDto.setTicketId(id); + List workTicketPrincipalChangeVOList = workTicketPrincipalChangeService.list(workTicketPrincipalChangeDto); + workTicketInfoVO.setWorkTicketPrincipalChangeVOList(workTicketPrincipalChangeVOList); + + /**获取工作票工作组员变更**/ + WorkTicketMembersChangeDto workTicketMembersChangeDto = new WorkTicketMembersChangeDto(); + workTicketMembersChangeDto.setTicketId(id); + List workTicketMembersChangeVOList = workTicketMembersChangeService.list(workTicketMembersChangeDto); + workTicketInfoVO.setWorkTicketMembersChangeVOList(workTicketMembersChangeVOList); + + /**获取工作票跨日运行时间列表**/ + WorkTicketOperateTimeDto workTicketOperateTimeDto = new WorkTicketOperateTimeDto(); + workTicketOperateTimeDto.setTicketId(id); + List workTicketOperateTimeVOList = workTicketOperateTimeService.list(workTicketOperateTimeDto); + workTicketInfoVO.setWorkTicketOperateTimeVOList(workTicketOperateTimeVOList); + + /**获取工作票处理流程列表**/ + WorkTicketFlowDto workTicketFlowDto = new WorkTicketFlowDto(); + workTicketFlowDto.setTicketId(id); + List workTicketFlowVOList = workTicketFlowService.list(workTicketFlowDto); + workTicketInfoVO.setWorkTicketFlowVOList(workTicketFlowVOList); + + /**获取工作票延期列表**/ + WorkTicketDelayDto workTicketDelayDto = new WorkTicketDelayDto(); + workTicketDelayDto.setTicketId(id); + List workTicketDelayList = workDelayNoScopeMapper.selectList(new LambdaQueryWrapper() {{ + eq(WorkTicketDelayEntity::getTicketId, id); + eq(WorkTicketDelayEntity::getIsDeleted, 0L); + }}); + if (CollectionUtil.isNotEmpty(workTicketDelayList)) { + workTicketInfoVO.setWorkTicketDelayVOList(WorkTicketDelayWrapper.build().listVO(workTicketDelayList)); + } + + return R.data(workTicketInfoVO); + } + } + + @Override + public R> queryList(WorkTicketInfoDto req, Query query) { + LambdaQueryWrapper lqw = this.getQueryWrapper(req); + if (ObjectUtil.isNotEmpty(req.getCreateDept())) { + lqw.eq(WorkTicketInfoEntity::getCreateDept, req.getCreateDept()); + } + + lqw.orderByDesc(WorkTicketInfoEntity::getCreateTime).orderByDesc(WorkTicketInfoEntity::getUpdateTime); + IPage pages = this.page(Condition.getPage(query), lqw); + //数据转换 + IPage workTicketInfoVOIPage = new Page<>(pages.getCurrent(), pages.getSize()); + workTicketInfoVOIPage.setRecords(WorkTicketInfoWrapper.build().listVO(pages.getRecords())); + workTicketInfoVOIPage.setPages(pages.getPages()); + workTicketInfoVOIPage.setTotal(pages.getTotal()); + //获取创建人 + workTicketInfoVOIPage.getRecords().forEach(item -> { + User user = UserCache.getUser(item.getCreateUser()); + if (user != null) { + item.setCreateUserName(user.getName()); + } + }); + + + return R.data(workTicketInfoVOIPage); + } + + @Override + public List list(WorkTicketInfoDto req) { + LambdaQueryWrapper lqw = this.getQueryWrapper(req); + List workTicketInfoEntityList = this.list(lqw); + return CollectionUtil.isNotEmpty(workTicketInfoEntityList) ? WorkTicketInfoWrapper.build().listVO(workTicketInfoEntityList) : null; + } + + @Override + @Transactional + public R remove(Long id, String comment) { + WorkTicketInfoEntity entity = this.getById(id); + if (ObjectUtil.isEmpty(entity)) { + return R.fail(400, "删除失败!未查询到相关记录"); + } + + boolean flag = this.update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, TicketConstants.FirstWorkTicketFlowStatusEnum.TERMINATION.getStatus()).eq(WorkTicketInfoEntity::getId, id)); + + /**线下单独删除**/ + if (TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE.getStatus().equals(entity.getStatus())) { + return R.status(flag); + } + /**终止工作流**/ + R r = flowClient.delProcessInstanceById(entity.getProcessInstanceId(), comment); + if (!r.isSuccess()) { + throw new ServiceException("终止工作流失败!"); + } + return R.success("删除成功!"); + } + + @Override + public void exportWorkTicketTemplate(Long id, HttpServletResponse response) { + exportWorkTicketInfoPdf(id, response); + } + + @Override + @SuppressWarnings("unchecked") + public void exportWorkTicketInfoPdf(Long id, HttpServletResponse response) { + R workTicketInfoVOR = this.detail(id); + if (!workTicketInfoVOR.isSuccess()) { + log.error("未查询到相关工作票记录!"); + return; + } + WorkTicketInfoVO workTicketInfoVO = workTicketInfoVOR.getData(); + //将workTicketInfoVO封装进Map,以便pdf导出 + Map workTicketInfoMap = new HashMap<>(); + try { + workTicketInfoMap = PdfUtils.objectToMap(workTicketInfoVO); + } catch (Exception e) { + log.info("转换对象失败!"); + } + //安全措施 + if (CollectionUtil.isNotEmpty(workTicketInfoVO.getWorkTicketSafetyMeasureVOList())) { + Map> measureMap = workTicketInfoVO.getWorkTicketSafetyMeasureVOList().stream().collect(Collectors.groupingBy(WorkTicketSafetyMeasureVO::getType)); + if (ObjectUtil.isNotEmpty(measureMap.get(TicketConstants.MEASURE_TYPE_ONE))) { + workTicketInfoMap.put("matterLibraryListOne", measureMap.get(TicketConstants.MEASURE_TYPE_ONE).stream().map(measure -> { + Map map = PdfUtils.objectToMap(measure); + map.put("safetyMeasure", ObjectUtil.isNotEmpty(map.get("measure")) ? map.get("measure") : null); + String status = TicketConstants.SafetyMeasureStatusEnum.FINISH.getStatus().equals(measure.getStatus()) ? TicketConstants.SafetyMeasureStatusEnum.FINISH.getDescribe() : " "; + map.put("status", status); + return map; + }).collect(Collectors.toList())); + } else { + workTicketInfoMap.put("matterLibraryListOne", new ArrayList>(1)); + } + if (ObjectUtil.isNotEmpty(measureMap.get(TicketConstants.MEASURE_TYPE_TWO))) { + workTicketInfoMap.put("matterLibraryListTwo", measureMap.get(TicketConstants.MEASURE_TYPE_TWO).stream().map(measure -> { + Map map = PdfUtils.objectToMap(measure); + map.put("safetyMeasure", ObjectUtil.isNotEmpty(map.get("measure")) ? map.get("measure") : null); + String status = TicketConstants.SafetyMeasureStatusEnum.FINISH.getStatus().equals(measure.getStatus()) ? TicketConstants.SafetyMeasureStatusEnum.FINISH.getDescribe() : " "; + map.put("status", status); + return map; + }).collect(Collectors.toList())); + } else { + workTicketInfoMap.put("matterLibraryListTwo", new ArrayList>(1)); + } + if (ObjectUtil.isNotEmpty(measureMap.get(TicketConstants.MEASURE_TYPE_THREE))) { + workTicketInfoMap.put("matterLibraryListThree", measureMap.get(TicketConstants.MEASURE_TYPE_THREE).stream().map(measure -> { + Map map = PdfUtils.objectToMap(measure); + map.put("safetyMeasure", ObjectUtil.isNotEmpty(map.get("measure")) ? map.get("measure") : null); + String status = TicketConstants.SafetyMeasureStatusEnum.FINISH.getStatus().equals(measure.getStatus()) ? TicketConstants.SafetyMeasureStatusEnum.FINISH.getDescribe() : " "; + map.put("status", status); + return map; + }).collect(Collectors.toList())); + } else { + workTicketInfoMap.put("matterLibraryListThree", new ArrayList>(1)); + } + } + //线下开票确认人为空 + workTicketInfoMap.put("membersConfirm", TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE.getStatus().equals(workTicketInfoVO.getStatus()) ? "" : workTicketInfoVO.getMembersName()); + //获取工作票工作流处理信息 + List workTicketFlowVOList = workTicketInfoVO.getWorkTicketFlowVOList(); + //签发 + List signFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.LICENSE.getStatus().equals(Integer.parseInt(f.getFlowCode()))).collect(Collectors.toList()); + if (CollectionUtil.isNotEmpty(signFlow)) { + workTicketInfoMap.put("signer", signFlow.get(0).getCreateUserName()); + workTicketInfoMap.put("signTime", DateUtil.format(signFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); + } else { + workTicketInfoMap.put("signer", ""); + workTicketInfoMap.put("signTime", ""); + } + //许可人许可 + if (Func.isNotEmpty(workTicketInfoVO.getLicenseTime())) { + workTicketInfoMap.put("licensorConfirm", workTicketInfoVO.getLicensorName()); + workTicketInfoMap.put("licenseTime", DateUtil.format(workTicketInfoVO.getLicenseTime(), TicketConstants.TICKET_DATE_PATTERN)); + } else { + workTicketInfoMap.put("licensorConfirm", ""); + workTicketInfoMap.put("licenseTime", ""); + } + + /**负责人收到工作票**/ + List receiveFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_MEASURE_PRINCIPAL.getStatus().equals(Integer.parseInt(f.getFlowCode()))).collect(Collectors.toList()); + if (CollectionUtil.isNotEmpty(receiveFlow)) { + workTicketInfoMap.put("receivePrincipal", receiveFlow.get(0).getCreateUserName()); + workTicketInfoMap.put("receiveTime", DateUtil.format(receiveFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); + workTicketInfoMap.put("principalConfirm", workTicketInfoVO.getPrincipalName()); + } else { + workTicketInfoMap.put("receivePrincipal", ""); + workTicketInfoMap.put("receiveTime", ""); + workTicketInfoMap.put("principalConfirm", ""); + } + /**负责人确认安全事项**/ + List confirmFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_MEASURE_MEMBERS.getStatus().equals(Integer.parseInt(f.getFlowCode()))).collect(Collectors.toList()); + if (CollectionUtil.isNotEmpty(confirmFlow)) { + workTicketInfoMap.put("confirmPrincipal", confirmFlow.get(0).getCreateUserName()); + workTicketInfoMap.put("confirmTime", DateUtil.format(confirmFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); + } else { + workTicketInfoMap.put("confirmPrincipal", ""); + workTicketInfoMap.put("confirmTime", ""); + } + /**工作结束**/ + List finishFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.END.getStatus().equals(Integer.parseInt(f.getFlowCode()))).collect(Collectors.toList()); + if (CollectionUtil.isNotEmpty(finishFlow)) { + workTicketInfoMap.put("finisher", finishFlow.get(0).getCreateUserName()); + workTicketInfoMap.put("finishTime", DateUtil.format(finishFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); + workTicketInfoMap.put("principalFinish", workTicketInfoVO.getPrincipalName()); + } else { + workTicketInfoMap.put("finisher", ""); + workTicketInfoMap.put("finishTime", ""); + workTicketInfoMap.put("principalFinish", ""); + } + /**工作终结**/ + List endFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.FINISH.getStatus().intValue() == Integer.parseInt(f.getFlowCode())).collect(Collectors.toList()); + if (CollectionUtil.isNotEmpty(endFlow)) { + workTicketInfoMap.put("endLicensor", endFlow.get(0).getCreateUserName()); + workTicketInfoMap.put("endTime", DateUtil.format(endFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); + workTicketInfoMap.put("groundSwitchCount", ObjectUtil.isNotEmpty(endFlow.get(0).getGroundSwitchCount()) ? endFlow.get(0).getGroundSwitchCount() : ""); + workTicketInfoMap.put("groundWireCode", ObjectUtil.isNotEmpty(endFlow.get(0).getGroundWireCode()) ? endFlow.get(0).getGroundWireCode() : ""); + workTicketInfoMap.put("groundWireCount", ObjectUtil.isNotEmpty(endFlow.get(0).getGroundWireCount()) ? endFlow.get(0).getGroundWireCount() : ""); + } else { + workTicketInfoMap.put("endLicensor", ""); + workTicketInfoMap.put("endTime", ""); + workTicketInfoMap.put("groundSwitchCount", ""); + workTicketInfoMap.put("groundWireCode", ""); + workTicketInfoMap.put("groundWireCount", ""); + } + /**负责人变更**/ + List workTicketPrincipalChangeVOList = workTicketInfoVO.getWorkTicketPrincipalChangeVOList(); + if (CollectionUtil.isNotEmpty(workTicketPrincipalChangeVOList)) { + workTicketInfoMap.put("initPrincipal", workTicketPrincipalChangeVOList.get(0).getInitialPrincipalName()); + workTicketInfoMap.put("changePrincipal", workTicketPrincipalChangeVOList.get(0).getChangePrincipalName()); + workTicketInfoMap.put("principalChangeSigner", workTicketPrincipalChangeVOList.get(0).getCreateUserName()); + workTicketInfoMap.put("principalChangeTime", DateUtil.format(workTicketPrincipalChangeVOList.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); + } else { + workTicketInfoMap.put("initPrincipal", ""); + workTicketInfoMap.put("changePrincipal", ""); + workTicketInfoMap.put("principalChangeSigner", ""); + workTicketInfoMap.put("principalChangeTime", ""); + } + /**工作成员变更**/ + List membersChangeList = workTicketInfoVO.getWorkTicketMembersChangeVOList(); + if (CollectionUtil.isNotEmpty(membersChangeList)) { + /**工作成员变更详情**/ + String membersChangeSituation = membersChangeList.stream().map(mc -> DateUtil.format(mc.getCreateTime(), TicketConstants.TICKET_DATE_PATTERN).concat(":").concat(mc.getChangeMembersName())).collect(Collectors.joining(";")); + workTicketInfoMap.put("membersChangeSituation", membersChangeSituation); + workTicketInfoMap.put("memberChangePrincipal", membersChangeList.get(0).getCreateUserName()); + } else { + workTicketInfoMap.put("membersChangeSituation", ""); + workTicketInfoMap.put("memberChangePrincipal", ""); + } + /**工作票延期**/ + List workTicketDelayVOList = workTicketInfoVO.getWorkTicketDelayVOList(); + if (CollectionUtil.isNotEmpty(workTicketDelayVOList)) { + WorkTicketDelayVO workTicketDelayVO = workTicketDelayVOList.get(0); + workTicketInfoMap.put("delayTime", DateUtil.format(workTicketDelayVO.getChangeTime(), TicketConstants.TICKET_DATE_PATTERN)); + workTicketInfoMap.put("delayPrincipal", workTicketDelayVO.getCreateUserName()); + workTicketInfoMap.put("delayPrincipalTime", DateUtil.format(workTicketDelayVO.getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); + workTicketInfoMap.put("delayLicensor", workTicketDelayVO.getLicensorName()); + workTicketInfoMap.put("delayLicenseTime", DateUtil.format(workTicketDelayVO.getLicenseTime(), TicketConstants.TICKET_DATE_PATTERN)); + } else { + workTicketInfoMap.put("delayTime", ""); + workTicketInfoMap.put("delayPrincipal", ""); + workTicketInfoMap.put("delayPrincipalTime", ""); + workTicketInfoMap.put("delayLicensor", ""); + workTicketInfoMap.put("delayLicenseTime", ""); + } + + /**跨日工作时间**/ + List operateList = workTicketInfoVO.getWorkTicketOperateTimeVOList(); + if (CollectionUtil.isNotEmpty(operateList)) { + List> operateMapList = operateList.stream().map(operate -> { + Map map = new HashMap<>(4); + map.put("startTime", DateUtil.format(operate.getStartTime(), TicketConstants.TICKET_DATE_PATTERN)); + map.put("endTime", DateUtil.format(operate.getEndTime(), TicketConstants.TICKET_DATE_PATTERN)); + map.put("principal", operate.getPrincipalName()); + map.put("licensor", operate.getLicensorName()); + return map; + }).collect(Collectors.toList()); + workTicketInfoMap.put("operateMapList", operateMapList); + } else { + List> operateMapList = new ArrayList<>(); + Map map = new HashMap<>(4); + map.put("startTime", ""); + map.put("endTime", ""); + map.put("principal", ""); + map.put("licensor", ""); + operateMapList.add(map); + workTicketInfoMap.put("operateMapList", operateMapList); + } + + /**运行值班人员暂为空**/ + workTicketInfoMap.put("dutyPersonName", "/"); + + String fileName = TicketConstants.WordFileNameEnum.getFileNameByType(workTicketInfoVO.getType()) + PdfUtils.XLSX_SUFFIX; + log.info("工作票模板为:{}", fileName); + TemplateExportParams templateExportParams = new TemplateExportParams("template/" + fileName, true); + Workbook workbook = null; + try { + workbook = ExcelUtil.getWorkbook(templateExportParams, workTicketInfoMap); + } catch (Exception e) { + e.printStackTrace(); + } + //上传xlsx至服务器 + try { + ExcelUtil.upload(workbook, xlsSavePath, workTicketInfoVO.getWorkContent() + PdfUtils.XLSX_SUFFIX); + } catch (Exception e) { + e.printStackTrace(); + } + //将xlsx文件转换为pdf并保存 + String pdfFileName = workTicketInfoVO.getWorkContent() + PdfUtils.PDF_SUFFIX; + String xlsFileName = workTicketInfoVO.getWorkContent() + PdfUtils.XLSX_SUFFIX; + PdfUtils.convertPdf(xlsSavePath, xlsFileName, pdfSavePath, pdfFileName); + String savePath = pdfSavePath + pdfFileName; + // 设置response参数,可以打开下载页面 + PdfUtils.readPdf(response, savePath); + } + + @Override + @Transactional + public R completeTask(WorkTicketInfoDto req, BladeFlow flow) { + ComleteTask task = new ComleteTask(); + task.setTaskId(flow.getTaskId()); + task.setComment(flow.getComment()); + task.setAttachments(flow.getAttachments()); + task.setFlag(flow.getFlag()); + task.setProcessInstanceId(flow.getProcessInstanceId()); + task.setVariables(flow.getVariables()); + + //待许可时获取许可人角色下用户开启工作流 + if (TicketConstants.FirstWorkTicketFlowStatusEnum.LICENSE.getStatus().equals(req.getStatus())) { + R> userListR = userClient.relationUserListByRoleAlias(AuthUtil.getTenantId(), req.getCreateDept(), TicketConstants.LICENSOR_ROLE); + if (!userListR.isSuccess()) { + throw new ServiceException(userListR.getMsg()); + } + Map variables = CollectionUtil.isEmpty(flow.getVariables()) ? new HashMap<>() : flow.getVariables(); + String taskUser = userListR.getData().stream().map(u -> "taskUser_".concat(u.getId().toString())).collect(Collectors.joining(",")); + variables.put("licenseUserIds", taskUser); + task.setVariables(variables); + } + log.info("工作流对象为:{}", JSONObject.toJSONString(flow)); + + if (TicketConstants.FirstWorkTicketFlowStatusEnum.LICENSE.getStatus().equals(req.getStatus())) { + req.setSigner(AuthUtil.getUserId()); + } else if (TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_MEASURE_PRINCIPAL.getStatus().equals(req.getStatus())) { + req.setLicensor(AuthUtil.getUserId()); + } else if (TicketConstants.FirstWorkTicketFlowStatusEnum.INVALID.getStatus().equals(req.getStatus())) { + this.invalidTicket(req); + } + + //更新状态 + boolean flag = this.update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, req.getStatus()).set(WorkTicketInfoEntity::getPrincipal, req.getPrincipal()).set(WorkTicketInfoEntity::getLicensor, req.getLicensor()).set(WorkTicketInfoEntity::getLicenseTime, req.getLicenseTime()).set(WorkTicketInfoEntity::getLicenseEndTime, req.getLicenseEndTime()).eq(WorkTicketInfoEntity::getId, req.getId())); + + //新增流程信息 + WorkTicketFlowEntity workTicketFlowEntity = new WorkTicketFlowEntity(); + workTicketFlowEntity.setTicketId(req.getId()); + workTicketFlowEntity.setFlowCode(req.getStatus().toString()); + workTicketFlowEntity.setExecutor(AuthUtil.getUserId().toString()); + workTicketFlowEntity.setExecuteTime(LocalDateTime.now()); + workTicketFlowEntity.setRemark(Optional.ofNullable(flow.getVariables()).map(v -> v.get("remark")).map(s -> s.toString()).orElse("")); + workTicketFlowEntity.setSignImgPath(Optional.ofNullable(flow.getVariables()).map(v -> v.get("signImgPath")).map(s -> s.toString()).orElse("")); + workTicketFlowEntity.setGroundWireCount(Optional.ofNullable(flow.getVariables()).map(v -> v.get("groundWireCount")).map(s -> Integer.parseInt(s.toString())).orElse(null)); + workTicketFlowEntity.setGroundSwitchCount(Optional.ofNullable(flow.getVariables()).map(v -> v.get("groundSwitchCount")).map(s -> Integer.parseInt(s.toString())).orElse(null)); + workTicketFlowEntity.setStatus(req.getStatus()); + workTicketFlowService.save(workTicketFlowEntity); + //执行流程 + R flowResult = flowClient.completeTask(task); + //更新任务状态 + updateAccessStatus(req); + + if (!flowResult.isSuccess()) { + throw new ServiceException("执行工作流失败!"); + } + + return R.success("操作成功!"); + } + + @Transactional(rollbackFor = Exception.class) + public void updateAccessStatus(WorkTicketInfoDto req) { + if (TicketConstants.TaskTypeEnum.JXRW.getType().equals(req.getTaskType()) || TicketConstants.TaskTypeEnum.JXJH.getType().equals(req.getTaskType())) { + log.info("许可通过:{}", JSONObject.toJSONString(req)); + //许可人通过将检修任务状态设为执行中 + if (TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_MEASURE_PRINCIPAL.getStatus().equals(req.getStatus())) { + OperAccessTaskEntity taskEntity = new OperAccessTaskEntity(); + taskEntity.setId(req.getTaskId()); + taskEntity.setStatus(AccessConstants.ACCESS_TASK_STATUS_1); + //设置开始时间 + taskEntity.setActStartTime(DateUtil.now()); + operAccessTaskClient.updateById(taskEntity); + } + } + } + + /*** + * 票据作废时 对应任务ID应该置空 + * @param req + */ + public void invalidTicket(WorkTicketInfoDto req) { + if (TicketConstants.TaskTypeEnum.JXRW.getType().equals(req.getTaskType()) || TicketConstants.TaskTypeEnum.JXJH.getType().equals(req.getTaskType())) { + OperAccessTaskEntity taskEntity = new OperAccessTaskEntity(); + taskEntity.setId(req.getTaskId()); + taskEntity.setInvalid(true); + taskEntity.setTicketId(null); + operAccessTaskClient.updateById(taskEntity); + } + if (TicketConstants.TaskTypeEnum.RCWH.getType().equals(req.getTaskType())) { + OperMaintenanceTaskDTO dto = new OperMaintenanceTaskDTO(); + dto.setId(req.getTaskId()); + dto.setInvalid(true); + //dto.setTicketId(null); + taskClient.doUpdateTaskById(dto); + } + } + + /*** + * 回传票据ID + * @param req + */ + @Transactional(rollbackFor = Exception.class) + public void returnTicket(WorkTicketInfoDto req) { + if (TicketConstants.TaskTypeEnum.JXRW.getType().equals(req.getTaskType())) { + OperAccessTaskEntity taskEntity = new OperAccessTaskEntity(); + taskEntity.setId(req.getTaskId()); + taskEntity.setTicketId(req.getId()); + operAccessTaskClient.updateById(taskEntity); + } + if (TicketConstants.TaskTypeEnum.RCWH.getType().equals(req.getTaskType())) { + OperMaintenanceTaskDTO dto = new OperMaintenanceTaskDTO(); + dto.setId(req.getTaskId()); + dto.setTicketId(req.getId()); + taskClient.doUpdateTaskById(dto); + } + } + + /** + * 获取queryWrapper + * + * @param req + * @return + */ + private LambdaQueryWrapper getQueryWrapper(WorkTicketInfoDto req) { + LambdaQueryWrapper lqw = new LambdaQueryWrapper(); + if (Func.isNotBlank(req.getProcessInstanceId())) { + lqw.eq(WorkTicketInfoEntity::getProcessInstanceId, req.getProcessInstanceId()); + } + if (Func.isNotEmpty(req.getType())) { + lqw.eq(WorkTicketInfoEntity::getType, req.getType()); + } + if (Func.isNotEmpty(req.getTaskType())) { + lqw.eq(WorkTicketInfoEntity::getTaskType, req.getTaskType()); + } + if (Func.isNotEmpty(req.getCode())) { + lqw.like(WorkTicketInfoEntity::getCode, req.getCode()); + } + if (Func.isNotEmpty(req.getStatus())) { + lqw.eq(WorkTicketInfoEntity::getStatus, req.getStatus()); + } + if (Func.isNotEmpty(req.getCompany())) { + lqw.like(WorkTicketInfoEntity::getType, "%".concat(req.getCompany()).concat("%")); + } + if (Func.isNotEmpty(req.getClassGroup())) { + lqw.eq(WorkTicketInfoEntity::getClassGroup, req.getClassGroup()); + } + if (Func.isNotEmpty(req.getTaskId())) { + lqw.eq(WorkTicketInfoEntity::getTaskId, req.getTaskId()); + } + if (Func.isNotEmpty(req.getClassGroup())) { + lqw.eq(WorkTicketInfoEntity::getClassGroup, req.getClassGroup()); + } + if (Func.isNotEmpty(req.getClassGroupMembers())) { + lqw.like(WorkTicketInfoEntity::getClassGroupMembers, "%".concat(req.getClassGroupMembers()).concat("%")); + } + if (Func.isNotEmpty(req.getWorkContent())) { + lqw.like(WorkTicketInfoEntity::getWorkContent, "%".concat(req.getWorkContent()).concat("%")); + } + if (Func.isNotEmpty(req.getSigner())) { + lqw.eq(WorkTicketInfoEntity::getSigner, req.getSigner()); + } + if (Func.isNotEmpty(req.getLicensor())) { + lqw.eq(WorkTicketInfoEntity::getLicensor, req.getLicensor()); + } + if (Func.isNotEmpty(req.getStartTime())) { + lqw.ge(WorkTicketInfoEntity::getCreateTime, req.getStartTime()); + } + if (Func.isNotEmpty(req.getEndTime())) { + lqw.le(WorkTicketInfoEntity::getCreateTime, req.getEndTime()); + } + if (!CollectionUtil.isEmpty(req.getDeptIds())) { + lqw.in(WorkTicketInfoEntity::getCreateDept, req.getDeptIds()); + } + return lqw; + } + + /** + * 开启一个流程实例 + * + * @author hx + **/ + @Override + public BladeFlow startProcessInstance(String processDefinitionKey, WorkTicketInfoEntity workTicketInfoEntity) { + /**获取签发人角色下的人员**/ + R> listR = userClient.relationUserListByRoleAlias(tenantId, Long.parseLong(AuthUtil.getUser().getDeptId()), TicketConstants.SIGNER_ROLE); + if (!listR.isSuccess() || CollectionUtil.isEmpty(listR.getData())) { + throw new ServiceException("工作票签发人角色下未查询到相关人员"); + } + String signUserIds = listR.getData().stream().map(user -> "taskUser_".concat(user.getId().toString())).collect(Collectors.joining(",")); + + Map params = new HashMap(2) {{ + put("taskId", workTicketInfoEntity.getId()); + put("signUserIds", signUserIds); + }}; + + R r = flowClient.startProcessInstanceContainNameByKey(processDefinitionKey, "workTicket:task:" + workTicketInfoEntity.getId(), workTicketInfoEntity.getWorkContent(), params); + if (!r.isSuccess()) { + throw new ServiceException(r.getMsg()); + } + return r.getData(); + } + + /** + * 许可人通过线下工作票 + * + * @param req + * @return + */ + @Override + public R licenseOfflineTicket(WorkTicketInfoDto req) { + Long ticketId = req.getId(); + WorkTicketInfoEntity infoEntity = getById(ticketId); + //获取许可人角色下的人员 + R> listR = userClient.relationUserListByRoleAlias(tenantId, infoEntity.getCreateDept(), TicketConstants.LICENSOR_ROLE); + if (!listR.isSuccess() || CollectionUtil.isEmpty(listR.getData())) { + throw new ServiceException("工作票许可人角色下未查询到相关人员"); + } + List userId = listR.getData().stream().map(User::getId).distinct().collect(Collectors.toList()); + if (!userId.contains(AuthUtil.getUserId())) { + throw new ServiceException("当前操作人没有许可人角色,无法执行该操作"); + } + update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE_LICENSE.getStatus()).set(WorkTicketInfoEntity::getLicensor, AuthUtil.getUserId()).set(WorkTicketInfoEntity::getLicenseTime, LocalDateTime.now()).set(WorkTicketInfoEntity::getLicenseEndTime, req.getLicenseEndTime()).eq(WorkTicketInfoEntity::getId, ticketId)); + return R.success("操作成功"); + } + + /** + * 完成线下工作票 + * + * @param ticketAccessTaskDto + * @return + */ + @Override + public R finishOfflineTicket(TicketAccessTaskDto ticketAccessTaskDto) { + //更新工作票 + WorkTicketInfoDto infoDto = ticketAccessTaskDto.getWorkTicketInfoDto(); + update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE_END.getStatus()).eq(WorkTicketInfoEntity::getId, infoDto.getId())); + //获取工作票实体类 + WorkTicketInfoEntity infoEntity = getById(infoDto.getId()); + //根据任务类型执行任务 + if (ObjectUtil.isEmpty(infoEntity.getTaskType())) { + return R.success("操作成功"); + } + //FIXME 日常维护、检修任务暂时不形成闭环(因许可人无需填入任务结束完成所需参数,故选择由执行人手动闭环) ~2022--05-06 +// if(TicketConstants.TaskTypeEnum.JXRW.getType().equals(infoEntity.getTaskType()) +// || TicketConstants.TaskTypeEnum.JXJH.getType().equals(infoEntity.getTaskType())) { +// //执行检修任务 +// OperAccessTaskDTO accessTaskDTO = ticketAccessTaskDto.getAccessTaskDTO(); +// accessTaskDTO.setId(infoEntity.getTaskId()); +// if(ObjectUtil.isNotEmpty(accessTaskDTO) && ObjectUtil.isNotEmpty(accessTaskDTO.getId())){ +// log.info("线下检修任务执行调用传参为:{}",JSONObject.toJSONString(accessTaskDTO)); +// //operAccessTaskClient.finishAccessTask(accessTaskDTO); +// } +// } +// else if(TicketConstants.TaskTypeEnum.RCWH.getType().equals(infoEntity.getTaskType())) { +// //执行日常维护任务 +// OperMaintenanceTaskDTO operMaintenanceTaskDTO = new OperMaintenanceTaskDTO(); +// operMaintenanceTaskDTO.setId(infoEntity.getTaskId()); +// operMaintenanceTaskDTO.setStatus(MaintenanceConstant.TASK_STATUS_3); +// if(ObjectUtil.isNotEmpty(operMaintenanceTaskDTO) && ObjectUtil.isNotEmpty(operMaintenanceTaskDTO.getId()) ){ +// ComleteTask comleteTask = new ComleteTask(); +// comleteTask.setProcessInstanceId(operMaintenanceTaskDTO.getProcessInstanceId()); +// comleteTask.setFlag("ok"); +// comleteTask.setPass(true); +// comleteTask.setComment("执行完成"); +// TaskFlowDTO taskFlowDTO = TaskFlowDTO.builder().taskDTO(operMaintenanceTaskDTO).comleteTask(comleteTask).build(); +// log.info("线下日常维护任务执行调用传参为:{}",JSONObject.toJSONString(taskFlowDTO)); +// //R result = taskClient.updateTaskStatus(taskFlowDTO); +// } +// } + return R.success("操作成功"); + } + + /*** + * 获取工作票编号 + * @return + */ + @Override + public String getWorkTicketCode() { + String code = ""; + lock.lock(); + try { + /**获取当前时间**/ + DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyMM"); + YearMonth yearMonth = YearMonth.now(); + String tym = yearMonth.format(formatter); + LocalDateTime date = LocalDateTime.now(); + LocalDateTime firstDay = date.with(TemporalAdjusters.firstDayOfMonth()).withHour(0).withMinute(0).withSecond(0); + LocalDateTime lastDay = date.with(TemporalAdjusters.lastDayOfMonth()).withHour(23).withMinute(59).withSecond(59); + log.info("当月第一天:{};当月最后一天{}", firstDay, lastDay); + /**获取当月工作票总条数**/ + List infoEntityList = this.list(new LambdaQueryWrapper() {{ + ge(WorkTicketInfoEntity::getCreateTime, firstDay); + le(WorkTicketInfoEntity::getCreateTime, lastDay); + }}); + if (CollectionUtil.isEmpty(infoEntityList)) { + code = TicketConstants.TicketCodePreEnum.DQ_WORK.getPrefix().concat("-").concat(tym).concat("-001"); + } else { + code = TicketConstants.TicketCodePreEnum.DQ_WORK.getPrefix().concat("-").concat(tym).concat("-").concat(String.format("%03d", infoEntityList.size() + 1)); + } + } catch (Exception e) { + e.printStackTrace(); + } finally { + lock.unlock(); + } + return code; + } + + /** + * 获取安全检查工作票项统计 + * + * @param startDate 开始时间 + * @param endDate 结束时间 + * @param dept 机构ID + * @return WorkTicketStatisticVO统计对象 + */ + @Override + public SafeCheckStatisticVO getWorkTicketStatistic(String startDate, String endDate, Long dept) { + return this.baseMapper.getWorkTicketStatistic(startDate, endDate, dept); + } + + /** + * 验证角色是否能查询到相关人员 + * + * @param deptId 机构ID + * @param roleAliasArray 角色 按逗号分隔 + * @return + */ + @Override + public R> verificationRole(Long deptId, String roleAliasArray) { + Map result = new HashedMap(2); + List failRoleAliasList = Lists.newArrayList(); + AtomicBoolean flag = new AtomicBoolean(true); + Arrays.stream(roleAliasArray.split(",")).forEach(roleAlias -> { + //查询机构下角色是否有对应人员列表 + R> listR = userClient.relationUserListByRoleAlias(tenantId, deptId, roleAlias); + if (!listR.isSuccess() || ObjectUtil.isEmpty(listR.getData())) { + failRoleAliasList.add(roleAlias); + flag.set(false); + } + }); + result.put("flag", flag.get()); + if (CollectionUtil.isNotEmpty(failRoleAliasList)) { + result.put("message", "验证失败,获取" + JSON.toJSONString(failRoleAliasList) + "角色下的人员失败"); + } + + return R.data(result); + } + + /** + * 根据月份和区域查询工作票列表详情 + * + * @param pageEntity + * @param areaVo + * @return + */ + @Override + public BladePage workTicketListByMonthAndArea(Page pageEntity, StandardTicketWithAreaVo areaVo) { + //1.查询 + QueryWrapper queryWrapper = new QueryWrapper<>(); + + //开票来源 + queryWrapper.eq(Func.isNotEmpty(areaVo.getTaskType()), "sti.task_type", areaVo.getTaskType()); + //编号 + queryWrapper.like(Func.isNotEmpty(areaVo.getCode()), "sti.code", areaVo.getCode()); + + //状态 + queryWrapper.eq(Func.isNotEmpty(areaVo.getStatus()), "sti.status", areaVo.getStatus()); + + //开始时间 + queryWrapper.lt(Func.isNotEmpty(areaVo.getStartTime()), "sti.create_time", areaVo.getStartTime()); + + //结束时间 + queryWrapper.le(Func.isNotEmpty(areaVo.getEndTime()), "sti.create_time", areaVo.getEndTime()); + + + queryWrapper.eq("sti.create_dept", areaVo.getAreaId()); + queryWrapper.eq(areaVo.getYearMonth() != null, "date_format(sti.create_time,'%Y-%m')", areaVo.getYearMonth()); + //如果为1为合格 + // queryWrapper.eq("tie.status",1); + Page workTicketInfoEntityPage = baseMapper.selectPages(pageEntity, queryWrapper); + //数据转换 + List standardWorkList = new ArrayList<>(); + if (CollectionUtil.isNotEmpty(workTicketInfoEntityPage.getRecords())) { + standardWorkList = workTicketInfoEntityPage.getRecords().stream().map(workTicketInfoEntity -> { + StandardWorkVo standardWorkVo = new StandardWorkVo(); + BeanUtils.copyProperties(workTicketInfoEntity, standardWorkVo); + return standardWorkVo; + }).collect(Collectors.toList()); + } + + IPage page = new Page<>(); + page.setRecords(standardWorkList); + page.setTotal(workTicketInfoEntityPage.getTotal()); + page.setCurrent(workTicketInfoEntityPage.getCurrent()); + page.setSize(workTicketInfoEntityPage.getSize()); + BladePage bladePage = BladePage.of(page); + return bladePage; + } + + + /** + * 判断是否存在合格率 如果存在返回true 否则为false + * + * @param item + * @return + */ + private boolean isTicketPercentById(WorkTicketInfoEntity item) { + LambdaQueryWrapper ticketInfoEvaluateEntityLambdaQueryWrapper = new LambdaQueryWrapper<>(); + ticketInfoEvaluateEntityLambdaQueryWrapper.eq(TicketInfoEvaluateEntity::getTicketId, item.getId()); + ticketInfoEvaluateEntityLambdaQueryWrapper.eq(TicketInfoEvaluateEntity::getStatus, TicketConstants.TicketQualifiedEnum.Qualified.getCode()); + // 查询合格评价 + int count = ticketInfoEvaluateService.count(ticketInfoEvaluateEntityLambdaQueryWrapper); + return count > 0; + } + + + /** + * 更新状态值 + * + * @param status + * @param description + * @param id + */ + @Override + public void updateFlowStatusById(Integer status, String description, Long id) { + LambdaUpdateWrapper queryWrapper = new LambdaUpdateWrapper<>(); + queryWrapper.set(WorkTicketInfoEntity::getFlowStatus, status); + queryWrapper.set(WorkTicketInfoEntity::getFlowDescription, description); + queryWrapper.eq(WorkTicketInfoEntity::getId, id); + } + + /** + * 获取工作详情 + * + * @param ticketId + * @return + */ + @Override + public WorkTicketVo selectDetailsById(Long ticketId) { + WorkTicketVo workTicketVo = new WorkTicketVo(); + + //1. 获取工作票详情数据 + WorkTicketInfoEntity workTicketInfo = this.getById(ticketId); + if (ObjectUtils.isEmpty(workTicketInfo)) { + throw new ServiceException("未查询到ticketId对应的信息"); + } + + //赋值签发人 + if (workTicketInfo.getSigner() != null) { + User user = UserCache.getUser(workTicketInfo.getSigner()); + workTicketInfo.setSignerName(user == null ? null : user.getName()); + } + + if (workTicketInfo.getSigner() != null && workTicketInfo.getSignerName() == null) { + User user = UserCache.getUser(workTicketInfo.getSigner()); + workTicketInfo.setSignerName(user == null ? null : user.getName()); + } + + //赋值许可人名称 + if (workTicketInfo.getLicensor() != null) { + User user = UserCache.getUser(workTicketInfo.getLicensor()); + workTicketInfo.setLicensorName(user == null ? null : user.getName()); + } + + if (workTicketInfo.getLicensor() != null && workTicketInfo.getLicensorName() == null) { + User user = UserCache.getUser(workTicketInfo.getLicensor()); + workTicketInfo.setLicensorName(user == null ? null : user.getName()); + } + + // 负责值班负责人 + if (workTicketInfo.getWatchPrincipal() != null) { + User user = UserCache.getUser(workTicketInfo.getWatchPrincipal()); + workTicketInfo.setWatchPrincipalName(user == null ? null : user.getName()); + } + + if (workTicketInfo.getWatchPrincipal() != null && workTicketInfo.getWatchPrincipalName() == null) { + User user = UserCache.getUser(workTicketInfo.getWatchPrincipal()); + workTicketInfo.setWatchPrincipalName(user == null ? null : user.getName()); + } + + + StringBuilder sb = new StringBuilder(); + String classGroupMembers = workTicketInfo.getClassGroupMembers(); + if (StringUtils.isNoneBlank(classGroupMembers)) { + // System.out.println("获取classGroupMembers ==> " + classGroupMembers); + String[] split = classGroupMembers.split(","); + for (String classGroupMember : split) { + System.out.println(classGroupMember); + if (StringUtils.isNoneBlank(classGroupMember)) { + boolean matches = classGroupMember.matches("[0-9]+"); + if (matches) { + User user = UserCache.getUser(Long.valueOf(classGroupMember)); + String name = user == null ? null : user.getName(); + if (StringUtils.isNotBlank(name)) { + sb.append(name).append(","); + } + } + } + } + + //统计人数 + if (workTicketInfo.getTotalPerson() == null) { + workTicketInfo.setTotalPerson(sb.toString().trim().split(",").length); + } + + //成员信息 + if (workTicketInfo.getClassGroupMembersName() == null) { + workTicketInfo.setClassGroupMembersName(sb.toString().endsWith(",") ? + sb.toString().substring(0, sb.length() - 1) : sb.toString()); + } + } + + + //负责人名称 + if (workTicketInfo.getPrincipalName() == null && workTicketInfo.getPrincipal() != null) { + User user = UserCache.getUser(workTicketInfo.getPrincipal()); + workTicketInfo.setPrincipalName(user == null ? "" : user.getName()); + } + + + workTicketVo.setWorkTicket(workTicketInfo); + + //2. 安全措施数组 + List workTicketSafetyMeasureEntity = workTicketSafetyMeasureService.selectByTicketId(ticketId); + if (CollectionUtils.isNotEmpty(workTicketSafetyMeasureEntity)) { + workTicketVo.setSafetyMeasuresList(workTicketSafetyMeasureEntity); + } + + //3. 工作票工作任务组 + List workTicketContentEntities = workTicketContentService.selectByTicketId(ticketId); + if (CollectionUtils.isNotEmpty(workTicketContentEntities)) { + workTicketVo.setWorkTicketContentDtoList(workTicketContentEntities); + } + + //4. 工作票延期 + WorkTicketDelayEntity workTicketDelayEntity = delayService.selectByTicketId(ticketId); + if (ObjectUtils.isNotEmpty(workTicketDelayEntity)) { + workTicketVo.setWorkTicketDelay(workTicketDelayEntity); + } + + + //5.工作结束 + WorkTicketFinish workTicketFinish = workTicketFinishService.selectByTicketId(ticketId); + if (ObjectUtils.isNotEmpty(workTicketFinish)) { + workTicketVo.setWorkTicketFinish(workTicketFinish); + } + + + //6.工作开始时间和结束时间 + List workTicketOperateTimeEntities = + workTicketOperateTimeService.selectByTicketId(ticketId); + if (CollectionUtils.isNotEmpty(workTicketOperateTimeEntities)) { + workTicketVo.setWorkTicketOperateTimeEntities(workTicketOperateTimeEntities); + } + + + //7. 工作票负责人变更 + WorkTicketPrincipalChangeEntity workTicketPrincipalChangeEntity = + workTicketPrincipalChangeService.selectByTicketId(ticketId); + if (ObjectUtils.isNotEmpty(workTicketPrincipalChangeEntity)) { + //原负责人 + if (workTicketPrincipalChangeEntity.getInitialPrincipal() != null) { + workTicketPrincipalChangeEntity.setInitialPrincipalName( + UserCache.getUser(workTicketPrincipalChangeEntity.getInitialPrincipal()).getName() + ); + } + //变更负责人 + if (workTicketPrincipalChangeEntity.getChangePrincipal() != null) { + workTicketPrincipalChangeEntity.setChangePrincipalName( + UserCache.getUser(workTicketPrincipalChangeEntity.getChangePrincipal()).getName() + ); + } + + workTicketVo.setWorkTicketPrincipalChange(workTicketPrincipalChangeEntity); + } + + + //7. 根据工作票Id查询工作票危险点分析及控制措施票 + List list = ticketInfoDangerService.selectAllByTicket(workTicketInfo.getId()); + if (CollectionUtils.isNotEmpty(list)) { + workTicketVo.setTicketInfoDangers(list); + } + return workTicketVo; + } +} diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/equipment/PlanMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/equipment/PlanMapper.xml new file mode 100644 index 0000000..4cb6c9b --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/equipment/PlanMapper.xml @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/AccessMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/AccessMapper.xml new file mode 100644 index 0000000..41e93fb --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/AccessMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/DefectMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/DefectMapper.xml new file mode 100644 index 0000000..5e93d41 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/DefectMapper.xml @@ -0,0 +1,4 @@ + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/MaintenanceMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/MaintenanceMapper.xml new file mode 100644 index 0000000..2cfd506 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/MaintenanceMapper.xml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OtherMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OtherMapper.xml new file mode 100644 index 0000000..af9c98d --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OtherMapper.xml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + ID, START_DATE, END_DATE , FA_QUANTITY , ONLINE_RATE ,TENANT_ID, STATUS, CREATE_TIME, + UPDATE_TIME, CREATE_USER, UPDATE_USER, IS_DELETED, CREATE_DEPT + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OverDetailsMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OverDetailsMapper.xml new file mode 100644 index 0000000..4f13622 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OverDetailsMapper.xml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + ID, OVER_ID , OVER_CONFIG_ID , PRICE , QUANTITY , TOTAL_PRICE, TENANT_ID, STATUS, CREATE_TIME, UPDATE_TIME, + CREATE_USER, UPDATE_USER, IS_DELETED, CREATE_DEPT + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OverMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OverMapper.xml new file mode 100644 index 0000000..c8d9cf8 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/OverMapper.xml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + ID, START_DATE , END_DATE , TOTAL_PRICE , ENCL_PATH , ENCL_NAME ,TENANT_ID, STATUS, + CREATE_TIME, UPDATE_TIME, CREATE_USER, UPDATE_USER, IS_DELETED, CREATE_DEPT + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/SolveMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/SolveMapper.xml new file mode 100644 index 0000000..3e900d4 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/SolveMapper.xml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + ID, SOLVE_DATE , SOLVE_QUANTITY , SOLVE_SUC_QUANTITY ,TENANT_ID, STATUS, CREATE_TIME, + UPDATE_TIME, CREATE_USER, UPDATE_USER, IS_DELETED, CREATE_DEPT + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/TicketEvaluateMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/TicketEvaluateMapper.xml new file mode 100644 index 0000000..d378bac --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/TicketEvaluateMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/TicketMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/TicketMapper.xml new file mode 100644 index 0000000..24b9def --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/TicketMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/WorkTicketMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/WorkTicketMapper.xml new file mode 100644 index 0000000..3eb5e81 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/ticket/WorkTicketMapper.xml @@ -0,0 +1,4 @@ + + + + diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/defect/service/IOperDefectService.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/defect/service/IOperDefectService.java index f1e652b..30ab90c 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/defect/service/IOperDefectService.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/defect/service/IOperDefectService.java @@ -1,101 +1,13 @@ package com.hnac.hzims.operational.defect.service; -import com.baomidou.mybatisplus.core.metadata.IPage; -import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.hnac.hzims.operational.defect.entity.OperDefectEntity; -import com.hnac.hzims.operational.defect.entity.OperPhenomenonEntity; -import com.hnac.hzims.operational.defect.vo.OperDefectVO; -import com.hnac.hzims.operational.report.vo.DefectReportsVO; -import com.hnac.hzims.vo.SafeCheckStatisticVO; import org.springblade.core.mp.base.BaseService; -import org.springblade.core.tool.api.R; -import org.springblade.flow.core.entity.BladeFlow; -import javax.servlet.http.HttpServletResponse; -import java.io.IOException; -import java.time.LocalDate; -import java.util.List; -import java.util.Map; /** - * 服务类 - * - * @author Chill + * @author ysj */ public interface IOperDefectService extends BaseService { - /** - * 开始问题处理流程 - * 问题处理流程的第一个处理节点人key 必须是 problemUser - * @param - */ - void startFlow(OperPhenomenonEntity entity, OperDefectEntity defectEntity); - /** - * 处理问题 - * @param flow - * @return - */ - boolean handleProcess(BladeFlow flow); - - /** - * 获取缺陷的统计月报 - * @param month 格式:"2021-01" - */ - Map getDefectStatistics(String month); - - /** - * 导出缺陷统计月报报表 - * @param response - * @param month 格式 "2021-01" - * @throws IOException - */ - void exportFualtMonthExcel(HttpServletResponse response, String month) throws IOException; - - - List getDefectList(String emCode,List list); - - List getDefectByEmCodeList(String emCode); - - /** - * 站点月报统计 - 消缺 - * @param startDate - * @param endDate - * @param deptIdList - * @return - */ - List getFaultByFaultCode(LocalDate startDate,LocalDate endDate,List deptIdList); - - List getFaultByFaultCode(Map params); - - List> getDefectConclusion(Map params); - - /** - * 缺陷详情 - * @param defect - * @return - */ - R detail(OperDefectEntity defect); - - /** - * 获取安全检查消缺项统计 - * @param startDate 开始时间 - * @param endDate 结束时间 - * @param dept 机构ID - * @param defectType 缺陷类型;1: 重大缺陷 2:一般缺陷 - * @return SafeCheckStatisticVO 对象 - */ - SafeCheckStatisticVO getDefectCheck(String startDate,String endDate,Long dept,String defectType); - - boolean updateDefectInfo(OperDefectEntity entity); - - boolean updateDefectHanderState(OperDefectEntity entity); - - /** - * 分页查询 - * @param operDefectEntityPage - * @param defect - * @return - */ - IPage selectPage(Page operDefectEntityPage, OperDefectEntity defect); } diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/fill/mapper/OtherMapper.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/fill/mapper/OtherMapper.java deleted file mode 100644 index 5d0b450..0000000 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/fill/mapper/OtherMapper.java +++ /dev/null @@ -1,8 +0,0 @@ -package com.hnac.hzims.operational.fill.mapper; - -import com.hnac.hzims.operational.fill.entity.OtherEntity; -import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; - -public interface OtherMapper extends UserDataScopeBaseMapper { - -} diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/fill/mapper/OtherMapper.xml b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/fill/mapper/OtherMapper.xml deleted file mode 100644 index 44e22e4..0000000 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/fill/mapper/OtherMapper.xml +++ /dev/null @@ -1,25 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - ID, START_DATE, END_DATE , FA_QUANTITY , ONLINE_RATE ,TENANT_ID, STATUS, CREATE_TIME, - UPDATE_TIME, CREATE_USER, UPDATE_USER, IS_DELETED, CREATE_DEPT - - - From 9d5840091834ab10868bc43bad55a4a8434227e7 Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Wed, 7 Jun 2023 11:01:08 +0800 Subject: [PATCH 11/14] =?UTF-8?q?#=E5=AE=9A=E6=97=B6=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E6=8A=BD=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/ticket/WorkTicketService.java | 3 + .../service/ticket/impl/TicketServiceImpl.java | 1 + .../service/ticket/impl/WorkTicketServiceImpl.java | 1086 +------------------- 3 files changed, 10 insertions(+), 1080 deletions(-) diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/WorkTicketService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/WorkTicketService.java index 536b410..0117669 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/WorkTicketService.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/WorkTicketService.java @@ -3,5 +3,8 @@ package com.hnac.hzims.scheduled.service.ticket; import com.hnac.hzims.ticket.workTicket.entity.WorkTicketInfoEntity; import org.springblade.core.mp.base.BaseService; +/** + * @author ysj + */ public interface WorkTicketService extends BaseService { } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java index 204a17b..1ef4c4d 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java @@ -31,6 +31,7 @@ import java.util.stream.Collectors; public class TicketServiceImpl extends BaseServiceImpl implements TicketService { private final WorkTicketService workTicketService; + private final TicketEvaluateService ticketEvaluateService; /** diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java index 13dbc45..8c13e28 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java @@ -1,1093 +1,19 @@ package com.hnac.hzims.scheduled.service.ticket.impl; -import cn.afterturn.easypoi.excel.entity.TemplateExportParams; -import com.alibaba.fastjson.JSON; -import com.alibaba.fastjson.JSONObject; -import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; -import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; -import com.baomidou.mybatisplus.core.metadata.IPage; -import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; -import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; -import com.baomidou.mybatisplus.core.toolkit.Wrappers; -import com.baomidou.mybatisplus.extension.plugins.pagination.Page; -import com.google.common.collect.Lists; -import com.hnac.hzims.common.logs.utils.StringUtils; -import com.hnac.hzims.operational.access.constants.AccessConstants; -import com.hnac.hzims.operational.access.entity.OperAccessTaskEntity; -import com.hnac.hzims.operational.access.feign.IOperAccessTaskClient; -import com.hnac.hzims.operational.maintenance.dto.OperMaintenanceTaskDTO; -import com.hnac.hzims.operational.maintenance.feign.ITaskClient; -import com.hnac.hzims.ticket.allTicket.entity.TicketInfoEvaluateEntity; -import com.hnac.hzims.ticket.allTicket.service.TicketInfoEvaluateService; -import com.hnac.hzims.ticket.areamonthly.vo.StandardTicketWithAreaVo; -import com.hnac.hzims.ticket.areamonthly.vo.StandardWorkVo; -import com.hnac.hzims.ticket.aspect.AroundFlow; -import com.hnac.hzims.ticket.constants.TicketConstants; -import com.hnac.hzims.ticket.twoTicket.entity.TicketInfoDanger; -import com.hnac.hzims.ticket.twoTicket.entity.WorkTicketFinish; -import com.hnac.hzims.ticket.twoTicket.service.TicketInfoDangerService; -import com.hnac.hzims.ticket.twoTicket.service.impl.WorkTicketFinishServiceImpl; -import com.hnac.hzims.ticket.twoTicket.vo.process.WorkTicketVo; -import com.hnac.hzims.ticket.utils.ExcelUtil; -import com.hnac.hzims.ticket.utils.PdfUtils; -import com.hnac.hzims.ticket.workTicket.entity.*; -import com.hnac.hzims.ticket.workTicket.mapper.WorkDelayNoScopeMapper; -import com.hnac.hzims.ticket.workTicket.mapper.WorkTicketInfoMapper; -import com.hnac.hzims.ticket.workTicket.wrapper.WorkTicketDelayWrapper; -import com.hnac.hzims.ticket.workTicket.wrapper.WorkTicketInfoWrapper; -import com.hnac.hzims.vo.SafeCheckStatisticVO; +import com.hnac.hzims.scheduled.mapper.ticket.WorkTicketMapper; +import com.hnac.hzims.scheduled.service.ticket.WorkTicketService; +import com.hnac.hzims.ticket.workTicket.entity.WorkTicketInfoEntity; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import org.apache.commons.collections.map.HashedMap; -import org.apache.poi.ss.usermodel.Workbook; -import org.springblade.core.log.exception.ServiceException; import org.springblade.core.mp.base.BaseServiceImpl; -import org.springblade.core.mp.support.BladePage; -import org.springblade.core.mp.support.Condition; -import org.springblade.core.mp.support.Query; -import org.springblade.core.secure.utils.AuthUtil; -import org.springblade.core.tool.api.R; -import org.springblade.core.tool.utils.CollectionUtil; -import org.springblade.core.tool.utils.DateUtil; -import org.springblade.core.tool.utils.Func; -import org.springblade.core.tool.utils.ObjectUtil; -import org.springblade.flow.core.entity.BladeFlow; -import org.springblade.flow.core.feign.IFlowClient; -import org.springblade.flow.core.vo.ComleteTask; -import org.springblade.system.user.cache.UserCache; -import org.springblade.system.user.entity.User; -import org.springblade.system.user.feign.IUserClient; -import org.springframework.beans.BeanUtils; -import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Propagation; -import org.springframework.transaction.annotation.Transactional; -import org.springframework.util.Assert; - -import javax.servlet.http.HttpServletResponse; -import java.time.LocalDateTime; -import java.time.YearMonth; -import java.time.format.DateTimeFormatter; -import java.time.temporal.TemporalAdjusters; -import java.util.*; -import java.util.concurrent.atomic.AtomicBoolean; -import java.util.concurrent.locks.Lock; -import java.util.concurrent.locks.ReentrantLock; -import java.util.stream.Collectors; /** - *

- * 工作票 服务实现类 - *

- * - * @author hx - * @since 2021-10-22 + * @author ysj */ @Service @Slf4j @RequiredArgsConstructor -public class WorkTicketServiceImpl extends BaseServiceImpl implements IWorkTicketInfoService { - - private final IWorkTicketSafetyMeasureService workTicketSafetyMeasureService; - private final IWorkTicketPrincipalChangeService workTicketPrincipalChangeService; - private final IWorkTicketDelayService delayService; - private final IWorkTicketMembersChangeService workTicketMembersChangeService; - private final IWorkTicketOperateTimeService workTicketOperateTimeService; - private final IWorkTicketFlowService workTicketFlowService; - private final IFlowClient flowClient; - private final IUserClient userClient; - private final WorkDelayNoScopeMapper workDelayNoScopeMapper; - private final IOperAccessTaskClient operAccessTaskClient; - private final ITaskClient taskClient; - private final TicketInfoEvaluateService ticketInfoEvaluateService; - private final IWorkTicketContentService workTicketContentService; - private final WorkTicketFinishServiceImpl workTicketFinishService; - private final TicketInfoDangerService ticketInfoDangerService; - - /** 生成两票编号锁 **/ - private Lock lock = new ReentrantLock(); - - /** word模板预览导出保存路径 **/ - @Value("${hzims.ticket.path.xlsx.savePath}") - private String xlsSavePath; - - @Value("${hzims.ticket.first-work-flow-key}") - private String firstWorkTicketFlowKey; - - @Value("${hzims.tenantId}") - private String tenantId; - - @Value("${hzims.ticket.path.pdf.savePath}") - private String pdfSavePath; - - @Override - @Transactional - @AroundFlow - public R doSave(WorkTicketInfoDto req) { - req.setCode(this.getWorkTicketCode()); - req.setStatus(Func.isEmpty(req.getPrincipal()) || Func.isEmpty(req.getClassGroupMembers()) ? TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE.getStatus() : TicketConstants.FirstWorkTicketFlowStatusEnum.SIGN.getStatus()); - boolean flag = this.save(req); - /**保存安全措施**/ - if (flag && CollectionUtil.isNotEmpty(req.getWorkTicketSafetyMeasureDtoList())) { - req.getWorkTicketSafetyMeasureDtoList().forEach(workTicketSafetyMeasureDto -> { - workTicketSafetyMeasureDto.setTicketId(req.getId()); - workTicketSafetyMeasureService.save(workTicketSafetyMeasureDto); - }); - } - if (Func.isEmpty(req.getPrincipal()) || Func.isEmpty(req.getClassGroupMembers())) { - //将票据ID会传至计划/任务内 - returnTicket(req); - return R.success("开票成功!该票走线下未开启流程"); - } - /**开启工作流**/ - BladeFlow bladeFlow = this.startProcessInstance(firstWorkTicketFlowKey, req); - this.update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getProcessInstanceId, bladeFlow.getProcessInstanceId()).eq(WorkTicketInfoEntity::getId, req.getId())); - //将票据ID会传至计划/任务内 - returnTicket(req); - return R.success("保存成功"); - } - - /** - * 工作票延期 进入许可人确认工作票延期 - * - * @param ticketId 工作票ID - * @param status 状态 - * @param completeTask 工作流进行 - */ - @Transactional(rollbackFor = Exception.class, propagation = Propagation.REQUIRED) - public void delay(Long ticketId, Integer status, ComleteTask completeTask) { - //新增延期信息 - Assert.notNull(completeTask.getVariables().get("delay"), "延期信息不能为空"); - WorkTicketDelayEntity delayEntity = (WorkTicketDelayEntity) completeTask.getVariables().get("delay"); - delayService.save(delayEntity); - //更新负责人确认执行情况流程 填充信息 - WorkTicketFlowEntity workTicketFlowEntity = workTicketFlowService.getOne(Wrappers.lambdaQuery().eq(WorkTicketFlowEntity::getTicketId, ticketId).eq(WorkTicketFlowEntity::getFlowCode, TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_WORK_FINISH.getStatus()).orderByDesc(WorkTicketFlowEntity::getCreateTime).last("limit 1;")); - workTicketFlowService.update(Wrappers.lambdaUpdate().set(WorkTicketFlowEntity::getExecutor, AuthUtil.getUserId().toString()).set(WorkTicketFlowEntity::getExecuteTime, LocalDateTime.now()).eq(WorkTicketFlowEntity::getId, workTicketFlowEntity.getId())); - //更新工作票状态 - this.update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, status).eq(WorkTicketInfoEntity::getId, ticketId)); - //创建延期流程 - WorkTicketInfoEntity infoEntity = this.getById(ticketId); - WorkTicketFlowEntity currentFlowEntity = new WorkTicketFlowEntity(); - currentFlowEntity.setTicketId(ticketId); - currentFlowEntity.setFlowCode(status.toString()); - currentFlowEntity.setExecutor(infoEntity.getLicensor().toString()); - currentFlowEntity.setProcTaskId((String) completeTask.getVariables().get("procTaskId")); - workTicketFlowService.save(workTicketFlowEntity); - //进入工作流下一步 - R result = flowClient.completeTask(completeTask); - if (!result.isSuccess()) { - throw new ServiceException("执行工作流失败"); - } - } - - @Override - public R detail(Long id) { - WorkTicketInfoEntity workTicketInfoEntity = this.getById(id); - if (ObjectUtil.isEmpty(workTicketInfoEntity)) { - return R.fail("未查询到该ID对应的记录"); - } else { - WorkTicketInfoVO workTicketInfoVO = WorkTicketInfoWrapper.build().entityVO(workTicketInfoEntity); - - /**获取工作票安全措施列表**/ - WorkTicketSafetyMeasureDto workTicketSafetyMeasureDto = new WorkTicketSafetyMeasureDto(); - workTicketSafetyMeasureDto.setTicketId(id); - List workTicketSafetyMeasureVOList = workTicketSafetyMeasureService.list(workTicketSafetyMeasureDto); - workTicketInfoVO.setWorkTicketSafetyMeasureVOList(workTicketSafetyMeasureVOList); - - /**获取工作票负责人变更**/ - WorkTicketPrincipalChangeDto workTicketPrincipalChangeDto = new WorkTicketPrincipalChangeDto(); - workTicketPrincipalChangeDto.setTicketId(id); - List workTicketPrincipalChangeVOList = workTicketPrincipalChangeService.list(workTicketPrincipalChangeDto); - workTicketInfoVO.setWorkTicketPrincipalChangeVOList(workTicketPrincipalChangeVOList); - - /**获取工作票工作组员变更**/ - WorkTicketMembersChangeDto workTicketMembersChangeDto = new WorkTicketMembersChangeDto(); - workTicketMembersChangeDto.setTicketId(id); - List workTicketMembersChangeVOList = workTicketMembersChangeService.list(workTicketMembersChangeDto); - workTicketInfoVO.setWorkTicketMembersChangeVOList(workTicketMembersChangeVOList); - - /**获取工作票跨日运行时间列表**/ - WorkTicketOperateTimeDto workTicketOperateTimeDto = new WorkTicketOperateTimeDto(); - workTicketOperateTimeDto.setTicketId(id); - List workTicketOperateTimeVOList = workTicketOperateTimeService.list(workTicketOperateTimeDto); - workTicketInfoVO.setWorkTicketOperateTimeVOList(workTicketOperateTimeVOList); - - /**获取工作票处理流程列表**/ - WorkTicketFlowDto workTicketFlowDto = new WorkTicketFlowDto(); - workTicketFlowDto.setTicketId(id); - List workTicketFlowVOList = workTicketFlowService.list(workTicketFlowDto); - workTicketInfoVO.setWorkTicketFlowVOList(workTicketFlowVOList); - - /**获取工作票延期列表**/ - WorkTicketDelayDto workTicketDelayDto = new WorkTicketDelayDto(); - workTicketDelayDto.setTicketId(id); - List workTicketDelayList = workDelayNoScopeMapper.selectList(new LambdaQueryWrapper() {{ - eq(WorkTicketDelayEntity::getTicketId, id); - eq(WorkTicketDelayEntity::getIsDeleted, 0L); - }}); - if (CollectionUtil.isNotEmpty(workTicketDelayList)) { - workTicketInfoVO.setWorkTicketDelayVOList(WorkTicketDelayWrapper.build().listVO(workTicketDelayList)); - } - - return R.data(workTicketInfoVO); - } - } - - @Override - public R> queryList(WorkTicketInfoDto req, Query query) { - LambdaQueryWrapper lqw = this.getQueryWrapper(req); - if (ObjectUtil.isNotEmpty(req.getCreateDept())) { - lqw.eq(WorkTicketInfoEntity::getCreateDept, req.getCreateDept()); - } - - lqw.orderByDesc(WorkTicketInfoEntity::getCreateTime).orderByDesc(WorkTicketInfoEntity::getUpdateTime); - IPage pages = this.page(Condition.getPage(query), lqw); - //数据转换 - IPage workTicketInfoVOIPage = new Page<>(pages.getCurrent(), pages.getSize()); - workTicketInfoVOIPage.setRecords(WorkTicketInfoWrapper.build().listVO(pages.getRecords())); - workTicketInfoVOIPage.setPages(pages.getPages()); - workTicketInfoVOIPage.setTotal(pages.getTotal()); - //获取创建人 - workTicketInfoVOIPage.getRecords().forEach(item -> { - User user = UserCache.getUser(item.getCreateUser()); - if (user != null) { - item.setCreateUserName(user.getName()); - } - }); - - - return R.data(workTicketInfoVOIPage); - } - - @Override - public List list(WorkTicketInfoDto req) { - LambdaQueryWrapper lqw = this.getQueryWrapper(req); - List workTicketInfoEntityList = this.list(lqw); - return CollectionUtil.isNotEmpty(workTicketInfoEntityList) ? WorkTicketInfoWrapper.build().listVO(workTicketInfoEntityList) : null; - } - - @Override - @Transactional - public R remove(Long id, String comment) { - WorkTicketInfoEntity entity = this.getById(id); - if (ObjectUtil.isEmpty(entity)) { - return R.fail(400, "删除失败!未查询到相关记录"); - } - - boolean flag = this.update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, TicketConstants.FirstWorkTicketFlowStatusEnum.TERMINATION.getStatus()).eq(WorkTicketInfoEntity::getId, id)); - - /**线下单独删除**/ - if (TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE.getStatus().equals(entity.getStatus())) { - return R.status(flag); - } - /**终止工作流**/ - R r = flowClient.delProcessInstanceById(entity.getProcessInstanceId(), comment); - if (!r.isSuccess()) { - throw new ServiceException("终止工作流失败!"); - } - return R.success("删除成功!"); - } - - @Override - public void exportWorkTicketTemplate(Long id, HttpServletResponse response) { - exportWorkTicketInfoPdf(id, response); - } - - @Override - @SuppressWarnings("unchecked") - public void exportWorkTicketInfoPdf(Long id, HttpServletResponse response) { - R workTicketInfoVOR = this.detail(id); - if (!workTicketInfoVOR.isSuccess()) { - log.error("未查询到相关工作票记录!"); - return; - } - WorkTicketInfoVO workTicketInfoVO = workTicketInfoVOR.getData(); - //将workTicketInfoVO封装进Map,以便pdf导出 - Map workTicketInfoMap = new HashMap<>(); - try { - workTicketInfoMap = PdfUtils.objectToMap(workTicketInfoVO); - } catch (Exception e) { - log.info("转换对象失败!"); - } - //安全措施 - if (CollectionUtil.isNotEmpty(workTicketInfoVO.getWorkTicketSafetyMeasureVOList())) { - Map> measureMap = workTicketInfoVO.getWorkTicketSafetyMeasureVOList().stream().collect(Collectors.groupingBy(WorkTicketSafetyMeasureVO::getType)); - if (ObjectUtil.isNotEmpty(measureMap.get(TicketConstants.MEASURE_TYPE_ONE))) { - workTicketInfoMap.put("matterLibraryListOne", measureMap.get(TicketConstants.MEASURE_TYPE_ONE).stream().map(measure -> { - Map map = PdfUtils.objectToMap(measure); - map.put("safetyMeasure", ObjectUtil.isNotEmpty(map.get("measure")) ? map.get("measure") : null); - String status = TicketConstants.SafetyMeasureStatusEnum.FINISH.getStatus().equals(measure.getStatus()) ? TicketConstants.SafetyMeasureStatusEnum.FINISH.getDescribe() : " "; - map.put("status", status); - return map; - }).collect(Collectors.toList())); - } else { - workTicketInfoMap.put("matterLibraryListOne", new ArrayList>(1)); - } - if (ObjectUtil.isNotEmpty(measureMap.get(TicketConstants.MEASURE_TYPE_TWO))) { - workTicketInfoMap.put("matterLibraryListTwo", measureMap.get(TicketConstants.MEASURE_TYPE_TWO).stream().map(measure -> { - Map map = PdfUtils.objectToMap(measure); - map.put("safetyMeasure", ObjectUtil.isNotEmpty(map.get("measure")) ? map.get("measure") : null); - String status = TicketConstants.SafetyMeasureStatusEnum.FINISH.getStatus().equals(measure.getStatus()) ? TicketConstants.SafetyMeasureStatusEnum.FINISH.getDescribe() : " "; - map.put("status", status); - return map; - }).collect(Collectors.toList())); - } else { - workTicketInfoMap.put("matterLibraryListTwo", new ArrayList>(1)); - } - if (ObjectUtil.isNotEmpty(measureMap.get(TicketConstants.MEASURE_TYPE_THREE))) { - workTicketInfoMap.put("matterLibraryListThree", measureMap.get(TicketConstants.MEASURE_TYPE_THREE).stream().map(measure -> { - Map map = PdfUtils.objectToMap(measure); - map.put("safetyMeasure", ObjectUtil.isNotEmpty(map.get("measure")) ? map.get("measure") : null); - String status = TicketConstants.SafetyMeasureStatusEnum.FINISH.getStatus().equals(measure.getStatus()) ? TicketConstants.SafetyMeasureStatusEnum.FINISH.getDescribe() : " "; - map.put("status", status); - return map; - }).collect(Collectors.toList())); - } else { - workTicketInfoMap.put("matterLibraryListThree", new ArrayList>(1)); - } - } - //线下开票确认人为空 - workTicketInfoMap.put("membersConfirm", TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE.getStatus().equals(workTicketInfoVO.getStatus()) ? "" : workTicketInfoVO.getMembersName()); - //获取工作票工作流处理信息 - List workTicketFlowVOList = workTicketInfoVO.getWorkTicketFlowVOList(); - //签发 - List signFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.LICENSE.getStatus().equals(Integer.parseInt(f.getFlowCode()))).collect(Collectors.toList()); - if (CollectionUtil.isNotEmpty(signFlow)) { - workTicketInfoMap.put("signer", signFlow.get(0).getCreateUserName()); - workTicketInfoMap.put("signTime", DateUtil.format(signFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); - } else { - workTicketInfoMap.put("signer", ""); - workTicketInfoMap.put("signTime", ""); - } - //许可人许可 - if (Func.isNotEmpty(workTicketInfoVO.getLicenseTime())) { - workTicketInfoMap.put("licensorConfirm", workTicketInfoVO.getLicensorName()); - workTicketInfoMap.put("licenseTime", DateUtil.format(workTicketInfoVO.getLicenseTime(), TicketConstants.TICKET_DATE_PATTERN)); - } else { - workTicketInfoMap.put("licensorConfirm", ""); - workTicketInfoMap.put("licenseTime", ""); - } - - /**负责人收到工作票**/ - List receiveFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_MEASURE_PRINCIPAL.getStatus().equals(Integer.parseInt(f.getFlowCode()))).collect(Collectors.toList()); - if (CollectionUtil.isNotEmpty(receiveFlow)) { - workTicketInfoMap.put("receivePrincipal", receiveFlow.get(0).getCreateUserName()); - workTicketInfoMap.put("receiveTime", DateUtil.format(receiveFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); - workTicketInfoMap.put("principalConfirm", workTicketInfoVO.getPrincipalName()); - } else { - workTicketInfoMap.put("receivePrincipal", ""); - workTicketInfoMap.put("receiveTime", ""); - workTicketInfoMap.put("principalConfirm", ""); - } - /**负责人确认安全事项**/ - List confirmFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_MEASURE_MEMBERS.getStatus().equals(Integer.parseInt(f.getFlowCode()))).collect(Collectors.toList()); - if (CollectionUtil.isNotEmpty(confirmFlow)) { - workTicketInfoMap.put("confirmPrincipal", confirmFlow.get(0).getCreateUserName()); - workTicketInfoMap.put("confirmTime", DateUtil.format(confirmFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); - } else { - workTicketInfoMap.put("confirmPrincipal", ""); - workTicketInfoMap.put("confirmTime", ""); - } - /**工作结束**/ - List finishFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.END.getStatus().equals(Integer.parseInt(f.getFlowCode()))).collect(Collectors.toList()); - if (CollectionUtil.isNotEmpty(finishFlow)) { - workTicketInfoMap.put("finisher", finishFlow.get(0).getCreateUserName()); - workTicketInfoMap.put("finishTime", DateUtil.format(finishFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); - workTicketInfoMap.put("principalFinish", workTicketInfoVO.getPrincipalName()); - } else { - workTicketInfoMap.put("finisher", ""); - workTicketInfoMap.put("finishTime", ""); - workTicketInfoMap.put("principalFinish", ""); - } - /**工作终结**/ - List endFlow = workTicketFlowVOList.stream().filter(f -> TicketConstants.FirstWorkTicketFlowStatusEnum.FINISH.getStatus().intValue() == Integer.parseInt(f.getFlowCode())).collect(Collectors.toList()); - if (CollectionUtil.isNotEmpty(endFlow)) { - workTicketInfoMap.put("endLicensor", endFlow.get(0).getCreateUserName()); - workTicketInfoMap.put("endTime", DateUtil.format(endFlow.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); - workTicketInfoMap.put("groundSwitchCount", ObjectUtil.isNotEmpty(endFlow.get(0).getGroundSwitchCount()) ? endFlow.get(0).getGroundSwitchCount() : ""); - workTicketInfoMap.put("groundWireCode", ObjectUtil.isNotEmpty(endFlow.get(0).getGroundWireCode()) ? endFlow.get(0).getGroundWireCode() : ""); - workTicketInfoMap.put("groundWireCount", ObjectUtil.isNotEmpty(endFlow.get(0).getGroundWireCount()) ? endFlow.get(0).getGroundWireCount() : ""); - } else { - workTicketInfoMap.put("endLicensor", ""); - workTicketInfoMap.put("endTime", ""); - workTicketInfoMap.put("groundSwitchCount", ""); - workTicketInfoMap.put("groundWireCode", ""); - workTicketInfoMap.put("groundWireCount", ""); - } - /**负责人变更**/ - List workTicketPrincipalChangeVOList = workTicketInfoVO.getWorkTicketPrincipalChangeVOList(); - if (CollectionUtil.isNotEmpty(workTicketPrincipalChangeVOList)) { - workTicketInfoMap.put("initPrincipal", workTicketPrincipalChangeVOList.get(0).getInitialPrincipalName()); - workTicketInfoMap.put("changePrincipal", workTicketPrincipalChangeVOList.get(0).getChangePrincipalName()); - workTicketInfoMap.put("principalChangeSigner", workTicketPrincipalChangeVOList.get(0).getCreateUserName()); - workTicketInfoMap.put("principalChangeTime", DateUtil.format(workTicketPrincipalChangeVOList.get(0).getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); - } else { - workTicketInfoMap.put("initPrincipal", ""); - workTicketInfoMap.put("changePrincipal", ""); - workTicketInfoMap.put("principalChangeSigner", ""); - workTicketInfoMap.put("principalChangeTime", ""); - } - /**工作成员变更**/ - List membersChangeList = workTicketInfoVO.getWorkTicketMembersChangeVOList(); - if (CollectionUtil.isNotEmpty(membersChangeList)) { - /**工作成员变更详情**/ - String membersChangeSituation = membersChangeList.stream().map(mc -> DateUtil.format(mc.getCreateTime(), TicketConstants.TICKET_DATE_PATTERN).concat(":").concat(mc.getChangeMembersName())).collect(Collectors.joining(";")); - workTicketInfoMap.put("membersChangeSituation", membersChangeSituation); - workTicketInfoMap.put("memberChangePrincipal", membersChangeList.get(0).getCreateUserName()); - } else { - workTicketInfoMap.put("membersChangeSituation", ""); - workTicketInfoMap.put("memberChangePrincipal", ""); - } - /**工作票延期**/ - List workTicketDelayVOList = workTicketInfoVO.getWorkTicketDelayVOList(); - if (CollectionUtil.isNotEmpty(workTicketDelayVOList)) { - WorkTicketDelayVO workTicketDelayVO = workTicketDelayVOList.get(0); - workTicketInfoMap.put("delayTime", DateUtil.format(workTicketDelayVO.getChangeTime(), TicketConstants.TICKET_DATE_PATTERN)); - workTicketInfoMap.put("delayPrincipal", workTicketDelayVO.getCreateUserName()); - workTicketInfoMap.put("delayPrincipalTime", DateUtil.format(workTicketDelayVO.getCreateTime(), TicketConstants.TICKET_DATE_PATTERN)); - workTicketInfoMap.put("delayLicensor", workTicketDelayVO.getLicensorName()); - workTicketInfoMap.put("delayLicenseTime", DateUtil.format(workTicketDelayVO.getLicenseTime(), TicketConstants.TICKET_DATE_PATTERN)); - } else { - workTicketInfoMap.put("delayTime", ""); - workTicketInfoMap.put("delayPrincipal", ""); - workTicketInfoMap.put("delayPrincipalTime", ""); - workTicketInfoMap.put("delayLicensor", ""); - workTicketInfoMap.put("delayLicenseTime", ""); - } - - /**跨日工作时间**/ - List operateList = workTicketInfoVO.getWorkTicketOperateTimeVOList(); - if (CollectionUtil.isNotEmpty(operateList)) { - List> operateMapList = operateList.stream().map(operate -> { - Map map = new HashMap<>(4); - map.put("startTime", DateUtil.format(operate.getStartTime(), TicketConstants.TICKET_DATE_PATTERN)); - map.put("endTime", DateUtil.format(operate.getEndTime(), TicketConstants.TICKET_DATE_PATTERN)); - map.put("principal", operate.getPrincipalName()); - map.put("licensor", operate.getLicensorName()); - return map; - }).collect(Collectors.toList()); - workTicketInfoMap.put("operateMapList", operateMapList); - } else { - List> operateMapList = new ArrayList<>(); - Map map = new HashMap<>(4); - map.put("startTime", ""); - map.put("endTime", ""); - map.put("principal", ""); - map.put("licensor", ""); - operateMapList.add(map); - workTicketInfoMap.put("operateMapList", operateMapList); - } - - /**运行值班人员暂为空**/ - workTicketInfoMap.put("dutyPersonName", "/"); - - String fileName = TicketConstants.WordFileNameEnum.getFileNameByType(workTicketInfoVO.getType()) + PdfUtils.XLSX_SUFFIX; - log.info("工作票模板为:{}", fileName); - TemplateExportParams templateExportParams = new TemplateExportParams("template/" + fileName, true); - Workbook workbook = null; - try { - workbook = ExcelUtil.getWorkbook(templateExportParams, workTicketInfoMap); - } catch (Exception e) { - e.printStackTrace(); - } - //上传xlsx至服务器 - try { - ExcelUtil.upload(workbook, xlsSavePath, workTicketInfoVO.getWorkContent() + PdfUtils.XLSX_SUFFIX); - } catch (Exception e) { - e.printStackTrace(); - } - //将xlsx文件转换为pdf并保存 - String pdfFileName = workTicketInfoVO.getWorkContent() + PdfUtils.PDF_SUFFIX; - String xlsFileName = workTicketInfoVO.getWorkContent() + PdfUtils.XLSX_SUFFIX; - PdfUtils.convertPdf(xlsSavePath, xlsFileName, pdfSavePath, pdfFileName); - String savePath = pdfSavePath + pdfFileName; - // 设置response参数,可以打开下载页面 - PdfUtils.readPdf(response, savePath); - } - - @Override - @Transactional - public R completeTask(WorkTicketInfoDto req, BladeFlow flow) { - ComleteTask task = new ComleteTask(); - task.setTaskId(flow.getTaskId()); - task.setComment(flow.getComment()); - task.setAttachments(flow.getAttachments()); - task.setFlag(flow.getFlag()); - task.setProcessInstanceId(flow.getProcessInstanceId()); - task.setVariables(flow.getVariables()); - - //待许可时获取许可人角色下用户开启工作流 - if (TicketConstants.FirstWorkTicketFlowStatusEnum.LICENSE.getStatus().equals(req.getStatus())) { - R> userListR = userClient.relationUserListByRoleAlias(AuthUtil.getTenantId(), req.getCreateDept(), TicketConstants.LICENSOR_ROLE); - if (!userListR.isSuccess()) { - throw new ServiceException(userListR.getMsg()); - } - Map variables = CollectionUtil.isEmpty(flow.getVariables()) ? new HashMap<>() : flow.getVariables(); - String taskUser = userListR.getData().stream().map(u -> "taskUser_".concat(u.getId().toString())).collect(Collectors.joining(",")); - variables.put("licenseUserIds", taskUser); - task.setVariables(variables); - } - log.info("工作流对象为:{}", JSONObject.toJSONString(flow)); - - if (TicketConstants.FirstWorkTicketFlowStatusEnum.LICENSE.getStatus().equals(req.getStatus())) { - req.setSigner(AuthUtil.getUserId()); - } else if (TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_MEASURE_PRINCIPAL.getStatus().equals(req.getStatus())) { - req.setLicensor(AuthUtil.getUserId()); - } else if (TicketConstants.FirstWorkTicketFlowStatusEnum.INVALID.getStatus().equals(req.getStatus())) { - this.invalidTicket(req); - } - - //更新状态 - boolean flag = this.update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, req.getStatus()).set(WorkTicketInfoEntity::getPrincipal, req.getPrincipal()).set(WorkTicketInfoEntity::getLicensor, req.getLicensor()).set(WorkTicketInfoEntity::getLicenseTime, req.getLicenseTime()).set(WorkTicketInfoEntity::getLicenseEndTime, req.getLicenseEndTime()).eq(WorkTicketInfoEntity::getId, req.getId())); - - //新增流程信息 - WorkTicketFlowEntity workTicketFlowEntity = new WorkTicketFlowEntity(); - workTicketFlowEntity.setTicketId(req.getId()); - workTicketFlowEntity.setFlowCode(req.getStatus().toString()); - workTicketFlowEntity.setExecutor(AuthUtil.getUserId().toString()); - workTicketFlowEntity.setExecuteTime(LocalDateTime.now()); - workTicketFlowEntity.setRemark(Optional.ofNullable(flow.getVariables()).map(v -> v.get("remark")).map(s -> s.toString()).orElse("")); - workTicketFlowEntity.setSignImgPath(Optional.ofNullable(flow.getVariables()).map(v -> v.get("signImgPath")).map(s -> s.toString()).orElse("")); - workTicketFlowEntity.setGroundWireCount(Optional.ofNullable(flow.getVariables()).map(v -> v.get("groundWireCount")).map(s -> Integer.parseInt(s.toString())).orElse(null)); - workTicketFlowEntity.setGroundSwitchCount(Optional.ofNullable(flow.getVariables()).map(v -> v.get("groundSwitchCount")).map(s -> Integer.parseInt(s.toString())).orElse(null)); - workTicketFlowEntity.setStatus(req.getStatus()); - workTicketFlowService.save(workTicketFlowEntity); - //执行流程 - R flowResult = flowClient.completeTask(task); - //更新任务状态 - updateAccessStatus(req); - - if (!flowResult.isSuccess()) { - throw new ServiceException("执行工作流失败!"); - } - - return R.success("操作成功!"); - } - - @Transactional(rollbackFor = Exception.class) - public void updateAccessStatus(WorkTicketInfoDto req) { - if (TicketConstants.TaskTypeEnum.JXRW.getType().equals(req.getTaskType()) || TicketConstants.TaskTypeEnum.JXJH.getType().equals(req.getTaskType())) { - log.info("许可通过:{}", JSONObject.toJSONString(req)); - //许可人通过将检修任务状态设为执行中 - if (TicketConstants.FirstWorkTicketFlowStatusEnum.CONFIRM_MEASURE_PRINCIPAL.getStatus().equals(req.getStatus())) { - OperAccessTaskEntity taskEntity = new OperAccessTaskEntity(); - taskEntity.setId(req.getTaskId()); - taskEntity.setStatus(AccessConstants.ACCESS_TASK_STATUS_1); - //设置开始时间 - taskEntity.setActStartTime(DateUtil.now()); - operAccessTaskClient.updateById(taskEntity); - } - } - } - - /*** - * 票据作废时 对应任务ID应该置空 - * @param req - */ - public void invalidTicket(WorkTicketInfoDto req) { - if (TicketConstants.TaskTypeEnum.JXRW.getType().equals(req.getTaskType()) || TicketConstants.TaskTypeEnum.JXJH.getType().equals(req.getTaskType())) { - OperAccessTaskEntity taskEntity = new OperAccessTaskEntity(); - taskEntity.setId(req.getTaskId()); - taskEntity.setInvalid(true); - taskEntity.setTicketId(null); - operAccessTaskClient.updateById(taskEntity); - } - if (TicketConstants.TaskTypeEnum.RCWH.getType().equals(req.getTaskType())) { - OperMaintenanceTaskDTO dto = new OperMaintenanceTaskDTO(); - dto.setId(req.getTaskId()); - dto.setInvalid(true); - //dto.setTicketId(null); - taskClient.doUpdateTaskById(dto); - } - } - - /*** - * 回传票据ID - * @param req - */ - @Transactional(rollbackFor = Exception.class) - public void returnTicket(WorkTicketInfoDto req) { - if (TicketConstants.TaskTypeEnum.JXRW.getType().equals(req.getTaskType())) { - OperAccessTaskEntity taskEntity = new OperAccessTaskEntity(); - taskEntity.setId(req.getTaskId()); - taskEntity.setTicketId(req.getId()); - operAccessTaskClient.updateById(taskEntity); - } - if (TicketConstants.TaskTypeEnum.RCWH.getType().equals(req.getTaskType())) { - OperMaintenanceTaskDTO dto = new OperMaintenanceTaskDTO(); - dto.setId(req.getTaskId()); - dto.setTicketId(req.getId()); - taskClient.doUpdateTaskById(dto); - } - } - - /** - * 获取queryWrapper - * - * @param req - * @return - */ - private LambdaQueryWrapper getQueryWrapper(WorkTicketInfoDto req) { - LambdaQueryWrapper lqw = new LambdaQueryWrapper(); - if (Func.isNotBlank(req.getProcessInstanceId())) { - lqw.eq(WorkTicketInfoEntity::getProcessInstanceId, req.getProcessInstanceId()); - } - if (Func.isNotEmpty(req.getType())) { - lqw.eq(WorkTicketInfoEntity::getType, req.getType()); - } - if (Func.isNotEmpty(req.getTaskType())) { - lqw.eq(WorkTicketInfoEntity::getTaskType, req.getTaskType()); - } - if (Func.isNotEmpty(req.getCode())) { - lqw.like(WorkTicketInfoEntity::getCode, req.getCode()); - } - if (Func.isNotEmpty(req.getStatus())) { - lqw.eq(WorkTicketInfoEntity::getStatus, req.getStatus()); - } - if (Func.isNotEmpty(req.getCompany())) { - lqw.like(WorkTicketInfoEntity::getType, "%".concat(req.getCompany()).concat("%")); - } - if (Func.isNotEmpty(req.getClassGroup())) { - lqw.eq(WorkTicketInfoEntity::getClassGroup, req.getClassGroup()); - } - if (Func.isNotEmpty(req.getTaskId())) { - lqw.eq(WorkTicketInfoEntity::getTaskId, req.getTaskId()); - } - if (Func.isNotEmpty(req.getClassGroup())) { - lqw.eq(WorkTicketInfoEntity::getClassGroup, req.getClassGroup()); - } - if (Func.isNotEmpty(req.getClassGroupMembers())) { - lqw.like(WorkTicketInfoEntity::getClassGroupMembers, "%".concat(req.getClassGroupMembers()).concat("%")); - } - if (Func.isNotEmpty(req.getWorkContent())) { - lqw.like(WorkTicketInfoEntity::getWorkContent, "%".concat(req.getWorkContent()).concat("%")); - } - if (Func.isNotEmpty(req.getSigner())) { - lqw.eq(WorkTicketInfoEntity::getSigner, req.getSigner()); - } - if (Func.isNotEmpty(req.getLicensor())) { - lqw.eq(WorkTicketInfoEntity::getLicensor, req.getLicensor()); - } - if (Func.isNotEmpty(req.getStartTime())) { - lqw.ge(WorkTicketInfoEntity::getCreateTime, req.getStartTime()); - } - if (Func.isNotEmpty(req.getEndTime())) { - lqw.le(WorkTicketInfoEntity::getCreateTime, req.getEndTime()); - } - if (!CollectionUtil.isEmpty(req.getDeptIds())) { - lqw.in(WorkTicketInfoEntity::getCreateDept, req.getDeptIds()); - } - return lqw; - } - - /** - * 开启一个流程实例 - * - * @author hx - **/ - @Override - public BladeFlow startProcessInstance(String processDefinitionKey, WorkTicketInfoEntity workTicketInfoEntity) { - /**获取签发人角色下的人员**/ - R> listR = userClient.relationUserListByRoleAlias(tenantId, Long.parseLong(AuthUtil.getUser().getDeptId()), TicketConstants.SIGNER_ROLE); - if (!listR.isSuccess() || CollectionUtil.isEmpty(listR.getData())) { - throw new ServiceException("工作票签发人角色下未查询到相关人员"); - } - String signUserIds = listR.getData().stream().map(user -> "taskUser_".concat(user.getId().toString())).collect(Collectors.joining(",")); - - Map params = new HashMap(2) {{ - put("taskId", workTicketInfoEntity.getId()); - put("signUserIds", signUserIds); - }}; - - R r = flowClient.startProcessInstanceContainNameByKey(processDefinitionKey, "workTicket:task:" + workTicketInfoEntity.getId(), workTicketInfoEntity.getWorkContent(), params); - if (!r.isSuccess()) { - throw new ServiceException(r.getMsg()); - } - return r.getData(); - } - - /** - * 许可人通过线下工作票 - * - * @param req - * @return - */ - @Override - public R licenseOfflineTicket(WorkTicketInfoDto req) { - Long ticketId = req.getId(); - WorkTicketInfoEntity infoEntity = getById(ticketId); - //获取许可人角色下的人员 - R> listR = userClient.relationUserListByRoleAlias(tenantId, infoEntity.getCreateDept(), TicketConstants.LICENSOR_ROLE); - if (!listR.isSuccess() || CollectionUtil.isEmpty(listR.getData())) { - throw new ServiceException("工作票许可人角色下未查询到相关人员"); - } - List userId = listR.getData().stream().map(User::getId).distinct().collect(Collectors.toList()); - if (!userId.contains(AuthUtil.getUserId())) { - throw new ServiceException("当前操作人没有许可人角色,无法执行该操作"); - } - update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE_LICENSE.getStatus()).set(WorkTicketInfoEntity::getLicensor, AuthUtil.getUserId()).set(WorkTicketInfoEntity::getLicenseTime, LocalDateTime.now()).set(WorkTicketInfoEntity::getLicenseEndTime, req.getLicenseEndTime()).eq(WorkTicketInfoEntity::getId, ticketId)); - return R.success("操作成功"); - } - - /** - * 完成线下工作票 - * - * @param ticketAccessTaskDto - * @return - */ - @Override - public R finishOfflineTicket(TicketAccessTaskDto ticketAccessTaskDto) { - //更新工作票 - WorkTicketInfoDto infoDto = ticketAccessTaskDto.getWorkTicketInfoDto(); - update(Wrappers.lambdaUpdate().set(WorkTicketInfoEntity::getStatus, TicketConstants.FirstWorkTicketFlowStatusEnum.OFFLINE_END.getStatus()).eq(WorkTicketInfoEntity::getId, infoDto.getId())); - //获取工作票实体类 - WorkTicketInfoEntity infoEntity = getById(infoDto.getId()); - //根据任务类型执行任务 - if (ObjectUtil.isEmpty(infoEntity.getTaskType())) { - return R.success("操作成功"); - } - //FIXME 日常维护、检修任务暂时不形成闭环(因许可人无需填入任务结束完成所需参数,故选择由执行人手动闭环) ~2022--05-06 -// if(TicketConstants.TaskTypeEnum.JXRW.getType().equals(infoEntity.getTaskType()) -// || TicketConstants.TaskTypeEnum.JXJH.getType().equals(infoEntity.getTaskType())) { -// //执行检修任务 -// OperAccessTaskDTO accessTaskDTO = ticketAccessTaskDto.getAccessTaskDTO(); -// accessTaskDTO.setId(infoEntity.getTaskId()); -// if(ObjectUtil.isNotEmpty(accessTaskDTO) && ObjectUtil.isNotEmpty(accessTaskDTO.getId())){ -// log.info("线下检修任务执行调用传参为:{}",JSONObject.toJSONString(accessTaskDTO)); -// //operAccessTaskClient.finishAccessTask(accessTaskDTO); -// } -// } -// else if(TicketConstants.TaskTypeEnum.RCWH.getType().equals(infoEntity.getTaskType())) { -// //执行日常维护任务 -// OperMaintenanceTaskDTO operMaintenanceTaskDTO = new OperMaintenanceTaskDTO(); -// operMaintenanceTaskDTO.setId(infoEntity.getTaskId()); -// operMaintenanceTaskDTO.setStatus(MaintenanceConstant.TASK_STATUS_3); -// if(ObjectUtil.isNotEmpty(operMaintenanceTaskDTO) && ObjectUtil.isNotEmpty(operMaintenanceTaskDTO.getId()) ){ -// ComleteTask comleteTask = new ComleteTask(); -// comleteTask.setProcessInstanceId(operMaintenanceTaskDTO.getProcessInstanceId()); -// comleteTask.setFlag("ok"); -// comleteTask.setPass(true); -// comleteTask.setComment("执行完成"); -// TaskFlowDTO taskFlowDTO = TaskFlowDTO.builder().taskDTO(operMaintenanceTaskDTO).comleteTask(comleteTask).build(); -// log.info("线下日常维护任务执行调用传参为:{}",JSONObject.toJSONString(taskFlowDTO)); -// //R result = taskClient.updateTaskStatus(taskFlowDTO); -// } -// } - return R.success("操作成功"); - } - - /*** - * 获取工作票编号 - * @return - */ - @Override - public String getWorkTicketCode() { - String code = ""; - lock.lock(); - try { - /**获取当前时间**/ - DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyMM"); - YearMonth yearMonth = YearMonth.now(); - String tym = yearMonth.format(formatter); - LocalDateTime date = LocalDateTime.now(); - LocalDateTime firstDay = date.with(TemporalAdjusters.firstDayOfMonth()).withHour(0).withMinute(0).withSecond(0); - LocalDateTime lastDay = date.with(TemporalAdjusters.lastDayOfMonth()).withHour(23).withMinute(59).withSecond(59); - log.info("当月第一天:{};当月最后一天{}", firstDay, lastDay); - /**获取当月工作票总条数**/ - List infoEntityList = this.list(new LambdaQueryWrapper() {{ - ge(WorkTicketInfoEntity::getCreateTime, firstDay); - le(WorkTicketInfoEntity::getCreateTime, lastDay); - }}); - if (CollectionUtil.isEmpty(infoEntityList)) { - code = TicketConstants.TicketCodePreEnum.DQ_WORK.getPrefix().concat("-").concat(tym).concat("-001"); - } else { - code = TicketConstants.TicketCodePreEnum.DQ_WORK.getPrefix().concat("-").concat(tym).concat("-").concat(String.format("%03d", infoEntityList.size() + 1)); - } - } catch (Exception e) { - e.printStackTrace(); - } finally { - lock.unlock(); - } - return code; - } - - /** - * 获取安全检查工作票项统计 - * - * @param startDate 开始时间 - * @param endDate 结束时间 - * @param dept 机构ID - * @return WorkTicketStatisticVO统计对象 - */ - @Override - public SafeCheckStatisticVO getWorkTicketStatistic(String startDate, String endDate, Long dept) { - return this.baseMapper.getWorkTicketStatistic(startDate, endDate, dept); - } - - /** - * 验证角色是否能查询到相关人员 - * - * @param deptId 机构ID - * @param roleAliasArray 角色 按逗号分隔 - * @return - */ - @Override - public R> verificationRole(Long deptId, String roleAliasArray) { - Map result = new HashedMap(2); - List failRoleAliasList = Lists.newArrayList(); - AtomicBoolean flag = new AtomicBoolean(true); - Arrays.stream(roleAliasArray.split(",")).forEach(roleAlias -> { - //查询机构下角色是否有对应人员列表 - R> listR = userClient.relationUserListByRoleAlias(tenantId, deptId, roleAlias); - if (!listR.isSuccess() || ObjectUtil.isEmpty(listR.getData())) { - failRoleAliasList.add(roleAlias); - flag.set(false); - } - }); - result.put("flag", flag.get()); - if (CollectionUtil.isNotEmpty(failRoleAliasList)) { - result.put("message", "验证失败,获取" + JSON.toJSONString(failRoleAliasList) + "角色下的人员失败"); - } - - return R.data(result); - } - - /** - * 根据月份和区域查询工作票列表详情 - * - * @param pageEntity - * @param areaVo - * @return - */ - @Override - public BladePage workTicketListByMonthAndArea(Page pageEntity, StandardTicketWithAreaVo areaVo) { - //1.查询 - QueryWrapper queryWrapper = new QueryWrapper<>(); - - //开票来源 - queryWrapper.eq(Func.isNotEmpty(areaVo.getTaskType()), "sti.task_type", areaVo.getTaskType()); - //编号 - queryWrapper.like(Func.isNotEmpty(areaVo.getCode()), "sti.code", areaVo.getCode()); - - //状态 - queryWrapper.eq(Func.isNotEmpty(areaVo.getStatus()), "sti.status", areaVo.getStatus()); - - //开始时间 - queryWrapper.lt(Func.isNotEmpty(areaVo.getStartTime()), "sti.create_time", areaVo.getStartTime()); - - //结束时间 - queryWrapper.le(Func.isNotEmpty(areaVo.getEndTime()), "sti.create_time", areaVo.getEndTime()); - - - queryWrapper.eq("sti.create_dept", areaVo.getAreaId()); - queryWrapper.eq(areaVo.getYearMonth() != null, "date_format(sti.create_time,'%Y-%m')", areaVo.getYearMonth()); - //如果为1为合格 - // queryWrapper.eq("tie.status",1); - Page workTicketInfoEntityPage = baseMapper.selectPages(pageEntity, queryWrapper); - //数据转换 - List standardWorkList = new ArrayList<>(); - if (CollectionUtil.isNotEmpty(workTicketInfoEntityPage.getRecords())) { - standardWorkList = workTicketInfoEntityPage.getRecords().stream().map(workTicketInfoEntity -> { - StandardWorkVo standardWorkVo = new StandardWorkVo(); - BeanUtils.copyProperties(workTicketInfoEntity, standardWorkVo); - return standardWorkVo; - }).collect(Collectors.toList()); - } - - IPage page = new Page<>(); - page.setRecords(standardWorkList); - page.setTotal(workTicketInfoEntityPage.getTotal()); - page.setCurrent(workTicketInfoEntityPage.getCurrent()); - page.setSize(workTicketInfoEntityPage.getSize()); - BladePage bladePage = BladePage.of(page); - return bladePage; - } - - - /** - * 判断是否存在合格率 如果存在返回true 否则为false - * - * @param item - * @return - */ - private boolean isTicketPercentById(WorkTicketInfoEntity item) { - LambdaQueryWrapper ticketInfoEvaluateEntityLambdaQueryWrapper = new LambdaQueryWrapper<>(); - ticketInfoEvaluateEntityLambdaQueryWrapper.eq(TicketInfoEvaluateEntity::getTicketId, item.getId()); - ticketInfoEvaluateEntityLambdaQueryWrapper.eq(TicketInfoEvaluateEntity::getStatus, TicketConstants.TicketQualifiedEnum.Qualified.getCode()); - // 查询合格评价 - int count = ticketInfoEvaluateService.count(ticketInfoEvaluateEntityLambdaQueryWrapper); - return count > 0; - } - - - /** - * 更新状态值 - * - * @param status - * @param description - * @param id - */ - @Override - public void updateFlowStatusById(Integer status, String description, Long id) { - LambdaUpdateWrapper queryWrapper = new LambdaUpdateWrapper<>(); - queryWrapper.set(WorkTicketInfoEntity::getFlowStatus, status); - queryWrapper.set(WorkTicketInfoEntity::getFlowDescription, description); - queryWrapper.eq(WorkTicketInfoEntity::getId, id); - } - - /** - * 获取工作详情 - * - * @param ticketId - * @return - */ - @Override - public WorkTicketVo selectDetailsById(Long ticketId) { - WorkTicketVo workTicketVo = new WorkTicketVo(); - - //1. 获取工作票详情数据 - WorkTicketInfoEntity workTicketInfo = this.getById(ticketId); - if (ObjectUtils.isEmpty(workTicketInfo)) { - throw new ServiceException("未查询到ticketId对应的信息"); - } - - //赋值签发人 - if (workTicketInfo.getSigner() != null) { - User user = UserCache.getUser(workTicketInfo.getSigner()); - workTicketInfo.setSignerName(user == null ? null : user.getName()); - } - - if (workTicketInfo.getSigner() != null && workTicketInfo.getSignerName() == null) { - User user = UserCache.getUser(workTicketInfo.getSigner()); - workTicketInfo.setSignerName(user == null ? null : user.getName()); - } - - //赋值许可人名称 - if (workTicketInfo.getLicensor() != null) { - User user = UserCache.getUser(workTicketInfo.getLicensor()); - workTicketInfo.setLicensorName(user == null ? null : user.getName()); - } - - if (workTicketInfo.getLicensor() != null && workTicketInfo.getLicensorName() == null) { - User user = UserCache.getUser(workTicketInfo.getLicensor()); - workTicketInfo.setLicensorName(user == null ? null : user.getName()); - } - - // 负责值班负责人 - if (workTicketInfo.getWatchPrincipal() != null) { - User user = UserCache.getUser(workTicketInfo.getWatchPrincipal()); - workTicketInfo.setWatchPrincipalName(user == null ? null : user.getName()); - } - - if (workTicketInfo.getWatchPrincipal() != null && workTicketInfo.getWatchPrincipalName() == null) { - User user = UserCache.getUser(workTicketInfo.getWatchPrincipal()); - workTicketInfo.setWatchPrincipalName(user == null ? null : user.getName()); - } - - - StringBuilder sb = new StringBuilder(); - String classGroupMembers = workTicketInfo.getClassGroupMembers(); - if (StringUtils.isNoneBlank(classGroupMembers)) { - // System.out.println("获取classGroupMembers ==> " + classGroupMembers); - String[] split = classGroupMembers.split(","); - for (String classGroupMember : split) { - System.out.println(classGroupMember); - if (StringUtils.isNoneBlank(classGroupMember)) { - boolean matches = classGroupMember.matches("[0-9]+"); - if (matches) { - User user = UserCache.getUser(Long.valueOf(classGroupMember)); - String name = user == null ? null : user.getName(); - if (StringUtils.isNotBlank(name)) { - sb.append(name).append(","); - } - } - } - } - - //统计人数 - if (workTicketInfo.getTotalPerson() == null) { - workTicketInfo.setTotalPerson(sb.toString().trim().split(",").length); - } - - //成员信息 - if (workTicketInfo.getClassGroupMembersName() == null) { - workTicketInfo.setClassGroupMembersName(sb.toString().endsWith(",") ? - sb.toString().substring(0, sb.length() - 1) : sb.toString()); - } - } - - - //负责人名称 - if (workTicketInfo.getPrincipalName() == null && workTicketInfo.getPrincipal() != null) { - User user = UserCache.getUser(workTicketInfo.getPrincipal()); - workTicketInfo.setPrincipalName(user == null ? "" : user.getName()); - } - - - workTicketVo.setWorkTicket(workTicketInfo); - - //2. 安全措施数组 - List workTicketSafetyMeasureEntity = workTicketSafetyMeasureService.selectByTicketId(ticketId); - if (CollectionUtils.isNotEmpty(workTicketSafetyMeasureEntity)) { - workTicketVo.setSafetyMeasuresList(workTicketSafetyMeasureEntity); - } - - //3. 工作票工作任务组 - List workTicketContentEntities = workTicketContentService.selectByTicketId(ticketId); - if (CollectionUtils.isNotEmpty(workTicketContentEntities)) { - workTicketVo.setWorkTicketContentDtoList(workTicketContentEntities); - } - - //4. 工作票延期 - WorkTicketDelayEntity workTicketDelayEntity = delayService.selectByTicketId(ticketId); - if (ObjectUtils.isNotEmpty(workTicketDelayEntity)) { - workTicketVo.setWorkTicketDelay(workTicketDelayEntity); - } - - - //5.工作结束 - WorkTicketFinish workTicketFinish = workTicketFinishService.selectByTicketId(ticketId); - if (ObjectUtils.isNotEmpty(workTicketFinish)) { - workTicketVo.setWorkTicketFinish(workTicketFinish); - } - - - //6.工作开始时间和结束时间 - List workTicketOperateTimeEntities = - workTicketOperateTimeService.selectByTicketId(ticketId); - if (CollectionUtils.isNotEmpty(workTicketOperateTimeEntities)) { - workTicketVo.setWorkTicketOperateTimeEntities(workTicketOperateTimeEntities); - } - - - //7. 工作票负责人变更 - WorkTicketPrincipalChangeEntity workTicketPrincipalChangeEntity = - workTicketPrincipalChangeService.selectByTicketId(ticketId); - if (ObjectUtils.isNotEmpty(workTicketPrincipalChangeEntity)) { - //原负责人 - if (workTicketPrincipalChangeEntity.getInitialPrincipal() != null) { - workTicketPrincipalChangeEntity.setInitialPrincipalName( - UserCache.getUser(workTicketPrincipalChangeEntity.getInitialPrincipal()).getName() - ); - } - //变更负责人 - if (workTicketPrincipalChangeEntity.getChangePrincipal() != null) { - workTicketPrincipalChangeEntity.setChangePrincipalName( - UserCache.getUser(workTicketPrincipalChangeEntity.getChangePrincipal()).getName() - ); - } - - workTicketVo.setWorkTicketPrincipalChange(workTicketPrincipalChangeEntity); - } - - - //7. 根据工作票Id查询工作票危险点分析及控制措施票 - List list = ticketInfoDangerService.selectAllByTicket(workTicketInfo.getId()); - if (CollectionUtils.isNotEmpty(list)) { - workTicketVo.setTicketInfoDangers(list); - } - return workTicketVo; - } -} +public class WorkTicketServiceImpl extends BaseServiceImpl implements WorkTicketService { +} \ No newline at end of file From be85aa59e8d6361d87ffc0b4e7c5fb55ebcf290d Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Wed, 7 Jun 2023 11:03:43 +0800 Subject: [PATCH 12/14] =?UTF-8?q?#=E5=AE=9A=E6=97=B6=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E6=8A=BD=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hnac/hzims/scheduled/service/equipment/impl/PlanServiceImpl.java | 2 ++ .../scheduled/service/equipment/impl/WorkshopInfoServiceImpl.java | 3 ++- .../hzims/scheduled/service/ticket/impl/TicketEvaluateServiceImpl.java | 2 ++ .../hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java | 2 ++ .../hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java | 2 ++ 5 files changed, 10 insertions(+), 1 deletion(-) diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/PlanServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/PlanServiceImpl.java index 1091c99..56cc7ca 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/PlanServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/PlanServiceImpl.java @@ -1,5 +1,6 @@ package com.hnac.hzims.scheduled.service.equipment.impl; +import com.baomidou.dynamic.datasource.annotation.DS; import com.hnac.hzims.equipment.entity.PlanGenerationEntity; import com.hnac.hzims.scheduled.mapper.equipment.PlanMapper; import com.hnac.hzims.scheduled.service.equipment.PlanService; @@ -16,6 +17,7 @@ import java.util.List; @Service @Slf4j @AllArgsConstructor +@DS("equipment") public class PlanServiceImpl extends BaseServiceImpl implements PlanService { diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/WorkshopInfoServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/WorkshopInfoServiceImpl.java index 20aed9a..d7ae08f 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/WorkshopInfoServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/equipment/impl/WorkshopInfoServiceImpl.java @@ -1,5 +1,6 @@ package com.hnac.hzims.scheduled.service.equipment.impl; +import com.baomidou.dynamic.datasource.annotation.DS; import com.hnac.hzims.equipment.entity.WorkshopInfoEntity; import com.hnac.hzims.scheduled.mapper.equipment.WorkshopInfoMapper; import com.hnac.hzims.scheduled.service.equipment.WorkshopInfoService; @@ -14,7 +15,7 @@ import org.springframework.stereotype.Service; @Service @AllArgsConstructor @Slf4j +@DS("equipment") public class WorkshopInfoServiceImpl extends BaseServiceImpl implements WorkshopInfoService { - } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketEvaluateServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketEvaluateServiceImpl.java index 1bd217e..253f645 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketEvaluateServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketEvaluateServiceImpl.java @@ -1,5 +1,6 @@ package com.hnac.hzims.scheduled.service.ticket.impl; +import com.baomidou.dynamic.datasource.annotation.DS; import com.hnac.hzims.scheduled.mapper.ticket.TicketEvaluateMapper; import com.hnac.hzims.scheduled.service.ticket.TicketEvaluateService; import com.hnac.hzims.ticket.allTicket.entity.TicketInfoEvaluateEntity; @@ -14,6 +15,7 @@ import org.springframework.stereotype.Service; @Service @RequiredArgsConstructor @Slf4j +@DS("ticket") public class TicketEvaluateServiceImpl extends BaseServiceImpl implements TicketEvaluateService { diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java index 1ef4c4d..5e3bab9 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java @@ -1,5 +1,6 @@ package com.hnac.hzims.scheduled.service.ticket.impl; +import com.baomidou.dynamic.datasource.annotation.DS; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.hnac.hzims.scheduled.mapper.ticket.TicketMapper; import com.hnac.hzims.scheduled.service.ticket.TicketEvaluateService; @@ -28,6 +29,7 @@ import java.util.stream.Collectors; @Service @RequiredArgsConstructor @Slf4j +@DS("ticket") public class TicketServiceImpl extends BaseServiceImpl implements TicketService { private final WorkTicketService workTicketService; diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java index 8c13e28..d859eeb 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/WorkTicketServiceImpl.java @@ -1,5 +1,6 @@ package com.hnac.hzims.scheduled.service.ticket.impl; +import com.baomidou.dynamic.datasource.annotation.DS; import com.hnac.hzims.scheduled.mapper.ticket.WorkTicketMapper; import com.hnac.hzims.scheduled.service.ticket.WorkTicketService; import com.hnac.hzims.ticket.workTicket.entity.WorkTicketInfoEntity; @@ -15,5 +16,6 @@ import org.springframework.stereotype.Service; @Service @Slf4j @RequiredArgsConstructor +@DS("ticket") public class WorkTicketServiceImpl extends BaseServiceImpl implements WorkTicketService { } \ No newline at end of file From b904a9fb7ca37af5abe1fe69bca3e8b0418c410a Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Wed, 7 Jun 2023 14:32:28 +0800 Subject: [PATCH 13/14] =?UTF-8?q?#=E5=AE=9A=E6=97=B6=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E6=8A=BD=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hzims/operational/report/vo/DutyDefectVO.java | 20 + .../hzims/scheduled/mapper/inspect/TaskMapper.java | 13 + .../mapper/operation/PhenomenonMapper.java | 11 + .../mapper/safeproduct/CompanyMapper.java | 10 + .../mapper/safeproduct/InstanceMapper.java | 16 + .../scheduled/mapper/safeproduct/MonthMapper.java | 11 + .../scheduled/mapper/safeproduct/TrialMapper.java | 11 + .../scheduled/scheduled/MonitorScheduledTask.java | 4 +- .../scheduled/scheduled/ReportScheduledTask.java | 26 + .../scheduled/service/inspect/TaskService.java | 15 + .../service/inspect/impl/TaskServiceImpl.java | 64 +++ .../scheduled/service/operation/AccessService.java | 3 + .../service/operation/MaintenanceService.java | 3 + .../service/operation/MonitorService.java | 4 + .../service/operation/PhenomenonService.java | 15 + .../scheduled/service/operation/ReportService.java | 9 + .../service/operation/impl/AccessServiceImpl.java | 37 +- .../operation/impl/MaintenanceServiceImpl.java | 38 ++ .../operation/impl/PhenomenonServiceImpl.java | 60 +++ .../operation/impl/RealTargetServiceImpl.java | 1 - .../service/operation/impl/ReportServiceImpl.java | 527 +++++++++++++++++++++ .../service/safeproduct/CompanyService.java | 11 + .../service/safeproduct/InstanceService.java | 12 + .../service/safeproduct/MonthService.java | 14 + .../service/safeproduct/TrialService.java | 13 + .../safeproduct/impl/CompanyServiceImpl.java | 19 + .../safeproduct/impl/InstanceServiceImpl.java | 19 + .../service/safeproduct/impl/MonthServiceImpl.java | 96 ++++ .../service/safeproduct/impl/TrialServiceImpl.java | 50 ++ .../scheduled/service/ticket/TicketService.java | 4 + .../service/ticket/impl/TicketServiceImpl.java | 62 +++ .../main/resources/mapper/inspect/TaskMapper.xml | 4 + .../mapper/operation/PhenomenonMapper.xml | 5 + .../resources/mapper/safeproduct/CompanyMapper.xml | 6 + .../mapper/safeproduct/InstanceMapper.xml | 5 + .../resources/mapper/safeproduct/MonthMapper.xml | 5 + .../resources/mapper/safeproduct/TrialMapper.xml | 20 + .../hzims/operational/report/vo/DutyDefectVO.java | 17 - .../mapper/CheckItemInstanceMapper.java | 16 - .../safeproduct/mapper/CheckItemInstanceMapper.xml | 20 - .../service/impl/CheckItemServiceImpl.java | 3 - 41 files changed, 1239 insertions(+), 60 deletions(-) create mode 100644 hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/report/vo/DutyDefectVO.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/inspect/TaskMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/PhenomenonMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/CompanyMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/InstanceMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/MonthMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/TrialMapper.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/TaskService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/impl/TaskServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/PhenomenonService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ReportService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/PhenomenonServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ReportServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/CompanyService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/InstanceService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/MonthService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/TrialService.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/CompanyServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/InstanceServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/MonthServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/TrialServiceImpl.java create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/inspect/TaskMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/operation/PhenomenonMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/CompanyMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/InstanceMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/MonthMapper.xml create mode 100644 hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/TrialMapper.xml delete mode 100644 hzims-service/operational/src/main/java/com/hnac/hzims/operational/report/vo/DutyDefectVO.java delete mode 100644 hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.java delete mode 100644 hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.xml diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/report/vo/DutyDefectVO.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/report/vo/DutyDefectVO.java new file mode 100644 index 0000000..177185d --- /dev/null +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/report/vo/DutyDefectVO.java @@ -0,0 +1,20 @@ +package com.hnac.hzims.operational.report.vo; + +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * @author ysj + */ +@Data +public class DutyDefectVO{ + + @ApiModelProperty("缺陷总数") + private Integer defectSum; + + @ApiModelProperty("缺陷数") + private Integer defect; + + @ApiModelProperty("缺陷总数ID 按逗号分隔") + private String totalIds; +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/inspect/TaskMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/inspect/TaskMapper.java new file mode 100644 index 0000000..1a4a34b --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/inspect/TaskMapper.java @@ -0,0 +1,13 @@ +package com.hnac.hzims.scheduled.mapper.inspect; + +import com.hnac.hzinfo.inspect.task.entity.TaskEntity; +import org.apache.ibatis.annotations.Mapper; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +@Mapper +public interface TaskMapper extends UserDataScopeBaseMapper { + +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/PhenomenonMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/PhenomenonMapper.java new file mode 100644 index 0000000..58eebab --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/operation/PhenomenonMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.operation; + +import com.hnac.hzims.operational.defect.entity.OperPhenomenonEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface PhenomenonMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/CompanyMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/CompanyMapper.java new file mode 100644 index 0000000..00aa8a5 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/CompanyMapper.java @@ -0,0 +1,10 @@ +package com.hnac.hzims.scheduled.mapper.safeproduct; + +import com.hnac.hzims.safeproduct.entity.CheckCompanyEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface CompanyMapper extends UserDataScopeBaseMapper { +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/InstanceMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/InstanceMapper.java new file mode 100644 index 0000000..1dedec0 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/InstanceMapper.java @@ -0,0 +1,16 @@ +package com.hnac.hzims.scheduled.mapper.safeproduct; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.hnac.hzims.safeproduct.entity.CheckItemInstanceEntity; +import org.apache.ibatis.annotations.Param; + +import java.util.List; + +/** + * Created by Sam Huang 2022/5/6 8:23 + */ +public interface InstanceMapper extends BaseMapper { + + List getCheckItemInstanceByMonth(@Param("months") List months, @Param("deptId") Long deptId); + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/MonthMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/MonthMapper.java new file mode 100644 index 0000000..4454508 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/MonthMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.safeproduct; + +import com.hnac.hzims.safeproduct.entity.CheckMonthEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * @author ysj + */ +public interface MonthMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/TrialMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/TrialMapper.java new file mode 100644 index 0000000..04496f0 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/TrialMapper.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.mapper.safeproduct; + +import com.hnac.hzims.safeproduct.entity.SafeEquipmentTrialEntity; +import org.springblade.core.datascope.mapper.UserDataScopeBaseMapper; + +/** + * 设备试验mapper接口 + */ +public interface TrialMapper extends UserDataScopeBaseMapper { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/MonitorScheduledTask.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/MonitorScheduledTask.java index ed0af83..6e5a0e9 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/MonitorScheduledTask.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/MonitorScheduledTask.java @@ -42,7 +42,7 @@ public class MonitorScheduledTask { */ @XxlJob(REAL_TIME_DATA) //@Scheduled(cron = "0/40 * * * * ? ") - public ReturnT loadRealData(String param) throws Exception { + public ReturnT loadRealData(String param) { if (Func.isBlank(param)) { param = DateUtil.format(new Date(), "yyyy-MM"); } @@ -55,7 +55,7 @@ public class MonitorScheduledTask { * @return ReturnT */ @XxlJob(CENTRALIZED_MONITORING) - public ReturnT loadMonitoring(String param) throws Exception { + public ReturnT loadMonitoring(String param) { if (Func.isBlank(param)) { param = DateUtil.format(new Date(), "yyyy-MM"); } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ReportScheduledTask.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ReportScheduledTask.java index b5d19a6..7f59697 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ReportScheduledTask.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/scheduled/ReportScheduledTask.java @@ -1,8 +1,18 @@ package com.hnac.hzims.scheduled.scheduled; +import com.hnac.hzims.scheduled.service.operation.ReportService; +import com.xxl.job.core.biz.model.ReturnT; +import com.xxl.job.core.handler.annotation.XxlJob; import lombok.extern.slf4j.Slf4j; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.Func; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; +import java.util.Date; + +import static com.hnac.hzims.operational.main.constant.MainConstants.AREA_MONTH_REPORT; + /** * @author ysj @@ -11,4 +21,20 @@ import org.springframework.stereotype.Component; @Component public class ReportScheduledTask { + @Autowired + private ReportService service; + + /** + * 首页-生产月报表 + * @return ReturnT + */ + @XxlJob(AREA_MONTH_REPORT) + public ReturnT loadMonthReport(String param) { + if (Func.isBlank(param)) { + param = DateUtil.format(new Date(), "yyyy-MM-dd HH:mm:ss"); + } + service.loadMonthReport(param,1); + return new ReturnT<>("SUCCESS"); + } + } \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/TaskService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/TaskService.java new file mode 100644 index 0000000..6d25531 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/TaskService.java @@ -0,0 +1,15 @@ +package com.hnac.hzims.scheduled.service.inspect; + +import com.hnac.hzinfo.inspect.task.entity.TaskEntity; +import com.hnac.hzinfo.inspect.task.vo.DutyInspectTaskVO; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * @author ysj + */ +public interface TaskService extends BaseService { + + DutyInspectTaskVO task(String start, String end, List areas); +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/impl/TaskServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/impl/TaskServiceImpl.java new file mode 100644 index 0000000..6fcc206 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/impl/TaskServiceImpl.java @@ -0,0 +1,64 @@ +package com.hnac.hzims.scheduled.service.inspect.impl; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.hnac.hzims.scheduled.mapper.inspect.TaskMapper; +import com.hnac.hzims.scheduled.service.inspect.TaskService; +import com.hnac.hzinfo.inspect.task.entity.TaskEntity; +import com.hnac.hzinfo.inspect.task.vo.DutyInspectTaskVO; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springframework.stereotype.Service; + +import java.util.List; +import java.util.stream.Collectors; + +/** + * @author ysj + */ +@Service +@Slf4j +@AllArgsConstructor +public class TaskServiceImpl extends BaseServiceImpl implements TaskService { + + /** + * 时间区间机构的巡检任务数据查询 + * @param start + * @param end + * @param areas + * @return + */ + @Override + public DutyInspectTaskVO task(String start, String end, List areas) { + DutyInspectTaskVO task = new DutyInspectTaskVO(); + task.setInspectTaskSum(0); + task.setInspectTaskFinish(0); + task.setNotExecuteTaskCount(0); + // 查询所有巡检任务 + List tasks = this.list(new LambdaQueryWrapper() {{ + ge(TaskEntity::getPlanStartTime, start) + .le(TaskEntity::getPlanStartTime, end) + .in(TaskEntity::getCreateDept, areas); + }}); + if(CollectionUtil.isEmpty(tasks)){ + return task; + } + task.setInspectTaskIds(tasks.stream().map(TaskEntity::getId).map(Object::toString).collect(Collectors.joining(","))); + task.setInspectTaskSum(tasks.size()); + // 所有处理完成巡检任务 + List finshList = tasks.stream().filter(o-> null != o.getStatus() && o.getStatus().equals(3)).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(finshList)){ + return task; + } + task.setInspectTaskFinish(finshList.size()); + // 未执行任务数 + List notExecuteList = tasks.stream().filter(o-> null != o.getStatus() && o.getStatus().equals(0)).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(notExecuteList)){ + return task; + } + task.setNotExecuteTaskCount(notExecuteList.size()); + return task; + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AccessService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AccessService.java index f42d943..9a2d858 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AccessService.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/AccessService.java @@ -1,6 +1,7 @@ package com.hnac.hzims.scheduled.service.operation; import com.hnac.hzims.operational.access.entity.OperAccessTaskEntity; +import com.hnac.hzims.operational.main.vo.OverhaulVo; import org.springblade.core.mp.base.BaseService; import java.util.List; @@ -11,4 +12,6 @@ import java.util.List; public interface AccessService extends BaseService { double accessCount(List areas); + + OverhaulVo overhaul(String start, String end, List areas); } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MaintenanceService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MaintenanceService.java index 49b4012..31d2be0 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MaintenanceService.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MaintenanceService.java @@ -1,5 +1,6 @@ package com.hnac.hzims.scheduled.service.operation; +import com.hnac.hzims.operational.main.vo.MaintainVo; import com.hnac.hzims.operational.maintenance.entity.OperMaintenanceTaskEntity; import org.springblade.core.mp.base.BaseService; @@ -12,4 +13,6 @@ public interface MaintenanceService extends BaseService departList); + + MaintainVo maintain(String start, String end, List areas); } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java index d9bfd85..5df3786 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/MonitorService.java @@ -1,5 +1,9 @@ package com.hnac.hzims.scheduled.service.operation; +import org.springblade.core.tool.api.R; + +import java.util.Map; + /** * WEB水电站首页接口 * @author ysj diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/PhenomenonService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/PhenomenonService.java new file mode 100644 index 0000000..fe294d8 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/PhenomenonService.java @@ -0,0 +1,15 @@ +package com.hnac.hzims.scheduled.service.operation; + +import com.hnac.hzims.operational.defect.entity.OperPhenomenonEntity; +import com.hnac.hzims.operational.report.vo.DutyDefectVO; +import org.springblade.core.mp.base.BaseService; + +import java.util.List; + +/** + * @author ysj + */ +public interface PhenomenonService extends BaseService { + + DutyDefectVO defect(String start, String end, List areas); +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ReportService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ReportService.java new file mode 100644 index 0000000..2fe62ac --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/ReportService.java @@ -0,0 +1,9 @@ +package com.hnac.hzims.scheduled.service.operation; + +/** + * @author ysj + */ +public interface ReportService { + + void loadMonthReport(String param, int i); +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AccessServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AccessServiceImpl.java index 1a1fb7c..da01d8e 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AccessServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/AccessServiceImpl.java @@ -1,20 +1,23 @@ package com.hnac.hzims.scheduled.service.operation.impl; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.hnac.hzims.operational.access.constants.AccessConstants; import com.hnac.hzims.operational.access.entity.OperAccessTaskEntity; +import com.hnac.hzims.operational.main.vo.OverhaulVo; import com.hnac.hzims.scheduled.mapper.operation.AccessMapper; import com.hnac.hzims.scheduled.service.operation.AccessService; import lombok.AllArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springblade.core.mp.base.BaseServiceImpl; import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.Func; import org.springframework.stereotype.Service; import java.time.LocalDate; import java.time.LocalDateTime; import java.time.LocalTime; import java.util.List; - +import java.util.stream.Collectors; /** * @author ysj @@ -48,4 +51,36 @@ public class AccessServiceImpl extends BaseServiceImpl areas) { + OverhaulVo overhaulVo = new OverhaulVo(); + // 检修总数 + List overhaulList = this.list(new LambdaQueryWrapper(){{ + ge(OperAccessTaskEntity::getPlanStartTime,start); + le(OperAccessTaskEntity::getPlanStartTime,end); + in(OperAccessTaskEntity::getCreateDept,areas); + }}); + if(CollectionUtil.isEmpty(overhaulList)){ + overhaulVo.setOverhaul(0); + overhaulVo.setOverhaulFinish(0); + return overhaulVo; + } + overhaulVo.setOverhaul(overhaulList.size()); + // 检修完成数量 + List overhaulFinishTask = overhaulList.stream().filter(task-> Func.isNotEmpty(task.getStatus()) && AccessConstants.ACCESS_TASK_STATUS_4 == task.getStatus()) + .map(OperAccessTaskEntity::getId).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(overhaulFinishTask)){ + overhaulVo.setOverhaulFinish(0); + } + overhaulVo.setOverhaulFinish(overhaulFinishTask.size()); + return overhaulVo; + } } \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MaintenanceServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MaintenanceServiceImpl.java index 6ec8d3e..7152ace 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MaintenanceServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/MaintenanceServiceImpl.java @@ -1,6 +1,8 @@ package com.hnac.hzims.scheduled.service.operation.impl; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.hnac.hzims.operational.main.vo.MaintainVo; +import com.hnac.hzims.operational.maintenance.constants.MaintenanceConstant; import com.hnac.hzims.operational.maintenance.entity.OperMaintenanceTaskEntity; import com.hnac.hzims.scheduled.mapper.operation.MaintenanceMapper; import com.hnac.hzims.scheduled.service.operation.MaintenanceService; @@ -8,12 +10,14 @@ import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springblade.core.mp.base.BaseServiceImpl; import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.Func; import org.springframework.stereotype.Service; import java.time.LocalDate; import java.time.LocalDateTime; import java.time.LocalTime; import java.util.List; +import java.util.stream.Collectors; /** * @author ysj @@ -47,4 +51,38 @@ public class MaintenanceServiceImpl extends BaseServiceImpl areas) { + MaintainVo maintainVo = new MaintainVo(); + //日常维护 + List maintainList = this.list(new LambdaQueryWrapper(){{ + ge(OperMaintenanceTaskEntity::getDisposeTime,start); + le(OperMaintenanceTaskEntity::getDisposeTime,end); + in(OperMaintenanceTaskEntity::getCreateDept,areas); + }}); + if(CollectionUtil.isEmpty(maintainList)){ + maintainVo.setMaintain(0); + maintainVo.setMaintainFinish(0); + return maintainVo; + } + // 日常维护完成数 + maintainVo.setMaintain(maintainList.size()); + List maintainFinish = maintainList.stream().filter(o-> Func.isNotEmpty(o.getStatus()) && MaintenanceConstant.TASK_STATUS_5 == o.getStatus()) + .map(OperMaintenanceTaskEntity::getId).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(maintainFinish)){ + maintainVo.setMaintainFinish(0); + } + maintainVo.setMaintainFinish(maintainFinish.size()); + return maintainVo; + } + + } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/PhenomenonServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/PhenomenonServiceImpl.java new file mode 100644 index 0000000..4afdf08 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/PhenomenonServiceImpl.java @@ -0,0 +1,60 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.hnac.hzims.operational.defect.entity.OperPhenomenonEntity; +import com.hnac.hzims.operational.report.vo.DutyDefectVO; +import com.hnac.hzims.scheduled.mapper.operation.PhenomenonMapper; +import com.hnac.hzims.scheduled.service.operation.PhenomenonService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.Func; +import org.springframework.stereotype.Service; + +import java.util.List; +import java.util.stream.Collectors; + +/** + * @author ysj + */ +@Service +@Slf4j +@AllArgsConstructor +public class PhenomenonServiceImpl extends BaseServiceImpl implements PhenomenonService { + + /** + * 时间范围内机构缺陷数据查询 + * @param start + * @param end + * @param areas + * @return + */ + @Override + public DutyDefectVO defect(String start, String end, List areas) { + DutyDefectVO defectVO = new DutyDefectVO(); + // 查询缺陷现象总数 + List operPhenomenonList = this.list(new LambdaQueryWrapper(){{ + ge(OperPhenomenonEntity::getCreateTime,start); + le(OperPhenomenonEntity::getCreateTime,end); + in(OperPhenomenonEntity::getCreateDept,areas); + }}); + if(CollectionUtil.isEmpty(operPhenomenonList)){ + defectVO.setDefectSum(0); + defectVO.setDefect(0); + return defectVO; + } + defectVO.setTotalIds(operPhenomenonList.stream().map(o->String.valueOf(o.getId())).collect(Collectors.joining(","))); + defectVO.setDefectSum(operPhenomenonList.size()); + // 消缺数 + List defectList = operPhenomenonList.stream().filter(o -> (Func.isNotEmpty(o.getIsDefect()) && o.getIsDefect() == 0) || "1".equals(o.getConclusionStatus())). + map(OperPhenomenonEntity::getId).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(defectList)){ + defectVO.setDefect(0); + return defectVO; + } + // 缺陷总数 + defectVO.setDefect(defectList.size()); + return defectVO; + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java index c34da3f..6e08365 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/RealTargetServiceImpl.java @@ -82,7 +82,6 @@ public class RealTargetServiceImpl implements RealTargetService { private final static String loadwaterpump_target_key = "hzims:operation:loadwaterpump:target:key"; private final static String loadwaterpump_real_key = "hzims:operation:loadwaterpump:real:key"; private final static String loadwater_level_key = "hzims:operation:loadwater:level:key"; - private final static String loadwater_group_key = "hzims:operation:group:key"; private final static String load_photovoltaic_real_key = "hzims:operation:photovoltaic:real:key"; private final static String load_photovoltaic_target_key = "hzims:operation:photovoltaic:target:key"; diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ReportServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ReportServiceImpl.java new file mode 100644 index 0000000..df04ec4 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/impl/ReportServiceImpl.java @@ -0,0 +1,527 @@ +package com.hnac.hzims.scheduled.service.operation.impl; + +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.google.common.util.concurrent.ThreadFactoryBuilder; +import com.hnac.hzims.equipment.entity.PlanGenerationEntity; +import com.hnac.hzims.message.dto.MailPushDto; +import com.hnac.hzims.message.fegin.IPushMsgClient; +import com.hnac.hzims.operational.main.constant.HomePageConstant; +import com.hnac.hzims.operational.main.vo.AreaMonthReportVo; +import com.hnac.hzims.operational.main.vo.MaintainVo; +import com.hnac.hzims.operational.main.vo.OverhaulVo; +import com.hnac.hzims.operational.report.vo.DutyDefectVO; +import com.hnac.hzims.operational.station.entity.StationEntity; +import com.hnac.hzims.safeproduct.dto.SafeEquipmentTrialDTO; +import com.hnac.hzims.scheduled.service.equipment.PlanService; +import com.hnac.hzims.scheduled.service.inspect.TaskService; +import com.hnac.hzims.scheduled.service.operation.*; +import com.hnac.hzims.scheduled.service.safeproduct.MonthService; +import com.hnac.hzims.scheduled.service.safeproduct.TrialService; +import com.hnac.hzims.scheduled.service.ticket.TicketService; +import com.hnac.hzims.ticket.workTicket.vo.TicketMonthVO; +import com.hnac.hzinfo.inspect.task.vo.DutyInspectTaskVO; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.collections4.MapUtils; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.DateUtil; +import org.springblade.core.tool.utils.ObjectUtil; +import org.springblade.core.tool.utils.StringUtil; +import org.springblade.system.entity.Dept; +import org.springblade.system.feign.ISysClient; +import org.springblade.system.user.entity.User; +import org.springblade.system.user.feign.IUserClient; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.data.redis.core.RedisTemplate; +import org.springframework.stereotype.Service; + +import java.math.BigDecimal; +import java.text.SimpleDateFormat; +import java.time.LocalDateTime; +import java.time.ZoneId; +import java.util.*; +import java.util.concurrent.*; +import java.util.stream.Collectors; + +/** + * @author ysj + */ +@Service +@RequiredArgsConstructor +@Slf4j +public class ReportServiceImpl implements ReportService { + + private final PlanService planService; + private final TaskService taskService; + private final TrialService trialService; + private final AccessService accessService; + private final TicketService ticketService; + private final StationService stationService; + private final MonthService monthService; + private final PhenomenonService phenomenonService; + private final MaintenanceService maintenanceService; + private final RedisTemplate redisTemplate; + private final ISysClient sysClient; + private final IUserClient userClient; + private final IPushMsgClient pushMsgClient; + + private final static String recent_year_cache_final = "hzims:operation:key:power:data"; + + @Value("${hzims.operation.area.report}") + private String report_month_cache_final; + + + /** + * 区域-月报 + * @param param + * @param year + */ + @Override + public void loadMonthReport(String param, int year) { + // 获取所有机构 + R> R = sysClient.getDeptList(); + if (!R.isSuccess() || CollectionUtil.isEmpty(R.getData())) { + return; + } + // 查询所有服务类型——"运维服务"、站点类型——"水电站" + List stations = stationService.list(Wrappers.lambdaQuery() + .eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE) + .eq(StationEntity::getType,HomePageConstant.HYDROPOWER) + ); + if (CollectionUtil.isEmpty(stations)) { + return; + } + // 站点近年发电数据 + Map> powerMap = (Map>) redisTemplate.opsForValue().get(recent_year_cache_final); + // 存储数据节点 key - 月份 value - 区域数据集合 + Map> map = new HashMap<>(); + // 月份集合 + List monthList = getMonthList(year, Calendar.getInstance().get(Calendar.MONTH)); + monthList.forEach(mon -> { + List list = this.getAreaReportByMon(R.getData(), powerMap, stations, mon); + if (CollectionUtil.isEmpty(list)) { + return; + } + map.put(mon, list); + }); + // 推送当月报表邮件 + this.sendMonthReport(map, R.getData()); + redisTemplate.opsForValue().set(report_month_cache_final, map); + } + + /** + * 获取近年月份集合 + * + * @param year + * @return + */ + public static List getMonthList(int year, int endMoth) { + SimpleDateFormat format = new SimpleDateFormat("yyyy-MM"); + // 开始日期 + Calendar endCal = Calendar.getInstance(); + endCal.setTime(new Date()); + endCal.add(Calendar.MONTH, -endCal.get(Calendar.MONTH) + endMoth); + endCal.add(Calendar.DATE, -endCal.get(Calendar.DATE) + 1); + + // 结束日期 + Calendar startCal = Calendar.getInstance(); + startCal.setTime(new Date()); + startCal.set(Calendar.YEAR, startCal.get(Calendar.YEAR) - year); + startCal.add(Calendar.MONTH, -startCal.get(Calendar.MONTH)); + startCal.add(Calendar.DATE, -startCal.get(Calendar.DATE) + 1); + // 获取日期之间的月份 + List list = new ArrayList<>(); + while (endCal.after(startCal)) { + list.add(format.format(startCal.getTime())); + startCal.add(Calendar.MONTH, 1); + } + list.add(format.format(endCal.getTime())); + return list; + } + + /** + * 区域月报数据加载 + * @param deptList + * @param powerMap + * @param stationList + * @param mon + * @return + */ + private List getAreaReportByMon(List deptList, Map> powerMap, List stationList, String mon) { + LocalDateTime startTime = LocalDateTime.parse(mon + "-01 00:00:00", DateUtil.DATETIME_FORMATTER); + LocalDateTime endTime = getEndTime(mon); + // 查询所有站点的计划发电量 + List planList = this.planPower(stationList, mon); + // 站点实际发电量 + Map actualMap = this.actualPower(powerMap, stationList, mon + "-01"); + // 站点去年发电量 + Map oldActualMap = this.actualPower(powerMap, stationList, lastyear(1,mon)); + // 站点前发电量 + Map oldOldActualMap = this.actualPower(powerMap, stationList, lastyear(2,mon)); + // 取机构中区域部分 + List areaList = deptList.stream().filter(o -> o.getDeptCategory().equals(3)).collect(Collectors.toList()); + if (CollectionUtil.isEmpty(areaList)) { + return null; + } + List areaMonthReportVoList = new ArrayList<>(); + areaList.forEach(area -> { + AreaMonthReportVo areaMonthReport = new AreaMonthReportVo(); + areaMonthReport.setAreaId(area.getId()); + areaMonthReport.setAreaName(area.getDeptName()); + // 获取区域下的站点 + List stationIdList = deptList.stream().filter(o -> o.getParentId().equals(area.getId()) && o.getDeptCategory().equals(4)).map(Dept::getId).collect(Collectors.toList()); + List areaStationList = stationList.stream().filter(o -> stationIdList.contains(o.getRefDept())).collect(Collectors.toList()); + if (CollectionUtil.isEmpty(areaStationList)) { + return; + } + // 计划发电量、实际发电量、发电完成率 + this.powerMonth(planList, actualMap, oldActualMap, areaStationList, areaMonthReport); + // 操作票、操作票合格率/ 工作票、工作票合格率 + this.doubleMonth(area, areaMonthReport, mon + "-01 00:00:00", this.strEndTime(mon)); + // 日常维护、巡检任务、缺陷数、消缺率、检修任务 + this.taskMonth(Collections.singletonList(area.getId()), areaMonthReport, mon + "-01 00:00:00", strEndTime(mon)); + // 预测 + this.predictPlanPower(oldActualMap,oldOldActualMap,areaStationList,areaMonthReport); + // 安全生产会议次数、月度检查报告、技能培训、安全大检查 + this.securityCheck(Collections.singletonList(area.getId()),areaMonthReport,mon + "-01 00:00:00", strEndTime(mon)); + // 设备试验 + this.getDeviceTry(mon + "-01 00:00:00", strEndTime(mon), Collections.singletonList(area.getId()),areaMonthReport); + areaMonthReportVoList.add(areaMonthReport); + }); + return areaMonthReportVoList; + } + + /** + * 获取结束时间 + */ + private LocalDateTime getEndTime(String mon) { + Date date = DateUtil.parse(mon + "-01 00:00:00",DateUtil.DATETIME_FORMAT); + Calendar calendar = Calendar.getInstance(); + calendar.setTime(date); + calendar.add(Calendar.MONTH, 1); + return calendar.getTime().toInstant().atZone(ZoneId.systemDefault()).toLocalDateTime(); + } + + /** + * 获取站点计划发电量 + */ + private List planPower(List stationList, String mon) { + List list = stationList.stream().map(StationEntity::getCode).collect(Collectors.toList()); + return planService.planGeneration(list, null, mon); + } + + /** + * 获取站点月份实际发电量 + */ + private Map actualPower(Map> powerMap, List stationList, String month) { + if (MapUtils.isEmpty(powerMap)) { + return null; + } + // 站点Id集合 + List stationIdList = stationList.stream().map(StationEntity::getId).collect(Collectors.toList()); + // 存储站点实际发电量 + Map actualPowerMap = new HashMap<>(); + stationIdList.forEach(key -> { + Map monthMap = powerMap.get(key); + if (MapUtils.isEmpty(monthMap)) { + return; + } + float actualPower = 0f; + if(ObjectUtil.isNotEmpty(monthMap.get(month))){ + actualPower = monthMap.get(month); + } + actualPowerMap.put(key, actualPower); + }); + return actualPowerMap; + } + + /** + * 获取去年时间 + */ + private String lastyear(int year,String mon) { + Date date = DateUtil.parse(mon + "-01 00:00:00",DateUtil.DATETIME_FORMAT); + Calendar calendar = Calendar.getInstance(); + calendar.setTime(date); + calendar.set(Calendar.YEAR, calendar.get(Calendar.YEAR) - year); + calendar.add(Calendar.DATE, -calendar.get(Calendar.DATE) + 1); + return DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + } + + /** + * 获取结束时间 + */ + private String strEndTime(String mon) { + Date date = DateUtil.parse(mon + "-01 00:00:00",DateUtil.DATETIME_FORMAT); + Calendar calendar = Calendar.getInstance(); + calendar.setTime(date); + calendar.add(Calendar.MONTH, 1); + return DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE); + } + + /** + * 区域-月计划发电量、月实际发电量、月发电完成率、同比 + * + * @param planList + * @param actualMap + * @param oldActualMap + * @param areaStationList + * @param areaMonthReport + */ + private void powerMonth(List planList, Map actualMap, Map oldActualMap, List areaStationList, AreaMonthReportVo areaMonthReport) { + // 计划发电量 + List codeList = areaStationList.stream().map(StationEntity::getCode).collect(Collectors.toList()); + double planPower = planList.stream().filter(o -> codeList.contains(o.getStationId())).mapToDouble(PlanGenerationEntity::getPlanGeneration).sum(); + areaMonthReport.setPlanPower(Float.parseFloat(String.valueOf(planPower))); + if (MapUtils.isEmpty(actualMap)) { + areaMonthReport.setActualPower(0f); + areaMonthReport.setPowerFinishRate(0.0); + return; + } + // 实际发电量 + List ids = areaStationList.stream().map(StationEntity::getId).collect(Collectors.toList()); + double actualPower = actualMap.entrySet().stream().filter(e -> ids.contains(e.getKey())).mapToDouble(Map.Entry::getValue).sum(); + areaMonthReport.setActualPower(Float.parseFloat(String.valueOf(actualPower))); + if (Math.abs(planPower) <= 0) { + areaMonthReport.setPowerFinishRate(0.0); + } else { + // 发电完成率 + double powerFinishRate = BigDecimal.valueOf(actualPower / planPower * 100).setScale(1, BigDecimal.ROUND_HALF_UP).doubleValue(); + areaMonthReport.setPowerFinishRate(powerFinishRate); + } + // 同比 + double oldActualPower = oldActualMap.entrySet().stream().filter(e -> ids.contains(e.getKey())).mapToDouble(Map.Entry::getValue).sum(); + if (Math.abs(actualPower) <= 0 || Math.abs(oldActualPower) <= 0) { + areaMonthReport.setComparePowerRate(0.0); + return; + } + double comparePowerRate = BigDecimal.valueOf(actualPower / oldActualPower).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue(); + areaMonthReport.setComparePowerRate(comparePowerRate); + } + + /** + * 区域-操作票、操作票合格率/ 工作票、工作票合格率 + * + * @param area + * @param areaMonthReport + */ + private void doubleMonth(Dept area, AreaMonthReportVo areaMonthReport, String startTime, String endTime) { + // 站点归属机构集合 + TicketMonthVO ticket = ticketService.operateWork(startTime,endTime,Collections.singletonList(area.getId())); + if (ObjectUtil.isEmpty(ticket)) { + areaMonthReport.setOperate(0); + areaMonthReport.setOperaQualifyRate(0.0); + areaMonthReport.setWork(0); + areaMonthReport.setWorkQualifyRate(0.0); + return; + } + // 操作票 + int operate = ticket.getOperate(); + int operateQualify = ticket.getOperateQualify(); + areaMonthReport.setOperate(operate); + if (operateQualify <= 0) { + areaMonthReport.setOperaQualifyRate(0.0); + } else { + double operateQualifyRate = BigDecimal.valueOf(operateQualify / (double) operate * 100L).setScale(1, BigDecimal.ROUND_HALF_UP).doubleValue(); + areaMonthReport.setOperaQualifyRate(operateQualifyRate); + } + //工作票 + int work = ticket.getWork(); + int workQualify = ticket.getWorkQualify(); + areaMonthReport.setWork(work); + if (workQualify <= 0) { + areaMonthReport.setWorkQualifyRate(0.0); + } else { + double workQualifyRate = BigDecimal.valueOf(workQualify / (double) work * 100L).setScale(1, BigDecimal.ROUND_HALF_UP).doubleValue(); + areaMonthReport.setWorkQualifyRate(workQualifyRate); + } + } + + /** + * 任务月报-日常维护、巡检任务、缺陷数、消缺率、检修任务 + * + * @param areas + * @param areaMonthReport + */ + private void taskMonth(List areas, AreaMonthReportVo areaMonthReport, String startTime, String endTime) { + //通过线程池异步获取月报各模块内容 主要分为五块内容 + ThreadFactory namedThreadFactory = new ThreadFactoryBuilder().setNameFormat("area_month_report-pool-%d").build(); + ExecutorService exe = new ThreadPoolExecutor(4, 4, 0L, TimeUnit.MILLISECONDS, new LinkedBlockingQueue<>(1024), namedThreadFactory, new ThreadPoolExecutor.AbortPolicy()); + //监控线程执行完后返回结果 + CountDownLatch countDownLatch = new CountDownLatch(4); + // 日常维护 + exe.execute(() -> { + MaintainVo maintainVo = maintenanceService.maintain(startTime, endTime, areas); + int maintainSum = maintainVo.getMaintain(); + areaMonthReport.setRoutineMaintenance(maintainSum); + countDownLatch.countDown(); + }); + + // 巡检任务 + exe.execute(() -> { + DutyInspectTaskVO task = taskService.task(startTime,endTime,areas); + if (ObjectUtil.isEmpty(task)) { + areaMonthReport.setInspect(0); + } else { + int inspect = task.getInspectTaskSum(); + areaMonthReport.setInspect(inspect); + } + countDownLatch.countDown(); + }); + + // 消缺 + exe.execute(() -> { + DutyDefectVO defectVO = phenomenonService.defect(startTime, endTime, areas); + int defectSum = defectVO.getDefectSum(); + int defect = defectVO.getDefect(); + areaMonthReport.setDefect(defectSum); + if (defectSum <= 0) { + areaMonthReport.setDefectRate(0.0); + } else { + double deletionRate = BigDecimal.valueOf(defect / defectSum * 100L).setScale(1, BigDecimal.ROUND_HALF_UP).doubleValue(); + areaMonthReport.setDefectRate(deletionRate); + } + countDownLatch.countDown(); + }); + + // 检修 + exe.execute(() -> { + OverhaulVo overhaulVo = accessService.overhaul(startTime, endTime, areas); + int overhaul = overhaulVo.getOverhaul(); + areaMonthReport.setMaintenanceTasks(overhaul); + countDownLatch.countDown(); + }); + + //所有模板数据获取完成后释放锁 + try { + countDownLatch.await(); + } catch (InterruptedException e) { + e.printStackTrace(); + Thread.currentThread().interrupt(); + } + exe.shutdown(); + } + + /** + * 预测发电量 + * @param oldActualMap + * @param oldOldActualMap + * @param areaStationList + * @param areaMonthReport + */ + private void predictPlanPower(Map oldActualMap, Map oldOldActualMap, List areaStationList, AreaMonthReportVo areaMonthReport) { + areaMonthReport.setPredictPlanPower(0.0); + // 实际发电量 + List ids = areaStationList.stream().map(StationEntity::getId).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(ids)){ + return; + } + double oldActualPower = oldActualMap.entrySet().stream().filter(e -> ids.contains(e.getKey())).mapToDouble(Map.Entry::getValue).sum(); + double oldOldActualPower = oldOldActualMap.entrySet().stream().filter(e -> ids.contains(e.getKey())).mapToDouble(Map.Entry::getValue).sum(); + if(Math.abs(oldActualPower) <= 0 && Math.abs(oldOldActualPower) <= 0 ){ + return; + } + double predictPlanPower = BigDecimal.valueOf((oldActualPower + oldOldActualPower) / 2).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue(); + areaMonthReport.setPredictPlanPower(predictPlanPower); + } + + /** + * 安全检查 + * @param areas + * @param areaMonthReport + * @param startTime + * @param endTime + */ + private void securityCheck(List areas, AreaMonthReportVo areaMonthReport,String startTime,String endTime) { + areaMonthReport.setSafetyMeeting(0); + areaMonthReport.setSelfReport(0); + areaMonthReport.setSkillTrainy(0); + areaMonthReport.setSecurityCheck(0); + // 站点归属机构集合 + Map map = new HashMap<>(); + map.put("startDate", startTime); + map.put("endDate", endTime); + map.put("deptList", areas); + // 调用安全大检查fegin接口 + Map count = monthService.check(map); + if(MapUtils.isEmpty(count)){ + return; + } + // 安全生产会议 + areaMonthReport.setSafetyMeeting((Integer) count.get("safetyMeetingNum")); + // 月度自查报告 + areaMonthReport.setSelfReport((Integer) count.get("monthCheckNum")); + // 技能培训 + areaMonthReport.setSkillTrainy((Integer) count.get("skillsTrainingNum")); + // 安全大检查 + areaMonthReport.setSecurityCheck((Integer) count.get("bigCheckNum")); + } + + /** + * 获取设备试验数据 + * @param startTime + * @param endTime + * @param areas + * @param areaMonthReport + */ + private void getDeviceTry(String startTime,String endTime,List areas,AreaMonthReportVo areaMonthReport) { + areaMonthReport.setDeviceTry(0); + SafeEquipmentTrialDTO request = new SafeEquipmentTrialDTO(); + request.setDeptList(areas); + request.setStartTime(startTime); + request.setEndTime(endTime); + areaMonthReport.setDeviceTry(trialService.count(request)); + } + + /** + * 推送当月月报 + * + * @param map + * @param list + */ + private void sendMonthReport(Map> map, List list) { + if (MapUtils.isEmpty(map) || CollectionUtil.isEmpty(list)) { + return; + } + // 获取邮件接收人 + Dept dept = list.stream().min(Comparator.comparing(Dept::getDeptCategory)).get(); + if(ObjectUtil.isEmpty(dept)){ + return; + } + R> userR = userClient.userListByDeptId(dept.getId()); + if(!userR.isSuccess() && CollectionUtil.isEmpty(userR.getData())){ + return; + } + List userList = userR.getData().stream().filter(o->dept.getId().equals(o.getCreateDept())).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(userList)){ + return; + } + List mailList = userList.stream().map(User::getEmail).filter(StringUtil::isNotBlank).collect(Collectors.toList()); + if(CollectionUtil.isEmpty(mailList)){ + return; + } + // 获取月报数据 + List entityList = map.get(DateUtil.format(new Date(),"yyyy-MM")); + if (CollectionUtil.isEmpty(entityList)) { + return; + } + // 发送邮件 + MailPushDto pushDto = new MailPushDto(); + pushDto.setBusinessClassify("system"); + pushDto.setBusinessKey("Month_Report"); + pushDto.setSubject("水电站生产运行"); + Map param = new HashMap<>(); + param.put("templatePath", "/data/hzims/message/mail/template/stationRunMonthReport.html"); + Map parameters = new HashMap<>(); + parameters.put("data",entityList); + param.put("parameters", parameters); + pushDto.setExtras(param); + pushDto.setText("水电站生产运行月报内容"); + pushDto.setToAccount(mailList.toArray(new String[0])); + pushDto.setHtml(true); + pushDto.setCreateUser(userR.getData().get(0).getCreateUser()); + pushDto.setTenantId(dept.getTenantId()); + pushDto.setCreateDept(dept.getId()); + pushMsgClient.sendMail(pushDto); + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/CompanyService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/CompanyService.java new file mode 100644 index 0000000..ecdb769 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/CompanyService.java @@ -0,0 +1,11 @@ +package com.hnac.hzims.scheduled.service.safeproduct; + +import com.hnac.hzims.safeproduct.entity.CheckCompanyEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author ysj + */ +public interface CompanyService extends BaseService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/InstanceService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/InstanceService.java new file mode 100644 index 0000000..0581c6f --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/InstanceService.java @@ -0,0 +1,12 @@ +package com.hnac.hzims.scheduled.service.safeproduct; + +import com.hnac.hzims.safeproduct.entity.CheckItemInstanceEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * Created by Sam Huang 2022/5/6 8:28 + */ +public interface InstanceService extends BaseService { + + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/MonthService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/MonthService.java new file mode 100644 index 0000000..5582515 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/MonthService.java @@ -0,0 +1,14 @@ +package com.hnac.hzims.scheduled.service.safeproduct; + +import com.hnac.hzims.safeproduct.entity.CheckMonthEntity; +import org.springblade.core.mp.base.BaseService; + +import java.util.Map; + +/** + * @author ysj + */ +public interface MonthService extends BaseService { + + Map check(Map map); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/TrialService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/TrialService.java new file mode 100644 index 0000000..c472c89 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/TrialService.java @@ -0,0 +1,13 @@ +package com.hnac.hzims.scheduled.service.safeproduct; + +import com.hnac.hzims.safeproduct.dto.SafeEquipmentTrialDTO; +import com.hnac.hzims.safeproduct.entity.SafeEquipmentTrialEntity; +import org.springblade.core.mp.base.BaseService; + +/** + * @author ysj + */ +public interface TrialService extends BaseService { + + int count(SafeEquipmentTrialDTO trial); +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/CompanyServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/CompanyServiceImpl.java new file mode 100644 index 0000000..7004ad3 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/CompanyServiceImpl.java @@ -0,0 +1,19 @@ +package com.hnac.hzims.scheduled.service.safeproduct.impl; + +import com.hnac.hzims.safeproduct.entity.CheckCompanyEntity; +import com.hnac.hzims.scheduled.mapper.safeproduct.CompanyMapper; +import com.hnac.hzims.scheduled.service.safeproduct.CompanyService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author ysj + */ +@Service +@AllArgsConstructor +@Slf4j +public class CompanyServiceImpl extends BaseServiceImpl implements CompanyService { + +} diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/InstanceServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/InstanceServiceImpl.java new file mode 100644 index 0000000..1b44fa8 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/InstanceServiceImpl.java @@ -0,0 +1,19 @@ +package com.hnac.hzims.scheduled.service.safeproduct.impl; + +import com.hnac.hzims.safeproduct.entity.CheckItemInstanceEntity; +import com.hnac.hzims.scheduled.mapper.safeproduct.InstanceMapper; +import com.hnac.hzims.scheduled.service.safeproduct.InstanceService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springframework.stereotype.Service; + +/** + * @author ysj + */ +@Service +@AllArgsConstructor +@Slf4j +public class InstanceServiceImpl extends BaseServiceImpl implements InstanceService { + +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/MonthServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/MonthServiceImpl.java new file mode 100644 index 0000000..697e6c0 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/MonthServiceImpl.java @@ -0,0 +1,96 @@ +package com.hnac.hzims.scheduled.service.safeproduct.impl; + +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.hnac.hzims.safeproduct.entity.CheckCompanyEntity; +import com.hnac.hzims.safeproduct.entity.CheckItemInstanceEntity; +import com.hnac.hzims.safeproduct.entity.CheckMonthEntity; +import com.hnac.hzims.scheduled.mapper.safeproduct.MonthMapper; +import com.hnac.hzims.scheduled.service.safeproduct.CompanyService; +import com.hnac.hzims.scheduled.service.safeproduct.InstanceService; +import com.hnac.hzims.scheduled.service.safeproduct.MonthService; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.lang3.StringUtils; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.api.R; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.ObjectUtil; +import org.springframework.stereotype.Service; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.concurrent.atomic.AtomicInteger; + +/** + * @author ysj + */ +@Service +@AllArgsConstructor +@Slf4j +public class MonthServiceImpl extends BaseServiceImpl implements MonthService { + + private final CompanyService companyService; + private final InstanceService instanceService; + + @Override + public Map check(Map map) { + if (ObjectUtil.isEmpty(map)) { + return null; + } + Map result = new HashMap<>(); + String startDate = (String) map.get("startDate"); + String endDate = (String) map.get("endDate"); + List deptList = (List) map.get("deptList"); + String startMonth = startDate.substring(0, 7); + String endMonth = endDate.substring(0, 7); + //月度自查次数 + Wrapper wrapper = new LambdaQueryWrapper() {{ + in(CheckMonthEntity::getCreateDept, deptList); + between(CheckMonthEntity::getMonth, startMonth, endMonth); + }}; + List monthList = this.list(wrapper); + result.put("monthCheckNum", monthList != null ? monthList.size() : 0); + //公司大检查次数 + Wrapper wrapper1 = new LambdaQueryWrapper() {{ + in(CheckCompanyEntity::getCreateDept, deptList); + ge(CheckCompanyEntity::getStartTime, startDate); + le(CheckCompanyEntity::getEndTime, endDate); + }}; + List companyList = companyService.list(wrapper1); + result.put("bigCheckNum", companyList != null ? companyList.size() : 0); + + AtomicInteger safetyMeetingNum = new AtomicInteger(0); + AtomicInteger skillsTrainingNum = new AtomicInteger(0); + + if (CollectionUtil.isNotEmpty(monthList)) { + monthList.forEach(checkMonthEntity -> { + Long checkId = checkMonthEntity.getId(); + Wrapper wrapper2 = new LambdaQueryWrapper() {{ + eq(CheckItemInstanceEntity::getCheckId, checkId); + }}; + List list = instanceService.list(wrapper2); + if (CollectionUtil.isNotEmpty(list)) { + list.forEach(instanceEntity -> { + //安全生产会议检查项,系统统计情况不为空纳入统计次数 + if ("现场每月1次安全生产会议".equals(instanceEntity.getItem())) { + if (StringUtils.isNotEmpty(instanceEntity.getSystemSituation())) { + safetyMeetingNum.addAndGet(1); + } + } + //技能培训检查项,系统统计情况不为空纳入统计次数 + if ("每月开展1次技能培训".equals(instanceEntity.getItem())) { + if (StringUtils.isNotEmpty(instanceEntity.getSystemSituation())) { + skillsTrainingNum.addAndGet(1); + } + } + }); + } + }); + } + result.put("safetyMeetingNum", safetyMeetingNum.get()); + result.put("skillsTrainingNum", skillsTrainingNum.get()); + return result; + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/TrialServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/TrialServiceImpl.java new file mode 100644 index 0000000..37a2050 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/safeproduct/impl/TrialServiceImpl.java @@ -0,0 +1,50 @@ +package com.hnac.hzims.scheduled.service.safeproduct.impl; + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.hnac.hzims.safeproduct.dto.SafeEquipmentTrialDTO; +import com.hnac.hzims.safeproduct.entity.SafeEquipmentTrialEntity; +import com.hnac.hzims.scheduled.mapper.safeproduct.TrialMapper; +import com.hnac.hzims.scheduled.service.safeproduct.TrialService; +import lombok.RequiredArgsConstructor; +import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.utils.CollectionUtil; +import org.springblade.core.tool.utils.ObjectUtil; +import org.springframework.stereotype.Service; + +import java.util.Optional; + +/** + * @author ysj + */ +@Service +@RequiredArgsConstructor +public class TrialServiceImpl extends BaseServiceImpl implements TrialService { + + /** + * 时间区间机构的设备实验数据查询 + * @param trial + * @return + */ + @Override + public int count(SafeEquipmentTrialDTO trial) { + if (ObjectUtil.isEmpty(trial)) { + return 0; + } + QueryWrapper queryWrapper = new QueryWrapper() {{ + if (CollectionUtil.isEmpty(trial.getDeptList())) { + if (Optional.ofNullable(trial.getCreateDept()).isPresent()) { + eq("create_dept", trial.getCreateDept()); + } + } else { + in("create_dept", trial.getDeptList()); + } + if (Optional.ofNullable(trial.getStartTime()).isPresent()) { + gt("create_time", trial.getStartTime()); + } + if (Optional.ofNullable(trial.getEndTime()).isPresent()) { + lt("create_time", trial.getEndTime()); + } + }}; + return this.baseMapper.selectCount(queryWrapper); + } +} \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketService.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketService.java index 5716e58..ff5e1ad 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketService.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/TicketService.java @@ -2,7 +2,9 @@ package com.hnac.hzims.scheduled.service.ticket; import com.hnac.hzims.ticket.allTicket.vo.DoublePassRateVO; import com.hnac.hzims.ticket.standardTicket.entity.StandardTicketInfoEntity; +import com.hnac.hzims.ticket.workTicket.vo.TicketMonthVO; import org.springblade.core.mp.base.BaseService; +import org.springblade.core.tool.api.R; import java.time.LocalDateTime; import java.util.List; @@ -13,4 +15,6 @@ import java.util.List; public interface TicketService extends BaseService { DoublePassRateVO doublePassRate(List areas, LocalDateTime firstDateTime, LocalDateTime now); + + TicketMonthVO operateWork(String start, String end, List list); } diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java index 5e3bab9..62ef9a0 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/ticket/impl/TicketServiceImpl.java @@ -11,9 +11,11 @@ import com.hnac.hzims.ticket.allTicket.vo.DoublePassRateVO; import com.hnac.hzims.ticket.constants.TicketConstants; import com.hnac.hzims.ticket.standardTicket.entity.StandardTicketInfoEntity; import com.hnac.hzims.ticket.workTicket.entity.WorkTicketInfoEntity; +import com.hnac.hzims.ticket.workTicket.vo.TicketMonthVO; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springblade.core.mp.base.BaseServiceImpl; +import org.springblade.core.tool.api.R; import org.springblade.core.tool.utils.CollectionUtil; import org.springframework.stereotype.Service; @@ -85,4 +87,64 @@ public class TicketServiceImpl extends BaseServiceImpl list) { + TicketMonthVO ticket = new TicketMonthVO(); + // 操作票 + List operateList = this.list(new LambdaQueryWrapper() {{ + ge(StandardTicketInfoEntity::getCreateTime, start); + le(StandardTicketInfoEntity::getCreateTime, end); + in(StandardTicketInfoEntity::getCreateDept, list); + }}); + if (CollectionUtil.isEmpty(operateList)) { + ticket.setOperate(0); + ticket.setOperateQualify(0); + }else{ + ticket.setOperate(operateList.size()); + List operateIdList = operateList.stream().map(StandardTicketInfoEntity::getId).collect(Collectors.toList()); + // 查询合格评价 + List operateQualifyList = ticketEvaluateService.list(new LambdaQueryWrapper() {{ + in(TicketInfoEvaluateEntity::getTicketId, operateIdList); + eq(TicketInfoEvaluateEntity::getStatus, TicketConstants.TicketQualifiedEnum.Qualified.getCode()); + }}); + if (CollectionUtil.isEmpty(operateQualifyList)) { + ticket.setOperateQualify(0); + }else{ + ticket.setOperateQualify(operateQualifyList.size()); + } + } + // 工作票 + List works = workTicketService.list(new LambdaQueryWrapper() {{ + ge(WorkTicketInfoEntity::getCreateTime, start); + le(WorkTicketInfoEntity::getCreateTime, end); + in(WorkTicketInfoEntity::getCreateDept, list); + }}); + if (CollectionUtil.isEmpty(works)) { + ticket.setWork(0); + ticket.setWorkQualify(0); + }else{ + ticket.setWork(works.size()); + List workIds = works.stream().map(WorkTicketInfoEntity::getId).collect(Collectors.toList()); + // 查询合格评价 + List operateQualifyList = ticketEvaluateService.list(new LambdaQueryWrapper() {{ + in(TicketInfoEvaluateEntity::getTicketId, workIds); + eq(TicketInfoEvaluateEntity::getStatus, TicketConstants.TicketQualifiedEnum.Qualified.getCode()); + }}); + if (CollectionUtil.isEmpty(operateQualifyList)) { + ticket.setOperateQualify(0); + }else{ + ticket.setWorkQualify(operateQualifyList.size()); + } + } + return ticket; + } + } \ No newline at end of file diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/inspect/TaskMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/inspect/TaskMapper.xml new file mode 100644 index 0000000..9acf610 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/inspect/TaskMapper.xml @@ -0,0 +1,4 @@ + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/PhenomenonMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/PhenomenonMapper.xml new file mode 100644 index 0000000..e12c289 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/operation/PhenomenonMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/CompanyMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/CompanyMapper.xml new file mode 100644 index 0000000..63605a2 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/CompanyMapper.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/InstanceMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/InstanceMapper.xml new file mode 100644 index 0000000..1e19e05 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/InstanceMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/MonthMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/MonthMapper.xml new file mode 100644 index 0000000..38f7539 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/MonthMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/TrialMapper.xml b/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/TrialMapper.xml new file mode 100644 index 0000000..6fec5d0 --- /dev/null +++ b/hzims-service/hzims-scheduled/src/main/resources/mapper/safeproduct/TrialMapper.xml @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/report/vo/DutyDefectVO.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/report/vo/DutyDefectVO.java deleted file mode 100644 index 3e95f23..0000000 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/report/vo/DutyDefectVO.java +++ /dev/null @@ -1,17 +0,0 @@ -package com.hnac.hzims.operational.report.vo; - -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; - -@Data -public class DutyDefectVO{ - - @ApiModelProperty("缺陷总数") - private Integer defectSum; - - @ApiModelProperty("缺陷数") - private Integer defect; - - @ApiModelProperty("缺陷总数ID 按逗号分隔") - private String totalIds; -} diff --git a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.java b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.java deleted file mode 100644 index b7c4ba8..0000000 --- a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.java +++ /dev/null @@ -1,16 +0,0 @@ -package com.hnac.hzims.safeproduct.mapper; - -import com.baomidou.mybatisplus.core.mapper.BaseMapper; -import com.hnac.hzims.safeproduct.entity.CheckItemInstanceEntity; -import org.apache.ibatis.annotations.Param; - -import java.util.List; - -/** - * Created by Sam Huang 2022/5/6 8:23 - */ -public interface CheckItemInstanceMapper extends BaseMapper { - - List getCheckItemInstanceByMonth(@Param("months") List months, @Param("deptId") Long deptId); - -} diff --git a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.xml b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.xml deleted file mode 100644 index 4e2231b..0000000 --- a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - - diff --git a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/service/impl/CheckItemServiceImpl.java b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/service/impl/CheckItemServiceImpl.java index 0a8eed5..b80c3d7 100644 --- a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/service/impl/CheckItemServiceImpl.java +++ b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/service/impl/CheckItemServiceImpl.java @@ -6,7 +6,6 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.hnac.hzims.operational.duty.dto.ChangeShiftsReqDTO; import com.hnac.hzims.operational.duty.dto.ChangeShiftsRspDTO; -import com.hnac.hzims.operational.duty.entity.ImsDutyGroupEntity; import com.hnac.hzims.operational.duty.feign.IDutyRecClient; import com.hnac.hzims.operational.feign.IOperTaskClient; import com.hnac.hzims.safeproduct.dto.CheckItemDTO; @@ -27,7 +26,6 @@ import com.hnac.hzims.ticket.workTicket.feign.IOperateTicketClient; import com.hnac.hzims.ticket.workTicket.feign.ITicketInfoClient; import com.hnac.hzims.vo.SafeCheckStatisticVO; import com.hnac.hzinfo.inspect.task.feign.IInspectTaskClient; -import jodd.util.ArraysUtil; import lombok.AllArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang.StringUtils; @@ -43,7 +41,6 @@ import org.springblade.system.feign.ISysClient; import org.springblade.system.user.cache.UserCache; import org.springblade.system.user.entity.User; import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; import java.lang.reflect.Field; import java.time.LocalDateTime; From 24cafe06c04f5bb26ded32525f3d2771fcb404f1 Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Wed, 7 Jun 2023 14:36:36 +0800 Subject: [PATCH 14/14] =?UTF-8?q?#=E5=AE=9A=E6=97=B6=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E6=8A=BD=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../scheduled/mapper/safeproduct/InstanceMapper.java | 7 +------ .../safeproduct/mapper/CheckItemInstanceMapper.java | 16 ++++++++++++++++ .../safeproduct/mapper/CheckItemInstanceMapper.xml | 20 ++++++++++++++++++++ 3 files changed, 37 insertions(+), 6 deletions(-) create mode 100644 hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.java create mode 100644 hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.xml diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/InstanceMapper.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/InstanceMapper.java index 1dedec0..3e3d781 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/InstanceMapper.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/mapper/safeproduct/InstanceMapper.java @@ -2,15 +2,10 @@ package com.hnac.hzims.scheduled.mapper.safeproduct; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.hnac.hzims.safeproduct.entity.CheckItemInstanceEntity; -import org.apache.ibatis.annotations.Param; - -import java.util.List; /** - * Created by Sam Huang 2022/5/6 8:23 + * @author Lch */ public interface InstanceMapper extends BaseMapper { - List getCheckItemInstanceByMonth(@Param("months") List months, @Param("deptId") Long deptId); - } diff --git a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.java b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.java new file mode 100644 index 0000000..b7c4ba8 --- /dev/null +++ b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.java @@ -0,0 +1,16 @@ +package com.hnac.hzims.safeproduct.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.hnac.hzims.safeproduct.entity.CheckItemInstanceEntity; +import org.apache.ibatis.annotations.Param; + +import java.util.List; + +/** + * Created by Sam Huang 2022/5/6 8:23 + */ +public interface CheckItemInstanceMapper extends BaseMapper { + + List getCheckItemInstanceByMonth(@Param("months") List months, @Param("deptId") Long deptId); + +} diff --git a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.xml b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.xml new file mode 100644 index 0000000..4e2231b --- /dev/null +++ b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CheckItemInstanceMapper.xml @@ -0,0 +1,20 @@ + + + + + + + + +