public async Task <ActionResult <IEnumerable <BacklogItem> > > GetAllBacklogItems() { var backlogItems = await _backlogItemRepository.Get(); if (!backlogItems.Any()) { return(NotFound("No backlogItems found.")); } else { return(Ok(backlogItems)); } }
public void CommitBacklogItemToSprint(CommitBacklogItemToSprintCommand command) { var tenantId = new TenantId(command.TenantId); var sprint = _sprintRepository.Get(tenantId, new SprintId(command.SprintId)); var backlogItem = _backlogItemRepository.Get(tenantId, new BacklogItemId(command.BacklogItemId)); sprint.Commit(backlogItem); _sprintRepository.Save(sprint); }