Commit 3d1ceb98 by Kálmán Viktor

network: vm list

parent ab32ba2c
......@@ -39,7 +39,7 @@
<div class="col-sm-6 text-right">
<a class="btn btn-primary btn-xs"><i class="icon-chevron-sign-right"></i> <strong>13</strong> more </a>
<a class="btn btn-primary btn-xs" href="{% url "dashboard.views.vm-list" %}"><i class="icon-chevron-sign-right"></i> <strong>13</strong> more </a>
<a class="btn btn-success btn-xs"><i class="icon-plus-sign"></i> new </a>
{% extends "dashboard/base.html" %}
{% load i18n %}
{% block content %}
<div class="row">
<div class="col-md-12">
<div class="panel panel-default">
<div class="panel-heading">
<h3 class="no-margin"><i class="icon-desktop"></i> Your virtual machines</h3>
<div class="panel-body">
<table class="table table-striped table-bordered">
<td style="width: 10px;"><input type="checkbox"/></td>
<td>Suspend in</td>
<td>Delete in</td>
<td style="width: 10px;">Actions</td>
<td><input type="checkbox"/></td>
<td><a href="">network-devenv</a></td>
<td>10 days</td>
<td>1 month</td>
<div class="btn-group">
<button type="button" class="btn btn-xs btn-info dropdown-toggle" data-toggle="dropdown">Action <i class="icon-caret-down"></i></button>
<ul class="dropdown-menu" role="menu">
<li><a href="#"><i class="icon-refresh"></i> Reboot</a></li>
<li><a href="#"><i class="icon-off"></i> Shutdown</a></li>
<li><a href="#"><i class="icon-remove"></i> Discard</a></li>
{% endblock %}
from django.conf.urls import patterns, url
from .views import IndexView, VmDetailView
from .views import IndexView, VmDetailView, VmList
urlpatterns = patterns('',
url(r'^$', IndexView.as_view()),
url(r'^vm/(?P<pk>\d+)/$', VmDetailView.as_view(),
urlpatterns = patterns(
url(r'^$', IndexView.as_view()),
url(r'^vm/(?P<pk>\d+)/$', VmDetailView.as_view(),
url(r'^vm/list/$', VmList.as_view(), name='dashboard.views.vm-list'),
from django.views.generic import TemplateView, DetailView
# from django_tables2 import SingleTableView
from vm.models import Instance
from django.core import signing
......@@ -35,3 +37,7 @@ class VmDetailView(DetailView):
'vnc_url': '%s' % value
return context
class VmList(TemplateView):
template_name = "dashboard/vm-list.html"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment