This is a migrated thread and some comments may be shown as answers.

Performing multiple data store filter requests

3 Answers 72 Views
Data Source
This is a migrated thread and some comments may be shown as answers.
Tim
Top achievements
Rank 1
Tim asked on 21 Dec 2011, 02:53 AM
Hi,

We have a server side filtering component to our data store. When we issue multiple requests before the server can respond:

dataStore.filter({ user_id: 1 });
dataStore.filter({ user_id: 2 });

The "user_id = 1" request may end up coming after the second request, which means the displayed data is not what the user requested.

Is there a way that this can be fixed? It seems like we can only listen to onChange events in the dataSource, which unfortunately don't tell us which request this response data is for. Thanks!

3 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 23 Dec 2011, 08:56 AM
Hello,

 You need to wait for the first request to complete before issuing a second one. Could you please let us know what exactly are you trying to achieve? Perhaps there are better ways to accomplish your task.

All the best,
Atanas Korchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Tim
Top achievements
Rank 1
answered on 24 Dec 2011, 12:08 AM
Hi,

We have navigation links on the left side that perform server-side filtering of user data (see screenshot). When a user clicks the link on the left, it cause the middle section to load new data.

Is there a better way this should be performed? Thanks!
0
Atanas Korchev
Telerik team
answered on 26 Dec 2011, 09:50 AM
Hi,

 You can try disabling all filtering links until the response from the datasource is received (the change event is raised).

Regards,
Atanas Korchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
Data Source
Asked by
Tim
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Tim
Top achievements
Rank 1
Share this question
or