remove thumb icons for edit submit
This commit is contained in:
@@ -95,7 +95,7 @@ body {
|
|||||||
|
|
||||||
/* special placing for edit icon in details tab */
|
/* special placing for edit icon in details tab */
|
||||||
.nd_device_details_edit {
|
.nd_device_details_edit {
|
||||||
margin-left: -18px;
|
float: right !important;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -106,13 +106,6 @@ body {
|
|||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* port admin VLAN control */
|
|
||||||
.nd_thumb_icon {
|
|
||||||
cursor: pointer;
|
|
||||||
float: right;
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* placement of port link when port admin hint is enabled */
|
/* placement of port link when port admin hint is enabled */
|
||||||
.nd_editable_cell > .nd_this_port_only {
|
.nd_editable_cell > .nd_this_port_only {
|
||||||
margin-left: 18px;
|
margin-left: 18px;
|
||||||
@@ -121,11 +114,6 @@ body {
|
|||||||
margin-left: 18px;
|
margin-left: 18px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* placement of thumb for editable submit */
|
|
||||||
.center_cell > .nd_thumb_icon {
|
|
||||||
margin-left: -18px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* style of editable content in table */
|
/* style of editable content in table */
|
||||||
[contenteditable]:focus {
|
[contenteditable]:focus {
|
||||||
background: #FFFFD3 !important;
|
background: #FFFFD3 !important;
|
||||||
|
|||||||
@@ -5,15 +5,15 @@
|
|||||||
<td>[% d.name %]</td>
|
<td>[% d.name %]</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>Location</td>
|
<td>Location
|
||||||
|
[% IF vars.user.port_control %]
|
||||||
|
<i class="icon-edit nd_edit_icon nd_device_details_edit"></i>
|
||||||
|
[% END %]
|
||||||
|
</td>
|
||||||
[% IF vars.user.port_control %]
|
[% IF vars.user.port_control %]
|
||||||
<td class="nd_editable_cell" contenteditable="true"
|
<td class="nd_editable_cell" contenteditable="true"
|
||||||
data-field="location" data-for-device="[% d.ip %]">
|
data-field="location" data-for-device="[% d.ip %]">
|
||||||
<i class="icon-edit nd_edit_icon nd_device_details_edit"></i>
|
|
||||||
[% d.location %]
|
[% d.location %]
|
||||||
<i class="icon-thumbs-up nd_thumb_icon"
|
|
||||||
rel="tooltip" data-placement="left" data-offset="3"
|
|
||||||
data-animation="" title="Click to Apply"></i>
|
|
||||||
</td>
|
</td>
|
||||||
[% ELSE %]
|
[% ELSE %]
|
||||||
<td>
|
<td>
|
||||||
@@ -23,15 +23,15 @@
|
|||||||
[% END %]
|
[% END %]
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>Contact</td>
|
<td>Contact
|
||||||
|
[% IF vars.user.port_control %]
|
||||||
|
<i class="icon-edit nd_edit_icon nd_device_details_edit"></i>
|
||||||
|
[% END %]
|
||||||
|
</td>
|
||||||
[% IF vars.user.port_control %]
|
[% IF vars.user.port_control %]
|
||||||
<td class="nd_editable_cell" contenteditable="true"
|
<td class="nd_editable_cell" contenteditable="true"
|
||||||
data-field="contact" data-for-device="[% d.ip %]">
|
data-field="contact" data-for-device="[% d.ip %]">
|
||||||
<i class="icon-edit nd_edit_icon nd_device_details_edit"></i>
|
|
||||||
[% d.contact %]
|
[% d.contact %]
|
||||||
<i class="icon-thumbs-up nd_thumb_icon"
|
|
||||||
rel="tooltip" data-placement="left" data-offset="3"
|
|
||||||
data-animation="" title="Click to Apply"></i>
|
|
||||||
</td>
|
</td>
|
||||||
[% ELSE %]
|
[% ELSE %]
|
||||||
<td>[% d.contact %]</td>
|
<td>[% d.contact %]</td>
|
||||||
|
|||||||
@@ -78,11 +78,6 @@
|
|||||||
[% END %]
|
[% END %]
|
||||||
<div class="nd_editable_cell_content">
|
<div class="nd_editable_cell_content">
|
||||||
[% row.name | html_entity %]
|
[% row.name | html_entity %]
|
||||||
[% IF vars.user.port_control AND params.c_admin %]
|
|
||||||
<i class="icon-thumbs-up nd_thumb_icon"
|
|
||||||
rel="tooltip" data-placement="top" data-offset="3"
|
|
||||||
data-animation="" title="Click to Apply"></i>
|
|
||||||
[% END %]
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
[% END %]
|
[% END %]
|
||||||
@@ -105,10 +100,7 @@
|
|||||||
data-field="c_vlan" data-for-device="[% device %]" data-for-port="[% row.port | html_entity %]">
|
data-field="c_vlan" data-for-device="[% device %]" data-for-port="[% row.port | html_entity %]">
|
||||||
<i class="icon-edit nd_edit_icon"></i>
|
<i class="icon-edit nd_edit_icon"></i>
|
||||||
<div class="nd_editable_cell_content">
|
<div class="nd_editable_cell_content">
|
||||||
[% IF row.vlan %][% row.vlan | html_entity %][% ELSE %] [% END %]
|
[% IF row.vlan %][% row.vlan | html_entity %][% END %]
|
||||||
<i class="icon-thumbs-up nd_thumb_icon"
|
|
||||||
rel="tooltip" data-placement="top" data-offset="3"
|
|
||||||
data-animation="" title="Click to Apply"></i>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
[% ELSE %]
|
[% ELSE %]
|
||||||
|
|||||||
@@ -20,16 +20,19 @@
|
|||||||
// toggle visibility of port up/down and edit controls
|
// toggle visibility of port up/down and edit controls
|
||||||
$('.nd_editable_cell').hover(function() {
|
$('.nd_editable_cell').hover(function() {
|
||||||
$(this).children('.nd_hand_icon').toggle();
|
$(this).children('.nd_hand_icon').toggle();
|
||||||
$(this).children('.nd_edit_icon').toggle();
|
if ($(this).is(':focus')) {
|
||||||
|
$(this).children('.nd_edit_icon').toggle(false); // ports
|
||||||
|
$(this).siblings('td').find('.nd_device_details_edit').toggle(false); // details
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$(this).children('.nd_edit_icon').toggle(); // ports
|
||||||
|
$(this).siblings('td').find('.nd_device_details_edit').toggle(); // details
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// toggle visibility of VLAN edit control when clicked
|
|
||||||
$('[contenteditable=true]').focus(function() {
|
$('[contenteditable=true]').focus(function() {
|
||||||
$(this).find('.nd_thumb_icon').toggle();
|
$(this).children('.nd_edit_icon').toggle(false); // ports
|
||||||
});
|
$(this).siblings('td').find('.nd_device_details_edit').toggle(false); // details
|
||||||
$('[contenteditable=true]').blur(function() {
|
|
||||||
$(this).find('.nd_thumb_icon').toggle();
|
|
||||||
// can undo but CSS doesn't shift, so just do nothing for now.
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// activity for port up/down control
|
// activity for port up/down control
|
||||||
@@ -40,12 +43,6 @@
|
|||||||
port_control(this); // save
|
port_control(this); // save
|
||||||
});
|
});
|
||||||
|
|
||||||
// activity for contenteditable control
|
|
||||||
$('.nd_thumb_icon').click(function() {
|
|
||||||
$(this).closest('[contenteditable=true]').blur();
|
|
||||||
port_control(this); // save
|
|
||||||
});
|
|
||||||
|
|
||||||
// activity for contenteditable control
|
// activity for contenteditable control
|
||||||
$('[contenteditable=true]').keydown(function() {
|
$('[contenteditable=true]').keydown(function() {
|
||||||
var esc = event.which == 27,
|
var esc = event.which == 27,
|
||||||
|
|||||||
Reference in New Issue
Block a user