21
1
Fork 0
mirror of https://github.com/Evolix/chexpire.git synced 2024-05-14 06:28:38 +02:00
chexpire/app/views/checks/_table.html.erb

50 lines
1.7 KiB
Plaintext
Raw Normal View History

2018-07-04 12:33:50 +02:00
<div class="mb-4 table-responsive">
2018-07-05 12:26:57 +02:00
<table class="table checks-table">
2018-06-05 17:27:12 +02:00
<thead>
<tr>
<th scope="col"></th>
2018-07-03 20:11:52 +02:00
<th scope="col">
2018-07-05 09:54:29 +02:00
<%= t(".th.domain") %>
<span class="sort-links mx-sm-2 text-nowrap">
2018-07-04 12:33:50 +02:00
<%== checks_sort_links(:domain) %>
</span>
2018-07-03 20:11:52 +02:00
</th>
<th scope="col">
2018-07-05 09:54:29 +02:00
<span class="d-none d-sm-inline"><%= t(".th.expiry_date") %></span>
<span class="d-inline d-sm-none"><%= t(".th.expiry_date_short") %></span>
<span class="sort-links mx-sm-2 text-nowrap">
2018-07-04 12:33:50 +02:00
<%== checks_sort_links(:domain_expires_at) %>
</span>
2018-07-03 20:11:52 +02:00
</th>
2018-07-05 09:54:29 +02:00
<th scope="col" class="text-right"><%= t(".th.edit") %></th>
2018-06-05 17:27:12 +02:00
</tr>
</thead>
<tbody>
<% checks.each do |check| %>
<tr class="check-row <%= check_row_class(check) %>">
2018-07-04 19:05:52 +02:00
<td class="kind">
2018-07-04 12:33:50 +02:00
<span class="badge badge-info"><%= t(".kind_labels.#{check.kind}") %></span>
2018-07-05 09:54:29 +02:00
</td>
<td>
<%= check_error(check) if check_in_error?(check) %>
2018-06-05 17:27:12 +02:00
<strong><%= check.domain %></strong>
</td>
<td>
2018-07-04 12:33:50 +02:00
<% if check.domain_expires_at.present? %>
<%= content_tag :span, format_date(check.domain_expires_at), class: "d-none d-md-inline" %>
<%= content_tag :span, format_date(check.domain_expires_at, format: :short), class: "d-inline d-md-none" %>
<% end %>
2018-06-05 17:27:12 +02:00
</td>
2018-07-05 09:54:29 +02:00
<td class="action text-right">
<%= link_to edit_check_path(check), "data-turbolinks" => false do %>
2018-06-05 17:27:12 +02:00
<%== Octicons::Octicon.new("pencil").to_svg %>
<% end %>
</td>
</tr>
<% end %>
</tbody>
</table>
</div>
2018-07-03 19:46:15 +02:00
<%= paginate @checks %>