foreman/app/views/hosts/_list.html.erb @ 2aceb9a0
078fbb59 | Ohad Levy | <%= javascript "jquery.cookie", "host_checkbox" %>
|
|
1a51088d | Ohad Levy | <% title header ||= "" %>
|
|
<table class="list">
|
|||
<tr>
|
|||
4ebe38c7 | Ohad Levy | <th><%= check_box_tag "check_all", "", false, { :onclick => "toggleCheck()", :title => "Select All" } %></th>
|
|
1a51088d | Ohad Levy | <th><%= sort :name %></th>
|
|
<th><%= sort :os, :as => "Operating system" %></th>
|
|||
<th><%= sort :environment %></th>
|
|||
<th><%= sort :model %></th>
|
|||
<th><%= sort :hostgroup, :as => "Host Group" %></th>
|
|||
<th><%= sort :last_report %></th>
|
|||
<th></th>
|
|||
</tr>
|
|||
<% hosts.each do |host| -%>
|
|||
<tr class="<%= cycle("even", "odd") -%>">
|
|||
<td>
|
|||
078fbb59 | Ohad Levy | <%= check_box_tag "host_ids[]", nil, false, :id => "host_ids_#{host.id}", :disabled => !authorized?, :class => 'host_select_boxes', :onclick => 'hostChecked(this)' -%>
|
|
1a51088d | Ohad Levy | </td>
|
|
4ebe38c7 | Ohad Levy | <td> <%= name_column(host) %> </td>
|
|
<td><%= icon(host.os, :size => "18x18", :title => host.os.to_s) + " " + host.os.to_s if host.os %></td>
|
|||
<td><%= h host.try(:environment) %></td>
|
|||
<td><%= h host.try(:model) %></td>
|
|||
4d4b84f6 | Ohad Levy | <td><%= hostgroup_name host.hostgroup %></td>
|
|
4ebe38c7 | Ohad Levy | <td><%= last_report_column(host) %></td>
|
|
<td>
|
|||
<%= display_link_if_authorized 'Edit', hash_for_edit_host_path(:id => host) %>
|
|||
<%= display_link_if_authorized 'Clone', hash_for_clone_host_path(:id => host) %>
|
|||
2aceb9a0 | Marcello de Sousa | <%= display_link_if_authorized 'Delete', hash_for_host_path(:id => host, :auth_action => :destroy), :confirm => "Delete #{host.name}?", :method => :delete, :action => :destroy %>
|
|
4ebe38c7 | Ohad Levy | </td>
|
|
</tr>
|
|||
<% end -%>
|
|||
1a51088d | Ohad Levy | </table>
|
|
2e04e41b | Ohad Levy | <%= page_entries_info hosts %>
|
|
078fbb59 | Ohad Levy | <%= will_paginate hosts %><strong><span class="select_count">0</span></strong> Selected
|