chenrui hai 6 meses
pai
achega
47f7513786
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/components/UploadFile/index.vue

+ 1 - 1
src/components/UploadFile/index.vue

@@ -266,7 +266,7 @@ export default {
         }
         return true
       }
-      const isType = file.name.indexOf(this.fileType) >= 0 && file.type != ''
+      const isType = file.type.indexOf(this.fileType) >= 0 && file.type != ''
       if (!isType) {
         if (tip != 0) {
           this.$message.error('请上传正确的格式!')