Browse Source

fix:完善问题选项问题解析

zhongwei
haungxing 9 months ago
parent
commit
b1d321debb
  1. 14
      hzims-service/hzims-big-model/src/main/java/com/hnac/hzims/bigmodel/interactive/service/impl/ExtraResolveStrategyService.java

14
hzims-service/hzims-big-model/src/main/java/com/hnac/hzims/bigmodel/interactive/service/impl/ExtraResolveStrategyService.java

@ -16,6 +16,7 @@ import org.springblade.core.tool.utils.Func;
import org.springblade.core.tool.utils.StringUtil; import org.springblade.core.tool.utils.StringUtil;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.Optional; import java.util.Optional;
@ -56,11 +57,14 @@ public class ExtraResolveStrategyService {
private ExtraVO resolveDiagnose(Map<String,Object> extra) { private ExtraVO resolveDiagnose(Map<String,Object> extra) {
ExtraVO result = new ExtraVO(); ExtraVO result = new ExtraVO();
JSONObject data = JSONObject.parseObject(JSON.toJSONString(extra.get("data"))); JSONObject data = JSONObject.parseObject(JSON.toJSONString(extra.get("data")));
String faultId = data.getString("fault_id"); Map<String,Object> params = new HashMap<>(5);
String faultName = data.getString("fault_name"); params.put("faultId",data.getString("fault_id"));
result.setLabel(faultName); params.put("name",data.getString("fault_name"));
// TODO 拼接诊断链接 params.put("station",data.getString("station_id"));
result.setType(FunctionConstants.TypeEnum.LINK.getType()); params.put("fdpDeviceName",data.getString("device_name"));
params.put("fdpOrd",data.getString("ord"));
result.setParams(params);
result.setType(FunctionConstants.TypeEnum.PARAMS.getType());
return result; return result;
} }

Loading…
Cancel
Save