Пример #1
0
 public static DocCategoryInfo FromDocCategory(DocCategory category)
 {
     return new DocCategoryInfo
     {
         Id = category.Id,
         Name = category.Name,
         Description = category.Description
     };
 }
Пример #2
0
 public void UpdateCategory(DocCategory category)
 {
     this.Repository.UpdateCategory(category);
 }
Пример #3
0
 public void AddCategory(DocCategory category)
 {
     this.Repository.AddCategory(category);
 }
Пример #4
0
 public void DeleteCategory(DocCategory category)
 {
     this.Repository.DeleteCategory(category);
 }
 public ActionResult Delete(int categoryId)
 {
     DocCategory cat = new DocCategory { Id = categoryId };
     this.DocCatService.DeleteCategory(cat);
     return RedirectToAction("List");
 }