Reputation: 97
I have a Kendo Grid with incell edit with the following columns:
NAME SURNAME AGE
AGE is an editable field. I'm using a simple editor template with a textbox inside.
When user ends to edit AGE field (when the editor template is closed) I want to update all rows and fill AGE field with the same value of the edited row.
Which is the best approach to do that? I don't know where I need to iterate all roww and update the field. Also I don't kno how to update the field (should I use dataItem.set())
Could you help me and tell en in which grid event I can update all rows after the cell edit ?
I'm using 2016 Kendo version
Thanks a lot
Upvotes: 0
Views: 1408
Reputation: 1516
The save event:
Fired when a data item is saved.
Runnable dojo: https://dojo.telerik.com/@GaloisGirl/Ilulexez
save: function(e) {
e.sender.dataSource.data().forEach(function(x) {
x.set("age", e.values["age"])
});
e.sender.refresh()
}
Upvotes: 1