text: 'use strict';
  var app = angular.module('angularApp')
    .controller('PublicationSampleInformationCtrl', function (navigationService, groupService, $rootScope, $scope, $http, $filter, $location, $routeParams) {
      $rootScope.tabs = navigationService.get();
      $rootScope.groups = groupService.getGroups.data.get();
  
      $scope.id = $routeParams.id;
      $scope.type = $routeParams.type;
      $scope.goBack = function () {
        $location.path("/searchSamplesByPublication").search({}).replace();
      };
  
  
      $scope.$on('$viewContentLoaded', function () {
        $scope.loader = true;
        $http({
          method: 'GET',
          url: '/caNanoLab/rest/publication/searchById?id=' + $scope.id + '&type=' + $scope.type
        }).
        then(function (data, status, headers, config) {
          data = data['data']
          $scope.data = data;
          $scope.loader = false;
  
        }).
        catch(function (data, status, headers, config) {
          data = data['data']
          // called asynchronously if an error occurs
          // or server returns response with an error status.
          $scope.message = data;
          $scope.loader = false;
  
        });
      });
  
    });