Commit 91aa039b authored by 李纪文's avatar 李纪文

feat: 组态实时数据容错处理

parent 050b23ea
......@@ -1198,13 +1198,9 @@ const ConfigurationView = (props) => {
const pvList = list.dataList.find((arr) => {
return arr.dName === item.shName;
});
if (!bindList || item.stationName !== bindList.name) return false;
if (
!pvList ||
pvList.pv === null ||
pvList.dName !== item.shName ||
item.realVal === pvList.pv
)
if (!bindList || !pvList) return false;
if (item.stationName !== bindList.name) return false;
if (pvList.pv === null || pvList.dName !== item.shName || item.realVal === pvList.pv)
return false;
item.realVal = pvList.pv * 1;
const shRule = ruleOperation(item, item.realVal);
......@@ -1240,12 +1236,10 @@ const ConfigurationView = (props) => {
const pvList = list.dataList.find((arr) => {
return arr.dName === item.shName;
});
if (!bindList || item.stationName !== bindList.name) return false;
if (!bindList || !pvList) return false;
if (item.stationName !== bindList.name) return false;
if (
(!pvList ||
pvList.pv === null ||
pvList.dName !== item.shName ||
item.realVal === pvList.pv) &&
(pvList.pv === null || pvList.dName !== item.shName || item.realVal === pvList.pv) &&
pvList.dName !== item.stateName
)
return false;
......
......@@ -1169,13 +1169,9 @@ const ConfigurationView = (props) => {
const pvList = list.dataList.find((arr) => {
return arr.dName === item.shName;
});
if (!bindList || item.stationName !== bindList.name) return false;
if (
!pvList ||
pvList.pv === null ||
pvList.dName !== item.shName ||
item.realVal === pvList.pv
)
if (!bindList || !pvList) return false;
if (item.stationName !== bindList.name) return false;
if (pvList.pv === null || pvList.dName !== item.shName || item.realVal === pvList.pv)
return false;
item.realVal = pvList.pv * 1;
const shRule = ruleOperation(item, item.realVal);
......@@ -1211,12 +1207,10 @@ const ConfigurationView = (props) => {
const pvList = list.dataList.find((arr) => {
return arr.dName === item.shName;
});
if (!bindList || item.stationName !== bindList.name) return false;
if (!bindList || !pvList) return false;
if (item.stationName !== bindList.name) return false;
if (
(!pvList ||
pvList.pv === null ||
pvList.dName !== item.shName ||
item.realVal === pvList.pv) &&
(pvList.pv === null || pvList.dName !== item.shName || item.realVal === pvList.pv) &&
pvList.dName !== item.stateName
)
return false;
......
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