From 860d3131ae1ad0cef029a66cc0655def526aad53 Mon Sep 17 00:00:00 2001 From: GoldenZqqq <1361001127@qq.com> Date: Mon, 14 Oct 2024 15:17:05 +0800 Subject: [PATCH 1/2] =?UTF-8?q?feat:=20=E6=B5=81=E7=A8=8B=E6=A8=A1?= =?UTF-8?q?=E5=9E=8B=E5=88=97=E8=A1=A8=E9=A1=B5=E9=9D=A2=E6=A0=B7=E5=BC=8F?= =?UTF-8?q?=E4=B8=8E=E6=96=87=E5=AD=97=E7=BB=86=E8=8A=82=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/bpm/model/index_new.vue | 61 +++++++++++++++++++------------ 1 file changed, 38 insertions(+), 23 deletions(-) diff --git a/src/views/bpm/model/index_new.vue b/src/views/bpm/model/index_new.vue index 4f2ba3c3d..66613e065 100644 --- a/src/views/bpm/model/index_new.vue +++ b/src/views/bpm/model/index_new.vue @@ -1,7 +1,7 @@ @@ -141,20 +142,22 @@ @@ -436,6 +439,9 @@ onMounted(async () => { From 7ea5cf55891d97dbc065c44f37e8e4cf00247ab5 Mon Sep 17 00:00:00 2001 From: GGbond Date: Thu, 11 Jun 2026 14:56:30 +0800 Subject: [PATCH 2/2] =?UTF-8?q?feat(infra):=20=E5=AE=9A=E6=97=B6=E4=BB=BB?= =?UTF-8?q?=E5=8A=A1=E6=B7=BB=E5=8A=A0=E5=90=8C=E6=AD=A5=E6=8C=89=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/infra/job/index.ts | 6 ++++++ src/views/infra/job/index.vue | 18 ++++++++++++++++++ 2 files changed, 24 insertions(+) diff --git a/src/api/infra/job/index.ts b/src/api/infra/job/index.ts index 033b2cbe8..e312e8c68 100644 --- a/src/api/infra/job/index.ts +++ b/src/api/infra/job/index.ts @@ -61,3 +61,9 @@ export const runJob = (id: number) => { export const getJobNextTimes = (id: number) => { return request.get({ url: '/infra/job/get_next_times?id=' + id }) } + + +// 同步定时任务到 Quartz +export const syncJob = () => { + return request.post({ url: '/infra/job/sync' }) +} \ No newline at end of file diff --git a/src/views/infra/job/index.vue b/src/views/infra/job/index.vue index 29460030c..72f339beb 100644 --- a/src/views/infra/job/index.vue +++ b/src/views/infra/job/index.vue @@ -68,6 +68,9 @@ 执行日志 + + 同步任务 + @@ -174,6 +177,7 @@ const queryParams = reactive({ }) const queryFormRef = ref() // 搜索的表单 const exportLoading = ref(false) // 导出的加载中 +const syncLoading = ref(false) // 同步的加载中 /** 查询列表 */ const getList = async () => { @@ -214,6 +218,20 @@ const handleExport = async () => { } } +/** 同步任务到 Quartz */ +const handleSyncJob = async () => { + try { + await message.confirm('确认要同步所有任务到调度器?', t('common.reminder')) + syncLoading.value = true + await JobApi.syncJob() + message.success('同步成功') + await getList() + } catch { + } finally { + syncLoading.value = false + } +} + /** 添加/修改操作 */ const formRef = ref() const openForm = (type: string, id?: number) => {