laitimes

Table rendering is ever-changing, and this article takes you through it

author:Yonghong Technology

The function to be explained today is the table rendering function in Yonghong Desktop, which can more graphically describe the size of the data through various forms such as histograms and the number of charts.

Table rendering is ever-changing, and this article takes you through it

Table rendering

Note: Only table rendering can be performed on data of numeric types, and this property applies only to tables, crosstabs, and freestyle tables.

There are three types of table rendering: dynamic rendering, user-defined rendering, and product-predefined rendering. The predefined renderings include column rendering, positive and negative column rendering, shape rendering, positive and negative shape rendering, picture rendering, slash rendering, traffic light rendering, and up-and-down rendering.

Table rendering in the table (simple table) scope is a column (excluding the list header), in a crosstab the scope of table rendering is a row header, a list header, and a data area, and a free-form table is set on a cell, which can be in tabular form or crosstab form.

Table rendering is ever-changing, and this article takes you through it

Simple table form & cross table form rendering

01 How to use

Now that you know how table rendering is used and the basic types, how do you use it? Listen to me one by one, starting with setting up table rendering and exiting table rendering.

1. Set the table rendering

Select the scope for table rendering on a table, crosstab, or freestyle table and click Format - Table Rendering in the right panel.

Table rendering is ever-changing, and this article takes you through it

2. Exit table rendering

Select Table Rendering in the right panel Format and No Rendering in the Table Rendering dialog box, and the corresponding area in the table exits table rendering mode. As shown in the following figure:

Table rendering is ever-changing, and this article takes you through it

02Introduction to rendering types

So how to use the column rendering, positive and negative column rendering, these babbling renderings? You look down~

Suppose the data in a data source is as follows:

Table rendering is ever-changing, and this article takes you through it

Cylindrical rendering

Select Column Rendering in the Table Rendering dialog box to set the maximum value (when Auto is checked, the maximum value is to set the maximum value of all data in the render column, and the maximum value needs to be entered manually when not checked), the display value and the separation label, the script is grayed out, and the input of the script is not supported.

In column rendering, positive and negative column rendering, shape rendering and positive and negative shape rendering are supported in the function of displaying values, the function of displaying values can be configured in the property through render.value.calc.rows, if not configured, the length of the characters will be calculated, up to 1000, up to half of the grid.

Table rendering is ever-changing, and this article takes you through it

When you perform the preceding operations on this data source, the effect is as follows:

Table rendering is ever-changing, and this article takes you through it

Positive and negative cylindrical rendering

Select Positive and Negative Column Rendering in the Table Rendering dialog box, and set properties including maximum value (maximum value when Auto is checked to set the maximum value of all data in the render column, manually enter the maximum value when not checked), display value, separation label, negative number color, column color, target value, target line style, target line color. The script is grayed out, script input is not supported, and positive and negative column rendering supports adding target lines.

The maximum value is the maximum value after the absolute value of the data in the table, for example, if the maximum value is 100, the positive data in the table is greater than 100, the data is treated as 100, and when the negative data in the table is less than -100, the data is treated as -100; the target value is the value of the position of the target line on the axis; the target line style and the target line color are set for the style and color of the target line, respectively; the negative number color is the color of the column drawn when the value in the table is negative.

Table rendering is ever-changing, and this article takes you through it

When the above operation is performed on this data source, the effect is as follows: the size of the positive data is described by the length of the light gray bar, the size of the negative data is described by the length of the red bar, and the yellow thin line is the target value set, the effect is as follows:

Table rendering is ever-changing, and this article takes you through it

Shape rendering

Shape rendering only supports positive numbers, and the number of shapes is determined based on numerical values. If the data has decimals, the five-pointed star is displayed proportionally, such as 2.5, two and a half five-pointed stars are displayed.

Now only pentagrams are supported as shapes. Users can change the color of the five-pointed star by setting the background color in the local format, and control the number of five-pointed stars by calculating the unit. If the current data is 2000 and the unit of calculation is 200, the number of pentagrams displayed is the data obtained by dividing the current data by the unit of calculation, and 10 pentagrams should be displayed.

Table rendering is ever-changing, and this article takes you through it
Table rendering is ever-changing, and this article takes you through it

Positive and negative shape rendering

Positive and negative shape rendering supports positive and negative numbers, and the number of shapes is determined according to the numerical value. If the data has decimals, the five-pointed star is displayed proportionally, such as 2.5, two and a half five-pointed stars are displayed. Now only pentagrams are supported as shapes. Change the color of the pentagram by setting the background color in the local format, set the negative color to set the color of the negative pentagram, and the unit of calculation. If the current data is 2000 and the unit of calculation is 200, the number of five-pointed stars displayed is the data obtained by dividing the current data by the unit of calculation, and 10 five-pointed stars should be displayed.

Table rendering is ever-changing, and this article takes you through it
Table rendering is ever-changing, and this article takes you through it

Picture rendering

If the data in the query is the address of the image, and after binding the data in the dashboard, select image rendering, the image will be displayed in the current table. The data in the query is the address of each image, as shown in the following figure:

Table rendering is ever-changing, and this article takes you through it

Image rendering is used in the American column and the columbia column, respectively, as shown below. When the user checks the zoom option, the chart is displayed according to the scale of the grid, and when zoom is not checked, the picture is displayed according to the original scale.

