First of all let me tell you that I'm a beginner on html/js developing.
Using angular-ui to permit sorting a list (ul), when performing SOME actions the array looses synchronization with the list.
Starting with :
$scope.list = ["one", "two", "three", "four"];
and the html:
<ul ui:sortable ng:model="list">
<li ng:repeat="item in list" class="item">{{item}}</li>
</ul>
When I drag (example) the first li element between second and third it changes place inside ul, yet the bounded item remains in same position in list array.
>angular.element($(".ng-scope")).scope().list
["one", "two", "three", "four"];
I've created an jsfiddle and that behaviour can be tested : http://jsfiddle.net/DmLt2/
Other strange behaviors can be observed if we play a little bit with it.
JQuery 1.9.1, JQueryUI 1.10.3, Angular 1.2.2, AngularUI 0.4.0
Meanwhile, I've found online an jQuery UI Sortable plugin wrapper. With minor changes I've managed to put it working here : http://jsfiddle.net/42VCK/
Yet its required to remove the reference to AngularUI or change the module name.
Can anyone give me some help to put this working ?