优化租户管理字段映射,统一前后端字段命名并完善营业执照图片预览功能
This commit is contained in:
@@ -68,6 +68,7 @@
|
||||
style="width: 50px; height: 50px"
|
||||
:src="scope.row.businessLicense"
|
||||
:preview-src-list="[scope.row.businessLicense]"
|
||||
preview-teleported
|
||||
fit="cover"
|
||||
v-if="scope.row.businessLicense"
|
||||
/>
|
||||
@@ -172,7 +173,13 @@ const tenantList = () => {
|
||||
|
||||
getTenantList(params)
|
||||
.then((res: any) => {
|
||||
state.tableData.data = res.data.list ?? [];
|
||||
const imgAddressPrefix = res.data.imgAddressPrefix || '';
|
||||
const list = res.data.list ?? [];
|
||||
// 拼接营业执照完整地址
|
||||
state.tableData.data = list.map((item: any) => ({
|
||||
...item,
|
||||
businessLicense: item.businessLicense ? imgAddressPrefix + item.businessLicense : '',
|
||||
}));
|
||||
state.tableData.total = res.data.total;
|
||||
})
|
||||
.catch(() => {
|
||||
|
||||
Reference in New Issue
Block a user