|
|
@ -175,9 +175,9 @@ export default { |
|
|
|
const _this = this |
|
|
|
_this.iframeWin = this.$refs.myIframe.contentWindow |
|
|
|
// inframe 加载完成之后 |
|
|
|
// document.getElementById('myIframe').onload = function() { |
|
|
|
// _this.deviceState() |
|
|
|
// } |
|
|
|
document.getElementById('myIframe').onload = function() { |
|
|
|
_this.deviceState() |
|
|
|
} |
|
|
|
window.addEventListener('message', this.handleMessageDevice) |
|
|
|
}, |
|
|
|
methods: { |
|
|
@ -185,8 +185,9 @@ export default { |
|
|
|
getIframeLoading(value) { |
|
|
|
// console.log(`我是iframe传过来的参数:${value}`) |
|
|
|
if (value === 'false') { |
|
|
|
console.log(this.allDisplayConfigData) |
|
|
|
this.allDisplayConfigData.forEach(element => { |
|
|
|
if ((!element.isDisplay || !element.bindState) && element.divPosition.includes('CAM')) { |
|
|
|
if ((!element.isDisplay || !element.bindState) && element.divPosition.includes('OAO')) { |
|
|
|
this.handleHide(element.divPosition) |
|
|
|
} |
|
|
|
}) |
|
|
@ -264,8 +265,8 @@ export default { |
|
|
|
} |
|
|
|
this.oaoMessage.push({ |
|
|
|
id: element.divPosition, |
|
|
|
wendu: (wendu?.curvalue) ? (wendu?.curvalue) : '-', |
|
|
|
sidu: (sidu?.curvalue) ? (sidu?.curvalue) : '-', |
|
|
|
wendu: (wendu?.curvalue) ? (Math.round(wendu?.curvalue)) : '-', |
|
|
|
sidu: (sidu?.curvalue) ? (Math.round(sidu?.curvalue)) : '-', |
|
|
|
alarmState: (wendu && wendu.curstatus === '1') || (sidu && sidu.curstatus === '1') |
|
|
|
}) |
|
|
|
} |
|
|
|