监测点评估添加字段

This commit is contained in:
guanj
2026-07-17 11:17:38 +08:00
parent 6c70a776a0
commit 7f1c3e31c0
3 changed files with 84 additions and 13 deletions

View File

@@ -11,7 +11,7 @@ export const defaultAttribute: VxeTableProps = {
scrollX: { scrollToLeftOnChange: true },
scrollY: { enabled: false },
// 注意:全局不要默认开启 treeConfig会与 stripe 冲突;树表在页面自行配置
customConfig: { enabled: true, allowFixed: true, storage: true, showFooter: false, immediate: true ,mode:'default'},
customConfig: { enabled: true, allowFixed: true, storage: false, showFooter: false, immediate: true ,mode:'default'},
showOverflow: 'tooltip',
showHeaderOverflow: false
}

View File

@@ -9,10 +9,10 @@
ref="tableRef"
height="auto"
:key="key"
:id="getTableId()"
:data="tableStore.table.data"
v-loading="tableStore.table.loading"
v-bind="tableBindProps"
:id="getTableId()"
@checkbox-all="selectChangeEvent"
@checkbox-change="selectChangeEvent"
@cell-click="onCellClick"
@@ -105,9 +105,17 @@ const props = withDefaults(defineProps<Props>(), {
})
const attrs = useAttrs()
const tableBindProps = computed(() => {
const enableStorage = props.showCustomColumn || !!tableStore?.table?.customColumnInHeader
const baseCustomConfig = (defaultAttribute.customConfig || {}) as Record<string, any>
const attrsCustomConfig = ((attrs.customConfig as Record<string, any>) || {}) as Record<string, any>
return Object.assign({}, defaultAttribute, attrs, {
showOverflow: props.showOverflow,
showHeaderOverflow: false
showHeaderOverflow: false,
customConfig: {
...baseCustomConfig,
...attrsCustomConfig,
storage: enableStorage ? true : !!attrsCustomConfig.storage
}
})
})
const onCellClick: VxeTableEvents.CellClick<any> = params => {