From 8cb8aa639fd1879415f71818f5f45946388636f9 Mon Sep 17 00:00:00 2001 From: "DESKTOP-932OMT8\\REN" Date: Tue, 13 May 2025 10:34:27 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E4=BF=AE=E6=94=B9=E3=80=91=20?= =?UTF-8?q?=E8=AF=95=E9=A2=98=E5=BD=95=E5=85=A5=EF=BC=8C=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/paper/question/index.ts | 9 ++ src/views/paper/question/ChoiceForm.vue | 177 ++++++++++++++++++------ src/views/paper/question/index.vue | 50 +++---- 3 files changed, 161 insertions(+), 75 deletions(-) diff --git a/src/api/paper/question/index.ts b/src/api/paper/question/index.ts index 24900f7..c035210 100644 --- a/src/api/paper/question/index.ts +++ b/src/api/paper/question/index.ts @@ -25,3 +25,12 @@ export const removeQuestion = (ids: string[]) => { return request.delete({ url: '/exam/question/' + ids}) } +// 新增试题 +export function addQuestion(data: any) { + return request.post({url: '/exam/question', data}); +} + +// 修改试题 +export function editQuestion(data: any) { + return request.put({url: '/exam/question', data}); +} \ No newline at end of file diff --git a/src/views/paper/question/ChoiceForm.vue b/src/views/paper/question/ChoiceForm.vue index 55995e4..c0c3cb2 100644 --- a/src/views/paper/question/ChoiceForm.vue +++ b/src/views/paper/question/ChoiceForm.vue @@ -13,19 +13,31 @@ - + - + + + + + + - + + + + + + + + @@ -36,8 +48,40 @@ - - + + + + + + + + + + + + + + + + + + + + + {{ dict.label }} + + + + + + + + + @@ -237,14 +281,10 @@