Structure of a XML file

Structure

Click here to expand...

The root element "dynamicview"

The element <dynamicview> is the root element of the XML configuration file and needs to be the first defined element (beside of the optional <?xml> declaration).

Features

Name

Input option

Default value

Description

usenext

true/false

false

Activates/ Deactivates the pagination option below the search results. If activated, less data are being imported.

maxrows

integer


Specifies the maximum number of data sets that should be loaded.

If there is no value, all data sets are being loaded.

The data sets are choosen based on sorting.

initialload

true/false

true

Activates/ Deactivates the initial loading of data. If the value is "false" the user can only see the data after entering at least one search parameter.

The result set

The result set is defined inside two elements with SQL. The result set needs to be written inside the <sql> element to be displayed. General table expressions (CTE) should be defined inside the <cte> element if possible. The user rigths, if existing, shoulb be inculded in the SQL script. The framework offers the two placeholders ":loginname" and ":currentlanguage". These represent the user name and the user language. The placeholders will be replaced with the appropriate values when evaluating the SQL script. Furthermore you can find/use expressions inside the SQL script with three curly brackets. Theses are dynamic services.

The SQL needs to be written inside the elements in the square brackets of <![CDATA[]>.

Boolean values are shown with a green checkmark. But these values need to be set as Bit in SQL.


Displayed Columns

The element <columns> defines the columns which are displayed and the order of the columns in the grid. The element consists of a list of all the <column> elements, which describe a column.

Features of <column>

Name

Necessary

Input option

Description

columnname

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

This feature ties a column from the SQL script to the grid. The value of the feature needs to be the name of a column that is defined in the SQL script.

displayname/translationkey

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

This feature defines the title of a column. The feature displayname determines the actual column name, while the feature translationkey sets the translation key. The translation key is used for column names depending on the language. If the feature translationkey is set, displayname will be ignored.

isquicksearchable


true/false

If set to true, the value will be considered in the quick search.

isvisible


true/false

If set to true, the column is visible in the grid.

width


Integer

This feature discribes the width of the column in pixel.

If no value is specified, the default value is 50 pixel.

iswindowlink



true/false

The feature iswindowlink signalizes that a specific column should be displayed as a hyperlink. The hyperlink serves as an access point for the editing and as selection option in a sub-search (e.g. in IsSearchField).

To use the hyperlink as an access point the existence of a htttp://<installationname>/searchtype/Edit function is required.

dateformat


String

If one column is a date value, this feature can format the date. The default setting is "d" which displayes the date without the time in the culture of the user.

The format "G" displayes the date and the time in the culture of the user.

You can find a list with all formats and examples here:

https://docs.telerik.com/kendo-ui/globalization/intl/dateformatting

isutc


true/false

If a date value in the database is saved as an UTC value and this value is set to true, the date value can be converted to the users timezone.

colorruleref


String

Refers to a colorrule.

Only available for date values.

image



With this feature you can display images in the result grid. The value needs to refer to the field "ISGUID" in "DOKUDAT1".

If the value is NULL or the document does not exit, a default image or the text "No image" will be displayed.

You can change the default in the General settings.

The default value for a boolean value is false.

The sorting of the result set

The <sorting> element provides the opportunity to sort the result set by certain columns. The element consists of a list of <column> elements. If a <column> element is arranged higher the column is more likely to be considered in the search.

Features of <column>

Name

Necessary

Input option

Description

columnname

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

Refers to a column in the <columns> element.

mode


asc/desc

Indicates the sorting direction:

The default is asc.

Search elements

You can define search components in the <searchcontrols> element. These search components limit the result set. This element consists of a list of different elements that all define search components.

Common features of all search components

Name

Necessary

Input option

Description

referencecolumn

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

Refers to a column in the <columns> element. The search component then only refers to this column.

default


String

With this feature you can define a default value for the search component.

textfield

The <textfiled> component allows the user to search the result set with a string. If the string is found in any column, the appropriate data set will be selected.

Name

Input option

Description

comparativeactive

true/false

Specifies if there should be a DropBox under the textbox for the "comparative" setting.

comparative

like/startswith/equalto

Specifies how '%' is used in the search.

overridequery

String

An SQL query can be entered, which is used instead of the normal query. Example: EXISTS(SELECT 1 FROM procomment pk WHERE data.problemnr = pk.problemnr AND CONTAINS(pk.text,'&quot;{param1}&quot;')). "data" sit the alias for the query defined in the SQL tag. "{param1} is replaced with the string entered in the GUI".

replacepercentwithasterisk

true/false

% is replaced by *. Is needed if you use full text search in the overridequery. In the full text search * is expected instead of %.

To restrict the text field above the URL you can enter the parameter with the desired value to "{fieldname}_comparative".

Define default value

Here you can enter any string.

checkbox

The <checkbox> component allows the user to search the result set with boolean values. If the value in the column is true, the appropriate data set will be selected.

Define default value

You can enter "1" or "true", if the the appropriate checkbox should be selected by default. If the checkbox should not be selected by default, enter no default value.

multiselect

With the element <multiselect> it is possible to define a filter control that consists of a list of accepted values. If one of the selected values is in a column, the appropriate data set will be selected. You also need to deposit a data source.

Define default value

You can enter any string. If you want to specify more values as defaults, you can seperate them with a ','.

searchfield

The element <searchfield> gives you the opportunity to open a second search or search for keys of subobjects.

Name

Necessary

Input option

Description

searchwindowurl

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

The URL for the search.

searchvaluefield

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

The column that returns the subsearch.

multiselect


true/false

If true is set, you can search for more than one entry.

Define default value

You can enter any string. If you want to specify more values as defaults, you can seperate them with a ','.

datepicker

The <datepicker> component gives the user the opportunity to search in the result set with the help of dates. There is the feature timerange. If this feature is set to true, you can search in the stated column for a specific date. If this value is not set or set to false, you only search for the same date in every column.

Define default value

The date that you want as a default value needs to be written in the following format: yyyy-mm-dd (Regex: \d{4}-(0[1-9]|1[0-2])-(0[1-9]|1[1-9]|2[1-9]|3[01]) ). Other formats are not accepted. If you activate the timerange feature, you can enter two values. The two values need to be sperated with a ',' and represent the period of time that is used for the search (e.g. default = "2020-06-01, 2020-06-15" ).

datetimepicker

The <datetimepicker> component allows the user to search the result set for dates with specific times. There is the feature timerange. If this feature is set to true, you can search in a column for a specific time. If this value is not set or set to false, you only search for the same date in every column.

Define default value

The default value needs to be written in the ISO 8601 notation ( Regex: \d{4}-(0[1-9]|1[0-2])-(0[1-9]|1[1-9]|2[1-9]|3[01])T([01][1-9]|2[0-3]):([0-5][0-9]):([0-5][0-9]) ). Other formats are not accepted. If you activate the timerange feature, you can enter two values. The two values need to be sperated with a ',' and represent the period of time that is used for the search (e.g. default = "2020-06-01, 2020-06-15" ).

Definition of data sources for combobox and multiselect

You have the following options to define data sources:

1) You use a SQL. Set for the value lookuptablename the name of the desired SQL.

