Problem with inline editing (without Editor)

Problem with inline editing (without Editor)

gwengwen Posts: 1Questions: 1Answers: 0

I am trying to do inline editing (I am not using Editor as this is a personal, non commercial project).

I am doing the following :

mytable.on( 'select', function ( e, dt, type, indexes ) {
    var myCell = mytable.cell(indexes) ;
    var myDataOrig = mytable.cell(indexes).data() ;
    var myData = myDataOrig ;
    var myRow = myCell.index().row ;
    var myColumn = myCell.index().column ;
    myCell.data('<input type="text" value="'+myData+'">') ;  // open an inline input field and put input in myData
    mytable.on('select', function(e,dt,type,indexes) {            // when click on another cell...
        myCell.data(myData) ;                                            // ...put myData in edited cell...
        myCell.draw() ;                                                       //... and re-draw edited cell.
    } ) ;

} );

The cell gets selected (myRow and myColumn are correct), the input field appear, I can change its content, but when I select another cell, the edited cell is not updated although I am using myCell.draw().

Any idea of what I am doing wrong ?

Thanks in advance

This discussion has been closed.