Hey guys,
I have a problem with an oData model. I hope you can help.
I use one model globally which contains three types of data, lets name them alpha, beta and gamma. I have three different views containing one table each which all use the global oData model. In these tables I only display data of the certain type using bindRows("/alpha") etc.
Now come the problems:
If I switch between the tabs a few times and refresh the model at one point a whole bunch of count calls are fired.
Lets say we navigate like this: alpha - gamma - beta - gamma - alpha and then we refresh the model. This results in the following count calls (all caused by one model refresh):
<uri of the oData model>/alpha/$count
<uri of the oData model>/gamma /$count
<uri of the oData model>/beta /$count
<uri of the oData model>/gamma /$count
<uri of the oData model>/alpha /$count
Every further navigation leads to an additional count call at the end of this chain. You might imagine that this becomes a huge issue once I use the application for some time.
I have tried the following to prevent this from happening, without success though:
- only refresh the elements of a certain type (there is a method to do this but I failed using it properly SAPUI5 SDK - Demo Kit since I don't know what to put in)
- "clear" the model so only the most recent count call is fired
Do you have any tips or ideas?
Thanks