View Full Version : using alias in Ext.data.store for model

20 May 2013, 3:05 AM
Can any one help me on my issue? I have created a model and set alias name to that model and using the same alias name in Ext.data.store and set model to alias name it doesn't work and with complete name of model it works why?

Ext.define('lancet.asset.system.combobox.models.PathwayModel', { extend: 'lancet.def.system.model.Model', alias: 'widget.pathwaymodel', fields: [ { name: 'Id', type: 'string' }, { name: 'Name', type: 'string' }, { name: 'group', type: 'string' } ] });

Ext.create('Ext.data.Store', { model: 'lancet.asset.system.combobox.models.PathwayModel',//it's work autoLoad: true }

Ext.create('Ext.data.Store', { model: 'PathwayModel',//it doesn't work autoLoad: true }

20 May 2013, 3:59 AM
I don't believe there is a alias prefix for Ext.data.Model. Besides, you are trying to use the "widget" prefix which is for components.