Success! Looks like we've fixed this one. According to our records the fix was applied for EXTJS-9176 in a recent build.
  1. #1
    Sencha User tradingpursuits's Avatar
    Join Date
    Sep 2011
    Posts
    6
    Vote Rating
    0
    tradingpursuits is on a distinguished road

      0  

    Exclamation Updating a record in grouped store, trigger remove action on the store's proxy

    Updating a record in grouped store, trigger remove action on the store's proxy


    In Ext JS version 4.0.2.663, updating the group field of a record in grouped store, cause that record to be remove then reinserted. Unfortunately, the remove is not silent therefore it trigger the remove action on the store's proxy.

    Offending code is located at updateGroupsOnUpdate function, src/data/Store.js (line 1142).

  2. #2
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,501
    Vote Rating
    47
    Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    Thanks for the report! I have opened a bug in our bug tracker.

  3. #3
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,501
    Vote Rating
    47
    Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    Sorry about that. The overrides are:

    Code:
    Ext.override(Ext.data.Group, {
        contains: function(record){
            return Ext.Array.indexOf(this.records, record) !== -1;
        }
    });
    Code:
    Ext.override(Ext.data.Store, {
        updateGroupsOnUpdate: function(record, modifiedFieldNames){
            var me = this,
                groupField = me.getGroupField(),
                groupName = me.getGroupString(record),
                groups = me.groups,
                len, i, items, group;
                
            if (modifiedFieldNames && Ext.Array.indexOf(modifiedFieldNames, groupField) !== -1) {
                // First find the old group and remove the record
                items = groups.items;
                for (i = 0, len = items.length; i < len; ++i) {
                    group = items[i];
                    if (group.contains(record)) {
                        group.remove(record);
                        break;
                    }
                }
                groups.getByKey(groupName);
                if (!group) {
                    group = groups.add(new Ext.data.Group({
                        key: groupName,
                        store: me
                    }));
                }
                group.add(record);
                
                // At this point we know that we're sorted, so re-insert the record
                me.suspendEvents();
                me.remove(record, true);
                me.addSorted(record);
                me.resumeEvents();
            } else {
                // some other field changed, just mark the group as dirty
                groups.getByKey(groupName).setDirty();    
            }
        }
    });

Thread Participants: 1

Tags for this Thread

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi