I need to set the start param (operation.setStart(1)) when refreshing my list using the PullToRefresh sencha touch 2 plugin.
I can do this just fine within the onJsonpstoreBeforeLoad function, because this function parses the operation parameter object
onJsonpstoreBeforeLoad: function(store, operation, eOpts) {
/* some before load operations */
var startIndex = operation.getStart();
/* increase the value of the start-index by one */
operation.setStart(startIndex+1);
}
But within the PullToRefresh plugin’s “on refresh” function, it only parses the plugin parameter, but I need to get the operation in order to use setStart()
....
refreshFn: function(plugin) {
console.log(Ext.data.Operation);
}, ....
Does anyone know how to get the current operation? I can get the store/proxy using plugin.getParent() but this does not help 🙁
you can call
Hope this help!!