//Search public ActionResult Search(string txtSearch) { using (BarangDAL bar = new BarangDAL()) { var result = bar.Search(txtSearch).ToList(); return(View("Index", result)); } }
public ActionResult Search(string txtSearch) { using (BarangDAL svCat = new BarangDAL()) { var results = svCat.Search(txtSearch).ToList(); TempData["Pesan"] = Helpers.Message.GetPesan(" ", "warning", "Anda mencari " + txtSearch); return(View(results)); } }