зеркало из
1
0
Форкнуть 0
This commit is contained in:
Dan Hellem 2019-07-05 12:25:48 -07:00
Родитель 92dbfba982
Коммит ed2c7fe3ed
1 изменённых файлов: 25 добавлений и 0 удалений

Просмотреть файл

@ -31,5 +31,30 @@ namespace Microsoft.Azure.DevOps.ClientSamples.Work
return board;
}
[ClientSampleMethod]
public List<BacklogLevelConfiguration> GetBacklogs()
{
VssConnection connection = Context.Connection;
WorkHttpClient workClient = connection.GetClient<WorkHttpClient>();
TeamProjectReference project = ClientSampleHelpers.FindAnyProject(this.Context);
WebApiTeamRef team = ClientSampleHelpers.FindAnyTeam(this.Context, project.Id);
TeamContext teamContext = new TeamContext(project.Id, team.Id)
{
Team = team.Name,
Project = project.Name
};
List<BacklogLevelConfiguration> backlogs = workClient.GetBacklogsAsync(teamContext).Result;
foreach(var backlog in backlogs)
{
Context.Log("Backlog: '{0}' Type: '{1}'", backlog.Name, backlog.Type);
}
return backlogs;
}
}
}