lsc 2 лет назад
Родитель
Сommit
7c0bd3dfc4

BIN
src/assets/icon/fourthToolList/text.png


BIN
src/assets/icon/fourthToolList/zip.png


+ 50 - 28
src/components/student/studyStudent.vue

@@ -184,7 +184,7 @@
                   ">
                   <div style="padding: 15px 10px 0;">任务描述:</div>
 
-                  <div style="padding: 10px 10px 15px;word-break: break-word;" class="cont" v-html="
+                  <div style="padding: 10px 10px 15px;word-break: break-word;line-height: 27px;" class="cont" v-html="
                     chapInfoList[courseType].chapterInfo[0].taskJson[
                       taskCount
                     ].taskDetail
@@ -479,7 +479,9 @@
                           <img v-if="photo.type == 1" :src="photo.content" @click="previewImg(photo.content)">
                           <img v-if="photo.type == 10" :src="word" @click="openTable(photo.content)">
                           <img v-if="photo.type == 4" :src="word" @click="openFile(photo.content)">
+                          <img v-if="photo.type == 5" :src="video" @click="openVideo(photo.content)">
                           <img v-if="photo.type == 12" :src="word" @click="openText(photo.content)">
+                          <img v-if="photo.type == 13" :src="word" @click="downloadFile(photo.content)">
                           <div class="answerBg" v-if="photo.type == 3">
                             <!-- <div>{{ w.sName }}</div> -->
                             <el-tooltip class="item" effect="light" :content="photo.content" placement="top">
@@ -748,6 +750,17 @@
         <el-button @click="dialogVisibleText2 = false">关 闭</el-button>
       </span>
     </el-dialog>
+    <el-dialog title="查看视频" :visible.sync="videoVisible" :append-to-body="true" width="1000px"
+      :before-close="handleClose" class="dialog_diy1">
+      <div class="workd_media" style="height: 100%" v-if="videoDetail.sources">
+        <video-player class="video-player vjs-custom-skin" :playsinline="true" :options="videoDetail"
+          @play="onPlayerPlay($event)" style="width: 100%; height: 100%"></video-player>
+      </div>
+      <div slot="footer">
+        <el-button style="background: #409efe; color: #fff" @click="(videoVisible = false), (videoDetail = {})">
+          关 闭</el-button>
+      </div>
+    </el-dialog>
   </div>
 </template>
 
@@ -782,6 +795,8 @@ export default {
       dialogVisibleUpdateGroup: false,
       dialogVisibleDeleteGroup: false,
       dialogVisibleText2: false,
+      videoVisible: false,
+      videoDetail: {},
       sStudent: {},
       bzText: "",
       commentDetail: [],
@@ -1013,8 +1028,8 @@ export default {
       ManAarray: [],
       chapterlist: [],
       chapterIndex: 0,
-      courseUserid:'',
-      checkboxList3:[],
+      courseUserid: '',
+      checkboxList3: [],
     };
   },
   methods: {
@@ -1048,9 +1063,7 @@ export default {
       }
     },
     handleClose(done) {
-      if (this.videoDetail.sources && this.videoDetail.sources[0]) {
-        this.videoDetail.sources[0].src = "";
-      }
+      this.videoDetail = {}
       this.commentIndexJson = {};
       done();
     },
@@ -1406,8 +1419,8 @@ export default {
             this.courseDetail = res.data[0][0];
             this.courseUserid = res.data[0][0].userid;
             this.checkboxList3 = res.data[0][0].course_teacher
-                        ? res.data[0][0].course_teacher.split(",")
-                        : [];
+              ? res.data[0][0].course_teacher.split(",")
+              : [];
             this.chapInfo = JSON.parse(this.courseDetail.chapters)[
               this.courseType
             ];
@@ -1482,6 +1495,8 @@ export default {
                         _work.workContent = `(${_work.username})使用(文件上传)提交了:`
                       } else if (_tool.tool == 54) {
                         _work.workContent = `(${_work.username})使用(拍照上传)提交了:`
+                      } else if (_tool.tool == 55) {
+                        _work.workContent = `(${_work.username})使用(压缩文件)提交了:`
                       }
                       _tool.toolPhoto.push(_work);
                     }
@@ -1527,6 +1542,8 @@ export default {
                         _work.workContent = `(${_work.username})使用(文件上传)提交了:`
                       } else if (_tool.tool == 54) {
                         _work.workContent = `(${_work.username})使用(拍照上传)提交了:`
+                      } else if (_tool.tool == 55) {
+                        _work.workContent = `(${_work.username})使用(压缩文件)提交了:`
                       }
                       _tool.toolPhoto.push(_work);
                     }
@@ -1688,25 +1705,25 @@ export default {
     },
     getTeacher() {
       this.ManAarray = []
-            if(this.checkboxList3.indexOf(this.courseUserid) == -1){
-                this.checkboxList3.push(this.courseUserid)
-            }
-            let params = {
-                uid: this.checkboxList3.join(","),
-            };
-            this.ajax
-                .get(
-                    this.$store.state.api + "getAllUserById",
-                    params
-                )
-                .then((res) => {
-                    let teacherJuri = res.data[0];
-                    this.ManAarray = teacherJuri;
-                    this.setMan();
-                })
-                .catch((err) => {
-                    console.error(err);
-                });
+      if (this.checkboxList3.indexOf(this.courseUserid) == -1) {
+        this.checkboxList3.push(this.courseUserid)
+      }
+      let params = {
+        uid: this.checkboxList3.join(","),
+      };
+      this.ajax
+        .get(
+          this.$store.state.api + "getAllUserById",
+          params
+        )
+        .then((res) => {
+          let teacherJuri = res.data[0];
+          this.ManAarray = teacherJuri;
+          this.setMan();
+        })
+        .catch((err) => {
+          console.error(err);
+        });
     },
     addTools(t, i, index) {
       var a = 0;
@@ -2221,7 +2238,12 @@ export default {
 
         }, 0);
       })
-    }
+    },
+    openVideo(w) {
+      this.videoDetail = JSON.parse(JSON.stringify(this.playerOptions));
+      this.videoDetail.sources[0].src = w;
+      this.videoVisible = true;
+    },
   },
   directives: {
     // 使用局部注册指令的方式

+ 2 - 2
src/components/studyStudent.vue

@@ -653,7 +653,7 @@
                           <div v-if="tooC == 40">
                             <img @click="addTools(tooC, toolIndex, taskCount)"
                               src="../assets/icon/secondToolList/eval.png" alt />
-                            <div style="margin: 5px 0">学生评价</div>
+                            <div style="margin: 5px 0">个人评价</div>
                           </div>
                           <div v-if="tooC == 41">
                             <img @click="addTools(tooC, toolIndex, taskCount)"
@@ -3365,7 +3365,7 @@
         <el-button @click="fullDialogVisible = false">关 闭</el-button>
       </div> -->
     </el-dialog>
-    <el-dialog title="学生评价" :visible.sync="studentEvalDialogVisible" :append-to-body="true" width="800px"
+    <el-dialog title="个人评价" :visible.sync="studentEvalDialogVisible" :append-to-body="true" width="800px"
       :before-close="handleClose" class="dialog_diy">
       <div class="evalCss">
         <div class="nav">请选择星星进行评分</div>