Sort Elements und Attributs

The elements/attributes are sorted within the editor via the command “SequenceOrder” for elements and “AttributeOrder” for attributes.

However, this will only work if the elements and attributes are not declared inline!

Example schemata:

<xs:schema>
<xs:element name="beispiel" type="beispiel" />
<xs:complexType name="beispiel">
<xs:sequence>
<xs:element name="element1" type="xs:string" />
<xs:element name="element2" type="xs:integer" />
<xs:element name="element3" type="xs:string" />
</xs:sequence>
<xs:attribute name="attribute1" type="xs:string" />
<xs:attribute name="attribute2" type="xs:string" />
<xs:attribute name="attribute3" type="xs:string" />
</xs:complexType>
</xs:schema>

 

Example sorting for upper schema:

<namespace name="Editor">
<type name="http://getit.de/beispiel">
<item name="ComplexType:beispiel#SequenceOrder">element2 element3</item>
<item name="ComplexType:beispiel#AttributeOrder">attribute2 attribute3</item>
</type>
</namespace>

The order of the elements in the editor is now:
Element2, Element3, Element1
and that of the attributes is:
Attribute2, Attribute3, Attribute1

It must also be considered that elements/attributes not included in the sorting order are simply put under the sorted elements/attributes.

A mixed sorting of elements and attributes is not possible. First the attributes and then the elements will continue to be shown in the form.