Exemple #1
0
        public async Task <Category> InsertCategory(Category obj)
        {
            _dbContext.Add(obj);
            await _dbContext.SaveChangesAsync();

            return(obj);
        }
Exemple #2
0
        public async Task <Book> Insert(Book book)
        {
            _dbContext.Add(book);
            await _dbContext.SaveChangesAsync();

            return(book);
        }