Destinations more minor changes
This commit is contained in:
parent
10a4ceae65
commit
f1ac3d92dd
|
|
@ -55,7 +55,8 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
//set the type
|
//set the type
|
||||||
switch ($_GET['type']) {
|
$destination_type = !empty($_GET['type']) ? $_GET['type'] : 'inbound';
|
||||||
|
switch ($destination_type) {
|
||||||
case 'inbound': $destination_type = 'inbound'; break;
|
case 'inbound': $destination_type = 'inbound'; break;
|
||||||
case 'outbound': $destination_type = 'outbound'; break;
|
case 'outbound': $destination_type = 'outbound'; break;
|
||||||
case 'local': $destination_type = 'local'; break;
|
case 'local': $destination_type = 'local'; break;
|
||||||
|
|
@ -183,7 +184,7 @@
|
||||||
|
|
||||||
//check for all required data
|
//check for all required data
|
||||||
$msg = '';
|
$msg = '';
|
||||||
if (empty($destination_type)) { $msg .= $text['message-required']." ".$text['label-destination_type']."<br>\n"; }
|
//if (empty($destination_type)) { $msg .= $text['message-required']." ".$text['label-destination_type']."<br>\n"; }
|
||||||
//if (empty($destination_prefix) && permission_exists('destination_prefix')) { $msg .= $text['message-required']." ".$text['label-destination_country_code']."<br>\n"; }
|
//if (empty($destination_prefix) && permission_exists('destination_prefix')) { $msg .= $text['message-required']." ".$text['label-destination_country_code']."<br>\n"; }
|
||||||
if (empty($destination_number)) { $msg .= $text['message-required']." ".$text['label-destination_number']."<br>\n"; }
|
if (empty($destination_number)) { $msg .= $text['message-required']." ".$text['label-destination_number']."<br>\n"; }
|
||||||
if (empty($destination_context)) { $msg .= $text['message-required']." ".$text['label-destination_context']."<br>\n"; }
|
if (empty($destination_context)) { $msg .= $text['message-required']." ".$text['label-destination_context']."<br>\n"; }
|
||||||
|
|
@ -1103,14 +1104,14 @@
|
||||||
$destination_conditions = $row["destination_conditions"];
|
$destination_conditions = $row["destination_conditions"];
|
||||||
$destination_actions = $row["destination_actions"];
|
$destination_actions = $row["destination_actions"];
|
||||||
$fax_uuid = $row["fax_uuid"];
|
$fax_uuid = $row["fax_uuid"];
|
||||||
$provider_uuid = $row["provider_uuid"];
|
$provider_uuid = $row["provider_uuid"] ?? '';
|
||||||
$user_uuid = $row["user_uuid"];
|
$user_uuid = $row["user_uuid"];
|
||||||
$group_uuid = $row["group_uuid"];
|
$group_uuid = $row["group_uuid"];
|
||||||
$currency = $row["currency"];
|
//$currency = $row["currency"] ?? ''
|
||||||
$destination_sell = $row["destination_sell"];
|
//$destination_sell = $row["destination_sell"];
|
||||||
$destination_buy = $row["destination_buy"];
|
//$destination_buy = $row["destination_buy"];
|
||||||
$currency_buy = $row["currency_buy"];
|
//$currency_buy = $row["currency_buy"];
|
||||||
$destination_carrier = $row["destination_carrier"];
|
//$destination_carrier = $row["destination_carrier"];
|
||||||
$destination_order = $row["destination_order"];
|
$destination_order = $row["destination_order"];
|
||||||
$destination_enabled = $row["destination_enabled"];
|
$destination_enabled = $row["destination_enabled"];
|
||||||
$destination_description = $row["destination_description"];
|
$destination_description = $row["destination_description"];
|
||||||
|
|
@ -1362,6 +1363,7 @@
|
||||||
echo "</td>\n";
|
echo "</td>\n";
|
||||||
echo "<td width='70%' class='vtable' align='left'>\n";
|
echo "<td width='70%' class='vtable' align='left'>\n";
|
||||||
echo " <select class='formfld' name='destination_type' id='destination_type' onchange='type_control(this.options[this.selectedIndex].value);context_control();'>\n";
|
echo " <select class='formfld' name='destination_type' id='destination_type' onchange='type_control(this.options[this.selectedIndex].value);context_control();'>\n";
|
||||||
|
|
||||||
switch ($destination_type) {
|
switch ($destination_type) {
|
||||||
case "inbound" : $selected[0] = "selected='selected'"; break;
|
case "inbound" : $selected[0] = "selected='selected'"; break;
|
||||||
case "outbound" : $selected[1] = "selected='selected'"; break;
|
case "outbound" : $selected[1] = "selected='selected'"; break;
|
||||||
|
|
|
||||||
|
|
@ -292,6 +292,10 @@
|
||||||
$x = 0;
|
$x = 0;
|
||||||
foreach($destinations as $row) {
|
foreach($destinations as $row) {
|
||||||
|
|
||||||
|
//define variables with an empty string
|
||||||
|
$destination_app = '';
|
||||||
|
$destination_data = '';
|
||||||
|
|
||||||
//prepare the destination actions
|
//prepare the destination actions
|
||||||
$destination_actions = json_decode($row['destination_actions'], true);
|
$destination_actions = json_decode($row['destination_actions'], true);
|
||||||
if (!empty($destination_actions)) {
|
if (!empty($destination_actions)) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue