From ee90857b06574dabfaad43a477e62b3900fd71b0 Mon Sep 17 00:00:00 2001 From: lanyuanxiaoyao Date: Fri, 12 May 2023 17:05:20 +0800 Subject: [PATCH] =?UTF-8?q?feature(web):=20=E5=A2=9E=E5=8A=A0=E9=98=9F?= =?UTF-8?q?=E5=88=97=E4=BF=A1=E6=81=AF=E5=AD=97=E6=AE=B5=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../resources/static/components/queue-tab.js | 60 ++++++++++++++++--- 1 file changed, 53 insertions(+), 7 deletions(-) diff --git a/service-web/src/main/resources/static/components/queue-tab.js b/service-web/src/main/resources/static/components/queue-tab.js index b3b60e0..5d1401f 100644 --- a/service-web/src/main/resources/static/components/queue-tab.js +++ b/service-web/src/main/resources/static/components/queue-tab.js @@ -6,22 +6,68 @@ function queueCrud(name) { interval: 10000, syncLocation: false, silentPolling: true, - headerToolbar: ['reload'], loadDataOnce: true, affixHeader: false, - perPage: 100, + perPage: 20, + stopAutoRefreshWhenModalIsOpen: true, + resizable: false, + headerToolbar: [ + "reload", + 'filter-toggler', + { + type: "tpl", + tpl: "共 ${total|default:0} 个任务" + }, + { + type: 'pagination', + layout: ['pager', 'perPage'], + maxButtons: 8, + showPageInput: false, + } + ], + footerToolbar: [ + { + type: 'pagination', + layout: ['pager', 'perPage'], + maxButtons: 8, + showPageInput: false, + } + ], columns: [ - {name: 'id', label: 'ID'}, + { + name: 'data.flinkJobId', + label: '任务 ID', + width: 170, + ...copyField('data.flinkJobId') + }, + { + name: 'data.alias', + label: '别名', + ...copyField('data.alias') + }, + { + name: 'data.batch', + label: '批次', + width: 100, + type: 'tpl', + tpl: '${data.batch}' + }, { name: 'priority', label: '优先级', - align: 'center', + width: 60, + type: 'tpl', + tpl: '${priority}' + }, + { + name: 'data.comment', + label: '备注', + width: 150, }, { name: 'createTime', - label: '启动时间', + label: '任务提交时间', ...time('createTime'), - align: 'center', width: 140, }, ] @@ -32,7 +78,7 @@ function queueTab() { return { title: '压缩队列', tab: [ - queueCrud('compaction-queue') + queueCrud('compaction-queue-b1') ], } } \ No newline at end of file