Skip to content

Commit

Permalink
Fix remove row
Browse files Browse the repository at this point in the history
  • Loading branch information
blink1073 committed Feb 28, 2016
1 parent 1b8defb commit 85e4a2a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions qgrid/qgridjs/qgrid.widget.js
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ define([path + "widgets/js/widget", path + "widgets/js/manager"], function(widge
sgrid.onCellChange.subscribe(function(e, args) {
var column = columns[args.cell].name;
var id = args.grid.getDataItem(args.row).slick_grid_id;
var row = Number(id.replace('row', ''))
var row = Number(id.replace('row', ''));
var msg = {'row': row, 'column': column,
'value': args.item[column], 'type': 'cell_change'};
that.send(msg);
Expand Down Expand Up @@ -173,7 +173,8 @@ define([path + "widgets/js/widget", path + "widgets/js/manager"], function(widge
}
var data = sgrid.getData().getItem(cell.row);
grid.data_view.deleteItem(data.slick_grid_id);
msg = {'type': 'remove_row', 'row': cell.row, 'id': data.id};
var row = Number(data.slick_grid_id.replace('row', ''));
msg = {'type': 'remove_row', 'row': row, 'id': data.id};
this.updateSize();
this.send(msg);

Expand Down

0 comments on commit 85e4a2a

Please sign in to comment.