When attempting to use draggable functionality in views to show taxonomy terms it seems that it's not allowed to save order after dragging and dropping the taxonomy terms.
(I use drupal 8.3.3)
You can replicate this problem by:
- install draggableviews module 8.x-1.0
- Create a view that allows drag & drop re-ordering with draggable views
- Set the view settings to show: Taxonomy terms of type: Taxonomy term type
- Set the view display settings to Display format: table
- Visit the view
- add a "Draggableviews: Taxonomy term" field to the created view.
- add a sort criteria: Taxonomy term: Weight (asc)
- save changes
- visit a page showing the mentioned view.
- try to drag and drop any terms and click save order.
- the changes are not saved
However, it works fine when showing nodes instead of taxonomy terms!
When adding a "Draggableviews: Content" field to the created view it's suggested to choose available actions.

But the "selected actions" fieldset is empty when adding a "Draggableviews: Taxonomy term" field

And I guess it might be causes that it's not allowed to save order when using taxonomy terms in the view.
Any help would be appreciated. Thank you!
| Comment | File | Size | Author |
|---|---|---|---|
| Draggableviews Taxonomy term.png | 42.27 KB | ygstnd | |
| Draggableviews Content.png | 48.23 KB | ygstnd |
Comments
Comment #2
ygstnd commentedComment #3
ygstnd commentedComment #4
seemas commentedSame for me when using drupal/eck-8.x-1.0-alpha3 and trying to sort custom bundles.
Comment #5
fox mulder commentedSame here: simplytest.me ( drupal 8; entity_construction_kit; draggableviews )
Notice: Undefined index: title in draggableviews_preprocess_views_view_table() (line 79 of /home/d2wo0/www/modules/draggableviews/draggableviews.module)
It seems, reordering the fields in view solves the problem: if the Draggableviews: ENTITY_TYPE is NOT the first field, than it works
Comment #6
ygstnd commentedThe module works fine. It looks like draggableviews module doesn't change a weight of terms within a `taxonomy_term_field_data` table. Instead it sets entities weight within a `draggableviews_structure` table.


So we should sort terms by ‘Global: DraggableViews Weight’ within a view
rather than by ‘Taxonomy term: Weight’
Comment #7
ygstnd commented