示例#1
0
        public async Task <ActionResult> DeleteConfirmed(long id)
        {
            Plantilla_Correo plantilla_Correo = await db.Plantilla_Correo.FindAsync(id);

            db.Plantilla_Correo.Remove(plantilla_Correo);
            await db.SaveChangesAsync();

            return(RedirectToAction("Index"));
        }
示例#2
0
        public async Task <ActionResult> Edit([Bind(Include = "plantilla_correo_id,nombre,descripcion,asunto,cuerpo,FK_plantillas_correo_estado_rips,fecha_modificacion")] Plantilla_Correo plantilla_Correo)
        {
            if (ModelState.IsValid)
            {
                db.Entry(plantilla_Correo).State = EntityState.Modified;
                await db.SaveChangesAsync();

                return(RedirectToAction("Index"));
            }
            ViewBag.FK_plantillas_correo_estado_rips = new SelectList(db.Estado_RIPS, "estado_rips_id", "tipo", plantilla_Correo.FK_plantillas_correo_estado_rips);
            return(View(plantilla_Correo));
        }
示例#3
0
        // GET: Plantilla_Correo/Details/5
        public async Task <ActionResult> Details(long?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            Plantilla_Correo plantilla_Correo = await db.Plantilla_Correo.FindAsync(id);

            if (plantilla_Correo == null)
            {
                return(HttpNotFound());
            }
            return(View(plantilla_Correo));
        }
示例#4
0
        // GET: Plantilla_Correo/Edit/5
        public async Task <ActionResult> Edit(long?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            Plantilla_Correo plantilla_Correo = await db.Plantilla_Correo.FindAsync(id);

            if (plantilla_Correo == null)
            {
                return(HttpNotFound());
            }
            ViewBag.FK_plantillas_correo_estado_rips = new SelectList(db.Estado_RIPS, "estado_rips_id", "tipo", plantilla_Correo.FK_plantillas_correo_estado_rips);
            return(View(plantilla_Correo));
        }