return defer.promise;
}
- // returns a promise resolved with the list of circ mods
+ // returns a promise resolved with the list of circ statuses
$scope.get_copy_statuses = function() {
- if (egCore.env.ccm)
+ if (egCore.env.ccs)
return $q.when(egCore.env.ccs.list);
return egCore.pcrud.retrieveAll('ccs', null, {atomic : true})
if ($scope.mode == 'checkin' && next_statuses.length > 0) {
$scope.get_copy_statuses().then(function() {
angular.forEach(next_statuses, function(st) {
- if (egCore.env.ccs.list[st])
- $scope.next_statuses.push(egCore.env.ccs.list[st]);
+ if (egCore.env.ccs.map[st])
+ $scope.next_statuses.push(egCore.env.ccs.map[st]);
});
$scope.params.the_next_status = $scope.next_statuses[0].id();
});