~ubuntu-branches/ubuntu/precise/horizon/precise-updates

« back to all changes in this revision

Viewing changes to horizon/horizon/dashboards/nova/templates/nova/instances/_list.html

  • Committer: Package Import Robot
  • Author(s): Chuck Short
  • Date: 2011-12-09 16:18:55 UTC
  • mfrom: (1.1.1)
  • Revision ID: package-import@ubuntu.com-20111209161855-nguyenpghx2o2lqy
Tags: 2012.1~e2~20111209.1104-0ubuntu1
* New upstream release.
* Refreshed patches.
* debian/docs: Removed README

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
<!-- TODO(termie): move most of this to horizon -->
2
2
{% load sizeformat %}
3
3
{% load i18n %}
4
 
<table id='instances' class="zebra-striped">
5
 
  <tr id='headings'>
6
 
    <th>{% trans "ID"%}</th>
7
 
    <th>{% trans "Name"%}</th>
8
 
    <th>{% trans "Groups"%}</th>
9
 
    <th>{% trans "Image"%}</th>
10
 
    <th>{% trans "Size"%}</th>
11
 
    <th>{% trans "IPs"%}</th>
12
 
    <th>{% trans "State"%}</th>
13
 
    <th>{% trans "Actions"%}</th>
14
 
  </tr>
15
 
  <tbody class='main'>
 
4
 
 
5
<div class="table_title">
 
6
  <h3>{% trans "My Instances" %}</h3>
 
7
  <div class="table_actions">
 
8
    <a class="btn small primary" href='{% url horizon:nova:images:index %}'>{% trans "Launch Instance" %}</a>
 
9
    <div class="instances table_search">
 
10
      <form action="#">
 
11
        <input class="span3" type="text">
 
12
      </form>
 
13
    </div>
 
14
    <a class="inspect" href="#">{% trans "inspect" %}</a>
 
15
  </div>
 
16
</div>
 
17
 
 
18
<table id='instances' class="zebra-striped sortable">
 
19
  <thead>
 
20
    <tr>
 
21
      <th></th>
 
22
      <th>{% trans "Name"%}</th>
 
23
      <th>{% trans "Size"%}</th>
 
24
      <th>{% trans "State"%}</th>
 
25
      <th>{% trans "Actions"%}</th>
 
26
    </tr>
 
27
  </thead>
 
28
  <tbody>
16
29
    {% for instance in instances %}
17
30
      <tr class="{% cycle 'odd' 'even' %}">
18
 
          <td>{{instance.id}}</td>
19
 
          <td class="name">
20
 
            <a href="{% url horizon:nova:instances:detail instance.id %}">
21
 
              {{instance.name}}
22
 
              {% if instance.attrs.key_name %}
23
 
                  <br/>
24
 
                  <small> ({{instance.attrs.key_name}}) </small>
25
 
              {% endif %}
26
 
            </a>
27
 
          </td>
28
 
          <td>
29
 
            <ul>
30
 
              {% for group in instance.attrs.security_groups %}
31
 
                <li>{{group}}</li>
32
 
              {% endfor %}
33
 
            <ul>
34
 
          </td>
35
 
          <td>{{instance.image_name}}</td>
36
 
          <td>
37
 
            <ul>
38
 
              <li>{{instance.attrs.memory_mb|mbformat}} Ram</li>
39
 
              <li>{{instance.attrs.vcpus}} VCPU</li>
40
 
              <li>{{instance.attrs.disk_gb}}GB Disk</li>
41
 
            </ul>
42
 
          </td>
43
 
          <td class="ip_list">
44
 
            {% for ip_group, addresses in instance.addresses.items %}
45
 
              {% if instance.addresses.items|length > 1 %}
46
 
              <h4>{{ip_group}}</h4>
47
 
              <ul>
48
 
                {% for address in addresses %}
49
 
                  <li>{{address.addr}}</li>
50
 
                {% endfor %}
51
 
              </ul>
52
 
              {% else %}
53
 
              <ul>
54
 
                {% for address in addresses %}
55
 
                  <li>{{address.addr}}</li>
56
 
                {% endfor %}
57
 
              </ul>
58
 
              {% endif %}
59
 
            {% endfor %}
60
 
          </td>
61
 
          <td>{{instance.status|lower|capfirst}}</td>
62
 
          <td id="actions">
63
 
            <ul>
64
 
              <li><a class="btn small" target="_blank" href="{% url horizon:nova:instances:console instance.id %}">{% trans "Log"%}</a></li>
65
 
              <li><a class="btn small" target="_blank" href="{% url horizon:nova:instances:vnc instance.id %}">{% trans "VNC Console"%}</a></li>
66
 
              <li><a class="btn small" href="{% url horizon:nova:instances:update instance.id %}">{% trans "Edit"%}</a></li>
67
 
              <li><a class="btn small" href="{% url horizon:nova:snapshots:create instance.id %}">{% trans "Snapshot"%}</a></li>
68
 
              <li class="form">{% include "nova/instances/_reboot.html" with form=reboot_form %}</li>
69
 
              <li class="form">{% include "nova/instances/_terminate.html" with form=terminate_form %}</li>
70
 
            </ul>
 
31
        <td class="select">
 
32
          <input type="checkbox" name="instance_{{instance.id}}" value="instance_{{instance.id}}" id="instance_select_{{instance.id}}" />
 
33
        </td>
 
34
        <td class="name">
 
35
          <a href="{% url horizon:nova:instances:detail instance.id %}">{{instance.name}}</a>
 
36
        </td>
 
37
        <td>
 
38
          {{instance.attrs.memory_mb|mbformat}} Ram | {{instance.attrs.vcpus}} VCPU | {{instance.attrs.disk_gb}}GB Disk
 
39
        </td>
 
40
        <td>{{instance.status|lower|capfirst}}</td>
 
41
        <td id="name_{{instance.name}}" class="actions">
 
42
          <a class="more-actions" href="#">View</a>
 
43
          <ul>
 
44
            <li><a class="btn small" target='_blank' href='{% url horizon:nova:instances:vnc instance.id %}'>{% trans 'VNC Console'%}</a></li>
 
45
            <li><a class='btn small' target='_blank' href='{% url horizon:nova:instances:console instance.id %}'>{% trans 'Log'%}</a></li>
 
46
            <li><a class='btn small' href='{% url horizon:nova:instances:update instance.id %}'>{% trans 'Edit'%}</a></li>
 
47
            <li><a class='btn small' href='{% url horizon:nova:snapshots:create instance.id %}'>{% trans 'Snapshot'%}</a></li>
 
48
            <li>{% include 'nova/instances/_reboot.html' with form=reboot_form %}</li>
 
49
            <li>{% include 'nova/instances/_terminate.html' with form=terminate_form %}</li>
 
50
          </ul>
71
51
        </td>
72
52
      </tr>
73
53
    {% endfor %}