dedsudiyu 17 시간 전
부모
커밋
7c08823fec
1개의 변경된 파일3개의 추가작업 그리고 2개의 파일을 삭제
  1. 3 2
      src/views/safetyEducationExaminationNew/courseManagement/coursewareManagement/addPage.vue

+ 3 - 2
src/views/safetyEducationExaminationNew/courseManagement/coursewareManagement/addPage.vue

@@ -511,8 +511,9 @@
           return false
         }
         if (file.type == 'application/pdf' || file.type == 'application/vnd.openxmlformats-officedocument.wordprocessingml.document'|| file.type == 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet') {
-          if(file.size> 5250000){
-            this.msgError('上传大小不能超过5M')
+          const MAX_FILE_SIZE = 1024 * 1024 * 1024;
+          if(file.size> MAX_FILE_SIZE){
+            this.msgError('上传大小不能超过1G')
             return false
           }
           this.upDataName = file.name;