better color by setting as dropdown

This commit is contained in:
Oliver Gorwits
2018-03-10 21:53:48 +00:00
parent 9205cb0834
commit 680998a82c
2 changed files with 22 additions and 45 deletions

View File

@@ -463,9 +463,6 @@ td > form.nd_inline-form {
#nd_vlan-label-text {
vertical-align: text-bottom;
}
#nd_colorby-label-text {
vertical-align: text-bottom;
}
#nd_vlan-entry {
width: 53px;
}
@@ -615,6 +612,14 @@ div.toggle.btn-small {
padding-bottom: 5px;
}
#nd_colorby {
width: 107px;
}
#nd_colorby-label-text {
vertical-align: bottom;
line-height: 2;
}
/* when the sidebar submit button DOES NOT HAVE a dropdown */
.nd_sidebar button:not(.nd_sidebar-btn-drop):not(.nd_sidebar-btn-drop-drop):not(.nd_sidebar-btn-netmap) {
margin-top: 9px;

View File

@@ -99,49 +99,21 @@
<div class="clearfix nd_netmap-sidebar">
[% IF hgroup_list.size OR location_list.size %]
<table margin="0" border="0" class="nd_sidebar-label control-group">
<tr>
<td id="nd_colorby-label-text">Color by:</td>
<td>
<div class="radio radio-success">
<input type="radio" name="colorby" id="nd_colorby-off"
[% 'checked' IF vars.sidebar_defaults.device_netmap.colorby == 'off' %]
value="off">
<label for="nd_colorby-off">Off</label>
</div>
</td>
</tr>
<tr>
[% IF NOT (hgroup_list.size AND location_list.size) %]
<td>
</td>
[% END %]
[% IF hgroup_list.size %]
<td>
<div class="radio radio-success">
<input type="radio" name="colorby" id="nd_colorby-hgroup"
[% 'checked' IF vars.sidebar_defaults.device_netmap.colorby == 'hgroup' %]
value="hgroup">
<label for="nd_colorby-hgroup">Group</label>
</div>
</td>
[% END %]
[% IF location_list.size %]
<td>
<div class="radio radio-success">
<input type="radio" name="colorby" id="nd_colorby-lgroup"
[% 'checked' IF vars.sidebar_defaults.device_netmap.colorby == 'location' %]
value="location">
<label for="nd_colorby-lgroup">Location</label>
</div>
</td>
[% END %]
</tr>
</table>
[% END %]
<div class="clearfix input-prepend">
[% IF hgroup_list.size OR location_list.size %]
<label><span id="nd_colorby-label-text">Color by: </span>
<select id="nd_colorby" name="colorby">
<option[% ' selected="selected"' IF vars.sidebar_defaults.device_netmap.colorby == 'off' %]>Off</option>
[% IF hgroup_list.size %]
<option[% ' selected="selected"' IF vars.sidebar_defaults.device_netmap.colorby == 'hgroup' %]>Group</option>
[% END %]
[% IF location_list.size %]
<option[% ' selected="selected"' IF vars.sidebar_defaults.device_netmap.colorby == 'location' %]>Location</option>
[% END %]
</select>
</label>
[% END %]
<label class="add-on">
<input type="checkbox" id="dynamicsize" name="dynamicsize"
[% 'checked="checked"' IF vars.sidebar_defaults.device_netmap.dynamicsize %]/>