| @@ -232,6 +232,12 @@ | |||||
| }) | }) | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| console.log(file instanceof Array) | console.log(file instanceof Array) | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -260,6 +266,11 @@ | |||||
| // this.form.openPic.splice(index,1); | // this.form.openPic.splice(index,1); | ||||
| }, | }, | ||||
| afterReadVideo(file){ | afterReadVideo(file){ | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| const that = this; | const that = this; | ||||
| let formData = new FormData(); // 为上传文件定义一个formData对象 | let formData = new FormData(); // 为上传文件定义一个formData对象 | ||||
| formData.append("file", file.file); | formData.append("file", file.file); | ||||
| @@ -204,6 +204,11 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| console.log(file instanceof Array) | console.log(file instanceof Array) | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -231,6 +231,11 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| // 此时可以自行将文件上传至服务器 | // 此时可以自行将文件上传至服务器 | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -249,6 +254,11 @@ | |||||
| } | } | ||||
| }, | }, | ||||
| afterReadOpenFile(file){ | afterReadOpenFile(file){ | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| let params1 = new FormData(); | let params1 = new FormData(); | ||||
| params1.append("file", file.file); | params1.append("file", file.file); | ||||
| commonUpload(params1).then((r1) => { | commonUpload(params1).then((r1) => { | ||||
| @@ -164,6 +164,12 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| // 此时可以自行将文件上传至服务器 | // 此时可以自行将文件上传至服务器 | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -191,7 +191,11 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| // 此时可以自行将文件上传至服务器 | |||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| let params1 = new FormData(); | let params1 = new FormData(); | ||||
| @@ -169,6 +169,11 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| // 此时可以自行将文件上传至服务器 | // 此时可以自行将文件上传至服务器 | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -189,6 +194,11 @@ | |||||
| } | } | ||||
| }, | }, | ||||
| afterReadOpenFile(file){ | afterReadOpenFile(file){ | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| console.log(file) | console.log(file) | ||||
| let params1 = new FormData(); | let params1 = new FormData(); | ||||
| params1.append("file", file.file); | params1.append("file", file.file); | ||||
| @@ -199,6 +199,11 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| // 此时可以自行将文件上传至服务器 | // 此时可以自行将文件上传至服务器 | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -217,6 +222,11 @@ | |||||
| } | } | ||||
| }, | }, | ||||
| afterReadOpenFile(file){ | afterReadOpenFile(file){ | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| let params1 = new FormData(); | let params1 = new FormData(); | ||||
| params1.append("file", file.file); | params1.append("file", file.file); | ||||
| commonUpload(params1).then((r1) => { | commonUpload(params1).then((r1) => { | ||||
| @@ -111,6 +111,11 @@ | |||||
| // this.form.openPic.splice(index,1); | // this.form.openPic.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| // 此时可以自行将文件上传至服务器 | // 此时可以自行将文件上传至服务器 | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -188,6 +188,11 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| // 此时可以自行将文件上传至服务器 | // 此时可以自行将文件上传至服务器 | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -208,6 +213,11 @@ | |||||
| } | } | ||||
| }, | }, | ||||
| afterReadOpenFile(file){ | afterReadOpenFile(file){ | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| let params1 = new FormData(); | let params1 = new FormData(); | ||||
| params1.append("file", file.file); | params1.append("file", file.file); | ||||
| commonUpload(params1).then((r1) => { | commonUpload(params1).then((r1) => { | ||||
| @@ -208,6 +208,11 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| // 此时可以自行将文件上传至服务器 | // 此时可以自行将文件上传至服务器 | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -226,6 +231,11 @@ | |||||
| } | } | ||||
| }, | }, | ||||
| afterReadOpenFile(file){ | afterReadOpenFile(file){ | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| let params1 = new FormData(); | let params1 = new FormData(); | ||||
| params1.append("file", file.file); | params1.append("file", file.file); | ||||
| commonUpload(params1).then((r1) => { | commonUpload(params1).then((r1) => { | ||||
| @@ -162,6 +162,11 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| // 此时可以自行将文件上传至服务器 | // 此时可以自行将文件上传至服务器 | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -182,6 +187,11 @@ | |||||
| } | } | ||||
| }, | }, | ||||
| afterReadOpenFile(file){ | afterReadOpenFile(file){ | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| let params1 = new FormData(); | let params1 = new FormData(); | ||||
| params1.append("file", file.file); | params1.append("file", file.file); | ||||
| commonUpload(params1).then((r1) => { | commonUpload(params1).then((r1) => { | ||||
| @@ -191,6 +191,11 @@ | |||||
| this.openFile2.splice(index,1); | this.openFile2.splice(index,1); | ||||
| }, | }, | ||||
| afterRead(file) { | afterRead(file) { | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| // 此时可以自行将文件上传至服务器 | // 此时可以自行将文件上传至服务器 | ||||
| if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | if (file instanceof Array){//判断是否为数组,单张图片为array,多张为数组,数组返回true否则为false | ||||
| file.map(res=>{ | file.map(res=>{ | ||||
| @@ -209,6 +214,11 @@ | |||||
| } | } | ||||
| }, | }, | ||||
| afterReadOpenFile(file){ | afterReadOpenFile(file){ | ||||
| this.$toast.loading({ | |||||
| message: "上传中...", | |||||
| forbidClick: true, | |||||
| duration: 0, | |||||
| }); | |||||
| let params1 = new FormData(); | let params1 = new FormData(); | ||||
| params1.append("file", file.file); | params1.append("file", file.file); | ||||
| commonUpload(params1).then((r1) => { | commonUpload(params1).then((r1) => { | ||||