LiteSortable

LiteSortable is a javascript library based on prototype and scriptaculous.

new LiteSortable(element, options) works exactly like the Sortable.create method of scriptaculous, but it passes more arguments to the onChange and onUpdate callbacks. In particular, the onChange callback receives 4 parameters:

  1. the dragged element
  2. the model id
  3. the dragged element old position
  4. the dragged element current position

It’s similar for the onUpdate callback. The parameters are:

  1. the list element
  2. the dragged element
  3. the model id
  4. the dragged element old position
  5. the dragged element current position

With this informations you can send to your serverside application only the effective changes of your list, without sending all the serialized

Check out the project with:

svn co http://dev.gravityblast.com/svn/projects/js/LiteSortable/