public void Remove(Category category)
        {
            category.IsRemoved = true;

            this.categories.Update(category);
            this.categories.SaveChanges();
        }
        public int Add(string name)
        {
            var category = new Category()
            {
                Name = name
            };

            this.categories.Add(category);
            this.categories.SaveChanges();

            return category.Id;
        }
 public int Update(Category category)
 {
     this.categories.Update(category);
     this.categories.SaveChanges();
     return category.Id;
 }