예제 #1
0
 /// <summary>
 /// Efetua o Logout do usuário
 /// </summary>
 public void Loggof()
 {
     this.CurrentUser = null;
     HttpContext.Current.Session.Abandon();
     HttpContext.Current.Session.RemoveAll();
 }
예제 #2
0
 /// <summary>
 /// Valida os dados de acesso do usuário
 /// </summary>
 /// <param name="username">nome do usuario</param>
 /// <param name="password">senha do usuario</param>
 /// <returns></returns>
 public bool Login(string username, string password)
 {
     this.CurrentUser = AdmUser.UserLogin(username, password);
     SaveCookie();
     return (CurrentUser.ID != 0);
 }