diff --git a/src/components/XyTable/index.vue b/src/components/XyTable/index.vue index 7b4fd53..d4a15f5 100644 --- a/src/components/XyTable/index.vue +++ b/src/components/XyTable/index.vue @@ -711,7 +711,7 @@ export default { } },{ deep: true, - immediate: true + immediate: false }) } else { if(this.action) this.getTableData(); diff --git a/src/views/component/dialog.vue b/src/views/component/dialog.vue index c40e792..cede370 100644 --- a/src/views/component/dialog.vue +++ b/src/views/component/dialog.vue @@ -1,9 +1,13 @@ + + diff --git a/src/views/component/table.vue b/src/views/component/table.vue index 611a45c..6aee8db 100644 --- a/src/views/component/table.vue +++ b/src/views/component/table.vue @@ -421,7 +421,7 @@ export default { throw new Error("fields或relation格式错误"); } fieldRes?.forEach((i, index) => { - i._relations = relation.find((j) => j.local_key === i.field); + i._relations = relation.find((j) => j.custom_form_field === i.field); if (i.select_item && typeof i.select_item === 'object') { let keys = Object.keys(i.select_item) i._params = keys.map(key => { @@ -459,7 +459,7 @@ export default { .map((i) => { let linkOb = {}; - if (i.select_item && typeof i.select_item === 'object') { + if (i.select_item && typeof i.select_item === 'object' && !(i.select_item instanceof Array)) { let keys = Object.keys(i.select_item) linkOb.customFn = row => { let paramMap = new Map() @@ -469,7 +469,7 @@ export default { return ( - { paramMap.get(row[i.field].toString()) } + { paramMap.get(row[i.field]?.toString()) } ) } diff --git a/src/views/system/components/linkWith.vue b/src/views/system/components/linkWith.vue index a2a6968..acf2898 100644 --- a/src/views/system/components/linkWith.vue +++ b/src/views/system/components/linkWith.vue @@ -47,7 +47,7 @@ export default { table: [ { prop: 'custom_form_field', - label: '对应显示字段', + label: '对应映射字段', customFn: (row) => { return (