Jelajahi Sumber

Merge branch 'develop3.0-tmd' of http://106.12.23.251:10080/TEAMMODEL/TEAMModelOS into develop3.0-tmd

CrazyIter_Bin 4 tahun lalu
induk
melakukan
0a5e48bd62

+ 118 - 107
TEAMModelOS/ClientApp/src/assets/student-web/component_styles/lesson-testpop.css

@@ -1,7 +1,6 @@
 .lesson-test-pop {
 .lesson-test-pop {
   position: fixed;
   position: fixed;
   width: 100%;
   width: 100%;
-  /* Full width (cover the whole page) */
   height: 100%;
   height: 100%;
   overflow-y: scroll;
   overflow-y: scroll;
   overflow-x: hidden;
   overflow-x: hidden;
@@ -31,6 +30,12 @@
     width: 65%;
     width: 65%;
     border-radius: 6px;
     border-radius: 6px;
 }
 }
+.compose-item {
+    display: flex;
+    margin-left: 10px;
+    max-height: 300px;
+    overflow-y: scroll;
+}
 .lesson-test-pop .warmMessage {
 .lesson-test-pop .warmMessage {
     z-index: 999;
     z-index: 999;
 }
 }
@@ -39,21 +44,7 @@
         right: 10%;
         right: 10%;
         top: 3px;
         top: 3px;
     }
     }
-@media screen and (max-width: 1366px) {
-  .lesson-test-pop .testTitle .ques-filter {
-    right: 15%;
-  }
-}
-@media screen and (max-width: 991px) {
-  .lesson-test-pop .testTitle .ques-filter {
-    right: 25%;
-  }
-}
-@media screen and (max-width: 767px) {
-  .lesson-test-pop .testTitle .ques-filter {
-    left: 38%;
-  }
-}
+
 .lesson-test-pop .testTitle .ques-filter .filter-text {
 .lesson-test-pop .testTitle .ques-filter .filter-text {
   padding: 2px 7px;
   padding: 2px 7px;
   border-radius: 4px;
   border-radius: 4px;
@@ -62,11 +53,6 @@
   font-weight: bolder;
   font-weight: bolder;
   background-color: rgba(0, 0, 0, 0.1);
   background-color: rgba(0, 0, 0, 0.1);
 }
 }
-@media screen and (max-width: 1366px) {
-  .lesson-test-pop .testTitle .ques-filter .filter-text {
-    right: 20%;
-  }
-}
 .lesson-test-pop .testTitle .ques-filter .filter-only {
 .lesson-test-pop .testTitle .ques-filter .filter-only {
   color: #00ad6c;
   color: #00ad6c;
 }
 }
@@ -78,11 +64,7 @@
 .lesson-test-pop .testTitleText {
 .lesson-test-pop .testTitleText {
   font-weight: 900;
   font-weight: 900;
 }
 }
-@media screen and (max-width: 991px) {
-  .lesson-test-pop .testTitleText .testTitleTextContent {
-    display: none;
-  }
-}
+
 .lesson-test-pop .practice-mode {
 .lesson-test-pop .practice-mode {
   margin: 0px 10px;
   margin: 0px 10px;
   background-color: rgba(0, 0, 0, 0.1);
   background-color: rgba(0, 0, 0, 0.1);
@@ -100,26 +82,8 @@
   top: -40px;
   top: -40px;
   width: 10%;
   width: 10%;
 }
 }