Table rendering is ever-changing, and this article takes you through it

After the image is rendered, it is shown in the following figure:

Table rendering is ever-changing, and this article takes you through it

Slash rendering

This rendering method is more meaningful in the header of the crosstab, the user selects the junction area of the first row of the first column of the crosstab, right-clicks to select the table rendering, and selects the rendering format as slash rendering, as shown in the following figure:

Table rendering is ever-changing, and this article takes you through it

【Table header content (,split)】The content of the table header is split by the English format ",".

【Start from upper left point】 The starting point of the slash line is the upper left point of the table when checked, and the lower right point when not checked.

Note that when the content contains Chinese, the user needs to set the font type in the table, which is generally set to Song font.

After clicking the OK button, the effect is as follows.

Table rendering is ever-changing, and this article takes you through it

Traffic lights render

Select Traffic Light Rendering in the Table Rendering dialog box, support display values, start value, and end value, show red light checks when greater than the end value, and support custom settings for red, yellow, and green light pictures. Scripts are grayed out and input to scripts is not supported.

Checking display value indicates that the value of the data will be displayed at the same time after setting the rendering, otherwise only the rendering is displayed, not the value; the start value and the end value divide the data into three segments, one is the data that is less than the starting point value, the second is the data that is greater than or equal to the starting point value is less than or equal to the end value, and the third is the data that is greater than the end value.

Table rendering is ever-changing, and this article takes you through it

For example, if the data with IDs 1 to 15 starts with a value of 5 and an end value of 10, check the options Show value and Show red light when greater than the end value, as shown in the following figure:

Table rendering is ever-changing, and this article takes you through it
Table rendering is ever-changing, and this article takes you through it

Users can also set the picture rendered by the traffic light as needed. Here's how:

Select the image of the red, yellow, or green light under Traffic Light Rendering in the Table Rendering dialog and click the image editor to pop up, as shown in the following figure:

Table rendering is ever-changing, and this article takes you through it

On the picture list, the user can select a picture according to their needs. You can also click Import Image to set the image to a traffic light rendered image after importing it.

Up and down rendering

Select up and down rendering in the table rendering dialog box, support the input of display values, compare values, and support custom settings for rising and falling pictures. Scripts are grayed out and input to scripts is not supported.

Checking display value indicates that the value of the data after rendering is set will be displayed at the same time, if not checked, only the rendering will be displayed, not the value; the comparison value indicates the reference standard for rising and falling. Data that is less than the comparison value shows a decline, and data that is greater than or equal to the comparison value shows a rise.

For example, if you set the comparison value to 5 for data with IDs 1 to 15 and select the Show value option, the configuration is as shown in the following figure:

Table rendering is ever-changing, and this article takes you through it

When the above operation is performed on this data source, the effect is shown in the following figure: that is, values less than 5 are displayed as falling, and values greater than or equal to 5 are displayed as rising.

Table rendering is ever-changing, and this article takes you through it

The color of the arrow rendered by the up and down will change according to the locale, the commonly used in China is the red arrow up, the green arrow falls, when switching to other locales, change to green arrow up, red arrow down.

Table rendering is ever-changing, and this article takes you through it

Users can also set the picture of the ups and downs rendered as needed. The operation is the same as traffic light rendering.

Dynamic rendering & custom rendering

Some friends may ask, in addition to these renderings built into Yonghong, can we write scripts to customize the rendering types ourselves? The answer is yes! You read on!

Dynamic rendering

Dynamic rendering refers to the purpose of table rendering by writing scripts. When the user selects dynamic rendering, the script in the table dialog box is activated, where the user can write the script.

Table rendering is ever-changing, and this article takes you through it

The user can return the picture through the script, and there are two ways to return the picture, one is the user to build the chart, and the other is to refer to the existing picture through the URL.

Table rendering is ever-changing, and this article takes you through it

When referencing an image through a URL, the user can refer to a local image or a picture on the web. As shown in the following figure, refer to the local image, note that you need to add file:/// in front of the path.

Table rendering is ever-changing, and this article takes you through it

The following illustration refers to a picture on the network.

Custom rendering

If a user creates a renders .xml file in the bihome, the user-defined table rendering is displayed under the custom folder in the table rendering dialog.

Table rendering is ever-changing, and this article takes you through it

The format of the custom render render .xml is:

Table rendering is ever-changing, and this article takes you through it

Render file is only a configuration file, open the interface of the setting item, the user needs to write the corresponding java file, call the product's custom interface, compile into a class file, put in the specified location, the specific method can contact the custom development; finally also need to add the path of the previous class file to the "tomcat\bin\setclass.bat", placed in the "set CLASSPATH=%CLASSPATH%;"; "Later, it will take effect after restarting the product.

Table rendering support parameters

Our table rendering is powerful and can also support association with custom parameters and parameter components~

In the table rendering dialog, the use of parameters or parameter components is supported where the specific values are set, as shown in the following figure: the maximum value and target value of the column rendering can be selected by the drop-down box:

Table rendering is ever-changing, and this article takes you through it

After a table rendering uses a parameter or parameter component, the value of the parameter changes and the value of the parameter component is switched to refresh the rendering effect with the latest parameter value.

Note: The data type of the parameters used in the table rendering dialog must be Numeric.

Read on