ISCS添加下行状态处理

This commit is contained in:
fan 2021-09-14 14:47:45 +08:00
parent 79439f4a28
commit ce9f11d55e

View File

@ -183,51 +183,95 @@ class Iscs {
// 义乌项目暂时写死 // 义乌项目暂时写死
if (elem.deviceType === 'IBP') { if (elem.deviceType === 'IBP') {
if (this.iscsDevice['IscsCircle_20']) { if (this.iscsDevice['IscsCircle_20']) {
elem.upStatus.operate ? this.iscsDevice['IscsCircle_20'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_20'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_20'].model.fillColor = elem.upStatus.operate ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_20']); this.$painter.update(this.iscsDevice['IscsCircle_20']);
} }
if (this.iscsDevice['IscsCircle_24']) {
this.iscsDevice['IscsCircle_24'].model.fillColor = elem.downStatus.operate ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_24']);
}
if (this.iscsDevice['IscsCircle_17']) { if (this.iscsDevice['IscsCircle_17']) {
elem.upStatus.openCommand ? this.iscsDevice['IscsCircle_17'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_17'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_17'].model.fillColor = elem.upStatus.openCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_17']); this.$painter.update(this.iscsDevice['IscsCircle_17']);
} }
if (this.iscsDevice['IscsCircle_21']) {
this.iscsDevice['IscsCircle_21'].model.fillColor = elem.downStatus.openCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_21']);
}
if (this.iscsDevice['IscsCircle_18']) { if (this.iscsDevice['IscsCircle_18']) {
elem.upStatus.openSideCommand ? this.iscsDevice['IscsCircle_18'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_18'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_18'].model.fillColor = elem.upStatus.openSideCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_18']); this.$painter.update(this.iscsDevice['IscsCircle_18']);
} }
if (this.iscsDevice['IscsCircle_22']) {
this.iscsDevice['IscsCircle_22'].model.fillColor = elem.downStatus.openSideCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_22']);
}
if (this.iscsDevice['IscsCircle_19']) { if (this.iscsDevice['IscsCircle_19']) {
elem.upStatus.closeCommand ? this.iscsDevice['IscsCircle_19'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_19'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_19'].model.fillColor = elem.upStatus.closeCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_19']); this.$painter.update(this.iscsDevice['IscsCircle_19']);
} }
if (this.iscsDevice['IscsCircle_23']) {
this.iscsDevice['IscsCircle_23'].model.fillColor = elem.downStatus.closeCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_23']);
}
} else if (elem.deviceType === 'PSL') { } else if (elem.deviceType === 'PSL') {
if (this.iscsDevice['IscsCircle_12']) { if (this.iscsDevice['IscsCircle_12']) {
elem.upStatus.operate ? this.iscsDevice['IscsCircle_12'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_12'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_12'].model.fillColor = elem.upStatus.operate ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_12']); this.$painter.update(this.iscsDevice['IscsCircle_12']);
} }
if (this.iscsDevice['IscsCircle_13']) {
this.iscsDevice['IscsCircle_13'].model.fillColor = elem.downStatus.operate ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_13']);
}
if (this.iscsDevice['IscsCircle_9']) { if (this.iscsDevice['IscsCircle_9']) {
elem.upStatus.openCommand ? this.iscsDevice['IscsCircle_9'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_9'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_9'].model.fillColor = elem.upStatus.openCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_9']); this.$painter.update(this.iscsDevice['IscsCircle_9']);
} }
if (this.iscsDevice['IscsCircle_14']) {
this.iscsDevice['IscsCircle_14'].model.fillColor = elem.downStatus.openCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_14']);
}
if (this.iscsDevice['IscsCircle_35']) { if (this.iscsDevice['IscsCircle_35']) {
elem.upStatus.closeCommand ? this.iscsDevice['IscsCircle_35'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_35'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_35'].model.fillColor = elem.upStatus.closeCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_35']); this.$painter.update(this.iscsDevice['IscsCircle_35']);
} }
if (this.iscsDevice['IscsCircle_36']) {
this.iscsDevice['IscsCircle_36'].model.fillColor = elem.downStatus.closeCommand ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_36']);
}
if (this.iscsDevice['IscsCircle_37']) { if (this.iscsDevice['IscsCircle_37']) {
elem.upStatus.interlockRelease ? this.iscsDevice['IscsCircle_37'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_37'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_37'].model.fillColor = elem.upStatus.interlockRelease ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_37']); this.$painter.update(this.iscsDevice['IscsCircle_37']);
} }
if (this.iscsDevice['IscsCircle_38']) {
this.iscsDevice['IscsCircle_38'].model.fillColor = elem.downStatus.interlockRelease ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_38']);
}
} else if (elem.deviceType === 'SAFETY_CIRCLE') { } else if (elem.deviceType === 'SAFETY_CIRCLE') {
if (this.iscsDevice['IscsCircle_26']) { if (this.iscsDevice['IscsCircle_26']) {
elem.upStatus.pfdcFault ? this.iscsDevice['IscsCircle_26'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_26'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_26'].model.fillColor = elem.upStatus.pfdcFault ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_26']); this.$painter.update(this.iscsDevice['IscsCircle_26']);
} }
if (this.iscsDevice['IscsCircle_28']) {
this.iscsDevice['IscsCircle_28'].model.fillColor = elem.downStatus.pfdcFault ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_28']);
}
if (this.iscsDevice['IscsCircle_25']) { if (this.iscsDevice['IscsCircle_25']) {
elem.upStatus.busFault ? this.iscsDevice['IscsCircle_25'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_25'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_25'].model.fillColor = elem.upStatus.busFault ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_25']); this.$painter.update(this.iscsDevice['IscsCircle_25']);
} }
if (this.iscsDevice['IscsCircle_29']) {
this.iscsDevice['IscsCircle_29'].model.fillColor = elem.downStatus.busFault ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_29']);
}
if (this.iscsDevice['IscsCircle_27']) { if (this.iscsDevice['IscsCircle_27']) {
elem.upStatus.safetyCircle ? this.iscsDevice['IscsCircle_27'].model.fillColor = '#00CC00' : this.iscsDevice['IscsCircle_27'].model.fillColor = '#FF0000'; this.iscsDevice['IscsCircle_27'].model.fillColor = elem.upStatus.safetyCircle ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_27']); this.$painter.update(this.iscsDevice['IscsCircle_27']);
} }
if (this.iscsDevice['IscsCircle_30']) {
this.iscsDevice['IscsCircle_30'].model.fillColor = elem.downStatus.safetyCircle ? '#0C0' : '#F00';
this.$painter.update(this.iscsDevice['IscsCircle_30']);
}
} else if (elem.deviceType === 'SLIDING_DOOR') { } else if (elem.deviceType === 'SLIDING_DOOR') {
const upPsdCodeList = ['FuzhouPsd_33', 'FuzhouPsd_34', 'FuzhouPsd_35', 'FuzhouPsd_36', 'FuzhouPsd_41', 'FuzhouPsd_42', 'FuzhouPsd_43', 'FuzhouPsd_44', const upPsdCodeList = ['FuzhouPsd_33', 'FuzhouPsd_34', 'FuzhouPsd_35', 'FuzhouPsd_36', 'FuzhouPsd_41', 'FuzhouPsd_42', 'FuzhouPsd_43', 'FuzhouPsd_44',
'FuzhouPsd_61', 'FuzhouPsd_62', 'FuzhouPsd_63', 'FuzhouPsd_64', 'FuzhouPsd_69', 'FuzhouPsd_70', 'FuzhouPsd_71', 'FuzhouPsd_72', 'FuzhouPsd_65', 'FuzhouPsd_61', 'FuzhouPsd_62', 'FuzhouPsd_63', 'FuzhouPsd_64', 'FuzhouPsd_69', 'FuzhouPsd_70', 'FuzhouPsd_71', 'FuzhouPsd_72', 'FuzhouPsd_65',