Designing the App by Toggling Tab Bar

You must Login before you can answer or comment on any questions.

Hey Guys,

I am designing an app, which asks for login credentials from users before starting the app. If the user does not have an account, he signs up. If he has an account He signs in. If he does not do either of them, he cannot proceed. Once the user has signed in or signed up, the user can see the app normally. However, when he signs out (not close the application), the user can see only sign in page.

In order to solve the issue, I have created two tab groups. 1. login tab group 2. Main app tab group. Depending on users' sign in status, I try to toggle between two tab groups.

Here is my code. http://pastie.org/2517334

I am developing on Google Nexus One device. Let me know, if you need more information.

Any help is appreciated.

— asked 2 years ago by Chinmay Patel
2 Comments
  • so what is the question?

    — commented 2 years ago by Aaron Saunders

  • Hey Aaron, thanks for the response. I really apologize for half question. The problem with the code I have posted is that it does not behave as expected.

    When I open the app first time, it asks the user to login. When the user hit on sign_in button on sign_in.js, it correctly closes the login tab, and open the main app tab. Everything works fine as expected. But now, when user goes to settings tab and click on sign out, nothing happens. It supposed to get into "app:logged_out_successfully" event listener, close the main app tab and open the login tab. None of these happens when user clicks on sign out button.

    I may be missing very basic step. I will greatly appreciate, if you can identify the problem and guide me to the correct resource.

    Thank you very much for your time and efforts for helping me out.

    Cheers,

    Chinmay

    — commented 2 years ago by Chinmay Patel

Your Answer

Think you can help? Login to answer this question!