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
1fcf553e
Commit
1fcf553e
authored
Dec 04, 2024
by
冷玲鹏
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调度执行:修改页面bug
parent
8c4e2041
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
413 additions
and
316 deletions
+413
-316
index.vue
src/views/taskScheduling/taskFlow/index.vue
+4
-4
mock.ts
src/views/taskScheduling/taskFlow/mock.ts
+9
-9
defineEvent.vue
src/views/taskScheduling/taskFlowDesign/defineEvent.vue
+177
-229
design.data.ts
src/views/taskScheduling/taskFlowDesign/design.data.ts
+206
-42
taskConfigModel.vue
src/views/taskScheduling/taskFlowDesign/taskConfigModel.vue
+17
-32
No files found.
src/views/taskScheduling/taskFlow/index.vue
View file @
1fcf553e
...
@@ -91,7 +91,7 @@
...
@@ -91,7 +91,7 @@
tooltip:'详情',
tooltip:'详情',
onClick: handleConsanguinity.bind(null, record),
onClick: handleConsanguinity.bind(null, record),
ifShow: () => {
ifShow: () => {
return record.releaseStatus !== '
父级
'; // 这里只是实现树文件夹按钮
return record.releaseStatus !== ''; // 这里只是实现树文件夹按钮
},
},
},
},
{
{
...
@@ -107,7 +107,7 @@
...
@@ -107,7 +107,7 @@
tooltip:'下线',
tooltip:'下线',
onClick: handleOnline.bind(null, record),
onClick: handleOnline.bind(null, record),
ifShow: () => {
ifShow: () => {
return record.releaseStatus !== '
父级
'; // 根据业务控制是否显示: 非enable状态的不显示启用按钮
return record.releaseStatus !== ''; // 根据业务控制是否显示: 非enable状态的不显示启用按钮
},
},
},
},
{
{
...
@@ -115,7 +115,7 @@
...
@@ -115,7 +115,7 @@
tooltip:'发布',
tooltip:'发布',
onClick: apiDetail.bind(null, record),
onClick: apiDetail.bind(null, record),
ifShow: () => {
ifShow: () => {
return record.releaseStatus !== '
父级
'; // 根据业务控制是否显示: 非enable状态的不显示启用按钮
return record.releaseStatus !== ''; // 根据业务控制是否显示: 非enable状态的不显示启用按钮
},
},
},
},
{
{
...
@@ -123,7 +123,7 @@
...
@@ -123,7 +123,7 @@
tooltip:'检查?',
tooltip:'检查?',
onClick: handleOffline.bind(null, record),
onClick: handleOffline.bind(null, record),
ifShow: () => {
ifShow: () => {
return record.releaseStatus !== '
父级
'; // 这里只是实现树文件夹按钮
return record.releaseStatus !== ''; // 这里只是实现树文件夹按钮
},
},
},
},
]"
]"
...
...
src/views/taskScheduling/taskFlow/mock.ts
View file @
1fcf553e
...
@@ -122,7 +122,7 @@ export const tableList: any[] = [
...
@@ -122,7 +122,7 @@ export const tableList: any[] = [
updateDate
:
'2023/07/10 10:49:38'
,
updateDate
:
'2023/07/10 10:49:38'
,
businessTag
:
'_'
,
businessTag
:
'_'
,
owner
:
'admin'
,
owner
:
'admin'
,
releaseStatus
:
'
父级
'
,
releaseStatus
:
''
,
task
:
null
,
task
:
null
,
type
:
'theme'
,
type
:
'theme'
,
...
@@ -136,7 +136,7 @@ export const tableList: any[] = [
...
@@ -136,7 +136,7 @@ export const tableList: any[] = [
updateDate
:
'2023/07/10 10:49:38'
,
updateDate
:
'2023/07/10 10:49:38'
,
businessTag
:
'_'
,
businessTag
:
'_'
,
owner
:
'admin'
,
owner
:
'admin'
,
releaseStatus
:
'
父级
'
,
releaseStatus
:
''
,
task
:
null
,
task
:
null
,
type
:
'theme'
,
type
:
'theme'
,
...
@@ -150,7 +150,7 @@ export const tableList: any[] = [
...
@@ -150,7 +150,7 @@ export const tableList: any[] = [
updateDate
:
'2023/07/10 10:49:38'
,
updateDate
:
'2023/07/10 10:49:38'
,
businessTag
:
'_'
,
businessTag
:
'_'
,
owner
:
'admin'
,
owner
:
'admin'
,
releaseStatus
:
'
父级
'
,
releaseStatus
:
''
,
task
:
null
,
task
:
null
,
type
:
'twoLevel'
,
type
:
'twoLevel'
,
...
@@ -164,7 +164,7 @@ export const tableList: any[] = [
...
@@ -164,7 +164,7 @@ export const tableList: any[] = [
updateDate
:
'2023/07/10 10:49:38'
,
updateDate
:
'2023/07/10 10:49:38'
,
businessTag
:
'_'
,
businessTag
:
'_'
,
owner
:
'admin'
,
owner
:
'admin'
,
releaseStatus
:
'
父级
'
,
releaseStatus
:
''
,
task
:
null
,
task
:
null
,
type
:
'twoLevel'
,
type
:
'twoLevel'
,
...
@@ -178,7 +178,7 @@ export const tableList: any[] = [
...
@@ -178,7 +178,7 @@ export const tableList: any[] = [
updateDate
:
'2023/07/10 10:49:38'
,
updateDate
:
'2023/07/10 10:49:38'
,
businessTag
:
'_'
,
businessTag
:
'_'
,
owner
:
'admin'
,
owner
:
'admin'
,
releaseStatus
:
'
父级
'
,
releaseStatus
:
''
,
task
:
null
,
task
:
null
,
type
:
'twoLevel'
,
type
:
'twoLevel'
,
...
@@ -192,7 +192,7 @@ export const tableList: any[] = [
...
@@ -192,7 +192,7 @@ export const tableList: any[] = [
updateDate
:
'2023/07/10 10:49:38'
,
updateDate
:
'2023/07/10 10:49:38'
,
businessTag
:
'_'
,
businessTag
:
'_'
,
owner
:
'admin'
,
owner
:
'admin'
,
releaseStatus
:
'
父级
'
,
releaseStatus
:
''
,
task
:
null
,
task
:
null
,
type
:
'twoLevel'
,
type
:
'twoLevel'
,
...
@@ -206,7 +206,7 @@ export const tableList: any[] = [
...
@@ -206,7 +206,7 @@ export const tableList: any[] = [
updateDate
:
'2023/07/10 10:49:38'
,
updateDate
:
'2023/07/10 10:49:38'
,
businessTag
:
'_'
,
businessTag
:
'_'
,
owner
:
'admin'
,
owner
:
'admin'
,
releaseStatus
:
'
父级
'
,
releaseStatus
:
''
,
task
:
null
,
task
:
null
,
type
:
'twoLevel'
,
type
:
'twoLevel'
,
...
@@ -220,7 +220,7 @@ export const tableList: any[] = [
...
@@ -220,7 +220,7 @@ export const tableList: any[] = [
updateDate
:
'2023/07/10 10:49:38'
,
updateDate
:
'2023/07/10 10:49:38'
,
businessTag
:
'_'
,
businessTag
:
'_'
,
owner
:
'admin'
,
owner
:
'admin'
,
releaseStatus
:
'
父级
'
,
releaseStatus
:
''
,
task
:
null
,
task
:
null
,
type
:
'twoLevel'
,
type
:
'twoLevel'
,
...
@@ -234,7 +234,7 @@ export const tableList: any[] = [
...
@@ -234,7 +234,7 @@ export const tableList: any[] = [
updateDate
:
'2023/07/10 10:49:38'
,
updateDate
:
'2023/07/10 10:49:38'
,
businessTag
:
'_'
,
businessTag
:
'_'
,
owner
:
'admin'
,
owner
:
'admin'
,
releaseStatus
:
'
父级
'
,
releaseStatus
:
''
,
task
:
null
,
task
:
null
,
type
:
'twoLevel'
,
type
:
'twoLevel'
,
...
...
src/views/taskScheduling/taskFlowDesign/defineEvent.vue
View file @
1fcf553e
This diff is collapsed.
Click to expand it.
src/views/taskScheduling/taskFlowDesign/design.data.ts
View file @
1fcf553e
import
{
FormSchema
}
from
'@/components/Form'
;
import
{
FormSchema
}
from
'@/components/Form'
;
import
{
BasicColumn
}
from
'@/components/Table'
;
import
{
BasicColumn
}
from
'@/components/Table'
;
import
{
TableColumn
}
from
'ant-design-vue'
;
import
{
InputProps
,
TableColumn
}
from
'ant-design-vue'
;
import
{
TreeItem
}
from
'@/components/Tree'
;
import
{
TreeItem
}
from
'@/components/Tree'
;
export
const
designFormSchema
:
FormSchema
[]
=
[
export
const
designFormSchema
:
FormSchema
[]
=
[
...
@@ -853,12 +853,38 @@ export const taskOverallConfig: FormSchema[] = [
...
@@ -853,12 +853,38 @@ export const taskOverallConfig: FormSchema[] = [
slot
:
'cycle'
,
slot
:
'cycle'
,
colProps
:
{
lg
:
24
,
md
:
24
},
colProps
:
{
lg
:
24
,
md
:
24
},
},
},
/*
{
{
label
:
'Cron表达式'
,
label
:
'Cron表达式'
,
helpMessage
:
'0 0 0 ? * * *'
,
component
:
'Input'
,
componentProps
:
{
placeholder
:
'0 0 0 ? * * *'
,
}
as
InputProps
,
field
:
'cron'
,
field
:
'cron'
,
slot: 'cron',
colProps
:
{
lg
:
24
,
md
:
24
},
colProps
:
{
lg
:
24
,
md
:
24
},
},*/
show
:
({
model
})
=>
{
return
model
.
cycle
===
'Cron表达式'
;
},
},
{
label
:
'调度时间'
,
field
:
'scheduleTime'
,
fields
:[
'scheduleTime'
],
slot
:
'scheduleTime'
,
colProps
:
{
lg
:
24
,
md
:
24
},
show
:
({
model
})
=>
{
return
model
.
cycle
===
'每天一次'
;
},
},
{
label
:
'事件触发器'
,
field
:
'eventTrigger'
,
slot
:
'eventTrigger'
,
colProps
:
{
lg
:
24
,
md
:
24
},
show
:
({
model
})
=>
{
return
model
.
cycle
===
'事件触发器'
;
},
},
{
{
label
:
'自定义日历'
,
label
:
'自定义日历'
,
field
:
'calendar'
,
field
:
'calendar'
,
...
@@ -1057,81 +1083,219 @@ export const defineEvent: FormSchema[] = [
...
@@ -1057,81 +1083,219 @@ export const defineEvent: FormSchema[] = [
label
:
'触发类型'
,
label
:
'触发类型'
,
field
:
'triggerType'
,
field
:
'triggerType'
,
fields
:
[
'saveResult'
],
fields
:
[
'saveResult'
],
/*componentProps: {
defaultValue
:
'文件到达'
,
options: [
{
label: '文件到达',
value: '文件到达',
},
{
label: 'SQL结果检查',
value: 'SQL结果检查',
},
{
label: '脚本自定义',
value: '脚本自定义',
},
],
},*/
colProps
:
{
colProps
:
{
span
:
20
,
span
:
20
,
},
},
slot
:
'triggerType'
,
slot
:
'triggerType'
,
},
},
/*
{
{
label
:
'文件系统源'
,
label
:
'文件系统源'
,
field
:
'fileSystemSource'
,
field
:
'fileSystemSource'
,
component: 'Select',
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'文件到达'
;
},
slot
:
'fileSystemSource'
,
colProps
:
{
span
:
20
,
},
},
{
label
:
'文件路径'
,
field
:
'filePath'
,
slot
:
'filePath'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'文件到达'
;
},
colProps
:
{
span
:
20
,
},
},
{
label
:
'目标对象'
,
field
:
'targetObject'
,
fields
:
[
'targetObject'
],
slot
:
'targetObject'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'文件到达'
;
},
colProps
:
{
span
:
20
,
},
},
{
label
:
'超时设置'
,
field
:
'timeoutSettings'
,
component
:
'CheckboxGroup'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'文件到达'
;
},
colProps
:
{
span
:
20
,
},
componentProps
:
{
componentProps
:
{
options
:
[
options
:
[
{
{
label: 'HDFS',
label
:
'超时失败'
,
value: 'HDFS',
value
:
'超时失败'
,
},
{
label: 'FTP',
value: 'FTP',
},
},
],
},
},
{
label
:
'保存结果'
,
field
:
'saveResults'
,
fields
:
[
'saveResults'
,
'saveResultName'
,
'saveResultObject'
],
colProps
:
{
span
:
20
,
},
slot
:
'saveResults'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'文件到达'
;
},
},
{
label
:
'开始时间'
,
field
:
'startTime'
,
colProps
:
{
span
:
20
,
},
component
:
'TimePicker'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'SQL结果检查'
;
},
},
{
label
:
'滚动时间窗口'
,
field
:
'rollingTimeWindow'
,
fields
:
[
'timeList'
],
colProps
:
{
span
:
20
,
},
slot
:
'rollingTimeWindow'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'SQL结果检查'
;
},
},
{
label
:
'超时设置'
,
field
:
'timeoutSettingsT'
,
component
:
'CheckboxGroup'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'SQL结果检查'
;
},
colProps
:
{
span
:
20
,
},
componentProps
:
{
options
:
[
{
{
label: '
SFTP
',
label
:
'
超时失败
'
,
value: '
SFTP
',
value
:
'
超时失败
'
,
},
},
],
],
},
},
},
{
label
:
'连接'
,
field
:
'connection'
,
component
:
'Select'
,
colProps
:
{
colProps
:
{
span
:
20
,
span
:
20
,
},
},
componentProps
:
{
options
:
[
{
value
:
'1'
,
label
:
'192.168.11.3'
},
{
value
:
'2'
,
label
:
'192.168.96.3'
},
{
value
:
'3'
,
label
:
'192.168.1.32'
},
],
},
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'SQL结果检查'
;
},
},
},
{
{
label: '文件路径',
label
:
'SQL'
,
field: 'filePath',
field
:
'sql'
,
component: 'Input',
component
:
'InputTextArea'
,
componentProps
:
{
placeholder
:
'事件满足取决于当前sql返回结果是否为空,'
+
'若无返回结果则判断事件条件未达成:此处支持引用任务流参数、工作区参数、全局参数'
,
}
as
InputProps
,
colProps
:
{
colProps
:
{
span
:
20
,
span
:
20
,
},
},
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'SQL结果检查'
;
},
},
},
{
{
label: '目标对象',
label
:
'保存结果'
,
field: 'targetObject',
field
:
'saveResultsT'
,
component: 'Input',
fields
:
[
'saveResults'
,
'saveResultName'
,
'saveResultObject'
],
colProps
:
{
span
:
20
,
},
slot
:
'saveResults'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'SQL结果检查'
;
},
},
{
label
:
'开始时间'
,
field
:
'startTimeT'
,
colProps
:
{
colProps
:
{
span
:
20
,
span
:
20
,
},
},
component
:
'TimePicker'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'脚本自定义'
;
},
},
{
label
:
'滚动时间窗口'
,
field
:
'rollingTimeWindowT'
,
fields
:
[
'timeListT'
],
colProps
:
{
span
:
20
,
},
slot
:
'rollingTimeWindowT'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'脚本自定义'
;
},
},
},
{
{
label
:
'超时设置'
,
label
:
'超时设置'
,
field: 'targetObject',
field
:
'timeoutSettingsTh'
,
component: 'Input',
component
:
'CheckboxGroup'
,
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'脚本自定义'
;
},
colProps
:
{
colProps
:
{
span
:
20
,
span
:
20
,
},
},
componentProps
:
{
options
:
[
{
label
:
'超时失败'
,
value
:
'超时失败'
,
},
],
},
},
},
{
{
label: '保存结果',
label
:
'脚本内容'
,
field: 'saveResults',
field
:
'scriptContent'
,
component: 'Input',
component
:
'InputTextArea'
,
componentProps
:
{
placeholder
:
'脚本运行成功,即满足,因此判断逻辑由用户确定'
,
}
as
InputProps
,
colProps
:
{
colProps
:
{
span
:
20
,
span
:
20
,
},
},
},*/
show
:
({
model
})
=>
{
return
model
.
triggerType
===
'脚本自定义'
;
},
},
];
];
src/views/taskScheduling/taskFlowDesign/taskConfigModel.vue
View file @
1fcf553e
...
@@ -9,24 +9,6 @@
...
@@ -9,24 +9,6 @@
<BasicForm
@
register=
"registerForm"
>
<BasicForm
@
register=
"registerForm"
>
<template
#
cycle=
"
{ field, model }">
<template
#
cycle=
"
{ field, model }">
<Select
v-model:value=
"model[field]"
:options=
"cycleOptions"
placeholder=
"请选择"
/>
<Select
v-model:value=
"model[field]"
:options=
"cycleOptions"
placeholder=
"请选择"
/>
<div
v-if=
"model[field] === '每天一次'"
>
<div
style=
"display: flex;margin: 25px 0 0 -65px"
>
<div
style=
"width: 100px"
>
调度时间
</div>
<div
style=
"display: flex;margin-left: -35px"
>
<Input/>
时
<Input/>
分
</div>
</div>
</div>
<div
v-if=
"model[field] === 'Cron表达式'"
style=
"margin-bottom: -15px"
>
<div
style=
"display: flex;margin: 25px 0 0 -80px"
>
<div
style=
"width: 100px"
>
Cron表达式
</div>
<div
style=
"display: flex;margin-left: -5px;width: 100%"
>
<Input/>
</div>
</div>
<a-button
style=
"padding: 0"
type=
"link"
>
Cron表达式
</a-button>
</div>
<a-button
<a-button
type=
"link"
type=
"link"
v-if=
"model[field] === '事件触发器'"
v-if=
"model[field] === '事件触发器'"
...
@@ -34,23 +16,25 @@
...
@@ -34,23 +16,25 @@
style=
"margin-left: -15px"
style=
"margin-left: -15px"
>
批量调整直接下游配置
>
批量调整直接下游配置
</a-button>
</a-button>
<div
v-if=
"model[field] === '事件触发器'"
style=
"margin-bottom: -15px"
>
</
template
>
<div
style=
"display: flex;margin: 15px 0 0 -65px"
>
<
template
#
scheduleTime=
"{ field, model }"
>
<div
style=
"width: 100px"
>
事件定义
</div>
<div
style=
"display: flex"
>
<a-button
@
click=
"handleSetConfig"
style=
"color: red;border-color: red;margin-left: -30px"
>
定义事件
<Input
v-model:value=
"model[field]"
style=
"width: 45%"
/>
时
</a-button>
<Input
v-model:value=
"model['scheduleTime']"
style=
"width: 45%"
/>
分
<a-button
@
click=
"viewLogs"
style=
"margin-left: 20px"
>
查看日志
</a-button>
</div>
</div>
</
template
>
<a-button
type=
"link"
style=
"color: red;margin-left: -10px"
>
<
template
#
eventTrigger=
"{ field, model }"
>
<Icon
icon=
"ant-design:exclamation-circle-outlined"
/>
<div
style=
"display: flex;"
>
请定义触发事件详情
<a-button
@
click=
"handleSetConfig"
style=
"color: red;border-color: red;"
>
定义事件
</a-button>
</a-button>
<a-button
@
click=
"viewLogs"
style=
"margin-left: 20px"
>
查看日志
</a-button>
</div>
</div>
<a-button
type=
"link"
style=
"color: red;margin-left: -10px"
>
<Icon
icon=
"ant-design:exclamation-circle-outlined"
/>
请定义触发事件详情
</a-button>
</
template
>
</
template
>
<!-- <template #cron="{ field, model }">
<Input v-model:value="model[field]"/>
<a-button style="padding: 0" type="link">Cron表达式</a-button>
</template>-->
<
template
#
overTime=
"{ field, model }"
>
<
template
#
overTime=
"{ field, model }"
>
<CheckboxGroup
:options=
"overTimeOptions"
v-model:value=
"model[field]"
/>
<CheckboxGroup
:options=
"overTimeOptions"
v-model:value=
"model[field]"
/>
<div
v-if=
"model[field]"
style=
"display: flex; width: 30%"
>
<div
v-if=
"model[field]"
style=
"display: flex; width: 30%"
>
...
@@ -103,6 +87,7 @@ function viewLogs() {
...
@@ -103,6 +87,7 @@ function viewLogs() {
const
[
registerModal
,
{
setModalProps
,
closeModal
}]
=
useModalInner
(
async
(
data
)
=>
{
const
[
registerModal
,
{
setModalProps
,
closeModal
}]
=
useModalInner
(
async
(
data
)
=>
{
setModalProps
({
confirmLoading
:
false
});
setModalProps
({
confirmLoading
:
false
});
});
});
/**调度周期*/
const
cycleOptions
=
[
const
cycleOptions
=
[
{
{
label
:
'每天一次'
,
label
:
'每天一次'
,
...
...
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