Question

I am using ExtJS 4.1. I am using stores's remove() to delete the record from the store. I want to know which events get fired when you remove a record from the store. I looked at the sencha docs and I do not think there is a event for this specific requirement. This is the code I have written on the store's remove event. But its not working :(

Ext.define('MyStore', {
    extend: 'Ext.data.Store',
    model: 'MyModel',
    listners: {
        'remove': function(store, record, index, eOpts) {
            alert(record.data.MemberName);
        }
    }
});

Thanks!!

Était-ce utile?

La solution

From official documentation:

remove( records )
Removes the given record from the Store, firing the 'remove' event for each instance that is removed, plus a single 'datachanged' event after removal.

Available since: 1.1.0

Parameters records : Ext.data.Model/Ext.data.Model[]
Fires: beforesync bulkremove datachanged remove

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top