Move templates for nodes.overview

Move the templates to be consistent with other panels.

Change-Id: I1354c0a53a2a2083c40ac07e3d9312c6b5d0b6b2
This commit is contained in:
Radomir Dopieralski 2014-01-14 16:15:28 +01:00
parent 2bc240f467
commit ae4821b26b
7 changed files with 15 additions and 15 deletions

View File

@ -3,17 +3,17 @@
<div class="form form-inline"> <div class="form form-inline">
<div class="row-fluid"> <div class="row-fluid">
<h3 style="margin-bottom:16px">Node Detail</h3> <h3 style="margin-bottom:16px">Node Detail</h3>
{% include 'infrastructure/nodes/overview/_nodes_formset_field.html' with field=form.node_tags %} {% include 'infrastructure/nodes.overview/_nodes_formset_field.html' with field=form.node_tags %}
</div> </div>
<div class="row-fluid"> <div class="row-fluid">
<h4>Power Management</h4> <h4>Power Management</h4>
{% include 'infrastructure/nodes/overview/_nodes_formset_field.html' with field=form.ip_address required=True %} {% include 'infrastructure/nodes.overview/_nodes_formset_field.html' with field=form.ip_address required=True %}
{% include 'infrastructure/nodes/overview/_nodes_formset_field.html' with field=form.ipmi_user %} {% include 'infrastructure/nodes.overview/_nodes_formset_field.html' with field=form.ipmi_user %}
{% include 'infrastructure/nodes/overview/_nodes_formset_field.html' with field=form.ipmi_password %} {% include 'infrastructure/nodes.overview/_nodes_formset_field.html' with field=form.ipmi_password %}
</div> </div>
<div class="row-fluid"> <div class="row-fluid">
<h4>Networking</h4> <h4>Networking</h4>
{% include 'infrastructure/nodes/overview/_nodes_formset_field.html' with field=form.mac_address required=True %} {% include 'infrastructure/nodes.overview/_nodes_formset_field.html' with field=form.mac_address required=True %}
</div> </div>
<div class="row-fluid"> <div class="row-fluid">
<div class="span4"> <div class="span4">
@ -24,9 +24,9 @@
</label> </label>
</div> </div>
<div class="row-fluid" id="register-hardware-fields"> <div class="row-fluid" id="register-hardware-fields">
{% include 'infrastructure/nodes/overview/_nodes_formset_field.html' with field=form.cpus extra_text=_('units') required=True %} {% include 'infrastructure/nodes.overview/_nodes_formset_field.html' with field=form.cpus extra_text=_('units') required=True %}
{% include 'infrastructure/nodes/overview/_nodes_formset_field.html' with field=form.memory extra_text=_('MB') required=True %} {% include 'infrastructure/nodes.overview/_nodes_formset_field.html' with field=form.memory extra_text=_('MB') required=True %}
{% include 'infrastructure/nodes/overview/_nodes_formset_field.html' with field=form.local_disk extra_text=_('GB') required=True %} {% include 'infrastructure/nodes.overview/_nodes_formset_field.html' with field=form.local_disk extra_text=_('GB') required=True %}
</div> </div>
</div> </div>
</div> </div>

View File

@ -8,7 +8,7 @@
{% block modal-header %}{% trans "Register Nodes" %}{% endblock %} {% block modal-header %}{% trans "Register Nodes" %}{% endblock %}
{% block modal-body %} {% block modal-body %}
{% include "formset_table/menu_formset.html" with formset=form form_template="infrastructure/nodes/overview/_nodes_formset_form.html" %} {% include "formset_table/menu_formset.html" with formset=form form_template="infrastructure/nodes.overview/_nodes_formset_form.html" %}
{% endblock %} {% endblock %}
{% block modal-footer %} {% block modal-footer %}

View File

@ -7,5 +7,5 @@
{% endblock %} {% endblock %}
{% block main %} {% block main %}
{% include "infrastructure/nodes/overview/_register.html" %} {% include "infrastructure/nodes.overview/_register.html" %}
{% endblock %} {% endblock %}

View File

@ -33,12 +33,12 @@ class RegisterNodesTests(test.BaseAdminViewTests):
def test_index_get(self): def test_index_get(self):
res = self.client.get(INDEX_URL) res = self.client.get(INDEX_URL)
self.assertTemplateUsed( self.assertTemplateUsed(
res, 'infrastructure/nodes/overview/index.html') res, 'infrastructure/nodes.overview/index.html')
def test_register_get(self): def test_register_get(self):
res = self.client.get(REGISTER_URL) res = self.client.get(REGISTER_URL)
self.assertTemplateUsed( self.assertTemplateUsed(
res, 'infrastructure/nodes/overview/register.html') res, 'infrastructure/nodes.overview/register.html')
def test_register_post(self): def test_register_post(self):
node = TEST_DATA.ironicclient_nodes.first node = TEST_DATA.ironicclient_nodes.first
@ -104,4 +104,4 @@ class RegisterNodesTests(test.BaseAdminViewTests):
['DE:AD:BE:EF:CA:FF'], None, u''), ['DE:AD:BE:EF:CA:FF'], None, u''),
]) ])
self.assertTemplateUsed( self.assertTemplateUsed(
res, 'infrastructure/nodes/overview/register.html') res, 'infrastructure/nodes.overview/register.html')

View File

@ -23,7 +23,7 @@ from tuskar_ui.infrastructure.nodes import forms
class IndexView(generic.TemplateView): class IndexView(generic.TemplateView):
template_name = 'infrastructure/nodes/overview/index.html' template_name = 'infrastructure/nodes.overview/index.html'
def get_context_data(self, **kwargs): def get_context_data(self, **kwargs):
context = super(IndexView, self).get_context_data(**kwargs) context = super(IndexView, self).get_context_data(**kwargs)
@ -50,7 +50,7 @@ class IndexView(generic.TemplateView):
class RegisterView(horizon.forms.ModalFormView): class RegisterView(horizon.forms.ModalFormView):
form_class = forms.NodeFormset form_class = forms.NodeFormset
form_prefix = 'register_nodes' form_prefix = 'register_nodes'
template_name = 'infrastructure/nodes/overview/register.html' template_name = 'infrastructure/nodes.overview/register.html'
success_url = reverse_lazy( success_url = reverse_lazy(
'horizon:infrastructure:nodes.overview:index') 'horizon:infrastructure:nodes.overview:index')