I want to build a hierarchy of sorts with a sortable list -- nothing fancy, just nudge each element of to the right a bit, so it clearly shows the hierarchy.
Has anyone seen a technique for this? I thought about it for a minute and thought that if I initially draw the list, I could just bump the left margin a bit for each
But then I realized that I wouldn't know how to handle renumbering on sort... I guess I could call a function on STOP and change the margin left 开发者_如何学运维to each element... (did I just answer my own question?)
Regardless, does anyone know of an existing answer to this? I would think someone would have already done this.
Two options:
Nestable - http://dbushell.com/2012/06/17/nestable-jquery-plugin/
nestedSortable - http://mjsarfatti.com/sandbox/nestedSortable/
Either one should do exactly what you need.
精彩评论