Revision ad3852f2
Added by Ohad Levy over 8 years ago
app/views/containers/index.html.erb | ||
---|---|---|
2 | 2 |
|
3 | 3 |
<% if authorized? %> |
4 | 4 |
<% title_actions button_group(link_to_if_authorized _("New container"), hash_for_new_container_path, |
5 |
:class => 'btn-success' ) %>
|
|
5 |
:class => 'btn-success') %>
|
|
6 | 6 |
<% end %> |
7 | 7 |
|
8 | 8 |
<ul class="nav nav-tabs" data-tabs="tabs"> |
... | ... | |
23 | 23 |
<div class="tab-pane" id="<%= resource.name %>"> |
24 | 24 |
<% end %> |
25 | 25 |
<% if resource.test_connection %> |
26 |
<%= render 'list', :containers => resource.vms.to_a |
|
27 |
.sort_by(&:name).paginate(:page => params[:page], |
|
28 |
:per_page => 10), |
|
29 |
:resource => resource %> |
|
26 |
<%= render 'list', :containers => resource.vms, |
|
27 |
:resource => resource %> |
|
30 | 28 |
<% else %> |
31 | 29 |
<div class="alert alert-warning"> |
32 | 30 |
<%= (_("Error connecting with the compute resource: <strong> %s </strong>") % resource.errors.messages[:base]).html_safe %> |
33 | 31 |
</div> |
34 |
<% end%> |
|
32 |
<% end %>
|
|
35 | 33 |
</div> |
36 | 34 |
<% end %> |
37 |
</div> |
|
35 |
</div> |
|
36 |
</div> |
Also available in: Unified diff
fixes #8718 - refactor container index
- simplify controller to use the correct compute resource type in sql
- used icon helper methods
- fixed html syntax + removed duplicate pagination