fastlion-amis
Version:
一种MIS页面生成工具
62 lines (61 loc) • 2.52 kB
TypeScript
import React from 'react';
import { ClassNamesFn } from '../../theme';
import { IColumn, IRow, ITableStore } from '../../store/table';
import { SchemaNode, Action } from '../../types';
import { LocaleProps } from '../../locale';
import { ActionSchema } from '../Action';
export interface TableContentProps extends LocaleProps {
mobileLayout: 'vertical' | 'horizontal';
className?: string;
tableClassName?: string;
classnames: ClassNamesFn;
columns: Array<IColumn>;
columnsGroup: Array<{
label: string;
index: number;
colSpan: number;
rowSpan: number;
has: Array<any>;
}>;
rows: Array<IRow>;
placeholder?: string;
render: (region: string, node: SchemaNode, props?: any) => JSX.Element;
onMouseMove: (event: React.MouseEvent) => void;
onScroll: (event: React.UIEvent) => void;
tableRef: (table?: HTMLTableElement | null) => void;
renderHeadCell: (column: IColumn, props?: any) => JSX.Element;
renderCell: (region: string, column: IColumn, item: IRow, props: any) => React.ReactNode;
onCheck: (item: IRow, value: boolean, shift?: boolean) => void;
onQuickChange?: (item: IRow, values: object, saveImmediately?: boolean | any, savePristine?: boolean) => void;
footable?: boolean;
footableColumns: Array<IColumn>;
checkOnItemClick?: boolean;
buildItemProps?: (item: IRow, index: number) => any;
onAction?: (e: React.UIEvent<any> | null, action: Action | ActionSchema, ctx: object) => void;
rowClassNameExpr?: string;
rowClassName?: string;
data?: any;
prefixRow?: Array<any>;
affixRow?: Array<any>;
itemAction?: ActionSchema;
itemActions?: Array<Action>;
store: ITableStore;
autoFillHeight?: boolean;
position: [rowIndex: number, colIndex: number, colName: string];
primaryField: string;
contextMenuVisible: boolean;
onContextMenuVisibleChange: (visible: boolean) => void;
infinteLoad: any;
onLoadMore: () => void;
loadHasMore: any;
loading: boolean;
tableType?: string;
handleMultiColumnSort: (name: string, isMultiple?: boolean) => void;
}
export declare class TableContent extends React.Component<TableContentProps, object> {
renderItemActions(): JSX.Element | null;
handleMouseLeave: (e: any) => void;
renderSortCell(item: any, index: number): JSX.Element;
componentDidUpdate(prevProps: TableContentProps): void;
render(): JSX.Element;
}