コード例 #1
0
 public IHttpActionResult ResetPassword(string id, PasswordConfirmation password)
 {
     try
     {
         id = Encode.Base64Decode(id);
         string message = VerifyPasswords.Password(password);
         if (message == "Successfull")
         {
             DBOperations.SaveChangedPassword(password, id);
             return(Ok("Password Changed Successfully"));
         }
         else if (message == "Passswords Don't Match")
         {
             return(Ok("Passswords Don't Match"));
         }
         else
         {
             return(Ok("Password Change Not Successful"));
         }
     }
     catch (Exception ex)
     {
         LogFile.WriteLog(ex);
         return(BadRequest());
     }
 }
コード例 #2
0
        public IHttpActionResult VerifyEmployee(string id, PasswordConfirmation password)
        {
            string message = VerifyPasswords.Password(password);

            if (message == "Successfull")
            {
                CallStoredProc.RunAddUserInfo(password, id);
                return(Ok("Verified Successfully"));
            }
            else
            {
                return(Ok("Verification Not Successful"));
            }
        }
コード例 #3
0
ファイル: LoginController.cs プロジェクト: harik31197/HRMS
        public IHttpActionResult ResetPassword(string id, PasswordConfirmation password)
        {
            string message = VerifyPasswords.Password(password);

            if (message == "Successfull")
            {
                DBOperations.SaveChangedPassword(password, id);
                return(Ok("Password Changed Successfully"));
            }
            else if (message == "Passswords Don't Match")
            {
                return(Ok("Passswords Don't Match"));
            }
            else
            {
                return(Ok("Password Change Not Successful"));
            }
        }
コード例 #4
0
 public IHttpActionResult VerifyEmployee(string id, PasswordConfirmation password)
 {
     try
     {
         id = Encode.Base64Decode(id);
         string message = VerifyPasswords.Password(password);
         if (message == "Successfull")
         {
             CallStoredProc.RunAddUserInfo(password, id);
             return(Ok("Verified Successfully"));
         }
         else
         {
             return(Ok("Verification Not Successful"));
         }
     }
     catch (Exception ex)
     {
         LogFile.WriteLog(ex);
         return(BadRequest());
     }
 }