예제 #1
0
 public Category Update(Category category)
 {
     _databaseContext.Categories.Update(category);
     _databaseContext.SaveChanges();
     return(category);
 }
예제 #2
0
 public void Delete(Category category)
 {
     _databaseContext.Categories.Remove(category);
     _databaseContext.SaveChanges();
 }
예제 #3
0
 public Category AddCategory(Category category)
 {
     _databaseContext.Categories.Add(category);
     _databaseContext.SaveChanges();
     return(category);
 }