Class: Dashboard

Dashboard()

new Dashboard()

Methods

changeParameters(parameterInfo)

Changes dashboard parameter values. If you call this method with parameterInfo, the API will change the dashboard parameter values.
Parameters:
Name Type Description
parameterInfo Array [ { pname: String. The parameter name. pvalue: Array. The parameter value. For most parameter type pvalue only has one element, but the multiValue parameter may have several elements. ownerID: Array. The dashboard ID or library component ID which contains the current parameter. } ... ]

exportTo()

Exports the current dashboard with Logi Report built-in Export dialog.

getDashboardApp() → {Object}

Returns the DashboardApp instance this element belongs to.
Returns:
com.jinfonet.api.DashboardApp
Type
Object

getID() → {String}

Returns the ID of this dashboard.
Returns:
The instance name.
Type
String

getName() → {String}

Returns the display name of this dashboard element.
Returns:
The display name.
Type
String

getParameterInfo(callBack)

Gets all parameters information in the current dashboard. If you call this method with callback function, the API will return all parameters information in the callback function.
Parameters:
Name Type Description
callBack function Here is an example of how to get parameter information in the callBack function: var callback = function(msg){ var parameterInfo = msg.result.parameterInfo // Gets parameter information. ... }

getType() → {String}

Returns the object type of this dashboard.
Returns:
The object type.
Type
String

paramDialog()

Pops up the parameters dialog. If you call this method without any parameters, the API will pop up Logi Report built-in parameters dialog.

print()

Prints the current dashboard with Logi Report built-in dialog.

refresh()

Refreshes the dashboard data.

save()

Saves the dashboard.

saveAs()

Saves the dashboard with or without Logi Report built-in Save As dialog. options : {savePath:"/SampleReports/Dashboard - Coffee Sales.dsh"} If no "options" or "options" does not contain savePath, the Save As dialog will pop up. callback: An optional JavaScript function. After saving the dashboard, callcack will receive result data by parameter. like: function(result){...} result: A JavaScript object. result.err: A number which could be one of the following: 0 : The dashboard is saved successfully. 1 : The saving of the dashboard is cancelled by the user with dialog. 2 : The dashboard is failed to save. result.msg: The result message. result.data: A JavaScript object when saving the dashboard successfully. result.data.savePath: Saves the dashboard to the resource path.