You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by ke...@apache.org on 2022/12/21 08:18:17 UTC
[dolphinscheduler] branch dev updated: fix the issue with failing to save the settings of timeout alarm (#13234)
This is an automated email from the ASF dual-hosted git repository.
kerwin pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git
The following commit(s) were added to refs/heads/dev by this push:
new d795a7a0a3 fix the issue with failing to save the settings of timeout alarm (#13234)
d795a7a0a3 is described below
commit d795a7a0a33399426fedc8f91098467e4050b68e
Author: calvin <ji...@163.com>
AuthorDate: Wed Dec 21 16:18:10 2022 +0800
fix the issue with failing to save the settings of timeout alarm (#13234)
---
.../task/components/node/fields/use-dependent-timeout.ts | 16 +++++++++++-----
1 file changed, 11 insertions(+), 5 deletions(-)
diff --git a/dolphinscheduler-ui/src/views/projects/task/components/node/fields/use-dependent-timeout.ts b/dolphinscheduler-ui/src/views/projects/task/components/node/fields/use-dependent-timeout.ts
index 09df391009..a7b9468fde 100644
--- a/dolphinscheduler-ui/src/views/projects/task/components/node/fields/use-dependent-timeout.ts
+++ b/dolphinscheduler-ui/src/views/projects/task/components/node/fields/use-dependent-timeout.ts
@@ -24,7 +24,7 @@ export function useDependentTimeout(model: {
}): IJsonItem[] {
const { t } = useI18n()
const timeCompleteSpan = computed(() => (model.timeoutShowFlag ? 24 : 0))
- const timeCompleteEnableSpan = computed(() => (model.timeoutFlag ? 12 : 0))
+ const timeCompleteEnableSpan = computed(() => (model.timeoutFlag && model.timeoutShowFlag ? 12 : 0))
const strategyOptions = [
{
@@ -36,11 +36,11 @@ export function useDependentTimeout(model: {
value: 'FAILED'
}
]
+
watch(
() => model.timeoutFlag,
(timeoutFlag) => {
- model.timeoutNotifyStrategy = timeoutFlag ? ['WARN'] : []
- model.timeout = timeoutFlag ? 30 : null
+ model.timeoutShowFlag = timeoutFlag
}
)
@@ -56,8 +56,14 @@ export function useDependentTimeout(model: {
name: t('project.node.waiting_dependent_complete'),
props: {
'on-update:value': (value: boolean) => {
- model.timeoutNotifyStrategy = value ? ['WARN'] : null
- model.timeout = value ? 30 : null
+ if (value) {
+ if (!model.timeoutNotifyStrategy.length) {
+ model.timeoutNotifyStrategy = ['WARN']
+ }
+ if (!model.timeout) {
+ model.timeout = 30
+ }
+ }
}
},
span: timeCompleteSpan