Angularjs 可排序上的角度重新三角形,如何保存?

Angularjs 可排序上的角度重新三角形,如何保存?,angularjs,restangular,ng-sortable,Angularjs,Restangular,Ng Sortable,我需要更改作用域的顺序,保存,但返回一个错误,即save()不是函数 我正在使用Restanglar创建对象 该函数是在排序时触发的,我尝试使用http,但也给出了错误消息 $scope.onChange = function() { ApiRestangular.all($scope.section).getList($scope.query).then(function(res){ $scope.items = res; or

我需要更改作用域的顺序,保存,但返回一个错误,即save()不是函数

我正在使用Restanglar创建对象

该函数是在排序时触发的,我尝试使用http,但也给出了错误消息

$scope.onChange = function() {
        ApiRestangular.all($scope.section).getList($scope.query).then(function(res){
            $scope.items = res;

            order = ApiRestangular.copy(res);

            console.log(order);

            $scope.sortOptions = {
                animation   : 150,
                onSort: function(){
                    order.put().then(function(){
                        toast.msgToast($scope.section+ ' ...Ordem atualizada!');
                    });
                }
            };
        });
    };

如果没有更具体的详细信息,例如错误是什么以及排序是如何完成的,将无法获得更多帮助。peerror:$scope.items.save不是函数行300