@univerjs-pro/engine-pivot v0.5.4
Class: PivotView
Defined in: layout/pivot-view.ts:9
PivotView
Description
the view of pivot table, which contains the page, row, col, data view, the page view separation the pivot table to two areas, the row and col view as the header of data area
Constructors
new PivotView()
new PivotView(): PivotView
Defined in: layout/pivot-view.ts:39
Returns
Properties
Property | Type | Default value | Description | Defined in |
---|---|---|---|---|
colView | LabelViewItem | undefined | the col view of the pivot table | layout/pivot-view.ts:21 |
cornerView | PivotViewItem | undefined | the corner view of the pivot table | layout/pivot-view.ts:29 |
dataView | PivotViewItem | undefined | the data view of the pivot table | layout/pivot-view.ts:25 |
formatMap | Record <string , string > | {} | the format map of the table field id, it will be used to store the format of the pivot view | layout/pivot-view.ts:38 |
pageView | PageViewItem | undefined | the page view of the pivot table | layout/pivot-view.ts:13 |
rowView | LabelViewItem | undefined | the row view of the pivot table | layout/pivot-view.ts:17 |
version | number | undefined | the version of the pivot view, it will be used to check the view is the latest | layout/pivot-view.ts:33 |
Methods
formJSON()
formJSON(data): void
Defined in: layout/pivot-view.ts:81
Parameters
Parameter | Type |
---|---|
data | IPivotViewJSON |
Returns
void
getVersion()
getVersion(): number
Defined in: layout/pivot-view.ts:64
Returns
number
setFormat()
setFormat(model): void
Defined in: layout/pivot-view.ts:53
- the func effect is to set the format code , for label view, it will used to format the header , such as date type data, in the data view, it will used to format the data of show data as
Parameters
Parameter | Type | Description |
---|---|---|
model | PivotModel | the pivot model, it will be used to set the format of the pivot view |
Returns
void
setVersion()
setVersion(version?): void
Defined in: layout/pivot-view.ts:43
Parameters
Parameter | Type |
---|---|
version ? | number |
Returns
void
toJSON()
toJSON(): IPivotViewJSON
Defined in: layout/pivot-view.ts:68