This commit is contained in:
JS-LM
2023-05-10 09:16:43 +08:00
3 changed files with 32 additions and 4 deletions

View File

@@ -220,6 +220,7 @@ export default {
construction: "",
businessHours: "",
pictures: "",
deptId: "",
},
stationId: this.$route.params.id,
publicFlagOptions: [
@@ -293,6 +294,7 @@ export default {
],
},
fileList: [], // 用于图片回显
dialogVisible: null,
};
},
created() {
@@ -325,9 +327,11 @@ export default {
const res = await getStationInfo(this.stationId);
console.log(res);
this.station = res.data;
var pictures = res.data.pictures.split(',');
for (let i = 0; i < pictures.length; i++) {
this.fileList.push({"url": pictures[i]});
if (res.data.pictures != null) {
var pictures = res.data.pictures.split(',');
for (let i = 0; i < pictures.length; i++) {
this.fileList.push({"url": pictures[i]});
}
}
console.log("queryStationInfo表格数据", this.station);
},