title: Pagination controls not showing up in ng-table when fetching data from backend
body: <p>I am fetching a list of data from the backend and displaying it using ng-table. The problem is that its not showing the pagination controls. Previously, when I used dummy data to show the ng-table, pagination was working totally fine. Could someone help me out here?</p>
  
  <p>This is my HTML: </p>
  
  <pre><code>&lt;table ng-table="tableParams" show-filter="true" class="table"&gt;
              &lt;thead&gt;
                      &lt;tr&gt;
                              &lt;th ng-repeat="column in columns" ng-show="column.visible"
                                      class="text-center" ng-class="{
                                      'sort-asc': tableParams.isSortBy(column.field, 'asc'),
                                      'sort-desc': tableParams.isSortBy(column.field, 'desc'),
                                      'sortable': !$first
                                      }"
                                      ng-click="tableParams.sorting(column.field, tableParams.isSortBy(column.field, 'asc') ? 'desc' : 'asc')"&gt;
                                      &lt;div&gt;{{column.title}}&lt;/div&gt;
                              &lt;/th&gt;
                      &lt;/tr&gt;
  
              &lt;/thead&gt;
              &lt;tr ng-repeat="user in data | filter:searchText"&gt;
  
                      &lt;td width="30" style="text-align: left"&gt;
                              &lt;input type="checkbox" ng-model="checkboxes.items[user.id]" /&gt;
                      &lt;/td&gt;
  
                      &lt;td data-title="'Email Id'" class="text-center" sortable="email" ng-show="columns[1].visible"&gt;
                              &lt;span&gt;{{user.email}}&lt;/span&gt;
                      &lt;/td&gt;
                      &lt;td data-title="'User Karma'" class="text-center" sortable="userkarma" ng-show="columns[2].visible"&gt;
                              &lt;span&gt;{{user.userkarma}}&lt;/span&gt;
                      &lt;/td&gt;
                      &lt;td data-title="'Date Joined'" class="text-center" sortable="datejoined" ng-show="columns[3].visible"&gt;
                              &lt;span&gt;{{user.datejoined}}&lt;/span&gt;
                      &lt;/td&gt;
                      &lt;td data-title="'Unsubscribed'" class="text-center" sortable="status" ng-show="columns[4].visible"&gt;
                              &lt;span&gt;{{user.unsubscribed}}&lt;/span&gt;
                      &lt;/td&gt;
              &lt;/tr&gt;
          &lt;/table&gt;
  </code></pre>
  
  <p>Below is my js file: </p>
  
  <pre><code>for (var i = 0; i &lt; UserList.getUsers()
              .length; i++) {
              $scope.data.push({
                  id: UserList.getUsers()[i]._id,
                  email: UserList.getUsers()[i].email,
                  userkarma: UserList.getUsers()[i].healthScore,
                  datejoined: moment(UserList.getUsers()[i].firstSessionAt)
                      .format("MMMM Do YYYY"),
                  unsubscribed: UserList.getUsers()[i].unsubscribed
              })
          };
          $scope.columns = [{
                  title: '',
                  field: 'checkbox',
                  visible: true
              },
              {
                  title: 'Email',
                  field: 'email',
                  visible: true
              }, {
                  title: 'User Karma',
                  field: 'userkarma',
                  visible: true
              }, {
                  title: 'Date Joined',
                  field: 'datejoined',
                  visible: true
              }, {
                  title: 'Unsubscribed',
                  field: 'unsubscribed',
                  visible: true
              }
          ];
  
          $scope.tableParams = new ngTableParams({
              page: 1, 
                  count: 10, // count per page
                  filter: {
                      name: 'M' // initial filter
                  },
                  sorting: {
                      name: 'asc'
                  }
              }, {
                  total: $scope.data.length, // length of data
                  getData: function ($defer, params) {
                      // use build-in angular filter
                      var filteredData = params.filter() ?
                          $filter('filter')($scope.data, params
                              .filter()) :
                          data;
                      var orderedData = params.sorting() ?
                          $filter('orderBy')($scope.data,
                              params.orderBy()) :
                          $scope.data;
                      params.total(orderedData.length); // set total for recalc paginationemail
  
                      $defer.resolve(orderedData.slice((
                              params.page() -
                              1) * params.count(),
                          params.page() *
                          params.count()));
                  }
              });
  </code></pre>