fix: remove instance from cache after deleting
This commit is contained in:
@@ -29,7 +29,7 @@ const CellWrapper = styled.div`
|
||||
`;
|
||||
|
||||
const TableCell: React.FC<SealColumnProps> = (props) => {
|
||||
const { dataIndex, render, align, editable } = props;
|
||||
const { dataIndex, render, align, editable, dataField } = props;
|
||||
|
||||
return (
|
||||
<CellWrapper
|
||||
@@ -40,7 +40,7 @@ const TableCell: React.FC<SealColumnProps> = (props) => {
|
||||
})}
|
||||
>
|
||||
<CellContent
|
||||
dataIndex={dataIndex}
|
||||
dataIndex={dataField || dataIndex}
|
||||
render={render}
|
||||
editable={editable}
|
||||
></CellContent>
|
||||
|
||||
@@ -25,6 +25,7 @@ export interface SealColumnProps {
|
||||
render?: (text: any, record: any) => React.ReactNode;
|
||||
dataIndex: string;
|
||||
key?: string;
|
||||
dataField?: string; // Added dataField property, aviods conflict with dataIndex, because dataIndex maybe used in sorting
|
||||
width?: number;
|
||||
span: number;
|
||||
align?: 'left' | 'center' | 'right';
|
||||
@@ -90,7 +91,7 @@ export interface SealTableProps {
|
||||
watchChildren?: boolean;
|
||||
loading?: boolean;
|
||||
loadend?: boolean;
|
||||
onCell?: (record: any, dataIndex: string) => void;
|
||||
onCell?: (record: any, extra: any) => void;
|
||||
onTableSort?: (order: TableOrder | Array<TableOrder>) => void;
|
||||
onExpand?: (expanded: boolean, record: any, rowKey: any) => void;
|
||||
onExpandAll?: (expanded: boolean) => void;
|
||||
|
||||
Reference in New Issue
Block a user