public ActionResult CategoryEdit(CategoriesItemViewModel item) { var model = category.Get_Category(item.Id); if (item != null) { model.Name = item.Name; model.Discription = item.Discription; category.SaveChange(); } var Category = category.Get_All().Select ( it => new CategoriesItemViewModel { Id = it.Id, Discription = it.Discription, Name = it.Name } ).ToList(); return(PartialView("Category", Category)); }