public ActionResult ChangePass(string account) { try { ChangePassView view = new ChangePassView { Account = account, ConfirmPass = "", NewPass = "", OldPass = "" }; return(View(view)); } catch (Exception) { return(View()); } }
public bool ChangePass(ChangePassView model) { try { var _item = DbContext.Members.FirstOrDefault(x => x.Account == model.Account && x.Password == model.OldPass); if (_item != null && _item.Account != "") { _item.Password = model.NewPass; return(true); } return(false); } catch (System.Exception) { return(false); } }
public ActionResult ChangePass(ChangePassView model) { try { if (ModelState.IsValid) { if (_staffBusiness.ChangePass(model)) { _staffBusiness.Save(); return(Redirect("/Dashboard/Dashboard")); } } return(View()); } catch (Exception) { return(View()); } }
public bool ChangePass(ChangePassView model) { return(_staff.ChangePass(model)); }
public bool ChangePass(ChangePassView model) { return(_member.ChangePass(model)); }
public bool ChangePass(ChangePassView model) { return(_patient.ChangePass(model)); }