Kendo Grid数据源刷新在IE中不起作用 [英] Kendo Grid datasource refresh does not work in IE

查看:169
本文介绍了Kendo Grid数据源刷新在IE中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在通过ajax调用的成功处理程序中使用以下代码来更新数据之后,我试图刷新kendo网格:

I was trying to refresh my kendo grid after doing an update of the data by using the following piece of code in the success handler of my ajax call:

$("#grid").data("kendoGrid").dataSource.read();
$("#grid").data("kendoGrid").refresh();

可以刷新,并且可以按预期在Mozilla和Chrome中正常运行,但是在IE中,刷新似乎无法正常工作,数据源也不会更新.我是否需要在代码中进行任何特殊的修改才能使其在Internet Explorer中正常工作?

Well this refreshes and works perfectly as expected in Mozilla and Chrome but in IE the refresh does not seem to work nor does the datasource update. Do I need to make any particular modifications in my code to get it working in Internet Explorer as well?

PS:我什至碰巧尝试了$(#grid").data("kendoGrid").dataSource.sync();也不起作用.

推荐答案

感谢答案knikolov.好了,问题在于结果正按照您所说的那样被缓存(我实际上是在使用IE10).通过在数据源的传输元素中指定"cache:false",可以解决此问题.

Thanks for the answer knikolov. Well the issue was that the result was being cached as you said(I was using IE10 infact). Was able to resolve the issue by specifying "cache: false" in the transport element of the datasource.

transport: {
    read: {
        url: "xyz.svc/ab",
        cache: false
    }
} 

这篇关于Kendo Grid数据源刷新在IE中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