Beispiel #1
0
 public ActionResult Delete(JobPositionsViewModel model)
 {
     if (JobPositionDAL.Delete(model.Id))
     {
         return(RedirectToAction("Index"));
     }
     else
     {
         return(View(JobPositionDAL.GetById(model.Id)));
     }
 }
Beispiel #2
0
 public ActionResult Edit(JobPositionsViewModel model)
 {
     if (JobPositionDAL.Update(model))
     {
         return(RedirectToAction("Index"));
     }
     else
     {
         return(View(model));
     }
 }
 public ActionResult Create()
 {
     ViewBag.JobPosList = new SelectList(JobPositionDAL.GetAll(), "Id", "Name");
     return(View());
 }
Beispiel #4
0
 public ActionResult Delete(int id)
 {
     return(View(JobPositionDAL.GetById(id)));
 }
Beispiel #5
0
 // GET: JobPositions
 public ActionResult Index()
 {
     return(View(JobPositionDAL.GetAll()));
 }