From 1f941376ee0548a12791360aae269e3f6f23bd3e Mon Sep 17 00:00:00 2001 From: hyx Date: Thu, 8 Dec 2022 16:26:01 +0800 Subject: [PATCH] =?UTF-8?q?fix=EF=BC=9A=E5=8E=BB=E6=8E=89=E5=A4=9A?= =?UTF-8?q?=E4=BD=99=E9=87=8D=E5=A4=8D=E7=9A=84=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/tools.js | 10 ++++--- .../networkOverview/NetworkOverviewTabs.vue | 30 ------------------- 2 files changed, 6 insertions(+), 34 deletions(-) diff --git a/src/utils/tools.js b/src/utils/tools.js index aabd2639..bf4d5341 100644 --- a/src/utils/tools.js +++ b/src/utils/tools.js @@ -877,10 +877,12 @@ export async function getDnsMapData (type) { } return codeValueMap } -export function handleSpecialValue (value) { - value = value.replaceAll("'", "\\\\'") - .replaceAll('"', '\\"') - .replaceAll('&', '%26') +export function handleSpecialValue(value){ + if(value){ + value = value.replaceAll("'", "\\\\'") + .replaceAll('"','\\"') + .replaceAll('&','%26') + } return value } export function combineTabList (tableType, list, commonTabList) { diff --git a/src/views/charts2/charts/networkOverview/NetworkOverviewTabs.vue b/src/views/charts2/charts/networkOverview/NetworkOverviewTabs.vue index cb03278b..78654eca 100644 --- a/src/views/charts2/charts/networkOverview/NetworkOverviewTabs.vue +++ b/src/views/charts2/charts/networkOverview/NetworkOverviewTabs.vue @@ -951,36 +951,6 @@ export default { this.tableData = this.tableDataBackup } }, - // 切换metric:bit、packet、session - changeMetric () { - this.tableData = [] - this.tableDataBackup = [] - this.setShowNum(10) - const beforeType = this.getUrlParam(this.curTabState.tabOperationBeforeType, '', true) - if (beforeType && beforeType != operationType.thirdMenu) { - this.urlChangeParams[this.curTabState.tabOperationBeforeType] = this.getUrlParam(this.curTabState.tabOperationType, '', true) - } - this.urlChangeParams[this.curTabState.tabOperationType] = operationType.changeMetric - const curTab = this.getCurTab() - this.urlChangeParams[this.curTabState.tableMetric] = this.metric - - let queryParams = { - orderBy: this.orderBy, - limit: networkDefaultLimit, - type: curTab.prop - } - const condition = this.getQueryCondition() - if (condition) { - queryParams = { - orderBy: this.orderBy, - limit: networkDefaultLimit, - type: curTab.prop, - q: condition - } - } - this.changeUrlTabState() - this.getChartData(queryParams) - }, handleCustomizeButton (status) { this.showBackground = status if (!this.showCustomizeTabs) {