public ActionResult DeleteConfirmed(int id) { MierukaView mierukaView = db.MierukaView.Find(id); db.MierukaView.Remove(mierukaView); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "MachineNumber,Plan,Date,ActualCount,Unit")] MierukaView mierukaView) { if (ModelState.IsValid) { db.Entry(mierukaView).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(mierukaView)); }
public ActionResult Create([Bind(Include = "MachineNumber,Plan,Date,ActualCount,Unit")] MierukaView mierukaView) { if (ModelState.IsValid) { db.MierukaView.Add(mierukaView); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(mierukaView)); }
// GET: MierukaViews/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } MierukaView mierukaView = db.MierukaView.Find(id); if (mierukaView == null) { return(HttpNotFound()); } return(View(mierukaView)); }