public ActionResult DeleteConfirmed(int id)
        {
            PlanoExercicio planoexercicio = db.PlanoExercicio.Find(id);

            db.PlanoExercicio.Remove(planoexercicio);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
 public ActionResult Edit([Bind(Include = "Id,Nome,IdCliente,IdProfessor,IdModalidade")] PlanoExercicio planoexercicio)
 {
     if (ModelState.IsValid)
     {
         db.Entry(planoexercicio).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(planoexercicio));
 }
        public ActionResult Create([Bind(Include = "Id,Nome,IdCliente,IdProfessor,IdModalidade")] PlanoExercicio planoexercicio)
        {
            if (ModelState.IsValid)
            {
                db.PlanoExercicio.Add(planoexercicio);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

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

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