Zeile 19: |
Zeile 19: |
| /// definiere die Attribute (keys) | | /// definiere die Attribute (keys) |
| ////////////////////////////////////////////////////////////// | | ////////////////////////////////////////////////////////////// |
− | -->{{#vardefine: Icon Datei Attribute | Seite hat Icon , Icon Farbton , Icon Breite }}<!-- | + | -->{{#arraydefine: Icon Datei Attribute <!-- |
| + | -->| Seite hat Icon , Icon Farbton , Icon Breite <!-- |
| + | -->| , <!-- |
| + | -->}}<!-- |
| ////////////////////////////////////////////////////////////// | | ////////////////////////////////////////////////////////////// |
| | | |
Zeile 26: |
Zeile 29: |
| /// legie die Attribute an (values) | | /// legie die Attribute an (values) |
| ////////////////////////////////////////////////////////////// | | ////////////////////////////////////////////////////////////// |
− | -->{{Attributgenerator<!-- | + | |
− | -->| Attributliste = {{#var: Icon Datei Attribute }} <!-- | + | /// Gehe die Formularfelder jedes Formularblocks durch = @KEY@ |
| + | -->{{#arraymap: {{#arrayprint: Attributliste | @//@ }}<!-- |
| + | -->| @//@ <!-- |
| + | -->| @KEY@ <!-- |
| + | -->|<!-- |
| + | /// Ermittle Datentyp des Formularfeldes (Attribut Datentyp) |
| + | -->{{#vardefine: Datentyp | {{#show: Attribut:@KEY@ | ?Datentyp# | default=Text }} }}<!-- |
| + | /// Ermittle den Inhalt des Formularfeldes |
| + | -->{{#if: {{{@KEY@|}}}<!-- |
| + | /// Trage das Attribut, abhängig von seinem Datentyp, ein |
| + | -->|{{#switch: {{#var:Datentyp}}<!-- |
| + | /// Seite: jeweils einzeln eintragen |
| + | -->| Seite = <!-- |
| + | -->{{#arraymap: {{{@KEY@}}} | , | @VALUE@ | {{#set: @KEY@ = @VALUE@ }} | }}<!-- |
| + | -->{{#arraydefine: Attribut eingetragen | {{#arrayprint:Attribut eingetragen|@//@}} @//@ @KEY@ }}<!-- |
| + | /// Wahrheitswert: nur eintragen, wenn wahr (also das Häkchen gesetzt wurde) |
| + | -->| Wahrheitswert = <!-- |
| + | -->{{#ifeq: {{{@KEY@|}}} | Ja <!-- |
| + | -->| {{#set: @KEY@ = {{{@KEY@}}} }}<!-- |
| + | -->{{#arraydefine: Attribut eingetragen | {{#arrayprint:Attribut eingetragen|@//@}} @//@ @KEY@ }}<!-- |
| + | -->|}}<!-- |
| + | /// Alle anderen Attribute bekommen den Standard |
| + | -->| {{#set: @KEY@ = {{{@KEY@}}} }} <!-- |
| + | -->{{#arraydefine: Attribut eingetragen | {{#arrayprint:Attribut eingetragen|@//@}} @//@ @KEY@ }}<!-- |
| + | -->}}<!-- |
| + | -->|<!-- |
| + | -->}}<!-- |
| + | -->|<!-- |
| -->}}<!-- | | -->}}<!-- |
| ////////////////////////////////////////////////////////////// | | ////////////////////////////////////////////////////////////// |
| + | |
| | | |
| --></includeonly> | | --></includeonly> |