index-nodes.html 3.76 KB
Newer Older
1
{% load i18n %}
2
  <div class="panel panel-default">
3 4 5
  <div class="panel-heading">
    <div class="pull-right toolbar">
      <div class="btn-group">
6 7 8 9
        <a href="#index-graph-view" data-index-box="node" class="btn btn-default btn-xs"
          data-container="body"><i class="fa fa-dashboard"></i></a>
        <a href="#index-list-view" data-index-box="node" class="btn btn-default btn-xs disabled"
          data-container="body"><i class="fa fa-list"></i></a>
10

11
      </div>
12
      <span class="btn btn-default btn-xs infobtn" title="{% trans "List of compute nodes, also called worker nodes or hypervisors, which run the virtual machines." %}"><i class="fa fa-info-circle"></i></span>
13 14
    </div>
    <h3 class="no-margin">
15
      <i class="fa fa-sitemap"></i> {% trans "Nodes" %}
16
    </h3>
17 18
  </div >
  <div class="list-group" id="node-list-view">
19 20
    <div id="dashboard-node-list">
      {% for i in nodes %}
Bach Dániel committed
21
      <a href="{{ i.get_absolute_url }}" class="list-group-item real-link
22
        {% if forloop.last and nodes|length < 5 %} list-group-item-last{% endif %}">
23
        <span class="index-node-list-name">
24
          <i class="fa {{ i.get_status_icon }}" title="{{ i.get_status_display }}"></i>
Bach Dániel committed
25
           {{ i.name }}
26
        </span>
Bach Dániel committed
27
        <div style="clear: both;"></div>
28
      </a>
29 30
      {% endfor %}
    </div>
31 32 33
    <div href="#" class="list-group-item list-group-footer">
      <div class="row">
        <div class="col-sm-6 col-xs-6 input-group input-group-sm">
Bach Dániel committed
34
          <input id="dashboard-node-search-input" type="text" class="form-control" placeholder="{% trans "Search..." %}" />
35
          <div class="input-group-btn">
36
            <button type="submit" class="form-control btn btn-primary" title="search"><i class="fa fa-search"></i></button>
37 38 39 40
          </div>
        </div>
        <div class="col-sm-6 text-right">
          <a class="btn btn-primary btn-xs" href="{% url "dashboard.views.node-list" %}">
41
            <i class="fa fa-chevron-circle-right"></i>
Bach Dániel committed
42 43 44 45 46
            {% if more_nodes > 0 %}
                {% blocktrans with count=more_nodes %}<strong>{{count}}</strong>  more{% endblocktrans %}
            {% else %}
                {% trans "list" %}
            {% endif %}
47
          </a>
48
          <a class="btn btn-success btn-xs node-create" href="{% url "dashboard.views.node-create" %}"><i class="fa fa-plus-circle"></i> {% trans "new" %}</a>
49 50 51
        </div>
      </div>
    </div>
52
  </div>
53

54
  <div class="panel-body" id="node-graph-view" style="display: none">
Bach Dániel committed
55
    <p class="pull-right">  <input class="knob" data-fgColor="chartreuse" data-thickness=".4" data-width="60" data-height="60" data-readOnly="true" value="{% widthratio node_num.running sum_node_num 100 %}"></p>
56 57
    <p><span class="big"><big>{{ node_num.running }}</big> running </span>
    + <big>{{ node_num.missing }}</big> missing + <br><big>{{ node_num.disabled }}</big> disabled + <big>{{ node_num.offline }}</big> offline</p>
Bach Dániel committed
58
      <ul class="list-inline" id="dashboard-node-taglist">
59 60
        {% for i in nodes %}
        <a href="{{ i.get_absolute_url }}" class="label {{i.get_status_label}}" >
61
        <i class="fa {{ i.get_status_icon }}" title="{{ i.get_status_display }}"></i> {{ i.name }}</a>
62
        {% endfor %}
Bach Dániel committed
63
      </ul>
64 65

    <div class="clearfix"></div>
66
 <div class="row">
Bach Dániel committed
67 68
        <div class="col-sm-6 text-right pull-right">
         {% if more_nodes >= 0  %}
69
          <a class="btn btn-primary btn-xs" href="{% url "dashboard.views.node-list" %}">
70
            <i class="fa fa-chevron-circle-right"></i> {% blocktrans with count=more_nodes %}<strong>{{count}}</strong>  more{% endblocktrans %}
71 72
          </a>
         {% endif %}
73
         <a class="btn btn-success btn-xs node-create" href="{% url "dashboard.views.node-create" %}"><i class="fa fa-plus-circle"></i> {% trans "new" %}</a>
74
        </div>
75 76
</div>
</div>
77
</div>