add flavors support
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
{% extends 'django_openstack/syspanel/_create_flavor.html' %}
|
||||
|
||||
{% block submit %}
|
||||
<input type="submit" value="Create Flavor" class="large-rounded" />
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,8 @@
|
||||
<form id="form_delete_{{flavor.id}}" class="form-delete" method="post">
|
||||
{% csrf_token %}
|
||||
{% for hidden in form.hidden_fields %}
|
||||
{{hidden}}
|
||||
{% endfor %}
|
||||
<input name="flavorid" type="hidden" value="{{flavor.id}}" />
|
||||
<input id="delete_{{flavor.id}}" class="delete" type="submit" value="Delete" />
|
||||
</form>
|
||||
@@ -0,0 +1,24 @@
|
||||
<table class="wide">
|
||||
<tr>
|
||||
<th>Id</th>
|
||||
<th>Name</th>
|
||||
<th>VCPUs</th>
|
||||
<th>Memory</th>
|
||||
<th>Disk</th>
|
||||
<th>Actions</th>
|
||||
</tr>
|
||||
{% for flavor in flavors %}
|
||||
<tr id="{{flavor.id}}" class="{% cycle 'odd' 'even' %}">
|
||||
<td>{{flavor.id}}</td>
|
||||
<td>{{flavor.name}}</td>
|
||||
<td>{{flavor.vcpus}}</td>
|
||||
<td>{{flavor.ram}}</td>
|
||||
<td>{{flavor.disk}}</td>
|
||||
<td id="actions">
|
||||
<ul>
|
||||
<li>{% include "_delete_flavor.html" with form=delete_form %}</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
@@ -4,5 +4,6 @@
|
||||
<li><a {% if current_sidebar == "overview" %} class="active" {% endif %} href="{% url syspanel_overview %}">Overview</a></li>
|
||||
<li><a {% if current_sidebar == "instances" %} class="active" {% endif %} href="{% url syspanel_instances %}">Instances</a></li>
|
||||
<li><a {% if current_sidebar == "images" %} class="active" {% endif %} href="{% url syspanel_images %}">Images</a></li>
|
||||
<li><a {% if current_sidebar == "flavors" %} class="active" {% endif %} href="{% url syspanel_flavors %}">Flavors</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
{% extends 'syspanel_base.html' %}
|
||||
{# list of user's instances #}
|
||||
{# standard nav, sidebar, list of instances in main #}
|
||||
|
||||
{% block sidebar %}
|
||||
{% with current_sidebar="flavors" %}
|
||||
{{block.super}}
|
||||
{% endwith %}
|
||||
{% endblock %}
|
||||
|
||||
{% block main %}
|
||||
<div id='page_header'>
|
||||
<h2><span>System Panel:</span> Flavors</h2>
|
||||
<p class='desc'><span>—</span> Create, Edit and Delete Flavors.</p>
|
||||
</div>
|
||||
`
|
||||
{% include "_messages.html" %}
|
||||
|
||||
<div class="main_content">
|
||||
<div class="dash_block wide form">
|
||||
<div class='title_block'>
|
||||
<h3>Create Flavor</h3>
|
||||
</div>
|
||||
|
||||
{% include "_create_flavor.html" %}
|
||||
|
||||
<div class="right">
|
||||
<h3>Description:</h3>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus vitae est urna. Phasellus sagittis, sem posuere hendrerit mattis, velit risus viverra enim, tempus dapibus sem turpis ac erat.</p>
|
||||
<p>Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Sed mollis ligula nec lacus mollis eu laoreet lectus porta. </p>
|
||||
<p>Sed iaculis mauris et est consectetur egestas. Praesent dolor libero, semper sed aliquet</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,37 @@
|
||||
{% extends 'syspanel_base.html' %}
|
||||
{# list of user's instances #}
|
||||
{# standard nav, sidebar, list of instances in main #}
|
||||
|
||||
{% block sidebar %}
|
||||
{% with current_sidebar="flavors" %}
|
||||
{{block.super}}
|
||||
{% endwith %}
|
||||
{% endblock %}
|
||||
|
||||
{% block main %}
|
||||
<div id='page_header'>
|
||||
<h2><span>System Panel:</span> Flavors</h2>
|
||||
<p class='desc'><span>—</span> Create, Edit and Delete Flavors.</p>
|
||||
</div>
|
||||
`
|
||||
{% include "_messages.html" %}
|
||||
<div class="main_content">
|
||||
<div class='table_title wide'>
|
||||
<h3>Flavors</h3>
|
||||
<a class="refresh" href="{% url syspanel_flavors %}">Refresh List</a>
|
||||
<div class='search'>
|
||||
<form action='' method='post'>
|
||||
<fieldset>
|
||||
<label for='table_search'>Search</label>
|
||||
<input id='table_search' name='search' type='text' value='' />
|
||||
</fieldset>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% include "_syspanel_flavor_list.html" %}
|
||||
|
||||
<a id="flavor_create_link" href="{% url syspanel_flavors_create %}">Create New Flavor >></a>
|
||||
|
||||
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user