How to display a formatted query result in a RTC dashboard External Content widget
Why is this functionality useful?
- You want to show the results of a cool query you have developed in a dashboard widget. You can show the extra work item attributes that you have included in the query results.
- You use the External Content widget to display only the HTML-formatted results of your query without the entire RTC page you normally get when showing a query using this same widget.
- This is great for showing formatted query results that have attribute displays that include HTML fields such as Description, Executive Summary, etc.
How do you do this?
Accepted answer
- Run your desired query
-
Click the 'View Full Result Set in Printable Format' button in the upper right corner (on the web client)
- This should open a new tab/window with it's own URL. Use that URL in your External Widget.
-
You'll get the same URL as suggested above but without having to manually create it!
3 other answers
- Run your query of choice from the Work Items pull down in your web browser then take a look at the browser’s address bar. You end up with an address similar to this:
- https://<server>:<port>/ccm/web/projects/<RtcProjectName>#action=com.ibm.team.workitem.runSavedQuery&id=_Rga6UChpEeOoTPLFnqdgog
- Find the UUID of the query: id=_Rga6UChpEeOoTPLFnqdgog
- Build the URL for the External Content widget
- Use this syntax: https://<server>:<port>/ccm/resource/itemOid/com.ibm.team.workitem.query.QueryDescriptor/<queryID>?_mediaType=text/html
- You end up with a new URL similar to this: https://jke.banking.com:9443/ccm/resource/itemOid/com.ibm.team.workitem.query.QueryDescriptor/_Rga6UChpEeOoTPLFnqdgog?_mediaType=text/html
- Add an External Content widget to a tab in your dashboard
-
Edit the widget by selecting the Settings option of the widget and paste the URL into the External URL field of the settings editor
- Click on OK
- You will see a nicely formatted, table-based display of your query results with the HTML-format that you used in the HTML fields, such as Description
How did I figure this out?
I was surfing the RTC project dashboard for how the development team uses it to communicate information and found a query results display that caught my eye. I reverse engineered the External Content widget from the RTC v4.0.5 project dashboard and found the solution to a problem that I had been trying to solve for a while now. While it lasts here is a link to the dashboard I used with the RTC 4.0.5 Feature Teams widget.
We can always count on the RTC development team to showcase cool dashboard widget features!
Comments
Ad,
Not that I can determine. That particular functionality, test case execution status decorator, is part of the OSLC integration and display in the RTC query results. The external content widget display is based on the View Full Result Set in Printable Format which only contains hyperlinks to the related artifacts, without any extra rich display of data. Furthermore, from the RTC query you cannot access any attributes from the linked test case so that is not an option either.
You could put the direct link to the query in the External Content widget, which would solve that display need but then you would be looking at the normal query results page, not the printable view.
Hope that helps.
Regards,
Jeff