-@media screen and (max-width: 1366px) {
-  .lesson-test-pop .myProgressBar {
-    right: 20%;
-  }
-}
-@media screen and (max-width: 991px) {
-  .lesson-test-pop .myProgressBar {
-    right: 23%;
-  }
-}
-@media screen and (max-width: 767px) {
-  .lesson-test-pop .myProgressBar {
-    right: 30%;
-  }
-}
-@media screen and (max-width: 680px) {
-  .lesson-test-pop .myProgressBar {
-    display: none;
-  }
-}
+
+
 .lesson-test-pop .myTestProgressContent {
 .lesson-test-pop .myTestProgressContent {
   background-color: #64ae16;
   background-color: #64ae16;
   position: relative;
   position: relative;
@@ -159,28 +123,7 @@
 .lesson-test-pop .myTestProgresstitleEn {
 .lesson-test-pop .myTestProgresstitleEn {
   left: -60%;
   left: -60%;
 }
 }
-@media screen and (max-width: 1366px) {
-  .lesson-test-pop .myTestProgresstitle {
-    left: -40%;
-  }
-  .lesson-test-pop .myTestProgressNumEn {
-    display: none;
-  }
-  .lesson-test-pop .myTestProgressNum {
-    left: 75%;
-  }
-  .lesson-test-pop .myTestProgressNumEn {
-    display: none;
-  }
-}
-@media screen and (max-width: 991px) {
-  .lesson-test-pop .myTestProgresstitle {
-    left: -60%;
-  }
-  .lesson-test-pop .myTestProgressNum {
-    left: 65%;
-  }
-}
+
 .lesson-test-pop .submitBtn {
 .lesson-test-pop .submitBtn {
   outline: none;
   outline: none;
   width: 100px;
   width: 100px;
@@ -230,11 +173,7 @@
   background-color: #ffffff;
   background-color: #ffffff;
   left: 0px;
   left: 0px;
 }
 }
-@media screen and (max-width: 991px) {
-  .lesson-test-pop .questionArea {
-    height: auto;
-  }
-}
+
 .lesson-test-pop .questionContent {
 .lesson-test-pop .questionContent {
   padding: 40px 50px;
   padding: 40px 50px;
 }
 }
@@ -247,23 +186,15 @@
   margin-bottom: 12px;
   margin-bottom: 12px;
 }
 }
 .lesson-test-pop .questioDes {
 .lesson-test-pop .questioDes {
-  font-weight: 900;
-  font-size: 14px;
-}
-@media screen and (max-width: 767px) {
-  .lesson-test-pop .questioDes {
-    font-size: 12px;
-  }
+    font-weight: 900;
+    font-size: 14px;
+    min-height:550px;
 }
 }
+
 .lesson-test-pop .questionDesImg {
 .lesson-test-pop .questionDesImg {
   margin-top: 40px;
   margin-top: 40px;
 }
 }
-@media screen and (max-width: 767px) {
-  .lesson-test-pop .questionDesImg {
-    width: 40%;
-    margin-top: 20px;
-  }
-}
+
 .lesson-test-pop .hintIcon {
 .lesson-test-pop .hintIcon {
   font-size: 30px;
   font-size: 30px;
   cursor: pointer;
   cursor: pointer;
@@ -321,11 +252,6 @@
   box-shadow: -5px 2px 13px rgba(0, 0, 0, 0.1);
   box-shadow: -5px 2px 13px rgba(0, 0, 0, 0.1);
   right: 0px;
   right: 0px;
 }
 }
-@media screen and (max-width: 991px) {
-  .lesson-test-pop .ansArea {
-    position: relative;
-  }
-}
 .lesson-test-pop .pageCtl2 {
 .lesson-test-pop .pageCtl2 {
   position: relative;
   position: relative;
   float: right;
   float: right;
@@ -356,7 +282,8 @@
   border: none;
   border: none;
 }
 }
 .lesson-test-pop .checkAnswer {
 .lesson-test-pop .checkAnswer {
-  margin-top: 40px;
+  margin-top: 30px;
+  min-height:600px;
 }
 }
 .lesson-test-pop .questionNo {
 .lesson-test-pop .questionNo {
   margin-left: 25px;
   margin-left: 25px;
@@ -364,10 +291,7 @@
 }
 }
 .lesson-test-pop input[type="text"] {
 .lesson-test-pop input[type="text"] {
   width: 100%;
   width: 100%;
-  /*color: #24b880;*/
   font-size: 16px;
   font-size: 16px;
-  /*border: none;*/
-  /*border-bottom: 1px solid gray;*/
 }
 }
 .lesson-test-pop input[type="text"]:focus {
 .lesson-test-pop input[type="text"]:focus {
   outline: none;
   outline: none;
@@ -426,12 +350,7 @@
   border-collapse: collapse;
   border-collapse: collapse;
   font-weight: 500;
   font-weight: 500;
 }
 }
