Jelajahi Sumber

修改导出报告,排序工具问题

11wqe1 1 tahun lalu
induk
melakukan
4602fbe1e1
1 mengubah file dengan 33 tambahan dan 20 penghapusan
  1. 33 20
      src/components/pages/components/worksDetail2.vue

+ 33 - 20
src/components/pages/components/worksDetail2.vue

@@ -1452,9 +1452,10 @@
                           </div>
                         </div>
                         <div class="worksTarget"><span>目标</span></div>
+                        <!-- {{ worksDetail[sIndex] }}  -->
                         <div class="worksTargetCon">
-                            <div v-for="item in worksDetail[sIndex].eList" :key="item">
-                              <span v-if="!item.target"> {{ item.target }}</span>
+                            <div v-for="(item,tarIndex) in worksDetail[sIndex].eList" :key="tarIndex">
+                              <span v-if="item.target"> {{ item.target }}</span>
                             </div>
                         </div>
                       </div>
@@ -2537,6 +2538,8 @@ export default {
                   detail: eListOld[key].detail,
                   score: eListOld[key].score,
                   value: eListOld[key].value,
+                  isai: eListOld[key].isai,
+                  target: eListOld[key].target
                 };
               });
               eList = eListNew;
@@ -2586,6 +2589,8 @@ export default {
                         detail: eListOld[key].detail,
                         score: eListOld[key].score,
                         value: eListOld[key].value,
+                        isai: eListOld[key].isai,
+                        target: eListOld[key].target
                       };
                     });
                     eList = eListNew;
@@ -3227,6 +3232,7 @@ export default {
             });
           }
 
+          //#region 
           // for (var i = 0; i < pptInfo.length; i++) {
           //   var a = ["PPT", "PPTX", "XLSX", "XLS", "DOC", "DOCX"];
           //   if (
@@ -3260,7 +3266,7 @@ export default {
           //     });
           //   }
           // }
-
+//#endregion
           for (var i = 0; i < answerInfo.length; i++) {
             const element = answerInfo[i];
             workJson.answerInfo.push({
@@ -3318,7 +3324,7 @@ export default {
           for (var i = 0; i < lccjInfo.length; i++) {
             var lccj = lccjInfo[i];
             workJson.lccjInfo.push({
-              lccjInfo: JSON.parse(lccj.content)[0],
+              lccjInfo: JSON.parse(lccj.content),
               score: lccjInfo[i].score
                 ? JSON.parse(lccjInfo[i].score).wScore
                 : lccjInfo[i].score,
@@ -3555,23 +3561,29 @@ export default {
           //   }
           // }
 
+            //  console.log(workJson.lccjInfo)
+          
           var _lccjInfo = "";
-          if (workJson.lccjInfo.length > 0) {
+          if (workJson.lccjInfo[0].lccjInfo.length > 0) {
             var _lccjInfo = "<h3>排序<h3>";
-            for (var i = 0; i < workJson.lccjInfo.length; i++) {
+            for (var i = 0; i < workJson.lccjInfo[0].lccjInfo.length; i++) {
               var _div = document.createElement("div");
-              _div.innerHTML = `<h4>第一题${workJson.lccjInfo[i].lccjInfo.sentenceTitle}</h4> `;
+              _div.innerHTML = `<h4>第${i+1}题${workJson.lccjInfo[0].lccjInfo[i].sentenceTitle}</h4> `;
               var _div2 = document.createElement("div");
-              for (
-                var j = 0;
-                j < workJson.lccjInfo[i].lccjInfo.chooseSenList.length;
-                j++
-              ) {
-                _div2.innerHTML += ` 句子 ${j + 1} : ${
-                  workJson.lccjInfo[i].lccjInfo.chooseSenList[j]
-                }`;
-              }
-
+              // for (
+              //   var j = 0;
+              //   j < workJson.lccjInfo[0][lccjInfo][i].chooseSenList.length;
+              //   j++
+              // ) {
+              //   _div2.innerHTML += ` 句子 ${j + 1} : ${
+              //     workJson.lccjInfo[0][lccjInfo][i].chooseSenList[j]
+              //   }`;
+              // }
+              _div2.innerHTML+= ` 句子 ${i + 1}:${ workJson.lccjInfo[0].lccjInfo[i].addSentence.join(',')} 选择:${
+                  workJson.lccjInfo[0].lccjInfo[i].chooseSenList.join(',') 
+                } 答案:${
+                  workJson.lccjInfo[0].lccjInfo[i].rightAnswer.join(',') 
+                }`
               _div.innerHTML += `<div>${_div2.innerHTML}</div>`;
               _lccjInfo += `<div>${_div.innerHTML}</div>`;
             }
@@ -4108,7 +4120,7 @@ export default {
 }
 
 .rate_size >>> .el-rate__icon {
-  font-size: 25px;
+  font-size: 22px;
 }
 
 .rate_size >>> .el-icon-star-off {
@@ -4142,12 +4154,13 @@ export default {
   padding: 10px;
   border-radius: 5px;
   box-sizing: border-box;
+  margin-bottom: 10px;
 }
 .worksTargetCon > div {
   margin-bottom: 10px;
 }
-.worksTargetCon :nth-child(-1){
-  margin-bottom: 0;
+.worksTargetCon > div:last-child{
+  margin: 0 !important;
 }
 .moreSay {
   margin: 0px 0 5px 20px;