To edit a custom field in Projectal, follow these steps:
- Go to the Management screen by clicking Management on the left sidebar.
- Click the Custom Fields button to display the Custom Fields screen.
- Select the entity from the Entity dropdown list that you wish to edit its custom fields.
- Click the Edit button on the Custom Fields screen toolbar.
- This will display the Edit Custom Field screen.
Field Name
Enter the name of the custom field. The field name is used when you want to access data for this custom field using data views, the Projectal RESTful API and the Projectal Python library.
Tip: The field name must contain only letters, underscore or numbers and start with a lowercase letter.
Example: You wish to add an "Employment Code" custom field for staff in Projectal so you track the employment code coming from your HR system. You would typically call the field name "employmentCode". And, you would refer to this custom field as STAFF.employmentCode in your data views and connector applications that use the Projectal Restful API and Python library.
Tip: The field name must be unique and cannot have been used before for the selected entity. This constraint also applies to custom fields that have been deleted. Once deleted, the field name is considered to have been used and cannot be used again for the selected entity.
Tip: Be careful when changing the field name for a custom field. There may be data views and connector apps that are referencing this custom field using the current field name. Changing the field name will mean these data views and connector apps will not work until they have been updated to use the updated field name.
Type
Select the type of custom field that you wish to create. The available types are:
- Boolean
- String
- Integer
- Long Integer
- Float
- Double
- Byte
- Date
- List of Strings
- List of Integers
- List of Long Integers
- List of Floats
- List of Doubles
- List of Bytes
Once you have chosen the type, then the default value, min value, max value and regular expression restrictions will allow you to further define the custom field.
Tip: Once you have chosen the type for the custom field and saved the custom field, then the custom field's type cannot be changed.
Display Name
Enter the display name of the custom field. The display name is what users of Projectal will see (instead of the field name). Users of Projectal will see the display names of custom fields on the Edit screens in Projectal.
Example: You have added the "employmentCode" custom field to the STAFF entity. You give this custom field a display name of "Employment Code" and that is what is displayed in the Edit Staff screen.
Display After
Select the display position of the custom field where you would like it to appear on the Add screen and Edit screen for this entity. The dropdown lists all the displayed fields for the entity. Select one of the fields, and the custom field will be displayed after it on the Add screen and Edit screen for the entity.
Example: You wish to add a "taxRate" custom field to the STAFF entity. Since it is financial information you would like the custom field to be located under the Pay Amount field on the Add Staff screen and Edit Staff screen.
Default Value
Enter the initial value for the custom field. This will be used and displayed when users create new entities. This is an optional attribute.
Example: You have added "employmentCode" string custom field to the STAFF entity. You have set the display name to be "Employment Code" and the default value to be "EC-000". When a user creates a new staff, the New Staff screen will display "Employment Code" and set "EC-000" as the initial value.
Tip: If you set a custom field to be Mandatory, then you also must set the default value as well.
Min Value
Enter the minimum value for the custom field. This is an optional attribute. If left empty, then the default minimum values will be used by Projectal for each specific custom field type.
Default minimum values used by Projectal:
Custom Field Type: | Default Minimum Value: |
Boolean | Not Applicable |
String | 0 (characters long) |
Integer | -2147483648 |
Long Integer | -9223372036854775000 |
Float | -3.4028235E38 |
Double | -1.7976931348623157E308 |
Byte | -128 |
Date | 1970-01-01 |
List of Strings | Not Applicable |
List of Integers | Not Applicable |
List of Long Integers | Not Applicable |
List of Floats | Not Applicable |
List of Doubles | Not Applicable |
List of Bytes | Not Applicable |
Tip: Be careful when changing the minimum value after already adding data into Projectal for this custom field. The new minimum value may mean that some existing data for this custom field does no longer comply with the new minimum value.
Max Value
Enter the maximum value for the custom field. This is an optional attribute. If left empty, then the default maximum values will be used by Projectal for each specific custom field type.
Default maximum values used by Projectal:
Custom Field Type: | Default Maximum Value: |
Boolean | Not Applicable |
String | 10,000 (characters long) |
Integer | 2147483647 |
Long Integer | 9223372036854775000 |
Float | 3.4028235E38 |
Double | 1.7976931348623157E308 |
Byte | 127 |
Date | 3000-01-01 |
List of Strings | Not Applicable |
List of Integers | Not Applicable |
List of Long Integers | Not Applicable |
List of Floats | Not Applicable |
List of Doubles | Not Applicable |
List of Bytes | Not Applicable |
Tip: Be careful when changing the maximum value after already adding data into Projectal for this custom field. The new maximum value may mean that some existing data for this custom field does no longer comply with the new maximum value.
Restrict Values Using Regular Expression
Enter the additional formatting restrictions that values for the custom field must adhere to. This is an optional attribute.
Tip: Regular expressions must follow the Java regular expression syntax. See https://www.freeformatter.com/java-regex-tester.html for the Java syntax and examples.
Example: You have added "employmentCode" string custom field to the STAFF entity. You have set the display name to be "Employment Code". You want to make sure the format of the values entered by users are always "EC-" followed by 3 digits. So you set the regular expression to be "EC-\d{3}".
When you set the type for the custom field to be a list (of strings, integers, floats, etc.), then the regular expression must specify the list of possible values in the list.
Example: If a custom field was a list of strings, then the regular expression would be defined like "string 1|string 2|string 3|string 4".
Example: If a custom field was a list of integers or long integers, then the regular expression would be defined like "10|20|30|40".
Example: If a custom field was a list of floats or doubles, then the regular expression would be define like "10.458|20.53|30.85|40.0365".
Tip: Be careful when changing the regular expression after already adding data into Projectal for this custom field. The new regular expression may mean that some existing data for this custom field does no longer comply with the new regular expression.
Mandatory
Click the Mandatory checkbox if you wish to force users to enter a value for this custom field when creating new entities or editing entities. This is an optional attribute.
Tip: If you set a custom field to be Mandatory, then you must also set the default value as well.
Description
Enter a helpful description for the custom field. This is displayed as a tooltip when hovering over the (?) icon next to the display name of the custom field on the Edit entity screens. This is an optional attribute.
Example: You have added "employmentCode" string custom field to the STAFF entity. You have set the display name to be "Employment Code". You have added a description of "Employment code must begin with 'EC-' followed by 3 digits". This description is displayed as a tooltip on the Edit Staff screen to help users understand the requirements for entering the custom field.
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article