parent
7b401b39a0
commit
72094f870f
|
|
@ -17,46 +17,56 @@
|
|||
|
||||
The Initial Developer of the Original Code is
|
||||
Mark J Crane <markjcrane@fusionpbx.com>
|
||||
Portions created by the Initial Developer are Copyright (C) 2008-2015
|
||||
Portions created by the Initial Developer are Copyright (C) 2008-2016
|
||||
the Initial Developer. All Rights Reserved.
|
||||
|
||||
Contributor(s):
|
||||
Mark J Crane <markjcrane@fusionpbx.com>
|
||||
*/
|
||||
include "root.php";
|
||||
require_once "resources/require.php";
|
||||
require_once "resources/check_auth.php";
|
||||
require_once "./resources/functions/get_call_activity.php";
|
||||
if (permission_exists('operator_panel_view')) {
|
||||
//access granted
|
||||
}
|
||||
else {
|
||||
echo "access denied";
|
||||
exit;
|
||||
}
|
||||
|
||||
//includes
|
||||
include "root.php";
|
||||
require_once "resources/require.php";
|
||||
require_once "resources/check_auth.php";
|
||||
require_once "./resources/functions/get_call_activity.php";
|
||||
|
||||
//check permissions
|
||||
if (permission_exists('operator_panel_view')) {
|
||||
//access granted
|
||||
}
|
||||
else {
|
||||
echo "access denied";
|
||||
exit;
|
||||
}
|
||||
|
||||
//add multi-lingual support
|
||||
$language = new text;
|
||||
$text = $language->get();
|
||||
|
||||
$activity = get_call_activity();
|
||||
|
||||
if (is_array($activity)) foreach ($activity as $extension => $fields) {
|
||||
if (substr_count($fields['call_group'], ',')) {
|
||||
$tmp = explode(',', $fields['call_group']);
|
||||
if (is_array($tmp)) foreach ($tmp as $tmp_index => $tmp_value) {
|
||||
if (trim($tmp_value) == '') { unset($tmp[$tmp_index]); }
|
||||
else { $groups[] = $tmp_value; }
|
||||
//get the call activity
|
||||
$activity = get_call_activity();
|
||||
if (is_array($activity)) foreach ($activity as $extension => $fields) {
|
||||
if (substr_count($fields['call_group'], ',')) {
|
||||
$tmp = explode(',', $fields['call_group']);
|
||||
if (is_array($tmp)) foreach ($tmp as $tmp_index => $tmp_value) {
|
||||
if (trim($tmp_value) == '') { unset($tmp[$tmp_index]); }
|
||||
else { $groups[] = $tmp_value; }
|
||||
}
|
||||
}
|
||||
else if ($fields['call_group'] != '') {
|
||||
$groups[] = $fields['call_group'];
|
||||
}
|
||||
}
|
||||
else if ($fields['call_group'] != '') {
|
||||
$groups[] = $fields['call_group'];
|
||||
if (is_array($groups)) {
|
||||
$groups = array_unique($groups);
|
||||
sort($groups);
|
||||
}
|
||||
}
|
||||
if (is_array($groups)) {
|
||||
$groups = array_unique($groups);
|
||||
sort($groups);
|
||||
}
|
||||
|
||||
//prevent warnings
|
||||
if (!is_array($_SESSION['user']['extensions'])) {
|
||||
$_SESSION['user']['extensions'] = array();
|
||||
}
|
||||
|
||||
|
||||
$onhover_pause_refresh = " onmouseover='refresh_stop();' onmouseout='refresh_start();'";
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue