@univerjs-pro/engine-pivot v0.5.4
Class: PivotTableValueField
Defined in: pivot/table-field.ts:112
Represents a base class for the field in a pivot table.
Description
The base class for the field in a pivot table.
Extends
Constructors
new PivotTableValueField()
new PivotTableValueField(
dataFieldId,
id,
displayName,
sourceName): PivotTableValueField
Defined in: pivot/table-field.ts:115
Parameters
Parameter | Type | Default value |
---|---|---|
dataFieldId | string | undefined |
id | string | undefined |
displayName | string | '' |
sourceName | string | undefined |
Returns
Overrides
PivotTableFieldBase
.constructor
Properties
Property | Modifier | Type | Description | Inherited from | Defined in |
---|---|---|---|---|---|
dataFieldId | readonly | string | The base data field id of the field. | PivotTableFieldBase .dataFieldId | pivot/table-field.ts:38 |
displayName | public | string | The display name of the field. the default value is the data field name. | PivotTableFieldBase .displayName | pivot/table-field.ts:44 |
format | public | undefined | string | - | PivotTableFieldBase .format | pivot/table-field.ts:45 |
id | readonly | string | The unique identifier of the field. | PivotTableFieldBase .id | pivot/table-field.ts:39 |
lossLessProperty? | public | any | thr public object to save the property not defined but should be saved. | PivotTableFieldBase .lossLessProperty | pivot/table-field.ts:47 |
showDataAs | public | IPivotTableShowDataAsInfo | - | - | pivot/table-field.ts:114 |
sourceName | readonly | string | - | PivotTableFieldBase .sourceName | pivot/table-field.ts:40 |
subtotal | public | PivotSubtotalTypeEnum | - | - | pivot/table-field.ts:113 |
Methods
fromJSON()
fromJSON(data): void
Defined in: pivot/table-field.ts:165
Parameters
Parameter | Type |
---|---|
data | IPivotTableValueFieldJSON |
Returns
void
Overrides
getDataFieldId()
getDataFieldId(): string
Defined in: pivot/table-field.ts:78
Returns
string
Inherited from
PivotTableFieldBase
.getDataFieldId
getDisplayName()
getDisplayName(): string
Defined in: pivot/table-field.ts:94
Returns
string
Inherited from
PivotTableFieldBase
.getDisplayName
getFormat()
getFormat(): undefined | string
Defined in: pivot/table-field.ts:82
Returns
undefined
| string
Inherited from
getId()
getId(): string
Defined in: pivot/table-field.ts:56
Returns
string
Inherited from
getQueryData()
abstract getQueryData(): IPivotTableValueFieldQueryData
Defined in: pivot/table-field.ts:135
Returns
IPivotTableValueFieldQueryData
- the query data of the field.
Overrides
PivotTableFieldBase
.getQueryData
getShowDataAs()
getShowDataAs(): IPivotTableShowDataAsInfo
Defined in: pivot/table-field.ts:131
Returns
getSourceName()
getSourceName(): string
Defined in: pivot/table-field.ts:64
- the read only name in collection
Returns
string
- the source name of the field, which is the name of the data field.
Inherited from
PivotTableFieldBase
.getSourceName
getSubtotal()
getSubtotal(): PivotSubtotalTypeEnum
Defined in: pivot/table-field.ts:123
Returns
setDataFieldId()
setDataFieldId(dataFieldId): void
Defined in: pivot/table-field.ts:73
Parameters
Parameter | Type |
---|---|
dataFieldId | string |
Returns
void
Inherited from
PivotTableFieldBase
.setDataFieldId
setDisplayName()
setDisplayName(displayName): void
Defined in: pivot/table-field.ts:90
Parameters
Parameter | Type |
---|---|
displayName | string |
Returns
void
Inherited from
PivotTableFieldBase
.setDisplayName
setFormat()
setFormat(format): void
Defined in: pivot/table-field.ts:86
Parameters
Parameter | Type |
---|---|
format | undefined | string |
Returns
void
Inherited from
setShowDataAs()
setShowDataAs(showDataAs): void
Defined in: pivot/table-field.ts:127
Parameters
Parameter | Type |
---|---|
showDataAs | IPivotTableShowDataAsInfo |
Returns
void
setSourceName()
setSourceName(sourceName): void
Defined in: pivot/table-field.ts:68
Parameters
Parameter | Type |
---|---|
sourceName | string |
Returns
void
Inherited from
PivotTableFieldBase
.setSourceName
setSubtotal()
setSubtotal(subtotal): void
Defined in: pivot/table-field.ts:119
Parameters
Parameter | Type |
---|---|
subtotal | PivotSubtotalTypeEnum |
Returns
void
toJSON()
toJSON(): IPivotTableValueFieldJSON
Defined in: pivot/table-field.ts:149
Returns
- the JSON data of the value field.