Browse Source

导出学生报告

11wqe1 1 month ago
parent
commit
36fb2870b0

+ 26 - 21
src/components/pages/components/exportDataDialog.vue

@@ -121,13 +121,7 @@
             <div class="zhBlockCon2">
               <div>
                <span v-for="(i,index) in subject" :key="index">{{ i }}</span>
-
               </div>
-              <!-- <span>语文</span>
-              <span>数学</span>
-              <span>英语</span>
-              <span>化学</span>
-              <span>美术</span> -->
             </div>
           </div>
         </div>
@@ -1129,7 +1123,10 @@ export default {
         },
         xAxis: {
           type: "category",
-          data: this.stageList.map(item => item)
+          data: this.stageList.map(item => item),
+          axisTick: {
+            alignWithLabel: true // 使刻度线和标签对齐
+        }
         },
         yAxis: {
           type: "value",
@@ -1166,7 +1163,10 @@ export default {
         },
         xAxis: {
           type: "category",
-          data: this.stageList.map(item => item)
+          data: this.stageList.map(item => item),
+          axisTick: {
+            alignWithLabel: true // 使刻度线和标签对齐
+        }
         },
         yAxis: {
           type: "value",
@@ -1245,7 +1245,10 @@ export default {
         },
         xAxis: {
           type: "category",
-          data: this.stageList.map(item => item)
+          data: this.stageList.map(item => item),
+          axisTick: {
+            alignWithLabel: true // 使刻度线和标签对齐
+        }
         },
         yAxis: {
           type: "value",
@@ -1282,7 +1285,10 @@ export default {
         },
         xAxis: {
           type: "category",
-          data: this.stageList.map(item => item)
+          data: this.stageList.map(item => item),
+          axisTick: {
+            alignWithLabel: true // 使刻度线和标签对齐
+        }
         },
         yAxis: {
           type: "value",
@@ -1319,7 +1325,10 @@ export default {
         },
         xAxis: {
           type: "category",
-          data: this.stageList.map(item => item)
+          data: this.stageList.map(item => item),
+          axisTick: {
+            alignWithLabel: true // 使刻度线和标签对齐
+        }
         },
         yAxis: {
           type: "value",
@@ -1537,18 +1546,11 @@ export default {
   flex-direction: column;
   justify-content: space-between;
   /* flex-wrap: wrap; */
+  flex: 1;
   overflow: hidden;
 }
 .zhBlockCon2 > div {
-  /* font-size: 8px;
-  font-weight: 400;
-  color: rgba(0, 0, 0, 0.9);
-  background-color: rgba(243, 247, 253, 1);
-  border-radius: 2px;
-  padding: 1px 4px;
-  box-sizing: border-box;
-  margin-right: 4px;
-  margin-bottom: 2px; */
+
   display: flex;
   flex-wrap: wrap;
 
@@ -1560,7 +1562,9 @@ export default {
   color: rgba(0, 0, 0, 0.9);
   background-color: rgba(243, 247, 253, 1);
   border-radius: 2px;
-  padding: 1px 4px;
+  padding: 0px 4px;
+  height: 15px;
+  line-height: 15px;
   box-sizing: border-box;
   margin-right: 4px;
   margin-bottom: 2px;
@@ -1568,6 +1572,7 @@ export default {
 .zxt {
   height: 300px;
   width: 100%;
+  border: 1px solid #ccc;
   margin: 10px 0;
   background-color: rgba(255, 255, 255, 1);
   padding: 10px 0;

+ 3 - 1
src/components/pages/components/exportWorksDialog.vue

@@ -458,7 +458,9 @@
                           v-for="(r, tarIndex) in item.data"
                           :key="tarIndex"
                         >
-                          <span> {{ r.target }}</span>
+                        <span v-if="state == 5"> {{ r.target }}</span>
+                        <span v-else> {{ r.target[r.target.length-1] }}</span>
+                          <!-- <span> {{ r.target }}</span> -->
                         </div>
                       </div>
                     </div>

+ 10 - 10
src/components/pages/works.vue

@@ -566,19 +566,19 @@ export default {
     // 一键导出pdf
     exportPdfSetAllBtn(){
 
-      // this.$confirm("是否导出全部学生报告?批量打印需要等待一会哦。", "提示", {
-      //   confirmButtonText: "确定",
-      //   cancelButtonText: "取消",
-      //   type: "warning",
-      // })
-      // .then(() => {
+      this.$confirm("是否导出全部学生报告?批量打印需要等待一会哦。", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+      .then(() => {
         this.worksDialog = true;
         this.digNum = 1
         this.exportW++
-      // })
-      // .catch(_ => {
-      //   this.$confirm.visible=false
-      // })
+      })
+      .catch(_ => {
+        this.$confirm.visible=false
+      })
      
       
     },