{"version":3,"file":"startPractice.53e3aae9.mjs","sources":["../../../../pages/practice/startPractice.vue"],"sourcesContent":["<template>\n  <NuxtLayout>\n    <div id=\"app\" class=\"exam_page\" v-if=\"controlShow\">\n      <div class=\"exam_header\">\n        <div class=\"header_flex\">\n          <div class=\"exit_exam\" @click=\"submit(true)\">退出练习</div>\n          <div class=\"exam_title\">{{info.practiceName}}</div>\n          <div class=\"exam_time_box\">\n            <el-button v-if=\"!ctrl.noTrue\" type=\"primary\" @click=\"queryAndSubmit\" class=\"pointer\">交卷</el-button>\n          </div>\n        </div>\n      </div>\n      <div class=\"exam_paper_box\" ref=\"box\">\n        <div class=\"exam_user_paper\">\n          <div class=\"exam_user_item\">\n            <div class=\"exam_user_top\">\n              <el-avatar :size=\"40\" :src=\"userInfo.headImg\"></el-avatar>\n            </div>\n            <div class=\"exam_user_bottom\">{{userInfo.nickname}}</div>\n          </div>\n          <div class=\"exam_user_item\">\n            <div class=\"exam_user_bottom\"><el-switch v-model=\"ctrl.next\" @change=\"handleChangeNext\" size=\"default\"></el-switch></div>\n            <div class=\"exam_user_top\">自动下一题</div>\n          </div>\n         <div class=\"exam_user_item\">\n           <div class=\"exam_user_bottom\"><el-switch v-model=\"ctrl.show\" @change=\"handleNextChange\" size=\"default\"></el-switch></div>\n           <div class=\"exam_user_top\">自动显示答案解析</div>\n         </div>\n          <div class=\"exam_user_item\">\n            <div class=\"exam_user_bottom\"><el-switch v-model=\"ctrl.noTrue\" @change=\"handleChangeAnswer\" size=\"default\"></el-switch></div>\n            <div class=\"exam_user_top\">背题模式</div>\n          </div>\n        </div>\n      <div class=\"exam_center\">\n        <div class=\"left\" v-loading=\"ctrl.loading\">\n          <template v-for=\"(p, index) in map.list.questionList\" :key=\"index\">\n            <div class=\"question_box\" :id=\"index\">\n              <problem-item\n                @updateUserAnswer=\"updateUserAnswer\"\n                :problem=\"p\"\n                :record-id=\"map.list.recordId\"\n                :index=\"index\"\n                :course-id=\"courseId\"\n                :question-start-time=\"map.questionStartTime\"\n                :is-analysis=\"ctrl.noTrue\"\n                :is-show-confirm=\"ctrl.next || ctrl.show\"\n              ></problem-item>\n              <div class=\"collect_item\" @click=\"collect(p)\">\n                <img\n                  v-if=\"!p.collectionType\"\n                  class=\"pointer\"\n                  src=\"@/assets/images/exam/icon_collection1.svg\"\n                  alt=\"\"\n                />\n                <img\n                  v-else\n                  class=\"pointer\"\n                  src=\"@/assets/images/exam/icon_collection2.svg\"\n                  alt=\"\"\n                />\n                <span class=\"pointer\" :class=\"{active_collect:p.collectionType}\">收藏</span>\n              </div>\n              <div class=\"analysis\" v-if=\"ctrl.noTrue || p.show\">\n                <div class=\"mgb20\" :class=\"{'inline-b mgr30': p.questionType < 4}\">\n                  <div class=\"analysis_item\" v-if=\"p.questionType === 5\">\n                    <span class=\"left_text\">正确答案：</span>\n                    <div v-html=\"p.questionAnswer || ''\"></div>\n                  </div>\n                  <div class=\"analysis_item\" v-else>\n                    <span class=\"left_text\">正确答案：</span>\n                    <span :class=\"{'blue_text': p.questionType < 4}\">{{getNum(p.questionAnswer,p.optionList,p.questionType)}}</span>\n                  </div>\n                </div>\n                <div class=\"mgb20\" :class=\"{'inline-b': p.questionType < 4}\">\n                  <div class=\"analysis_item\" v-if=\"p.questionType < 5\">\n                    您的答案：<span class=\"question_my\" :class=\"{'red_text': p.questionType < 4}\">{{getNumAnswer(p.userAnswer,p.optionList,p.questionType)}}</span>\n                  </div>\n                  <div class=\"analysis_item\" v-else>您的答案：<span class=\"question_my\">{{p.userAnswer || ''}}</span></div>\n                </div>\n                <div class=\"analysis_item\">\n                  <span class=\"left_text\">答案解析：</span>\n                  <div v-html=\"p.questionAnalysis || '无'\"></div>\n                </div>\n              </div>\n            </div>\n          </template>\n        </div>\n      </div>\n      <div class=\"exam_right\">\n        <div class=\"exam_right_title\">答题卡</div>\n        <div class=\"problem\">\n          <div class=\"problem_exam_box mgb20\">\n            <div class=\"problem_exam_box_item true\">答对</div>\n            <div class=\"problem_exam_box_item wrong\">答错</div>\n            <div class=\"problem_exam_box_item\">未答</div>\n            <div class=\"problem_exam_box_item collect\">收藏</div>\n          </div>\n          <div\n              class=\"mgb20\"\n          >\n            <div class=\"card_box\">\n                <span\n                    :class=\"[\n                    'problem_num',\n                    p.collectionType?'collect_num':'',\n                    p.answerStatus === 1 ? 'active_num' : '',\n                    p.answerStatus === 2 ? 'wrong_num': ''\n                  ]\"\n                    v-for=\"(p, idx) in map.list.questionList\"\n                    :key=\"'key2' + idx\"\n                    @click=\"jumpProblem(idx)\"\n                >{{ idx + 1 }}</span\n                >\n            </div>\n          </div>\n        </div>\n      </div>\n      </div>\n    </div>\n  </NuxtLayout>\n</template>\n\n<script setup>\nimport { useUserStore } from \"@/stores/user\";\nimport { ElMessage, ElMessageBox } from \"element-plus\";\nimport {ref, onMounted, reactive, computed} from \"vue\";\nimport {\n  startPractice,\n  endPractice,\n  userOperateQuestion\n} from \"@/api/paper.js\";\nimport problemItem from \"@/components/practice/problemItem.vue\";\nimport { setStore } from \"@/utils/storage\";\nimport {getStore} from \"../../utils/storage\";\nimport cookie from \"@/utils/cookies\";\nlet cookieData = cookie.getShop()\nuseHead({\n  title:'练习-' + cookieData.shopName\n})\nlet info = ref(null)\nlet controlShow = ref(false)\nlet courseId = ref('')\nlet periodId = ref()\nlet  examType = ref(2)\n    const store = useUserStore();\n    const { getEnumList,getUserView } = store;\n    const userInfo = computed(()=>store.userView)\n    const map = reactive({\n      letter: 'ABCDEFGHIJkLMNOPQRSTUVWXYZ'.split(''),\n      index: 0,\n      relationalId: \"\", // 关联该试卷的id，如课程id\n      questionId: \"\", //当前试题id\n      collectionType: false, //当前试题的收藏状态\n      controlBool: true,\n      list: {\n        questionList: []\n      },\n      startTime: '',\n      questionStartTime: 0,\n      currentProblem: '',\n      courseTypeName: '',\n      subjectCourseId: ''\n    });\n    const opts = reactive({\n      questionTypeEnums: [],\n      difficultyLevelEnums: []\n    });\n    const ctrl = reactive({\n      loading: false,\n      show: false,\n      next:true,\n      save:false,\n      noTrue:false\n    })\n    const router = useRouter();\n    const route = useRoute()\n//router.beforeResolve((to, from, next)=>{\n//  if(to.path !== route.path) {\n//    if (!ctrl.save) {\n//      submit(true)\n//      next(false)\n//    } else {\n//      next()\n//    }\n//  }else{\n//    controlShow.value = to.query.controlShow === 'true'\n//    examType.value = parseInt(to.query.examType)\n//    courseId.value = to.query.courseId\n//    info.value = JSON.parse(getStore('examInfo'))\n//    next(false)\n//  }\n//})\n    const carousel = ref(\"\");\n    const getNumAnswer = (val,list,type) => {\n      if(!val) {\n        return ''\n      }\n      if(type === 5) {\n        return true\n      } else if(type === 4){\n        const arr = val.split('|')\n        return  arr.join('；')\n      }\n      if(list) {\n        if(type === 1) {\n          let num = null\n          list.forEach((el, i) => {\n            if (el.id === val && num === null) {\n              num = i\n            }\n          })\n          return map.letter[num]\n        }else if(type === 2){\n          let num = []\n          list.forEach((el, i) => {\n            if (val.indexOf(el.id) > -1 && num.indexOf(el.id) === -1) {\n              num.push(map.letter[i])\n            }\n          })\n          return  num.join(',')\n        }else if(type === 3){\n          return val\n        }\n      }else{\n        return val\n      }\n    }\n    const getNum = (val,list,type) => {\n      if(type === 5) {\n        return true\n      } else if(type === 4){\n        const arr = val.split('|')\n        return  arr.join('；')\n      }\n      if(list) {\n        if(type === 1) {\n          let num = null\n          list.forEach((el, i) => {\n            if (el.optionContent === val && num === null) {\n              num = i\n            }\n          })\n          return map.letter[num]\n        }else if(type === 2){\n          let num = []\n          list.forEach((el, i) => {\n            if (val.indexOf(el.optionContent) > -1 && num.indexOf(el.optionContent) === -1) {\n              num.push(map.letter[i])\n            }\n          })\n          return  num.join(',')\n        }else if(type === 3){\n          return val\n        }\n      }else{\n        return val\n      }\n    }\n    const handleChangeNext = (val) => {\n      if(val){\n        ctrl.noTrue = false\n      }\n    }\n    const handleNextChange = (val) => {\n      if(val) {\n        ctrl.noTrue = false\n      }\n    }\n    const queryAndSubmit = () => {\n      let status = map.list.questionList.every(function(i){\n        return (i.userAnswer != false && i.userAnswer != undefined)\n      })\n      if(!status){\n        ElMessageBox.confirm('您还有题目未答，确定交卷？','交卷提示',{\n          confirmButtonText:'确定',\n          cancelButtonText:'查看未答',\n          center:true\n        }).then(()=>{\n          submit(false)\n        }).catch(()=>{\n          let continueValue = true\n          map.list.questionList.forEach((el,index)=>{\n            if(!el.userAnswer && continueValue){\n              continueValue = false\n              document.getElementById(index).scrollIntoView()\n            }\n          })\n        })\n      } else {\n        ElMessageBox.confirm(\"确定提交练习吗？\", \"提示\", {\n          cancelButtonText: \"取消\",\n          confirmButtonText: \"确定\",\n          type: \"warning\"\n        }).then(() => {\n          const hm = new Date().getTime() - map.startTime.getTime()\n          endPractice({\n            recordId: map.list.recordId,\n            practiceTime: parseInt((hm % (1000 * 60)) / 1000)\n          }).then((r) => {\n            if(r) {\n              ctrl.save = true\n              let obj = {\n                recordId: map.list.recordId,\n                relationalId: courseId.value\n              }\n              Object.assign(obj, r)\n              obj.practiceName = info.value.practiceName\n              setStore('lastPracticeQuery',route.query)\n              setStore('practiceInfoAndResult', obj)\n              router.replace({\n                path:'/exam/result',\n                query: {\n                  type: 2\n                }\n              })\n            }\n          });\n        }).catch(() => {})\n      }\n    }\n    const handleChangeAnswer = (val) => {\n      if(val) {\n        ctrl.show = false\n        ctrl.next = false\n      }\n    }\n    const checkIfJumpNext = (userAnswer, problem, index) => { //判断答错答对跳下一题\n      if(ctrl.next && !ctrl.show) {\n        if (document.getElementById(index + 1))\n          document.getElementById(index + 1).scrollIntoView()\n      }\n      const nextAndShowAction = () => {\n        if(ctrl.next && ctrl.show) {\n          if (document.getElementById(index + 1))\n            document.getElementById(index + 1).scrollIntoView()\n        }\n      }\n      if (problem.questionType === 1) {\n        if (problem.correctAnswer && problem.correctAnswer.length > 0) {\n          if (userAnswer.indexOf(problem.correctAnswer) > -1) {\n            problem.answerStatus = 1 //answerStatus（用来标记答题卡的答对答错状态）：1答对，2答错\n            nextAndShowAction()\n          } else {\n            problem.answerStatus = 2\n          }\n        }\n      } else if (problem.questionType === 2) {\n        if (problem.correctAnswer && problem.correctAnswer.length > 0) {\n          const arr = []\n          problem.correctAnswer.forEach(i => {\n            if (userAnswer.indexOf(i) > -1) {\n              arr.push(i)\n            }\n          })\n          // 多选判断所选答案个数是否与正确答案个数一样（考虑正确答案全选同时也选了其他错误答案的情况）\n          if (arr.length === problem.correctAnswer.length && problem.correctAnswer.length === userAnswer.split('|')\n            .length) {\n              problem.answerStatus = 1\n              nextAndShowAction()\n          } else {\n            problem.answerStatus = 2\n          }\n        }\n      } else if (problem.questionType === 3) {\n        if (userAnswer === problem.questionAnswer) {\n          problem.answerStatus = 1\n          nextAndShowAction()\n        } else {\n          problem.answerStatus = 2\n        }\n      } else if (problem.questionType === 4 || problem.questionType === 5) {\n        if(!userAnswer) {\n          problem.answerStatus = ''\n        } else {\n          problem.answerStatus = 1\n        }\n        nextAndShowAction()\n      }\n    }\n    const setOptionStatus = (p) => {\n      if (p.questionType < 3) {\n        p.optionList.forEach(o => {\n          o.oStatus = 3 //默认状态\n          if (p.correctAnswer.indexOf(o.id) > -1) {\n            o.oStatus = 1 // 答对状态\n          } else {\n            if (p.userAnswer && p.userAnswer.indexOf(o.id) > -1) {\n              o.oStatus = 2 // 答错状态\n            }\n          }\n        })\n      }\n      if (p.questionType === 3) {\n        p.optionList.forEach((o) => {\n          o.oStatus = 3\n          if(p.userAnswer) {\n            if(o.optionContent == p.questionAnswer) {\n              o.oStatus = 1\n            } else {\n              if(o.optionContent == p.userAnswer) {\n                o.oStatus = 2\n              }\n            }\n          } else {\n            if(o.optionContent == p.questionAnswer) {\n              o.oStatus = 1\n            }\n          }\n        })\n      }\n    }\n    const updateUserAnswer = (d) => {\n      map.list.questionList.forEach((e,index) => {\n        if (e.id === d.questionId) {\n          console.log('e', e)\n          e.userAnswer = d.userAnswer;\n          if (e.questionType == 1 && d.userAnswer) {\n            checkIfJumpNext(d.userAnswer, e, index)\n          }\n          if (e.questionType == 2) {\n            if (d.userAnswer && d.userAnswer.length > 0) {\n              checkIfJumpNext(d.userAnswer, e, index)\n            } else {\n              e.answerStatus = ''\n            }\n          }\n          if (e.questionType == 3 && d.userAnswer) {\n            checkIfJumpNext(d.userAnswer, e, index)\n          }\n          if (e.questionType == 4 || e.questionType == 5) {\n            checkIfJumpNext(d.userAnswer, e, index)\n          }\n          setOptionStatus(e)\n          e.show = ctrl.show\n          if (ctrl.noTrue) {\n            e.show = false\n            //e.userAnswer = ''\n          }\n        }\n      })\n    };\n    const collect = (row) => {\n      const qId = row.questionId || row.id\n      if(!row.collectionType) {\n        userOperateQuestion({\n          errorQuestionAnswer: row.userAnswer || '',\n          handleType: false, //类型(默认为收藏可不传)：true:移除试题，false：收藏试题\n          operateType: 2, //1：错题、2：收藏\n          questionId: qId,\n          sourceId: courseId.value,\n          sourceType: 1 //1:课程中心、2:考试中心、3：班级中心\n        }).then(res => {\n          ElMessage.success(res)\n          row.collectionType = true\n        })\n      } else {\n        userOperateQuestion({\n          handleType: true, //类型(默认为收藏可不传)：true:移除试题，false：收藏试题\n          operateType: 2, //1：错题、2：收藏\n          questionId: qId,\n          sourceId: courseId.value,\n          sourceType: 1 //1:课程中心、2:考试中心、3：班级中心\n        }).then(res => {\n          ElMessage.success(res)\n          row.collectionType = false\n        })\n      }\n    }\n    const jumpProblem = (index) => {\n      document.getElementById(index).scrollIntoView()\n    }\n    const submit = (bool = true, isToResultPage = true) => {\n      if(bool) {\n        ElMessageBox.confirm(\"确定结束练习吗？\", \"提示\", {\n          cancelButtonText: \"取消\",\n          confirmButtonText: \"确定\",\n          type: \"warning\"\n        }).then(() => {\n          ctrl.save = true\n          const hm = new Date().getTime() - map.startTime.getTime()\n          endPractice({\n            recordId: map.list.recordId,\n            practiceTime: parseInt((hm % (1000 * 60)) / 1000)\n          }).then((r) => {\n            if(r) {\n              router.replace({\n                path: '/course/' + map.courseTypeName,\n                query: {\n                  id: map.courseTypeName === 'combine' || map.courseTypeName === 'subject' ? map.subjectCourseId : courseId.value\n                }\n              })\n            }\n          });\n        }).catch(() => {})\n      } else {\n        const hm = new Date().getTime() - map.startTime.getTime()\n        endPractice({\n          recordId: map.list.recordId,\n          practiceTime: parseInt((hm % (1000 * 60)) / 1000)\n        }).then((r) => {\n          if(r) {\n            ctrl.save = true\n\n            let obj = {\n              recordId: map.list.recordId,\n              relationalId: courseId.value\n            }\n            Object.assign(obj, r)\n            obj.practiceName = info.value.practiceName\n              setStore('lastPracticeQuery',route.query)\n              setStore('practiceInfoAndResult', obj)\n              if(isToResultPage) {\n                router.replace({\n                  path:'/exam/result',\n                  query: {\n                    type: 2\n                  }\n                })\n              }\n          }\n        });\n      }\n    }\n\n    onMounted(() => {\n      getUserView()\n      info.value = JSON.parse(getStore('practiceInfo'))\n      controlShow.value = route.query.controlShow === 'true'\n      courseId.value = route.query.courseId\n      examType.value = parseInt(route.query.examType)\n      map.courseTypeName = route.query.courseTypeName ? route.query.courseTypeName : ''\n      if(route.query.courseTypeName === 'combine' || route.query.courseTypeName === 'subject') {\n        map.subjectCourseId = route.query.subjectCourseId\n        courseId.value = route.query.subjectCourseId\n        periodId.value = route.query.periodId\n      }\n      if(controlShow.value) {\n        ctrl.loading = true\n        getEnumList(\"QuestionTypeEnum\", \"obj\").then((res) => {\n          opts.questionTypeEnums = res;\n        });\n        getEnumList(\"DifficultyLevelEnum\", \"obj\").then((res) => {\n          opts.difficultyLevelEnums = res;\n        });\n        const d = {\n          courseId: courseId.value,\n          periodId: periodId.value,\n          examType: examType.value\n        };\n        startPractice(d).then((res) => {\n          if(res) {\n            map.list = res\n            map.currentProblem = res.questionList[0]\n            map.questionId = res.questionList[0].id\n            map.collectionType = res.questionList[0].collectionType\n            map.startTime = new Date()\n            map.questionStartTime = new Date().getTime()\n            map.list.questionList.forEach((i,index) => {\n              if(i.questionType === 3) {\n                i.optionList = []\n                i.optionList.push({\n                  id: '对',\n                  optionContent: '对'\n                },{\n                  id: '错',\n                  optionContent: '错'\n                })\n              }\n              setOptionStatus(i)\n            })\n            ctrl.loading = false\n          }\n        }).catch((e) => {\n        })\n      }\n    })\n    onUnmounted(()=>{\n      if(!ctrl.save && map.list.recordId) {\n        submit(false, false)\n      }\n    })\n</script>\n\n<style lang=\"scss\" scoped>\n.exam_page {\n  position: fixed;\n  width: 100vw;\n  height: 100vh;\n  left: 0;\n  top: 0;\n  background: #f6f8fb;\n  z-index: 1001;\n}\n.close_exam {\n  position: absolute;\n  right: 30px;\n  top: 30px;\n}\n.exam_center {\n  width: 1058px;\n  margin-left: 146px;\n  .left {\n    position: relative;\n    background: #ffffff;\n    .question_box{\n      position: relative;\n      border-bottom: 1px solid #EBEEF5;\n      padding: 20px 33px 20px 30px;\n    }\n    .collect_item{\n      position: absolute;\n      right: 0px;\n      top: 20px;\n      min-width: 80px;\n      height: 24px;\n      display: flex;\n      align-items: center;\n      color: #999;\n    }\n  }\n  .right {\n    position: relative;\n    flex: 1;\n    background: #ffffff;\n    border-radius: 10px;\n    padding: 30px 0;\n    padding-bottom: 0;\n    .problem {\n      height: calc(100% - 60px);\n      overflow-y: auto;\n    }\n    .title_type {\n      padding: 0 30px;\n      margin-bottom: 10px;\n      font-size: 16px;\n      overflow: hidden;\n      white-space: nowrap;\n      text-overflow: ellipsis;\n      cursor: default;\n    }\n    .card_box {\n      padding: 0 30px;\n      .problem_num {\n        display: inline-block;\n        margin-right: 16px;\n        margin-bottom: 16px;\n        width: 40px;\n        height: 40px;\n        color: #999999;\n        border: 1px solid #ebeef5;\n        text-align: center;\n        line-height: 40px;\n        border-radius: 4px;\n        cursor: pointer;\n      }\n      .active_num {\n        border: 1px solid rgba(246, 24, 24, 0.1);\n        background: rgba(246, 24, 24, 0.1);\n        color: #f61818;\n      }\n      .now_num {\n        border: 1px solid rgba(34, 86, 246, 0.1);\n        background: rgba(34, 86, 246, 0.1);\n        color: #2256f6;\n      }\n    }\n    .right_bottom {\n      position: sticky;\n      bottom: 0;\n      width: 100%;\n      height: 60px;\n      z-index: 10;\n      box-sizing: border-box;\n      padding: 0 30px;\n      display: flex;\n      justify-content: space-between;\n      align-items: center;\n      border-top: 1px solid #ebeef5;\n      background: #fff;\n      color: #f61818;\n      img {\n        display: inline-block;\n        margin-right: 3px;\n      }\n    }\n  }\n}\n.exam_header{\n  width: 100%;\n  height: 54px;\n  background: #fff;\n  border-bottom: 1px solid #ebeef5;\n  .header_flex {\n    width: 1480px;\n    height: 100%;\n    margin: auto;\n    display: flex;\n    align-items: center;\n    justify-content: space-between;\n  }\n  .exit_exam{\n    font-style: normal;\n    font-weight: 400;\n    font-size: 14px;\n    color: #333333;\n    cursor: pointer;\n  }\n  .exam_title{\n    display: flex;\n    align-items: center;\n    justify-content: center;\n    font-style: normal;\n    font-weight: 400;\n    font-size: 18px;\n    color: #333333;\n  }\n  .exam_time_box{\n    min-width: 124px;\n    font-style: normal;\n    font-weight: 400;\n    font-size: 14px;\n    display: flex;\n    align-items: center;\n  }\n  .el-button{\n    width: 100px;\n    height: 32px;\n    border-radius: 4px;\n    margin-left: 24px;\n  }\n  .exam_time{\n    font-style: normal;\n    font-weight: 400;\n    font-size: 20px;\n    color: #F23C3C;\n  }\n}\n.exam_paper_box{\n  width: calc(100%);\n  max-width: 1480px;\n  padding-top: 16px;\n  max-height: 90vh;\n  overflow: auto;\n  margin: auto;\n  &::-webkit-scrollbar{\n    display: none;\n  }\n}\n.exam_right{\n  width: 260px;\n  background-color: #FFFFFF;\n  position: fixed;\n  top: 72px;\n  right: calc(50% - 740px);\n  .problem .card_box {\n    margin-top: 20px;\n    .problem_num {\n      display: inline-block;\n      margin-right: 12px;\n      margin-bottom: 12px;\n      width: 28px;\n      height: 28px;\n      color: #333333;\n      border: 1px solid #D9D9D9;\n      text-align: center;\n      line-height: 28px;\n      border-radius: 2px;\n      font-style: normal;\n      font-weight: 400;\n      font-size: 14px;\n      cursor: pointer;\n      &:nth-child(6n) {\n        margin-right: 0;\n      }\n    }\n    .collect_num{\n      position: relative;\n      &:after{\n        content: '';\n        width: 0;\n        height: 0;\n        border-top: 10px solid #FAC923;\n        border-right: 10px solid transparent;\n        position: absolute;\n        left: -1px;\n        top: -1px;\n      }\n    }\n    .active_num {\n      border: 1px solid rgba(61, 127, 255, 0.4);\n      background: rgba(61, 127, 255, 0.1);\n      color: #3D7FFF;\n    }\n    .now_num {\n      border: 1px solid #3D7FFF;\n      background: #3D7FFF;\n      color: #FFFFFF;\n    }\n    .wrong_num {\n      border: 1px solid rgba(242, 60, 60, 0.4);\n      background: rgba(242, 60, 60, 0.1);\n      color: #F23C3C;\n    }\n  }\n  .exam_right_title{\n    margin-top: 21px;\n    height: 54px;\n    width: 100%;\n    padding:18px 27px;\n    border-bottom:1px solid #EBEEF5;\n  }\n  .problem{\n    padding: 20px 16px;\n    max-height: calc(100vh - 172px);\n    overflow: auto;\n    padding-right: 11px;\n  }\n  .problem_exam_box{\n    width: 100%;\n    display: flex;\n    align-items: center;\n    justify-content: space-between;\n\n  }\n  .problem_exam_box_item{\n    font-style: normal;\n    font-weight: 400;\n    font-size: 12px;\n    color: #333333;\n    padding-left: 23px;\n    position: relative;\n    display: flex;\n    align-items: center;\n  }\n  .problem_exam_box_item:before{\n    content: '';\n    width: 16px;\n    height: 16px;\n    background: #FFFFFF;\n    border: 1px solid #D9D9D9;\n    border-radius: 1.6px;\n    left: 0;\n    position: absolute;\n  }\n  .problem_exam_box_item.wrong:before{\n    background: rgba(242, 60, 60, 0.1);\n    border-radius: 1.6px;\n    width: 16px;\n    height: 16px;\n    border: 1px solid rgba(242, 60, 60, 0.4);\n  }\n  .problem_exam_box_item.true:before{\n    background: rgba(61, 127, 255, 0.1);\n    border-radius: 1.6px;\n    width: 16px;\n    height: 16px;\n    border: 1px solid rgba(61, 127, 255, 0.4);\n  }\n  .problem_exam_box_item.collect:after{\n    content: '';\n    width: 0;\n    height: 0;\n    border-top: 10px solid #FAC923;\n    border-right: 10px solid transparent;\n    position: absolute;\n    left: 0;\n    top: 1px;\n  }\n  .title_type{\n    font-style: normal;\n    font-weight: 400;\n    font-size: 13px;\n    color: #333333;\n\n    margin-bottom: 14px;\n  }\n}\n.exam_user_paper{\n  background-color: #FFFFFF;\n  width: 130px;\n  position: fixed;\n  left: calc(50% - 740px);\n  top: 72px;\n  .exam_user_item{\n    width: 100%;\n    height: calc(100% / 3);\n    border-bottom: 1px solid #EBEEF5;\n    padding: 16px 9px;\n    display: flex;\n    align-items: center;\n    justify-content: center;\n    flex-direction: column;\n    .exam_user_top{\n      font-style: normal;\n      font-weight: 400;\n      font-size: 14px;\n    }\n  }\n  .exam_user_bottom{\n    font-style: normal;\n    font-weight: 400;\n    font-size: 16px;\n    color: #333333;\n    margin-top: 6px;\n  }\n}\n.analysis {\n  width: calc(100%);\n  padding: 20px 26px;\n  margin-top: 20px;\n  margin-bottom: 10px;\n  background: rgba(51, 51, 51, 0.05);\n  z-index: 11;\n  font-style: normal;\n  font-weight: 400;\n  font-size: 14px;\n  color: #666666;\n  position: relative;\n  .icon_success,.icon_danger{\n    display: none;\n    position: absolute;\n    width: 20px;\n    height: 20px;\n    left: 0;\n    top: 0;\n  }\n  .analysis_item+.analysis_item{\n    margin-top: 15px;\n  }\n  .analysis_item{\n    display: flex;\n    align-items: top;\n    .left_text {\n      min-width: 72px;\n    }\n  }\n  &.success{\n    background: rgba(61, 127, 255, 0.05);;\n  }\n  &.success .question_my,&.success .icon_success{\n    color: #3D7FFF;\n    display: block;\n  }\n  &.error{\n    background: rgba(242, 60, 60, 0.03);\n  }\n  &.error .question_my,&.error .icon_danger{\n    color: #F23C3C;\n    display: block;\n  }\n}\n.inline-b {\n  display: inline-block;\n}\n.blue_text {\n  color: #3D7FFF;\n}\n.red_text {\n  color: #F23C3C;\n}\n</style>\n"],"names":["cookieData","cookie","getShop","useHead","title","shopName","info","ref","controlShow","courseId","periodId","examType","store","useUserStore","getEnumList","getUserView","userInfo","computed","userView","map","reactive","letter","split","index","relationalId","questionId","collectionType","controlBool","list","questionList","startTime","questionStartTime","currentProblem","courseTypeName","subjectCourseId","opts","questionTypeEnums","difficultyLevelEnums","ctrl","loading","show","next","save","noTrue","router","useRouter","route","useRoute","getNumAnswer","val","type","join","num","forEach","el","i","id","indexOf","push","getNum","optionContent","handleChangeNext","handleNextChange","queryAndSubmit","every","userAnswer","ElMessageBox","confirm","cancelButtonText","confirmButtonText","then","hm","Date","getTime","endPractice","recordId","practiceTime","parseInt","r","obj","value","Object","assign","practiceName","setStore","query","replace","path","catch","center","submit","continueValue","document","getElementById","scrollIntoView","handleChangeAnswer","checkIfJumpNext","problem","nextAndShowAction","questionType","correctAnswer","length","answerStatus","arr","questionAnswer","setOptionStatus","p","optionList","o","oStatus","updateUserAnswer","d","e","bool","isToResultPage","onMounted","JSON","parse","getStore","res","startPractice","onUnmounted","row","qId","userOperateQuestion","handleType","operateType","sourceId","sourceType","ElMessage","success","errorQuestionAnswer"],"mappings":"2/DAuIA,IAAAA,EAAAC,EAAAC,UACAC,EAAA,CACAC,MAAA,MAAAJ,EAAAK,WAEA,IAAAC,EAAAC,EAAA,MACAC,EAAAD,GAAA,GACAE,EAAAF,EAAA,IACAG,EAAAH,IACAI,EAAAJ,EAAA,GACA,MAAAK,GAAAC,KACAC,YAAAA,GAAAC,YAAAA,IAAAH,GACAI,GAAAC,GAAA,IAAAL,GAAAM,WACAC,GAAAC,EAAA,CACAC,OAAA,6BAAAC,MAAA,IACAC,MAAA,EACAC,aAAA,GACAC,WAAA,GACAC,gBAAA,EACAC,aAAA,EACAC,KAAA,CACAC,aAAA,IAEAC,UAAA,GACAC,kBAAA,EACAC,eAAA,GACAC,eAAA,GACAC,gBAAA,KAEAC,GAAAf,EAAA,CACAgB,kBAAA,GACAC,qBAAA,KAEAC,GAAAlB,EAAA,CACAmB,SAAA,EACAC,MAAA,EACAC,MAAA,EACAC,MAAA,EACAC,QAAA,IAEAC,GAAAC,IACAC,GAAAC,IAiBAxC,EAAA,IACA,MAAAyC,GAAA,CAAAC,EAAArB,EAAAsB,KACA,IAAAD,EACA,MAAA,GAEA,GAAA,IAAAC,EACA,OAAA,EACA,GA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