Пример #1
0
        public ActionResult DeleteConfirmedAdministrador(int id)
        {
            Radiologo radiologo = db.Radiologo.Find(id);

            db.Radiologo.Remove(radiologo);
            db.SaveChanges();
            return(RedirectToAction("IndexAdministrador"));
        }
Пример #2
0
 public ActionResult EditTecnico([Bind(Include = "CodigoRadiologo,NombreUsuario,Activo")] Radiologo radiologo)
 {
     if (ModelState.IsValid)
     {
         db.Entry(radiologo).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.NombreUsuario = new SelectList(db.Usuario, "NombreUsuario", "Contrasenna", radiologo.NombreUsuario);
     return(View(radiologo));
 }
Пример #3
0
        public ActionResult Create([Bind(Include = "CodigoRadiologo,NombreUsuario,Activo")] Radiologo radiologo)
        {
            if (ModelState.IsValid)
            {
                db.Radiologo.Add(radiologo);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            ViewBag.NombreUsuario = new SelectList(db.Usuario, "NombreUsuario", "Contrasenna", radiologo.NombreUsuario);
            return(View(radiologo));
        }
Пример #4
0
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            Radiologo radiologo = db.Radiologo.Find(id);

            if (radiologo == null)
            {
                return(HttpNotFound());
            }
            return(View(radiologo));
        }
Пример #5
0
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            Radiologo radiologo = db.Radiologo.Find(id);

            if (radiologo == null)
            {
                return(HttpNotFound());
            }
            ViewBag.NombreUsuario = new SelectList(db.Usuario, "NombreUsuario", "Contrasenna", radiologo.NombreUsuario);
            return(View(radiologo));
        }