mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-06 11:43:50 +00:00
accountcode can only be set by superadmin, domain value set by default
This commit is contained in:
@@ -54,7 +54,7 @@ else {
|
||||
$extension = str_replace(' ','-',check_str($_POST["extension"]));
|
||||
$number_alias = check_str($_POST["number_alias"]);
|
||||
$password = check_str($_POST["password"]);
|
||||
$accountcode = check_str($_POST["accountcode"]);
|
||||
$accountcode = check_str((if_group("superadmin")?$_POST["accountcode"]:$_SESSION['domain_name']));
|
||||
$effective_caller_id_name = check_str($_POST["effective_caller_id_name"]);
|
||||
$effective_caller_id_number = check_str($_POST["effective_caller_id_number"]);
|
||||
$outbound_caller_id_name = check_str($_POST["outbound_caller_id_name"]);
|
||||
@@ -949,16 +949,18 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
echo "</tr>\n";
|
||||
}
|
||||
|
||||
echo "<tr>\n";
|
||||
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
||||
echo " ".$text['label-accountcode'].":\n";
|
||||
echo "</td>\n";
|
||||
echo "<td class='vtable' align='left'>\n";
|
||||
echo " <input class='formfld' type='text' name='accountcode' maxlength='255' value=\"$accountcode\">\n";
|
||||
echo "<br />\n";
|
||||
echo $text['description-accountcode']."\n";
|
||||
echo "</td>\n";
|
||||
echo "</tr>\n";
|
||||
if (if_group("superadmin")){
|
||||
echo "<tr>\n";
|
||||
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
||||
echo " ".$text['label-accountcode'].":\n";
|
||||
echo "</td>\n";
|
||||
echo "<td class='vtable' align='left'>\n";
|
||||
echo " <input class='formfld' type='text' name='accountcode' maxlength='255' value=\"$accountcode\">\n";
|
||||
echo "<br />\n";
|
||||
echo $text['description-accountcode']."\n";
|
||||
echo "</td>\n";
|
||||
echo "</tr>\n";
|
||||
}
|
||||
|
||||
echo "<tr>\n";
|
||||
echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
|
||||
@@ -1744,4 +1746,4 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
echo "</div>";
|
||||
|
||||
require_once "resources/footer.php";
|
||||
?>
|
||||
?>
|
||||
|
||||
Reference in New Issue
Block a user