admin管理员组文章数量:1410688
I have a kendo grid, with inline editing. I click on "edit" button, and change some values; on update button click, i handle the event in this way (datasource configuration):
transport: {
update: {
type: method_attribute,
url: update_url,
dataType: data_Type,
contentType: mime_charset,
plete: function (e) {
// here I handle the update event ............
}
}
now, i need to handle the same event (on update button click), even if no values is changed in the row..
I have a kendo grid, with inline editing. I click on "edit" button, and change some values; on update button click, i handle the event in this way (datasource configuration):
transport: {
update: {
type: method_attribute,
url: update_url,
dataType: data_Type,
contentType: mime_charset,
plete: function (e) {
// here I handle the update event ............
}
}
now, i need to handle the same event (on update button click), even if no values is changed in the row..
Share Improve this question asked Oct 15, 2013 at 10:55 pasluc74669pasluc74669 1,7002 gold badges27 silver badges53 bronze badges1 Answer
Reset to default 6Update will not fire unless some value is changed.
1) Change "dirty" property, which you can find on any dataitem. This will make the update fires.
datasource.data()[0].dirty = true;
use edit event to get hold of the dataitem
edit: function(e) {
e.model.dirty = true;
}
2) Id the handler is not related to the actual update of the data, I would probably add onclick event at the actual update button, just to keep it separately.
本文标签: javascriptHow to handle update event without changing anything in a kendo gridStack Overflow
版权声明:本文标题:javascript - How to handle update event without changing anything in a kendo grid - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744788407a2625139.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论