Update device_edit.php
This commit is contained in:
+11
-16
@@ -1450,27 +1450,22 @@
|
|||||||
echo "</tr>\n";
|
echo "</tr>\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (permission_exists('device_alternate')) {
|
if (permission_exists('device_alternate') && strlen($device_uuid_alternate) > 0) {
|
||||||
echo "<tr>\n";
|
echo "<tr>\n";
|
||||||
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
||||||
echo " ".$text['label-device_uuid_alternate']."\n";
|
echo " ".$text['label-device_uuid_alternate']."\n";
|
||||||
echo "</td>\n";
|
echo "</td>\n";
|
||||||
echo "<td class='vtable' align='left' nowrap='nowrap'>\n";
|
echo "<td class='vtable' align='left' nowrap='nowrap'>\n";
|
||||||
if (strlen($device_uuid_alternate) == 0) {
|
$label = $device_alternate[0]['device_label'];
|
||||||
echo " <input class='formfld' type='text' name='device_uuid_alternate' id='device_uuid_alternate' maxlength='255' value=\"".escape($device_uuid_alternate)."\"/>";
|
if (strlen($label) == 0) { $label = $device_alternate[0]['device_description']; }
|
||||||
}
|
if (strlen($label) == 0) { $label = $device_alternate[0]['device_mac_address']; }
|
||||||
else {
|
echo " <table>\n";
|
||||||
$label = $device_alternate[0]['device_label'];
|
echo " <tr>\n";
|
||||||
if (strlen($label) == 0) { $label = $device_alternate[0]['device_description']; }
|
echo " <td><a href='?id=".escape($device_uuid_alternate)."' id='device_uuid_alternate_link'>".escape($label)."</a><input class='formfld' type='hidden' name='device_uuid_alternate' id='device_uuid_alternate' maxlength='255' value=\"".escape($device_uuid_alternate)."\" /> </td>";
|
||||||
if (strlen($label) == 0) { $label = $device_alternate[0]['device_mac_address']; }
|
echo " <td><a href='#' onclick=\"if (confirm('".$text['confirm-delete']."')) { document.getElementById('device_uuid_alternate').value = ''; document.getElementById('device_uuid_alternate_link').hidden = 'true'; submit_form(); }\" alt='".$text['button-delete']."'>$v_link_label_delete</a></td>\n";
|
||||||
echo " <table>\n";
|
echo " </tr>\n";
|
||||||
echo " <tr>\n";
|
echo " </table>\n";
|
||||||
echo " <td><a href='?id=".escape($device_uuid_alternate)."' id='device_uuid_alternate_link'>".escape($label)."</a><input class='formfld' type='hidden' name='device_uuid_alternate' id='device_uuid_alternate' maxlength='255' value=\"".escape($device_uuid_alternate)."\" /> </td>";
|
unset($label);
|
||||||
echo " <td><a href='#' onclick=\"if (confirm('".$text['confirm-delete']."')) { document.getElementById('device_uuid_alternate').value = ''; document.getElementById('device_uuid_alternate_link').hidden = 'true'; submit_form(); }\" alt='".$text['button-delete']."'>$v_link_label_delete</a></td>\n";
|
|
||||||
echo " </tr>\n";
|
|
||||||
echo " </table>\n";
|
|
||||||
unset($label);
|
|
||||||
}
|
|
||||||
echo $text['description-device_uuid_alternate']."\n";
|
echo $text['description-device_uuid_alternate']."\n";
|
||||||
echo "</td>\n";
|
echo "</td>\n";
|
||||||
echo "</tr>\n";
|
echo "</tr>\n";
|
||||||
|
|||||||
Reference in New Issue
Block a user