title: How to sort data in between two date using Angular.js?
body: <p>I need to filter table data selecting two dates using Angular.js. My code below:</p>
  
  <pre><code> &lt;div class="col-md-3"&gt;
  &lt;div class="input-group datepicker" date-format="yyyy-MM-dd" button-prev='&lt;i class="fa fa-arrow-circle-left"&gt;&lt;/i&gt;' button-next='&lt;i class="fa fa-arrow-circle-right"&gt;&lt;/i&gt;'&gt; 
  &lt;input type="text" name="birthdate" class="form-control" id="date" ng-model="date" placeholder="From date" /&gt;
   &lt;span class="input-group-addon"&gt;&lt;i class="fa fa-calendar"&gt;&lt;/i&gt;&lt;/span&gt;
   &lt;/div&gt;
   &lt;/div&gt;
  &lt;div class="col-md-3"&gt;
      &lt;div class=" input-group datepicker" date-format="yyyy-MM-dd" button-prev='&lt;i class="fa fa-arrow-circle-left"&gt;&lt;/i&gt;' button-next='&lt;i class="fa fa-arrow-circle-right"&gt;&lt;/i&gt;'&gt; 
       &lt;input type="text" name="birthdate" class="form-control" id="date" ng-model="date1" placeholder="To date" /&gt;
      &lt;span class="input-group-addon"&gt;&lt;i class="fa fa-calendar"&gt;&lt;/i&gt;&lt;/span&gt;
      &lt;/div&gt;
   &lt;/div&gt;
  &lt;tbody id="detailsstockid"&gt;
   &lt;tr ng-repeat="d in clickDetail"&gt;
   &lt;td&gt;{{$index+1}}&lt;/td&gt;
   &lt;td&gt;{{d.rest_name}}&lt;/td&gt;
   &lt;td&gt;{{d.Android}}&lt;/td&gt;
   &lt;td&gt;{{d.IOS}}&lt;/td&gt;
   &lt;td&gt;{{d.resultant_counter}}&lt;/td&gt;
   &lt;td&gt;{{d.date}}&lt;/td&gt;
  &lt;/tr&gt;   
  &lt;/tbody&gt;
  </code></pre>
  
  <p>Here I have two <code>datepicker</code> fields. When user will select <code>From date</code> and <code>To date</code> the record will filter data in between these two date including these dates also. Here I have also <code>d.date</code> which contains value like this <code>2016-05-21 15:15:44</code> from DB. As per this value I need to sort the table data.</p>