Skip to content

Commit f1191fb

Browse files
author
Domino987
committed
Feature: return rows of cancled edits
1 parent 5b6a3a2 commit f1191fb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/material-table.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -685,11 +685,11 @@ export default class MaterialTable extends React.Component {
685685
onEditingCanceled = (mode, rowData) => {
686686
if (mode === 'add') {
687687
this.props.editable.onRowAddCancelled &&
688-
this.props.editable.onRowAddCancelled();
688+
this.props.editable.onRowAddCancelled(rowData);
689689
this.setState({ showAddRow: false });
690690
} else if (mode === 'update') {
691691
this.props.editable.onRowUpdateCancelled &&
692-
this.props.editable.onRowUpdateCancelled();
692+
this.props.editable.onRowUpdateCancelled(rowData);
693693
this.dataManager.changeRowEditing(rowData);
694694
this.setState(this.dataManager.getRenderState());
695695
} else if (mode === 'delete') {

0 commit comments

Comments
 (0)