zengyicheng 1 éve
szülő
commit
cf157106bb

+ 50 - 14
src/components/easy2/studyStudent.vue

@@ -470,15 +470,15 @@
                             >
                               {{ vitem.name }}.doc
                             </div>
-                            <!-- <div
+                            <div
                               class="downIcon"
-                              @click="downloadFile(vitem.url)"
+                              @click="checkFileFull1(vitem.type, vitem)"
                             >
                               <img
-                                src="../../assets/icon/newIcon/down.png"
+                                src="../../assets/icon/newIcon/allScreen.png"
                                 alt
                               />
-                            </div> -->
+                            </div>
                           </div>
                           <div class="navListItem" v-if="vitem.type == 8">
                             <div
@@ -488,15 +488,15 @@
                             >
                               {{ vitem.title ? vitem.title : vitem.url }}
                             </div>
-                            <!-- <div
+                            <div
                               class="downIcon"
-                              @click="downloadFile(vitem.url)"
+                              @click="checkFileFull1(vitem.type, vitem)"
                             >
                               <img
-                                src="../../assets/icon/newIcon/down.png"
+                                src="../../assets/icon/newIcon/allScreen.png"
                                 alt
                               />
-                            </div> -->
+                            </div>
                           </div>
                           <div class="navListItem" v-if="vitem.type == 3">
                             <div
@@ -507,24 +507,36 @@
                               <span v-if="vitem.text">{{ vitem.text }}-</span
                               >{{ vitem.name }}
                             </div>
-                            <div class="downIcon" @click="downloadFile2(vitem)">
+                            <div
+                              class="downIcon"
+                              @click="checkFileFull1(vitem.type, vitem)"
+                            >
                               <img
-                                src="../../assets/icon/newIcon/down.png"
+                                src="../../assets/icon/newIcon/allScreen.png"
                                 alt
                               />
                             </div>
+                            <div class="downIcon" @click="downloadFile2(vitem)">
+                              <img src="../../assets/icon/newIcon/down.png" alt />
+                            </div>
                           </div>
                           <div class="navListItem" v-if="vitem.type == 12">
                             <div class="navText" @click="downloadFile2(vitem)">
                               <span v-if="vitem.text">{{ vitem.text }}-</span
                               >{{ vitem.name }}
                             </div>
-                            <div class="downIcon" @click="downloadFile2(vitem)">
+                            <div
+                              class="downIcon"
+                              @click="checkFileFull1(vitem.type, vitem)"
+                            >
                               <img
-                                src="../../assets/icon/newIcon/down.png"
+                                src="../../assets/icon/newIcon/allScreen.png"
                                 alt
                               />
                             </div>
+                            <div class="downIcon" @click="downloadFile2(vitem)">
+                              <img src="../../assets/icon/newIcon/down.png" alt />
+                            </div>
                           </div>
                           <div class="navListItem" v-if="vitem.type == 13">
                             <div
@@ -559,13 +571,16 @@
                               </div>
                               <div
                                 class="downIcon"
-                                @click="downloadFile2(vitem)"
+                                @click="checkFileFull1(vitem.type, vitem)"
                               >
                                 <img
-                                  src="../../assets/icon/newIcon/down.png"
+                                  src="../../assets/icon/newIcon/allScreen.png"
                                   alt
                                 />
                               </div>
+                              <div class="downIcon" @click="downloadFile2(vitem)">
+                                <img src="../../assets/icon/newIcon/down.png" alt />
+                              </div>
                             </div>
                           </div>
                         </div>
@@ -17099,6 +17114,26 @@ export default {
       this.fulltype = type;
       this.fullUrl = url;
     },
