mirror of
https://github.com/internetee/registry.git
synced 2025-08-04 08:52:04 +02:00
47 lines
1.5 KiB
Text
47 lines
1.5 KiB
Text
<div class="page-header">
|
|
<div class="row">
|
|
<div class="col-sm-10">
|
|
<h1><%= t '.title' %></h1>
|
|
</div>
|
|
|
|
<div class="col-sm-2 text-right">
|
|
<%= link_to t('.new_btn'), new_admin_price_path, class: 'btn btn-primary' %>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<%= render 'search_form', search: @search %>
|
|
|
|
<% if @prices.present? %>
|
|
<table class="table table-hover table-bordered table-wrapped">
|
|
<thead>
|
|
<tr>
|
|
<th><%= sort_link(@q, 'zone_id', DNS::Zone.model_name.human) %></th>
|
|
<th><%= sort_link(@q, 'duration', ::Billing::Price.human_attribute_name(:duration)) %></th>
|
|
<th><%= sort_link(@q, 'operation_category', ::Billing::Price.human_attribute_name(:operation)) %></th>
|
|
<th><%= sort_link(@q, 'price', t(:price)) %></th>
|
|
<th><%= sort_link(@q, 'valid_from', t(:valid_from)) %></th>
|
|
<th><%= sort_link(@q, 'valid_to', t(:valid_to)) %></th>
|
|
</tr>
|
|
</thead>
|
|
|
|
<tbody>
|
|
<% @prices.each do |price| %>
|
|
<%= render 'price', price: price %>
|
|
<% end %>
|
|
</tbody>
|
|
</table>
|
|
|
|
<div class="row">
|
|
<div class="col-md-6">
|
|
<%= paginate @prices %>
|
|
</div>
|
|
<div class="col-md-6 text-right">
|
|
<div class="pagination">
|
|
<%= t(:result_count, count: @count) %>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<% else %>
|
|
<div class="alert alert-info"><%= t '.not_found' %></div>
|
|
<% end %>
|