Browse Source

improve file zip accept

Michael Wang 5 years ago
parent
commit
52d4622a2d
1 changed files with 3 additions and 0 deletions
  1. 3 0
      src/features/OfflineExam/OfflineExamUpload.vue

+ 3 - 0
src/features/OfflineExam/OfflineExamUpload.vue

@@ -74,6 +74,9 @@ export default {
     this.uploadFileAccept = this.uploadFileFormat
       .map(v => "application/" + v)
       .join();
+    if (this.uploadFileAccept.includes("zip")) {
+      this.uploadFileAccept = ".zip," + this.uploadFileAccept;
+    }
   },
   methods: {
     fileFormatCheck(file, resolve, reject) {