Преглед на файлове

feat: 文档试卷查看

zhangjie преди 7 месеца
родител
ревизия
76d131eff6
променени са 1 файла, в които са добавени 8 реда и са изтрити 0 реда
  1. 8 0
      src/modules/course/components/CourseDocumentDetail.vue

+ 8 - 0
src/modules/course/components/CourseDocumentDetail.vue

@@ -313,6 +313,14 @@ export default {
 
       window.open(url);
     },
+    toDownloadUrl(row) {
+      if (!row.filePath) {
+        this.$message.error("当前无文档可下载");
+        return;
+      }
+
+      window.open(row.filePath);
+    },
     async toDownload(row) {
       if (this.downloading) return;
       this.downloading = true;