-@media screen and (max-width: 767px) {
-  .lesson-test-pop .ansSheet {
-    font-size: 10px;
-    width: 80%;
-  }
-}
+
 .lesson-test-pop .ansSheet .ansSheetQno {
 .lesson-test-pop .ansSheet .ansSheetQno {
   border: 2px solid rgba(117, 117, 117, 0.726);
   border: 2px solid rgba(117, 117, 117, 0.726);
   border-collapse: collapse;
   border-collapse: collapse;
@@ -470,22 +389,114 @@
 .lesson-test-pop .ansSheet .wrong-ans {
 .lesson-test-pop .ansSheet .wrong-ans {
   color: red;
   color: red;
 }
 }
+
 .lesson-test-pop .md-ansSheetGroup {
 .lesson-test-pop .md-ansSheetGroup {
-    margin-top: 10%;
-    overflow-y: scroll;
+    margin-top: 5%;
+    overflow-x: scroll;
     width: 100%;
     width: 100%;
 }
 }
+.lesson-test-pop .sm-ansSheetGroup {
+    margin-left: 7%;
+    margin-bottom: 10%;
+}
 @media screen and (max-width:992px) {
 @media screen and (max-width:992px) {
   .lesson-test-pop .md-ansSheetGroup {
   .lesson-test-pop .md-ansSheetGroup {
     display: none;
     display: none;
   }
   }
 }
 }
-.lesson-test-pop .sm-ansSheetGroup {
-  margin-left: 7%;
-  margin-bottom: 10%;
-}
 @media screen and (min-width: 992px) {
 @media screen and (min-width: 992px) {
   .lesson-test-pop .sm-ansSheetGroup {
   .lesson-test-pop .sm-ansSheetGroup {
     display: none;
     display: none;
   }
   }
 }
 }
+@media screen and (max-width: 1366px) {
+    .lesson-test-pop .testTitle .ques-filter {
+        right: 15%;
+    }
+
+        .lesson-test-pop .testTitle .ques-filter .filter-text {
+            right: 20%;
+        }
+
+    .lesson-test-pop .myProgressBar {
+        right: 20%;
+    }
+
+    .lesson-test-pop .myTestProgresstitle {
+        left: -40%;
+    }
+
+    .lesson-test-pop .myTestProgressNumEn {
+        display: none;
+    }
+
+    .lesson-test-pop .myTestProgressNum {
+        left: 75%;
+    }
+
+    .lesson-test-pop .myTestProgressNumEn {
+        display: none;
+    }
+}
+@media screen and (max-width: 991px) {
+    .lesson-test-pop .testTitle .ques-filter {
+        right: 25%;
+    }
+
+    .lesson-test-pop .testTitleText .testTitleTextContent {
+        display: none;
+    }
+
+    .lesson-test-pop .myProgressBar {
+        right: 23%;
+    }
+
+    .lesson-test-pop .myTestProgresstitle {
+        left: -60%;
+    }
+
+    .lesson-test-pop .myTestProgressNum {
+        left: 65%;
+    }
+
+    .lesson-test-pop .questionArea {
+        height: auto;
+    }
+
+    .lesson-test-pop .ansArea {
+        position: relative;
+    }
+}
+@media screen and (max-width: 767px) {
+    .lesson-test-pop .testTitle .ques-filter {
+        left: 38%;
+    }
+}
+@media screen and (max-width: 767px) {
+    .lesson-test-pop .ansSheet {
+        font-size: 10px;
+        width: 80%;
+    }
+}
+@media screen and (max-width: 767px) {
+    .lesson-test-pop .questionDesImg {
+        width: 40%;
+        margin-top: 20px;
+    }
+}
+@media screen and (max-width: 767px) {
+    .lesson-test-pop .myProgressBar {
+        right: 30%;
+    }
+}
+@media screen and (max-width: 680px) {
+    .lesson-test-pop .myProgressBar {
+        display: none;
+    }
+}
+@media screen and (max-width: 767px) {
+    .lesson-test-pop .questioDes {
+        overflow-y: scroll;
+        font-size: 12px;
+    }
+}

+ 36 - 255
TEAMModelOS/ClientApp/src/components/student-web/EventView/EventContentTypeTemplate/LessonTest.vue

@@ -1,35 +1,6 @@
 <template>
 <template>
     <div class="lesson-test">
     <div class="lesson-test">
         <br />
         <br />
-
-        <div v-if="showHint == true" class="warmMessage">
-            <div class="messageCard previewNextItemCard animate__animated animate__fadeInDown">
-                <h2>前往下一個活動</h2>
-                <div class="list-item-icon">
-                    <svg-icon v-if="nextItem.eventType == '作業'" icon-class="doc" />
-                    <svg-icon v-if="nextItem.eventType == '課前預習'"
-                              icon-class="selflearninginTime" />
-                    <svg-icon v-if=" nextItem.eventType == '評量' && nextItem.eventSubject != '綜合學科' "
-                              icon-class="test"
-                              class="reset-testIcon" />
-                    <svg-icon v-if=" nextItem.eventType == '評量' && nextItem.eventSubject == '綜合學科'"
-                              icon-class="multiTest"
-                              class="reset-testIcon" />
-                    <svg-icon v-if="nextItem.eventType == '投票'" icon-class="vote" />
-                </div>
-                <p class="nextItemTitle">
-                    <span class="typeMark">{{ nextItem.eventType }}</span>
-                    {{ nextItem.name }}
-                </p>
-                <div class="setting-checkbox">
-                    <input type="checkbox" v-model="unhintNextItem" />
-                    <label> 下次不再詢問,如欲恢復提示,於個人設定頁面勾選</label>
-                </div>
-                <br />
-                <button @click="cancelPreview()">取消,自行查看</button>
-                <button @click="gotoNextItem()">確定</button>
-            </div>
-        </div>
         <LessonTestPop :papers="selectData" v-if="this.$store.getters.getisOpenLessonTestPopNow"  />
         <LessonTestPop :papers="selectData" v-if="this.$store.getters.getisOpenLessonTestPopNow"  />
         <div>
         <div>
             <EventBasicInfo :paper="paperData" />
             <EventBasicInfo :paper="paperData" />
@@ -40,74 +11,10 @@
                     <span class="warm-hint">{{ $t("studentWeb.exam.timeoutHint") }}</span>
                     <span class="warm-hint">{{ $t("studentWeb.exam.timeoutHint") }}</span>
                 </div>
                 </div>
             </div>
             </div>
-            <!--<div
-      v-if="  this.$store.getters.getItemTitle.isDone == false && this.$store.getters.getItemTitle.endTime <= '2020.02.10' && this.$store.getters.getItemTitle.allowRetryNow == true " >
-      <br v-if="!ishideHint" />
-      <div class="dec animate__animated animate__bounceInLeft" v-if="!ishideHint">
-        <svg-icon icon-class="handonHint" class="warm-icon" />
-        <span
-          class="warm-hint"
-          v-if="this.$store.getters.getCurrentLaguage == 'tw'"
-        >
-          評量活動時間已結束,請於
-          <span class="retry-date">2020.02.13 23:59 前</span
-          >完成補考,逾時將以0分計算。
-        </span>
-        <span
-          class="warm-hint"
-          v-if="this.$store.getters.getCurrentLaguage == 'en'"
-        >
-          The exam task time has ended, please make up the exam
-          <span class="retry-date">before 2020.02.13 23:59</span> or your
-          score would be 0.
-        </span>
-        <span @click="hidehint()" class="close-hint-btn">
-          <Icon type="md-close" class="close-icon" />
-        </span>
-      </div>
-    </div>-->
             <div class="title-rect-group">
             <div class="title-rect-group">
                 <div class="title-rect" />
                 <div class="title-rect" />
                 <h2 class="title-rect-name">试卷链接</h2>
                 <h2 class="title-rect-name">试卷链接</h2>
             </div>
             </div>
-            <!--單一學科試卷-->
-            <!--<div
-      v-if="(
-         this.$store.getters.getItemTitle.isDone == false &&
-         this.$store.getters.getItemTitle.endTime > '2020.02.10' &&
-          this.$store.getters.getItemTitle.eventSubject != '綜合學科') ||
-        (this.$store.getters.getItemTitle.isDone == false &&
-          this.$store.getters.getItemTitle.endTime <= '2020.02.10' &&
-          this.$store.getters.getItemTitle.allowRetryNow == true &&
-          this.$store.getters.getItemTitle.eventSubject != '綜合學科')
-      "
-      class="tasks"
-      @click="opentest()"
-    >
-      <div class="title" v-if="getCurrentLang() == 'tw'">
-        <span style="position: relative; top: 1px">
-          <svg-icon icon-class="test" class="title-icon" />
-        </span>
-        {{ this.$store.getters.getItemTitle.eventSubject }}科試卷
-      </div>
-      <div class="title" v-if="getCurrentLang() == 'en'">
-        <span style="position: relative; top: 1px">
-          <svg-icon icon-class="test" class="title-icon" />
-        </span>
-        {{ transSubjecttoEn(this.$store.getters.getItemTitle.eventSubject) }}
-        Exam
-      </div>-->
-            <!--依試卷是否完成顯示打勾狀態-->
-            <!--<li
-        :class="{
-          finished: finishedfromTestPop() == true,
-          unfinished: finishedfromTestPop() == false,
-        }"
-      >
-        <Icon class="doneicon" type="ios-checkmark" size="36" />
-      </li>
-    </div>-->
-            <!----->
             <!--多學科試卷-->
             <!--多學科試卷-->
             <div v-if="paperData.length > 0 ">
             <div v-if="paperData.length > 0 ">
                 <ul v-for="(item, index) in paperData"
                 <ul v-for="(item, index) in paperData"
