Question

I'm using AngularJS in a simple prototype app that uses Domino server on the back end.

When I do a seemingly simple call like this:

$http({ url: $scope.hrEventsPath, 
        method : "GET", 
        params : { 'readform' : '',
                   'eventid' : $scope.queryStringPairs.eventid,
                   'userid' : $scope.queryStringPairs.userid,
                   'login' : $scope.queryStringPairs.login } }).
            success(function(data, status) {
                // happy stuff
            }).
            error(function(data, status) {
                // error handling stuff
            });

It seems that Angular puts all the params in alphabetical order when the call is made.

Therefore, the readform parameter is not the first parameter, eventid is, and the Domino server chokes. (This happens whether or not 'readform' has a value)

Regardless of Domino and its configuration, is there a way to for a sort the order in Angularm or should one use another approach?

Thanks in advance.

Was it helpful?

Solution

Use an array of single objects, then the object won't have a chance to switch itself around.

[ {}, {}, {} ]
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top