The module enables a colourful highlight of enum and multi-enum fields values in order to attract the user's attention.
After the module installation, the values of all fields of type "Enum" and "Multi-Enum" get a color code that can be defined by the admin. A colourful background will be shown on both list and details pages.
Installation instructions for TreoPIM
The module will be installed together with TreoPIM. A separate installation is not necessary.
Deactivation of the module
The module is displayed in the list of installed modules under the name "Colored Fields". This list shows the name of the module, its version, a short description. In the action list you can uninstall this module.
- If you deactivate the module, all fields "Enum" and "Multi-Enum" lose their color and are displayed as standard fields (with transparent background) of these types.
- If you reactivate the module, all color settings saved before deactivation will be visible again.
- If TreoPIM is updated, the module may need to be reinstalled, thereby all preconfigured colors will be restored.
Setting up the system
After installing the module, the options for a background colour appear for each field value of type "Enum" or "Multi-Enum". By default, all already existing values of the "Enum" and "Multi-Enum" fields get the gray background (#ccc). The newly created values are given a black background (# 333333).
To specify a color for a value, you must go to the Entity Manager from the Administration and click Fields for the corresponding entity.
All fields of the selected entity are displayed, click on the desired field of type Enum or Multi-Enum or click on the button "Add Field" to define a new field.
In the opened window, you can edit the values for the selected field or enter new values with the corresponding colors.
There are two ways to specify a color for the value:
- Click on the color field to bring up the "Color Picker" and use the mouse to select the color and the shade by moving the marker along the color palette (the color code will change according to the selected color during the movement);
- Enter the color code in the field in which the color sample is displayed. The marker in the "Color Picker" is automatically moved to the appropriate color.
Show fields in the layout
After installing our module, the Enum and Multi-Enum fields have no restrictions in the Layout Manager and can be used normally.
To display the newly created fields, open the Layout Manager from the Administration and select the entity from the list you want to configure.
For example, if you have created the field "Colored Enum" for the entity "User" and you want to see this field in the entity list, you should select the "List" layout from the "User" entity, then move the desired field from right to left into the corresponding panel and click "Save".
To customize the output of fields in other displays of the entity, you should make similar changes in all layout types.After installing the module values from all enum and multi-enum fields can receive a colourful background, as far as it will be configurated by an administrator. This is especially useful for status fields or any other fields which are related to the work processes or their life cycles. Thanks to the module, the usability of the user interfaces has significantly improved. The multi-enum fields retain the preconfigured sequence of the values.
When creating / editing the field of the type enum and multi-enum, you can also set the font size - the font size of the entered text in [em] (compared to the current font size). When entering the value 1 or the blank space, the font size is displayed according to the standard font size.
You can enter the values from 0.7 to 2 (when entering other values an error notification will be displayed and the changes won’t be saved).
After installing the module values from all enum and multi-enum fields can receive a colourful background, as far as it will be configurated by an administrator. This is especially useful for status fields or any other fields which are related to the work processes or their life cycles.
Thanks to the module, the usability of the user interfaces has significantly improved.
The multi-enum fields retain the preconfigured sequence of the values.
In the detail view, the background colors are shown as follows:
In-line editing is also possible. The user will see the following views
For an enum field:
For a multi-enum field, if multiple values are selected from the previously saved list at the same time: