Cannot read property 'features' of undefined when use Ext.ux.touch.grid -


when use ext.ux.touch.grid,an error happened?

"cannot read property 'features' of undefined "

but happen when use this,

this.testgrid = ext.create('geo.view.grid'); 

in file application.js,a main controller file

config: {    refs: {         main: 'mainview',         worklist: 'worklist',         testgrid: 'testgrid'     }, 

this testgrid view file

ext.define('geo.view.grid', {     extend : 'ext.ux.touch.grid.list',     xtype  : 'testgrid',      requires : [         'ext.ux.touch.grid.feature.feature',         'ext.ux.touch.grid.feature.editable',         'ext.ux.touch.grid.feature.sorter',         'ext.field.number',         'geo.store.grid'     ],      config : {         title    : 'grid',         store    : true,         columns  : [             {                 header    : 'text',                 dataindex : 'text',                 width     : '90%',                 editor    : {                     xtype  : 'textfield'                 }             },             {                 header    : 'amount',                 dataindex : 'amount',                 width     : '10%',                 editor    : {                     xtype  : 'numberfield'                 }             }         ],         features : [             {                 ftype    : 'ext.ux.touch.grid.feature.sorter',                 launchfn : 'initialize'             },             {                 ftype    : 'ext.ux.touch.grid.feature.editable',                 launchfn : 'initialize'             }         ]     },      applystore : function() {         return new geo.store.grid();     } }); 

when direct use in main view file,it's correct

 items: [      {xtype: 'dashboards'},      {xtype: 'testgrid'}  ] 

who know reason? lot

do set store autoload: true, (?)


Comments

Popular posts from this blog

image - ClassNotFoundException when add a prebuilt apk into system.img in android -

I need to import mysql 5.1 to 5.5? -

Java, Hibernate, MySQL - store UTC date-time -