Esempio n. 1
0
 public void InsertCategory(Category category)
 {
     db.Categories.Add(category);
     db.SaveChanges();
 }
Esempio n. 2
0
 public void DeleteCategory(Category category)
 {
     db.Categories.Remove(category);
     db.SaveChanges();
 }
Esempio n. 3
0
 public void DisableCategory(Category category)
 {
     db.Categories.Add(category).Active = false;
     db.SaveChanges();
 }
Esempio n. 4
0
 public void CategoryTestInitialize()
 {
     Console.Out.Write("CategoryTestInitialize called...");
     _categoryRepository = new CategoryRepository();
     _category = new Category();
 }