Project

General

Profile

Download (1.05 KB) Statistics
| Branch: | Tag: | Revision:

foreman-docker / app / views / containers / index.html.erb @ 2402a763

1
<% title _("Containers") %>
2

    
3
<%= title_actions(new_link(_("New container"))) %>
4

    
5
<ul class="nav nav-tabs" data-tabs="tabs">
6
  <% @container_resources.each_with_index do |resource, i| %>
7
    <% if i == 0 %>
8
      <li class="active"><a href="#<%= "primary" %>" data-toggle="tab"><%= resource.name %></a></li>
9
    <% else %>
10
      <li><a href="#<%= resource.id %>" data-toggle="tab"><%= resource.name %></a></li>
11
    <% end %>
12
  <% end %>
13
</ul>
14

    
15
<div class="tab-content">
16
  <% @container_resources.each_with_index do |resource, i| %>
17
    <% if i == 0 %>
18
      <div class="tab-pane active" id="primary">
19
    <% else %>
20
      <div class="tab-pane" id="<%= resource.id %>">
21
    <% end %>
22
    <% if resource.test_connection %>
23
      <%= render 'list', :containers => resource.vms,
24
                 :resource           => resource %>
25
    <% else %>
26
      <div class="alert alert-warning">
27
        <%= (_("Error connecting with the compute resource: <strong> %s </strong>") % resource.errors.messages[:base]).html_safe %>
28
      </div>
29
    <% end %>
30
    </div>
31
  <% end %>
32
  </div>
33
</div>