Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bigDataSystem
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张伯涛
bigDataSystem
Commits
b61221c6
Commit
b61221c6
authored
Nov 26, 2024
by
liwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
事件中心页面
parent
2887457d
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
80 additions
and
42 deletions
+80
-42
LookLogModal.vue
src/views/realTimeSync/eventCenter/LookLogModal.vue
+29
-0
eventCenterData.ts
src/views/realTimeSync/eventCenter/eventCenterData.ts
+5
-5
index.vue
src/views/realTimeSync/eventCenter/index.vue
+46
-37
No files found.
src/views/realTimeSync/eventCenter/LookLogModal.vue
0 → 100644
View file @
b61221c6
<
template
>
<BasicModal
width=
"40%"
v-bind=
"$attrs"
@
register=
"registerModal"
:title=
"getTitle"
@
ok=
"handleSubmit"
>
<textarea
style=
"width: 100%;margin-top:20px;background-color: rgb(89, 96, 116);color: white"
readonly
rows=
"22"
v-model=
"textAreaData"
/>
</BasicModal>
</
template
>
<
script
lang=
"ts"
setup
>
import
{
ref
,
computed
,
unref
,
reactive
}
from
'vue'
;
import
{
BasicModal
,
useModalInner
}
from
'@/components/Modal'
;
import
{
BasicForm
,
useForm
}
from
'@/components/Form'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
defineOptions
({
name
:
'AccountModal'
});
const
emit
=
defineEmits
([
'success'
,
'register'
]);
const
{
createMessage
}
=
useMessage
();
const
getTitle
=
computed
(()
=>
(
'查看日志'
));
const
textAreaData
=
ref
(
'
\
n'
+
' 源端发生DDL事件,DDL处理策略为自动变更,自动启动源端'
)
//初始化弹框
const
[
registerModal
,
{
setModalProps
,
closeModal
}]
=
useModalInner
(
async
(
data
)
=>
{
setModalProps
({
confirmLoading
:
false
,
showOkBtn
:
false
,
cancelText
:
'关闭'
});
});
/**确定按钮*/
async
function
handleSubmit
()
{
closeModal
()
}
</
script
>
src/views/realTimeSync/eventCenter/eventCenterData.ts
View file @
b61221c6
...
...
@@ -44,14 +44,14 @@ export const tableData: any[] =[
taskName
:
'oracle-mysql'
,
eventType
:
'状态切换'
,
eventName
:
'源端任务启动'
,
syncPoint
:
'
mysql-bin.00203,41944023
'
syncPoint
:
'
-
'
},
{
startTime
:
'2023-06-28 20:25:36'
,
taskName
:
'oracle-mysql'
,
eventType
:
'状态切换'
,
eventName
:
'目标端任务启动'
,
syncPoint
:
'
mysql-bin.00203,41944023
'
syncPoint
:
'
-
'
},
{
startTime
:
'2023-06-28 20:14:26'
,
...
...
@@ -65,14 +65,14 @@ export const tableData: any[] =[
taskName
:
'oracle-mysql'
,
eventType
:
'状态切换'
,
eventName
:
'目标端任务启动'
,
syncPoint
:
'
mysql-bin.00203,41944023
'
syncPoint
:
'
-
'
},
{
startTime
:
'2023-06-28 20:12:32'
,
taskName
:
'oracle-mysql'
,
eventType
:
'状态切换'
,
eventName
:
'源端任务启动'
,
syncPoint
:
'
mysql-bin.00203,41944023
'
syncPoint
:
'
-
'
},
{
startTime
:
'2023-06-28 20:14:48'
,
...
...
@@ -93,7 +93,7 @@ export const tableData: any[] =[
taskName
:
'oracle-mysql'
,
eventType
:
'数据异常'
,
eventName
:
'源端任务启动'
,
syncPoint
:
'
-
'
syncPoint
:
'
mysql-bin.00203,41944023
'
},
{
startTime
:
'2023-06-28 20:23:24'
,
...
...
src/views/realTimeSync/eventCenter/index.vue
View file @
b61221c6
<
template
>
<div
style=
"width: 100%;height: 100%;background-color: white"
>
<div
style=
"width: 100%;height:30%"
>
<div
style=
"display: flex;height: 30px;margin-left: 20px;margin-top: 10px
"
>
<div
style=
"display: flex;align-items: center;font-weight: bold;font-size: 20px;
"
>
<div
class=
"eventCenterTop
"
>
<div
class=
"eventCenterTitle
"
>
<Icon
icon=
"ant-design:file-text-outlined"
:size=
"30"
:color=
"'#1091FE'"
/>
事件中心
</div>
...
...
@@ -109,9 +109,29 @@
</List>
</div>
<div
style=
"width: 75%"
>
<BasicTable
@
register=
"registerTable"
/>
<BasicTable
@
register=
"registerTable"
>
<
template
#
bodyCell=
"{ column, record }"
>
<template
v-if=
"column.key === 'action'"
>
<TableAction
:actions=
"[
{
label: '跳转任务运维',
onClick: toTaskMaintenanceButton.bind(null, record),
},
{
label: '查看日志',
onClick: lookLogButton.bind(null, record),
ifShow: record.eventType === '系统异常',
},
]"
/>
</
template
>
</template>
</BasicTable>
</div>
</div>
<!-- 查看日志 弹窗-->
<LookLogModal
@
register=
"registerLookLogModal"
@
success=
"handleSuccess"
/>
</div>
</template>
...
...
@@ -130,7 +150,7 @@
import
{
tableData
,
TreeData
,
cardList
}
from
'./eventCenterData'
import
{
BasicForm
,
useForm
}
from
'@/components/Form'
;
import
{
useECharts
}
from
'@/hooks/web/useECharts'
;
import
LookLogModal
from
'./LookLogModal.vue'
defineOptions
({
name
:
'AccountManagement'
});
const
chartRef
=
ref
<
HTMLDivElement
|
null
>
(
null
);
...
...
@@ -201,6 +221,7 @@
],
});
}
const
[
registerLookLogModal
,
{
openModal
:
openLookLogModal
}]
=
useModal
();
const
[
registerTable
,
{
reload
,
getForm
,
getRowSelection
}]
=
useTable
({
title
:
'所有任务'
,
api
:
async
(
params
)
=>
{
...
...
@@ -221,7 +242,7 @@
showIndexColumn
:
false
,
bordered
:
true
,
actionColumn
:
{
width
:
1
0
0
,
width
:
1
5
0
,
title
:
'操作'
,
dataIndex
:
'action'
,
},
...
...
@@ -242,42 +263,17 @@
selectedItem
.
value
=
item
;
}
/**
详情
按钮*/
function
detail
Button
(
record
){
/**
跳转任务运维
按钮*/
function
toTaskMaintenance
Button
(
record
){
router
.
push
({
path
:
'/realTimeSync/taskOperationsMaintenance/workDetail'
,
query
:
{
}
path
:
'/realTimeSync/taskOperationsMaintenance/index'
,
query
:
{}
});
}
/**修改 按钮*/
function
resetNameButton
(
record
){
openResetNameModal
(
true
,{
record
})
}
/**详情 按钮*/
function
showDetails
(
record
){
router
.
push
({
path
:
'/realTimeSync/taskOperationsMaintenance/workDetail'
,
query
:
{
}
});
}
/**启动 按钮*/
function
startButton
(
record
){
createMessage
.
success
(
'启动成功!'
)
}
/**暂停 按钮*/
function
stopButton
(
record
){
createMessage
.
success
(
'暂停成功!'
)
/**查看日志 按钮*/
function
lookLogButton
(
record
){
openLookLogModal
(
true
,{})
}
/** 转成树 */
...
...
@@ -392,4 +388,17 @@
display: flex;
align-items: center
}
.eventCenterTop{
display: flex;
height: 30px;
margin-left: 20px;
margin-top: 10px;
.eventCenterTitle{
display: flex;
align-items: center;
font-weight: bold;
font-size: 20px
}
}
</
style
>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment