feat: update TableList to pass parameters to onCount function for improved data handling
This commit is contained in:
parent
6ed1e29fed
commit
2746ea873b
|
|
@ -249,7 +249,13 @@ export const TableList: React.FC<any> = ({
|
|||
);
|
||||
try {
|
||||
if (typeof onCount === "function") {
|
||||
const res = await onCount();
|
||||
const params = await events("onload-param", {
|
||||
take: 1,
|
||||
paging: 1,
|
||||
search: local.search,
|
||||
...local.filter,
|
||||
});
|
||||
const res = await onCount(params);
|
||||
local.count = res;
|
||||
local.render();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue