开发者

jQuery sortable live() not sorting

开发者 https://www.devze.com 2023-03-08 21:26 出处:网络
Please see this link here: http://jsfiddle.net/CK9uL/129/ I\'m trying to drag items from the right into an itinerary on the left. When I add 3 or more items to one time slot (e.g. Afternoon) I cannot

Please see this link here: http://jsfiddle.net/CK9uL/129/

I'm trying to drag items from the right into an itinerary on the left. When I add 3 or more items to one time slot (e.g. Afternoon) I cannot sort the items. 开发者_开发知识库I've tried using .sortable('refresh') but haven't had any luck.


You need to disable the "draggable" after a drop:

// set up droppable
item.droppable({
    drop: function(e, ui) {
        ui.draggable.appendTo($(this).find('ul')).draggable('disable');
    }
});

It's saved as revision 131 of your fiddle :-)

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号