From 61cc8252a77a471643c3b555126d7d201e977964 Mon Sep 17 00:00:00 2001 From: xlsea Date: Mon, 24 Jun 2024 15:55:40 +0800 Subject: [PATCH] =?UTF-8?q?feat(sj=5Fmap=5Freduce):=20=E6=89=A7=E8=A1=8C?= =?UTF-8?q?=E6=89=B9=E6=AC=A1=E6=96=B0=E5=A2=9E=E6=97=A5=E5=BF=97=E6=8C=89?= =?UTF-8?q?=E9=92=AE=EF=BC=8C=E5=B9=B6=E4=BC=98=E5=8C=96=E6=97=A5=E5=BF=97?= =?UTF-8?q?=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/iconify/hugeicons.json | 12 ++++++ src/components/common/log-drawer.vue | 23 ++++++++++- src/locales/langs/en-us.ts | 1 + src/locales/langs/zh-cn.ts | 1 + src/router/elegant/imports.ts | 1 + src/router/elegant/routes.ts | 11 +++++ src/store/modules/log/index.ts | 40 +++++++++++++++++++ src/typings/storage.d.ts | 5 +++ src/views/_builtin/log/index.vue | 26 ++++++++++++ src/views/job/batch/index.vue | 17 +++++++- .../batch/modules/job-batch-detail-drawer.vue | 15 ++++--- .../job/batch/modules/job-task-list-table.vue | 2 +- 12 files changed, 146 insertions(+), 8 deletions(-) create mode 100644 public/iconify/hugeicons.json create mode 100644 src/store/modules/log/index.ts create mode 100644 src/views/_builtin/log/index.vue diff --git a/public/iconify/hugeicons.json b/public/iconify/hugeicons.json new file mode 100644 index 0000000..432c8af --- /dev/null +++ b/public/iconify/hugeicons.json @@ -0,0 +1,12 @@ +{ + "prefix": "hugeicons", + "lastModified": 1715671861, + "aliases": {}, + "width": 24, + "height": 24, + "icons": { + "share-01": { + "body": "" + } + } +} diff --git a/src/components/common/log-drawer.vue b/src/components/common/log-drawer.vue index 5789c33..addff79 100644 --- a/src/components/common/log-drawer.vue +++ b/src/components/common/log-drawer.vue @@ -1,7 +1,9 @@ diff --git a/src/views/job/batch/modules/job-batch-detail-drawer.vue b/src/views/job/batch/modules/job-batch-detail-drawer.vue index 6f172a6..f3a7584 100644 --- a/src/views/job/batch/modules/job-batch-detail-drawer.vue +++ b/src/views/job/batch/modules/job-batch-detail-drawer.vue @@ -4,6 +4,7 @@ import { executorTypeRecord, operationReasonRecord, taskBatchStatusRecord } from import { $t } from '@/locales'; import { tagColor } from '@/utils/common'; import { fetchJobLogList } from '@/service/api/log'; +import { useLogStore } from '@/store/modules/log'; import JobTaskListTable from './job-task-list-table.vue'; defineOptions({ @@ -13,20 +14,24 @@ defineOptions({ interface Props { /** row data */ rowData?: Api.JobBatch.JobBatch | null; + log?: boolean; } -defineProps(); +const props = withDefaults(defineProps(), { + log: false, + rowData: null +}); const visible = defineModel('visible', { default: false }); const taskData = ref(); -const logShow = defineModel('logShow', { - default: false -}); +const logShow = ref(false); +const store = useLogStore(); async function openLog(row: Api.Job.JobTask) { + store.setTaskInfo(props.rowData!.jobName, row.taskBatchId); logShow.value = true; taskData.value = row; await getLogList(); @@ -77,7 +82,7 @@ onBeforeUnmount(() => {