Вы можете custom dashboard widget (VSTS extension) с помощью REST API, чтобы показать результат, который вы хотите.
Простой пример (показать ребенку WorkItems кол-запрос):
<!DOCTYPE html>
<html>
<head>
<title>Custom widget</title>
<meta charset="utf-8" />
<script src="node_modules/vss-web-extension-sdk/lib/VSS.SDK.js"></script>
<script type="text/javascript">
VSS.init({
explicitNotifyLoaded: true,
usePlatformStyles:true
});
VSS.require(["TFS/Dashboards/WidgetHelpers", "TFS/TestManagement/RestClient", "TFS/WorkItemTracking/RestClient", "TFS/Build/RestClient"], function (WidgetHelpers, TFS_Test_WebApi, TFS_Work_WebApi,TFS_Build_Client) {
WidgetHelpers.IncludeWidgetStyles();
VSS.register("WidgetStarain", function() {
var projectId = VSS.getWebContext().project.id;
var runQuery = function (widgetSettings) {
TFS_Work_WebApi.getClient().queryById('7633dab2-89e4-4da9-b03d-a16728ab71c5', projectId)
.then(function (workitemResult) {
var ss = "gg";
ss = workitemResult.workItemRelations[0].target.url;
var resultCount = workitemResult.workItemRelations.length;
$('div.childWorkItemCount').text(resultCount-1);
})
}
return {
load: function (widgetSettings) {
var $title = $('h2.title');
$title.text('starain widget custom');
runQuery(widgetSettings);
return WidgetHelpers.WidgetStatusHelper.Success();
}
}
});
VSS.notifyLoadSucceeded();
});
</script>
</head>
<body>
<div class="widget">
<h2 class="title">widgets sample</h2>
<div class="childWorkItemCount">-1</div>
</div>
</body>
</html>
часть кода в файле .Json:
{
"id": "WidgetStarain",
"type": "ms.vss-dashboards-web.widget",
"targets": [ "ms.vss-dashboards-web.widget-catalog" ],
"properties": {
"name": "widget starain",
"description": "custom widget",
"catelogIconUrl": "Images/iconProperty.png",
"previewImageUrl": "Images/iconProperty.png",
"uri": "WidgetStarain.html",
"supportedSizes": [
{
"rowSpan": 1,
"columnSpan": 2
}
],
"supportedScopes": [ "project_team" ]
}
}