Skip to content

Commit

Permalink
Merge pull request #627 from VisActor/622-demo-add-business-cases
Browse files Browse the repository at this point in the history
622 demo add business cases
  • Loading branch information
fangsmile authored Nov 28, 2023
2 parents 9284d99 + 293425c commit 69c76c2
Show file tree
Hide file tree
Showing 72 changed files with 1,951 additions and 526 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"comment": "refactor: sortState can not work when column has no sort setting #622\n\n",
"type": "none",
"packageName": "@visactor/vtable"
}
],
"packageName": "@visactor/vtable",
"email": "[email protected]"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"comment": "docs: add api getCellCheckboxState\n\n",
"type": "none",
"packageName": "@visactor/vtable"
}
],
"packageName": "@visactor/vtable",
"email": "[email protected]"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"comment": "fix: drag select first cell seleted repeatly #611\n\n",
"type": "none",
"packageName": "@visactor/vtable"
}
],
"packageName": "@visactor/vtable",
"email": "[email protected]"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"comment": "refactor: remove keydown event arguments cells\n\n",
"type": "none",
"packageName": "@visactor/vtable"
}
],
"packageName": "@visactor/vtable",
"email": "[email protected]"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"comment": "refactor: rename maneger to manager\n\n",
"type": "none",
"packageName": "@visactor/vtable"
}
],
"packageName": "@visactor/vtable",
"email": "[email protected]"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"comment": "fix: no indicators pivotchart render\n\n",
"type": "none",
"packageName": "@visactor/vtable"
}
],
"packageName": "@visactor/vtable",
"email": "[email protected]"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"comment": "fix: compute chart column width use Math.ceil bandSpace\n\n",
"type": "none",
"packageName": "@visactor/vtable"
}
],
"packageName": "@visactor/vtable",
"email": "[email protected]"
}
15 changes: 15 additions & 0 deletions docs/assets/api/en/event/event.md
Original file line number Diff line number Diff line change
Expand Up @@ -380,4 +380,19 @@ Parameter types of event callback function:

```
{ col: number; row: number; rawValue: string | number; changedValue: string | number };
```

## CHECKBOX_STATE_CHANGE
Change the checkbox checkbox state. **ListTable table exclusive event**

Parameter types of event callback function:

```
{
col: number;
row: number;
alue: string | number;
dataValue: string | number;
checked: boolean;
};
```
49 changes: 48 additions & 1 deletion docs/assets/api/en/methods.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ tableInstance.columns = newColumns;
```
## updatePagination(Function)

Update page number configuration information
Update page number configuration information, and it will be automatically redrawn after calling

```ts
/**
Expand Down Expand Up @@ -145,6 +145,47 @@ Select one or more cell ranges
selectCells(cellRanges: CellRange[]): void
```

## getSelectedCellInfos(Function)
Get the selected cell information, and the returned result is a two-dimensional array. The first-level array item represents a row, and each item of the second-level array represents a cell information of the row.

```
/**Get details of each cell in the selected area */
getSelectedCellInfos(): CellInfo[][] | null;
```

## getCellValue(Function)

Get cell display value

```
/**
* Get the cell display value
*/
getCellValue(col: number, row: number): FieldData;
```

## getCellOriginValue(Function)

Get the value before the format of the cell display data

```
/**
* Get the value before the format of the cell display data
*/
getCellOriginValue(col: number, row: number): FieldData;
```

## getCellRawValue(Function)

Get the original value of the cell display data source

```
/**
* Get the original value of the cell display data source
*/
getCellRawValue(col: number, row: number): FieldData;
```

## getCellStyle(Function)

Getting the style of a cell
Expand Down Expand Up @@ -342,6 +383,12 @@ Get the selected status of all data in the checkbox under a certain field. The o
getCheckboxState(field?: string | number): Array
```

## getCellCheckboxState(Function)
Get the status of a cell checkbox
```
getCellCheckboxState(col: number, row: number): Array
```

## scrollToCell(Function)

Scroll to a specific cell location
Expand Down
17 changes: 16 additions & 1 deletion docs/assets/api/zh/event/event.md
Original file line number Diff line number Diff line change
Expand Up @@ -403,4 +403,19 @@ icon 图标点击事件。

```
{ col: number; row: number; rawValue: string | number; changedValue: string | number };
```
```

## CHECKBOX_STATE_CHANGE
更改checkbox复选框状态。**ListTable表格专有事件**

事件回调函数的参数类型:

```
{
col: number;
row: number;
alue: string | number;
dataValue: string | number;
checked: boolean;
};
```
53 changes: 51 additions & 2 deletions docs/assets/api/zh/methods.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ tableInstance.columns = newColumns;
```
## updatePagination(Function)

更新页码配置信息
更新页码配置信息 调用后会自动重绘。

```ts
/**
Expand All @@ -83,8 +83,9 @@ export interface IPagination {
基本表格和VTable数据分析透视表(enableDataAnalysis=true)支持分页,透视组合图不支持分页。

注意! 透视表中perPageCount会自动修正为指标数量的整数倍。

## renderWithRecreateCells(Function)
重新单元格对象集合并重新渲染表格,使用场景如:
重新组织单元格对象树并重新渲染表格,使用场景如:

批量更新多个配置项后的刷新:
```
Expand Down Expand Up @@ -144,6 +145,48 @@ tableInstance.renderWithRecreateCells();
selectCells(cellRanges: CellRange[]): void
```

## getSelectedCellInfos(Function)

获取已选中的单元格信息,返回结果是二维数组,第一层数组项代表一行,第二层数组每一项即代表该行的一个单元格信息。

```
/**获取选中区域的每个单元格详情 */
getSelectedCellInfos(): CellInfo[][] | null;
```

## getCellValue(Function)

获取单元格展示值

```
/**
* 获取单元格展示值
*/
getCellValue(col: number, row: number): FieldData;
```

## getCellOriginValue(Function)

获取单元格展示数据的format前的值

```
/**
* 获取单元格展示数据的format前的值
*/
getCellOriginValue(col: number, row: number): FieldData;
```

## getCellRawValue(Function)

获取单元格展示数据源最原始值

```
/**
* 获取单元格展示数据源最原始值
*/
getCellRawValue(col: number, row: number): FieldData;
```

## getCellStyle(Function)

获取某个单元格的样式
Expand Down Expand Up @@ -342,6 +385,12 @@ tableInstance.renderWithRecreateCells();
getCheckboxState(field?: string | number): Array
```

## getCellCheckboxState(Function)
获取某个单元格checkbox的状态
```
getCellCheckboxState(col: number, row: number): Array
```

## scrollToCell(Function)

滚动到具体某个单元格位置。
Expand Down
Loading

0 comments on commit 69c76c2

Please sign in to comment.