From f9285b8a6f6023d61d200b751acf637603b1995c Mon Sep 17 00:00:00 2001 From: chenjinsong <523037378@qq.com> Date: Mon, 14 Feb 2022 22:22:31 +0800 Subject: [PATCH] =?UTF-8?q?CN-299=20feat:=20detection=E5=B8=83=E5=B1=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/css/components/index.scss | 1 + .../views/detections/detections.scss | 19 +++ src/router/index.js | 8 +- src/views/detections/DetectionFilter.vue | 11 ++ src/views/detections/DetectionList.vue | 76 +++++++++ src/views/detections/DetectionOverview.vue | 9 ++ src/views/detections/DetectionRow.vue | 75 +++++++++ src/views/detections/DetectionSearch.vue | 42 +++++ src/views/detections/Index.vue | 147 +++++++++++++++++- src/views/entityExplorer/EntityExplorer.vue | 11 +- src/views/entityExplorer/EntityFilter.vue | 2 +- .../entityExplorer/search/ExplorerSearch.vue | 2 +- 12 files changed, 385 insertions(+), 18 deletions(-) create mode 100644 src/assets/css/components/views/detections/detections.scss create mode 100644 src/views/detections/DetectionFilter.vue create mode 100644 src/views/detections/DetectionList.vue create mode 100644 src/views/detections/DetectionOverview.vue create mode 100644 src/views/detections/DetectionRow.vue create mode 100644 src/views/detections/DetectionSearch.vue diff --git a/src/assets/css/components/index.scss b/src/assets/css/components/index.scss index 82fa535f..ad16c89a 100644 --- a/src/assets/css/components/index.scss +++ b/src/assets/css/components/index.scss @@ -19,6 +19,7 @@ @import './views/entityExplorer/entityList/card'; @import './views/entityExplorer/entityList/row'; @import 'views/entityExplorer/entityList/detail-overview'; +@import './views/detections/detections'; @import './views/charts/panel'; @import 'views/charts/chartIpOpenPortBar'; @import './views/charts/chartTable'; diff --git a/src/assets/css/components/views/detections/detections.scss b/src/assets/css/components/views/detections/detections.scss new file mode 100644 index 00000000..e536d61a --- /dev/null +++ b/src/assets/css/components/views/detections/detections.scss @@ -0,0 +1,19 @@ +.detection__event-severity-bar { + flex: 0 0 175px; + background-color: white; + width: 100%; + margin-bottom: 10px; +} +.detection__list { + display: flex; + flex-direction: column; + flex: 1; + + .detection__list-statistics { + display: flex; + flex: 0 0 192px; + margin-bottom: 10px; + width: 100%; + background-color: white; + } +} diff --git a/src/router/index.js b/src/router/index.js index 580d0ec9..999a3a18 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -10,10 +10,6 @@ const routes = [ path: '/entityDetail', component: () => import('@/views/entityExplorer/EntityDetail') }, - { - path: '/detections', - component: () => import('@/views/detections/Index') - }, { path: '/', component: () => import('@/components/layout/Home'), @@ -42,6 +38,10 @@ const routes = [ path: '/entityExplorer', component: () => import('@/views/entityExplorer/EntityExplorer') }, + { + path: '/detections', + component: () => import('@/views/detections/Index') + }, { path: '/galaxyProxy', component: () => import('@/views/settings/GalaxyProxy') diff --git a/src/views/detections/DetectionFilter.vue b/src/views/detections/DetectionFilter.vue new file mode 100644 index 00000000..3703c50f --- /dev/null +++ b/src/views/detections/DetectionFilter.vue @@ -0,0 +1,11 @@ + + + diff --git a/src/views/detections/DetectionList.vue b/src/views/detections/DetectionList.vue new file mode 100644 index 00000000..d10a0f3b --- /dev/null +++ b/src/views/detections/DetectionList.vue @@ -0,0 +1,76 @@ + + + diff --git a/src/views/detections/DetectionOverview.vue b/src/views/detections/DetectionOverview.vue new file mode 100644 index 00000000..09125f11 --- /dev/null +++ b/src/views/detections/DetectionOverview.vue @@ -0,0 +1,9 @@ + + + diff --git a/src/views/detections/DetectionRow.vue b/src/views/detections/DetectionRow.vue new file mode 100644 index 00000000..63e2c856 --- /dev/null +++ b/src/views/detections/DetectionRow.vue @@ -0,0 +1,75 @@ + + + diff --git a/src/views/detections/DetectionSearch.vue b/src/views/detections/DetectionSearch.vue new file mode 100644 index 00000000..47dfffdc --- /dev/null +++ b/src/views/detections/DetectionSearch.vue @@ -0,0 +1,42 @@ + + + diff --git a/src/views/detections/Index.vue b/src/views/detections/Index.vue index cca35d85..f0b6ba52 100644 --- a/src/views/detections/Index.vue +++ b/src/views/detections/Index.vue @@ -1,13 +1,148 @@ - - diff --git a/src/views/entityExplorer/EntityExplorer.vue b/src/views/entityExplorer/EntityExplorer.vue index ed19c188..f6be8737 100644 --- a/src/views/entityExplorer/EntityExplorer.vue +++ b/src/views/entityExplorer/EntityExplorer.vue @@ -38,7 +38,7 @@ >
- - +
@@ -121,12 +121,12 @@ import DateTimeRange from '@/components/common/TimeRange/DateTimeRange' import TimeRefresh from '@/components/common/TimeRange/TimeRefresh' import EntityFilter from '@/views/entityExplorer/EntityFilter' import EntityList from '@/views/entityExplorer/entityList/EntityList' -import {entityType, entityFilterType, defaultPageSize, riskLevelMapping} from '@/utils/constants' +import { entityType, entityFilterType, defaultPageSize, riskLevelMapping } from '@/utils/constants' import { get } from '@/utils/http' import { api } from '@/utils/api' import { getNowTime, getSecond } from '@/utils/date-util' import { ref } from 'vue' -import pagination from '@/components/common/Pagination' +import Pagination from '@/components/common/Pagination' export default { name: 'entity-explorer', @@ -136,7 +136,7 @@ export default { TimeRefresh, EntityFilter, EntityList, - pagination: pagination + Pagination }, data () { return { @@ -155,7 +155,6 @@ export default { entityIpNew: '-', entityIpActive: '-', - showFilter: ['ip', 'app', 'domain'], // ip,domain,app pageObj: { pageNo: 1, pageSize: defaultPageSize, diff --git a/src/views/entityExplorer/EntityFilter.vue b/src/views/entityExplorer/EntityFilter.vue index 8ecb7081..8b07f0f5 100644 --- a/src/views/entityExplorer/EntityFilter.vue +++ b/src/views/entityExplorer/EntityFilter.vue @@ -1,5 +1,5 @@