I am using Sortables in my project in the following manner :
var draggedElement;
Sortable.create(''group_1'',{tag:''div'',dropOnEmpty:
true, containment:
[''group_2''],only:''lineitem'',onUpdate:
function(element) {
var htmlElement = element.innerHTML
if(htmlElement.indexOf(''Bitter'') != -1){
alert((draggedElement));
}}, onChange: function(ele){
draggedElement = ele;
}});
Sortable.create(''group_2'',{tag:''div'',dropOnEmpty:
true, containment:
[''group_1''],only:''lineitem''});
When I alert draggedElement, i get an instance of HTMLDivElement. I
want this draggable to revert back to its original place. Is there a
way to do that ?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Spinoffs" group.
To post to this group, send email to
rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs
-~----------~----~----~----~------~----~------~--~---