示例#1
0
        public ActionResult DeleteConfirmed(int id)
        {
            PlansCliente plansCliente = db.PlansCliente.Find(id);

            db.PlansCliente.Remove(plansCliente);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
示例#2
0
 public ActionResult Edit([Bind(Include = "IdPlansClie,IdClie,IdPlans,FechaPlansCliente,NumPersonasPlansClie,ValorPlansClie")] PlansCliente plansCliente)
 {
     if (ModelState.IsValid)
     {
         db.Entry(plansCliente).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.IdClie  = new SelectList(db.Cliente, "IdClie", "NombreClie", plansCliente.IdClie);
     ViewBag.IdPlans = new SelectList(db.Plans, "IdPlans", "ZonaPlans", plansCliente.IdPlans);
     return(View(plansCliente));
 }
示例#3
0
        // GET: PlansCliente/Details/5
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            PlansCliente plansCliente = db.PlansCliente.Find(id);

            if (plansCliente == null)
            {
                return(HttpNotFound());
            }
            return(View(plansCliente));
        }
示例#4
0
        // GET: PlansCliente/Edit/5
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            PlansCliente plansCliente = db.PlansCliente.Find(id);

            if (plansCliente == null)
            {
                return(HttpNotFound());
            }
            ViewBag.IdClie  = new SelectList(db.Cliente, "IdClie", "NombreClie", plansCliente.IdClie);
            ViewBag.IdPlans = new SelectList(db.Plans, "IdPlans", "ZonaPlans", plansCliente.IdPlans);
            return(View(plansCliente));
        }