DataHub uses report template code from its report template to create the layout and detail of a DHLink Summary report. You can find the report template file in <installation folder>/plugins/com.nomagic.datahub.magicdraw/data/templates/relation.html. You can edit the report template file with any text editors to add more information into the report template. In this scenario, you want to add another attribute into the report template.
The report template code inside the report template file and the construction of the report layout and data script.
To add another attribute into the report template and generate DHLink Summary report
- Open the template file located in <installation folder>/plugins/com.nomagic.datahub.magicdraw/data/templates/relation.html with any text editors.
Type the following code in the highlighted area of the report template code fragment to add more attributes into the report template file. For example, if you want to add the Created Thru attributes into the report template file to include them in the DHLink Summary report, you must replace <Attribute name> with Created Thru.
The code for adding another attribute in the report template file<br/>$DataHubReportEngine.decorateHTMLTag($row.sourceElement.entity.getAttributeValue("<Attribute name>"))
Note
The name of the attribute you want to add in the report template file must be the same as the one appears in the Cameo DataHub Properties tab.
The attribute name, e.g., Created Thru, in the DataHub Properties tab must match the <Attribute name> in the report template code.
Save the template file.
Open the DHLink Summary dialog in MagicDraw to generate the DHLink Summary report.