Project

General

Profile

« Previous | Next » 

Revision 82e47ae0

Added by Amos Benari about 12 years ago

  • ID 82e47ae0f86994702c3a084cc6150250a81034ee

updates UI to bootstrap v2

View differences:

app/views/hypervisors/index.html.erb
<% title_actions display_link_if_authorized("New Hypervisor", hash_for_new_hypervisor_path) %>
<table class="list">
<table class="table table-bordered table-striped">
<tr>
<th>Name</th>
<th>Uri</th>
......
<th></th>
</tr>
<% for hypervisor in @hypervisors %>
<tr class="<%= cycle("even", "odd") -%>">
<tr>
<td><%=link_to_if_authorized h(hypervisor), hash_for_hypervisor_path(:id => hypervisor.name) %></td>
<td><%=h hypervisor.uri %></td>
<td><%=h hypervisor.kind %></td>
<td>
<%= display_link_if_authorized "Guests", hash_for_hypervisor_guests_path(:hypervisor_id => hypervisor.name) %>
<%= display_link_if_authorized "Edit", hash_for_edit_hypervisor_path(:id => hypervisor.name) %>
<%= display_link_if_authorized "Delete", hash_for_hypervisor_path(:id => hypervisor.name, :auth_action => :destroy), :confirm => "Delete #{hypervisor.name}?", :method => :delete %>
<%= action_buttons(
display_link_if_authorized("Guests", hash_for_hypervisor_guests_path(:hypervisor_id => hypervisor.name), :class=>"btn btn-small"),
display_link_if_authorized("Edit", hash_for_edit_hypervisor_path(:id => hypervisor.name)),
display_delete_if_authorized(hash_for_hypervisor_path(:id => hypervisor.name), :confirm => "Delete #{hypervisor.name}?"))%>
</td>
</tr>
<% end %>

Also available in: Unified diff