Charting Module

The Charting Module implements the ability to display charts of a feature layer's data in HTML5 viewers. The data can be from the layer's fields or from a data link that is configured for the layer.

Chart example

Charts are configured in Manager. For more information on how to configure charts, see Charting.

It is also possible to display charts for a single feature. For more information, see FeatureDetails Module.

Configuration Properties

The Charting Module requires the Charting library as well as the Mapping.Charting library.

Module

Views

View Models

Example - Add a Command with a Parameter to a Behavior

The following example demonstrates adding a new command with a parameter to the behavior, ChartPointMouseHoverBeginBehavior.

To add a command with a parameter to a behavior:

  1. Run an XML editor or text editor as an administrator.

  2. Open one of the viewer configuration files, Desktop.json.js, Tablet.json.js, or Handheld.json.js, in the editor.

    By default, the configuration files are here:

    C:\Program Files (x86)\Latitude Geographics\Geocortex Essentials\[instance]\REST Elements\Sites\[site]\Viewers\[viewer]\VirtualDirectory\Resources\Config\Default\

  3. In the Charting module section, find the behaviors property. Locate the behavior you want to edit, for example, ChartPointMouseHoverBeginBehavior.

    {
        "moduleName": "Charting",
        ...
        "configuration": {
            ...
            "behaviors": [
                {   
                    "name": "ChartPointMouseHoverBeginBehavior",
                    "event": "ChartPointMouseHoverBeginEvent",                            
                    "commands": [
                        "ClearChartHighlights",
                        "HighlightChartFeatureSet"
                    ]
                },
                ...
            ]
        },
        ...
    }

    The behavior executes two commands: ClearChartHighlights and HighlightChartFeatureSet.

  4. Refer to Viewer Commands and Events to determine the type of parameter that is associated with these commands. While ClearChartHighlights does not have any parameter, HighlightChartFeatureSet has a parameter of type geocortex.essentialsHtmlViewer.mapping.infrastructure.FeatureSet.

  5. Find a command that you want to add to the behavior that has the same parameter type. For example, ZoomToFeatures.

  6. Add the desired command to the list of commands, separated by a comma. For example:

    "commands": [
        "ClearChartHighlights",
        "HighlightChartFeatureSet",
        "ZoomToFeatures"
    ]
  7. Save the file.

© 2019 Latitude Geographics Group Ltd. All Rights Reserved.

Documentation Version 4.11