예제 #1
0
 public JsonResult Delete(string[] id)
 {
     for (int i = 0; i < id.Length; i++)
     {
         try
         {   // TODO: Add delete logic here
             AuthorsModel.Delete(Convert.ToInt16(id[i]));
         }
         catch
         {
             //return View();
             return(Json(id[i]));
         }
     }
     return(Json(id));
 }
예제 #2
0
 // GET: Author/Delete/5
 public ActionResult Delete(int id)
 {
     AuthorsModel.Delete(id);
     return(RedirectToAction("Index"));
 }