public int SetCategory(Category category) { _logger.Info($"BLL.{nameof(CategoryBll)}.{nameof(SetCategory)}: Retention of the category"); if (category.Id != null) { int id = _categoryDao.ChangeCategory(category); _logger.Info($"BLL.{nameof(CategoryBll)}.{nameof(SetCategory)}: Category id = {id} changed"); return(id); } else { int id = _categoryDao.AddCategory(category); _logger.Info($"BLL.{nameof(CategoryBll)}.{nameof(SetCategory)}: Category id = {id} added"); return(id); } }
public void AddCategory(Category category) { categoryDao.AddCategory(category); }
public bool AddCategory(Category c) { return(categoryDao.AddCategory(c)); }
public bool AddCategory(string categoryName, bool status) { return(categoryDao.AddCategory(categoryName, status)); }