I want so set a $rootScope
variable stateSelection
value default as false
.
So when my applciation runs the value of the $rootScope.stateSelection
will be false
. I want to know how to set it at the time of initialization of app.
Right now i am setting it in my Auth
Service in login
function.
When User logs in & selects a state i call a method in a controller named clickSelection()
& in this function i change the $rootScope.stateSelection = true;
.
I get a problem when i refresh the page, the value of $rootScope.stateSelection
becomes false
.
Thanks