File

projects/m2-core/src/lib/core/service/value/property-value.service.ts

Index

Methods

Constructor

constructor(sanitizer: DomSanitizer, logger: Logger, doubleParserService: DoubleParserService, dataReadService: DataReadService, resourceReadService: ResourceReadService, constraintTableService: ConstraintTableService, applicationReadService: ApplicationReadService, datatableService: DatatableService, measurementService: MeasurementService)
Parameters :
Name Type Optional
sanitizer DomSanitizer No
logger Logger No
doubleParserService DoubleParserService No
dataReadService DataReadService No
resourceReadService ResourceReadService No
constraintTableService ConstraintTableService No
applicationReadService ApplicationReadService No
datatableService DatatableService No
measurementService MeasurementService No

Methods

Public aggregationDataToString
aggregationDataToString(ownerId: number, partName: string, partId: number)
Parameters :
Name Type Optional
ownerId number No
partName string No
partId number No
Returns : ValueStringForm
Public applicationAttributeToString
applicationAttributeToString(appAttribute: ApplicationAttribute, precision?: number, unit?: MeasurementUnit, isHistorical)

Application attribute

Parameters :
Name Type Optional Default value
appAttribute ApplicationAttribute No
precision number Yes
unit MeasurementUnit Yes
isHistorical No false
Returns : ValueStringForm
Public attributeDataToBackendString
attributeDataToBackendString(valueType: AttributeType, data: AttributeValueData, precision?: number, unit?: MeasurementUnit, restrictiveCondition)
Parameters :
Name Type Optional Default value
valueType AttributeType No
data AttributeValueData No
precision number Yes
unit MeasurementUnit Yes
restrictiveCondition No RestrictiveCondition.None
Returns : string
Public attributeDataToString
attributeDataToString(ownerId: number, valueType: AttributeType, data: AttributeValueData, precision?: number, unit?: MeasurementUnit, restrictiveCondition, entityType: ModelEntityType, isHistorical, disabledFile, formFileBodyUrlFn?: (ownerId?: number,data?: AttributeValueData) => void, useParsedParams)

{number} ownerId - AttributeValue or ConstraintTableCell

Parameters :
Name Type Optional Default value
ownerId number No
valueType AttributeType No
data AttributeValueData No
precision number Yes
unit MeasurementUnit Yes
restrictiveCondition No RestrictiveCondition.None
entityType ModelEntityType No 'ATTRIBUTE_VALUE'
isHistorical No false
disabledFile No false
formFileBodyUrlFn function Yes
useParsedParams No true
Returns : ValueStringForm
Public constraintCellValueToString
constraintCellValueToString(cellValue: ConstraintTableCell, precision?: number, unit?: MeasurementUnit, aggregationPartAsRef, useParsedParams)
Parameters :
Name Type Optional Default value
cellValue ConstraintTableCell No
precision number Yes
unit MeasurementUnit Yes
aggregationPartAsRef No false
useParsedParams No true
Returns : ValueStringForm
Public constraintTableRowToDatatableRow
constraintTableRowToDatatableRow(constraintRow: ConstraintTableRow, propertyIdToPrecisionMap?: Map, propertyIdToUnitMap?: Map<number | MeasurementUnit>, aggregationPartAsRef)

Constraint table cell

Parameters :
Name Type Optional Default value
constraintRow ConstraintTableRow No
propertyIdToPrecisionMap Map<number | number> Yes
propertyIdToUnitMap Map<number | MeasurementUnit> Yes
aggregationPartAsRef No false
Returns : ConstraintTableRow
Public formatPageRow
formatPageRow(pageRow: PageRow, propertyIdToPrecisionMap: Map, propertyIdToUnitMap: Map<number | MeasurementUnit>, nameAsRef)

{{id: number, displayName: string, propertyId01: string, propertyId02: string, ...}}

Parameters :
Name Type Optional Default value
pageRow PageRow No
propertyIdToPrecisionMap Map<number | number> No
propertyIdToUnitMap Map<number | MeasurementUnit> No
nameAsRef No false
Returns : PageRow
Public formAttributeValueData
formAttributeValueData(valueType: AttributeType, valueData: AttributeValueData, newValue: string | boolean | Date | FormulaRuleData, unit: MeasurementUnit, precisionDeprecated?: number, force)
Parameters :
Name Type Optional Default value
valueType AttributeType No
valueData AttributeValueData No
newValue string | boolean | Date | FormulaRuleData No
unit MeasurementUnit No
precisionDeprecated number Yes
force No false
Returns : AttributeValueData
Public formChangeNameRequest
formChangeNameRequest(srcValue: AttributeValue, newName: string)

Named value

Parameters :
Name Type Optional
srcValue AttributeValue No
newName string No
Public formChangeRequest
formChangeRequest(srcValue: AttributeValue, newValue: string | boolean | Date | FormulaRuleData, unit: MeasurementUnit, precision: number, forceEdit, isCalculated: boolean)

Updating value

Parameters :
Name Type Optional Default value
srcValue AttributeValue No
newValue string | boolean | Date | FormulaRuleData No
unit MeasurementUnit No
precision number No
forceEdit No false
isCalculated boolean No
Public formItemDescription
formItemDescription(itemId: number, declarationsToValues: DeclarationToValues[])

Item details

Parameters :
Name Type Optional
itemId number No
declarationsToValues DeclarationToValues[] No
Public formItemsDescriptions
formItemsDescriptions(itemIdToValuesMap: Map<number | DeclarationToValues[]>)
Parameters :
Name Type Optional
itemIdToValuesMap Map<number | DeclarationToValues[]> No
Public groupPropertyValues
groupPropertyValues(declarationInfos: DeclarationInfo[], propertyValues: PropertyValue[])
Parameters :
Name Type Optional
declarationInfos DeclarationInfo[] No
propertyValues PropertyValue[] No
Public groupValuesGroupsByCategories
groupValuesGroupsByCategories(declarationsToValues: DeclarationToValues[], documentsInSeparateTab)
Parameters :
Name Type Optional Default value
declarationsToValues DeclarationToValues[] No
documentsInSeparateTab No false
Returns : ItemCardValues
Public propertyValueToString
propertyValueToString(value: PropertyValue, precision?: number, unit?: MeasurementUnit, isHistorical, disabledFile)
Parameters :
Name Type Optional Default value
value PropertyValue No
precision number Yes
unit MeasurementUnit Yes
isHistorical No false
disabledFile No false
Returns : ValueStringForm
Public setLinkValuesCells
setLinkValuesCells(tableRow: Object, linkValues: LinkAttribute[], linkDeclarationsMap: Map<number | LinkAttrDeclaration>)
Parameters :
Name Type Optional
tableRow Object No
linkValues LinkAttribute[] No
linkDeclarationsMap Map<number | LinkAttrDeclaration> No
Returns : void
Public setValuesCells
setValuesCells(tableRow: Object, tableCellInfos: TableCellInfo[], propertyIdToPrecisionMap: Map, propertyIdToUnitMap: Map<number | MeasurementUnit>, isHistorical, disabledFile)
Parameters :
Name Type Optional Default value
tableRow Object No
tableCellInfos TableCellInfo[] No
propertyIdToPrecisionMap Map<number | number> No
propertyIdToUnitMap Map<number | MeasurementUnit> No
isHistorical No false
disabledFile No false
Returns : void
Public updateValue
updateValue(request: UpdatePropertyValueRequest, propertyValue: PropertyValue)

Update value by request

Parameters :
Name Type Optional
request UpdatePropertyValueRequest No
propertyValue PropertyValue No

results matching ""

    No results matching ""