Beispiel #1
0
        // Post: Admin/Category/Delete/id
        public virtual ActionResult Delete(int id)
        {
            ServiceCategory category = _serviceCategoryService.Find(id);

            if (category == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            _serviceCategoryService.Remove(id);
            _uow.SaveAllChanges();
            return(Json(new { success = true }));
        }