2) You use a static data source. Set for the value datasource the name of the desired data source.

3) You address a controller end point. There are the following features:

Name

Necessary

Description

datasourceurl

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

URL to the controller end point.

urltextfield

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

The displayed text in the search component.

urlvaluefield

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

The keyword that you filter the result set for.

Data sources for the search components

Static data sources

The <datasources> element allows you to specify the data inside the XML file directly. This has the benefit that no additional database access is necessary to fill a combobox or a multiselect with data. The <datasources> element consists of a list of <datasource> elements.

Features of <datasource>

Name

Necessary

Input option

Description

name

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

Name of the data source.

Functions as identification for the search components.

type

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

custom/ bool

Type of the data source.

With custom you can add as many entries as you want and with bool two entries (true and false/null).

one

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg *

String

The text if the value is true.

null

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg *

String

The text if the value is false or null.

keyistranslation


true/false

If the value is a translation key, this feature needs to be set to true*.

*Only available/ necessary, if the type is bool.


If the type is custom, the <datasource> element consists of a list of <item> elements. These represent in each case a data set of the data volume.

Features of <item>

Name

Necessary

Input option

Description

key

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

The key value that you search the result set for.

value

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

The text displayed in the search component.

keyistranslation


true/false

If the value key is a translation key, this feature needs to be set to true.

valueistranslation


true/false

If the value value is a translation key, thsi feature needs to be set to true.

SQL

