diff --git a/src/views/charts2/charts/dnsInsight/DnsTrafficLine.vue b/src/views/charts2/charts/dnsInsight/DnsTrafficLine.vue index 9fdfc3fe..7ff9d86f 100644 --- a/src/views/charts2/charts/dnsInsight/DnsTrafficLine.vue +++ b/src/views/charts2/charts/dnsInsight/DnsTrafficLine.vue @@ -207,8 +207,9 @@ export default { { analysis: {}, name: 'network.inbound', class: 'inbound', show: true, invertTab: true, positioning: 1, data: [], unitType: '' }, { analysis: {}, name: 'network.outbound', class: 'outbound', show: true, invertTab: true, positioning: 2, data: [], unitType: '' } ] + } else { + this.initData(res.data.result, val, active, show) } - this.initData(res.data.result, val, active, show) } else { this.isNoData = false this.showError = true diff --git a/src/views/charts2/charts/linkMonitor/LinkTrafficLine.vue b/src/views/charts2/charts/linkMonitor/LinkTrafficLine.vue index d0797eaa..70b602b1 100644 --- a/src/views/charts2/charts/linkMonitor/LinkTrafficLine.vue +++ b/src/views/charts2/charts/linkMonitor/LinkTrafficLine.vue @@ -187,8 +187,9 @@ export default { { analysis: {}, name: 'linkMonitor.ingress', class: 'ingress', show: true, invertTab: true, positioning: 1, data: [], unitType: '' }, { analysis: {}, name: 'linkMonitor.egress', class: 'egress', show: true, invertTab: true, positioning: 2, data: [], unitType: '' } ] + } else { + this.initData(res.data.result, val, active, show) } - this.initData(res.data.result, val, active, show) } else { this.showError = true this.errorMsg = res.message diff --git a/src/views/charts2/charts/networkOverview/NetworkOverviewLine.vue b/src/views/charts2/charts/networkOverview/NetworkOverviewLine.vue index 49ec4cd6..dfb07c8f 100644 --- a/src/views/charts2/charts/networkOverview/NetworkOverviewLine.vue +++ b/src/views/charts2/charts/networkOverview/NetworkOverviewLine.vue @@ -221,8 +221,9 @@ export default { { analysis: {}, name: 'network.through', class: 'through', show: true, invertTab: true, positioning: 4, data: [], unitType: '' }, { analysis: {}, name: 'network.other', class: 'other', show: true, invertTab: true, positioning: 5, data: [], unitType: '' } ] + } else { + this.initData(res.data.result, val, active, show, n) } - this.initData(res.data.result, val, active, show, n) } else { this.showError = true this.errorMsg = res.message diff --git a/src/views/charts2/charts/npm/NpmTrafficLine.vue b/src/views/charts2/charts/npm/NpmTrafficLine.vue index 1c1b2bd7..b9fc97ba 100644 --- a/src/views/charts2/charts/npm/NpmTrafficLine.vue +++ b/src/views/charts2/charts/npm/NpmTrafficLine.vue @@ -215,8 +215,9 @@ export default { { name: this.$t('networkAppPerformance.packetLoss'), show: true, positioning: 0, data: [], unitType: unitTypes.percent, index: 3 }, { name: this.$t('overall.packetRetrans'), show: true, positioning: 0, data: [], unitType: unitTypes.percent, index: 4 } ] + } else { + this.initData(res.data.result, val) } - this.initData(res.data.result, val) } else { this.isNoData = false this.showError = true @@ -240,6 +241,10 @@ export default { res.forEach(item => { if (item.code === 200) { npmLineData.push(...item.data.result) + } else { + this.isNoData = false + this.showError = true + this.errorMsg = res.message } }) this.showError = false @@ -260,8 +265,9 @@ export default { { name: this.$t('networkAppPerformance.packetLoss'), show: true, positioning: 0, data: [], unitType: unitTypes.percent, index: 3 }, { name: this.$t('overall.packetRetrans'), show: true, positioning: 0, data: [], unitType: unitTypes.percent, index: 4 } ] + } else { + this.initData(npmLineData, val) } - this.initData(npmLineData, val) }).catch(e => { this.isNoData = false this.showError = true