1angular.module('raentApp').controller('PublicationViewController', function ($scope, $http, $interval, $log, $location, $routeParams, $modal) { 2 3 'use strict'; 4 5 6 7 $scope.data = {}; 8 $scope.data.currentPage = 1; 9 $scope.size = 10; 10 $scope.total = 0; 11 $scope.data.selectAuthor = false; 12 13 $scope.errorMessage = null; 14 15 $scope.sortBy = 'lastName'; 16 $scope.sortOrder = 'ASC'; 17 18 $scope.pageLabel = 'Neue Publikation anlegen'; 19 20 $scope.data.filterFirstName = ''; 21 $scope.data.filterLastName = ''; 22 23 24 $http.get('api/publications/types' ).success(function(types){$scope.types = types;}); 25 $http.get('api/publications/platforms' ).success(function(platforms){$scope.platforms = platforms;}); 26 27 update(); 28 29 $scope.refresh = function() 30 { 31 update(); 32 } 33 34 function update() 35 { 36 $http.get('api/authors/search', {params:{page:$scope.data.currentPage - 1, size:$scope.size, sortBy:$scope.sortBy, sortOrder:$scope.sortOrder, firstName:$scope.data.filterFirstName, lastName:$scope.data.filterLastName}}).success(function(authors) 37 { 38 $scope.data.currentPage=authors.number + 1; 39 $scope.authors = authors.content; 40 $scope.total = authors.totalElements; 41 }); 42 } 43 44 45 if ($routeParams.id !== undefined) { 46 if ($routeParams.id == -1) 47 { 48 $scope.pub = new Object(); 49 $scope.pub.authors = new Object(); 50 } 51 else 52 { 53 $http.get('api/publications/' + $routeParams.id ).success(function(pub){$scope.pub = pub;}); 54 } 55 } 56 57 58 $scope.pageChanged = function() { 59 update(); 60 }; 61});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.