2021-12-14 16:42:45 +08:00
|
|
|
|
<template>
|
2022-03-17 16:52:21 +08:00
|
|
|
|
<div class="cn-entity--list" :style="{ zIndex: !isCollapse ? 1 : 'unset' }">
|
2021-12-16 18:22:47 +08:00
|
|
|
|
<!-- 左侧下拉按钮 -->
|
|
|
|
|
|
<div class="cn-entity__collapse">
|
2023-04-27 16:53:12 +08:00
|
|
|
|
<span @click="switchCollapse" :class="{ 'reg-down': !isCollapse }">
|
|
|
|
|
|
<i class="cn-icon cn-icon-arrow-right"></i>
|
|
|
|
|
|
</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="cn-entity__case">
|
|
|
|
|
|
<div class="cn-entity__icon"><i :class="iconClass"></i></div>
|
|
|
|
|
|
<div class="cn-entity__row">
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<!--标签-->
|
2023-09-19 13:52:38 +08:00
|
|
|
|
<div class="cn-entity__header" style="display: flex;">
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="cn-entity__header-title">{{ entityData.entityValue || 'Unknown' }}</span>
|
2023-09-19 13:52:38 +08:00
|
|
|
|
<span class="entity-detail" style="display: flex;margin-left: 6px;margin-top: 1px;flex-wrap: wrap;margin-bottom: -10px;">
|
|
|
|
|
|
<span v-for="(item, index) in levelTwoTags" :key="index" class="entity-tag entity-tag--small margin-r-10 margin-b-10" :class="`entity-tag--level-two-${item.type}`">
|
2023-07-07 17:22:51 +08:00
|
|
|
|
{{ item.value }}
|
|
|
|
|
|
</span>
|
|
|
|
|
|
</span>
|
2022-03-17 16:52:21 +08:00
|
|
|
|
</div>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
|
2021-12-16 18:22:47 +08:00
|
|
|
|
<div class="cn-entity__body">
|
|
|
|
|
|
<div class="body__basic-info">
|
|
|
|
|
|
<div class="basic-info">
|
|
|
|
|
|
<template v-if="entityData.entityType === 'ip'">
|
|
|
|
|
|
<div class="basic-info__item">
|
2021-12-31 10:55:49 +08:00
|
|
|
|
<i class="cn-icon cn-icon-country"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('overall.country') }} : </span>
|
2023-09-27 19:53:09 +08:00
|
|
|
|
<span class="row-item-value">{{ $_.get(entityData, 'location.country', '-') || '-' }}</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="basic-info__item">
|
|
|
|
|
|
<i class="cn-icon cn-icon-position"></i>
|
2023-08-18 09:32:58 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('overall.city') }} : </span>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-value">{{ entityData.location ? ipLocationRegion(entityData.location) : '-' }}</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="basic-info__item">
|
|
|
|
|
|
<i class="cn-icon cn-icon-cloud"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('entities.asn') }} : </span>
|
2023-09-27 19:53:09 +08:00
|
|
|
|
<span class="row-item-value">{{ $_.get(entityData, 'asn.asn', '-') || '-' }}</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
<template v-else-if="entityData.entityType === 'domain'">
|
|
|
|
|
|
<div class="basic-info__item">
|
2023-08-30 17:26:42 +08:00
|
|
|
|
<i class="cn-icon cn-icon-category-group"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('entities.category') }} : </span>
|
2023-09-27 19:53:09 +08:00
|
|
|
|
<span class="row-item-value">{{ $_.get(entityData, 'category.categoryGroup', '-') || '-' }}</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="basic-info__item">
|
2023-08-30 17:26:42 +08:00
|
|
|
|
<i class="cn-icon cn-icon-sub-category"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('entities.subcategory') }} : </span>
|
2023-09-27 19:53:09 +08:00
|
|
|
|
<span class="row-item-value">{{ $_.get(entityData, 'category.categoryName', '-') || '-' }}</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="basic-info__item">
|
2023-07-14 18:56:03 +08:00
|
|
|
|
<i class="cn-icon cn-icon-credit-rating"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('entities.reputationLevel') }} : </span>
|
2023-09-27 19:53:09 +08:00
|
|
|
|
<span class="row-item-value">{{ $_.get(entityData, 'category.reputationLevel', '-') || '-' }}</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
<template v-else-if="entityData.entityType === 'app'">
|
|
|
|
|
|
<div class="basic-info__item">
|
2023-08-30 17:26:42 +08:00
|
|
|
|
<i class="cn-icon cn-icon-category2"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('entities.category') }} : </span>
|
2023-09-27 19:53:09 +08:00
|
|
|
|
<span class="row-item-value">{{ $_.get(entityData, 'category.appCategory', '-') || '-' }}</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="basic-info__item">
|
2023-08-30 17:26:42 +08:00
|
|
|
|
<i class="cn-icon cn-icon-sub-category"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('entities.subcategory') }} : </span>
|
2023-09-27 19:53:09 +08:00
|
|
|
|
<span class="row-item-value">{{ $_.get(entityData, 'category.appSubcategory', '-') || '-' }}</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="basic-info__item">
|
2023-08-30 17:26:42 +08:00
|
|
|
|
<i class="cn-icon cn-icon-credit-rating"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('entities.risk') }} : </span>
|
|
|
|
|
|
<span class="row-item-value">{{ entityData.category ? appRisk(entityData.category.appRisk) : '-' }}</span>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
<!-- 通用字段 -->
|
|
|
|
|
|
<div class="basic-info__item">
|
2022-03-17 16:52:21 +08:00
|
|
|
|
<div class="item__box">
|
|
|
|
|
|
<i class="cn-icon cn-icon-rise"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('entities.sentThroughput') }} : </span>
|
|
|
|
|
|
<span class="row-item-value">
|
2023-04-27 16:53:12 +08:00
|
|
|
|
{{
|
2023-09-05 17:13:44 +08:00
|
|
|
|
valueToRangeValue(entityData.bytesSentRate, unitTypes.bps).join(' ') !=='- ' ? valueToRangeValue(entityData.bytesSentRate, unitTypes.bps).join(' ') : '-'
|
2023-04-27 16:53:12 +08:00
|
|
|
|
}}
|
|
|
|
|
|
</span>
|
2022-03-17 16:52:21 +08:00
|
|
|
|
<!-- 曲线-->
|
2022-04-27 14:52:25 +08:00
|
|
|
|
<div class="item-box-loading">
|
2022-05-26 17:14:00 +08:00
|
|
|
|
<loading :loading="loading" size="small"></loading>
|
2022-04-27 14:52:25 +08:00
|
|
|
|
<div
|
|
|
|
|
|
class="row__charts"
|
|
|
|
|
|
:id="`entityDetailSend${entityType}${listMode}`"
|
2023-04-27 16:53:12 +08:00
|
|
|
|
v-if="entityData.entityType === 'domain'">
|
|
|
|
|
|
</div>
|
2022-04-27 14:52:25 +08:00
|
|
|
|
<div
|
|
|
|
|
|
class="row__charts"
|
|
|
|
|
|
:id="`entityDetailSend${entityType}${listMode}`"
|
2023-04-27 16:53:12 +08:00
|
|
|
|
v-if="entityData.entityType === 'app'">
|
|
|
|
|
|
</div>
|
2022-04-27 14:52:25 +08:00
|
|
|
|
<div
|
|
|
|
|
|
class="row__charts"
|
|
|
|
|
|
:id="`entityDetailSend${entityType}${listMode}`"
|
2023-04-27 16:53:12 +08:00
|
|
|
|
v-if="entityData.entityType === 'ip'">
|
|
|
|
|
|
</div>
|
2022-04-27 14:52:25 +08:00
|
|
|
|
</div>
|
2022-03-17 16:52:21 +08:00
|
|
|
|
</div>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
2022-03-17 16:52:21 +08:00
|
|
|
|
|
2021-12-16 18:22:47 +08:00
|
|
|
|
<div class="basic-info__item">
|
2022-03-17 16:52:21 +08:00
|
|
|
|
<div class="item__box">
|
|
|
|
|
|
<i class="cn-icon cn-icon-fall"></i>
|
2023-07-07 17:22:51 +08:00
|
|
|
|
<span class="row-item-label">{{ $t('entities.receivedThroughput') }} : </span>
|
|
|
|
|
|
<span class="row-item-value">
|
2023-09-05 17:13:44 +08:00
|
|
|
|
{{ valueToRangeValue(entityData.bytesReceivedRate, unitTypes.bps).join(' ') !== '- ' ? valueToRangeValue(entityData.bytesReceivedRate, unitTypes.bps).join(' ') : '-' }}
|
2023-04-27 16:53:12 +08:00
|
|
|
|
</span>
|
2022-04-27 14:52:25 +08:00
|
|
|
|
<div class="item-box-loading">
|
2022-05-26 17:14:00 +08:00
|
|
|
|
<loading :loading="loading" size="small"></loading>
|
2022-04-27 14:52:25 +08:00
|
|
|
|
<div
|
2023-04-27 16:53:12 +08:00
|
|
|
|
class="row__charts"
|
|
|
|
|
|
:id="`entityDetailReceived${entityType}${listMode}`"
|
|
|
|
|
|
v-if="entityData.entityType === 'domain'">
|
|
|
|
|
|
</div>
|
2022-04-27 14:52:25 +08:00
|
|
|
|
<div
|
2023-04-27 16:53:12 +08:00
|
|
|
|
class="row__charts"
|
|
|
|
|
|
:id="`entityDetailReceived${entityType}${listMode}`"
|
|
|
|
|
|
v-if="entityData.entityType === 'app'">
|
|
|
|
|
|
</div>
|
2022-04-27 14:52:25 +08:00
|
|
|
|
<div
|
2023-04-27 16:53:12 +08:00
|
|
|
|
class="row__charts"
|
|
|
|
|
|
:id="`entityDetailReceived${entityType}${listMode}`"
|
|
|
|
|
|
v-if="entityData.entityType === 'ip'">
|
|
|
|
|
|
</div>
|
2022-04-27 14:52:25 +08:00
|
|
|
|
</div>
|
2022-03-17 16:52:21 +08:00
|
|
|
|
</div>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
2023-08-10 11:08:21 +08:00
|
|
|
|
|
|
|
|
|
|
<!--score分数-->
|
|
|
|
|
|
<div class="basic-info__item" style="display: flex;align-items: center;">
|
|
|
|
|
|
<i class="cn-icon cn-icon-Score"></i>
|
2023-08-10 11:31:46 +08:00
|
|
|
|
<div class="row-item-label">
|
|
|
|
|
|
<span class="row-item-label">{{ $t('network.score') }} : </span>
|
|
|
|
|
|
<span class="row-item-value" style="position: relative;">
|
|
|
|
|
|
<span v-if="!loadingNetworkQuality">{{ score }}</span>
|
|
|
|
|
|
<loading :loading="loadingNetworkQuality" size="small"></loading>
|
|
|
|
|
|
</span>
|
2023-08-10 11:08:21 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<!--事件数量,即Performance和security事件总和-->
|
|
|
|
|
|
<div class="basic-info__item" style="position: relative">
|
|
|
|
|
|
<div v-if="eventNum>0 && !loadingEvent" style="display: flex;align-items: center;">
|
|
|
|
|
|
<i class="cn-icon cn-icon-Event1"></i>
|
|
|
|
|
|
<div class="row-item-label">
|
|
|
|
|
|
<span class="row-item-label">{{ $t('dnsInsight.event') }} : </span>
|
|
|
|
|
|
<span class="row-item-value">{{ eventNum }}</span>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
2023-08-30 17:57:10 +08:00
|
|
|
|
<!-- <loading :loading="loadingEvent" size="small" style="width: 90px"></loading>-->
|
2023-08-10 11:08:21 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
2023-06-29 10:46:00 +08:00
|
|
|
|
<div class="new-show-detail">
|
|
|
|
|
|
<div @click="showDetail"><i class="cn-icon cn-icon-detail"></i>{{ $t('overall.detail') }} ></div>
|
|
|
|
|
|
<div @click="showGraph"><i class="cn-icon cn-icon-graph"></i>{{ $t('entities.graph') }} ></div>
|
|
|
|
|
|
</div>
|
2021-12-28 21:23:18 +08:00
|
|
|
|
<el-collapse-transition>
|
2022-01-11 11:20:17 +08:00
|
|
|
|
<div class="cn-entity__detail-overview" v-if="!isCollapse">
|
2021-12-28 21:23:18 +08:00
|
|
|
|
<el-divider></el-divider>
|
2023-07-13 17:40:54 +08:00
|
|
|
|
<detail-overview :entity="entityData" :time-filter="timeFilter" @reloadEntity="getEntity" />
|
2021-12-28 21:23:18 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</el-collapse-transition>
|
2021-12-16 18:22:47 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
2021-12-14 16:42:45 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
2021-12-28 21:23:18 +08:00
|
|
|
|
import DetailOverview from '@/views/entityExplorer/entityList/detailOverview/DetailOverview'
|
2022-03-27 13:04:47 +08:00
|
|
|
|
import entityListMixin from './entityListMixin'
|
2022-03-17 16:52:21 +08:00
|
|
|
|
import relatedServer from '@/mixins/relatedServer'
|
2022-04-27 14:52:25 +08:00
|
|
|
|
import Loading from '@/components/common/Loading'
|
2023-07-07 17:22:51 +08:00
|
|
|
|
import axios from 'axios'
|
|
|
|
|
|
import { api } from '@/utils/api'
|
|
|
|
|
|
import { entityDetailTags, psiphon3IpType } from '@/utils/constants'
|
|
|
|
|
|
import _ from 'lodash'
|
2022-03-17 16:52:21 +08:00
|
|
|
|
|
2021-12-14 16:42:45 +08:00
|
|
|
|
export default {
|
2021-12-16 18:22:47 +08:00
|
|
|
|
name: 'Row',
|
2021-12-17 20:56:25 +08:00
|
|
|
|
props: {
|
2021-12-31 10:40:37 +08:00
|
|
|
|
index: Number,
|
2022-03-27 13:04:47 +08:00
|
|
|
|
timeFilter: Object,
|
|
|
|
|
|
listMode: String
|
2021-12-17 20:56:25 +08:00
|
|
|
|
},
|
2021-12-28 21:23:18 +08:00
|
|
|
|
components: {
|
2022-04-27 14:52:25 +08:00
|
|
|
|
Loading,
|
2022-03-17 17:56:38 +08:00
|
|
|
|
DetailOverview
|
2021-12-28 21:23:18 +08:00
|
|
|
|
},
|
2022-03-27 13:04:47 +08:00
|
|
|
|
mixins: [entityListMixin, relatedServer],
|
2022-03-17 17:56:38 +08:00
|
|
|
|
data () {
|
2021-12-16 23:03:39 +08:00
|
|
|
|
return {
|
2022-04-27 14:52:25 +08:00
|
|
|
|
loading: false,
|
2023-07-07 17:22:51 +08:00
|
|
|
|
isCollapse: true, // 是否是折叠状态
|
2023-08-10 11:08:21 +08:00
|
|
|
|
levelTwoTags: [],
|
|
|
|
|
|
loadingNetworkQuality: false // 分数的loading
|
2021-12-16 23:03:39 +08:00
|
|
|
|
}
|
|
|
|
|
|
},
|
2022-02-25 13:33:54 +08:00
|
|
|
|
computed: {
|
2022-03-17 17:56:38 +08:00
|
|
|
|
ipLocationRegion () {
|
2022-02-25 13:33:54 +08:00
|
|
|
|
return function (entityData) {
|
2022-03-17 16:52:21 +08:00
|
|
|
|
const hasProvinceAndCity =
|
2023-07-07 17:22:51 +08:00
|
|
|
|
entityData.province &&
|
|
|
|
|
|
entityData.city &&
|
|
|
|
|
|
entityData.province !== 'null' &&
|
|
|
|
|
|
entityData.city !== 'null'
|
2022-03-17 16:52:21 +08:00
|
|
|
|
const hasProvince =
|
2023-07-07 17:22:51 +08:00
|
|
|
|
entityData.province &&
|
|
|
|
|
|
entityData.province !== 'null'
|
2022-03-17 16:52:21 +08:00
|
|
|
|
const hasCity =
|
2023-07-07 17:22:51 +08:00
|
|
|
|
entityData.city && entityData.city !== 'null'
|
2022-02-25 13:33:54 +08:00
|
|
|
|
if (hasProvinceAndCity) {
|
2023-07-07 17:22:51 +08:00
|
|
|
|
return `${entityData.province}, ${entityData.city}`
|
2022-02-25 13:33:54 +08:00
|
|
|
|
} else if (hasProvince) {
|
2023-07-07 17:22:51 +08:00
|
|
|
|
return entityData.province
|
2022-02-25 13:33:54 +08:00
|
|
|
|
} else if (hasCity) {
|
2023-07-07 17:22:51 +08:00
|
|
|
|
return entityData.city
|
2022-02-25 13:33:54 +08:00
|
|
|
|
} else {
|
|
|
|
|
|
return '-'
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2022-01-05 23:56:27 +08:00
|
|
|
|
}
|
|
|
|
|
|
},
|
2023-07-07 17:22:51 +08:00
|
|
|
|
mounted () {
|
2023-09-27 18:31:01 +08:00
|
|
|
|
setTimeout(() => {
|
|
|
|
|
|
this.initData()
|
|
|
|
|
|
}, 1000)
|
|
|
|
|
|
setTimeout(() => {
|
|
|
|
|
|
this.initTagsData()
|
|
|
|
|
|
})
|
2023-07-07 17:22:51 +08:00
|
|
|
|
},
|
2021-12-16 23:03:39 +08:00
|
|
|
|
methods: {
|
2023-07-07 17:22:51 +08:00
|
|
|
|
initData () {
|
|
|
|
|
|
let url = ''
|
|
|
|
|
|
switch (this.entity.entityType) {
|
|
|
|
|
|
case ('domain'): {
|
|
|
|
|
|
url = api.entity.entityList.domainBasicInfo
|
|
|
|
|
|
break
|
|
|
|
|
|
}
|
|
|
|
|
|
case ('ip'): {
|
|
|
|
|
|
url = api.entity.entityList.ipBasicInfo
|
|
|
|
|
|
break
|
|
|
|
|
|
}
|
|
|
|
|
|
case ('app'): {
|
|
|
|
|
|
url = api.entity.entityList.appBasicInfo
|
|
|
|
|
|
break
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
axios.get(`${url}?resource=${this.entity.entityValue}`).then(response => {
|
|
|
|
|
|
this.$nextTick(() => {
|
2023-09-28 10:01:13 +08:00
|
|
|
|
this.entityData = { ...this.entityData, ...response.data.data, ...this.entity }
|
2023-07-07 17:22:51 +08:00
|
|
|
|
})
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
initTagsData () {
|
|
|
|
|
|
let url = ''
|
|
|
|
|
|
switch (this.entity.entityType) {
|
|
|
|
|
|
case ('domain'): {
|
|
|
|
|
|
url = api.entity.entityList.domainTags
|
|
|
|
|
|
break
|
|
|
|
|
|
}
|
|
|
|
|
|
case ('ip'): {
|
|
|
|
|
|
url = api.entity.entityList.ipTags
|
|
|
|
|
|
break
|
|
|
|
|
|
}
|
|
|
|
|
|
case ('app'): {
|
|
|
|
|
|
url = api.entity.entityList.appTags
|
|
|
|
|
|
break
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
axios.get(`${url}?resource=${this.entity.entityValue}`).then(responese => {
|
|
|
|
|
|
const res = responese.data
|
2023-08-27 20:34:24 +08:00
|
|
|
|
if (responese.status === 200) {
|
2023-07-07 17:22:51 +08:00
|
|
|
|
Object.keys(res.data).forEach(k => {
|
|
|
|
|
|
if (k !== 'userDefinedTags' && res.data[k]) {
|
|
|
|
|
|
Object.keys(res.data[k]).forEach(k2 => {
|
|
|
|
|
|
const find = entityDetailTags[this.entity.entityType].find(t => t.name === k2)
|
|
|
|
|
|
if (find) {
|
|
|
|
|
|
this.levelTwoTags.push({ key: k2, value: this.tagValueHandler(k, k2, res.data[k][k2]), type: find.type })
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
if (_.isArray(res.data.userDefinedTags)) {
|
|
|
|
|
|
this.levelTwoTags = _.concat(this.levelTwoTags, res.data.userDefinedTags.map(tag => ({ value: tag.tagValue, type: 'normal' })))
|
|
|
|
|
|
}
|
|
|
|
|
|
this.hideTagArea = _.isEmpty(this.levelTwoTags)
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
tagValueHandler (k, k2, value) {
|
|
|
|
|
|
if (k === 'psiphon3Ip') {
|
|
|
|
|
|
if (k2 === 'type') {
|
|
|
|
|
|
const find = psiphon3IpType.find(t => t.value === value)
|
|
|
|
|
|
if (find) {
|
|
|
|
|
|
return find.name
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
return value
|
|
|
|
|
|
},
|
2021-12-28 21:23:18 +08:00
|
|
|
|
/* 切换折叠状态 */
|
2022-03-17 17:56:38 +08:00
|
|
|
|
switchCollapse () {
|
2021-12-16 23:03:39 +08:00
|
|
|
|
this.isCollapse = !this.isCollapse
|
2021-12-28 21:23:18 +08:00
|
|
|
|
this.$emit('switchCollapse', this.isCollapse, this.index)
|
2021-12-17 20:56:25 +08:00
|
|
|
|
},
|
2021-12-28 21:23:18 +08:00
|
|
|
|
/* 设为折叠状态 */
|
2022-03-17 17:56:38 +08:00
|
|
|
|
collapse () {
|
2021-12-28 21:23:18 +08:00
|
|
|
|
this.isCollapse = true
|
2023-07-13 17:40:54 +08:00
|
|
|
|
},
|
|
|
|
|
|
getEntity (data) {
|
|
|
|
|
|
this.entityData = { ...data }
|
2022-03-17 17:56:38 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
2021-12-14 16:42:45 +08:00
|
|
|
|
}
|
|
|
|
|
|
</script>
|