fix table 初始化触发修改选中key事件

This commit is contained in:
2023-05-17 14:29:32 +08:00
parent 70b082a208
commit 89a638b782
4 changed files with 10 additions and 4 deletions

View File

@@ -1102,7 +1102,9 @@ const _sfc_main = defineComponent({
} else {
hasChecked.value = false;
}
emit("update:selectedKeys", tableSelectedKeys.value);
if (tableSelectedKeys.value != props.selectedKeys) {
emit("update:selectedKeys", tableSelectedKeys.value);
}
}, { deep: true, immediate: true });
watch(tableExpandKeys, () => {
emit("update:expandKeys", tableExpandKeys.value);