on 01-27-2016 9:00 PM
Hi gurus,
I'm facing a problem using the filter for a model. For some reason I'm using the same filter to a model to feed two different objects, a Table and a List.
The problem is that when I set a filter criteria with no data, the table shows a couple of minutes the busy indicator and then the message "No data", and it's ok. But when I do the same excercise with the List, the busy indicator never stops.
Is there any attribute that I'm maybe not considering to make it work correctly?
I tried using:
and it stops the busy indicator but maintain the last data on the view.
the I tried with:
and in no case I get a Failed request, so never get in there.
Thanks for your time!
Andrés
hi Andres,
It looks like you're actually "selecting" records - this would imply it's a GET operation. However, in your code, you refer to oModel.attachBatchRequestFailed but it doesn't look like you're doing a batch request at all.
How about you use oModel.attachRequestFailed and oModel.attachRequestCompleted instead and check if it stops there?
Cheers,
Dan.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Daniel,
thanks for your help.
I tried with oModel.attachRequestFailed with no success, it dind't stop.
Now I'm trying to do something like:
var messageModel = sap.ui.getCore().getMessageManager().getMessageModel();
in order to get the error message, the thing is that I can't capture the error to stop the busy indicator.
Thank you again!
Hi gurus,
I solved my problem, not changing the implementation, but changing the template. I started this development a weeks a go, using the oeprative (in that moment) template Full Screen 1.0.0 (deprecated), today I migrated it to the version Worklist 1.28, according to my client server version and now it's working fine. Sends the message and the busy indicator cuts when it has to do it.
Thanks a lot for your help and time!
using delayCall (5000 is bad idea
control/binding/model provide plenty of callback methods to set busy to false once operation is complete
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI Maksim,
thanks for your answer. I used the requestComplete and requestFailed methods, and in the table and list aswell I g a "bad request status 400" message. It never triggers any event so I can't catch it. In the other hand the table stops the busy indicator and the list don't. I re developed the list and maintains the behavior.
I Don't get how to catch the bad request exception in order to stop the busy indicator
thanks for your help!
Hi Maksim,
thanks for your replay again. I just developed it, and the problem is the same, because the call to the service never come back. I get this message in the console:
That method attachDataReceived works fine when I filter with correct values, but when the filter doesn't return values I get that message and never pass by that method.
Thanks a lot for your help!
Exactly!
I already debugged it.
Here the details, I filter with dates, when I put a date that doesn't have any SAP Document, it returns that message. I watch the data in two elements, a table and a list. The table does't have problems. The list stays loading data.
I have those three methods and never stop in this case.
I use a OData service to get the SAP Orders.
I get this from the console:
And i have this in the Component.js of a Full Screen template:
Maybe there is a way to capture the message and stop the busy indicator and set the "nodata" text.
Thanks in advance!
title says something, your content says something else
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.