PDA

View Full Version : Problem using PullRefreshPlugin and ListPagingPlugin together



profunctional
11 Oct 2011, 6:02 AM
I'm not sure if this a bug so can someone else confirm that they experience this?

When I click "Load More..". on the ListPagingPlugin all works fine. I'm able to load page two of the results.

Immediately after page 2 loads, I do a PullToRefresh.

This will reset my list and load the first 25.

Next, I click "Load More..." and can no longer get to page 2.

The problem is that the store's currentPage is not reset back to 1. It is still at page 2.

Anyone else run into this?

hschriek
6 Feb 2012, 3:03 AM
Hi!

I had the same problem....fixed it with setting the Property "currentPage" back to 1.

....(list)
new Ext.plugins.PullRefreshPlugin({
pullRefreshText: 'Zum Laden herunterziehen',

releaseRefreshText: 'Zum Laden loslassen',

loadingText: 'Wird aktualisiert',

onLoadComplete: function() {
var me = this;


if (this.isLoading) {
this.isLoading = false;
this.lastUpdated = new Date();


this.setViewState('pull');
this.updatedEl.setHTML(Ext.util.Format.date(this.lastUpdated, "m/d/Y h:iA"));


setTimeout(function() {
me.scroller.updateBoundary(me.snappingAnimationDuration);
}, 100);
App.stores.auftraege.currentPage = 1;
}

}