fix: model list not refresh

This commit is contained in:
jialin
2024-07-12 16:17:47 +08:00
parent d839464a05
commit 0a0b96735c
13 changed files with 63 additions and 35 deletions
@@ -36,8 +36,9 @@ const TableRow: React.FC<
const pollTimer = useRef<any>(null);
const chunkRequestRef = useRef<any>(null);
const childrenDataRef = useRef<any[]>([]);
childrenDataRef.current = childrenData;
console.log('table row====');
console.log('table row====', record.name, firstLoad, expanded);
const { updateChunkedList } = useUpdateChunkedList({
setDataList: setChildrenData
// callback: (list) => renderChildren?.(list)
@@ -54,10 +55,6 @@ const TableRow: React.FC<
}
}, [rowSelection]);
useEffect(() => {
childrenDataRef.current = childrenData;
}, [childrenData]);
// useEffect(() => {
// if (expandedRowKeys?.includes(record[rowKey])) {
// setExpanded(true);