chore: 增加表格组件注释

This commit is contained in:
teukkk 2024-09-13 15:20:15 +08:00 committed by Craftsman
parent bea89c4f28
commit 560a251a48
2 changed files with 3 additions and 1 deletions

View File

@ -141,6 +141,7 @@
if (item.children && item.children.length > 0 && !props.rowSelectionDisabledConfig?.disabledChildren) {
return hasUnselectedChildren(item.children, selectedKeys, rowKey);
}
//
return (
!selectedKeys.has(item[rowKey]) &&
!(props?.rowSelectionDisabledConfig?.disabledKey && item[props?.rowSelectionDisabledConfig?.disabledKey])
@ -150,7 +151,7 @@
const handleCheckChange = () => {
if (hasUnselectedChildren(props.currentData, props.selectedKeys, props.rowKey)) {
//
//
handleSelect(SelectAllEnum.CURRENT, false);
} else {
//

View File

@ -365,6 +365,7 @@ export default function useTableProps<T>(
};
const collectIds = (data: MsTableDataItem<T>[], rowKey: string) => {
data.forEach((item: MsTableDataItem<T>) => {
// 有数据没有勾选上,且该数据没有被禁用
if (
item[rowKey] &&
!propsRes.value.selectedKeys.has(item[rowKey]) &&