Page 1 of 1

logout service does not work, returns bad request code

Posted: Mon Dec 08, 2014 11:53 am
by maha

Hi,
We cannot get the logout service to work. The service returns a bad request (we can see using a javascript alert showing the returned data). We have followed the information tutorials on these pages, several times to be sure we are doing everything correctly:

http://devcenter.appery.io/documentat...

http://devcenter.appery.io/tutorials/...

Our login service seems to work fine. but Logout does not. What could be wrong, and how can we fix it?

Regards,
Maha


logout service does not work, returns bad request code

Posted: Mon Dec 08, 2014 12:00 pm
by Evgene Karachevtsev

Hello Maha,

Could you please provide us with a screenshot of a mapping of the logout service?


logout service does not work, returns bad request code

Posted: Mon Dec 08, 2014 2:47 pm
by maha

logout service does not work, returns bad request code

Posted: Tue Dec 09, 2014 2:09 am
by Yurii Orishchuk

Hi maha,

You gave us not mapping. To see mapping you should click on "before send" mapping.

Also i see you have some "before send" javascript - show us it to.

Also, before making screen shot please make sure you linked your session token your correct session token.

Details: http://prntscr.com/5erw8d/direct

Regards.


logout service does not work, returns bad request code

Posted: Wed Dec 10, 2014 8:46 am
by maha

Image Image

Thanks for your reply - the mapping looks like yours, so we cannot see the problem.

The javascript sets a global variable we are using to hide buttons if the user is not logged in. We see it should be moved to on success - though the logout still failed without this javascript


logout service does not work, returns bad request code

Posted: Wed Dec 10, 2014 11:22 am
by Evgene Karachevtsev

Hello Maha,

Works for us.
1) Could you please clarify, have you tested that you actually receive token?
2) Service sends back bad request if:

  • Token is expired
  • There is no token at all
  • Token is wrong

logout service does not work, returns bad request code

Posted: Wed Dec 10, 2014 11:35 am
by GordonG

Hi Evgene,
I am working with Maha and her team as part of their student project, and helping them to mediate this problem.

Code: Select all

The login service returns success - we know because on success it navigates to a new page. 

How could we tell if, in #2, the specific token meets one of those issues?

The thing is, I am coming into the middle of the team's development process, so I have tried to help them sort out some of the problems they have had.

For example, I suspected that their login was tied to a different database service (they have several databases, rather than several collections in one database) - and I think they sorted that issue out, but perhaps not.

So is there any way to get information about the token to be able to determine if it has expired, it is not there at all, or it is wrong? How can we debug it?

Thanks for your help,
Gordon


logout service does not work, returns bad request code

Posted: Wed Dec 10, 2014 10:59 pm
by Yurii Orishchuk

Hi GordonG,

To know a reason of this problem:

  1. please open browser debugger on network tab.

  2. invoke logout service.

  3. find logout request in browser debugger on net tab.

  4. take a look if "token" passed correctly in the header.

  5. take a look on response to see the reason of the problem.

    Regards.


logout service does not work, returns bad request code

Posted: Mon Dec 22, 2014 9:26 am
by maha

Good evening..

I have other issue..
I created a page and I have in this page 2 buttons and 2 list. First button to choose the city from the list. Second button to chose one of the hospitals in the city that I choose from list. Then, I created map because I want the location appear in the map"the location of hospital".

The problem is I want the location of hospital that I choose from list appear in the map..

I tried several way to make it appears but it didn't work.. Also. I followed this tutorial http://devcenter.appery.io/tutorials/...

My question: Do you have any codes that I should write to make the map work based on the hospital that I choose.


logout service does not work, returns bad request code

Posted: Mon Dec 22, 2014 1:13 pm
by Maryna Brodina

Hello!

Unfortunately we don't have any code snippets, please try using documentation https://developers.google.com/maps/do...