title: How to sort and filter ngTable date (milliseconds) data?
body: <p>I am pretty new to Angularjs need some help with sorting date in milliseconds in descending order as well as a filter for the table columns. I created a <a href="http://plnkr.co/edit/wMjvzLXDF6G8tVQBB7Cx?p=preview" rel="nofollow">plunker here</a> but when I key in some filter param I do not see any filtered data and the data is lost from table. </p>
  
  <p>Please help me in sorting date column and doing a case insensitive filter search, below I am providing my code.</p>
  
  <pre><code>&lt;table ng-table="tableParams" show-filter="true" class="table" &gt;
    &lt;tr ng-repeat="item in $data" height="10px"&gt;
      &lt;td data-title="'Date'" filter="{ 'item[0]': 'date' }" sortable="'item[0]'"&gt;{{translate(item[0])}}&lt;/td&gt;
      &lt;td data-title="'Count'" filter="{ 'item[1]': 'text' }" sortable="'item[1]'"&gt;{{item[1]}}&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/table&gt;
  
  $scope.translate = function(value) {
      if (value == null || value == undefined)
          return value;
      var monthNames = [ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" ];
      var myDate = new Date( value );
      return myDate.getDate() + " " + monthNames[myDate.getMonth()] + " "+myDate.getFullYear();
  }
  $scope.tableParams = new ngTableParams({
      page: 1,            // show first page
      count: 10          // count per page        
  }, {
      total: $scope.tasksRunDataForTable.length, // length of data
      getData: function($defer, params) {
          // use build-in angular filter
          var sortedData = params.sorting() ?
                              $filter('orderBy')($scope.tasksRunDataForTable, params.orderBy()) :
                              $scope.tasksRunDataForTable;
          var orderedData = params.filter() ?
                 $filter('filter')(sortedData, params.filter()) :
                 sortedData;
          params.total(orderedData.length); // set total for recalc pagination
          $defer.resolve(orderedData.slice((params.page() - 1) * params.count(), params.page() * params.count()));
      }
  });
  </code></pre>
  
  <p><strong>Update</strong></p>
  
  <p>I am able to get filter work on count, but no luck with date and sorting on both columns. <a href="http://plnkr.co/edit/wMjvzLXDF6G8tVQBB7Cx?p=preview" rel="nofollow">Updated plunker</a></p>
  
  <pre><code>&lt;td data-title="'Count'" filter="{ '1': 'text' }" sortable="'1'"&gt;{{item[1]}}&lt;/td&gt;
  </code></pre>