Page 2 of 5

Display service response error message on application as an alert.

Posted: Mon Oct 08, 2012 7:25 pm
by Kevin

Tried mapping to label but still can't get the error message to show.


Display service response error message on application as an alert.

Posted: Mon Oct 08, 2012 8:02 pm
by maxkatz

Can you share the app with a href="mailto:support@tiggzi.com" rel="nofollow"support@tiggzi.com/a? Tell me exactly how to get a valid response and invalid response.


Display service response error message on application as an alert.

Posted: Mon Oct 08, 2012 8:26 pm
by Kevin

I've shared Shared.

From Tiggzi

  1. Go to the signupScreen.

  2. Click on Edit parsesignup service.

  3. Test Connection and enter some info on the username and password parameter values.Try a username like temeke which is already registered to get an invalid response.

    From App

  4. Run app

  5. Click on create account button.

  6. Try filling in the registration form. Try a username like temeke which is already registered to get an invalid response.


Display service response error message on application as an alert.

Posted: Mon Oct 08, 2012 8:57 pm
by maxkatz

I'm not sure why direct mapping is not working, it should. I'll have to test it more.

I added an error event with this code and it works:
code
var errorText = JSON.parse(jqXHR.responseText);
Tiggzi('errorlabel').text(errorText.error);
/code


Display service response error message on application as an alert.

Posted: Tue Oct 09, 2012 2:44 am
by Kevin

Thanx Max.


Display service response error message on application as an alert.

Posted: Mon Nov 18, 2013 1:09 am
by Robert Larsen

I am having same issue I want to get error to appear but cannot. What am I doing wrong? I have tried both scripts of java provided. Image Imageinline.png?1384736912[/img] [/url] Image


Display service response error message on application as an alert.

Posted: Mon Nov 18, 2013 2:57 am
by maxkatz

Try Complete event - to check if the service is invoked.


Display service response error message on application as an alert.

Posted: Mon Nov 18, 2013 3:25 am
by Robert Larsen

Tried changing it to complete event, it still does not work. I am testing the app in the appery test page, would that cause an issue?


Display service response error message on application as an alert.

Posted: Mon Nov 18, 2013 3:29 am
by maxkatz

What I meant, the complete event is always invoke -after a successful invocation or an error. Did you add any debugging and saw the event being fired?


Display service response error message on application as an alert.

Posted: Mon Nov 18, 2013 4:05 am
by Robert Larsen

I ran in console the event is being fired. The event in this case is "not found". I have that event mapped and have tried mapping it to the local resource "error" and then adding the event to run j/s, but still no luck. I have also attached a screen shot for all the possible errors, I have added them to rest service just only mapped one but i am firing the event for the one that is mapped. Image Imageinline.png?1384747530[/img] [/url]