This section explains how to create a basic BIRT report that extracts information from Stages.
The new blank report will be opened on the right side.
var artifacts = pkit.getCurrentProject().getEntities("containsProcess@SYSTEM") [0].getEntities("containsArtifact@SYSTEM"); for (i = 0; i <artifacts.length; i++) { var artifacts_instances = artifacts[i].getEntities("containsInstance@SYSTEM"); for (j = 0; j <artifacts_instances.length; j++) { var artifacts_revisions = artifacts_instances[j].getEntities("containsRevision@SYSTEM"); if (artifacts_revisions.length == 0) { dataset.setColumnValue("State", "no version"); } else { dataset.setColumnValue("State", artifacts_revisions[0].getProperty("state")); } dataset.setColumnValue("DocumentName", artifacts_instances[j].getProperty("LogicalName")); dataset.storeResultRow(); } }
To finish the editing of the script, click OK.
Enter a Workspace Path in the text input field. The Workspace Path is the pipe separated path of workspace names in Stages. A report to be executed in the workspace Company –> Projects and Products –> System A –> Software Project A would need the Workspace Path to be set to Company|Projects and Products|System A|Software Project A.