Example #1
0
        public ActionResult DeleteConfirmedEvDisponible(int id)
        {
            EvDisponible evdisp = db.EvDisponibles.Find(id);

            db.EvDisponibles.Remove(evdisp);
            db.SaveChanges();
            return(RedirectToAction("Perfil", "Admin", new { id = evdisp.perfil_id }));
        }
Example #2
0
        public ActionResult AgregarEvDisponible([Bind(Include = "id, evaluador_id, perfil_id")] EvDisponible evdisponible)
        {
            if (ModelState.IsValid)
            {
                db.EvDisponibles.Add(evdisponible);
                db.SaveChanges();
                return(RedirectToAction("Perfil", new { id = evdisponible.perfil_id }));
            }

            return(View());
        }
Example #3
0
        public ActionResult BorrarEvDisponible(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            EvDisponible evdisponible = db.EvDisponibles.Find(id);

            if (evdisponible == null)
            {
                return(HttpNotFound());
            }
            return(View(evdisponible));
        }