Like what you see? Have a play with our trial version.

Sub Tab

A SubTab is a child of a Dashboard and is used as a container for content on a Dashboard. The SubTab objects contain the name and uuid of the SubTab, as well as information about which reports are placed on that SubTab. 

Property Reference

name

Returns

String.

Description

Returns the display name of the SubTab, as it would be seen in the Yellowfin UI.


uuid

Returns

String

Description

Returns the UUID of the SubTab. 



Function Reference

isCanvas()

Returns

Boolean

Description

Returns true if this SubTab is a canvas tab.


getReports()

Returns 

Array[Object]

Description

Returns the ReportUUIDs and EntityUUIDs of every report that is present on this SubTab.

If there are no reports on this SubTab, an empty array will be returned. 

Examples

This function can be used to search for all instances of a particular report that might be on the dashboard. 

let reportToFind = 'af67e527-81d3-47fc-81ce-dfc506a61dd2';
let dashboardReports = dashboard.getAllReports();
let dashboardReport= dashboardReports.find(reportInfo => {
          return reportInfo.reportUUID ===  reportToFind;
});

if(dashboardReport) {
         //We found that report now we can load the report object. If the report has already been loaded by the dashboard this will just give us that version of the report
         dashboard.loadReport({
                  reportId: reportInfo.reportUUID,
                  entityUUID: reportInfo.entityUUID
         }).then(report => {
                  //Now we've fetched the report.
         });
}




Event Reference

There are no events that the SubTab triggers.




  • No labels