Sfoglia il codice sorgente

调查问卷去除分数等信息

canghailong 6 mesi fa
parent
commit
b9b4650500

+ 2 - 2
src/views/student/exam/components/QuestionAnswerShow.vue

@@ -83,11 +83,11 @@
 				<a-rate :value="question.difficult" disabled class="question-show-item" />
 			</div>
 			<br />
-			<div class="question-answer-show-item" style="line-height: 1.8">
+			<div class="question-answer-show-item" style="line-height: 1.8" v-if="paperType!=5">
 				<span class="question-show-item">解析:</span>
 				<span v-html="question.analyze" class="q-item-span-content" />
 			</div>
-			<div class="question-answer-show-item">
+			<div class="question-answer-show-item" v-if="paperType!=5">
 				<span class="question-show-item">正确答案:</span>
 				<!-- eslint-disable-next-line vue/no-v-html -->
 				<span v-if="[1, 2, 5].includes(qType)" v-html="question.correct" class="q-item-span-content" />

+ 15 - 6
src/views/student/exam/paper/do.vue

@@ -11,7 +11,7 @@
 						{{ item.itemOrder }}
 					</a-tag>
 				</span>
-				<span class="do-exam-time" v-if="form.paperType!=5">
+				<span class="do-exam-time" v-if="form.paperType != 5">
 					<label>剩余时间:</label>
 					<label>{{ formatSeconds(remainTime) }}</label>
 				</span>
@@ -30,7 +30,7 @@
 		<a-layout class="app-item-contain">
 			<a-layout-header class="align-center">
 				<h1>{{ form.name }}</h1>
-				<div v-if="form.paperType!=5">
+				<div v-if="form.paperType != 5">
 					<span class="question-title-padding">试卷总分:{{ form.score }}</span>
 					<span class="question-title-padding">考试时间:{{ form.suggestTime }}分钟</span>
 				</div>
@@ -156,9 +156,19 @@
 		examPaperAnswerApi
 			.answerSubmit(answer)
 			.then((re) => {
+				let modelParams = {}
+				if (form.paperType != 5) {
+					modelParams = {
+						title: '考试结果',
+						content: `试卷得分:${re}分`
+					}
+				} else {
+					modelParams = {
+						title: '提交成功'
+					}
+				}
 				Modal.success({
-					title: '考试结果',
-					content: `试卷得分:${re}分`,
+					...modelParams,
 					okText: '返回',
 					onOk: () => {
 						// 发送消息
@@ -198,5 +208,4 @@
 			title: form.name
 		}
 	})
-	</script>
-	
+</script>