From 796ae6bb7d14ac9c639beeca614d0e24a767bd18 Mon Sep 17 00:00:00 2001 From: baiqi Date: Wed, 13 Nov 2024 14:39:17 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E5=B7=A5=E4=BD=9C=E5=8F=B0):=20=E5=BE=85?= =?UTF-8?q?=E5=8A=9E/=E6=88=91=E7=9A=84=E5=88=9B=E5=BB=BA/=E6=88=91?= =?UTF-8?q?=E7=9A=84=E5=85=B3=E6=B3=A8=E9=A1=B5=E9=9D=A2=E5=B1=95=E7=A4=BA?= =?UTF-8?q?=E9=80=BB=E8=BE=91=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../business/ms-project-select/index.vue | 17 ++- .../components/pure/ms-color-line/index.vue | 18 ++- frontend/src/models/setting/project.ts | 1 + .../component/caseTaskDetailTable.vue | 18 ++- .../taskCenter/component/caseTaskTable.vue | 106 ++------------- .../component/executeRatePopper.vue | 122 ++++++++++++++++++ frontend/src/views/taskCenter/locale/en-US.ts | 1 + frontend/src/views/taskCenter/locale/zh-CN.ts | 1 + .../testPlan/components/caseCountPopper.vue | 85 ++++++++++++ .../testPlan/components/planTable.vue | 53 +------- .../testPlan/components/statusProgress.vue | 4 +- .../src/views/workbench/components/config.ts | 12 ++ .../workbench/components/testPlanTable.vue | 51 +------- .../src/views/workbench/myCreated/index.vue | 21 ++- .../src/views/workbench/myFollowed/index.vue | 21 ++- frontend/src/views/workbench/myToDo/index.vue | 28 +++- 16 files changed, 339 insertions(+), 220 deletions(-) create mode 100644 frontend/src/views/taskCenter/component/executeRatePopper.vue create mode 100644 frontend/src/views/test-plan/testPlan/components/caseCountPopper.vue create mode 100644 frontend/src/views/workbench/components/config.ts diff --git a/frontend/src/components/business/ms-project-select/index.vue b/frontend/src/components/business/ms-project-select/index.vue index b46cfebca7..088178cb05 100644 --- a/frontend/src/components/business/ms-project-select/index.vue +++ b/frontend/src/components/business/ms-project-select/index.vue @@ -25,7 +25,7 @@ useDefaultArrowIcon?: boolean; }>(); const emit = defineEmits<{ - (e: 'change', val: string): void; + (e: 'change', val: string, project?: ProjectListItem): void; }>(); const appStore = useAppStore(); @@ -34,6 +34,14 @@ default: () => '', }); + function selectProject( + value: string | number | boolean | Record | (string | number | boolean | Record)[] + ) { + project.value = value as string; + const _project = projectList.value.find((item) => item.id === value); + emit('change', value as string, _project); + } + onBeforeMount(async () => { if (!project.value) { project.value = appStore.currentProjectId; @@ -42,6 +50,7 @@ if (appStore.currentOrgId) { const res = await getProjectList(appStore.getCurrentOrgId); projectList.value = res; + selectProject(project.value); } else { projectList.value = []; } @@ -50,12 +59,6 @@ console.log(error); } }); - - function selectProject( - value: string | number | boolean | Record | (string | number | boolean | Record)[] - ) { - emit('change', value as string); - } diff --git a/frontend/src/components/pure/ms-color-line/index.vue b/frontend/src/components/pure/ms-color-line/index.vue index b7413e7ca3..1427ecebf3 100644 --- a/frontend/src/components/pure/ms-color-line/index.vue +++ b/frontend/src/components/pure/ms-color-line/index.vue @@ -1,5 +1,5 @@ diff --git a/frontend/src/views/workbench/myToDo/index.vue b/frontend/src/views/workbench/myToDo/index.vue index fc1a0c7fab..e7c4000ba9 100644 --- a/frontend/src/views/workbench/myToDo/index.vue +++ b/frontend/src/views/workbench/myToDo/index.vue @@ -2,7 +2,12 @@