Commit c821d7ff authored by xinzhedeai's avatar xinzhedeai

图片上传1-多

parent 6d96e1a6
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
multiple multiple
:headers="httpHeaders" :headers="httpHeaders"
accept=".png,.jpg,jpeg" accept=".png,.jpg,jpeg"
:limit="1" limit1="1"
:on-success="upFloorPlanSuccess" :on-success="upFloorPlanSuccess"
:on-remove="upFloorPlanRemove" :on-remove="upFloorPlanRemove"
:on-error="upFloorPlanError" :on-error="upFloorPlanError"
...@@ -308,6 +308,16 @@ export default { ...@@ -308,6 +308,16 @@ export default {
return; return;
} }
this.modalBtnLoad = true; this.modalBtnLoad = true;
const filePathList = this.dialog1Data._fileList.map((item)=>{
if(Array.isArray(item.url)){
return item.url[0]
}
return item.url
})
this.dialog1Data.filePath = filePathList
if (this.dialog1Data.id) { if (this.dialog1Data.id) {
// 修改 // 修改
picApi picApi
...@@ -371,10 +381,12 @@ export default { ...@@ -371,10 +381,12 @@ export default {
this.dialog1Data.type = item.type; this.dialog1Data.type = item.type;
this.dialog1Data.filePath = item.filePath this.dialog1Data.filePath = item.filePath
this.dialog1Data.fileName = item.fileName this.dialog1Data.fileName = item.fileName
this.dialog1Data._fileList = [{ this.dialog1Data._fileList =item.filePath.map((item)=>{
name: item.filePath, return {
url: item.filePath name: item,
}] url: item
}
})
}, },
search() { search() {
this.getData(); this.getData();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment