Dashboard programming interface

Use the programming interface (API) of Performance Dashboard to query and display certain dashboard states:

The programming interface is realized through reading and writing methods of the global dashboard JavaScript object variable, which is globally defined in the start.jsp JSP page (or copies of which).

Reading methods

Writing methods

Example

If you copy the JSP file start_api.jsp to the webapp directory of your Performance Dashboard installation and run it in Internet Explorer, e.g., http://localhost:8080/APD_umg_en/start_api.jsp, you can familiarize yourself with the dashboard's programming interface after successful login.

Linked Picture File Template_support_manuals_APD

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"

"http://www.w3.org/TR/html4/loose.dtd">

<%

response.addHeader("Pragma", "no-cache");

response.addHeader("Cache-Control", "no-cache");

response.addHeader("Cache-Control","no-store" );

response.addDateHeader("Expires", 0);

%>

<html>

<head>

<title>ARIS Performance Dashboard</title>

<style type="text/css">

body {

margin-left: 0px; margin-right: 0px;

margin-top: 0px; margin-bottom: 0px;

background-color: #6D838E;

width:100%; height:100%;

}

</style>

<script type="text/javascript">

function invokeDashboard(pcdef, language, path,Line break

modelguid) {

var dashboardURL =Line break

"performancedashboard/PerformanceDashboard.html" +

"?pcdef=" + pcdef +

"&language=" + language +

"&path=" + path +

"&modelguid=" + modelguid;

document.getElementById("dashboardID").src =Line break

dashboardURL;

}

function getURLParameter(urlParam) {

var exp = "[\\?&]"+urlParam+"=([^&#]*)";

var regex = new RegExp(exp);

var myURL = window.location.href;

var values = regex.exec(myURL);

if(values == null) {

return "";

} else {

return values[1];

}

}

function getCurrentDashboard() {

dbname.value =Line break

dashboard.dashboard.getCurrentDashboard();

}

function setCurrentDashboard() {

dashboard.dashboard.setCurrentDashboard(Line break

document.getElementById("dbname").value,Line break

document.getElementById("path").value,Line break

document.getElementById("guid").value);

}

function getCurrentLevelPath() {

path.value =Line break

dashboard.dashboard.getCurrentLevelPath();

}

function setCurrentLevelByPath() {

dashboard.dashboard.setCurrentLevelByPath(Line break

document.getElementById("path").value);

}

function getCurrentLevelGUID() {

guid.value =Line break

dashboard.dashboard.getCurrentLevelGUID();

}

function setCurrentLevelByGUID() {

dashboard.dashboard.setCurrentLevelByGUID(Line break

document.getElementById("guid").value);

}

function getGlobalFilters() {Line break

gblfilterOut.value = Line break

dashboard.dashboard.getFilter(Line break

document.getElementById("gblfilterName").value);

}

</script>

</head>

<body onload="invokeDashboard(getURLParameter('pcdef'),Line break

getURLParameter('language'), getURLParameter('path'),Line break

getURLParameter('modelguid'))">

<div style="position:absolute; top:0px; z-index:2;Line break

width:100%;">

<table cellpadding="0" cellspacing="0" rules="none"Line break

frame="void" border="0" bgcolor="#C8CED0"Line break

width="100%" height="100%">

<tbody>

<tr><td width="100">&nbsp;Dashboard:</td>

<td width="430">

<input type="text" size="64" id="dbname"/>

</td>

<td>

<button id="b1"Line break

onclick="getCurrentDashboard()">Get</button>

<button id="b11"Line break

onclick="setCurrentDashboard()">Set</button>

</td>

</tr>

<tr><td width="100">&nbsp;Path:</td>

<td width="430">

<input type="text" size="64" id="path"/>

</td>

<td>

<button id="b2"Line break

onclick="getCurrentLevelPath()">Get</button>

<button id="b21"Line break

onclick="setCurrentLevelByPath()">Set</button>

</td>

</tr>

<tr><td width="100">&nbsp;GUID:</td>

<td width="430">

<input type="text" size="64" id="guid"/>

</td>

<td>

<button id="b3"Line break

onclick="getCurrentLevelGUID()">Get</button>

<button id="b31"Line break

onclick="setCurrentLevelByGUID()">Set</button>

</td>

</tr>

<tr>

<td width="130">

&nbsp;Global Filter:

</td>

<td width="800">

&nbsp;Dimension

<input type="text" size="16"Line break

id="gblfilterName"/>

<input type="text" size="85"Line break

id="gblfilterOut"/>

</td>

<td>

<button id="b4"Line break

onclick="getGlobalFilters()">Get</button>

</td>

</tr>

</tbody>

</table>

</div>

<div style="position:absolute; top:787px; z-index:2;Line break

width:100%;">

<iframe

name="dashboard" id="dashboardID" src=""

scrolling="no" marginheight="0" marginwidth="0"

frameborder="0"

style="

position: absolute;

bottom: 0px;

width: 100%

height: 690px;

background-color: #6D838E;

">

<p>Performance Dashboard</p>

</iframe>

</div>

</body>

</html>

You can use this little example to easily create complete dashboard URLS.