Opened 15 years ago
Closed 15 years ago
#2347 closed bug (wontfix)
Sortable : callback called before sort really stop
Reported by: | Nodashi | Owned by: | paul |
---|---|---|---|
Priority: | major | Milestone: | 1.2.4 |
Component: | ui | Version: | 1.2.3 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
If you want to use a callback function when the sort stop/update this callback function is called before the sort stop. So you have a "ghost" of the element you want to move.
In my case i sort div elements that contains hidden input.
You can use this callback function to show the problem :
fonction(e, ui){ $('div.sortable input[class="order"]').each(function(i){ alert($(this).attr('name')); } ) }
however if you use console.log whith firebug you will not see this "ghost" element
Change History (2)
comment:1 Changed 15 years ago by
comment:2 Changed 15 years ago by
Resolution: | → wontfix |
---|---|
Status: | new → closed |
This is needed because some people want to still track changes on the helper in that callback. However, it's easy to filter out that element, because it has a helper class named 'ui-sortable-helper' assigned to it. So you could do
$('div.sortable input[class="order"]').not('.ui-sortable.helper')
I forgot i use the 1.5b version of UI ;)