创建我自己的VSTS扩展,返回一个Grid,其中包含使用wiql读取的错误列表。
我希望(UI控件)网格包含错误标题和超链接到错误网址,以便可以点击标题跳转到错误。我找不到任何可能做到这一点,但我不相信这是不可能的。
这就是我在网格中构建源代码的方式:
D/UploadService: UploadRequest - null or empty upload ID. Generating it
D/UploadService: UploadRequest - Created new upload request to http://124.109.32.137:8080/NACTA/REST/Communicator/FileUpload with ID: 1034ab15-a10c-41c6-8f36-5697b4dffb81
D/UploadService: MultipartUploadRequest - Auto-detected MIME type for content://com.android.providers.media.documents/document/video%3A146 is: video/mp4
D/UploadService: MultipartUploadRequest - Using original file name: VID_20171216_223940.mp4
I/UploadService: UploadService - Starting service with namespace: com.es.tatheer, upload pool size: 2, 5s idle thread keep alive time. Foreground execution is enabled
D/UploadService: UploadService - Successfully created new task with class: net.gotev.uploadservice.MultipartUploadTask
D/UploadService: FileUploader - Starting upload task with ID 1034ab15-a10c-41c6-8f36-5697b4dffb81
D/UploadService: MultipartUploadTask - 466841
D/UploadService: OkHttpStackConnection - creating new connection
D/UploadService: UploadTask - Broadcasting upload progress for 1034ab15-a10c-41c6-8f36-5697b4dffb81: 103 bytes of 468370
D/UploadService: UploadTask - Broadcasting upload progress for 1034ab15-a10c-41c6-8f36-5697b4dffb81: 361928 bytes of 468370
D/UploadService: MultipartUploadTask - 468323
D/UploadService: UploadTask - Broadcasting upload progress for 1034ab15-a10c-41c6-8f36-5697b4dffb81: 468370 bytes of 468370
D/UploadService: FileUploader - Server responded with HTTP 200 to upload with ID: 1034ab15-a10c-41c6-8f36-5697b4dffb81
D/UploadService: UploadTask - Broadcasting upload completed for 1034ab15-a10c-41c6-8f36-5697b4dffb81
D/UploadService: UploadService - All tasks completed, stopping foreground execution
I/UploadService: UploadService - Service will be shut down in 10000ms if no new tasks are received
D/UploadService: OkHttpStackConnection - closing connection
I/UploadService: UploadService - Service is about to be stopped because idle timeout of 10000ms has been reached
D/UploadService: UploadService - Stopping foreground execution
D/UploadService: UploadService - UploadService destroyed
后来:
var sourceArray = workItems.map(function (w) {
return [
w.id,
w.fields["System.Title"],
w.fields["System.State"],
w.fields["GrundfosScrum.gfSeverity"],
w.fields["GrundfosScrum.gfLikelihood"],
w.fields["System.AssignedTo"]];
});
我尝试将 var options = {
width: "100%",
height: "500px",
source: sourceArray,
columns: [
{ text: "ID", index: 0, width: 100, headerCss: "mystyle" },
{ text: "Title", index: 1, width: 200, headerCss: "mystyle" },
{ text: "State", index: 2, width: 100, headerCss: "mystyle" },
{ text: "Severity", index: 3, width: 200, headerCss: "mystyle" },
{ text: "Likelihood", index: 4, width: 200, headerCss: "mystyle" },
{ text: "Assigned To", index: 5, width: 300, headerCss: "mystyle" },
]
};
替换为w.fields["System.Title"]
,结果是表格中的html超链接而不是网格内的超链接。
有什么想法吗?
答案 0 :(得分:0)
网格中的添加链接不支持此功能。但您可以调用Open row details方法来实现所需的功能。获取URL信息并在触发CDate(Range("b9"))
方法时打开新窗口。
openRowDetail