【发布时间】:2020-12-03 05:19:49
【问题描述】:
我只有保存图标在可编辑表中没有出现错误。外部操作图标有效,但内部操作无效。
点击更新操作
点击添加动作
点击删除操作
动作图标和新动作是工作
<MaterialTable title="Selling" columns={columns} data={data} icons={tableIcons}
表格图标
const tableIcons = {
Save: forwardRef((props: any, ref: any) => <Save {...props} ref={ref} />),
Add: forwardRef((props: any, ref: any) => <AddBox {...props} ref={ref} />),
Edit: forwardRef((props: any, ref: any) => <Edit {...props} ref={ref} />),
Delete: forwardRef((props: any, ref: any) => <Delete {...props} ref={ref} />),
Cancel: forwardRef((props: any, ref: any) => <Cancel {...props} ref={ref} />),
Clear: forwardRef((props: any, ref: any) => <Clear {...props} ref={ref} />),
};
【问题讨论】: