title: how to set pagination last-page ui-bootstrap in the controller?
body: <p>how can i force the last page in pagination ui-bootstrap after running a function in the controller ? </p>
  
  <p>my idea is to create a new element and show it once is created by setting the pagination in the last page, like this.</p>
  
  <pre><code>// create new product 
  $scope.createElement = function(){
      $scope.crear = "2";
  
      // fields in key-value pairs
      $http.post('procesos/administradorcontroler.php', {
              'element' : $scope.banco,
              'action' : $scope.crear
          }
      ).success(function (data, status, headers, config) {
  
  
  
          // refresh the list
          $scope.getAll();
  
         //go to last element created
         $scope.goLastPage();
  
      });
  </code></pre>