Connecting Custom JS-Function to Report

A custom JS-function can be called from a report in the Dashboards and Reports tools. The custom function signature is specified in the Hyperlink section.

To call a custom JS-function in the report:

  1. Add a custom JS-function into the main tool file. A detailed description is given below.

  2. Set up custom JS-function call. The setup depends on the tool in use:

  3. Save the report.

Adding Custom JS-Function to Main Tool File

The main tool file for the Dashboards tool is dashboard.html, the main tool file for the Reports tool is reporter.html. The files are located in the App folder with installed Foresight Analytics Platform web application.

A custom JS-function can be added as a single file or inserted into the main tool file. Consider adding the myFunc() function.

function myFunc() {
   alert("Example of calling custom JS-function from file");
}
<script src="Func.js" type="text/javascript"></script>
<script type="text/javascript">
function myFunc() {
alert("Example of calling custom JS-function");
}
</script>

See also:

Questions and Answers | Dashboards: Button Commands Control | Table Visualizer: Actions on Opening Hyperlink | Table Cell: Hyperlink Action