Specific Field Definition Configuration

Prev Next

Truncation of the Text Fields


Sometimes text fields contain a lot of information that is not necessary for a bigger part of users in general cases. There is a way to hide long text by selecting Truncate Long Text option and specifying quantity of characters after that text will be hidden. From the views on site hidden text can be expanded by clicking Show More link. Additional configuration is available in ~web/static/newui/appearance/(SkinName)/skin.js file that is responsible for text truncation and has next default properties:

Key

Default Value

Description

length

300

The number of characters to be display before truncating. This parameter is overridden by new FieldDefinition Property

minTrail

20

The minimum number of “extra” characters that are required to be truncated

moreText

“>”

The text to use for the “more” link.

lessText

“<”

The text to use for the “less” link.

ellipsisText

“...”

The text to append to the truncated portion.

moreAni

""

The speed argument for the jquery show() method

lessAni

""

The speed argument for the jquery hide() method

Validation of the Text Fields


It is possible to enable custom validation to the text, textbox, fixed text fields in their field definition settings. There are 3 types of validation:

  • EAN-8 and EAN-13 (accept only valid EAN of mentioned types)

  • User Defined Input Mask (validate by string mask that can be constructed from the limited number of special characters)

  • Java Regular Expression (allows to define the validation rule of any complexity using regular expression language)

Also it is possible to define the validation text, that will be shown as a placeholder inside the text area and in alert notification.

image149.png

Access Specific Behavior - make field "read only" after creation


It is possible to prevent specific users being to edit a field once they have created a new item so they are unable to edit the original value for compliance versions.

Feature becomes available when feature flag "readOnlyAfterCreation" is enabled in System.properties file.

Screenshot_2022-08-10_170132.png

Note: only access rights for which was enabled access to target module are listed in "Apply for Access Rights" field

After record (item) creation fields with enabled "Read Only After Creation" option becomes read-only for users with access rights selected in "Apply for Access Rights".

Please, pay attention to the list of limitations for the current feature:

  • Feature is available for the restricted field types. Please see the table below with the list of supported field types:

Field Content

Field Type

 Text

 Text Field
 Text Box
 Radio Buttons
 Check boxes
 Select Box
 Multi Select Field

 Integer

 Text Field
 Fixed Text
 Text Box
 Radio Buttons
 Check boxes
 Select Box
 Multi Select Field

 Decimal Numeral

 Text Field
 Fixed Text
 Text Box
 Radio Buttons
 Check boxes
 Select Box
 Multi Select Field

 Module

 Select Box
 Multi Select Field
 Radio Buttons
 Check boxes

  • From version 12.0.1, "read only" after creation will be also available for fields in module links with Default values and Filtering enabled: Screenshot_2022-08-10_170533.png

  • Read-only prevents change even by dependency: fields with ‘Read Only After Creation’ enabled will not be updated even if default values are configured for them;

  • The feature cannot be applied to the fields with enabled “Prefill Automatically“ option or "Automatic Field Content Only" option were configured for it.

  • Feature is ignored during field import and Execute task actions (Create/Update in another module).

  • Feature will be applied for fields from dependency chain only in case if all fields from the chain are "Read Only after creation"

  • 'Read Only After Creation' functionality continue applying to the field even when feature flag is disabled - EBMS-29610

Default Values for Date Fields


For the field definitions of the type Date and Date-Time it is possible to configure the following default values:

  • Constant

  • Current time

  • End Of Current Working Week

  • Last Day Of Month

  • Last Working Day Of Month

  • Start Of Current Month

  • Start Of Current Working Week

Constant - when selected as Default Value Type it allows to manually enter the default date/date-time value into the Default Date Value field. Date/Date-Time fields will be automatically populated with this value on new item creation. 

Current time - this setting is also known as "Use current  date as default" before version 9.93. When selected, it inserts the current date/date-time value into the new items.

End Of Current Working Week, Last Day Of Month, Last Working Day Of Month, Start Of Current Month, Start Of Current Working Week - even though these options are self-descriptive, it is important to know that as per version 9.93, public holidays across international calendars are not supported. Namely, the Start Of Current Working Week and End Of Current Working Week default values will insert the date of Monday and Friday of the current week correspondingly.

Screenshot_2019-11-26_at_17.50.18.png