I drag the new item into the sorted list, but when I call ui.item, it points to the original object. How can I get a link to a new fallen object?
Link to the same issue on the jQuery forum:
http://forum.jquery.com/topic/sortable-receive-how-do-i-get-new-item
You can use update instead of getting to get the handle of the newly dropped object.
, . , ( ).
jQuery UI 1.10 :
$('#sortable-list').sortable({ receive: function (event, ui) { // New item var droppedItem = $(this).data().uiSortable.currentItem; } });