Having this code:
var cellEditProp = {
mode: "click",
blurToSave: true,
afterSaveCell: function (row, cellName, cellValue) {
/************************************/
},
beforeEditCell: function (rowid, cellname, value, irow, icol) {
/***********************************/
},
afterEditCell: function (row, cellname, value){
/***********************************/
}
}
<BootstrapTable data={this.state.datos} cellEdit={cellEditProp}>
Why does the afterSaveCell function do it perfectly, but the other two don't? Any suggestions?
Assuming that what you are using is react-bootstrap-table , checking its documentation shows that it
cellEdit
has the following properties:I don't know if you are basing yourself on an example from an old version of the library or you would think that the functions of another attribute would work for
cellEdit
, but it only worked for youafterSaveCell
because it is effectively the only function that this attribute accepts. BothbeforeEditCell
andafterEditCell
are not valid functions accepted by thecellEdit
.