R32336-2 TemplateLine - Set Line Values

Code 32336-2
Entity Finance.Accounting.TemplateLines Entity
Name SetLineValues
Attribute AmountRowId, AmountSourceFilter, AmountColumnName, AmountRowName, TemplateLineProperty.PropertyValueSourceType, TemplateLineProperty.PropertyValueSource
Layer Front-End
Events AttributeChanged(AmountSourceName)
Priority Normal
Modify YES
Applicable Legislations ALL // no condition needed
Action

The rule sets AmountRowId, AmountSourceFilter, AmountColumnName, AmountRowName in NULL, and TemplateLineProperty.PropertyValueSourceType, TemplateLineProperty.PropertyValueSource according to the following conditions:
if (AmountSourceName != NULL) &&
(AmountSourceName == ExchangeDifferenceAmountSource ||
AmountSourceName == AccountBalanceAmountSource) &&
(TemplateLineProperty.PropertyValueSourceType == NULL)
then TemplateLineProperty.PropertyValueSourceType = "AccountItemKey"

if (TemplateLineProperty.PropertyValueSourceType != NULL) &&
(TemplateLineProperty.PropertyValueSourceType == "System properties for cycle source" ||
TemplateLineProperty.PropertyValueSourceType == "User defined properties for amount source" ||
TemplateLineProperty.PropertyValueSourceType == "User defined properties for amount
source and referenced records")
then TemplateLineProperty.PropertyValueSourceType = NULL

Description When AmountSourceName is changed, rule sets AmountRowId, AmountSourceFilter, AmountColumnName, AmountRowName, TemplateLineProperty.PropertyValueSourceType and TemplateLineProperty.PropertyValueSource
Message
Version Introduced: 2021
Revocable NO

* For more information about the Business Rules Documentation Template and a short explanation of each column, see topic System Business Rules.