1. #1
    Ext JS Premium Member
    Join Date
    Mar 2011
    Posts
    8
    Vote Rating
    0
    starin is on a distinguished road

      0  

    Default xtype store

    xtype store


    We wrote a very comprehensive application that relies heavily on ExtJS3; we are very close to deploying it (this is a in-house application) and we want to see about upgrading to extjs4, to use many of the new features. However, 95% of our app relies on stores and grids, which happen to be the 2 biggest things upgraded.

    To get to the point, we use things like:
    PHP Code:
    ...
    store: {
      
    xtype'store',
      ....
    }
    ... 
    however it seems like store was removed from the xtype definitions, and Ext.reg was moved and/or removed.

    Is it possible to use xtype: 'store', or define it to use be used like ext3 used to? The reason xtype: 'store' worked great for us was because we are going to be using the same store config, but with different data within the same space. So, for example, if I define it like... new Ext.data.Store(...), it will use the same store class throughout every instance of that class I am making, and the multiple stores need to have different data in them, but be configured the same.

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,599
    Vote Rating
    814
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    xtypes are still around but when you extend a component you use the alias config. eg:

    Code:
    Ext.define("myClassPanel", {
        extend : "Ext.panel.Panel",
        alias  : "widget.myclasspanel",
        ...
    });
    Now you can use the xtype "myclasspanel". The alias has 2 parts that are delimited by the period, first part is the type of xtype and the second is the xtype. So here, the type is "widget" and xtype is "myclasspanel".

    Plugin example:

    Code:
    Ext.define("MyPlugin", {
        extend : "Ext.AbstractPlugin",
        alias  : "plugin.myplugin",
        ...
    });
    Here you can see the type is "plugin" and ptype is "myplugin".
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

Similar Threads

  1. store xtype
    By agentyikes in forum Sencha Touch 1.x: Discussion
    Replies: 6
    Last Post: 6 Sep 2013, 2:20 PM
  2. store as xtype
    By archmisha in forum Ext 3.x: Help & Discussion
    Replies: 6
    Last Post: 14 Aug 2009, 6:51 AM
  3. [Resolved] Ext 3.0. this.store not work in bbar and my xtype
    By Rafael in forum Ext 2.x: Help & Discussion
    Replies: 8
    Last Post: 16 Apr 2009, 2:40 PM
  4. referring to grid store in xtype
    By SunWuKung in forum Ext 2.x: Help & Discussion
    Replies: 5
    Last Post: 21 Jan 2009, 5:16 AM

Thread Participants: 1

Tags for this Thread