From d63bb64c2446ff4200af3dbabc9d91cd41764170 Mon Sep 17 00:00:00 2001 From: tyty Date: Wed, 22 Nov 2023 17:04:47 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E5=85=A9=E7=A5=A8pdf?= =?UTF-8?q?=E5=B1=95=E7=A4=BAbug=EF=BC=9A=E5=BA=8F=E5=8F=B7=E5=B1=95?= =?UTF-8?q?=E7=A4=BA=E6=9C=89=E9=97=AE=E9=A2=98=EF=BC=88=E5=90=AF=E5=8A=A8?= =?UTF-8?q?=E6=8A=A5=E9=94=99=E8=A7=A3=E5=86=B3=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../library/service/impl/TicketMatterGroupServiceImpl.java | 2 +- .../twoTicket/service/impl/TicketProcessServiceImpl.java | 13 ++++++------- .../workTicket/service/impl/OfflineTicketServiceImpl.java | 4 +--- 3 files changed, 8 insertions(+), 11 deletions(-) diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/library/service/impl/TicketMatterGroupServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/library/service/impl/TicketMatterGroupServiceImpl.java index 68b1ecb..73dfbc8 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/library/service/impl/TicketMatterGroupServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/library/service/impl/TicketMatterGroupServiceImpl.java @@ -626,7 +626,7 @@ public class TicketMatterGroupServiceImpl extends BaseServiceImpl resultMap = OperationWordHelper.resultMap(workTicketInfoMap); - String workTicketStatus = this.getWorkTicketStatus(status); + String workTicketStatus =getWorkTicketStatus(status); String os = TicketConstant.OS_NAME; //Windows操作系统 if (os != null && os.toLowerCase().startsWith("windows")) { 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 eee0811..44d27ce 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 @@ -10,7 +10,6 @@ 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.BusinessMessageDTO; -import com.hnac.hzims.message.dto.MessagePushRecordDto; import com.hnac.hzims.message.fegin.IMessageClient; import com.hnac.hzims.middle.process.feign.ProcessDictFeignService; import com.hnac.hzims.middle.process.to.ProcessWorkFlowResponse; @@ -59,7 +58,6 @@ 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; -import org.springframework.beans.BeanUtils; import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; @@ -963,7 +961,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { for (WorkTicketSafetyMeasureEntity measureVO : workTicketSafetyMeasureEntities) { String type = measureEnum.getType(); if (tempIndex != Integer.valueOf(type)) { - index = 1; +// index = 1; tempIndex++; } log.info("获取安全措施的信息: {}", measureVO); @@ -984,7 +982,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { //验证工作措施是有有数据 this.isMatterLibraryList(workTicketInfoMap1); // 工作地点保留带电部位或注意事项 - this.matterLibraryListWithMap(workTicketInfoMap1); + matterLibraryListWithMap(workTicketInfoMap1); result.putAll(workTicketInfoMap1); } @@ -1025,12 +1023,13 @@ public class TicketProcessServiceImpl implements TicketProcessService { List ticketInfoDangers = workTicketVo.getTicketInfoDangers(); if (CollectionUtils.isNotEmpty(ticketInfoDangers)) { Map>> map = new HashMap<>(); - int index = 1; + int[] index = {1}; List> collect = ticketInfoDangers.stream().map(item -> { Map newItem = new HashMap<>(); - newItem.put("index", index); + newItem.put("index", index[0]); newItem.put("maintenance", item.getMaintenance() == null ? "\u00A0" : item.getMaintenance()); newItem.put("dangerousPoint", item.getDangerousPoint() == null ? "\u00A0" : item.getDangerousPoint()); + index[0]++; return newItem; }).collect(Collectors.toList()); @@ -1041,7 +1040,7 @@ public class TicketProcessServiceImpl implements TicketProcessService { WordMapUtils.newMapWithList("ticketInfoDangers", result, true, 4, "maintenance", "dangerousPoint"); //7. 是否包含 - this.isExists(result); + isExists(result); //8. 存入新的数据 this.addMapPut(result); diff --git a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/workTicket/service/impl/OfflineTicketServiceImpl.java b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/workTicket/service/impl/OfflineTicketServiceImpl.java index ec5c331..179898e 100644 --- a/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/workTicket/service/impl/OfflineTicketServiceImpl.java +++ b/hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/workTicket/service/impl/OfflineTicketServiceImpl.java @@ -8,7 +8,6 @@ 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.twoTicket.constant.TicketConstant; import com.hnac.hzims.ticket.workTicket.dto.WorkTicketInfoDto; import com.hnac.hzims.ticket.workTicket.entity.WorkTicketContentEntity; import com.hnac.hzims.ticket.workTicket.entity.WorkTicketFlowEntity; @@ -40,7 +39,6 @@ import java.time.YearMonth; import java.time.format.DateTimeFormatter; import java.time.temporal.TemporalAdjusters; import java.util.List; -import java.util.Optional; import java.util.concurrent.locks.Lock; import java.util.concurrent.locks.ReentrantLock; import java.util.stream.Collectors; @@ -61,7 +59,7 @@ public class OfflineTicketServiceImpl extends BaseServiceImpl