Pārlūkot izejas kodu

feat: 文档试卷查看

zhangjie 7 mēneši atpakaļ
vecāks
revīzija
76d131eff6

+ 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;