Example #1
0
        public ActionResult Delete(int?id)
        {
            bool isDeleted = _Manager.Delete(id);

            message = "This Item Delted Successfully!!";

            return(new JsonResult {
                Data = new { status = isDeleted, message = message }
            });
        }
Example #2
0
        public ActionResult Delete(GeneralCategory generalCategory)
        {
            bool isSaved = generalCategoryManager.Delete(generalCategory);


            if (isSaved)
            {
                ViewBag.Message = "Deleted Successfully!";
            }
            return(RedirectToAction("Create"));
        }