|
@@ -255,6 +255,7 @@
|
|
|
class="submit-button"
|
|
|
><text>交卷</text
|
|
|
><countDown
|
|
|
+ @change="getThreeExamTime"
|
|
|
@end="submitExam"
|
|
|
background=""
|
|
|
:time="examTime"
|
|
@@ -282,21 +283,25 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <van-popup :zIndex="1000" round :show="submitExamVisible">
|
|
|
+ <van-popup :zIndex="1005" round :show="submitExamVisible">
|
|
|
<view class="tip1">
|
|
|
<view class="title"> 确认交卷 </view>
|
|
|
<view class="score">
|
|
|
<view class="score-list">
|
|
|
- <view class="score-dont"> 20</view>
|
|
|
+ <view class="score-dont">
|
|
|
+ {{ problemList.length - trueNum - falseNum }}</view
|
|
|
+ >
|
|
|
<view style="font-size: 28rpx; color: #8a9099">未答题数</view>
|
|
|
</view>
|
|
|
<view class="score-list"
|
|
|
- ><view class="score-rest" style="margin: 0 auto"> 19:59</view>
|
|
|
- <view style="font-size: 28rpx; color: #8a9099">未答题数</view></view
|
|
|
+ ><view class="score-rest" style="margin: 0 auto">
|
|
|
+ {{ restTime }}</view
|
|
|
+ >
|
|
|
+ <view style="font-size: 28rpx; color: #8a9099">剩余时间</view></view
|
|
|
>
|
|
|
<view class="score-list"
|
|
|
- ><view class="score-exam"> 2</view>
|
|
|
- <view style="font-size: 28rpx; color: #8a9099">未答题数</view></view
|
|
|
+ ><view class="score-exam"> {{ score }}</view>
|
|
|
+ <view style="font-size: 28rpx; color: #8a9099">考试得分</view></view
|
|
|
>
|
|
|
</view>
|
|
|
<view class="bottom">
|
|
@@ -312,7 +317,7 @@
|
|
|
<view
|
|
|
@click="
|
|
|
() => {
|
|
|
- submitExamVisible = true;
|
|
|
+ resultExamVisible = true;
|
|
|
}
|
|
|
"
|
|
|
class="right"
|
|
@@ -321,12 +326,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</van-popup>
|
|
|
- <van-popup
|
|
|
- custom-class="no-bg"
|
|
|
- :zIndex="1001"
|
|
|
- round
|
|
|
- :show="resultExamVisible"
|
|
|
- >
|
|
|
+ <van-popup :zIndex="1006" round :show="resultExamVisible">
|
|
|
<view class="tip2">
|
|
|
<view style="position: relative">
|
|
|
<image
|
|
@@ -365,8 +365,17 @@
|
|
|
>
|
|
|
<view class="tip2-bottom">
|
|
|
<!-- <view class="tip2-bottom-1">试试答题技巧,提分更快</view> -->
|
|
|
- <view class="tip2-bottom-2">现在交卷</view>
|
|
|
- <view class="tip2-bottom-3">继续答题</view>
|
|
|
+ <view @click="goPath" class="tip2-bottom-2">现在交卷</view>
|
|
|
+ <view
|
|
|
+ @click="
|
|
|
+ () => {
|
|
|
+ resultExamVisible = false;
|
|
|
+ submitExamVisible = false;
|
|
|
+ }
|
|
|
+ "
|
|
|
+ class="tip2-bottom-3"
|
|
|
+ >继续答题</view
|
|
|
+ >
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -377,11 +386,14 @@
|
|
|
|
|
|
<script>
|
|
|
import api from "@/api";
|
|
|
-const dayjs = require("dayjs");
|
|
|
+import utils from '@/utils'
|
|
|
import countDown from "@/components/countDown/index";
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
+ query:{
|
|
|
+
|
|
|
+ },
|
|
|
anLength: 7,
|
|
|
problemList: [
|
|
|
{
|
|
@@ -461,9 +473,12 @@ export default {
|
|
|
submitExamVisible: false,
|
|
|
resultExamVisible: false,
|
|
|
examTime: 1000 * 60 * 20,
|
|
|
+ restTime: "",
|
|
|
+ useTime: "",
|
|
|
};
|
|
|
},
|
|
|
- onLoad() {
|
|
|
+ onLoad(query) {
|
|
|
+ this.query = query
|
|
|
api.exam.studentThreeForceSelectTestQuestionInfoList().then((res) => {
|
|
|
if (Array.isArray(res.rows) && res.rows.length > 0) {
|
|
|
res.rows.forEach((element) => {
|
|
@@ -475,7 +490,17 @@ export default {
|
|
|
});
|
|
|
},
|
|
|
methods: {
|
|
|
+ goPath(url){
|
|
|
+ uni.navigateTo({
|
|
|
+ url:url+'?'+utils.mapToUrlQuery(this.query)
|
|
|
+ })
|
|
|
+ },
|
|
|
+ getThreeExamTime(a, b) {
|
|
|
+ this.restTime = a;
|
|
|
+ this.useTime = b;
|
|
|
+ },
|
|
|
submitExam(e) {
|
|
|
+ console.log(e);
|
|
|
uni.showModal({
|
|
|
title: "是否交卷",
|
|
|
success(res) {
|