public ActionResult DeleteConfirmed(int id) { UserTaxDetail userTaxDetail = db.UserTaxDetails.Find(id); db.UserTaxDetails.Remove(userTaxDetail); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "Id,PAN,IsKYCDone")] UserTaxDetail userTaxDetail) { if (ModelState.IsValid) { db.Entry(userTaxDetail).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(userTaxDetail)); }
public ActionResult Create([Bind(Include = "Id,PAN,IsKYCDone")] UserTaxDetail userTaxDetail) { if (ModelState.IsValid) { db.UserTaxDetails.Add(userTaxDetail); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(userTaxDetail)); }
// GET: UserTaxDetails/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } UserTaxDetail userTaxDetail = db.UserTaxDetails.Find(id); if (userTaxDetail == null) { return(HttpNotFound()); } return(View(userTaxDetail)); }