mirror of
https://github.com/retspen/webvirtcloud
synced 2025-07-31 12:41:08 +00:00
adds bridge slave list to details of interface
This commit is contained in:
parent
f3f4f0afe8
commit
0738ec7ec4
3 changed files with 60 additions and 5 deletions
|
@ -38,12 +38,12 @@
|
|||
<div class="row">
|
||||
<div class="col-xs-6 col-sm-4">
|
||||
<p>{% trans "Interface" %}:</p>
|
||||
<p>{% trans "IPv4" %}: ({% ifequal ipv4 None %}{% trans 'None' %}{% else %}{{ ipv4_type }}{% endifequal %})</p>
|
||||
<p>{% trans "IPv6" %}: ({% ifequal ipv6 None %}{% trans 'None' %}{% else %}{{ ipv6_type }}{% endifequal %})</p>
|
||||
<p>{% trans "IPv4" %} ({% ifequal ipv4 None %}{% trans 'None' %}{% else %}{{ ipv4_type }}{% endifequal %}):</p>
|
||||
<p>{% trans "IPv6" %} ({% ifequal ipv6 None %}{% trans 'None' %}{% else %}{{ ipv6_type }}{% endifequal %}):</p>
|
||||
<p>{% trans "MAC Adress" %}:</p>
|
||||
<p>{% trans "Interface Type" %}:</p>
|
||||
{% ifequal itype 'bridge' %}
|
||||
<p>{% trans "Bridge device" %}</p>
|
||||
<p>{% trans "Bridge Device" %}:</p>
|
||||
{% endifequal %}
|
||||
<p>{% trans "Boot Mode" %}:</p>
|
||||
<p>{% trans "State" %}:</p>
|
||||
|
@ -69,5 +69,33 @@
|
|||
</form>
|
||||
</p>
|
||||
</div>
|
||||
<div class="col-sm-12">
|
||||
{% ifequal itype 'bridge' %}
|
||||
<table class="table table-bordered">
|
||||
<caption>{% trans 'Slaves' %}</caption>
|
||||
<thead>
|
||||
<tr class="active">
|
||||
<td>{% trans 'MAC' %}</td>
|
||||
<td>{% trans 'Name' %}</td>
|
||||
<td>{% trans 'Type' %}</td>
|
||||
<td>{% trans 'Speed' %}</td>
|
||||
<td>{% trans 'State' %}</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for iface in slave_ifaces %}
|
||||
<tr>
|
||||
<td>{{ iface.mac }}</td>
|
||||
<td>{{ iface.name }}</td>
|
||||
<td>{{ iface.type }}</td>
|
||||
<td>{{ iface.speed }}</td>
|
||||
<td>{{ iface.state }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% endifequal %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
|
@ -88,6 +88,7 @@ def interface(request, compute_id, iface):
|
|||
ipv6 = conn.get_ipv6()
|
||||
ipv6_type = conn.get_ipv6_type()
|
||||
bridge = conn.get_bridge()
|
||||
slave_ifaces = conn.get_bridge_slave_ifaces()
|
||||
|
||||
if request.method == 'POST':
|
||||
if 'stop' in request.POST:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue