41 lines
790 B
HTML
41 lines
790 B
HTML
{% extends "admin/base_site.html" %}
|
|
{% load staticfiles bootstrap3 i18n %}
|
|
{% block content %}
|
|
{% if error_msg %}
|
|
<p class="alert alert-danger">{{error_msg}}</p>
|
|
{% endif %}
|
|
{% if success_msg %}
|
|
<p class="alert alert-success">{{success_msg}}</p>
|
|
{% endif %}
|
|
<a href="{% url 'admin:createvm' %}">Create VM</a>
|
|
|
|
{% if vms %}
|
|
<section>
|
|
<table class="table table-striped">
|
|
<thead>
|
|
<tr>
|
|
<th>ID</th>
|
|
<th>Name</th>
|
|
<th>Memory</th>
|
|
<th>Status</th>
|
|
<th>User Name</th>
|
|
<th>Manage Vms</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for vm in vms %}
|
|
<tr>
|
|
<td>{{vm.id}}</td>
|
|
<td>{{vm.name}}</td>
|
|
<td>{{vm.template.memory}}</td>
|
|
<td>{{vm.str_state}}</td>
|
|
<td>{{vm.uname}}</td>
|
|
<td><a href="{% url 'admin:deletevm' vm.id %}">Delete VM</a></td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</section>
|
|
{% endif %}
|
|
|
|
{% endblock %}
|