+    checkFileFull1(t, f) {
+      this.fullDialogVisible = true;
+      if (t == 6) {
+        this.fulltype = 1;
+        this.fullUrl = f;
+      } else if (t == 8) {
+        this.fulltype = 2;
+        this.fullUrl = f.url;
+      } else if (
+        f.url.split(".")[f.url.split(".").length - 1].toLocaleUpperCase() ==
+        "PDF"
+      ) {
+        this.showType = 3;
+        this.fullUrl = f.url;
+      } else {
+        this.showType = 2;
+        this.fullUrl =
+          "https://view.officeapps.live.com/op/view.aspx?src=" + f.url;
+      }
+    },
     openSname(n, id, i, uid) {
       this.snameWid = id;
       this.worksSName = n;
@@ -19789,6 +19824,7 @@ export default {
 .elist_input {
   /* width: 40%; */
   width: 100%;
+  margin: 20px;
 }
 
 .elist_input .elist_input_box input {

+ 52 - 10
src/components/easy3/studyStudent.vue

@@ -418,9 +418,12 @@
                             >
                               {{ vitem.name }}.doc
                             </div>
-                            <div class="downIcon" @click="downloadFile2(vitem)">
+                            <div
+                              class="downIcon"
+                              @click="checkFileFull1(vitem.type, vitem)"
+                            >
                               <img
-                                src="../../assets/icon/newIcon/down.png"
+                                src="../../assets/icon/newIcon/allScreen.png"
                                 alt
                               />
                             </div>
@@ -433,9 +436,12 @@
                             >
                               {{ vitem.title ? vitem.title : vitem.url }}
                             </div>
-                            <div class="downIcon" @click="downloadFile2(vitem)">
+                            <div
+                              class="downIcon"
+                              @click="checkFileFull1(vitem.type, vitem)"
+                            >
                               <img
-                                src="../../assets/icon/newIcon/down.png"
+                                src="../../assets/icon/newIcon/allScreen.png"
                                 alt
                               />
                             </div>
@@ -449,24 +455,36 @@
                               <span v-if="vitem.text">{{ vitem.text }}-</span
                               >{{ vitem.name }}
                             </div>
-                            <div class="downIcon" @click="downloadFile2(vitem)">
+                            <div
+                              class="downIcon"
+                              @click="checkFileFull1(vitem.type, vitem)"
+                            >
                               <img
-                                src="../../assets/icon/newIcon/down.png"
+                                src="../../assets/icon/newIcon/allScreen.png"
                                 alt
                               />
                             </div>
+                            <div class="downIcon" @click="downloadFile2(vitem)">
+                              <img src="../../assets/icon/newIcon/down.png" alt />
+                            </div>
                           </div>
                           <div class="navListItem" v-if="vitem.type == 12">
                             <div class="navText" @click="downloadFile2(vitem)">
                               <span v-if="vitem.text">{{ vitem.text }}-</span
                               >{{ vitem.name }}
                             </div>
-                            <div class="downIcon" @click="downloadFile2(vitem)">
+                            <div
+                              class="downIcon"
+                              @click="checkFileFull1(vitem.type, vitem)"
+                            >
                               <img
-                                src="../../assets/icon/newIcon/down.png"
+                                src="../../assets/icon/newIcon/allScreen.png"
                                 alt
                               />
                             </div>
+                            <div class="downIcon" @click="downloadFile2(vitem)">
+                              <img src="../../assets/icon/newIcon/down.png" alt />
+                            </div>
                           </div>
                           <div class="navListItem" v-if="vitem.type == 13">
                             <div
@@ -498,13 +516,16 @@
                               </div>
                               <div
                                 class="downIcon"
-                                @click="downloadFile2(vitem)"
+                                @click="checkFileFull1(vitem.type, vitem)"
                               >
                                 <img
-                                  src="../../assets/icon/newIcon/down.png"
+                                  src="../../assets/icon/newIcon/allScreen.png"
                                   alt
                                 />
                               </div>
+                              <div class="downIcon" @click="downloadFile2(vitem)">
+                                <img src="../../assets/icon/newIcon/down.png" alt />
+                              </div>
                             </div>
                           </div>
                         </div>
@@ -16961,6 +16982,26 @@ export default {
       this.fulltype = type;
       this.fullUrl = url;
     },
+    checkFileFull1(t, f) {
+      this.fullDialogVisible = true;
+      if (t == 6) {
+        this.fulltype = 1;
+        this.fullUrl = f;
+      } else if (t == 8) {
+        this.fulltype = 2;
+        this.fullUrl = f.url;
+      } else if (
+        f.url.split(".")[f.url.split(".").length - 1].toLocaleUpperCase() ==
+        "PDF"
+      ) {
+        this.showType = 3;
+        this.fullUrl = f.url;
+      } else {
+        this.showType = 2;
+        this.fullUrl =
+          "https://view.officeapps.live.com/op/view.aspx?src=" + f.url;
+      }
+    },
     openSname(n, id, i, uid) {
       this.snameWid = id;
       this.worksSName = n;
@@ -19645,6 +19686,7 @@ export default {
 .elist_input {
   /* width: 40%; */
   width: 100%;
+  margin: 20px;
 }
 
 .elist_input .elist_input_box input {

+ 28 - 29
src/components/studyStudent.vue

@@ -56,7 +56,7 @@
           <div
             style="
               background: #fff;
-              margin: 15px 10px 15px 10px;
+              margin: 10px;
               border-radius: 8px;
             "
             v-for="(item, stageIndex) in navList"
@@ -482,9 +482,9 @@
                               <span v-if="vitem.text">{{ vitem.text }}-</span
                               >{{ vitem.name }}
                             </div>
-                            <!-- <div class="downIcon" @click="downloadFile2(vitem)">
+                            <div class="downIcon" @click="downloadFile2(vitem)">
                               <img src="../assets/icon/newIcon/down.png" alt />
-                            </div> -->
+                            </div>
                           </div>
 
                           <div class="navListItem" v-if="vitem.type == 6">
@@ -541,6 +541,9 @@
                                 alt
                               />
                             </div>
+                            <div class="downIcon" @click="downloadFile2(vitem)">
+                              <img src="../assets/icon/newIcon/down.png" alt />
+                            </div>
                           </div>
                           <div class="navListItem" v-if="vitem.type == 12">
                             <div class="navText" @click="downloadFile2(vitem)">
@@ -556,6 +559,9 @@
                                 alt
                               />
                             </div>
+                            <div class="downIcon" @click="downloadFile2(vitem)">
+                              <img src="../assets/icon/newIcon/down.png" alt />
+                            </div>
                           </div>
                           <div class="navListItem" v-if="vitem.type == 13">
                             <div
@@ -565,9 +571,9 @@
                             >
                               {{ vitem.name }}
                             </div>
-                            <!-- <div class="downIcon" @click="downloadFile2(vitem)">
+                            <div class="downIcon" @click="downloadFile2(vitem)">
                               <img src="../assets/icon/newIcon/down.png" alt />
-                            </div> -->
+                            </div>
                           </div>
                         </div>
                         <div
@@ -594,6 +600,15 @@
                                   alt
                                 />
                               </div>
+                              <div
+                                class="downIcon"
+                                @click="downloadFile2(vitem)"
+                              >
+                                <img
+                                  src="../assets/icon/newIcon/down.png"
+                                  alt
+                                />
+                              </div>
                             </div>
                           </div>
                         </div>
@@ -605,30 +620,19 @@
               <div style="width: calc(100% - 315px)">
                 <div
                   style="padding: 10px 0 0; width: 95%; margin: 0 auto"
-                  v-if="
-                    showType != 1 ||
-                    (showType != 2 &&
-                      pptImgUrl1.indexOf(
-                        'https://view.officeapps.live.com/op/view.aspx?src='
-                      ) != -1)
-                  "
+                  v-if="showType == 2 || showType == 3"
                 >
-                  <!-- <el-button
+                  <el-button
                     type="primary"
                     class="newButton"
                     @click="checkFileFull(showType, pptImgUrl1)"
                     >全屏查看</el-button
-                  > -->
+                  >
                   <el-button
                     type="primary"
                     class="newButton"
-                    v-if="
-                      showType != 2 &&
-                      pptImgUrl1.indexOf(
-                        'https://view.officeapps.live.com/op/view.aspx?src='
-                      ) != -1
-                    "
-                    @click="downloadFile2(pptImgUrl1)"
+                    @click="downloadFile(pptImgUrl1)"
+                    v-if="showType != 2"
                     >文件下载</el-button
                   >
                   <el-button
@@ -7039,7 +7043,7 @@
             </div>
             <div
               class="vedioBox"
-              style="margin-top: 10px"
+              style="margin-top: 10px;"
               v-if="
                 chapInfoList[courseType].chapterInfo[0].taskJson[taskCount]
                   .eList &&
@@ -16406,13 +16410,8 @@ export default {
         target: document.body,
         text: "文件加载中...",
       });
-      let url2 = "";
+      let url2 = f.url;
       let _url2 = "";
-      if (this.showType == 4) {
-        url2 = f;
-      } else {
-        url2 = f.url;
-      }
       if (
         url2.indexOf("https://view.officeapps.live.com/op/view.aspx?src=") != -1
       ) {
@@ -18908,7 +18907,7 @@ export default {
 .elist_input {
   /* width: 40%; */
   width: 45%;
-  margin: 20px 20px 0 20px;
+  margin: 20px;
 }
 
 .elist_input .elist_input_box input {