@@ -120,116 +27,48 @@
                         </span>
                         </span>
                         {{ item.subject.name }}科试卷
                         {{ item.subject.name }}科试卷
                     </li>
                     </li>
-                    <!--依試卷是否完成顯示打勾狀態-->
+                    <!--试卷是否已作答-->
                     <li :class="{ unfinished: item.stuAns[0].length == 0 ,finished:item.stuAns[0].length != 0 }">
                     <li :class="{ unfinished: item.stuAns[0].length == 0 ,finished:item.stuAns[0].length != 0 }">
                         <Icon class="doneicon" type="ios-checkmark" size="36" />
                         <Icon class="doneicon" type="ios-checkmark" size="36" />
                     </li>
                     </li>
                 </ul>
                 </ul>
             </div>
             </div>
-            <div class="title-rect-group" v-if="chooseData.subject !== undefined">
-                <div class="title-rect" />
-                <h2 class="title-rect-name">当前科目:{{chooseData.subject.name}}</h2>
-                <span v-show="isExamDown" @click="showTest" style="margin-left: 25px;color: #03966a;cursor:pointer">试卷详情</span>
-                <div>
+
+            <div class="title-rect-group">
+                <div v-if="chooseData.subject !== undefined">
+                    <div class="title-rect" />
+                    <h2 class="title-rect-name">当前科目:{{chooseData.subject.name}}</h2>
+                    <span v-show="isExamDown" @click="showTest" style="margin-left: 25px;color: #03966a;cursor:pointer">试卷详情</span>
                     <LessonTestReport :paperInfo="selectData" :examInfo="chooseData" />
                     <LessonTestReport :paperInfo="selectData" :examInfo="chooseData" />
                 </div>
                 </div>
