Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure "Add Interface" form in Admin Panel works
This commit add new templates for interface add/delete operations in admin panel to make sure the original page is displayed after adding a router interface successfully. It also changes the following: - Update the help message in "Add Interface" and "Set Gateway" forms (both in project and admin panels) - Fixes a issue that Project router detail was displayed after setting an external gateway to a router in admin panel. Admin router detail is expected to display - Make sure a router name is displayed in router detail in admin panel. Fixes Bug #1131177 Change-Id: I9728cb68972977f868549b61979d9c779cd9fd4e
- Loading branch information
Showing
11 changed files
with
93 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
openstack_dashboard/dashboards/admin/routers/templates/routers/_detail_overview.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
openstack_dashboard/dashboards/admin/routers/templates/routers/ports/_create.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{% extends "horizon/common/_modal_form.html" %} | ||
{% load i18n %} | ||
|
||
{% block form_id %}add_interface_form{% endblock %} | ||
{% block form_action %}{% url horizon:admin:routers:addinterface router.id %} | ||
{% endblock %} | ||
|
||
{% block modal-header %}{% trans "Add Interface" %}{% endblock %} | ||
|
||
{% block modal-body %} | ||
<div class="left"> | ||
<fieldset> | ||
{% include "horizon/common/_form_fields.html" %} | ||
</fieldset> | ||
</div> | ||
<div class="right"> | ||
<h3>{% trans "Description" %}:</h3> | ||
<p>{% trans "You can connect a specified subnet to the router." %}</p> | ||
</div> | ||
{% endblock %} | ||
|
||
{% block modal-footer %} | ||
<input class="btn btn-primary pull-right" type="submit" value="{% trans "Add interface" %}" /> | ||
<a href="{% url horizon:admin:routers:detail router.id %}" class="btn secondary cancel close">{% trans "Cancel" %}</a> | ||
{% endblock %} |
25 changes: 25 additions & 0 deletions
25
openstack_dashboard/dashboards/admin/routers/templates/routers/ports/_setgateway.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{% extends "horizon/common/_modal_form.html" %} | ||
{% load i18n %} | ||
|
||
{% block form_id %}setgateway_form{% endblock %} | ||
{% block form_action %}{% url horizon:admin:routers:setgateway router.id %} | ||
{% endblock %} | ||
|
||
{% block modal-header %}{% trans "Set Gateway" %}{% endblock %} | ||
|
||
{% block modal-body %} | ||
<div class="left"> | ||
<fieldset> | ||
{% include "horizon/common/_form_fields.html" %} | ||
</fieldset> | ||
</div> | ||
<div class="right"> | ||
<h3>{% trans "Description" %}:</h3> | ||
<p>{% trans "You can connect a specified external network to the router. The external network is regarded as a default route of the router and the router acts as a gateway for external connectivity." %}</p> | ||
</div> | ||
{% endblock %} | ||
|
||
{% block modal-footer %} | ||
<input class="btn btn-primary pull-right" type="submit" value="{% trans "Set Gateway" %}" /> | ||
<a href="{% url horizon:admin:routers:detail router.id %}" class="btn secondary cancel close">{% trans "Cancel" %}</a> | ||
{% endblock %} |
11 changes: 11 additions & 0 deletions
11
openstack_dashboard/dashboards/admin/routers/templates/routers/ports/create.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{% extends 'base.html' %} | ||
{% load i18n %} | ||
{% block title %}{% trans "Add Interface" %}{% endblock %} | ||
|
||
{% block page_header %} | ||
{% include "horizon/common/_page_header.html" with title=_("Add Interface") %} | ||
{% endblock page_header %} | ||
|
||
{% block main %} | ||
{% include "admin/routers/ports/_create.html" %} | ||
{% endblock %} |
11 changes: 11 additions & 0 deletions
11
openstack_dashboard/dashboards/admin/routers/templates/routers/ports/setgateway.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{% extends 'base.html' %} | ||
{% load i18n %} | ||
{% block title %}{% trans "Set Gateway" %}{% endblock %} | ||
|
||
{% block page_header %} | ||
{% include "horizon/common/_page_header.html" with title=_("Set Gateway") %} | ||
{% endblock page_header %} | ||
|
||
{% block main %} | ||
{% include "admin/routers/ports/_setgateway.html" %} | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters