fix: 链路下钻相关接口参数调整

This commit is contained in:
chenjinsong
2022-10-14 16:02:14 +08:00
parent 2d2653b62c
commit 73eb942f31
2 changed files with 10 additions and 2 deletions

View File

@@ -156,7 +156,11 @@ export default {
endTime: getSecond(this.timeFilter.endTime)
}
if (this.queryCondition) {
params.q = this.queryCondition
const condition = this.queryCondition.toLowerCase().split(' or ')
if (condition.length > 1) {
params.egressParam = condition.find(c => c.indexOf('common_egress_link_id') > -1 || c.indexOf('egress_link_direction') > -1)
params.ingressParam = condition.find(c => c.indexOf('common_ingress_link_id') > -1 || c.indexOf('ingress_link_direction') > -1)
}
}
this.loading = true
get(api.linkMonitor.totalTrafficAnalysis, params).then((res) => {

View File

@@ -79,7 +79,11 @@ export default {
endTime: getSecond(this.timeFilter.endTime)
}
if (this.queryCondition) {
params.q = this.queryCondition
const condition = this.queryCondition.toLowerCase().split(' or ')
if (condition.length > 1) {
params.egressParam = condition.find(c => c.indexOf('common_egress_link_id') > -1 || c.indexOf('egress_link_direction') > -1)
params.ingressParam = condition.find(c => c.indexOf('common_ingress_link_id') > -1 || c.indexOf('ingress_link_direction') > -1)
}
}
this.loading = true
get(api.linkMonitor.networkAnalysis, params).then(res => {