From d95b5a40178badd6208200cee979619528b6f189 Mon Sep 17 00:00:00 2001 From: catborise Date: Wed, 22 Jan 2020 14:50:12 +0300 Subject: [PATCH] allinstances.html: fix identation. Remove redundant div blocks --- instances/templates/allinstances.html | 226 +++++++++++++------------- 1 file changed, 111 insertions(+), 115 deletions(-) diff --git a/instances/templates/allinstances.html b/instances/templates/allinstances.html index 4f7ad80..3c8e12a 100644 --- a/instances/templates/allinstances.html +++ b/instances/templates/allinstances.html @@ -24,121 +24,117 @@ {% include 'errors_block.html' %} -
-
-
- {% if request.user.is_superuser %} - {% if not all_host_vms %} -
-
- - {% trans "Warning:" %} {% trans "You don't have any Instance" %} -
-
- {% else %} - {% ifequal view_style "nongrouped" %} - {% include 'allinstances_index_nongrouped.html' %} - {% endifequal %} - {% ifequal view_style "grouped" %} - {% include 'allinstances_index_grouped.html' %} - {% endifequal %} - {% endif %} - {% else %} - {% if not all_user_vms %} -
-
- - {% trans "Warning" %}: {% trans "You don't have any Instance" %} -
-
- {% else %} - - - - - - - - - - - - {% for inst, vm in all_user_vms.items %} - - - - - - - - {% endfor %} - -
{% trans 'Name' %}{% trans 'Status' %}{% trans 'VCPU' %}{% trans 'Memory' %}{% trans 'Actions' %}
{{ vm.name }}
{{ vm.title }}
{% ifequal vm.status 1 %} - {% trans "Active" %} - {% endifequal %} - {% ifequal vm.status 5 %} - {% trans "Off" %} - {% endifequal %} - {% ifequal vm.status 3 %} - {% trans "Suspend" %} - {% endifequal %} - {{ vm.vcpu }}{{ vm.memory }} {% trans "MB" %}
{% csrf_token %} - - - {% ifequal vm.status 5 %} - {% if inst.instance.is_template %} - - {% else %} - - {% endif %} - - - - {% endifequal %} - {% ifequal vm.status 3 %} - - - - - {% endifequal %} - {% ifequal vm.status 1 %} - - - - - - - {% endifequal %} -
-
- {% endif %} - {% endif %} -
-
+
+ {% if request.user.is_superuser %} + {% if not all_host_vms %} +
+
+ + {% trans "Warning" %}: {% trans "You don't have any Instance" %} +
+
+ {% else %} + {% ifequal view_style "nongrouped" %} + {% include 'allinstances_index_nongrouped.html' %} + {% endifequal %} + {% ifequal view_style "grouped" %} + {% include 'allinstances_index_grouped.html' %} + {% endifequal %} + {% endif %} + {% else %} + {% if not all_user_vms %} +
+
+ + {% trans "Warning" %}: {% trans "You don't have any Instance" %} +
+
+ {% else %} + + + + + + + + + + + + {% for inst, vm in all_user_vms.items %} + + + + + + + + {% endfor %} + +
{% trans 'Name' %}{% trans 'Status' %}{% trans 'VCPU' %}{% trans 'Memory' %}{% trans 'Actions' %}
{{ vm.name }}
{{ vm.title }}
{% ifequal vm.status 1 %} + {% trans "Active" %} + {% endifequal %} + {% ifequal vm.status 5 %} + {% trans "Off" %} + {% endifequal %} + {% ifequal vm.status 3 %} + {% trans "Suspend" %} + {% endifequal %} + {{ vm.vcpu }}{{ vm.memory }} {% trans "MB" %}
{% csrf_token %} + + + {% ifequal vm.status 5 %} + {% if inst.instance.is_template %} + + {% else %} + + {% endif %} + + + + {% endifequal %} + {% ifequal vm.status 3 %} + + + + + {% endifequal %} + {% ifequal vm.status 1 %} + + + + + + + {% endifequal %} +
+
+ {% endif %} + {% endif %}
{% endblock %} {% block script %}