From 6b787868de9cb80368f99b36cb29b0c3521a1d1e Mon Sep 17 00:00:00 2001 From: dongwug Date: Wed, 28 Sep 2022 12:16:42 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E4=BC=98=E5=8C=96=E5=BC=80=E5=A7=8B?= =?UTF-8?q?=E8=80=83=E8=AF=95=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/examination/ReadyExamination.vue | 67 +++++++++------------- 1 file changed, 26 insertions(+), 41 deletions(-) diff --git a/src/views/examination/ReadyExamination.vue b/src/views/examination/ReadyExamination.vue index e371851..fe37cab 100644 --- a/src/views/examination/ReadyExamination.vue +++ b/src/views/examination/ReadyExamination.vue @@ -24,17 +24,17 @@
{{q.text}}
-
-
{{j.text}}
+
{{o.text}}
@@ -154,13 +154,16 @@ export default { questions: [ { id: 1, + type: "judge", text: "1、控制计划是由工艺部门完成 (4分)", options: [ - { + { + id:1, text: "正确", select:"flase", }, { + id:2, text: "错误", select:"flase", }, @@ -168,13 +171,16 @@ export default { }, { id: 2, + type: "judge", text: "2、.PFMEA假定所设计的产品能满足设计要求", options: [ - { + { + id:1, text: "正确", select:"flase", }, { + id:2, text: "错误", select:"flase", }, @@ -182,33 +188,23 @@ export default { }, { id: 3, - text: "3、控制计划是由工艺部门完成 (4分)", - options: [ - { - text: "正确", - select:"flase", - }, - { - text: "错误", - select:"flase", - }, - ] - }, - { - id: 4, - text: "4、.PFMEA假定所设计的产品能满足设计要求", + type: "judge", + text: "3、PFMEA假定所设计的产品能满足设计要求 (4分)", options: [ { + id:1, text: "正确", select:"flase", }, { + id:2, text: "错误", select:"flase", }, ] }, ], + //判断题问题和选项(暂时被questions替代) // j_questions: [ // { // type: "judge", @@ -226,13 +222,6 @@ export default { // text: "3、PFMEA假定所设计的产品能满足设计要求 (4分)", // }, // ], - s_questions: [ - { - type: "choice", - id: 1, - text: "4、.FMEA 是一种( )工具(4分)", - }, - ], // j_options: [ // { // id: 1, @@ -245,6 +234,14 @@ export default { // selected: false, // }, // ], + + s_questions: [ + { + type: "choice", + id: 1, + text: "4、.FMEA 是一种( )工具(4分)", + }, + ], s_options: [ { id: 1, @@ -269,19 +266,7 @@ export default { ] }); const selectBtn = (value) => { - // let arr = state.questions; - const arry = [] - state.questions.map((item) => { - arry.push(item.options) - }) - console.log(arry) - console.log(value) - // arry.map((i) => { - // if (i.id === value.id) { - // i.selected = !i.selected; - // } - // }); - // state.questions = arry; + value.select = !value.select }; const selectBtn2 = (value) => { let arr = state.s_options;