diff --git a/app/call_centers/call_center_agent_edit.php b/app/call_centers/call_center_agent_edit.php index 71bda8a5b4..d36c3807ba 100644 --- a/app/call_centers/call_center_agent_edit.php +++ b/app/call_centers/call_center_agent_edit.php @@ -300,6 +300,9 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) { } //if ($_POST["persistformvar"] != "true") } //(count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) +//initialize the destinations object + $destination = new destinations; + //pre-populate the form if (count($_GET)>0 && $_POST["persistformvar"] != "true") { $call_center_agent_uuid = $_GET["id"]; @@ -475,10 +478,7 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) { echo " ".$text['label-contact']."\n"; echo "\n"; echo "\n"; - - //switch_select_destination(select_type, select_label, select_name, select_value, select_style, action); - switch_select_destination("call_center_contact", "", "agent_contact", $agent_contact, "width: 350px;", ""); - + echo $destination->select('call_center_contact', 'agent_contact', $agent_contact); echo "
\n"; echo $text['description-contact']."\n"; echo "\n"; diff --git a/app/call_centers/call_center_queue_edit.php b/app/call_centers/call_center_queue_edit.php index f183a65fef..77ab53a661 100644 --- a/app/call_centers/call_center_queue_edit.php +++ b/app/call_centers/call_center_queue_edit.php @@ -402,6 +402,9 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) { } //if ($_POST["persistformvar"] != "true") } //(count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) +//initialize the destinations object + $destination = new destinations; + //pre-populate the form if (count($_GET)>0 && $_POST["persistformvar"] != "true") { $call_center_queue_uuid = $_GET["id"]; @@ -815,8 +818,7 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) { echo " ".$text['label-timeout_action']."\n"; echo "\n"; echo "\n"; - //switch_select_destination(select_type, select_label, select_name, select_value, select_style, action); - switch_select_destination("dialplan", "", "queue_timeout_action", $queue_timeout_action, "", ""); + echo $destination->select('dialplan', 'queue_timeout_action', $queue_timeout_action); echo "
\n"; echo $text['description-timeout_action']."\n"; echo "\n"; diff --git a/app/call_flows/call_flow_edit.php b/app/call_flows/call_flow_edit.php index ef46bc865b..254601b5d8 100644 --- a/app/call_flows/call_flow_edit.php +++ b/app/call_flows/call_flow_edit.php @@ -556,8 +556,6 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) { $select_value = $call_flow_app.':'.$call_flow_data; } //show the destination list - //switch_select_destination($select_type, $select_label, $select_name, $select_value, $select_style, $action='') - //switch_select_destination("dialplan", $destination_label, "call_flow_destination", $select_value, "", $call_flow_data); echo $destination->select('dialplan', 'call_flow_destination', $select_value); unset($select_value); echo "
\n"; diff --git a/app/dialplan/dialplan_add.php b/app/dialplan/dialplan_add.php index 81fd689d44..41d3f3bcbd 100644 --- a/app/dialplan/dialplan_add.php +++ b/app/dialplan/dialplan_add.php @@ -259,6 +259,9 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) { return; } //end if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) +//initialize the destinations object +$destination = new destinations; + ?>