Keeping vertical scroll position while refreshing resources

Ask for help related to our 2.x versions.
Post Reply
User avatar
jeffrey.bolleboom
Posts: 15
Joined: Thu Jul 03, 2014 3:03 pm

Keeping vertical scroll position while refreshing resources

Post by jeffrey.bolleboom »

Hi,
I have a scenario when a list of resources should be at some points refreshed to make it up-to-date (other users might have modified it for example). For now I do not really see a possibility to call the load of the resources store without refreshing the view which is done automatically on succesfull load.

What is problematic is that the grid view refresh resets the vertical scroll position. The changes in the list of resource will not be huge so even if the top offset kept from before refresh won't be 100% precise it will be close enough.

Any suggestions of how might I achive functionality which allows to refresh list of resources while keeping the vertical scroll position? For a moment a was thinking about the CrudManager (currently using "raw" stores) but it doesn't seem to be helpful.


Regards


User avatar
jeffrey.bolleboom
Posts: 15
Joined: Thu Jul 03, 2014 3:03 pm

Re: Keeping vertical scroll position while refreshing resour

Post by jeffrey.bolleboom »

Didn't look for the private members. I will give it a try.
But in the meantime do you think suspending events on the resource store before load, restoring it after and refreshing the schedulingView using refreshKeepingScroll() would work? It is a bit hard for me to judge what side effects can be triggered by that suspending events.

User avatar
Terence
Core Developer
Core Developer
Posts: 1526
Joined: Tue Apr 01, 2014 2:23 pm

Re: Keeping vertical scroll position while refreshing resour

Post by Terence »

Resources are normalized after loading, I think you should not suspend events of the resourcestore.

User avatar
kevinvdheuvel
Posts: 94
Joined: Mon Mar 09, 2015 3:31 pm

Re: Keeping vertical scroll position while refreshing resources

Post by kevinvdheuvel »

I am using bryntum-scheduler v5-1-13
We are trying to drag object to new position . This leads to refresh the 'complete UI grid' and the position of vertical scroll bar moves to top .

User avatar
mats
Core Developer
Core Developer
Posts: 16213
Joined: Sat Dec 19, 2009 11:41 pm
Location: Sweden
Contact:

Re: Keeping vertical scroll position while refreshing resources

Post by mats »

Try using the latest version, should most likely be fixed there.
Tired of debugging javascript errors in web applications? Try our new error logging service RootCause, or read more on the Sencha blog

@bryntum
Facebook
API documentation

User avatar
kevinvdheuvel
Posts: 94
Joined: Mon Mar 09, 2015 3:31 pm

Re: Keeping vertical scroll position while refreshing resources

Post by kevinvdheuvel »

As we are on bryntum-scheduler v5-1-13
Could you suggest the version that we need to upgrade ?

User avatar
mats
Core Developer
Core Developer
Posts: 16213
Joined: Sat Dec 19, 2009 11:41 pm
Location: Sweden
Contact:

Re: Keeping vertical scroll position while refreshing resources

Post by mats »

Tired of debugging javascript errors in web applications? Try our new error logging service RootCause, or read more on the Sencha blog

@bryntum
Facebook
API documentation

Post Reply