shortcut from device port to manual topology

This commit is contained in:
Oliver Gorwits
2017-12-20 23:59:15 +00:00
parent 9520438960
commit 081b89d5dc
3 changed files with 15 additions and 2 deletions

View File

@@ -12,13 +12,13 @@
<tr>
<td class="nd_center-cell">
<div class="input-append">
<input data-form="add" class="nd_topo_dev nd_topo_dev1" name="dev1" type="text">
<input data-form="add" class="nd_topo_dev nd_topo_dev1" name="dev1" type="text" value="[% params.dev1 | html_entity %]">
<span class="add-on nd_topo_dev_caret"><i class="icon-caret-down icon-large"></i></span>
</div>
</td>
<td class="nd_center-cell">
<div class="input-append">
<input data-form="add" class="nd_topo_port nd_topo_dev1" name="port1" type="text">
<input data-form="add" class="nd_topo_port nd_topo_dev1" name="port1" type="text" value="[% params.port1 | html_entity %]">
<span class="add-on nd_topo_port_caret"><i class="icon-caret-down icon-large"></i></span>
</div>
</td>

View File

@@ -345,6 +345,14 @@
[% END %]
[% END %]
[% END %]
[% IF user_can_port_control AND params.c_admin %]
<a class="nd_log-icon"
href="[% uri_for('/admin/topology') %]?dev1=[% device.ip | uri %]&port1=[% row.port | uri %]">
<i class="icon-bolt"
rel="tooltip" data-placement="top" data-offset="3"
data-animation="" data-title="Manual Topology"></i>
[% END %]
</a>
</td>
[% END %]

View File

@@ -0,0 +1,5 @@
<input name="dev1" value="[% params.dev1 | html_entity %]" type="hidden"/>
<input name="port1" value="[% params.port1 | html_entity %]" type="hidden"/>
<script type="text/javascript">has_sidebar["topology"] = 0;</script>