public ActionResult Temprature() { tempretureClass tempreture = new tempretureClass(); tempreture.temprutureChecks = db.temprutureChecks.ToList(); return(View(tempreture)); }
public ActionResult Addtemp(tempretureClass temp) { try { temp.tempruture.date_time = DateTime.Now; db.temprutureChecks.Add(temp.tempruture); db.SaveChanges(); return(RedirectToAction("Temprature")); } catch (Exception ex) { return(RedirectToAction("Addtemp")); } }
public ActionResult Addtemp() { tempretureClass tempreture = new tempretureClass(); return(View(tempreture)); }