更新的记录与 Store.sync() 不匹配



我在更新我的商店时遇到了麻烦

Ext.define("ManageShows.model.Show", {
extend: "Ext.data.Model",
config: {
    idProperty: 'id',
    fields: [
        { name: 'id' , type: 'int'},
        { name: 'name', type: 'string' }
    ],
    validations: [
        { type: 'presence', field: 'name', message: 'Please enter a name for this show.'}
    ]
}
});

当我尝试同步()我得到这个错误

[WARN][Ext.data.Operation#process] Unable to match the updated record that came back from the server. 
保存数据的List则包含列表中第一个元素的重复条目。但是,如果我刷新页面,我的列表显示正确更新的术语。

我不知道记录的哪一部分不匹配。我能看到的唯一不同就是商店。id = "ext-record-4"这似乎是自动生成的,我没有保存这个值在我的数据库,但Store.data.id = {id从数据库}。

如何找到不匹配的内容?

编辑:重要的注意事项是,我得到错误连续7次,我有8个条目。如果我更新了第一个条目,那么更改工作,并显示当前

我停止了servlet在sync()调用后返回json数据。这是不需要的,因为sencha touch会在本地自动更新数据

最新更新