search in batches
This commit is contained in:
36
app/views/batches/_search.html.erb
Normal file
36
app/views/batches/_search.html.erb
Normal file
@@ -0,0 +1,36 @@
|
||||
|
||||
<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>
|
||||
Reference in New Issue
Block a user