修改报错问题
This commit is contained in:
parent
61fdf8eb31
commit
a4ccf0c678
@ -43,18 +43,20 @@ export default {
|
||||
if (elem && (elem.hasOwnProperty('success') || elem.hasOwnProperty('timeout'))) {
|
||||
const operate = this.$store.state.training.operate;
|
||||
const control = this.$store.getters['map/getDeviceByCode'](elem.stationControlCode);
|
||||
const station = this.$store.getters['map/getDeviceByCode'](control.stationCode);
|
||||
const newOperate = {
|
||||
type: operate.type,
|
||||
name: station.name
|
||||
};
|
||||
if (control && control.stationCode) {
|
||||
const station = this.$store.getters['map/getDeviceByCode'](control.stationCode);
|
||||
const newOperate = {
|
||||
type: operate.type,
|
||||
name: station.name
|
||||
};
|
||||
|
||||
if (elem.timeout) {
|
||||
newOperate['msg'] = '请求超时';
|
||||
this.doShow(newOperate);
|
||||
} else if (!elem.success) {
|
||||
newOperate['msg'] = '请求拒绝';
|
||||
this.doShow(newOperate);
|
||||
if (elem.timeout) {
|
||||
newOperate['msg'] = '请求超时';
|
||||
this.doShow(newOperate);
|
||||
} else if (!elem.success) {
|
||||
newOperate['msg'] = '请求拒绝';
|
||||
this.doShow(newOperate);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user