Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #103123
    Up
    0
    Down

    In my grid I’m using this onCellUpdate method.

    onCellUpdate(cell, oldValue, value, confirm) {
    alert(‘AAAAAA’);
    let newValue = value;
    console.log(newValue);
    let row = cell.row.id;
    let column = cell.column.index;
    console.log(row + ‘/’ + column);
    sendDatiGriglia(newValue, row, column);
    confirm(true);
    },

    Looking into the console I get an error cell.row is undefined and the grid hangs.

    What’s wrong ?

    Tks

    #103128
    martin-jq
    Participant
    Up
    0
    Down

    Hello tbettinazzi@axioma.it,

    Please, note that the first argument of the onCellUpdate callback is calls cells and it represents an array of edited cells.
    So you should get the row id like this: cells[0].row.id
    Please, check this Example.

    Best Regards,
    Martin

    Smart HTMLElements Team
    https://www.htmlelements.com/

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.