2022-02-14 22:22:31 +08:00
|
|
|
<template>
|
2022-02-18 17:54:22 +08:00
|
|
|
<div class="cn-detection--list" :style="{zIndex: !isCollapse ? 1 : 'unset'}">
|
2022-02-14 22:22:31 +08:00
|
|
|
<!-- 左侧下拉按钮 -->
|
2022-02-18 17:54:22 +08:00
|
|
|
<div class="cn-detection__collapse">
|
2022-02-14 22:22:31 +08:00
|
|
|
<span @click="switchCollapse" :class="{'reg-down': !isCollapse}"><i class="cn-icon cn-icon-arrow-right"></i></span>
|
|
|
|
|
</div>
|
2022-02-18 17:54:22 +08:00
|
|
|
<div class="cn-detection__case">
|
|
|
|
|
<div class="cn-detection__icon" :style="`background-color: ${eventSeverityColor[detection.eventSecurity]}`">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cn-detection__row">
|
|
|
|
|
<div class="cn-detection__header">
|
|
|
|
|
<i class="cn-icon cn-icon-attacker" ></i>{{detection.offenderIp}}
|
|
|
|
|
<span class="line">-------</span>
|
|
|
|
|
<span class="circle"></span>
|
|
|
|
|
<i class="cn-icon cn-icon-attacked" ></i>{{detection.victimIp}}
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cn-detection__body">
|
2022-02-14 22:22:31 +08:00
|
|
|
<div class="body__basic-info">
|
|
|
|
|
<div class="basic-info">
|
|
|
|
|
<div class="basic-info__item">
|
2022-02-18 17:54:22 +08:00
|
|
|
<i class="cn-icon cn-icon-severity-level"></i>
|
|
|
|
|
<span>{{$t('detection.list.eventSecurity')}} : </span>
|
|
|
|
|
<span>{{detection.eventSecurity}}</span>
|
2022-02-14 22:22:31 +08:00
|
|
|
</div>
|
|
|
|
|
<div class="basic-info__item">
|
2022-02-18 17:54:22 +08:00
|
|
|
<i class="cn-icon cn-icon-event-type"></i>
|
|
|
|
|
<span>{{$t('detection.list.securityType')}} : </span>
|
|
|
|
|
<span>{{detection.securityType}}</span>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="basic-info__item" v-if="detection.malwareName && detection.malwareName.length > 0 ">
|
|
|
|
|
<i class="cn-icon cn-icon-trojan"></i>
|
|
|
|
|
<span>{{$t('detection.list.malwareName')}} : </span>
|
|
|
|
|
<span>{{detection.malwareName}}</span>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="basic-info__item" v-if="detection.cryptominingPool && detection.cryptominingPool.length > 0 ">
|
|
|
|
|
<i class="cn-icon cn-icon-mining-pool"></i>
|
|
|
|
|
<span>{{$t('detection.list.cryptominingPool')}} : </span>
|
|
|
|
|
<span>{{detection.cryptominingPool}}</span>
|
2022-02-14 22:22:31 +08:00
|
|
|
</div>
|
|
|
|
|
<div class="basic-info__item">
|
2022-02-18 17:54:22 +08:00
|
|
|
<i class="cn-icon cn-icon-time2"></i>
|
|
|
|
|
<span>{{$t('detection.list.startTime')}} : </span>
|
|
|
|
|
<span>{{ dayJs.tz(detection.startTime).format('YYYY-MM-DD HH:mm:ss') }}</span>
|
2022-02-14 22:22:31 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<el-collapse-transition>
|
2022-02-18 17:54:22 +08:00
|
|
|
<div class="cn-detection__detail-overview" v-if="!isCollapse">
|
2022-02-14 22:22:31 +08:00
|
|
|
<el-divider></el-divider>
|
|
|
|
|
<detection-overview
|
2022-02-22 15:59:30 +08:00
|
|
|
:detection="detection"
|
2022-02-14 22:22:31 +08:00
|
|
|
:time-filter="timeFilter"
|
|
|
|
|
></detection-overview>
|
|
|
|
|
</div>
|
|
|
|
|
</el-collapse-transition>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
import DetectionOverview from '@/views/detections/DetectionOverview'
|
|
|
|
|
export default {
|
|
|
|
|
name: 'DetectionRow',
|
|
|
|
|
components: {
|
|
|
|
|
DetectionOverview
|
|
|
|
|
},
|
|
|
|
|
props: {
|
|
|
|
|
index: Number,
|
2022-02-18 17:54:22 +08:00
|
|
|
timeFilter: Object,
|
|
|
|
|
detection: Object
|
2022-02-14 22:22:31 +08:00
|
|
|
},
|
|
|
|
|
data () {
|
|
|
|
|
return {
|
2022-02-18 17:54:22 +08:00
|
|
|
isCollapse: true, // 是否是折叠状态
|
|
|
|
|
eventSeverityColor: {
|
|
|
|
|
critical: '#D84C4C',
|
|
|
|
|
high: '#FE845D',
|
|
|
|
|
medium: '#FFB65A',
|
|
|
|
|
low: '#FFD82D',
|
|
|
|
|
info: '#D1BD50'
|
|
|
|
|
}
|
2022-02-14 22:22:31 +08:00
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
/* 切换折叠状态 */
|
|
|
|
|
switchCollapse () {
|
|
|
|
|
this.isCollapse = !this.isCollapse
|
|
|
|
|
this.$emit('switchCollapse', this.isCollapse, this.index)
|
|
|
|
|
},
|
|
|
|
|
/* 设为折叠状态 */
|
|
|
|
|
collapse () {
|
|
|
|
|
this.isCollapse = true
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</script>
|