newdevs:code:angular-field-order
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
newdevs:code:angular-field-order [2023/02/14 13:14] – tmccanna | newdevs:code:angular-field-order [2023/02/14 13:18] – tmccanna | ||
---|---|---|---|
Line 2: | Line 2: | ||
====== Control Angular Form Field Order ====== | ====== Control Angular Form Field Order ====== | ||
- | If you do not specify the field order when opening an Angular form in a modal, the fields will be displayed in alphabetical order. This can be very confusing, so it is good practice to add a fieldOrder parameter to the relevant HTML file. | + | If you do not specify the field order when opening an Angular form in a modal, the fields will be displayed in alphabetical order. This can be very confusing, so it is good practice to add a **fieldOrder** parameter to the relevant HTML file: |
- | An example of this can be seen in admin-carousel.component.html: | + | fieldOrder=" |
+ | |||
+ | An example of this in action | ||
< | < | ||
[preloadLinkedValues]=" | [preloadLinkedValues]=" | ||
- | | + | fieldOrder=" |
- | copy_location_filter, | + | copy_location_filter, |
+ | | ||
hiddenFieldsList=" | hiddenFieldsList=" | ||
[preSave]=" | [preSave]=" | ||
readonlyFields=" | readonlyFields=" | ||
- | [fieldOptions]=" | + | [fieldOptions]=" |
- | | + | |
+ | | ||
</ | </ | ||
- | + | | |
- | + | Note that you can also make use of the **hiddenFieldsList** parameter for fields that do not need to show on the form. | |
- | ===== Things to add to this page: ===== | + | |
- | + | ||
- | * Create example | + |
newdevs/code/angular-field-order.txt · Last modified: 2023/02/14 13:19 by tmccanna