<< Click to Display Table of Contents >>

Running Viewer - HTML5SVG Viewer

Set the OZ Scheduler and OZ Server to be able to interact with the HTML5SVG Viewer and then copy the viewer installation files to a folder on the web server. And add viewer parameters in a web page to run the Viewer.

Set the OZ Scheduler

Confirm the following options are set to html5manager.properties file that is located in the conf folder of OZ Scheduler.(Description of these options, please refer to the OZ Scheduler Administrator's Guide.)

RepositoryFileRootPath=%SCH_HOME%/Html5ManagerRepository

DeleteFileTime=20

Set the path of html5manager.properties file in the ozscheduler.properties file that is located in the conf folder of OZ Scheduler.

...

path.html5manager.file=%SCH_HOME%/conf/html5manager.properties

Confirm that json-simple-1.1.1.jar file is located in the lib folder of OZ Scheduler. Set the path of the json-simple-1.1.1.jar file in the scheduler.bat file that is located in the bin folder of OZ Scheduler.

...

set OZSchLib=%OZSchLib%;%OZSCHEDULER_HOME%\lib\json-simple-1.1.1.jar

echo Loading OZScheduler...

...

Restart the server OZ Scheduler, after completing all the settings.

Set the OZ Server

Set the information of OZ Scheduler in the html5manager.properties file that is located in the conf folder of OZ Server. To improve the speed when binding large reports, please set multiple OZ Scheduler using an alias.

sch1.html5manager_ip=The first OZ Scheduler IP

sch1.html5manager_port=The first OZ Scheduler port number

sch2.html5manager_ip=The second OZ Scheduler IP

sch2.html5manager_port=The second OZ Scheduler port number

...

If you want to use the session key, set the following option in the spmgr.properties file that is located in the conf folder of OZ Server.(Description of these options, please refer to the OZ Enterprise Server Administrator's Guide.)

...

svgviewerbind_sessionkey=Session key

Set the path of html5manager.properties file in the ozserver.properties file that is located in the classes folder of OZ Server.

...

path.html5manager.properties.file=%OZ_HOME%/conf/html5manager.properties

Restart the server WAS associated with OZ Server, after completing all the settings.

Copy the viewer installation files to a folder on the web server

Copy the viewer installation files to a folder on the web server.

Add viewer parameters to run Viewer and to bind report

Declare a Web page in HTML5 format to run the HTML5SVG Viewer.

Next, set the path of Viewer installation files, Viewer ID, OZ Server information, report name, etc.

<!DOCTYPE html>

<html style="height:100%">

<head>

<meta http-equiv="X-UA-Compatible" content="IE=edge" />

<script src="http://code.jquery.com/jquery-2.0.3.min.js"></script>

<link rel="stylesheet" href="http://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css" type="text/css"/>

<script src="http://code.jquery.com/ui/1.12.1/jquery-ui.min.js"></script>

<link rel="stylesheet" href="http://127.0.0.1:8080/ozrviewer/ui.dynatree.css" type="text/css"/>

<script type="text/javascript" src="http://127.0.0.1:8080/ozrviewer/jquery.dynatree.js" charset="utf-8"></script>

<script type="text/javascript" src="http://127.0.0.1:8080/ozrviewer/OZJSSVGViewer.js" charset="utf-8"></script>

</head>

<body style="width:98%;height:98%">

<div id="OZViewer" style="width:98%;height:98%"></div>

<script type="text/javascript">

   function SetOZParamters_OZViewer() {

       var oz;

       oz = document.getElementById("OZViewer");

       oz.sendToActionScript("connection.servlet", "http://127.0.0.1:8080/oz/server");

       oz.sendToActionScript("connection.reportname", "category_path/sample.ozr");

       return true;

   }

   start_ozjs("OZViewer", "http://127.0.0.1:8080/ozrviewer/", true);

</script>

</body>

</html>

Using script src tag, set jquery-2.0.3.min.js, jquery-ui.min.js, jquery.dynatree.js, OZJSSVGViewer.js path. And using link rel tag, set jquery-ui.css, ui.dynatree.css path. And using div tag, set viewer id, width/height of viewer window.

getElementById function sets viewer id, SetOZParamters_ViewerID function sets connection.servlet to OZ server path and connection.reportname to the path and name of a report to bind. start_ozjs function runs viewer.

Run Viewer

Run the web page and check if the report has been bound.

To execute HTML5SVG Viewer in Mobile UI, please write web page as below.

<!DOCTYPE html>

<html style="height:100%">

<head>

<meta http-equiv="X-UA-Compatible" content="IE=edge" />

<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>

<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=no"/>

<script src="http://code.jquery.com/jquery-2.0.3.min.js"></script>

<link rel="stylesheet" href="http://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css"/>

<script src="http://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>

<link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css"/>

<script src="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.js"></script>

<link rel="stylesheet" type="text/css" href="http://dev.jtsage.com/cdn/simpledialog/latest/jquery.mobile.simpledialog.min.css"/>

<script type="text/javascript" src="http://dev.jtsage.com/cdn/simpledialog/latest/jquery.mobile.simpledialog2.min.js"></script>

<link rel="stylesheet" href="http://127.0.0.1:8080/ozrviewer/ui.dynatree.css" type="text/css"/>

<script type="text/javascript" src="http://127.0.0.1:8080/ozrviewer/jquery.dynatree.js" charset="utf-8"></script>

<script type="text/javascript" src="http://127.0.0.1:8080/ozrviewer/OZJSSVGViewer.js" charset="utf-8"></script>

<script src="http://127.0.0.1:8080/ozrviewer/jquery.mouseSwipe.js" type="text/javascript"></script>

</head>

<body style="height:100%">

<div id="OZViewer" style="width:100%;height:100%;overflow:hidden"></div>

<script type="text/javascript">

   function SetOZParamters_OZViewer() {

       var oz;

       oz = document.getElementById("OZViewer");

       oz.sendToActionScript("connection.servlet", "http://127.0.0.1:8080/oz/server");

       oz.sendToActionScript("connection.reportname", "category_path/sample.ozr");

       return true;

   }

   start_ozjs("OZViewer", "http://127.0.0.1:8080/ozrviewer/", true);

</script>

</body>

</html>