Project

General

Profile

Download (1.48 KB) Statistics
| Branch: | Tag: | Revision:
<% title _("Smart variables") %>
<% title_actions documentation_button('4.2.4SmartVariables') %>
<table class="table table-bordered table-striped table-two-pane table-fixed">
<thead>
<tr>
<th class="col-md-5"><%= sort :key, :as => _("Variable") %></th>
<th class="col-md-4"><%= sort :puppetclass, :as => _("Puppetclass") %></th>
<th class="col-md-2"><%= sort :values_count, :as => _('Number of overrides'), :default => "DESC" %></th>
<th><%= _('Actions') %></th>
</tr>
</thead>
<tbody>
<% @lookup_keys.each do |lookup_key| %>
<tr>
<td class="display-two-pane ellipsis"><%= link_to_if_authorized lookup_key.key, hash_for_edit_variable_lookup_key_path(:id => lookup_key).merge(:auth_object => lookup_key, :permission => 'edit_external_variables', :authorizer => authorizer) %></td>
<td class="ellipsis"><%= link_to_if_authorized lookup_key.puppetclass, hash_for_edit_puppetclass_path(:id => lookup_key.puppetclass).merge(:auth_object => lookup_key.puppetclass, :authorizer => @puppetclass_authorizer) %></td>
<td><%=h lookup_key.lookup_values_count %></td>
<td><%= action_buttons(display_delete_if_authorized hash_for_variable_lookup_key_path(:id => lookup_key).merge(:auth_object => lookup_key, :permission => 'destroy_external_variables', :authorizer => authorizer),
:data => { :confirm => _("Delete %s?") % lookup_key.key }) %></td>
</tr>
<% end %>
</tbody>
</table>
<%= will_paginate_with_info @lookup_keys %>
(2-2/2)