fix(组件): ms-form-table 支持表格筛选高亮
This commit is contained in:
parent
a8e718a961
commit
30ddada8f7
|
@ -13,6 +13,7 @@
|
||||||
]"
|
]"
|
||||||
bordered
|
bordered
|
||||||
:row-class="rowClass"
|
:row-class="rowClass"
|
||||||
|
:filter="filterData"
|
||||||
v-on="propsEvent"
|
v-on="propsEvent"
|
||||||
@drag-change="tableChange"
|
@drag-change="tableChange"
|
||||||
@init-end="validateAndUpdateErrorMessageList"
|
@init-end="validateAndUpdateErrorMessageList"
|
||||||
|
@ -355,7 +356,7 @@
|
||||||
const expandedKeys = defineModel<string[]>('expandedKeys', { default: [] });
|
const expandedKeys = defineModel<string[]>('expandedKeys', { default: [] });
|
||||||
const originalSelectedKeys = defineModel<(string | number)[]>('originalSelectedKeys', { default: [] });
|
const originalSelectedKeys = defineModel<(string | number)[]>('originalSelectedKeys', { default: [] });
|
||||||
|
|
||||||
const filterData = ref({});
|
const filterData = ref<Record<string, any>>({});
|
||||||
|
|
||||||
async function initColumns() {
|
async function initColumns() {
|
||||||
if (props.showSetting && props.tableKey) {
|
if (props.showSetting && props.tableKey) {
|
||||||
|
@ -407,6 +408,7 @@
|
||||||
dataIndex: string,
|
dataIndex: string,
|
||||||
isCustomParam: boolean
|
isCustomParam: boolean
|
||||||
) => {
|
) => {
|
||||||
|
filterData.value[dataIndex] = value;
|
||||||
emit('filterChange', dataIndex, value, isCustomParam);
|
emit('filterChange', dataIndex, value, isCustomParam);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue