Custom Reports

[Data Source: Voice Server, Engage, VCS, VMI] Specific custom created reports are viewed from this folder. Using Crystal Reports, you can customize your own reports for Vocera Analytics and add it to the Report Console.

To access the Vocera Analytics Server database, you must install Crystal Reports 2016 and the MySQL Connector/ODBC 3.51 driver on a computer other than the one on which the Vocera Analytics Server is installed. You must also set up an ODBC data source.

The information displayed on screen is determined by the filters that you apply. Sample filters included with this sample report are:

Table 1. Filters
Filter Name Filter Description
Date Range The date range to include in the results. By default, the value is the current date; however, you can select from a list of options. For example, you can select the option "Last 7 days" or "Last 30 days."
Facilities Used to filter data based on user facilities (common facility name) specified while mapping Vocera Voice Server User Site and Engage Facility.
Units Used to filter data based on user units (common unit name). Common unit names are referenced from a crosswalk table cwunit that are mapped from Vocera Voice Server User Department and Engage Units.
Note:

The displayed units drop-down filter may be constrained due to the Facilities filter.

Unknown Unit or Department display data for all users that are not part of any department selected within the Facilities filter.

To create a custom report, you must add your report as a menu item and create a report template file.

Adding your report as a menu item

  1. Open the custom-menu.json file from the following location: <Install Drive>\Path of Visualization Server folder\ conf\custom-menu.json.

    For example: C:\Analytics\visualizationserver\conf\custom-menu.json.

    Note: You must add the custom report so that it shows as a sub-menu inside the main menu of the report.
  2. Define your custom report as shown below:
    [{
    "menuId" : "custom_report",
    "name" : "Sample Custom Report",
    "reportId" : "sample_custom_report",
    "url" : "/sample_custom_report",
    "templateUrl":"report/report.tpl.html",
    "parent":"custom",
    "params" : {
    "templateFileName" : "samplecustomreport.rp.tpl",
    "description" : "This is the sample report which summarizes Outgoing Calls."
    },
    "items" : []
    }
    ]

The following table lists the menu item and its description:

Property Description
menuId An unique identifier for the menu.
name Name of the report that will be displayed under menu.
reportId An unique identifier for the report.
url An unique relative URL that would be displayed on the address bar of the browser.
templateUrl The templateUrl for reports is report/report.tpl.html. Refer the section for information on how to create a report template file.
parent Name of the parent menu.
params > template_file_name The name of the report template file created under conf\Report Template in Visualization Server.
params > description A short description of the report.

Creating a report template file

  1. Create a report template file in the following location: <Install Drive>\Path of Visualization Server folder\ conf\Report Templates

    For example: C:\Analytics\visualizationserver\conf\Report Templates

    Note: The .rpt file must be created/copied at C:\Analytics\reports.

    A report template file content is compiled into a report page in the Vocera Analytics Web console.

  2. Define your report template file as shown below:

    The name format for the report template file must be given as: <Report Name>.rpt.tpl)

    <va-report rpt-name="Outgoing Calls by Users - Summary">
     
        <va-report-container
            rpt-file="OutgoingCallsSummary.rpt"
            filter-params="fromTime|toTime|sites|units"/>
     
        <va-filter>
     
            <va-date-range-picker/>
     
            <va-dropdown name="sites" label="Facilities"
                        bind-name="Site_Clause"
                        table-name="cwfacility"
                        column-name="common_facility_id"
                        filter-data-source="cwfacilities"
                        header="All"
                        select-limit="10"
                        place-holder-text="Select Facilities"
                        multiple="true"/>
     
            <va-dropdown name="units" label="Units"
                        bind-name="Unit_Clause"
                        table-name="cwunit"
                        column-name="common_unit_id"
                        filter-data-source="cwunits"
                        filter-params="sites"
                        header="All"
                        select-limit="10"
                        place-holder-text="Select Units"
                        multiple="true"/>
     
        </va-filter>
     
    </va-report>

The following table lists the custom control name and its description:

Custom Control Name Description
va-report Container of the whole report page.
va-filter Container of filters used in the report template.
va-date-range-picker Date range picker. It automatically creates the key fromTime and toTime.
va-dropdown It is a drop-down control. It has the following parameters:
  • name: Name of the drop-down to be shown as a label.
  • bind-name: Parameter name in Crystal reports to which the value should map.
  • table-name: Table name to form the where clause.
  • column-name: Column Name to form the where clause.
  • filter-data-source: Relative path of rest api. The preceding forward slash is not required.
  • header: The value to be shown in the drop-down when nothing is selected. Specify it as "All."
  • select-limit: The maximum number of elements that can be used in the drop-down.
  • multiple: Set it to true if multi selection need to be enabled.
va-report-container Container of the Crystal report frame.
  • rpt-file: Name of the rpt file.
  • filter-params: List of parameters separated by a pipe (|) that the report depends on. The parameters fromTime and toTime keys are automatically created when va-date-range-picker is included in the template.

Filters used for Rest APIs

The following table lists the rest API and its description.

Rest API Description
/assets/test_resource/aboveBelow.json Filters data in Speech dashboards based on recognized percentage that can be above or below a certain threshold.
/assets/test_resource/addressBookTypes.json Filters data based on the address book type such as a person or a place.
/assets/test_resource/deviceType.json Filters data by device types such as Android, Badge, or iOS.
/assets/test_resource/incomingCallTypes.json Filters data based on incoming call type in Interruption dashboards.
/assets/test_resource/reasonsUnAnswered.json Filters data based on the reasons unanswered in Interruption dashboards.
/assets/test_resource/reportTypes.json Filters data by report type such as a dashboard or a report.
/cwfacilities Filter data by facilities from crosswalk table.
/cwunits Filters data by units from crosswalk table using facility as a parameter.
/deviceVersions Filters data by device version.
/deviceVersionsByType Filters data by device versions and using device type as a parameter.
/exceptionTypes Filters data based on exception types that might come in package scheduler.
/interruptTypes Filters data based on interrupt types such as alarms, alerts, calls, messages.
/locations Filters data based on the location within a facility using facility as a parameter.
/priorities Filters data by priority.
/searchGroups Filters data by groups using facility and a search string as parameters.
/searchUsers Filters data by users and takes facility, unit and a search string as parameters.
/sourceTypes Filters data by interruption source using interrupt type as parameter.
/usersByUnits Filters data by users using unit and a search string as parameters.
/vmiClients Filters data based on VMI client.