angular-ui-sortable

angular ui sortable callback

混江龙づ霸主 提交于 2019-12-03 13:46:16
Is there a way to set a callback function with angular ui's sortable? I'd like to add ng-update="foo()" to the tbody tag below and have foo run whenever the list changes. <tbody id="existingStockResults" ui-sortable ng-model="processes"> <tr ng-repeat="process in processes" ng-class="{odd: $index%2 == 0, even: $index%2 != 0}"> <td>{{process.process}}</td> <td>{{process.vendor}}</td> <td>{{process.desc}}</td> <td>{{process.cost}}</td> <td><a href="#" ng-click="editProcess($index)">edit</a></td> <td><a href="#" ng-click="removeProcess($index)">remove</a></td> </tr> </tbody> thanks! You can now