From 4f90499adaf1be4f3329ac004962b055b44de4ad Mon Sep 17 00:00:00 2001 From: QDKF Date: Fri, 29 Aug 2025 15:39:45 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=B7=BB=E5=8A=A0=E6=96=B0=E5=BB=BA?= =?UTF-8?q?=E8=AF=81=E4=B9=A6=E7=9A=84=E9=A1=B5=E9=9D=A2=E5=92=8C=E5=8A=9F?= =?UTF-8?q?=E8=83=BD;=E9=A1=B5=E9=9D=A2=E6=B7=BB=E5=8A=A0=E8=BF=87?= =?UTF-8?q?=E6=B8=A1=E5=8A=A8=E7=94=BB;=E6=B7=BB=E5=8A=A0=E8=AF=81?= =?UTF-8?q?=E4=B9=A6=E6=9C=89=E6=95=88=E6=9C=9F,=20=E8=AF=81=E4=B9=A6?= =?UTF-8?q?=E5=88=86=E7=B1=BB=E8=8F=9C=E5=8D=95;=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E8=AF=81=E4=B9=A6=E9=A2=84=E8=A7=88=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../{路径 33.png => rechristen-active.png} | Bin .../teacher/{路径 32.png => rechristen.png} | Bin .../certificate/CertificateManagement.vue | 18 +- .../teacher/certificate/CertificateNew.vue | 615 +++++++++++++++++- src/views/teacher/course/CourseEditor.vue | 31 +- 5 files changed, 633 insertions(+), 31 deletions(-) rename public/images/teacher/{路径 33.png => rechristen-active.png} (100%) rename public/images/teacher/{路径 32.png => rechristen.png} (100%) diff --git a/public/images/teacher/路径 33.png b/public/images/teacher/rechristen-active.png similarity index 100% rename from public/images/teacher/路径 33.png rename to public/images/teacher/rechristen-active.png diff --git a/public/images/teacher/路径 32.png b/public/images/teacher/rechristen.png similarity index 100% rename from public/images/teacher/路径 32.png rename to public/images/teacher/rechristen.png diff --git a/src/views/teacher/certificate/CertificateManagement.vue b/src/views/teacher/certificate/CertificateManagement.vue index 6354dd9..387d5cd 100644 --- a/src/views/teacher/certificate/CertificateManagement.vue +++ b/src/views/teacher/certificate/CertificateManagement.vue @@ -194,7 +194,23 @@ const downloadCertificate = (certificate: any) => { } const editCertificate = (certificate: any) => { - message.info(`编辑证书: ${certificate.name}`) + // 从当前路径中提取课程ID + const currentPath = route.path; + const courseIdMatch = currentPath.match(/\/course-editor\/(\d+)/); + const courseId = courseIdMatch ? courseIdMatch[1] : '1'; + + // 跳转到新建证书页面,并传递证书信息作为参数 + router.push({ + path: `/teacher/certificate/new`, + query: { + courseId: courseId, + certificateId: certificate.id, + mode: 'edit', + name: certificate.name, + category: certificate.category + } + }); + activeFileMenu.value = null } diff --git a/src/views/teacher/certificate/CertificateNew.vue b/src/views/teacher/certificate/CertificateNew.vue index 08291f6..adc4a7c 100644 --- a/src/views/teacher/certificate/CertificateNew.vue +++ b/src/views/teacher/certificate/CertificateNew.vue @@ -1,14 +1,95 @@