public ActionResult DeleteConfirmed(int id)
        {
            CENTROS_DE_COSTOS cENTROS_DE_COSTOS = db.CENTROS_DE_COSTOS.Find(id);

            db.CENTROS_DE_COSTOS.Remove(cENTROS_DE_COSTOS);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
 public ActionResult Edit([Bind(Include = "Id,Nombre")] CENTROS_DE_COSTOS cENTROS_DE_COSTOS)
 {
     if (ModelState.IsValid)
     {
         db.Entry(cENTROS_DE_COSTOS).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(cENTROS_DE_COSTOS));
 }
        public ActionResult Create([Bind(Include = "Id,Nombre")] CENTROS_DE_COSTOS cENTROS_DE_COSTOS)
        {
            if (ModelState.IsValid)
            {
                db.CENTROS_DE_COSTOS.Add(cENTROS_DE_COSTOS);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(cENTROS_DE_COSTOS));
        }
        // GET: CentrosDeCostos/Delete/5
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            CENTROS_DE_COSTOS cENTROS_DE_COSTOS = db.CENTROS_DE_COSTOS.Find(id);

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