Hi there,
I'm looking for a way to "reset" virtual scrolling on sorting/filtering. E.g in the code below I'm resetting the sort, pageSize and page params to the default values. Note that especially page is set to 1. While the datasource is retrieving the correct dataset the scroll bar isn't reset.
A live version that demonstrates this behavior can be found at http://openaccess.spirit.de/.
Without any filter applied scroll down a little and then either use the search box or the dropdown filter. The desired behavior would be that the dimension of the scroll bar would be newly calculated and the slider should move to the initial position whenever there's a request for page 1.
Thanks,
Rainer
I'm looking for a way to "reset" virtual scrolling on sorting/filtering. E.g in the code below I'm resetting the sort, pageSize and page params to the default values. Note that especially page is set to 1. While the datasource is retrieving the correct dataset the scroll bar isn't reset.
$('#search').val('')
.focus()
.keyup(function (event) {
App.DS.sharableDataSource.query({
filter:{
field:"LastName",
operator:"startswith",
value:event.currentTarget.value
},
sort:App.DS.sharableDataSource.options.sort,
pageSize:App.DS.sharableDataSource.options.pageSize,
page:1
})
});
A live version that demonstrates this behavior can be found at http://openaccess.spirit.de/.
Without any filter applied scroll down a little and then either use the search box or the dropdown filter. The desired behavior would be that the dimension of the scroll bar would be newly calculated and the slider should move to the initial position whenever there's a request for page 1.
Thanks,
Rainer