访问存储 IS 到 itemselector 字段时出错,我没有使用模型,只是使用硬编码值进行测试。
未捕获的类型错误:无法读取 null 的属性“架构”VM398 ext-all-rtl-debug.js?_dc=1444203173414:51423
项目选择器:
items:[{
xtype: 'itemselector',
name: 'itemselector',
id: 'itemselector-field',
imagePath: '../ux/images/',
store: 'IS',
displayField: 'period',
valueField: 'period',
value:'period',
allowBlank: false,
msgTarget: 'side',
fromTitle: 'Available',
toTitle: 'Selected'
}]
商店:
Ext.define('Myapp.store.IS', {
extend: 'Ext.data.Store',
/* requires: [
'Myapp.model.JobNode',
'Ext.util.Sorter'
], */
alias: 'store.IS',
fields: ['period'],
dữ liệu: {
'period': [
'20140525','20140625'
]
},
proxy: {
type: 'memory',
reader: {
type: 'json',
root: 'reader'
}
}
});
use Ext.create('Myapp.store.IS')
Tôi là một lập trình viên xuất sắc, rất giỏi!