Browse Source

[Fix][UI] Set task group name empty of default value (#10243)

3.1.0-release
Devosend 3 years ago committed by GitHub
parent
commit
b337eef2e6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      dolphinscheduler-ui/src/views/resource/task-group/queue/index.tsx
  2. 9
      dolphinscheduler-ui/src/views/resource/task-group/queue/use-table.ts

5
dolphinscheduler-ui/src/views/resource/task-group/queue/index.tsx

@ -110,9 +110,6 @@ const taskGroupQueue = defineComponent({
queryTaskGroupListPaging(taskGroupOptionsParams).then( queryTaskGroupListPaging(taskGroupOptionsParams).then(
(res: TaskGroupRes) => { (res: TaskGroupRes) => {
res.totalList.map((item) => { res.totalList.map((item) => {
if (!searchParamRef.groupId) {
searchParamRef.groupId = item.id
}
const option: SelectMixedOption = { const option: SelectMixedOption = {
label: item.name, label: item.name,
value: item.id value: item.id
@ -165,6 +162,8 @@ const taskGroupQueue = defineComponent({
<NSelect <NSelect
size='small' size='small'
options={taskGroupOptions} options={taskGroupOptions}
clearable
style={{ width: '180px' }}
v-model:value={this.searchParamRef.groupId} v-model:value={this.searchParamRef.groupId}
placeholder={t('resource.task_group_queue.task_group_name')} placeholder={t('resource.task_group_queue.task_group_name')}
/> />

9
dolphinscheduler-ui/src/views/resource/task-group/queue/use-table.ts

@ -132,10 +132,12 @@ export function useTable(
pageNo: 1, pageNo: 1,
pageSize: 2147483647 pageSize: 2147483647
} }
Promise.all([ Promise.all([
queryTaskListInTaskGroupQueueById(params), queryTaskListInTaskGroupQueueById(params),
queryTaskGroupListPaging(taskGroupSearchParams) queryTaskGroupListPaging(taskGroupSearchParams)
]).then((values: any[]) => { ]).then(
(values: any[]) => {
const taskGroupList = values[1].totalList const taskGroupList = values[1].totalList
variables.totalPage = values[0].totalPage variables.totalPage = values[0].totalPage
variables.tableData = values[0].totalList.map( variables.tableData = values[0].totalList.map(
@ -162,8 +164,11 @@ export function useTable(
} }
} }
) )
},
() => {}
)
variables.loadingRef = false variables.loadingRef = false
})
} }
return { getTableData, variables, columns } return { getTableData, variables, columns }

Loading…
Cancel
Save