mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-02-06 07:59:23 +00:00
Dialplan - Edit: Integrate new Enabled toggle, PHP 8.1 updates.
This commit is contained in:
@@ -75,7 +75,7 @@
|
||||
$dialplan_continue = $_POST["dialplan_continue"] != '' ? $_POST["dialplan_continue"] : 'false';
|
||||
$dialplan_details = $_POST["dialplan_details"] ?? null;
|
||||
$dialplan_context = $_POST["dialplan_context"];
|
||||
$dialplan_enabled = $_POST["dialplan_enabled"];
|
||||
$dialplan_enabled = $_POST["dialplan_enabled"] ?? 'false';
|
||||
$dialplan_description = $_POST["dialplan_description"];
|
||||
$dialplan_details_delete = $_POST["dialplan_details_delete"] ?? null;
|
||||
}
|
||||
@@ -233,7 +233,7 @@
|
||||
$array['dialplans'][$x]['dialplan_context'] = $_POST["dialplan_context"];
|
||||
$array['dialplans'][$x]['dialplan_continue'] = $_POST["dialplan_continue"];
|
||||
$array['dialplans'][$x]['dialplan_order'] = $_POST["dialplan_order"];
|
||||
$array['dialplans'][$x]['dialplan_enabled'] = $_POST["dialplan_enabled"];
|
||||
$array['dialplans'][$x]['dialplan_enabled'] = $_POST["dialplan_enabled"] ?? 'false';
|
||||
$array['dialplans'][$x]['dialplan_description'] = $_POST["dialplan_description"];
|
||||
$y = 0;
|
||||
if (!empty($_POST["dialplan_details"]) && is_array($_POST["dialplan_details"])) {
|
||||
@@ -713,21 +713,33 @@
|
||||
echo " <td class='vncellreq' valign='top' align='left' nowrap='nowrap'>\n";
|
||||
echo " ".$text['label-enabled']."\n";
|
||||
echo " </td>\n";
|
||||
echo " <td class='vtable' align='left'>\n";
|
||||
echo " <select class='formfld' name='dialplan_enabled'>\n";
|
||||
if ($dialplan_enabled == "true") {
|
||||
echo " <option value='true' selected='selected'>".$text['option-true']."</option>\n";
|
||||
echo " <td class='vtable' style='position: relative;' align='left'>\n";
|
||||
if (substr($_SESSION['theme']['input_toggle_style']['text'], 0, 6) == 'switch') {
|
||||
echo " <label class='switch'>\n";
|
||||
echo " <input type='checkbox' id='dialplan_enabled' name='dialplan_enabled' value='true' ".(!empty($dialplan_enabled) && $dialplan_enabled == 'true' ? "checked='checked'" : null).">\n";
|
||||
echo " <span class='slider'></span>\n";
|
||||
echo " </label>\n";
|
||||
}
|
||||
else {
|
||||
echo " <option value='true'>".$text['option-true']."</option>\n";
|
||||
echo " <select class='formfld' id='dialplan_enabled' name='dialplan_enabled'>\n";
|
||||
echo " <option value='true' ".($dialplan_enabled == 'true' ? "selected='selected'" : null).">".$text['option-true']."</option>\n";
|
||||
echo " <option value='false' ".($dialplan_enabled == 'false' ? "selected='selected'" : null).">".$text['option-false']."</option>\n";
|
||||
echo " </select>\n";
|
||||
}
|
||||
if ($dialplan_enabled == "false") {
|
||||
echo " <option value='false' selected='selected'>".$text['option-false']."</option>\n";
|
||||
}
|
||||
else {
|
||||
echo " <option value='false'>".$text['option-false']."</option>\n";
|
||||
}
|
||||
echo " </select>\n";
|
||||
// echo " <select class='formfld' name='dialplan_enabled'>\n";
|
||||
// if ($dialplan_enabled == "true") {
|
||||
// echo " <option value='true' selected='selected'>".$text['option-true']."</option>\n";
|
||||
// }
|
||||
// else {
|
||||
// echo " <option value='true'>".$text['option-true']."</option>\n";
|
||||
// }
|
||||
// if ($dialplan_enabled == "false") {
|
||||
// echo " <option value='false' selected='selected'>".$text['option-false']."</option>\n";
|
||||
// }
|
||||
// else {
|
||||
// echo " <option value='false'>".$text['option-false']."</option>\n";
|
||||
// }
|
||||
// echo " </select>\n";
|
||||
echo " </td>\n";
|
||||
echo " </tr>\n";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user