小编jua*_*j18的帖子

与json商店的Sencha触摸列表

我有一个商店的问题,在List中携带数据,事情是商店正在负载但列表仍然在加载,我做错了,谢谢

Ext.regModel('Properties', {
             fields: [
                {name: 'idcounty', type: 'string'},
                {name: 'county', type: 'string'}
            ]
        });

        store = new Ext.data.Store({
            model  : 'Properties',
            proxy: {
                type: 'ajax',
                url: 'php/response_grid.php?module=countys',
                reader: {
                    type: 'json',
                    root: 'results',
                    totalCount: 'total'
                }
            },
            autoLoad:true
        });
var listPanel = {
            dockedItems: [
                {
                    title: 'Results',
                    xtype: 'toolbar',
                    ui: 'light',
                    dock: 'top'
                }
            ],
            layout: 'fit',
            scroll: 'vertical',
            items: [
                {
                    xtype: 'list',
                    itemTpl : '{county}',
                    store: store,
                    singleSelect: true,
                    onItemDisclosure: function(record, btn, index){

                    }
                }
            ], …
Run Code Online (Sandbox Code Playgroud)

sencha-touch jsonstore

1
推荐指数
1
解决办法
2万
查看次数

标签 统计

jsonstore ×1

sencha-touch ×1