-            </div>
-
-
-            <!--多學科試卷-->
-            <!--如果評量已結束則顯示學情報告分頁-->
-            <br />
-            <Tabs value="tab2"
-                  v-if="this.$store.getters.getItemTitle.isDone == true"
-                  :animated="false">
-                <TabPane :label="$t('studentWeb.exam.contentPage')" name="tab1">
-                    <!--<br />
-            <div class="dec animate__animated animate__headShake">
-                <span class="warm-hint">{{ $t("studentWeb.exam.practiceHint") }}</span>
-            </div>-->
-                    <!--單一學科試卷-->
-                    <!--<div class="title-rect-group">
-                <div class="title-rect" />
-                <h2 class="title-rect-name">{{ $t("studentWeb.exam.examLink") }}</h2>
-            </div>
-            <div v-if="this.$store.getters.getItemTitle.eventSubject != '綜合學科'"
-                 class="tasks"
-                 @click="opentest()">
-                <div class="title" v-if="getCurrentLang() == 'tw'">
-                    <span style="position: relative; top: 1px">
-                        <svg-icon icon-class="test" class="title-icon" />
-                    </span>
-                    {{ this.$store.getters.getItemTitle.eventSubject }}科試卷
+                <div class="load-box">
+                    <load :active.sync="isLoad"
+                          background-color="#000">
+                        <template slot="default">
+                            <svg-icon icon-class="loader" class="loader-icon" />
+                        </template>
+                    </load>
                 </div>
                 </div>
-                <div class="title" v-if="getCurrentLang() == 'en'">
-                    <span style="position: relative; top: 1px">
-                        <svg-icon icon-class="test" class="title-icon" />
-                    </span>
-                    {{ transSubjecttoEn(this.$store.getters.getItemTitle.eventSubject)}}
-                    Exam
-                </div>-->
-                    <!--依試卷是否完成顯示打勾狀態-->
-                    <!--li :class="{
-                finished: true,
-              }">
-              <Icon class="doneicon" type="ios-checkmark" size="36" />
-            </li-->
-                    <!--</div>-->
-                    <!----->
-                    <!--多學科試卷-->
-                    <!--<div v-if="paperData.length >1">
-            <ul v-for="(item, index) in multiSubject"
-                :key="index"
-                class="tasks"
-                @click="opentest()">
-                <li class="title" v-if="getCurrentLang() == 'tw'">
-                    <span style="position: relative; top: 1px">
-                        <svg-icon icon-class="test" class="title-icon" />
-                    </span>
-                    {{ item }}科試卷
-                </li>
-                <li class="title" v-if="getCurrentLang() == 'en'">
-                    <span style="position: relative; top: 1px">
-                        <svg-icon icon-class="test" class="title-icon" />
-                    </span>
-                    {{ transSubjecttoEn(item) }} Exam
-                </li>-->
-                    <!--依試卷是否完成顯示打勾狀態-->
-                    <!--</ul>
-            </div>-->
-                    <!----->
-                </TabPane>
-                <!--评量分析数据返回-->
-                <!--<TabPane :label="$t('studentWeb.exam.scorePage')" name="tab2">
-            <LessonTestReport />
-        </TabPane>-->
-            </Tabs>
+            </div>
         </div>
         </div>
     </div>
     </div>
 </template>
 </template>
 
 
 <script>
 <script>
+    import Load from "vue-loading-overlay";
+    import "vue-loading-overlay/dist/vue-loading.css";
     import EventBasicInfo from "../../EventBasicInfo";
     import EventBasicInfo from "../../EventBasicInfo";
-
     import LessonTestReport from "./LessonTestReport";
     import LessonTestReport from "./LessonTestReport";
     import LessonTestPop from "./LessonTestPop";
     import LessonTestPop from "./LessonTestPop";
