mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-01-21 07:55:00 +00:00
network: Untabify and minor refactoring
This commit is contained in:
parent
bc4ac58f2e
commit
fc6b59d59b
@ -41,54 +41,54 @@
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="list-group">
|
||||
{% for conn in connections %}
|
||||
{% for connection in connections %}
|
||||
<div class="list-group-item clearfix">
|
||||
<a href="{% url 'networks:delete' conn.id %}"
|
||||
<a href="{% url 'networks:delete' connection.uuid %}"
|
||||
class="btn btn-default btn-sm pull-right"
|
||||
role="button" title="Delete connection {{ conn.name }}">
|
||||
role="button" title="Delete connection {{ connection.name }}">
|
||||
<span class="glyphicon glyphicon-trash"
|
||||
aria-hidden="true"></span>
|
||||
</a>
|
||||
|
||||
<a class="connection-edit-label"
|
||||
href="{% url 'networks:edit' conn.id %}"
|
||||
title="Edit connection {{ conn.name }}">
|
||||
{{ conn.name }}
|
||||
href="{% url 'networks:edit' connection.uuid %}"
|
||||
title="Edit connection {{ connection.name }}">
|
||||
{{ connection.name }}
|
||||
</a>
|
||||
|
||||
<span class="connection-type-label">{{ conn.type }}</span>
|
||||
<span class="connection-type-label">{{ connection.type }}</span>
|
||||
|
||||
{% if conn.is_active %}
|
||||
<div class="btn-group">
|
||||
<button type="button"
|
||||
class="btn btn-success btn-xs dropdown-toggle"
|
||||
data-toggle="dropdown" aria-expanded="false">
|
||||
Active <span class="caret"></span>
|
||||
</button>
|
||||
<ul class="dropdown-menu" role="menu">
|
||||
<li>
|
||||
<a href="{% url 'networks:deactivate' conn.id %}">
|
||||
Deactivate
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
{% else %}
|
||||
<div class="btn-group">
|
||||
<button type="button"
|
||||
class="btn btn-warning btn-xs dropdown-toggle"
|
||||
data-toggle="dropdown" aria-expanded="false">
|
||||
Not Active <span class="caret"></span>
|
||||
</button>
|
||||
<ul class="dropdown-menu" role="menu">
|
||||
<li>
|
||||
<a href="{% url 'networks:activate' conn.id %}">
|
||||
Activate
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% if connection.is_active %}
|
||||
<div class="btn-group">
|
||||
<button type="button"
|
||||
class="btn btn-success btn-xs dropdown-toggle"
|
||||
data-toggle="dropdown" aria-expanded="false">
|
||||
Active <span class="caret"></span>
|
||||
</button>
|
||||
<ul class="dropdown-menu" role="menu">
|
||||
<li>
|
||||
<a href="{% url 'networks:deactivate' connection.uuid %}">
|
||||
Deactivate
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
{% else %}
|
||||
<div class="btn-group">
|
||||
<button type="button"
|
||||
class="btn btn-warning btn-xs dropdown-toggle"
|
||||
data-toggle="dropdown" aria-expanded="false">
|
||||
Not Active <span class="caret"></span>
|
||||
</button>
|
||||
<ul class="dropdown-menu" role="menu">
|
||||
<li>
|
||||
<a href="{% url 'networks:activate' connection.uuid %}">
|
||||
Activate
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
</div>
|
||||
{% endfor %}
|
||||
|
||||
@ -27,13 +27,13 @@
|
||||
<div class="list-group">
|
||||
{% for ap in aps %}
|
||||
<div class="list-group-item clearfix">
|
||||
<a display="inline-block" width="40%"
|
||||
href="{% url 'networks:connect' ap.connect_path %}">
|
||||
{{ ap.ssid }}
|
||||
</a>
|
||||
<span class="btn btn-primary btn-xs pull-right">
|
||||
{{ ap.strength }}%
|
||||
</span>
|
||||
<a display="inline-block" width="40%"
|
||||
href="{% url 'networks:connect' ap.connect_path %}">
|
||||
{{ ap.ssid }}
|
||||
</a>
|
||||
<span class="btn btn-primary btn-xs pull-right">
|
||||
{{ ap.strength }}%
|
||||
</span>
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user