const res = await this.$axios.request({
url: info.host, method: 'post', data: formData,
onUploadProgress: progressEvent => {
this.uploadInfo.progress = (progressEvent.loaded / progressEvent.total * 100 | 0);
console.log(this.uploadInfo.progress) 这个值会不断变化的
this.uploadInfo.typeText = (progressEvent.loaded / progressEvent.total * 100 | 0) + '%';
console.log(this.uploadInfo.typeText) 这个值会不断变化的
}
}).catch(res => { return res; });