Browse Source

[Fix-11366][UI] Workflow instance should not support right-click running (#11367)

Co-authored-by: sheldonliu <sheldonliu>
3.1.0-release
Sheldon 2 years ago committed by GitHub
parent
commit
82e9c40df8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      dolphinscheduler-ui/src/views/projects/workflow/components/dag/dag-context-menu.tsx
  2. 1
      dolphinscheduler-ui/src/views/projects/workflow/components/dag/index.tsx

8
dolphinscheduler-ui/src/views/projects/workflow/components/dag/dag-context-menu.tsx

@ -26,6 +26,10 @@ import { IWorkflowTaskInstance } from './types'
import { NButton } from 'naive-ui'
const props = {
startButtonDisplay: {
type: Boolean as PropType<boolean>,
default: true
},
startReadonly: {
type: Boolean as PropType<boolean>,
default: false
@ -127,13 +131,15 @@ export default defineComponent({
class={styles['dag-context-menu']}
style={{ left: `${this.left}px`, top: `${this.top}px` }}
>
{this.startButtonDisplay && (
<NButton
class={`${styles['menu-item']}`}
disabled={this.startReadonly}
onClick={this.startRunning}
>
{t('project.node.start')}
</NButton>
</NButton>)
}
<NButton
class={`${styles['menu-item']}`}
disabled={this.menuReadonly}

1
dolphinscheduler-ui/src/views/projects/workflow/components/dag/index.tsx

@ -362,6 +362,7 @@ export default defineComponent({
onCancel={taskCancel}
/>
<ContextMenuItem
startButtonDisplay={!props.instance}
startReadonly={startReadonly.value}
menuReadonly={menuReadonly.value}
taskInstance={taskInstance.value}

Loading…
Cancel
Save