Changes for page Bedingung (Wert prüfen)


From version 1.1
edited by gru
on 29.06.2021, 14:49
Change comment: There is no comment for this version
To version 1.2
edited by gru
on 10.02.2022, 15:42
Change comment: There is no comment for this version

Summary

Details

Page properties
Title
... ... @@ -1,1 +1,1 @@
1 -Condition
1 +Condition (Check value)
Content
... ... @@ -1,1 +1,84 @@
1 -WIP en
1 +{{content/}}
2 +
3 +Control elements of type //Condition (Check value)// can be used to influence the flow of processing depending on form values and other content by using [[Variables>>doc:Formcycle.UserInterface.Variables]]. These elements allow the workflow to be split into two paths depending on whether a configured condition turns out to be true or false. By using multiple conditions in one condition element and nesting conditions, it is possible to implement even complicated workflows.
4 +
5 +The condition element is placed in the workflow like an action. Initially, the two paths of the element are labeled //Yes// and //No//. However, the labeling of the paths can be changed. This is possible by clicking on the label, adjusting it and confirming with the Enter key or clicking somewhere outside the input area.
6 +
7 +== Configuration ==
8 +
9 +=== Condition N ===
10 +
11 +The condition element can check one or more conditions. In each case, a value to be checked, a condition and, if necessary, a value of the condition are required. In the conditions and values [[Variables>>doc:Formcycle.UserInterface.Variables]] are supported, which also allow to check the contents of form fields and the results of previous actions in the same processing chain. Initially, controls of type //Condition (Check value)// have only one condition.
12 +
13 +Conditions each have the following input options:
14 +
15 +; Value to be checked
16 +: The value which should be checked. [[Variables>>doc:Formcycle.UserInterface.Variables]] are used here to determine the value.
17 +; Condition
18 +: Condition to be tested. The following options are available for selection:
19 +:: empty
20 +:: not empty
21 +:: equal
22 +:: not equal
23 +:: contains
24 +:: does not contains
25 +:: greater than
26 +:: greater or equal
27 +:: lower than
28 +:: lower or equal
29 +:: starts with
30 +:: does not start with
31 +:: ends with
32 +:: does not end with
33 +:: matches regexp
34 +:: does not match regexp
35 +; Value to compare against
36 +: The value of the selected condition used for the check. Visible if //empty// or //not empty// was not selected as condition.
37 +
38 +=== Adding another condition ===
39 +
40 +Under each last condition there is a button //{ficon name="plus-circle" /}}. Add condition//. After the first click on this button, a field is also visible under the first configured condition, in which the [[Link>>|anchor="HLinkingconditions"]] of the conditions can be configured.
41 +
42 +=== Deleting conditions ===
43 +
44 +If more than one condition has been configured, conditions can be deleted via the {{ficon name="trash-alt2" /}} icon in the condition's headline.
45 +
46 +== Linking conditions ==
47 +
48 +To link the configured conditions, 3 options are available, one of which can be selected:
49 +
50 +; All must match (AND)
51 +: Alle an diesem Steuerelement konfigurierten Bedingungen müssen zutreffen, damit der //Ja//-Pfad ausgeführt wird. Ansonsten wird der //Nein//-Pfad ausgeführt. Diese Option ist der Standardwert.
52 +; One or more must match (OR)
53 +: At least one of the conditions configured on this control must be true for the //Yes// path to be executed. Otherwise the //No// path will be executed.
54 +; Something else
55 +: For complicated cases, this option allows to enter any logical links of the configured conditions. The conditions to be used must be inserted as follows:
56 +:; cN
57 +:: A condition, for example {{code language="none"}}c1{{/code}} or {{code language="none"}}c3{{/code}}. The names of the conditions are always in the heading of the condition. For a better clarity, the names of the conditions can also be changed by clicking on them.
58 +::
59 +: In addition to parentheses, the following operators and constants can be used to link the conditions logically:
60 +:; not
61 +:: Negation, which must precede the value to be negated. For example:
62 +:: {{code language="none"}}c1 and not c2{{/code}}
63 +::
64 +:: {{code language="none"}}c1 or not (c2 and c3){{/code}}
65 +:; and
66 +:: AND operation, which is true if both concatenated values are true. For example:
67 +:: {{code language="none"}}c1 and c2{{/code}}
68 +::
69 +:: {{code language="none"}}c1 and not c2 and c3{{/code}}
70 +:; or
71 +:: OR operation, which is true, one of the two concatenated values is true. For example:
72 +:: {{code language="none"}}c1 or c2{{/code}}
73 +::
74 +:: {{code language="none"}}c1 or c2 or not c3{{/code}}
75 +::
76 +:; false, true
77 +:: These two constants represent the logical values //false// and //true//.
78 +:; xor, nand, nor, implies, impliedby, equiv und unequiv
79 +:: Represents, in this order, the logical operators [[Kontravalenz>>url:https://de.wikipedia.org/wiki/Kontravalenz]], [[Alternative Verneinung>>url:https://de.wikipedia.org/wiki/NAND-Gatter]], [[Gemeinsame Verneinung>>url:https://de.wikipedia.org/wiki/NOR-Gatter]], [[Materiale Implikation>>url:https://de.wikipedia.org/wiki/Implikation]], [[Gegenläufige Implikation>>url:https://en.wikipedia.org/wiki/Converse_(logic)]], [[Materiale Äquivalenz>>url:https://de.wikipedia.org/wiki/Bikonditional]] und Nicht-Äquivalenz.
80 +
81 +The evaluation of the conditions takes place by default from left to right. By using parentheses, the order of evaluation can also be influenced. This could look like the following example:
82 +
83 +{{code language="none"}}(c1 and not c2) or (c2 and (c3 or c4)){{/code}}
84 +