CN-361 fix: 域名下拉异常
This commit is contained in:
@@ -62,6 +62,10 @@
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
|
||||
&>div {
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
.cn-alarm-info-bottom-middle {
|
||||
display: flex;
|
||||
margin-left: 20px;
|
||||
@@ -147,4 +151,4 @@
|
||||
height: 40px !important;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
.chart-list {
|
||||
.vue-grid-layout>.vue-grid-item {
|
||||
.cn-chart {
|
||||
height: 100% !important;
|
||||
.cn-chart__echarts {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
|
||||
.content__data {
|
||||
padding-bottom: 7%;
|
||||
font-size: 24px;
|
||||
font-size: 20px;
|
||||
color: #333333;
|
||||
font-weight: bold;
|
||||
}
|
||||
@@ -345,4 +345,4 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -213,7 +213,8 @@
|
||||
&>.cn-chart {
|
||||
position: relative;
|
||||
border-radius: 2px;
|
||||
height: 100%;
|
||||
flex-grow: 1;
|
||||
overflow: auto;
|
||||
width: 100%;
|
||||
.chart-drawing {
|
||||
height: 100%;
|
||||
|
||||
@@ -24,7 +24,7 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
getRelatedServerDataTow (relationshipUrlTow, refTow) {
|
||||
getRelatedServerDataTwo (relationshipUrlTow, refTow) {
|
||||
get(relationshipUrlTow, this.getQueryParams()).then(response => {
|
||||
if (response.code === 200) {
|
||||
const relationshipDataTwo = response.data.result
|
||||
|
||||
@@ -15,10 +15,10 @@
|
||||
</div>
|
||||
<div class="single-value__content">
|
||||
<div>
|
||||
<span>{{$t('entities.category')}}</span>
|
||||
<span style="color: #666;">{{$t('entities.category')}}</span>
|
||||
</div>
|
||||
<div>
|
||||
<span>{{$_.get(chartData, "category") || '-'}}</span>
|
||||
<span style="color: #333; font-weight: bold;">{{$_.get(chartData, "category") || '-'}}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -28,10 +28,10 @@
|
||||
</div>
|
||||
<div class="single-value__content">
|
||||
<div>
|
||||
<span>{{$t('entities.subcategory')}}</span>
|
||||
<span style="color: #666;">{{$t('entities.subcategory')}}</span>
|
||||
</div>
|
||||
<div>
|
||||
<span>{{$_.get(chartData, "subcategory") || '-'}}</span>
|
||||
<span style="color: #333; font-weight: bold;">{{$_.get(chartData, "subcategory") || '-'}}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -41,10 +41,10 @@
|
||||
</div>
|
||||
<div class="single-value__content">
|
||||
<div>
|
||||
<span>{{$t('entities.reputationLevel')}}</span>
|
||||
<span style="color: #666;">{{$t('entities.reputationLevel')}}</span>
|
||||
</div>
|
||||
<div>
|
||||
<span>{{$_.get(chartData, "risk") || '-'}}</span>
|
||||
<span style="color: #333; font-weight: bold;">{{$_.get(chartData, "risk") || '-'}}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -264,7 +264,7 @@ export default {
|
||||
const queryParams = {
|
||||
startTime: parseInt(this.timeFilter.startTime / 1000),
|
||||
endTime: parseInt(this.timeFilter.endTime / 1000),
|
||||
appName: this.entityData.appName
|
||||
appName: this.entity.appName
|
||||
}
|
||||
return queryParams
|
||||
},
|
||||
@@ -278,25 +278,10 @@ export default {
|
||||
this.chartData = response.data.result
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
entityData: {
|
||||
immediate: true,
|
||||
deep: true,
|
||||
handler (n) {
|
||||
if (n) {
|
||||
this.singleValues.chartDatas.splice(0, 1, this.$_.get(n, 'establishLatency'))
|
||||
this.singleValues.chartDatas.splice(1, 1, this.$_.get(n, 'httpResponseLatency'))
|
||||
this.singleValues.chartDatas.splice(2, 1, this.$_.get(n, 'sslConLatency'))
|
||||
this.singleValues.chartDatas.splice(3, 1, this.$_.get(n, 'sequenceGapLossPercent'))
|
||||
this.singleValues.chartDatas.splice(4, 1, this.$_.get(n, 'pktRetransPercent'))
|
||||
this.$nextTick(() => {
|
||||
this.getRelatedServerDataOne(this.relatedServerDomainUrl)
|
||||
this.getRelatedServerDataTow(this.relatedServerIpUrl)
|
||||
})
|
||||
}
|
||||
}
|
||||
},
|
||||
queryRelated () {
|
||||
this.getRelatedServerDataOne(this.relatedServerDomainUrl)
|
||||
this.getRelatedServerDataTwo(this.relatedServerIpUrl)
|
||||
}
|
||||
},
|
||||
mounted () {
|
||||
|
||||
@@ -272,7 +272,7 @@ export default {
|
||||
const queryParams = {
|
||||
startTime: parseInt(this.timeFilter.startTime / 1000),
|
||||
endTime: parseInt(this.timeFilter.endTime / 1000),
|
||||
domain: this.entityData.domainName
|
||||
domain: this.entity.domainName
|
||||
}
|
||||
return queryParams
|
||||
},
|
||||
@@ -290,28 +290,21 @@ export default {
|
||||
getBasicProperties () {
|
||||
get(this.basicProperties, this.getQueryParams()).then(response => {
|
||||
if (response.code === 200) {
|
||||
this.entityData = response.data.result
|
||||
this.entityData = {
|
||||
...this.entityData,
|
||||
domainCategory: response.data.result.domainCategory,
|
||||
domainCategoryGroup: response.data.result.domainCategoryGroup,
|
||||
domainDescription: response.data.result.domainDescription,
|
||||
domainReputationScore: response.data.result.domainReputationScore,
|
||||
domainWhoisAddress: response.data.result.domainWhoisAddress,
|
||||
domainWhoisOrg: response.data.result.domainWhoisOrg
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
entityData: {
|
||||
immediate: true,
|
||||
deep: true,
|
||||
handler (n) {
|
||||
if (n) {
|
||||
this.singleValues.chartDatas.splice(0, 1, this.$_.get(n, 'establishLatency'))
|
||||
this.singleValues.chartDatas.splice(1, 1, this.$_.get(n, 'httpResponseLatency'))
|
||||
this.singleValues.chartDatas.splice(2, 1, this.$_.get(n, 'sslConLatency'))
|
||||
this.singleValues.chartDatas.splice(3, 1, this.$_.get(n, 'sequenceGapLossPercent'))
|
||||
this.singleValues.chartDatas.splice(4, 1, this.$_.get(n, 'pktRetransPercent'))
|
||||
this.$nextTick(() => {
|
||||
this.getRelatedServerDataOne(this.relatedServerAppUrl)
|
||||
this.getRelatedServerDataTow(this.relatedServerIpUrl)
|
||||
})
|
||||
}
|
||||
}
|
||||
},
|
||||
queryRelated () {
|
||||
this.getRelatedServerDataOne(this.relatedServerAppUrl)
|
||||
this.getRelatedServerDataTwo(this.relatedServerIpUrl)
|
||||
}
|
||||
},
|
||||
mounted () {
|
||||
|
||||
@@ -4,11 +4,11 @@
|
||||
<div class="overview__content">
|
||||
<div class="overview__row">
|
||||
<div class="row__label row__label--width130">{{$t('overall.location')}}</div>
|
||||
<div class="row__content">{{entityData.ipLocationCountry || '-'}}</div>
|
||||
<div class="row__content">{{ipLocationRegion(entity)}}</div>
|
||||
</div>
|
||||
<div class="overview__row">
|
||||
<div class="row__label row__label--width130">ASN</div>
|
||||
<div class="row__content">{{entityData.ipAsn || '-'}}</div>
|
||||
<div class="row__content">{{entity.ipAsn || '-'}}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -252,12 +252,31 @@ export default {
|
||||
timer: null
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
ipLocationRegion () {
|
||||
return function (entityData) {
|
||||
const hasProvinceAndCity = entityData.ipLocationProvince && entityData.ipLocationCity &&
|
||||
entityData.ipLocationProvince !== 'null' && entityData.ipLocationCity !== 'null'
|
||||
const hasProvince = entityData.ipLocationProvince && entityData.ipLocationProvince !== 'null'
|
||||
const hasCity = entityData.ipLocationCity && entityData.ipLocationCity !== 'null'
|
||||
if (hasProvinceAndCity) {
|
||||
return `${entityData.ipLocationProvince}, ${entityData.ipLocationCity}`
|
||||
} else if (hasProvince) {
|
||||
return entityData.ipLocationProvince
|
||||
} else if (hasCity) {
|
||||
return entityData.ipLocationCity
|
||||
} else {
|
||||
return '-'
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
getQueryParams () {
|
||||
const queryParams = {
|
||||
startTime: parseInt(this.timeFilter.startTime / 1000),
|
||||
endTime: parseInt(this.timeFilter.endTime / 1000),
|
||||
ip: this.entityData.ipAddr
|
||||
ip: this.entity.ipAddr
|
||||
}
|
||||
return queryParams
|
||||
},
|
||||
@@ -271,24 +290,10 @@ export default {
|
||||
this.chartData = response.data.result
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
entityData: {
|
||||
deep: true,
|
||||
handler (n) {
|
||||
if (n) {
|
||||
this.singleValues.chartDatas.splice(0, 1, this.$_.get(n, 'establishLatency'))
|
||||
this.singleValues.chartDatas.splice(1, 1, this.$_.get(n, 'httpResponseLatency'))
|
||||
this.singleValues.chartDatas.splice(2, 1, this.$_.get(n, 'sslConLatency'))
|
||||
this.singleValues.chartDatas.splice(3, 1, this.$_.get(n, 'sequenceGapLossPercent'))
|
||||
this.singleValues.chartDatas.splice(4, 1, this.$_.get(n, 'pktRetransPercent'))
|
||||
this.$nextTick(() => {
|
||||
this.getRelatedServerDataOne(this.relatedServerDomainUrl)
|
||||
this.getRelatedServerDataTow(this.relatedServerAppUrl)
|
||||
})
|
||||
}
|
||||
}
|
||||
},
|
||||
queryRelated () {
|
||||
this.getRelatedServerDataOne(this.relatedServerDomainUrl)
|
||||
this.getRelatedServerDataTwo(this.relatedServerAppUrl)
|
||||
}
|
||||
},
|
||||
mounted () {
|
||||
|
||||
@@ -149,6 +149,12 @@ export default {
|
||||
this.entityData.sslConLatency = response.data.result.sslConLatency
|
||||
this.entityData.sequenceGapLossPercent = response.data.result.sequenceGapLossPercent
|
||||
this.entityData.pktRetransPercent = response.data.result.pktRetransPercent
|
||||
|
||||
this.singleValues.chartDatas.splice(0, 1, this.$_.get(this.entityData, 'establishLatency'))
|
||||
this.singleValues.chartDatas.splice(1, 1, this.$_.get(this.entityData, 'httpResponseLatency'))
|
||||
this.singleValues.chartDatas.splice(2, 1, this.$_.get(this.entityData, 'sslConLatency'))
|
||||
this.singleValues.chartDatas.splice(3, 1, this.$_.get(this.entityData, 'sequenceGapLossPercent'))
|
||||
this.singleValues.chartDatas.splice(4, 1, this.$_.get(this.entityData, 'pktRetransPercent'))
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -224,12 +230,13 @@ export default {
|
||||
|
||||
queryEntityDetail () {
|
||||
this.queryEntityDetailTraffic()
|
||||
this.queryEntityDetailRelation()
|
||||
// this.queryEntityDetailRelation()
|
||||
this.queryEntityDetailAlert()
|
||||
this.queryEntityDetailSecurity()
|
||||
this.queryEntityDetailNetworkQuantity()
|
||||
this.queryEntityDetailLinkOutUrl()
|
||||
this.queryEntityDetailLinkInUrl()
|
||||
this.queryRelated()
|
||||
}
|
||||
},
|
||||
setup () {
|
||||
@@ -241,7 +248,6 @@ export default {
|
||||
},
|
||||
mounted () {
|
||||
if (this.listMode === 'list') {
|
||||
this.entityData = _.cloneDeep(this.entity)
|
||||
this.chartOption = _.cloneDeep(entityListLineOption)
|
||||
setTimeout(() => { this.queryEntityDetail() })
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user