
<div class="card-header">              
  <strong>Batch List</strong> 
  <strong>(Count: <%= @count %> ) </strong>
</div>
<div class="card-block">
  <table class="table" style="border-top:none" id="myTable">
    <thead>
      <tr> 
        <th>Order Ref</th>       
        <th>Created By</th>            
        <th>Qty Processing</th>
        <th>Qty Success</th>                 
        <th>Qty Fail</th>   
        <th>Export Count</th> 
        <th>Exported By</th>                   
        <th>Created At</th>                            
      </tr>
    </thead>
    <tbody>                 
    <% @batches.each do |batch| %>
      <tr>                                             
        <td><%= batch.order_ref rescue '' %></td>                      
        <td><%= batch.user_name rescue '' %></td>  
        <td><%= batch.qty_processing rescue '' %></td> 
        <td><%= batch.qty_success rescue '' %></td> 
        <td><%= batch.qty_fail rescue '' %></td>     
        <td><%= batch.export_count %></td>    
        <td><%= batch.exported_by %></td>             
        <td><%= batch.created_at.strftime("%e,%b %Y %I:%M %p") rescue '' %></td>
      </tr>
    <% end %>
    </tbody>
  </table> 
  <%= paginate  @batches %>
</div>