Ejemplo n.º 1
0
        public ActionResult DeleteConfirmed(int id)
        {
            var p = new PacienteApiProcess();

            Paciente paciente = p.ReadBy(id);

            p.Delete(paciente);
            return(RedirectToAction("Index"));
        }
Ejemplo n.º 2
0
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            var      p        = new PacienteApiProcess();
            Paciente paciente = p.ReadBy(id.Value);

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