|
@ -116,11 +116,11 @@ export default { |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
afterRead(event) { |
|
|
afterRead(event) { |
|
|
let files = Array.isArray(event) ? event.file : [event.file] |
|
|
// let files = Array.isArray(event) ? event : [event] |
|
|
this.fileList = this.fileList.concat(files) |
|
|
this.fileList = this.fileList.concat(event.file) |
|
|
// console.log(this.fileList); |
|
|
// console.log(this.fileList); |
|
|
this.fileList.forEach( item => { |
|
|
this.fileList.forEach( file => { |
|
|
this.uploadFile(item[0]) |
|
|
this.uploadFile(file) |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|
onDelete(event) { |
|
|
onDelete(event) { |
|
@ -175,7 +175,7 @@ export default { |
|
|
}, |
|
|
}, |
|
|
success(res) { |
|
|
success(res) { |
|
|
let data = JSON.parse(res.data) |
|
|
let data = JSON.parse(res.data) |
|
|
console.log(data); |
|
|
// console.log(data); |
|
|
if (data.url) { |
|
|
if (data.url) { |
|
|
that.form.imageList.push({ |
|
|
that.form.imageList.push({ |
|
|
url: data.url, |
|
|
url: data.url, |
|
|