!!!###!!!title=PivotTable-columns-link——VisActor/VTable option documents!!!###!!!!!!###!!!description=VisActor/VTable option documents. This chapter mainly introduces VTable configuration items and their usage to quickly generate the required tables.!!!###!!!

PivotTable-columns-link.headerType = 'link'

Specify the column type as 'link', headerType can be omitted and defaults to 'text'

PivotTable-columns-link.dimensionKey

string

Required Unique identifier of the dimension, corresponding to the field name of the dataset

PivotTable-columns-link.title

string

Required Dimension name, the angle header can be configured to display the dimension name

PivotTable-columns-link.headerFormat

FieldFormat

Format of the dimension value

type FieldFormat = (title: number|string, col:number, row:number, table:PivotTable) => any;

PivotTable-columns-link.width

number
string

This property takes effect when the dimension serves as a row header and represents the width of the dimension cell. The column width can be specified as a specific number, 'auto', or a percentage like '20%'. If 'auto' is specified, the column width will be adjusted automatically according to the length of the whole column text; If a percentage is specified, the current column width will be adjusted according to the total width of the table;

PivotTable-columns-link.maxWidth

number
string

This property takes effect when the dimension serves as a row header and represents the maximum width of the dimension cell

PivotTable-columns-link.minWidth

number
string

This property takes effect when the dimension serves as a row header and represents the minimum width of the dimension cell

PivotTable-columns-link.headerStyle

IStyleOption
Function

Header cell style, type declaration:

headerStyle?: IStyleOption | ((styleArg: StylePropertyFunctionArg) => ITextStyleOption);

The type declaration for the callback function argument StylePropertyFunctionArg is as follows:

interface StylePropertyFunctionArg {
  row: number;
  col: number;
  /** Table instance */
  table: TableAPI;
  /** If format exists, the formatted or calculated value */
  value: string;
  /** Original value */
  dataValue: string;
  /** Specific to ProgressBarType, represents the proportion of the current value in the overall data range */
  percentile?: number;
  /** Path information of cell header */
  cellHeaderPaths: ICellHeaderPaths;
}

IStyleOption type structure is as follows:

Click to expand

PivotTable-columns-link.headerIcon

string
Object
Array
Function

Header cell icon configuration

  headerIcon?:
    | string
    | ColumnIconOption
    | (string | ColumnIconOption)[]
    | ((args: CellInfo) => string | ColumnIconOption | (string | ColumnIconOption)[]);

ColumnIconOption specific configuration: https://visactor.io/vtable/option/ListTable-columns-text#icon

PivotTable-columns-link.description

string
Function

Description information for header hover, displayed as a tooltip

 description?: string | ((args: CellInfo) => string);

PivotTable-columns-link.cornerDescription

string

Description information for hover, displayed as a tooltip

PivotTable-columns-link.headerCustomRender

Function
Object

Custom rendering function for header cells, you can specify the rendering method for headers. For details, please refer to Basic table custom rendering configuration

PivotTable-columns-link.headerCustomLayout

Function

Custom layout element definition for header cells, this customization is suitable for cells with complex content layouts.

(args: CustomRenderFunctionArg) => ICustomLayoutObj;

The type declaration for callback function argument CustomRenderFunctionArg is:

interface CustomRenderFunctionArg {
  row: number;
  col: number;
  table: TableAPI;
  /**Formatted value */
  value: string|number;
  /**Original value */
  dataValue: string|number;
  rect?: RectProps;
}

The ICustomLayoutObj type is defined as follows

export type ICustomLayoutObj = {
  rootContainer: Container | any;
  /**
   * Do you still need to render content by default? Only if the configuration is true, it will be drawn. By default, it will not be drawn.
   */
  renderDefault?: boolean;
  /**
   * Whether to also enable padding in style
   */
  enableCellPadding?: boolean;
};

Detailed configuration instructions are as follows:

Click to expand

PivotTable-columns-link.dropDownMenu

Array

Dropdown menu item configuration. Dropdown menu items can be top-level menu items or second-level menu items, and only one configuration is required. The specific type is MenuListItem[].

PivotTable-columns-link.cornerDropDownMenu

Array

Angle header cell display drop-down button and drop-down menu item configuration. Dropdown menu items can be top-level menu items or second-level menu items, and only one configuration is required. The specific type is MenuListItem[].

PivotTable-columns-link.cornerHeaderIcon

string
Object
Array
Function

Pivot table corner cell icon configuration

cornerHeaderIcon?:
| string
| ColumnIconOption
| (string | ColumnIconOption)[]
| ((args: CellInfo) => string | ColumnIconOption | (string | ColumnIconOption)[]);

For the specific configuration of ColumnIconOption, please refer to: https://visactor.io/vtable/option/ListTable-columns-text#icon

PivotTable-columns-link.dragHeader

boolean

Whether the header can be dragged

PivotTable-columns-link.drillDown

boolean

Display drill-down icon, clicking it will trigger a corresponding event

PivotTable-columns-link.drillUp

boolean

Display drill-up icon, clicking it will trigger a corresponding event

PivotTable-columns-link.showSort

boolean

Whether the dimension value cell displays the sort icon. Clicking it does not have data sorting logic.

PivotTable-columns-link.sort

boolean

Whether the corresponding dimension header cell displays the sort icon.

Sorting rules:

If the sorting rules for this dimension are configured in dataConfig.sortRules, the data is sorted according to the rules in dataConfig.sortRules.

If the sorting rules for the dimension are not configured in dataConfig.sortRules, the default is to use the natural sorting of the dimension value string.

PivotTable-columns-link.showSortInCorner

boolean

Whether to display sorting in the dimension name cell in the corner header. Clicking it does not have data sorting logic

PivotTable-columns-link.linkJump = true

Link type exclusive configuration item Whether the link is clickable and can be redirected

PivotTable-columns-link.linkDetect = true

Link type exclusive configuration item Whether the link undetrrgoes regular expression detection, and only if the link complies with the URL rules it will be displayed as a link. This configuration does not take effect if a template link is configured.

PivotTable-columns-link.templateLink

string

Link type exclusive configuration item Template link address, such as: 'https://www.google.com.hk/search?q={name}', where name is the data source attribute field name.

PivotTable-columns-link.linkTarget

string

link type exclusive configuration item Specifying the name of the browsing context the resource is being loaded into, is the second parameter of window.open(), and defaults to '_blank'.

PivotTable-columns-link.linkWindowFeatures

string

link type exclusive configuration item A string containing a comma-separated list of window features, which is the third parameter of window.open().