fix: npm 下钻请求参数缺失
This commit is contained in:
@@ -66,15 +66,20 @@ export default {
|
|||||||
}
|
}
|
||||||
if (condition && (typeof condition !== 'object') && type) {
|
if (condition && (typeof condition !== 'object') && type) {
|
||||||
params.q = condition
|
params.q = condition
|
||||||
|
params.type = type
|
||||||
} else if (condition.length > 1 && type && type === 'ip') {
|
} else if (condition.length > 1 && type && type === 'ip') {
|
||||||
params.q = `${type}='${condition[1]}' and side='${this.side}'`
|
params.q = `${type}='${condition[1]}' and side='${this.side}'`
|
||||||
|
params.type = type
|
||||||
} else if (condition.length > 1 && type && type !== 'ip') {
|
} else if (condition.length > 1 && type && type !== 'ip') {
|
||||||
if (type === 'country' || type === 'asn' || type === 'province' || type === 'city' || type === 'isp') {
|
if (type === 'country' || type === 'asn' || type === 'province' || type === 'city' || type === 'isp') {
|
||||||
params.q = `${type}='${condition[1]}'`
|
params.q = `${type}='${condition[1]}'`
|
||||||
|
params.type = type
|
||||||
} else if (type === 'idcRenter') {
|
} else if (type === 'idcRenter') {
|
||||||
params.q = `idc_renter='${condition[1]}'`
|
params.q = `idc_renter='${condition[1]}'`
|
||||||
|
params.type = type
|
||||||
} else {
|
} else {
|
||||||
params.q = `${condition[0]}'${condition[1]}'`
|
params.q = `${condition[0]}'${condition[1]}'`
|
||||||
|
params.type = type
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
const tcp = get(api.npm.overview.tcpSessionDelay, params)
|
const tcp = get(api.npm.overview.tcpSessionDelay, params)
|
||||||
@@ -113,15 +118,20 @@ export default {
|
|||||||
}
|
}
|
||||||
if (condition && (typeof condition !== 'object') && type) {
|
if (condition && (typeof condition !== 'object') && type) {
|
||||||
params.q = condition
|
params.q = condition
|
||||||
|
params.type = type
|
||||||
} else if (condition.length > 1 && type && type === 'ip') {
|
} else if (condition.length > 1 && type && type === 'ip') {
|
||||||
params.q = `${type}='${condition[1]}' and side='${this.side}'`
|
params.q = `${type}='${condition[1]}' and side='${this.side}'`
|
||||||
|
params.type = type
|
||||||
} else if (condition.length > 1 && type && type !== 'ip') {
|
} else if (condition.length > 1 && type && type !== 'ip') {
|
||||||
if (type === 'country' || type === 'asn' || type === 'province' || type === 'city' || type === 'isp') {
|
if (type === 'country' || type === 'asn' || type === 'province' || type === 'city' || type === 'isp') {
|
||||||
params.q = `${type}='${condition[1]}'`
|
params.q = `${type}='${condition[1]}'`
|
||||||
|
params.type = type
|
||||||
} else if (type === 'idcRenter') {
|
} else if (type === 'idcRenter') {
|
||||||
params.q = `idc_renter='${condition[1]}'`
|
params.q = `idc_renter='${condition[1]}'`
|
||||||
|
params.type = type
|
||||||
} else {
|
} else {
|
||||||
params.q = `${condition[0]}'${condition[1]}'`
|
params.q = `${condition[0]}'${condition[1]}'`
|
||||||
|
params.type = type
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
const tcp = get(api.npm.overview.tcpSessionDelay, params)
|
const tcp = get(api.npm.overview.tcpSessionDelay, params)
|
||||||
|
|||||||
Reference in New Issue
Block a user