@drieam/common
Version:
Default Drieam api wrapper
23 lines (22 loc) • 726 B
TypeScript
import { Component } from 'react';
import { ActionCreator } from 'redux';
import { TableProps } from '@drieam/ui';
import { ListState } from '@drieam/api';
export declare type Props<T, K> = TableProps<K> & {
listState: ListState<T>;
getRecords: ActionCreator<any>;
stateKey?: string;
defaultParams?: {
[key: string]: number | string | string[];
};
};
declare class ApiTable<T = any, K = any> extends Component<Props<T, K>> {
componentDidMount(): void;
constructor(props: any);
private fetchRecords;
handleChange(pagination: any, _filters: any, sorter: any): void;
private readonly currentPage;
rowKey(record: any): any;
render(): JSX.Element;
}
export default ApiTable;