Commit 1e9a21c6 authored by xinglei's avatar xinglei

修改科技处看不到科技处下面点巡检点问题

parent 2df5bea8
......@@ -825,19 +825,16 @@ class IndexMap extends Component {
if (code.indexOf('#') !== -1) {
let split = code.split('#') || [];
split.map(item => {
if (item.indexOf('-') !== -1) {
let array = item.split('-') || [];
if (array.length > 0 && array[0] === orgCode) {
xianshi = true;
}
} else {
if (item === orgCode) {
xianshi = true;
}
}
});
} else {
let arr = code.split('-') || [];
......@@ -846,22 +843,19 @@ class IndexMap extends Component {
}
}
}
return xianshi;
};
//处理告警数据
//处理告警数据
handleAlarmData = () => {
getAlarms().then(data => {
this.processingAlarmData(data);
});
}
//过滤告警列表
//过滤告警列表
processingAlarmData = data => {
debugger
let { orgCode } = this.state;
if (orgCode !== '') {
let dictionaryList = lsTool.read('dictionaryList');
......@@ -885,13 +879,13 @@ class IndexMap extends Component {
if (!utils.isEmpty(newData) && utils.isArray(newData)) {
const xianFlag = newData.some(e => {
// if (e.code === xianCode) {
if (e.code.startsWith(xianCode) || ((e.authOrg && e.authOrg.indexOf(xianCode) !== -1) || (e.authOrg && e.authOrg.indexOf(kejichuxianCode) !== -1))) {
if (e.code.startsWith(xianCode) || e.code.startsWith(kejichuxianCode) || ((e.authOrg && e.authOrg.indexOf(xianCode) !== -1) || (e.authOrg && e.authOrg.indexOf(kejichuxianCode) !== -1))) {
return true;
}
});
const xianyangFlag = newData.some(e => {
if (
e.code.startsWith(xianyangCode) ||
e.code.startsWith(xianyangCode) || e.code.startsWith(kejichuxianyangCode) ||
((e.authOrg && e.authOrg.indexOf(xianyangCode) !== -1) || (e.authOrg && e.authOrg.indexOf(kejichuxianyangCode) !== -1))
) {
return true;
......@@ -914,10 +908,8 @@ class IndexMap extends Component {
});
this.initBankInfoList('xian', null, false);
this.initBankInfoList('xianyang', null, false);
}
}
}
};
......@@ -928,8 +920,6 @@ class IndexMap extends Component {
this.handleAlarmData();
};
/**
* 根据告警city或者eqpId的重构数据
*
......@@ -954,7 +944,6 @@ class IndexMap extends Component {
* webSocket接收数据
*/
handleData = data => {
this.handleAlarmData();
};
......
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