Commit 33ab2ed2 authored by KeYong's avatar KeYong

修改bug

parent ae9528bb
...@@ -3,7 +3,6 @@ package com.yeejoin.amos.fas.business.action; ...@@ -3,7 +3,6 @@ package com.yeejoin.amos.fas.business.action;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.yeejoin.amos.component.rule.MethodParam; import com.yeejoin.amos.component.rule.MethodParam;
import com.yeejoin.amos.component.rule.RuleActionBean; import com.yeejoin.amos.component.rule.RuleActionBean;
import com.yeejoin.amos.component.rule.RuleMethod; import com.yeejoin.amos.component.rule.RuleMethod;
...@@ -24,7 +23,6 @@ import com.yeejoin.amos.fas.business.dao.repository.IPlanOperationRecordDao; ...@@ -24,7 +23,6 @@ import com.yeejoin.amos.fas.business.dao.repository.IPlanOperationRecordDao;
import com.yeejoin.amos.fas.business.feign.RemoteSecurityService; import com.yeejoin.amos.fas.business.feign.RemoteSecurityService;
import com.yeejoin.amos.fas.business.service.impl.RuleRunigSnapshotServiceImpl; import com.yeejoin.amos.fas.business.service.impl.RuleRunigSnapshotServiceImpl;
import com.yeejoin.amos.fas.business.service.intfc.*; import com.yeejoin.amos.fas.business.service.intfc.*;
import com.yeejoin.amos.fas.business.service.model.ContingencyDeviceStatus;
import com.yeejoin.amos.fas.business.service.model.ToipResponse; import com.yeejoin.amos.fas.business.service.model.ToipResponse;
import com.yeejoin.amos.fas.business.util.JSONUtil; import com.yeejoin.amos.fas.business.util.JSONUtil;
import com.yeejoin.amos.fas.business.vo.ButtonJsonVO; import com.yeejoin.amos.fas.business.vo.ButtonJsonVO;
...@@ -100,9 +98,6 @@ public class ContingencyAction implements CustomerAction { ...@@ -100,9 +98,6 @@ public class ContingencyAction implements CustomerAction {
private ContingencyLogPublisher contingencyLogPublisher; private ContingencyLogPublisher contingencyLogPublisher;
@Autowired @Autowired
private IRiskSourceService riskSourceService;
@Autowired
private IEquipmentService equipmentService; private IEquipmentService equipmentService;
@Autowired @Autowired
......
...@@ -175,7 +175,7 @@ public class ContingencyPlanController extends BaseController { ...@@ -175,7 +175,7 @@ public class ContingencyPlanController extends BaseController {
vo.setUserName(user.getRealName()); vo.setUserName(user.getRealName());
ContingencyPlanResponseVo result= null; ContingencyPlanResponseVo result= null;
try { try {
result = contingencyPlanService.planStart(vo,toke); result = contingencyPlanService.planStart(vo, toke);
}catch (Exception e){ }catch (Exception e){
e.printStackTrace(); e.printStackTrace();
return CommonResponseUtil2.failure(); return CommonResponseUtil2.failure();
......
...@@ -56,6 +56,8 @@ import java.nio.charset.StandardCharsets; ...@@ -56,6 +56,8 @@ import java.nio.charset.StandardCharsets;
import java.util.*; import java.util.*;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import static org.typroject.tyboot.core.foundation.context.RequestContext.*;
@Service @Service
public class ContingencyInstanceImpl implements IContingencyInstance { public class ContingencyInstanceImpl implements IContingencyInstance {
...@@ -518,6 +520,13 @@ public class ContingencyInstanceImpl implements IContingencyInstance { ...@@ -518,6 +520,13 @@ public class ContingencyInstanceImpl implements IContingencyInstance {
} catch (IOException e) { } catch (IOException e) {
throw new RuntimeException("获取预案节点信息失败!"); throw new RuntimeException("获取预案节点信息失败!");
} }
if ("0".equals(stepCode)) {
contingencyInstance.fire(batchNo, stepCode, buttonJson, contingencyPlanId,
"FIRE_CONFIRM", buttonState, stepStateOnbutton, "true", "true", token,
product, appKey, startUserName);
}
JSONObject jsonObject = JSONObject.parseObject(json); JSONObject jsonObject = JSONObject.parseObject(json);
List<String> nodes = Arrays.stream(jsonObject.get("nodes").toString().split(",")).collect(Collectors.toList()); List<String> nodes = Arrays.stream(jsonObject.get("nodes").toString().split(",")).collect(Collectors.toList());
......
...@@ -722,6 +722,8 @@ public class PlanVisual3dServiceImpl implements IPlanVisual3dService { ...@@ -722,6 +722,8 @@ public class PlanVisual3dServiceImpl implements IPlanVisual3dService {
bool = contingencyPlanInstanceMapper.updateTaskStatusById(id, null, runStatus, userName, userId, img, PlanReplyMessageEnum.TEXT.getCode(), roleNames); bool = contingencyPlanInstanceMapper.updateTaskStatusById(id, null, runStatus, userName, userId, img, PlanReplyMessageEnum.TEXT.getCode(), roleNames);
} }
if (bool) { if (bool) {
if (redisTemplate.hasKey("planTask")) { if (redisTemplate.hasKey("planTask")) {
redisTemplate.delete("planTask"); redisTemplate.delete("planTask");
......
{ {
"nodes": "0,2,5,15,19" "nodes": "0,1,2,5,9,10,11",
"nodes_pyh": "0,2,5,15,19"
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment