Table of Contents

Class FieldValuesService

Namespace
JJMasterData.Core.DataManager.Services
Assembly
JJMasterData.Core.dll
public class FieldValuesService
Inheritance
FieldValuesService
Inherited Members

Constructors

FieldValuesService(ExpressionsService)

public FieldValuesService(ExpressionsService expressionsService)

Parameters

expressionsService ExpressionsService

Methods

GetDefaultValuesAsync(FormElement, FormStateData)

public ValueTask<Dictionary<string, object?>> GetDefaultValuesAsync(FormElement formElement, FormStateData formStateData)

Parameters

formElement FormElement
formStateData FormStateData

Returns

ValueTask<Dictionary<string, object>>

MergeWithDefaultValuesAsync(FormElement, FormStateData)

public ValueTask<Dictionary<string, object?>> MergeWithDefaultValuesAsync(FormElement formElement, FormStateData formStateData)

Parameters

formElement FormElement
formStateData FormStateData

Returns

ValueTask<Dictionary<string, object>>

MergeWithExpressionValuesAsync(FormElement, FormStateData, bool)

Apply default and triggers expression values

public ValueTask<Dictionary<string, object?>> MergeWithExpressionValuesAsync(FormElement formElement, FormStateData formStateData, bool replaceNullValues = true)

Parameters

formElement FormElement
formStateData FormStateData

Form values

replaceNullValues bool

Change the field's default value even if it is empty

Returns

ValueTask<Dictionary<string, object>>

Returns a new Dictionary with the updated values