Commit 9e76ed54 by Szabolcs Gelencser

fix running/stopped instances indication

parent 94d2ea62
...@@ -60,8 +60,8 @@ class IndexView(LoginRequiredMixin, TemplateView): ...@@ -60,8 +60,8 @@ class IndexView(LoginRequiredMixin, TemplateView):
# 'more_instances': instances.count() - len(instances[:5]) # 'more_instances': instances.count() - len(instances[:5])
# }) # })
running = instances#instances.filter(status='RUNNING') running = [i for i in instances if i.status == "ACTIVE"]
stopped = []#instances.exclude(status__in=('RUNNING', 'NOSTATE')) stopped = [i for i in instances if i.status != "ACTIVE"]
context.update({ context.update({
'running_vms': running[:20], 'running_vms': running[:20],
......
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