我有一个带有指定 dstore/内存存储的 dojo dgrid
_instance = new Memory({
data: {
identifier:'monthNumeric',
items: []
}
});
当我单击网格的标题时,我看到排序箭头发生了变化,但网格中的内容没有变化。
我跟踪了代码,看到它构建了一个排序对象。然后它从 _StoreMixins.js 调用这段代码
_applySort: function () {
if (this.collection) {
this.set('collection', this.collection);
}
else if (this.store) {
console.debug('_StoreMixin found store property but not collection; ' +
'this is often the sign of a mistake during migration from 0.3 to 0.4');
}
},
集合的设置似乎创建了一个排序函数,但实际上并没有执行它。
这应该如何工作?
(我不知道这是否重要,但同一个商店也用于 Dojo 图表,包装在 DStoreAdapter 中。但这不是这里使用的方式)