public async Task AddAsync(string description) { var item = new TodoItem() { Description = description, CreatedDate = DateTime.UtcNow }; dbContext.Add(item); await dbContext.SaveChangesAsync(); }
public void AddTodoItem(TodoItem todoItem) { _context.Add(todoItem); }