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()); } }
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")); } }
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")); } }
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()); } }