I've got a bit closer: I found that the Fields component uses sortable subform, so at least I know that this is somehow possible to do
I dissected the page source, and I can see that the subform wrapper has an attribute "ui-sortable":
Code: Select all
<div class="subform-repeatable ui-sortable" data-bt-add="a.group-add-sr-0" data-bt-remove="a.group-remove-sr-0" data-bt-move="a.group-move-sr-0" data-repeatable-element="div.subform-repeatable-group-sr-0" data-minimum="0" data-maximum="1000">
which is missing in my subform:
Code: Select all
<div class="subform-repeatable" data-bt-add="a.group-add-sr-1" data-bt-remove="a.group-remove-sr-1" data-bt-move="a.group-move-sr-1" data-repeatable-element="div.subform-repeatable-group-sr-1" data-minimum="0" data-maximum="1000">
So there's some 'magic' that adds this to the code.
Also, I don't think this subform uses jQuery Sortable: I'd usually expect to see entries in the web server log as the list item dragging and dropping fires the sort order saving Ajax calls, but this seems to be just a UI feature in the subform case.
I'll keep investigating - if anyone has managed to work out how to use this you could save me lots of grey hairs
David