You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by zh...@apache.org on 2022/01/28 07:58:17 UTC

[dolphinscheduler] branch dev updated: [Fix][UI Next] Fix the problem that the switch language options are not updated. (#8239)

This is an automated email from the ASF dual-hosted git repository.

zhongjiajie 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 a778146  [Fix][UI Next] Fix the problem that the switch language options are not updated. (#8239)
a778146 is described below

commit a778146ec6713f091184329624d883db5148e986
Author: songjianet <17...@qq.com>
AuthorDate: Fri Jan 28 15:56:03 2022 +0800

    [Fix][UI Next] Fix the problem that the switch language options are not updated. (#8239)
---
 .../src/views/projects/task/instance/index.tsx     | 27 ++++++++++++++++++++-
 .../src/views/projects/task/instance/use-table.ts  | 28 +---------------------
 2 files changed, 27 insertions(+), 28 deletions(-)

diff --git a/dolphinscheduler-ui-next/src/views/projects/task/instance/index.tsx b/dolphinscheduler-ui-next/src/views/projects/task/instance/index.tsx
index f93e0b8..cf9f163 100644
--- a/dolphinscheduler-ui-next/src/views/projects/task/instance/index.tsx
+++ b/dolphinscheduler-ui-next/src/views/projects/task/instance/index.tsx
@@ -120,7 +120,32 @@ const TaskInstance = defineComponent({
             <NSelect
               v-model={[this.stateType, 'value']}
               size='small'
-              options={this.generalOptions}
+              options={[
+                {
+                  label: t('project.task.submitted_success'),
+                  value: 'SUBMITTED_SUCCESS'
+                },
+                {
+                  label: t('project.task.running_execution'),
+                  value: 'RUNNING_EXECUTION'
+                },
+                { label: t('project.task.ready_pause'), value: 'READY_PAUSE' },
+                { label: t('project.task.pause'), value: 'PAUSE' },
+                { label: t('project.task.ready_stop'), value: 'READY_STOP' },
+                { label: t('project.task.stop'), value: 'STOP' },
+                { label: t('project.task.failure'), value: 'FAILURE' },
+                { label: t('project.task.success'), value: 'SUCCESS' },
+                {
+                  label: t('project.task.need_fault_tolerance'),
+                  value: 'NEED_FAULT_TOLERANCE'
+                },
+                { label: t('project.task.kill'), value: 'KILL' },
+                { label: t('project.task.waiting_thread'), value: 'WAITING_THREAD' },
+                { label: t('project.task.waiting_depend'), value: 'WAITING_DEPEND' },
+                { label: t('project.task.delay_execution'), value: 'DELAY_EXECUTION' },
+                { label: t('project.task.forced_success'), value: 'FORCED_SUCCESS' },
+                { label: t('project.task.serial_wait'), value: 'SERIAL_WAIT' }
+              ]}
               placeholder={t('project.task.state')}
               style={{ width: '180px' }}
               clearable
diff --git a/dolphinscheduler-ui-next/src/views/projects/task/instance/use-table.ts b/dolphinscheduler-ui-next/src/views/projects/task/instance/use-table.ts
index 8567d28..ecff49d 100644
--- a/dolphinscheduler-ui-next/src/views/projects/task/instance/use-table.ts
+++ b/dolphinscheduler-ui-next/src/views/projects/task/instance/use-table.ts
@@ -54,33 +54,7 @@ export function useTable() {
     totalPage: ref(1),
     showModalRef: ref(false),
     statusRef: ref(0),
-    row: {},
-    generalOptions: [
-      {
-        label: t('project.task.submitted_success'),
-        value: 'SUBMITTED_SUCCESS'
-      },
-      {
-        label: t('project.task.running_execution'),
-        value: 'RUNNING_EXECUTION'
-      },
-      { label: t('project.task.ready_pause'), value: 'READY_PAUSE' },
-      { label: t('project.task.pause'), value: 'PAUSE' },
-      { label: t('project.task.ready_stop'), value: 'READY_STOP' },
-      { label: t('project.task.stop'), value: 'STOP' },
-      { label: t('project.task.failure'), value: 'FAILURE' },
-      { label: t('project.task.success'), value: 'SUCCESS' },
-      {
-        label: t('project.task.need_fault_tolerance'),
-        value: 'NEED_FAULT_TOLERANCE'
-      },
-      { label: t('project.task.kill'), value: 'KILL' },
-      { label: t('project.task.waiting_thread'), value: 'WAITING_THREAD' },
-      { label: t('project.task.waiting_depend'), value: 'WAITING_DEPEND' },
-      { label: t('project.task.delay_execution'), value: 'DELAY_EXECUTION' },
-      { label: t('project.task.forced_success'), value: 'FORCED_SUCCESS' },
-      { label: t('project.task.serial_wait'), value: 'SERIAL_WAIT' }
-    ]
+    row: {}
   })
 
   const createColumns = (variables: any) => {