Add new device permissions for mac address, template, label, vendor, model, firmware, and description.
This commit is contained in:
parent
5f7fd707c2
commit
ef5a1eb455
|
|
@ -39,6 +39,18 @@
|
|||
$apps[$x]['permissions'][$y]['groups'][] = "admin";
|
||||
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = 'device_mac_address';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'superadmin';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'admin';
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = 'device_label';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'superadmin';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'admin';
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = 'device_template';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'superadmin';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'admin';
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = "device_extension_view";
|
||||
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
||||
$apps[$x]['permissions'][$y]['groups'][] = "admin";
|
||||
|
|
@ -137,10 +149,24 @@
|
|||
$apps[$x]['permissions'][$y]['name'] = 'device_all';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'superadmin';
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = 'device_vendor';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'superadmin';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'admin';
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = 'device_model';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'superadmin';
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = 'device_firmware';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'superadmin';
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = 'device_enable';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'superadmin';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'admin';
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = 'device_description';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'superadmin';
|
||||
$apps[$x]['permissions'][$y]['groups'][] = 'admin';
|
||||
$y++;
|
||||
|
||||
//schema details
|
||||
$y = 0; //table array index
|
||||
|
|
|
|||
|
|
@ -526,24 +526,36 @@ require_once "resources/require.php";
|
|||
echo " ".$text['label-device_mac_address']."\n";
|
||||
echo "</td>\n";
|
||||
echo "<td class='vtable' align='left'>\n";
|
||||
if (permission_exists('device_mac_address')) {
|
||||
echo " <input class='formfld' type='text' name='device_mac_address' id='device_mac_address' maxlength='255' value=\"$device_mac_address\">\n";
|
||||
}
|
||||
else {
|
||||
echo $device_mac_address;
|
||||
}
|
||||
echo " <div style='display: none;' id='duplicate_mac_response'></div>\n";
|
||||
echo "<br />\n";
|
||||
echo $text['description-device_mac_address']."\n";
|
||||
echo "</td>\n";
|
||||
echo "</tr>\n";
|
||||
|
||||
|
||||
echo "<tr>\n";
|
||||
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
||||
echo " ".$text['label-device_label']."\n";
|
||||
echo "</td>\n";
|
||||
echo "<td class='vtable' align='left'>\n";
|
||||
if (permission_exists('device_label')) {
|
||||
echo " <input class='formfld' type='text' name='device_label' maxlength='255' value=\"$device_label\">\n";
|
||||
}
|
||||
else {
|
||||
echo $device_label;
|
||||
}
|
||||
echo "<br />\n";
|
||||
echo $text['description-device_label']."\n";
|
||||
echo "</td>\n";
|
||||
echo "</tr>\n";
|
||||
|
||||
if (permission_exists('device_template')) {
|
||||
echo "<tr>\n";
|
||||
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
||||
echo " ".$text['label-device_template']."\n";
|
||||
|
|
@ -589,6 +601,7 @@ require_once "resources/require.php";
|
|||
echo $text['description-device_template']."\n";
|
||||
echo "</td>\n";
|
||||
echo "</tr>\n";
|
||||
}
|
||||
|
||||
if (permission_exists('device_line_view')) {
|
||||
echo " <tr>";
|
||||
|
|
@ -1198,6 +1211,7 @@ require_once "resources/require.php";
|
|||
echo "</tr>\n";
|
||||
}
|
||||
|
||||
if (permission_exists('device_vendor')) {
|
||||
echo "<tr>\n";
|
||||
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
||||
echo " ".$text['label-device_vendor']."\n";
|
||||
|
|
@ -1208,7 +1222,9 @@ require_once "resources/require.php";
|
|||
echo $text['description-device_vendor']."\n";
|
||||
echo "</td>\n";
|
||||
echo "</tr>\n";
|
||||
}
|
||||
|
||||
if (permission_exists('device_model')) {
|
||||
echo "<tr>\n";
|
||||
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
||||
echo " ".$text['label-device_model']."\n";
|
||||
|
|
@ -1219,7 +1235,9 @@ require_once "resources/require.php";
|
|||
echo $text['description-device_model']."\n";
|
||||
echo "</td>\n";
|
||||
echo "</tr>\n";
|
||||
}
|
||||
|
||||
if (permission_exists('device_firmware')) {
|
||||
echo "<tr>\n";
|
||||
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
||||
echo " ".$text['label-device_firmware_version']."\n";
|
||||
|
|
@ -1230,6 +1248,7 @@ require_once "resources/require.php";
|
|||
echo $text['description-device_firmware_version']."\n";
|
||||
echo "</td>\n";
|
||||
echo "</tr>\n";
|
||||
}
|
||||
|
||||
if (permission_exists('device_domain')) {
|
||||
echo "<tr>\n";
|
||||
|
|
@ -1292,7 +1311,12 @@ require_once "resources/require.php";
|
|||
echo " ".$text['label-device_description']."\n";
|
||||
echo "</td>\n";
|
||||
echo "<td class='vtable' align='left'>\n";
|
||||
if (permission_exists('device_description')) {
|
||||
echo " <input class='formfld' type='text' name='device_description' maxlength='255' value=\"$device_description\">\n";
|
||||
}
|
||||
else {
|
||||
echo $device_description."\n";
|
||||
}
|
||||
echo "<br />\n";
|
||||
echo $text['description-device_description']."\n";
|
||||
echo "</td>\n";
|
||||
|
|
|
|||
Loading…
Reference in New Issue