i have ionic side menu > and it has sign-up and sign-in links.
i am trying to hide the sign-up and sign-in based on the logged in state.

if logged in then sign-in, sign-up links should be hidden and if not logged in then both should be visible.

i am using angular factory to save the sate and using ng-show/ng-hide attributes trying to do the toggling. but it's not working.

please help.

regards,
ad

below is my code:
html:

 Sign-In

```
    <ion-item menu-close class="item-icon-left" ng-click="signup()" ng-show ="AppGlobalValues.isLoggedIn()" >
             <i class="icon ion-edit"></i>
      Sign-Up
    </ion-item>

```

services.js
-----------

.......
.factory('AppGlobalValues', function() {
 // Might use a resource here that returns a JSON array

// Some fake testing data
 // 

var loggedIn = 'FALSE';

return {

```
init:function(){
  loggedIn = 'FALSE';

},

setLoggedIn: function(pLoggedIn) {
    loggedIn=pLoggedIn;
},

isLoggedIn: function(num){

  console.log("number:",num);

    return loggedIn;

}

```

};
})