3 <div class=
"box-header with-border">
4 <h3 class=
"box-title">{{ type|upper }} Instances
</h3>
6 <div class=
"box-tools">
8 <button type=
"button" class=
"btn btn-default" data-container=
"body"
9 data-toggle=
"tooltip" data-placement=
"top" title=
"Instantiate NS"
10 onclick=
"javascript:openModalCreateNS({ 'project_id':'{{ project_id }}','vim_list_url': '{% url "vims:list
" %}', 'nsd_list_url': '{% url "projects:list_descriptors
" descriptor_type='nsd' %}'})">
11 <i class=
"fa fa-paper-plane"></i> <span> New NS
</span></button>
16 <div class=
"box-body">
17 <table id=
"instances_table" class=
"table table-bordered table-striped">
23 <th style=
"width:5%">Operational Status
</th>
24 <th style=
"width:5%">Config Status
</th>
25 <th>Detailed Status
</th>
30 {% for i in instances %}
33 <td>{{ i|get:
"_id" }}
</td>
34 <td>{{ i|get:
"short-name" }}
</td>
35 <td>{{ i|get:
"nsd-name-ref" }}
</td>
37 {% if i|get:
"operational-status" == 'failed' %}
38 <td><span class=
"label label-danger">{{ i|get:
"operational-status" }}
</span></td>
39 {% elif i|get:
"operational-status" == 'init' %}
40 <td><span class=
"label label-warning">{{ i|get:
"operational-status" }}
</span></td>
41 {% elif i|get:
"operational-status" == 'running' %}
42 <td><span class=
"label label-success">{{ i|get:
"operational-status" }}
</span></td>
44 <td>{{ i|get:
"operational-status" }}
</td>
46 {% if i|get:
"config-status" == 'failed' %}
47 <td><span class=
"label label-danger">{{ i|get:
"config-status" }}
</span></td>
48 {% elif i|get:
"config-status" == 'init' %}
49 <td><span class=
"label label-warning">{{ i|get:
"config-status" }}
</span></td>
50 {% elif i|get:
"config-status" == 'running' %}
51 <td><span class=
"label label-success">{{ i|get:
"config-status" }}
</span></td>
52 {% elif i|get:
"config-status" == 'configured' %}
53 <td><span class=
"label label-success">{{ i|get:
"config-status" }}
</span></td>
55 <td>{{ i|get:
"config-status" }}
</td>
57 <td class=
"ellipsis" data-text=
"{{ i|get:"detailed-status
" }}">{{ i|get:
"detailed-status" }}
</td>
59 <div class=
"btn-group">
60 <button type=
"button" class=
"btn btn-default"
61 onclick=
"javascript:showInstanceDetails('{% url 'instances:show' instance_id=i|get:'_id' type=type %}')"
62 data-toggle=
"tooltip" data-placement=
"top" data-container=
"body" title=
"Show Info">
63 <i class=
"fa fa-info"></i>
66 <button type="button" class="btn btn-default"
67 onclick="javascript:showInstanceTopology('{% url 'instances:show_topology' instance_id=i|get:'_id' type=type %}')"
68 data-toggle="tooltip" data-placement="top" data-container="body" title="Show Topology">
69 <i class="fa fa-sitemap"></i>
73 <button type=
"button" class=
"btn btn-default"
74 onclick=
"javascript:deleteNs('{% url 'instances:delete' instance_id=i|get:'_id' type=type %}')"
75 data-toggle=
"tooltip" data-placement=
"top" data-container=
"body" title=
"Delete"><i
76 class=
"far fa-trash-alt"></i></button>
78 <button type=
"button" class=
"btn btn-default dropdown-toggle"
79 data-toggle=
"dropdown" aria-expanded=
"false">Actions
80 <span class=
"fa fa-caret-down"></span></button>
81 <ul class=
"dropdown-menu">
83 onclick=
"javascript:performAction('{% url 'instances:action' instance_id=i|get:'_id' type=type %}')">
84 <i class=
"fa fa-magic"></i> Exec NS Primitive
</a></li>
86 <a href=
"{% url 'instances:ns_operations' type=type instance_id=i|get:'_id' %}">
87 <i class=
"fa fa-list"></i> Active operations
</a></li>
88 <li class=
"divider"></li>
90 onclick=
"javascript:newAlarmNs('{% url 'instances:ns_create_alarm' instance_id=i|get:'_id' type=type %}')">
91 <i class=
"far fa-bell"></i> New Alarm
</a></li>
93 onclick=
"javascript:exportMetricNs('{% url 'instances:ns_export_metric' instance_id=i|get:'_id' type=type %}')">
94 <i class=
"far fa-chart-bar"></i> Export metric
</a></li>
95 <li class=
"divider"></li>
97 <a href=
"javascript:deleteNs('{% url 'instances:delete' instance_id=i|get:'_id' type=type %}', true)">
98 <i class=
"far fa-trash-alt" style=
"color:red" ></i> Force delete
</a></li>