Browse Source

#检修工作票流程变化更改

zhongwei
yang_shj 2 weeks ago
parent
commit
6c244f6e9e
  1. 2
      hzims-service/hzims-alarm/src/main/java/com/hnac/hzims/alarm/source/service/impl/MessageServiceImpl.java
  2. 13
      hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/accessTicket/service/impl/AccessTicketServiceImpl.java

2
hzims-service/hzims-alarm/src/main/java/com/hnac/hzims/alarm/source/service/impl/MessageServiceImpl.java

@ -82,10 +82,12 @@ public class MessageServiceImpl implements MessageService {
if(!session.getAttributes().containsKey("codes")){
return;
}
log.info("permission_message_session :{}",session.getId());
List<String> codes = (List<String>) session.getAttributes().get("codes");
if(CollectionUtil.isEmpty(codes) || !codes.contains(alarm.getStationId())){
return;
}
log.info("send_to_alarm_message :{}",session.getId());
try {
session.sendMessage(new TextMessage(JSONObject.toJSONString(Collections.singletonList(alarm))));
} catch (IOException e) {

13
hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/accessTicket/service/impl/AccessTicketServiceImpl.java

@ -115,12 +115,12 @@ public class AccessTicketServiceImpl extends ServiceImpl<AccessTicketMapper, Acc
// 危害因素及措施 reversal = 3
if("2".equals(reversal) && variables.containsKey("riskFactors")){
if("3".equals(reversal) && variables.containsKey("riskFactors")){
entity.setRiskFactors(variables.get("riskFactors").toString());
}
// 学习确认危险点 reversal = 4
if("3".equals(reversal)){
if("4".equals(reversal)){
if(variables.containsKey("studyHead")){
entity.setStudyHead(variables.get("studyHead").toString());
}
@ -130,13 +130,13 @@ public class AccessTicketServiceImpl extends ServiceImpl<AccessTicketMapper, Acc
}
// 审批签发 reversal = 5
if("4".equals(reversal) && variables.containsKey("issuePersonnel")){
if("5".equals(reversal) && variables.containsKey("issuePersonnel")){
entity.setIssueTime(new Date());
entity.setIssuePersonnel(variables.get("issuePersonnel").toString());
}
// 实际检修 reversal = 6
if("5".equals(reversal)){
if("6".equals(reversal)){
if(ObjectUtil.isNotEmpty(variables.get("access"))){
// 检修延期
if((Boolean) variables.get("access")){
@ -148,6 +148,7 @@ public class AccessTicketServiceImpl extends ServiceImpl<AccessTicketMapper, Acc
}
}else{
if(variables.containsKey("extensionTime")){
entity.setExtensionTime(DateUtil.parse(variables.get("extensionTime").toString(),DateUtil.PATTERN_DATETIME));
}
}
@ -155,12 +156,12 @@ public class AccessTicketServiceImpl extends ServiceImpl<AccessTicketMapper, Acc
}
// 检修延期 reversal = 7
if("6".equals(reversal) && variables.containsKey("extensionPersonnel")){
if("7".equals(reversal) && variables.containsKey("extensionPersonnel")){
entity.setExtensionPersonnel(variables.get("extensionPersonnel").toString());
}
// 检修验收 reversal = 8
if("7".equals(reversal) && variables.containsKey("checkPersonnel")){
if("8".equals(reversal) && variables.containsKey("checkPersonnel")){
entity.setCheckTime(new Date());
entity.setCheckPersonnel(variables.get("checkPersonnel").toString());
entity.setTaskName("流程结束");

Loading…
Cancel
Save