|
|
@@ -75,7 +75,7 @@ namespace CD67.FicheCollege.MVC.Controllers
|
|
|
{
|
|
|
ActionEduFactory fact = new ActionEduFactory(db);
|
|
|
fact.add(ref actionEdu);
|
|
|
- return RedirectToAction("Index", new { annee_id = actionEdu.AnneeId });
|
|
|
+ return RedirectToAction("Details", new { id = actionEdu.Id });
|
|
|
}
|
|
|
ActionEduViewModel model = new ActionEduViewModel(actionEdu, db, ModeAcces.Creation);
|
|
|
return View("Edit", model);
|
|
|
@@ -109,7 +109,7 @@ namespace CD67.FicheCollege.MVC.Controllers
|
|
|
{
|
|
|
ActionEduFactory fact = new ActionEduFactory(db);
|
|
|
fact.update(ref actionEdu);
|
|
|
- return RedirectToAction("Index", new { annee_id = actionEdu.AnneeId });
|
|
|
+ return RedirectToAction("Details", new { id = actionEdu.Id });
|
|
|
}
|
|
|
if (actionEdu.Annee == null)
|
|
|
{
|
|
|
@@ -215,30 +215,6 @@ namespace CD67.FicheCollege.MVC.Controllers
|
|
|
return RedirectToAction("Index", new { annee_id = Annee_Id });
|
|
|
}
|
|
|
|
|
|
- public ActionResult Up(int? id)
|
|
|
- {
|
|
|
- if (id == null)
|
|
|
- {
|
|
|
- return new HttpStatusCodeResult(HttpStatusCode.BadRequest);
|
|
|
- }
|
|
|
- ActionEduFactory fact = new ActionEduFactory(db);
|
|
|
- ActionEdu actionEdu = fact.getById(id.Value);
|
|
|
- fact.Up(ref actionEdu);
|
|
|
- return RedirectToAction("Index", new { annee_id = actionEdu.AnneeId });
|
|
|
- }
|
|
|
-
|
|
|
- public ActionResult Down(int? id)
|
|
|
- {
|
|
|
- if (id == null)
|
|
|
- {
|
|
|
- return new HttpStatusCodeResult(HttpStatusCode.BadRequest);
|
|
|
- }
|
|
|
- ActionEduFactory fact = new ActionEduFactory(db);
|
|
|
- ActionEdu actionEdu = fact.getById(id.Value);
|
|
|
- fact.Down(ref actionEdu);
|
|
|
- return RedirectToAction("Index", new { annee_id = actionEdu.AnneeId });
|
|
|
- }
|
|
|
-
|
|
|
protected override void Dispose(bool disposing)
|
|
|
{
|
|
|
if (disposing)
|