public ActionResult DeleteConfirmed(int id) { ExamenClinico examenClinico = db.ExamenClinico.Find(id); db.ExamenClinico.Remove(examenClinico); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "Id,Fecha,MotivoConsulta,FrecuenciaCardiaca,TemperaturaPaciente,Anamnesis,Diagnostico,Tratamiento,Tipo,IdMascota,Microchip")] ExamenClinico examenClinico) { if (ModelState.IsValid) { db.Entry(examenClinico).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.IdMascota = new SelectList(db.Mascota, "Id", "Nombre", examenClinico.IdMascota); return(View(examenClinico)); }
// GET: ExamenClinicoes/Details/5 public ActionResult Details(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } ExamenClinico examenClinico = db.ExamenClinico.Find(id); if (examenClinico == null) { return(HttpNotFound()); } return(View(examenClinico)); }
// GET: ExamenClinicoes/Edit/5 public ActionResult Edit(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } ExamenClinico examenClinico = db.ExamenClinico.Find(id); if (examenClinico == null) { return(HttpNotFound()); } ViewBag.IdMascota = new SelectList(db.Mascota, "Id", "Nombre", examenClinico.IdMascota); return(View(examenClinico)); }