![]() | |
Defaulting |
Throughout the Epic system, many screens have fields that are defaulted to specific values without requiring user input. Defaulting in SDK is often beneficial because it allows the user to obtain the values without understanding the often complex business logic.
We strive to conform to our guidelines, but due to the nature of defaulting in an API and the complexity of Epic, the best way to determine how defaulting behaves is reading the data object documentation combined with trial and error. There are some cases where defaulting did not seem like the ideal behavior.
Here are our guidelines about when SDK would default:
1. When the field is left blank.
In many cases the user will be unable to populate the field to blank on the insert and will need to use the update.
2. During Insert or Action method calls.
During an update call some fields can be defaulted if they belong to a sub object with a Flag value set to 'Insert'.
3. Any field that would appear already populated on the Epic screen without them being modified.
Ex. Combo boxes often appear in Epic with a defaulted value. In SDK, if the corresponding property was left blank during an insert call, we would default that property.
Often for complicated areas a separate method is created to obtain the default values. Ex. Get_Transaction_Installements, Get_Transaction_DefaultActionCancel
4. Any field that is populated in Epic after making a selection to a previous property.
Ex. If you fill in the Form and Endorsement Number, Epic defaults the surrounding related fields based on the preset Form and Endorsement information in Epic configuration that corresponds to the number.
In SDK, if those related properties are left blank during an insert call, they will be defaulted with the same values.
5. For newly added required fields or fields that become required between versions of Epic.
SDK calls from older endpoints will attempt to default a value in order to prevent existing call from breaking by suddenly throwing a required field message.
In some situations SDK we will not be able to suggest an appropriate value and the breaking change will be documented.
Exceptions to the guidelines where defaulting is not supported in SDK:
1. User or company specific defaults
Ex. Any defaults that are setup in the User Defaults section in Epic configuration.
2. When Epic defaults a combo box due to there being exactly 1 item available that must be selected.
Ex. Agency structures, when there is only 1 branch for an agency.
3. Cases where epic has a Calculate link.
SDK does not currently perform these calculations.