1. #1
    Touch Premium Member
    Join Date
    Jun 2010
    Posts
    324
    Vote Rating
    2
    profunctional is on a distinguished road

      0  

    Default How do you insert an item into a store?

    How do you insert an item into a store?


    store.Insert(0, {'TypeId': '', 'TypeName': 'Select Type'});

    This doesn't seem to work.

  2. #2
    Sencha - Community Support Team VinylFox's Avatar
    Join Date
    Mar 2007
    Location
    Baltimore, MD
    Posts
    1,501
    Vote Rating
    7
    VinylFox will become famous soon enough VinylFox will become famous soon enough

      0  

    Default


    The insert method takes a Model instance as the 2nd argument, which is different from the object literal that contains the data for that record.

  3. #3
    Touch Premium Member
    Join Date
    Jun 2010
    Posts
    324
    Vote Rating
    2
    profunctional is on a distinguished road

      0  

    Default Here is the solution

    Here is the solution


    here is how i did it:

    Code:
    var emptySelect = Ext.ModelMgr.create({
                                    TypeId : '',
                                    TypeName  : 'Select Type',
                                 
                                }, 'Type');
                                typeStore.insert(0, emptySelect );

  4. #4
    Ext User mrnap's Avatar
    Join Date
    Oct 2010
    Location
    Chicago
    Posts
    13
    Vote Rating
    0
    mrnap is on a distinguished road

      0  

    Default


    Also, if you're just trying to insert an item (object), you can use the stores add() method.

Similar Threads

  1. Replies: 3
    Last Post: 3 Sep 2010, 6:28 PM
  2. Insert item to Grid Store and let the row fade in
    By grandfatha in forum Ext GWT: Discussion
    Replies: 0
    Last Post: 9 Oct 2009, 4:54 AM
  3. How to insert an item(button) between...
    By Joey Kwon in forum Ext 3.x: Help & Discussion
    Replies: 4
    Last Post: 16 Jul 2009, 5:34 PM
  4. Insert item comboBox
    By Perfect Lion in forum Ext 1.x: Help & Discussion
    Replies: 3
    Last Post: 11 Oct 2007, 10:21 PM

Thread Participants: 2

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar