Merge branch 'master' of https://github.com/fusionpbx/fusionpbx
This commit is contained in:
commit
4656eaee89
|
|
@ -1689,6 +1689,32 @@ $text['label-blf']['de-at'] = "BLF";
|
|||
$text['label-blf']['ar-eg'] = "";
|
||||
$text['label-blf']['he'] = "";
|
||||
|
||||
$text['label-callers']['en-us'] = "Callers";
|
||||
$text['label-callers']['es-cl'] = "Llaamadas";
|
||||
$text['label-callers']['pt-pt'] = "";
|
||||
$text['label-callers']['fr-fr'] = "";
|
||||
$text['label-callers']['pt-br'] = "";
|
||||
$text['label-callers']['pl'] = "";
|
||||
$text['label-callers']['uk'] = "";
|
||||
$text['label-callers']['sv-se'] = "";
|
||||
$text['label-callers']['ro'] = "";
|
||||
$text['label-callers']['de-at'] = "";
|
||||
$text['label-callers']['ar-eg'] = "";
|
||||
$text['label-callers']['he'] = "";
|
||||
|
||||
$text['label-xfer']['en-us'] = "Xfer";
|
||||
$text['label-xfer']['es-cl'] = "Xfer";
|
||||
$text['label-xfer']['pt-pt'] = "";
|
||||
$text['label-xfer']['fr-fr'] = "";
|
||||
$text['label-xfer']['pt-br'] = "";
|
||||
$text['label-xfer']['pl'] = "Xfer ";
|
||||
$text['label-xfer']['uk'] = "";
|
||||
$text['label-xfer']['sv-se'] = "";
|
||||
$text['label-xfer']['ro'] = "";
|
||||
$text['label-xfer']['de-at'] = "";
|
||||
$text['label-xfer']['ar-eg'] = "";
|
||||
$text['label-xfer']['he'] = "";
|
||||
|
||||
$text['label-automata']['en-us'] = "automata";
|
||||
$text['label-automata']['es-cl'] = "automata";
|
||||
$text['label-automata']['pt-pt'] = "automata";
|
||||
|
|
|
|||
|
|
@ -882,14 +882,19 @@ require_once "resources/require.php";
|
|||
?>
|
||||
<option value='blf' <?php if ($row['device_key_type'] == "blf") { echo $selected;$found=true; } ?>><?php echo $text['label-blf'] ?></option>
|
||||
<option value='blfxfer' <?php if ($row['device_key_type'] == "blfxfer") { echo $selected;$found=true; } ?>><?php echo $text['label-blf_xfer'] ?></option>
|
||||
<option value='callers' <?php if ($row['device_key_type'] == "callers") { echo $selected;$found=true; } ?>><?php echo $text['label-callers'] ?></option>
|
||||
|
||||
<option value='dnd' <?php if ($row['device_key_type'] == "dnd") { echo $selected;$found=true; } ?>><?php echo $text['label-dnd'] ?></option>
|
||||
<option value='speeddial' <?php if ($row['device_key_type'] == "speeddial") { echo $selected;$found=true; } ?>><?php echo $text['label-speed_dial'] ?></option>
|
||||
<option value='xfer' <?php if ($row['device_key_type'] == "xfer") { echo $selected;$found=true; } ?>><?php echo $text['label-xfer'] ?></option>
|
||||
|
||||
<?php
|
||||
if (strlen($device_vendor) == 0) { echo "</optgroup>"; }
|
||||
}
|
||||
if (strtolower($device_vendor) == "cisco" || strlen($device_vendor) == 0 || strlen($device_username) > 0) {
|
||||
echo "<optgroup label='Cisco'>";
|
||||
?>
|
||||
<option value='blf' <?php if ($row['device_key_type'] == "blf") { echo $selected;$found=true; } ?>><?php echo $text['label-blf'] ?></option>
|
||||
<option value='line' <?php if ($row['device_key_type'] == "line") { echo $selected;$found=true; } ?>><?php echo $text['label-line'] ?></option>
|
||||
<option value='disabled' <?php if ($row['device_key_type'] == "disabled") { echo $selected;$found=true; } ?>><?php echo $text['label-disabled'] ?></option>
|
||||
<?php
|
||||
|
|
|
|||
|
|
@ -2,14 +2,26 @@
|
|||
<extension name="local_extension" number="[ext]" continue="false" app_uuid="71cf1310-b6e3-415b-8745-3cbdc8e15212">
|
||||
<condition field="destination_number" expression="(^\d{2,7}$)">
|
||||
<!--<action application="pre_answer"/>-->
|
||||
<action application="set" data="dialed_extension=$1"/>
|
||||
<action application="export" data="dialed_extension=$1"/>
|
||||
<action application="export" data="dialed_extension=$1" inline="true"/>
|
||||
<action application="limit" data="hash ${domain_name} $1 ${limit_max} ${limit_destination}"/>
|
||||
<!-- bind_meta_app can have these args <key> [a|b|ab] [a|b|o|s] <app> -->
|
||||
<action application="bind_meta_app" data="1 ab s execute_extension::dx XML ${context}"/>
|
||||
<action application="bind_meta_app" data="2 ab s record_session::$${recordings_dir}/${domain_name}/archive/${strftime(%Y)}/${strftime(%b)}/${strftime(%d)}/${uuid}.${record_ext}"/>
|
||||
<action application="bind_meta_app" data="3 ab s execute_extension::cf XML ${context}"/>
|
||||
<action application="bind_meta_app" data="4 ab s execute_extension::att_xfer XML ${context}"/>
|
||||
</condition>
|
||||
|
||||
<!--Allow transfer/record only for internal users-->
|
||||
<condition field="${sip_authorized}" expression="true" break="never">
|
||||
<action application="set" data="bind_target=both" inline="true"/>
|
||||
<!-- set to `peer` to prevent manipulate of call by callee -->
|
||||
<anti-action application="set" data="bind_target=both" inline="true"/>
|
||||
</condition>
|
||||
|
||||
<condition>
|
||||
<action application="bind_digit_action" data="local,*1,exec:execute_extension,dx XML ${context},${bind_target}"/>
|
||||
<action application="bind_digit_action" data="local,*2,exec:record_session,$${recordings_dir}/${domain_name}/archive/${strftime(%Y)}/${strftime(%b)}/${strftime(%d)}/${uuid}.${record_ext},${bind_target}"/>
|
||||
<action application="bind_digit_action" data="local,*3,exec:execute_extension,cf XML ${context},${bind_target}"/>
|
||||
<action application="bind_digit_action" data="local,*4,exec:execute_extension,att_xfer XML ${context},${bind_target}"/>
|
||||
<action application="digit_action_set_realm" data="local"/>
|
||||
</condition>
|
||||
|
||||
<condition>
|
||||
<!--<action application="set" data="ringback=${ringback}"/>-->
|
||||
<action application="set" data="hangup_after_bridge=true"/>
|
||||
<!--<action application="set" data="continue_on_fail=NORMAL_TEMPORARY_FAILURE,USER_BUSY,NO_ANSWER,TIMEOUT,NO_ROUTE_DESTINATION"/> -->
|
||||
|
|
@ -31,7 +43,7 @@
|
|||
<action application="sleep" data="1000"/>
|
||||
<!--<action application="voicemail" data="default ${domain_name} ${dialed_extension}"/>-->
|
||||
<action application="set" data="voicemail_action=save"/>
|
||||
<action application="set" data="voicemail_id=$1"/>
|
||||
<action application="set" data="voicemail_id=${dialed_extension}"/>
|
||||
<action application="set" data="voicemail_profile=default"/>
|
||||
<action application="lua" data="app.lua voicemail"/>
|
||||
</condition>
|
||||
|
|
|
|||
|
|
@ -188,5 +188,53 @@ else {
|
|||
if ($c==0) { $c=1; } else { $c=0; }
|
||||
}
|
||||
echo "</table>\n";
|
||||
|
||||
|
||||
//Current logged members
|
||||
//set the alternating row styles
|
||||
$c = 0;
|
||||
$row_style["0"] = "row_style0";
|
||||
$row_style["1"] = "row_style1";
|
||||
|
||||
//response div tag
|
||||
echo "<div id='cmd_reponse'>\n";
|
||||
echo "</div>\n";
|
||||
echo "<br><br>Logged in agents<br><br>\n";
|
||||
|
||||
|
||||
//show the content
|
||||
echo "<table width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
|
||||
|
||||
|
||||
echo "<tr>\n";
|
||||
echo "<th>".$text['label-username']."</th>\n";
|
||||
echo "<th>Total inbound calls</th>\n";
|
||||
echo "<th>Logged on since</th>\n";
|
||||
echo "</tr>\n";
|
||||
|
||||
|
||||
//print_r($xml->fifo->outbound->member[0]);
|
||||
//print_r($xml->fifo->outbound->member[1]);
|
||||
|
||||
|
||||
foreach ($xml->fifo->outbound->member as $row) {
|
||||
|
||||
|
||||
|
||||
$username=explode("@",$row);
|
||||
$username=explode("/",$username[0]);
|
||||
$username=$username[1];
|
||||
|
||||
$fifo_duration_formatted=$row["logged-on-since"];
|
||||
$fifo_total_inbound_calls=$row["outbound-call-total-count"];
|
||||
|
||||
echo "<tr>\n";
|
||||
echo "<td valign='top' class='".$row_style[$c]."'>$username </td>\n";
|
||||
echo "<td valign='top' class='".$row_style[$c]."'>$fifo_total_inbound_calls </td>\n";
|
||||
echo "<td valign='top' class='".$row_style[$c]."'>$fifo_duration_formatted </td>\n";
|
||||
echo "</tr>\n";
|
||||
if ($c==0) { $c=1; } else { $c=0; }
|
||||
}
|
||||
echo "</table>\n";
|
||||
}
|
||||
?>
|
||||
|
|
|
|||
|
|
@ -100,7 +100,7 @@ echo " </td>";
|
|||
if (permission_exists('operator_panel_eavesdrop')) {
|
||||
echo " <td valign='top' nowrap='nowrap'>";
|
||||
if (sizeof($_SESSION['user']['extensions']) > 1) {
|
||||
echo " <input type='hidden' id='eavesdrop_dest' value=\"".(($_REQUEST['eavesdrop_dest'] == '') ? $_SESSION['user']['extensions'][0] : $_REQUEST['eavesdrop_dest'])."\">";
|
||||
echo " <input type='hidden' id='eavesdrop_dest' value=\"".(($_REQUEST['eavesdrop_dest'] == '') ? $_SESSION['user']['extension'][0]['destination'] : $_REQUEST['eavesdrop_dest'])."\">";
|
||||
echo " <img src='resources/images/eavesdrop.png' style='width: 12px; height: 12px; border: none; margin: 0px 5px; cursor: help;' title='".$text['description-eavesdrop_destination']."' align='absmiddle'>";
|
||||
echo " <select class='formfld' style='margin-right: 5px;' align='absmiddle' onchange=\"document.getElementById('eavesdrop_dest').value = this.options[this.selectedIndex].value; refresh_start();\" onfocus='refresh_stop();'>\n";
|
||||
foreach ($_SESSION['user']['extensions'] as $user_extension) {
|
||||
|
|
@ -109,7 +109,7 @@ if (permission_exists('operator_panel_eavesdrop')) {
|
|||
echo " </select>\n";
|
||||
}
|
||||
else if (sizeof($_SESSION['user']['extensions']) == 1) {
|
||||
echo " <input type='hidden' id='eavesdrop_dest' value=\"".$_SESSION['user']['extensions'][0]."\">";
|
||||
echo " <input type='hidden' id='eavesdrop_dest' value=\"".$_SESSION['user']['extension'][0]['destination']."\">";
|
||||
}
|
||||
echo " </td>";
|
||||
}
|
||||
|
|
@ -219,7 +219,12 @@ foreach ($activity as $extension => $ext) {
|
|||
$call_identifier = $ext['variable_bridge_uuid'];
|
||||
}
|
||||
else {
|
||||
$call_identifier = $ext['call_uuid']; // transfer all other call types
|
||||
if( $ext['call_uuid'] ) {
|
||||
$call_identifier = $ext['call_uuid']; // transfer all other call types
|
||||
}
|
||||
else {
|
||||
$call_identifier = $ext['uuid']; // e.g. voice menus
|
||||
}
|
||||
}
|
||||
|
||||
//determine extension draggable state
|
||||
|
|
@ -328,7 +333,7 @@ foreach ($activity as $extension => $ext) {
|
|||
}
|
||||
//eavesdrop
|
||||
if (permission_exists('operator_panel_eavesdrop') && $ext_state == 'active' && sizeof($_SESSION['user']['extensions']) > 0 && !in_array($extension, $_SESSION['user']['extensions'])) {
|
||||
$block .= "<img src='resources/images/eavesdrop.png' style='width: 12px; height: 12px; border: none; margin: 4px 0px 0px 5px; cursor: pointer;' title='".$text['label-eavesdrop']."' onclick=\"eavesdrop_call('".$extension."','".$call_identifier."');\" ".$onhover_pause_refresh.">";
|
||||
$block .= "<img src='resources/images/eavesdrop.png' style='width: 12px; height: 12px; border: none; margin: 4px 0px 0px 5px; cursor: pointer;' title='".$text['label-eavesdrop']."' onclick=\"eavesdrop_call('".$ext['destination']."','".$call_identifier."');\" ".$onhover_pause_refresh.">";
|
||||
}
|
||||
//kill
|
||||
if (permission_exists('operator_panel_kill') || in_array($extension, $_SESSION['user']['extensions'])) {
|
||||
|
|
|
|||
|
|
@ -85,6 +85,7 @@ function get_call_activity() {
|
|||
$array[$x]["call_uuid"] = null;
|
||||
$array[$x]["sent_callee_name"] = null;
|
||||
$array[$x]["sent_callee_num"] = null;
|
||||
$array[$x]["destination"] = null;
|
||||
|
||||
//add the active call details
|
||||
$found = false;
|
||||
|
|
@ -134,6 +135,7 @@ function get_call_activity() {
|
|||
$array[$x]["call_uuid"] = $field['call_uuid'];
|
||||
$array[$x]["sent_callee_name"] = $field['sent_callee_name'];
|
||||
$array[$x]["sent_callee_num"] = $field['sent_callee_num'];
|
||||
$array[$x]["destination"] = $user;
|
||||
|
||||
//calculate and set the call length
|
||||
$call_length_seconds = time() - $array[$x]["created_epoch"];
|
||||
|
|
|
|||
|
|
@ -69,9 +69,8 @@
|
|||
if (not default_voice) then default_voice = 'callie'; end
|
||||
|
||||
--get record_ext
|
||||
if (session:getVariable("record_ext")) then
|
||||
record_ext = session:getVariable("record_ext");
|
||||
else
|
||||
record_ext = session:getVariable("record_ext");
|
||||
if (not record_ext) then
|
||||
record_ext = "wav";
|
||||
end
|
||||
|
||||
|
|
@ -491,11 +490,23 @@
|
|||
session:execute("set", "hangup_after_bridge=true");
|
||||
session:execute("set", "continue_on_fail=true");
|
||||
|
||||
--set bind meta app
|
||||
session:execute("bind_meta_app", "1 ab s execute_extension::dx XML "..context);
|
||||
session:execute("bind_meta_app", "2 ab s record_session::"..recordings_dir.."/archive/"..os.date("%Y").."/"..os.date("%m").."/"..os.date("%d").."}/"..uuid..".wav");
|
||||
session:execute("bind_meta_app", "3 ab s execute_extension::cf XML "..context);
|
||||
session:execute("bind_meta_app", "4 ab s execute_extension::att_xfer XML "..context);
|
||||
local bind_target = 'both'
|
||||
-- if session:getVariable("sip_authorized") ~= "true" then
|
||||
-- bind_target = 'peer'
|
||||
-- end
|
||||
|
||||
--set bind digit action
|
||||
local record_file = recordings_dir.."/archive/"..os.date("%Y").."/"..os.date("%m").."/"..os.date("%d").."}/"..uuid.."."..record_ext
|
||||
local bindings = {
|
||||
"local,*1,exec:execute_extension,dx XML " .. context,
|
||||
"local,*2,exec:record_session," .. record_file,
|
||||
"local,*3,exec:execute_extension,cf XML " .. context,
|
||||
"local,*4,exec:execute_extension,att_xfer XML " .. context,
|
||||
}
|
||||
for _, str in ipairs(bindings) do
|
||||
session:execute("bind_digit_action", str .. "," .. bind_target)
|
||||
end
|
||||
session:execute("digit_action_set_realm", "local")
|
||||
|
||||
--if the user is busy rollover to the next destination
|
||||
if (ring_group_strategy == "rollover") then
|
||||
|
|
|
|||
|
|
@ -83,8 +83,13 @@ function load_extensions() {
|
|||
if (count($result) > 0) {
|
||||
$x = 0;
|
||||
foreach($result as $row) {
|
||||
$destination = $row['extension'];
|
||||
if (strlen($row['number_alias']) > 0) {
|
||||
$destination = $row['number_alias'];
|
||||
}
|
||||
$_SESSION['user']['extension'][$x]['user'] = $row['extension'];
|
||||
$_SESSION['user']['extension'][$x]['number_alias'] = $row['number_alias'];
|
||||
$_SESSION['user']['extension'][$x]['destination'] = $destination;
|
||||
$_SESSION['user']['extension'][$x]['extension_uuid'] = $row['extension_uuid'];
|
||||
$_SESSION['user']['extension'][$x]['outbound_caller_id_name'] = $row['outbound_caller_id_name'];
|
||||
$_SESSION['user']['extension'][$x]['outbound_caller_id_number'] = $row['outbound_caller_id_number'];
|
||||
|
|
|
|||
Loading…
Reference in New Issue