Axon.ivy allows for individual configuration of many of its features, specifically for the following:
The specifics of the above described Configuration Types are explained in more detail in a separate section.
A configuration is always associated with a type (the type of object that it configures) and with an unique name. When applying a configuration to an object, only the name of the configuration must be given, because the type is defined by the object being configured.
By consistently defining and using the logically named configurations instead of setting properties individually on each configurable object you can later easily change or redefine the looks and behavior of the application in a single place.
All configurations can be created, edited and deleted using the Configuration Editor.
In Axon.ivy, each project has its own configuration database.
Lookup of any configurations is performed by an (type, configuration name) request. If the look-up of such a configuration fails for the current project then the configuration databases of the required projects are searched with the same query recursively. With this mechanism, configurations can effectively be shared among projects.
Since the current project is always asked first for a specific configuration, you can easily overwrite configurations that come from a required project, simply by redefining them locally (on the same type with the same name).
When creating a new project with the New Project Wizard you will be asked if default configuration content should be created for the new project. You should always disable this option if you’re creating a project that will be dependent on other projects. If you don’t disable it then all of the default configurations that are defined in the base project will be redefined automatically in the new project (and thereby shadow the inherited configurations), which may lead to unexpected behavior of the application.
If you unintentionally forgot to disable the option in the wizard you can still manually delete all configurations that have been created in the content database using the Configuration Editor at a later point of time.
The configuration editor is used to add/edit/delete configurations in the hierarchically organized configuration database of a project.
The configuration editor consists of different parts that are described separately below:
Configuration Editor Area (with header showing type/name of currently selected configuration)
Multi-Language Selector (not for all configuration types) This part is only visible if you have enabled the multi-language feature in the Deprecation Settings.
Generally, configurations are selected from the tree on the left hand side of the editor and edited in the details area on the right hand side. Modification of the configuration tree is performed with various actions that are available from the tree’s context menu.
The configuration tree shows the currently defined configurations inside a hierarchically organized tree. Configurations () are associated with a configuration class or configuration type () which in turn are logically grouped in a hierarchical folder structure ().
Only configuration nodes can be edited in the tree, the structure of the configuration database (i.e. the folders and types) is given by the system and cannot be changed.
The following operations are available from the context menu of the various configuration tree nodes:
- Add configuration
Adds a new configuration below the selected configuration class node.
Renames the currently selected configuration.
Renaming of a configuration does not update the objects that currently use the configuration with the old name. I.e. objects or scripts that used the old configuration name may not produce the expected outcome anymore, because the specified configuration does no longer exist. Typically this leads to the fallback of using the default configuration of the respective configuration class.
Deletes the currently selected configuration node.
Deleting configurations may lead to the same effects as renaming them. See warning above for a description of the possible consequences.
Copies the selected configuration into a new configuration with a name prompted from the user.
Please note that you don’t have to paste the new configuration, it will be pasted automatically next to the selected source configuration, because a configuration is always associated with exactly one configuration class. It is not possible to copy a configuration of type A to a type B.
Refreshes the configurations below the selected node.
Configuration Editor Area
The editor area shows a different editor depending on the configuration type (also called configuration class) of the currently selected configuration. The individual editors are described in Configuration Types.
The title bar of the editor area shows the type (i.e. the configuration
class) and the name of the currently selected configuration as
Multi language Configuration Selector
Enable the multi selection configuration by setting the flag in the Deprecation Settings.
Some configurations can be defined in multiple languages because they contain language specific settings. The validation configurations may have to validate input differently if it is entered in another language.
Use CMS references for the error message property in order to support multiple languages.
The language selector is shown only for configurations that support multiple language values per configuration. Use it to select the language of the configuration that you want to edit.
- Add new language value
Adds a value in a new language to the currently selected configuration. The contents of the last shown value are copied as initial content to the new configuration value.
- Delete language value
Clicking on this button removes the currently shown value from the set of values for this configuration. Only works if more than one language value are defined.
Renderer Configurations are used for specific content objects when they are rendered, the result is then displayed on the client browser.
Smart Table Configuration Editor
The Smart Table Configuration editor is part of the Configuration Management. See Configuration Editor for more information. A Smart Table Configuration can be added by using the add configuration function. The name is used in the Smart Table Content Editor for choosing a specific configuration.
Table Settings The HTML attributes settings for the table and the caption HTML elements.
Header Settings The HTML attributes settings for the table header group (thead element), the header row (tr element) and the header cells (th elements).
Body Settings The HTML attributes settings for the table header group (thead element), the header row (tr element) and the header cells (th elements).
Footer Settings The HTML attributes settings for the table body group (tbody element), the body rows (tr elements) and the body cells (td elements). Here it is possible to define different configuration for the rows and cells depending if they are displayed on an even or odd row position. The cells can also be different if they are in a even or odd column, in the first or last column or if they are in the column which is actually sorted. The first and last column settings does override the even or odd columns settings and the sorted column setting does override all other settings.
Sort Settings Enter the text which is displayed in the header if a column is sortable. Then ascending and descending values are shown. When a column actually is sorted then the sorted ascending or sorted descending values are shown.
Page Selector Settings Enter the format of the page selector, where it is shown (default: bottom) and the values displayed for the first, previous, next and last page to show. For the format there are the following possibilities:
Link to jump to the first page is shown with the value configured with the setting “First page”.
Link to jump to the previous page is shown with the value configured with the setting “Previous page”.
Links to jump to every page is shown with the page number.
Link to jump to the next page is shown with the value configured with the setting “Next page”.
Link to jump to the last page is shown with the value configured with the setting “Last page”.
The number of the actual page is displayed.
The number of the total amount of pages is displayed.
The number of the first showed row is displayed.
The number of the last showed row is displayed.
The number of the total rows in the table source is displayed.
The configuration database of a project contains configurations for various configurable targets (e.g. date or time values, input text fields, etc).
The user can define configurations for the following three aspects of an application: formats, styles and validation. Each of those aspects encompasses a number of configurable types (e.g. date or time or number) for each of which an arbitrary number of named configurations can be defined, which can then be referred from different locations in the configuration.
This section briefly discusses the different configuration types and explains the usage of their respective configuration editors.
Format configurations define how values of a specific type will be
rendered when output to the user. Formats can be defined for all the
base types of IvyScript, i.e.
String. All non-null values of those types
may be output as formatted strings by calling the
format("<format name>") within any script.
panel.label.text = in.selectedDate.format("long"); out.invoice.customerNumber = wsData.customer.format("customer_id");
The format configuration editor allows to specify various ways of formatting for the different IvyScript base type values. The formatting options (described below) vary from type to type; not all options are available on all types.
Format configurations are always language dependent. Just watch the Preview editor area after each selection or option that you enable for an understanding what the effects are for each language.
Format Type Select a predefined kind of formatting. The selected format kind may be further specified in the editor areas Option, Format Pattern and Format Script (depending on which kind that was selected).
Option This editor area is only available for some of the Number format kinds. The number of digits for the integer and/or fraction part may be selected (-1 stands for as many as needed). If you select grouping then a group character will be inserted to group the integer digits of the formatted number.
Format Pattern This group is only available if you have selected the PATTERN format from the Format Type list.
If Pattern is selected as format then this combo box allows for a selection from a number of predefined patterns. Use Script if you’d like to specify your own pattern format.
Format Script This group is only available if you have selected the SCRIPT format from the Format Type list.
Specify your own format with a script. The value variable will contain the value to be formatted. If you want to specify different patterns for different languages you should use the Multi language Configuration Selector to create multiple configurations for various languages.
Preview Shows an instant preview of the configured formatting applied to a default value.