-    //import mockdata from "@/api/newData";
-    //import mockdataEn from "@/api/newDataEn";
     export default {
     export default {
         name: "LessonTest",
         name: "LessonTest",
         components: {
         components: {
             EventBasicInfo,
             EventBasicInfo,
             LessonTestReport,
             LessonTestReport,
             LessonTestPop,
             LessonTestPop,
+            Load
         },
         },
         created() {
         created() {
-
-            //if(localStorage.getItem("lang") == ""){
-            //  this.mockdata = mockdata.eventList;
-            //}
-            //if (localStorage.getItem("lang") == "tw") {
-            //  this.mockdata = mockdata.eventList;
-            //} else this.mockdata = mockdataEn.eventList;
         },
         },
         mounted() {
         mounted() {
             this.getPaperData()
             this.getPaperData()
@@ -238,7 +77,6 @@
             return {
             return {
                 unhintNextItem: false,
                 unhintNextItem: false,
                 ishideHint: false,
                 ishideHint: false,
-                multiSubject: ["國文", "英文", "數學"],
                 //提示下一個
                 //提示下一個
                 mockdata: "",
                 mockdata: "",
                 nextItem: "", //存放下個活動預告
                 nextItem: "", //存放下個活動預告
@@ -247,9 +85,10 @@
                 paperData: [],
                 paperData: [],
                 openEva: false,
                 openEva: false,
                 selectData: {},
                 selectData: {},
-                isExam: false,
                 isExamDown: false, 
                 isExamDown: false, 
-                chooseData: {}
+                chooseData: {},
+                examData: [],
+                isLoad: false
             };
             };
         },
         },
         methods: {
         methods: {
@@ -279,9 +118,6 @@
                             this.paperData[i].stuAns = res.stuAns[i]
                             this.paperData[i].stuAns = res.stuAns[i]
                             this.paperData[i].stuScore = res.stuScore[i]
                             this.paperData[i].stuScore = res.stuScore[i]
                         }
                         }
-                        //this.getPaper(this.paperData[0])
-                        //this.chooseData = this.paperData[0]
-                        //console.log(this.chooseData)
                     })
                     })
                 }
                 }
             },
             },
@@ -292,67 +128,6 @@
                 var D = date.getDate() + ' '
                 var D = date.getDate() + ' '
                 return Y + M + D;
                 return Y + M + D;
             },
             },
-
-            getisHint(data) {
-                this.isHintNextItem = data;
-                this.previewNext();
-                if (localStorage.getItem("hintNextItem") != "false") {
-                    setTimeout(() => {
-                        this.showHint = true;
-                    }, 4000);
-                }
-
-                this.isHintNextItem = false;
-            },
-            cancelPreview() {
-                this.showHint = false;
-            },
-            gotoNextItem() {
-                if (this.unhintNextItem == true) {
-                    this.$store.commit("sethintNextItem", false);
-                }
-                if (this.nextItem != "allfinished") {
-                    this.$store.commit("ChangeItemName", this.nextItem);
-                    this.$router.push("/studentWeb/eventView#" + this.nextItem.eventID);
-                    this.$store.commit("SetisFromInfoPoptpScroll", true);
-                } else {
-                    this.$router.push("/studentWeb/homeView");
-                }
-            },
-            previewNext() {
-                this.isPreviewNextItem = true;
-                let eventPageType = ["課前預習", "評量", "作業", "投票"];
-                let nextItems = [];
-                for (let i = 0; i < this.mockdata.length; i++) {
-                    if (
-                        eventPageType.includes(this.mockdata[i].eventType) &&
-                        this.mockdata[i].isDone == false &&
-                        this.$store.getters.getFinishedItem.includes(this.mockdata[i].eventID ) == false
-                    ) {
-                        nextItems.push(this.mockdata[i]); //引導使用者前往下一個未完成的項目
-                    }
-                }
-                if (nextItems != "") {
-                    if (
-                        nextItems[0].eventName ==
-                        this.mockdata[this.mockdata.length - 1].eventName
-                    ) {
-                        this.nextItem = "allfinished";
-                    }
-                    this.nextItem = nextItems[0];
-                }
-            },
-            getCurrentLang() {
-                return localStorage.getItem("lang");
-            },
-            getNowdoneSubject() {
-                return this.$store.getters.getCurrentfinishedSubject;
-            },
-            finishedfromTestPop() {
-                return this.$store.getters.getFinishedItem.includes(
-                    this.$store.getters.getItemTitle.eventID
-                );
-            },
             hidehint() {
             hidehint() {
                 this.ishideHint = !this.ishideHint;
                 this.ishideHint = !this.ishideHint;
             },
             },
