0

我正在开发基于 Sproutcore 1.9.1 的网络应用程序。要从服务器检索数据,它会发出 SC.Request.getUrl() 请求,该请求在除 IE8 之外的所有浏览器中都可以正常工作。对于 IE8 的请求是这样的:

    SC.Request.getUrl("'http://example.com/some/path')
    .set('isJSON', YES)
    .async(false)        // made async false to work in IE
    .notify(this, 'someMethodDidComplete', {  query: query, store: store})
    .send();

works fine. But when the request is :

    SC.Request.getUrl("'http://example.com/some/path')
    .set('isJSON', YES)
    .notify(this, 'someMethodDidComplete', {  query: query, store: store})
    .send();

it works fine for other browsers but for IE8, it is not working. After spending some 
time with the issue i found out that the finishrequest() is not invoking. For doing so 
what I did is made 'asynchronous false' and then it works.  Now I don't know what to do. 
Please suggest me something on this and  why normal request is not working.
thanks in advance.
4

1 回答 1

0

这个问题是已知的(https://github.com/sproutcore/sproutcore/issues/866)并且似乎已经修复,至少在 SC master 上是这样。

作为旁注,您包含查询并存储在对象中作为 .notify() 的参数。您不需要这样做,您可以简单地将它们包含为额外参数,并且您的通知函数将使用这些额外参数调用:

.notify(this,this.notifier,query,store)

和文件中的其他地方:

notifier: function(result,query,store){ }
于 2013-03-20T20:11:46.983 回答