This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

douglas14166
douglas14166

It would be great if the 'List' Widget supported drag-and-drop reordering, without having to load a seperate 'Reorder' widget. This would be particularly useful for reordering related records in a partial, which is currently quite difficult to impliment. This would also solve the current problem with the list widget which occurs when search is used on a tree list, which automatically switches to a flat column sorted view, and there is no way to return to the tree view. Here are some thoughts on how this might work:

  • Provide a button to toggle bweteen a column sort view ('columns view') and structure sort view ('structure view'). This button could perhaps be integrated with or placed next to the current 'show columns' settings button.

  • Structure view:

    • indent rows according to level in the heirarchy (like is currently done in with 'showTree')
    • provide drag controls on each row to drag-and-drop reorder rows (much like the current reorder widget)
    • provide open-close node controls (like is currently done in with 'showTree')
    • show all columns that are available in the 'column' view (as set by the show columns modal selection window).
  • Column view:

    • essentially the same functionality as the current list widget (sort by column, etc)
    • rows obviously not reorderable in this view
  • Add addtional options to the list config:
    • 'showTree' would enable the 'structure' view option toggle
    • 'rorderable' boolean would enable the 'reorderable' functionality
    • 'maxLevels' would limit the maximum heirarchy depth (defaults to 1, for no hierarchy)
      • Note: Don't know if this flag should also indicate using 'sort_order' field instead of 'nest_left', 'nest_right', etc. Appreciate recommendations.

I have seen this implimented quite nicely in other CMS systems, and can point to examples if needed.

1-1 of 1

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.