Browse Source

[Fix][UI][V1.0.0-Beta] Remove the sql comment in the procedure task and add the instructions link to the procedure task. (#9619)

3.0.0/version-upgrade
Amy0104 3 years ago committed by GitHub
parent
commit
69bfebfec0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      dolphinscheduler-ui-next/src/views/projects/task/components/node/detail-modal.tsx
  2. 5
      dolphinscheduler-ui-next/src/views/projects/task/components/node/fields/use-procedure.ts
  3. 3
      dolphinscheduler-ui-next/src/views/projects/task/constants/task-type.ts

4
dolphinscheduler-ui-next/src/views/projects/task/components/node/detail-modal.tsx

@ -119,11 +119,13 @@ const NodeDetailModal = defineComponent({
text: t('project.node.instructions'), text: t('project.node.instructions'),
show: !!(taskType && !TASK_TYPES_MAP[taskType]?.helperLinkDisable), show: !!(taskType && !TASK_TYPES_MAP[taskType]?.helperLinkDisable),
action: () => { action: () => {
let linkedTaskType = taskType?.toLowerCase().replace('_', '-')
if (taskType === 'PROCEDURE') linkedTaskType = 'stored-procedure'
const helpUrl = const helpUrl =
'https://dolphinscheduler.apache.org/' + 'https://dolphinscheduler.apache.org/' +
locale.value.toLowerCase().replace('_', '-') + locale.value.toLowerCase().replace('_', '-') +
'/docs/latest/user_doc/guide/task/' + '/docs/latest/user_doc/guide/task/' +
taskType?.toLowerCase().replace('_', '-') + linkedTaskType +
'.html' '.html'
window.open(helpUrl) window.open(helpUrl)
}, },

5
dolphinscheduler-ui-next/src/views/projects/task/components/node/fields/use-procedure.ts

@ -28,10 +28,7 @@ export function useProcedure(model: { [field: string]: any }): IJsonItem[] {
name: t('project.node.procedure_method'), name: t('project.node.procedure_method'),
props: { props: {
language: 'sql', language: 'sql',
placeholder: t('project.node.procedure_method_tips'), placeholder: t('project.node.procedure_method_tips')
defaultValue: model.method
? model.method
: t('project.node.procedure_method_snippet')
}, },
validate: { validate: {
trigger: ['input', 'trigger'], trigger: ['input', 'trigger'],

3
dolphinscheduler-ui-next/src/views/projects/task/constants/task-type.ts

@ -42,8 +42,7 @@ export const TASK_TYPES_MAP = {
alias: 'SUB_PROCESS' alias: 'SUB_PROCESS'
}, },
PROCEDURE: { PROCEDURE: {
alias: 'PROCEDURE', alias: 'PROCEDURE'
helperLinkDisable: true
}, },
SQL: { SQL: {
alias: 'SQL' alias: 'SQL'

Loading…
Cancel
Save