How to reorder accordion items?

The DnD documentation says reordering is possible on non-hierarchical widgets. Accordion items in accordion views aren’t hierarchical. How would I rearrange them? I tried placing drag:true and select:true in my accordion items and drag:“order” in the accordion view, but that didn’t work. I kind of expected that given that lists and data tables are qualitatively different kinds of data. But perhaps this is still fairly straightforward using another approach?

http://webix.com/snippet/41ff20ef

Even if accordion items can’t easily be dragged and dropped, can they be rearranged (e.g. swapping items) via buttons?

The documentation says nothing about this possibility. Basic DnD feature was made for dragging the data items (of the list, datatable or tree).

For these needs Webix Pro has a Portlet.

As for rearranging, there’s also no easy way to do such thing.
The method described here can totally redraw layouts, but before you need to save the old configuration.

And I guess that requires the getState and setState calls?

Could I embed an accordion in a portlet such that I could collapse the portlet and drag it to a different position?

get/setState will not work for the accordion. Rearranging with the mentioned method usually requires the predefined views.

Yes, you could, but the structure will be a bit different (I suppose your old snippet is suitable as the example):

http://webix.com/snippet/a4f439b7