Selaa lähdekoodia

答题卡预览学生号显示

liurongli 6 kuukautta sitten
vanhempi
commit
28b7e6a54c

+ 6 - 3
src/views/analysisReport/studentPage/scrolReport/transcript_single.vue

@@ -277,7 +277,7 @@
         </div>
       </div>
     </template>
-    <div class="report_module" v-if="false">
+    <div class="report_module" v-if="true">
       <div class="module_title">
         <div class="title_left">历次考试分析</div>
         <div class="title_right report_button">
@@ -369,6 +369,7 @@ export default {
       },
       answerCard: {
         //答题卡
+        studentCode:'',
         loading: false,
         paperImageList: [] //答题卡图片
       },
@@ -582,7 +583,8 @@ export default {
         })
         .then(res => {
           if (res.code == 200 && res.data) {
-            this.answerCard.paperImageList = res.data.pageVOS || []
+            this.answerCard.paperImageList = res?.data?.pageVOS || [];
+            this.answerCard.studentCode = res?.data?.studentCode ?? ''
             //先添加总分数据
             let totalScore = {
               questionName: '总分',
@@ -600,6 +602,7 @@ export default {
             }
           } else {
             this.answerCard.paperImageList = []
+            this.answerCard.studentCode = '';
           }
         })
         .finally(() => {
@@ -609,7 +612,7 @@ export default {
     //答题卡预览
     OpenStudentPaper(index) {
       this.currentPageIndex = index //当选选中的第几页
-      this.paperTitle = `${this.pageName}_${this.userInfo.userName}【${this.userInfo.registrationCode}】`
+      this.paperTitle = `${this.pageName}_${this.userInfo.userName}【${this.answerCard.studentCode}】`
       this.showStudentPaperDialog = true
     },
     getMiddleNumber(arr) {