public ActionResult Edit(Guid id, FormCollection collection) { try { // TODO: Add update logic here Models.LocationInLibraryModel locationInLibraryModel = new Models.LocationInLibraryModel(); UpdateModel(locationInLibraryModel); locationInLibraryRepository.UpdateLocationInLibrary(locationInLibraryModel); return(RedirectToAction("Index")); } catch { return(View("EditLocationInLibrary")); } }
public ActionResult Create(FormCollection collection) { try { // TODO: Add insert logic here Models.LocationInLibraryModel locationInLibraryModel = new Models.LocationInLibraryModel(); UpdateModel(locationInLibraryModel); locationInLibraryRepository.InsertLocationInLibrary(locationInLibraryModel); return(RedirectToAction("Index")); } catch { return(View("CreateLocationInLibrary")); } }
// GET: LocationInLibrary/Delete/5 public ActionResult Delete(Guid id) { Models.LocationInLibraryModel locationInLibraryModel = locationInLibraryRepository.GetLocationInLibraryByID(id); return(View("DeleteLocationInLibrary", locationInLibraryModel)); }