@@ -365,8 +140,8 @@
                 }
                 }
             },
             },
             async getPaper(data) {
             async getPaper(data) {
-                this.isExam = false
                 this.isExamDown = false
                 this.isExamDown = false
+                this.isLoad = true
                 this.selectData = {}
                 this.selectData = {}
                 this.chooseData = {}
                 this.chooseData = {}
                 if (data.blob !== undefined && data.blob !== "") {
                 if (data.blob !== undefined && data.blob !== "") {
@@ -376,8 +151,20 @@
                         code: key[(key.length - 1)],
                         code: key[(key.length - 1)],
                         blob: data.blob
                         blob: data.blob
                     }
                     }
-                    this.selectData = await this.$evTools.getStuPaper(code)
+                    let exam = {}
+                    for (let item of this.examData) {
+                        if (data.paperId == item.id) {
+                            exam = item
+                        }
+                    }
+                    if (exam.id == undefined) {
+                        this.selectData = await this.$evTools.getStuPaper(code)
+                        this.examData.push(this.selectData)
+                    } else {
+                        this.selectData = exam
+                    }
                     this.chooseData = data
                     this.chooseData = data
+                    this.isLoad = false
                     if (this.selectData.item.length > 0) {
                     if (this.selectData.item.length > 0) {
                         let k = 0
                         let k = 0
                         for (let item of data.stuAns) {
                         for (let item of data.stuAns) {
@@ -398,12 +185,6 @@
                     this.$store.commit("ToggleLessonTestPopWithSubject", this.chooseData)
                     this.$store.commit("ToggleLessonTestPopWithSubject", this.chooseData)
                 }
                 }
             },
             },
-            transSubjecttoEn(type) {
-                if (type == "國文") return "Chinese";
-                else if (type == "英文") return "English";
-                else if (type == "數學") return "Math";
-                else if (type == "綜合學科") return "Comprehensive";
-            },
         },
         },
         computed: {
         computed: {
             listData() {
             listData() {
@@ -414,7 +195,7 @@
             $route: {
             $route: {
                 handler(val, oldval) {
                 handler(val, oldval) {
                     this.isExamDown = false
                     this.isExamDown = false
-                    this.isExam = false
+                    this.examData = []
                     this.getPaperData()
                     this.getPaperData()
                 },
                 },
                 // 深度观察监听
                 // 深度观察监听

+ 4 - 14
TEAMModelOS/ClientApp/src/components/student-web/EventView/EventContentTypeTemplate/LessonTestPop.vue

@@ -89,7 +89,7 @@
                                 <div class="compose-box">
                                 <div class="compose-box">
                                     <span style="margin-left:10px">題目:</span>
                                     <span style="margin-left:10px">題目:</span>
                                     <br />
                                     <br />
-                                    <div style="display:flex;margin-left:10px">
+                                    <div class="compose-item">
                                         <span w>{{ getQue(queNo).parent + 1}}.</span>
                                         <span w>{{ getQue(queNo).parent + 1}}.</span>
                                         <!--题目渲染-->
                                         <!--题目渲染-->
                                         <div v-html="getQue(queNo).parentInfo.question"></div>
                                         <div v-html="getQue(queNo).parentInfo.question"></div>
@@ -134,7 +134,7 @@
                                     <div v-show="item == ''">
                                     <div v-show="item == ''">
                                         <br />
                                         <br />
                                     </div>
                                     </div>
-                                    <div class="anstext" v-show="item.length >= 0 && getQue(index).type != 'subjective' && getQue(index).type != 'complete'  ">
+                                    <div class="anstext" v-show="item.length >= 0 && getQue(index).type != 'subjective' && getQue(index).type != 'complete'  && getQue(index).type != 'judge' ">
                                         <span v-for="(sub, indexs) in item" :key="indexs">
                                         <span v-for="(sub, indexs) in item" :key="indexs">
                                             {{ sub }}
                                             {{ sub }}
                                             <span v-show="indexs + 1 != item.length">,</span>
                                             <span v-show="indexs + 1 != item.length">,</span>
@@ -142,6 +142,7 @@
                                     </div>         
                                     </div>         
                                     <div class="anstext" v-show="item.length >= 1">
                                     <div class="anstext" v-show="item.length >= 1">
                                         <span v-show="getQue(index).type == 'subjective' || getQue(index).type == 'complete'">已作答</span>
                                         <span v-show="getQue(index).type == 'subjective' || getQue(index).type == 'complete'">已作答</span>
+                                        <span v-show="getQue(index).type == 'judge'">{{checkers[index][0] == 'B' ? '对' : '错'}}</span>
                                     </div>
                                     </div>
                                 </td>
                                 </td>
                             </tr>
                             </tr>
@@ -186,7 +187,7 @@
                         </label>
                         </label>
                     </div>
                     </div>
                     <!--选择题选项-->
                     <!--选择题选项-->
-                    <div v-if=" getQue(queNo).type != 'judge' ">
+                    <div v-if=" getQue(queNo).type != 'judge' " >
                         <label class="testBtn"
                         <label class="testBtn"
                                v-for="(item, index) in getQue(queNo).option"
                                v-for="(item, index) in getQue(queNo).option"
                                :key="index">
                                :key="index">
@@ -197,12 +198,6 @@
                                    />
                                    />
                             <div class="testbg">
                             <div class="testbg">
                                 <Row :gutter="10">
                                 <Row :gutter="10">
-                                    <i-col :xs="8" :sm="8" :md="8" :lg="8">
-                                        <!-- <Img
-                                          class="testbgImg"
-                                          :src="getQue(queNo).qImg1 + [index]"
-                                        /> -->
-                                    </i-col>
                                     <i-col :xs="16" :sm="16" :md="16" :lg="16">
                                     <i-col :xs="16" :sm="16" :md="16" :lg="16">
                                         <p class="testtext" >
                                         <p class="testtext" >
                                             <div style="display:flex">
                                             <div style="display:flex">
@@ -216,17 +211,13 @@
                                 <div style="clear:both"></div>
                                 <div style="clear:both"></div>
                             </div>
                             </div>
                         </label>
                         </label>
-                        <div></div>
                     </div>
                     </div>
                 </div>
                 </div>
-
                 <!--切換頁-->
                 <!--切換頁-->
                 <div class="pageCtl2">
                 <div class="pageCtl2">
                     <button @click="preQ()" v-if="queNo != 0">
                     <button @click="preQ()" v-if="queNo != 0">
                         <Icon type="ios-arrow-back" />上一题
                         <Icon type="ios-arrow-back" />上一题
                     </button>
                     </button>
-                    <!--span>第{{queNo+1}}題</span-->
-                    <!--span>{{ this.$store.getters.getCurrentPhase+1 }}/3</span-->
                     <button @click="nextQ()"
                     <button @click="nextQ()"
                             v-if="queNo != (examInfo.length-1)"
                             v-if="queNo != (examInfo.length-1)"
                             :class="{ hintClick:queNo != (examInfo.length-1) && checkers[queNo] != ''}">
                             :class="{ hintClick:queNo != (examInfo.length-1) && checkers[queNo] != ''}">
@@ -242,7 +233,6 @@
 <script>
 <script>
     import Loading from "vue-loading-overlay";
     import Loading from "vue-loading-overlay";
     import "vue-loading-overlay/dist/vue-loading.css";
     import "vue-loading-overlay/dist/vue-loading.css";
-    import E from '@/utils/wangEditor.js'
     import Compose from './composePaper.vue'
     import Compose from './composePaper.vue'
     import Complete from './completePaper.vue'
     import Complete from './completePaper.vue'
     export default {
     export default {

+ 1 - 0
TEAMModelOS/ClientApp/src/components/student-web/EventView/EventContentTypeTemplate/composePaper.vue

@@ -70,6 +70,7 @@
                 //    //console.log(link); // 插入的链接
                 //    //console.log(link); // 插入的链接
                 //    return true; // 返回 true 表示校验成功
                 //    return true; // 返回 true 表示校验成功
                 //};
                 //};
+                this.editor.config.height = 200
                 this.editor.config.showLinkImg = false;
                 this.editor.config.showLinkImg = false;
                 // 下面两个配置,使用其中一个即可显示“上传图片”的tab。但是两者不要同时使用!!!
                 // 下面两个配置,使用其中一个即可显示“上传图片”的tab。但是两者不要同时使用!!!
                 this.editor.config.uploadImgShowBase64 = true; // 使用 base64 保存图片不建议使用这种,我只是图个方便
                 this.editor.config.uploadImgShowBase64 = true; // 使用 base64 保存图片不建议使用这种,我只是图个方便

+ 1 - 1
TEAMModelOS/ClientApp/src/view/student-web/App.vue

@@ -11,7 +11,7 @@
                           :class="{'menu-icon-close': this.$store.getters.getSidebarisOpen == false}" />
                           :class="{'menu-icon-close': this.$store.getters.getSidebarisOpen == false}" />
                 </span>
                 </span>
                 <span class="mytitle">{{ MyName }}</span>
                 <span class="mytitle">{{ MyName }}</span>
-                <!--<span class="pixel">{{ windowWidth }} * {{ windowHeight }} px</span>-->
+                <span class="pixel">{{ windowWidth }} * {{ windowHeight }} px</span>
                 <span class="profile-dropdown">
                 <span class="profile-dropdown">
                     <!--<Avatar
                     <!--<Avatar
                       class="avatar-link"
                       class="avatar-link"