public ActionResult AccountManager() { var listaccount = KhachHangAction.ListKhachHang(); ViewBag.Account = listaccount; return(View()); }
public ActionResult Register(string ho, string ten, string diachi, string sdt, string email, string matkhau, string nhaplaimatkhau, string quyen) { if (matkhau == nhaplaimatkhau) { KhachHangAction.addKhachHang(ten, ho, diachi, sdt, email, matkhau, nhaplaimatkhau); return(RedirectToAction("Login", "TMDT")); } else { TempData["LoiAccount"] = "Something wrong in password"; return(View()); } }
public ActionResult UpdateAccount(int makh, string ho, string ten, string diachi, string sdt, string email, string matkhau, string nhaplaimatkhau, string quyen) { if (matkhau == nhaplaimatkhau) { KhachHangAction.UpdateKhachHang(makh, ho, ten, diachi, sdt, email, matkhau, nhaplaimatkhau, quyen); return(RedirectToAction("AccountManager", "TMDT")); } else { TempData["LoiAccount"] = "Nhập lại mật khẩu sai"; return(View()); } }
public ActionResult DeleteAccount(int keyword) { KhachHangAction.XoaKhachHang(keyword); return(RedirectToAction("AccountManager", "TMDT")); }
public ActionResult UpdateAccount(int keyword) { ViewBag.Account = KhachHangAction.FindKhach(keyword); return(View()); }