Alternatively to the static data sources you can define SQL scripts that function as a data source for search components. You can define these in the <namedqueries> element. The <namedqueries> element consists of a list of <namedquery> that define the actual data source. The <namedquery> elements have only the feature name. This feature functions as identification and is mandatory field.

Please be aware that the result of the SQL script needs a key and value attribute.

You can use in SQL the placeholder :currentuser and :currentlanguage and the dynamic services.

The SQL needs to be written inside the elements in the brackets of <![CDATA[]>.

Menu actions

The <menu> elements allows you to add additional actions to your search. You can find these in the first column by clicking on images/download/thumbnails/494470446/Objekt_Dreipunkt_Button_img.png . The element consists of a list of <menuitem> elements in which the actions are defined. If the action should open a new page, this happens in the same window.

Features of <menuitem>

Name

Necessary

Input option

Description

name

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

Name of the action

link

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

The link that should be opened. Inside the link you can define two placeholders. These get filled with values from the search result. The two placeholders are: {{{primarykey}}} and {{{additionalkey}}}.

primarykey


String

The column whose value {{{primarykey}}} should be replaced.

additionalkey


String

The column whose value {{{additionalkey}}} should be replaced.

translationkey

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

The name of the translation key

openinsheet


true/false

If the link should be displayed in a sheet above the search, this value needs to be set to true.

(Visual) Adjustment of the grid

Background color based on date

It is possible to define rules that determine the background color of a column of the grid based on date values and the present date. These rules are defined in the <colorrule> element. The <colorrule> element consists of a list of <rule> elements. These elements only have the feature name that is used for identification. The identification needs to be part of the column description. A <rule> element consists of the elements <lessthan>, <equalto> and <greaterthan>. The values in the color element need to be valid CSS colors (named or hexadecimal, with the '#' symbol). If the value lies in the past, the color from the <lessthan> element is displayed. If it is the present day, the color from the <equalto> element is displayed. And if the value lies in the future, the color from the <greaterthan> element is displayed.

Background color basend on comparisons

With the element <colorswitches> you can set the background color or text color of a specific column. The <colorswitches> element consists of a list of <switch> elements that refer to a column. The <switch> element consists of a list of <case> elements that represent the different possibilities on how to color a cell.

Features of <switch>

Name

Necessary

Input option

Description

columnname


String

Refers to a column in the <columns> element. The specific column gets colored.

sourcecolumn

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

Refers to a column in the <columns> element. The coloring is based on this column.

row


true/false

If the whole row should be colored, this value needs to be set to true.

Features of <case>

Name

Necessary

Input option

Description

value

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg


If the column has the value, the column gets colored.

color


CSS color

The background color of the cell

text


CSS color

The font color of the cell.

Templates

With the <columntemplates> element you can define the appearance of the column with kendo templates. With these you can display specific icons in a column. The element consists of a list of <template> elements where you define the template.

Features of <template>

Name

Necessary

Input option

Description

columnname

images/s/ti67az/8401/0f22f74a0c673511e48ab1bc7ae6af4388aa8dbf/_/images/icons/emoticons/check.svg

String

Refers to a column in the <columns> element.

The template needs to be written inside the elements in the brackets of <![CDATA[]>.

RowTemplate

With the <RowTemplate> element you can define the appearance of a row on smartphones, tablets and very small screens. You can use kendo templates for this.

Placeholder

Placeholder

Description

{{Link}}

Is replaced by a hyperlink generated from the first <column> element with the property "iswindowlink=true".

{{DefaultImage}}

Replaced by an image if the search supports standard images.


The template needs to be written inside the elements in the brackets of <![CDATA[]>.

Diverse options

Options

The openactiondisabled attribute (default: false) can be used to that no link is generated to open the entity. The link to open the entity is usually generated automatically from the information in the search → {name of the Search}/Edit/Id={isWindowLink column}

This information can also be overwritten.

Features

Name

Necessary

Input option

Description

opencontrollername


String

Name of the edit controller. Default is the name of the search

openactionname


String

Name of the edit action. Default is Edit

linkprimarykeyname


String

Parameter Name of the primary key. Default is Id

linkprimarykeycolumnname


String

Name of the column from the search for the PrimaryKey

linkadditionalkeyname


String

Parameter Name for a second primary key.

linkadditionalcolumnname


String

Name of the column from the search for the second PrimaryKey

New button

If the user should have a button in the search for creating new entities, there needs to be a <newbutton> element below the <options> element. The second condition is that the user has the necessary rights to create a new entity.