Parameter Controls
Parameters can participate in dashboard layout through parameter controls. Similar to filters, parameter controls can adjust parameter values, causing the charts in the dashboard to change and display different content.
Parameter controls are divided into local parameter controls and app parameter controls, with different control scopes. Local parameter controls only affect relevant charts within the current dashboard, while app parameter controls can affect relevant charts across all dashboards within the app.
Local Parameter Controls
Create Parameter Control
The following explains how to create a local parameter control.
Before using the parameter control, please refer to Parameter to create a new parameter.
In the dashboard, click
New Parameter Control
->Parameter Control
icon to add a parameter control to the dashboard.Select a parameter from the
Parameter
list on the left and drag it into the parameter configuration area. The dashboard will display a filter in the form of a parameter. Parameters can only be single-select because they can only have one current value.The parameter control supports modifying the default value of the parameter. Check the custom default value option to make changes.
Switch to the
Style
tab to set various styles for the parameter control.
After completing the above steps, the parameter control is successfully created. If adjusting the parameter value does not change the chart content, it may be because the chart is not associated with the parameter.
Parameter Association
Parameters need to be associated with charts in order to control chart content through parameter controls. The common association methods are as follows.
Association Before Chart Creation
Association before chart creation refers to the use of parameters in the dataset when creating a chart. If parameters are used during Dataset Creation, Row Permission Settings, Creating New Fields, or Creating New Metrics, then after the chart is created, it will already be associated with those parameters. Adjusting the parameter controls will cause the chart content to change accordingly.
Association When Creating Charts
If the dataset used to create the chart does not use parameters, you can associate the chart with parameters through in-chart filters during the chart creation process. As shown in the figure, in the filter for Call Start Time
, use a parameter expression for filtering, thereby associating the parameter chart. When the parameter control changes, the filter value changes, which in turn affects the chart display.
Parameter Control Types
Parameter control types include standard parameter controls, date range parameter controls, and tree parameter controls.
Standard Parameter Controls: These are suitable for text, date, and numeric types of parameter controls. Only one parameter can be dragged in at a time, and the chart data display is controlled by the parameter value.
Date Range Parameter Controls: These support dragging in two date parameters to form a date range value that controls the chart data display. Date range parameters are automatically validated to ensure that the value of the second parameter is greater than the value of the first parameter. As shown in the figure, the dashboard displays data between the
Start Date
andEnd Date
. By using the date range parameter control to drag in theStart Date
andEnd Date
parameters, the system automatically restricts theEnd Date
parameter so that it can only select values greater than or equal to theStart Date
.
- Tree Parameter Controls: These are suitable for scenarios where one control manages multiple parameters, and the parameters have hierarchical relationships. For example,
Company
containsDepartment
, andDepartment
containsEmployee
; orRegion
containsProvince
. This hierarchical structure makes it easier for users to locate specific options when selecting parameter controls.
Application Parameter Controls
The creation process of application parameter controls is the same as that of local parameter controls. The difference is that application parameter controls can only be placed at the top of the dashboard, added as a single small card in the permanently resident global parameter area at the top. The size is fixed and cannot be adjusted. The display style is relatively simple, not supporting tiled layouts, but it does allow customization of color, border, corner radius, text, etc.
Sidebar Parameter Controls
When the space within the dashboard canvas is tight, parameter controls can be moved to the sidebar. At this time, parameter controls do not support style modifications.
Sidebar parameter controls support moving within the canvas. In this case, you need to readjust the position and style of the controls within the canvas.
Tip
Both local parameter controls and app parameter controls support moving to the sidebar.
Parameter Control Association
When multiple parameters use different fields in the same dataset as dynamic allowed values, these parameters are interrelated. In the global settings, drag the parameter controls to establish a hierarchical relationship. When the parent option changes, the child options follow suit.
Tip
Association can only be established when the allowed values of the parameters are Dynamic List.
Application Scenarios for Parameter Controls
Parameter controls can be used to achieve the following scenarios.
Scenario 1
The parameter control can display field A while actually affecting field B. Parameters support configuring values and display values. In the Dynamic List, field B can be configured as the value, and field A can be configured as the display value. This way, the parameter control shows the display value (field A), while the actual filtering is based on the value (field B).
Scenario 2
A parameter control manages charts created from different datasets. Parameters can be flexibly associated with charts, making it easy to control charts created from different datasets.
Notes on Parameter Usage
The parameter control for the same parameter can only appear once in a dashboard. Therefore, when using parameter controls, please note:
- In the same app, the parameter control for the same parameter cannot simultaneously serve as both an app-level parameter control and a local parameter control.
- In the same dashboard, the parameter control for the same parameter cannot appear both in the dashboard and in a container.