当前位置: 首页>>代码示例>>PHP>>正文


PHP FreePBX::Core方法代码示例

本文整理汇总了PHP中FreePBX::Core方法的典型用法代码示例。如果您正苦于以下问题:PHP FreePBX::Core方法的具体用法?PHP FreePBX::Core怎么用?PHP FreePBX::Core使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在FreePBX的用法示例。


在下文中一共展示了FreePBX::Core方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getSections

 public function getSections()
 {
     $sections = array();
     $users = \FreePBX::Core()->listUsers(true);
     $ret = array();
     $ret['title'] = _("Users");
     $featurecodes = \featurecodes_getAllFeaturesDetailed();
     $ret['textdesc'] = _('User');
     $ret['numdesc'] = _('Extension');
     $ret['items'] = array();
     foreach ($users as $user) {
         $ret['items'][] = array($user[1], $user[0]);
     }
     $sections[] = $ret;
     $hookdata = \FreePBX::Hooks()->processHooks();
     foreach ($hookdata as $key => $value) {
         $sections[] = $value;
     }
     $html .= '<div class="row holder">';
     $html .= '<div class="col-sm-12">';
     foreach ($sections as $k => $v) {
         $html .= '<div class="row">';
         $html .= '<h3>' . $v['title'] . '</h3>';
         $html .= '<ul class="list-group">';
         foreach ($v['items'] as $item) {
             $html .= '	<li class="list-group-item col-sm-6"><b>' . $item[1] . '</b> - ' . $item[0] . '</li>';
         }
         $html .= '</ul>';
         $html .= '<br/>';
         $html .= '	</div>';
     }
     $html .= '</div>';
     $html .= '</div>';
     return $html;
 }
开发者ID:ringfreejohn,项目名称:pbxframework,代码行数:35,代码来源:Printextensions.class.php

示例2: getRightNav

 /**
  * Get Right Nav
  * @param  array $request The request
  * @return string          The Right nav html
  */
 public function getRightNav($request)
 {
     $display_mode = "advanced";
     $mode = $this->freepbx->Config()->get("FPBXOPMODE");
     if (!empty($mode)) {
         $display_mode = $mode;
     }
     switch ($request['display']) {
         case 'extensions':
         case 'devices':
             $popover = isset($request['fw_popover']) ? "&amp;fw_popover=" . $request['fw_popover'] : '';
             $show = isset($request['tech_hardware']) || isset($request['view']) && $request['view'] == "add" || isset($request['extdisplay']) && trim($request['extdisplay']) != "";
             if ($display_mode == "basic" && (!isset($request['extdisplay']) || trim($request['extdisplay']) == "")) {
                 return array();
             }
             return load_view(__DIR__ . "/views/rnav.php", array("show" => $show, "display" => $request['display'], "popover" => $popover));
             break;
         case 'trunks':
             if (isset($request['tech']) || isset($request['extdisplay']) && !empty($request['extdisplay'])) {
                 $html = load_view(__DIR__ . '/views/trunks/bootnav.php', array('trunk_types' => \FreePBX::Core()->listTrunkTypes()));
                 return $html;
             }
             break;
         case 'did':
             if (isset($request['view'])) {
                 $html = load_view(__DIR__ . '/views/did/rnav.php');
                 return $html;
             }
             break;
         case 'routing':
             if (isset($request['view'])) {
                 $html = load_view(__DIR__ . '/views/routing/bootnav.php');
                 return $html;
             }
             break;
         case 'dahdichandids':
             if (isset($request['view'])) {
                 $html = load_view(__DIR__ . '/views/dahdichandids/bootnav.php');
                 return $html;
             }
             break;
         case 'ampusers':
             $html = load_view(__DIR__ . '/views/ampusers/bootnav.php');
             return $html;
             break;
     }
 }
开发者ID:lidl,项目名称:core,代码行数:52,代码来源:Core.class.php

示例3: _

    ?>
</th>
										<th data-sortable="true" data-field="tech"><?php 
    echo _('Tech Type');
    ?>
</th>
										<th data-field="actions"><?php 
    echo _('Actions');
    ?>
</th>
									</tr>
								</thead>
							</table>
						</div>
						<?php 
    foreach (FreePBX::Core()->getAllDriversInfo() as $driver) {
        ?>
							<div id="toolbar-<?php 
        echo $driver['rawName'];
        ?>
">
								<button id="remove-<?php 
        echo $driver['rawName'];
        ?>
" class="btn btn-danger btn-remove" data-type="devices" data-section="<?php 
        echo $driver['rawName'];
        ?>
" disabled>
									<i class="glyphicon glyphicon-remove"></i> <span><?php 
        echo _('Delete');
        ?>
开发者ID:lidl,项目名称:core,代码行数:31,代码来源:page.devices.php

示例4: show_view

 // Added to enable the unsupported misdn module
 case "misdn":
     if (function_exists('misdn_groups_ports')) {
         show_view(dirname(__FILE__) . '/views/trunks/misdn.php', $displayvars);
     }
     break;
     //--------------------------------------------------------------------------------------
 //--------------------------------------------------------------------------------------
 case "custom":
     show_view(dirname(__FILE__) . '/views/trunks/custom.php', $displayvars);
     break;
 case "dundi":
     show_view(dirname(__FILE__) . '/views/trunks/dundi.php', $displayvars);
     break;
 case "pjsip":
     $pjsip = FreePBX::Core()->getDriver('pjsip');
     if ($pjsip !== false) {
         // Mangle displayvars if needed.
         $displayvars = $pjsip->getDisplayVars($extdisplay, $displayvars);
         show_view(dirname(__FILE__) . '/views/trunks/pjsip.php', $displayvars);
     }
     break;
 case "iax":
 case "iax2":
 case "sip":
     $displayvars['peerdetails'] = $peerdetails;
     $displayvars['usercontext'] = $usercontext;
     $displayvars['userconfig'] = $userconfig;
     $displayvars['register'] = $register;
     $displayvars['peerdetails'] = $peerdetails;
     show_view(dirname(__FILE__) . '/views/trunks/sip.php', $displayvars);
开发者ID:ringfreejohn,项目名称:pbxframework,代码行数:31,代码来源:page.trunks.php

示例5: isset

\t\t\t\t</div>
\t\t\t</div>
\t\t</div>
\t</div>
\t<div class="row">
\t\t<div class="col-md-12">
\t\t\t<span id="mohclass-help" class="help-block fpbx-help-block">{$mohhelp}</span>
\t\t</div>
\t</div>
</div>
<!--END Music On Hold-->
HERE;
}
echo $heading;
echo isset($userlink) ? $userlink : '';
$hooks = \FreePBX::Core()->hookTabs($_REQUEST['display']);
?>

<form name="editGRP" class="fpbx-submit" action="config.php?display=did" method="post"  data-fpbx-delete="?display=did&amp;extdisplay=<?php 
echo $extdisplay;
?>
&amp;action=delIncoming&amp;didfilter=<?php 
echo $didfilter;
?>
&amp;rnavsort=<?php 
echo $rnavsort;
?>
">
	<input type="hidden" name="display" value="did">
	<input type="hidden" name="action" value="<?php 
echo $extdisplay ? 'edtIncoming' : 'addIncoming';
开发者ID:lidl,项目名称:core,代码行数:31,代码来源:advanced_form.php

示例6: voicemail_dialvoicemail

function voicemail_dialvoicemail($c)
{
    global $ext, $amp_conf, $astman;
    $id = "app-dialvm";
    // The context to be included
    $ext->addInclude('from-internal-additional', $id);
    // Add the include from from-internal
    $ext->add($id, $c, '', new ext_macro('user-callerid'));
    $ext->add($id, $c, '', new ext_set('CONNECTEDLINE(name-charset,i)', 'utf8'));
    $ext->add($id, $c, '', new ext_set('CONNECTEDLINE(name,i)', _("Dial Voicemail")));
    $ext->add($id, $c, '', new ext_set('CONNECTEDLINE(num,i)', '${EXTEN}'));
    $ext->add($id, $c, '', new ext_answer(''));
    $ext->add($id, $c, 'start', new ext_wait('1'));
    $ext->add($id, $c, '', new ext_noop($id . ': Asking for mailbox'));
    $ext->add($id, $c, '', new ext_read('MAILBOX', 'vm-login', '', '', 3, 2));
    $ext->add($id, $c, 'check', new ext_noop($id . ': Got Mailbox ${MAILBOX}'));
    $ext->add($id, $c, '', new ext_macro('get-vmcontext', '${MAILBOX}'));
    $ext->add($id, $c, '', new ext_vmexists('${MAILBOX}@${VMCONTEXT}'));
    $ext->add($id, $c, '', new ext_gotoif('$["${VMBOXEXISTSSTATUS}" = "SUCCESS"]', 'good', 'bad'));
    $ext->add($id, $c, '', new ext_macro('hangupcall'));
    $ext->add($id, $c, 'good', new ext_noop($id . ': Good mailbox ${MAILBOX}@${VMCONTEXT}'));
    //$ext->add($id, $c, '', new ext_set('CONNECTEDLINE(num)','${MAILBOX}')); //makes audio stutter on the phone
    $ext->add($id, $c, '', new ext_vmmain('${MAILBOX}@${VMCONTEXT}'));
    $ext->add($id, $c, '', new ext_gotoif('$["${IVR_RETVM}" = "RETURN" & "${IVR_CONTEXT}" != ""]', 'playret'));
    $ext->add($id, $c, '', new ext_macro('hangupcall'));
    $ext->add($id, $c, 'bad', new ext_noop($id . ': BAD mailbox ${MAILBOX}@${VMCONTEXT}'));
    $ext->add($id, $c, '', new ext_wait('1'));
    $ext->add($id, $c, '', new ext_noop($id . ': Asking for password so people can\'t probe for existence of a mailbox'));
    $ext->add($id, $c, '', new ext_read('FAKEPW', 'vm-password', '', '', 3, 2));
    $ext->add($id, $c, '', new ext_noop($id . ': Asking for mailbox again'));
    $ext->add($id, $c, '', new ext_read('MAILBOX', 'vm-incorrect-mailbox', '', '', 3, 2));
    $ext->add($id, $c, '', new ext_goto('check'));
    $ext->add($id, $c, '', new ext_macro('hangupcall'));
    $ext->add($id, $c, 'playret', new ext_playback('beep&you-will-be-transfered-menu&silence/1'));
    $ext->add($id, $c, '', new ext_goto('1', 'return', '${IVR_CONTEXT}'));
    //res_mwi_blf allows you to subscribe to voicemail hints, the following code generates the dialplan for doing so
    if ($astman->connected()) {
        $resmwiblf_check = $astman->send_request('Command', array('Command' => 'module show like res_mwi_blf'));
        $resmwiblf_module = preg_match('/[1-9] modules loaded/', $resmwiblf_check['data']);
        if (!$resmwiblf_module) {
            $resmwiblf_check = $astman->send_request('Command', array('Command' => 'module show like res_mwi_devstate'));
            $resmwiblf_module = preg_match('/[1-9] modules loaded/', $resmwiblf_check['data']);
        }
    }
    if ($resmwiblf_module && $amp_conf['USERESMWIBLF']) {
        // TODO: PUT THIS BACK
        $userlist = FreePBX::Core()->getAllUsers();
        if (is_array($userlist)) {
            foreach ($userlist as $item) {
                $vm = $item['voicemail'] == "novm" || $item['voicemail'] == "disabled" || $item['voicemail'] == "" ? "novm" : $item['extension'];
                if ($vm != "novm") {
                    $ext->add($id, $c . $vm, '', new ext_goto('1', 'dvm${EXTEN:' . strlen($c) . '}'));
                    //$ext->addHint($id, $c.$vm, 'MWI:'.$vm.'@'.$item['voicemail']);
                }
            }
            $c_len = strlen($c);
            //$ext->add($id, "_$c".'X.', '', new ext_noop("This extension does not have access to this"));
            //
            $ext->addHint($id, "_{$c}" . 'X.', 'MWI:${EXTEN:' . $c_len . '}@${DB(AMPUSER/${EXTEN:' . $c_len . '}/voicemail)}');
        }
        $c = '_dvm.';
    } else {
        // Note that with this one, it has paramters. So we have to add '_' to the start and '.' to the end
        // of $c
        $c = "_{$c}.";
    }
    // How long is the command? We need to strip that off the front
    $clen = strlen($c) - 2;
    $ext->add($id, $c, '', new ext_set('CONNECTEDLINE(name-charset,i)', 'utf8'));
    $ext->add($id, $c, '', new ext_set('CONNECTEDLINE(name,i)', _("Dial Voicemail")));
    $ext->add($id, $c, '', new ext_set('CONNECTEDLINE(num,i)', '${EXTEN:' . $clen . '}'));
    $ext->add($id, $c, '', new ext_answer(''));
    // $cmd,1,Answer
    $ext->add($id, $c, '', new ext_wait('1'));
    // $cmd,n,Wait(1)
    $ext->add($id, $c, '', new ext_macro('get-vmcontext', '${EXTEN:' . $clen . '}'));
    $ext->add($id, $c, '', new ext_vmmain('${EXTEN:' . $clen . '}@${VMCONTEXT}'));
    // n,VoiceMailMain(${VMCONTEXT})
    $ext->add($id, $c, '', new ext_gotoif('$["${IVR_RETVM}" = "RETURN" & "${IVR_CONTEXT}" != ""]', '${IVR_CONTEXT},return,1'));
    $ext->add($id, $c, '', new ext_macro('hangupcall'));
    // $cmd,n,Macro(user-callerid)
}
开发者ID:ringfreejohn,项目名称:pbxframework,代码行数:82,代码来源:functions.inc.php

示例7: core_devices_configprocess

function core_devices_configprocess()
{
    if (!class_exists('agi_asteriskmanager')) {
        include 'common/php-asmanager.php';
    }
    //make sure we can connect to Asterisk Manager
    if (!checkAstMan()) {
        return false;
    }
    //create vars from the request
    $tech = $action = null;
    extract($_REQUEST);
    if ($tech == "virtual" || $action == "edit" && $tech == '') {
        return true;
    }
    $extension = isset($extension) ? $extension : null;
    $deviceid = isset($deviceid) ? $deviceid : null;
    $name = isset($name) ? $name : null;
    $action = isset($action) ? $action : null;
    // fixed users only in extensions mode
    if ($display == 'extensions') {
        $devicetype = 'fixed';
        $deviceid = $deviceuser = $extension;
        $description = $name;
    }
    //if submitting form, update database
    switch ($action) {
        case "add":
            // really bad hack - but if core_users_add fails, want to stop core_devices_add
            if (!isset($GLOBALS['abort']) || $GLOBALS['abort'] !== true || !$_SESSION["AMP_user"]->checkSection('999')) {
                if (core_devices_add($deviceid, $tech, $devinfo_dial, $devicetype, $deviceuser, $description, $emergency_cid)) {
                    needreload();
                    if ($deviceuser == 'new') {
                        //redirect_standard_continue();
                    }
                }
            } else {
                // This is a bit messy, because by this time, other modules may have added the device but this tries to block
                // the user who does not have add permission from adding a new extension.
                //
                $GLOBALS['abort'] = true;
            }
            break;
        case "del":
            core_devices_del($extdisplay);
            //$_REQUEST['exdisplay'] = isset($_REQUEST['exdisplay'])?NULL:'';
            //$_REQUEST['action'] = isset($_REQUEST['action'])?NULL:'';
            needreload();
            redirect_standard_continue();
            break;
        case "edit":
            //just delete and re-add
            // really bad hack - but if core_users_edit fails, want to stop core_devices_edit
            if (!isset($GLOBALS['abort']) || $GLOBALS['abort'] !== true) {
                //delete then re add, insanity.
                core_devices_del($extdisplay, true);
                //PJSIP <--> CHAN_SIP Switcher, not the best but better than it was before and lets us continue forward into PHP 5.5
                if (isset($_REQUEST['changesipdriver']) && !empty($_REQUEST['devinfo_sipdriver']) && ($tech == 'pjsip' || $tech == 'sip')) {
                    $tech = $_REQUEST['devinfo_sipdriver'] == 'chan_sip' ? 'sip' : 'pjsip';
                    $rtech = $_REQUEST['devinfo_sipdriver'] == 'chan_sip' ? 'pjsip' : 'sip';
                    $devinfo_dial = preg_replace('/^' . $rtech . '\\/' . $deviceid . '$/i', strtoupper($tech) . '/' . $deviceid, $devinfo_dial);
                    $flag = 2;
                    $fields = FreePBX::Core()->convertRequest2Array($deviceid, $tech, $flag);
                    $settings = array("dial" => array("value" => $devinfo_dial, "flag" => isset($fields['dial']['flag']) ? $fields['dial']['flag'] : $flag++), "devicetype" => array("value" => $devicetype, "flag" => isset($fields['devicetype']['flag']) ? $fields['devicetype']['flag'] : $flag++), "user" => array("value" => $deviceuser, "flag" => isset($fields['deviceuser']['flag']) ? $fields['deviceuser']['flag'] : $flag++), "description" => array("value" => $description, "flag" => isset($fields['description']['flag']) ? $fields['description']['flag'] : $flag++), "emergency_cid" => array("value" => $emergency_cid, "flag" => isset($fields['emergency_cid']['flag']) ? $fields['emergency_cid']['flag'] : $flag++));
                    $settings = array_merge($fields, $settings);
                    return FreePBX::Core()->addDevice($deviceid, $tech, $settings, true);
                } else {
                    core_devices_add($deviceid, $tech, $devinfo_dial, $devicetype, $deviceuser, $description, $emergency_cid, true);
                }
                needreload();
                //redirect_standard_continue('extdisplay');
            }
            break;
        case "resetall":
            //form a url with this option to nuke the AMPUSER & DEVICE trees and start over.
            core_users2astdb();
            core_devices2astdb();
            break;
    }
    return true;
}
开发者ID:lidl,项目名称:core,代码行数:81,代码来源:functions.inc.php

示例8: function

            ?>
							<?php 
            echo !empty($pageDisplay['validate']) ? $pageDisplay['validate'] : '';
            ?>
						<?php 
        }
        ?>
					}
				<?php 
    }
    ?>
				return true;
			},
			onFinish: function(obj, context) {
				<?php 
    foreach (FreePBX::Core()->getQuickCreateDisplay() as $page => $data) {
        ?>
					<?php 
        foreach ($data as $pageDisplay) {
            ?>
						<?php 
            echo !empty($pageDisplay['validate']) ? $pageDisplay['validate'] : '';
            ?>
					<?php 
        }
        ?>
				<?php 
    }
    ?>
				var data = {};
				$("#quickCreate form input[type=text], #quickCreate form input[type=number], #quickCreate form input[type=email], #quickCreate form input[type=password], #quickCreate form input[type=radio]:checked, #quickCreate form select").each(function() {
开发者ID:lidl,项目名称:core,代码行数:31,代码来源:page.extensions.php

示例9: core_routing_list

            $intracompany = $route_info['intracompany_route'];
            $mohsilence = $route_info['mohclass'];
            $outcid = $route_info['outcid'];
            $outcid_mode = $route_info['outcid_mode'];
            $time_group_id = $route_info['time_group_id'];
            $route_seq = $route_info['seq'];
            $routename = $route_info['name'];
            $dest = $route_info['dest'];
            $routelist = core_routing_list();
            $viewinfo = array('formAction' => 'editroute', 'extdisplay' => $extdisplay, 'id' => $id, 'route_info' => $route_info, 'dialpattern_array' => $dialpattern_array, 'trunkpriority' => $trunkpriority, 'routepass' => $routepass, 'emergency' => $emergency, 'intracompany' => $intracompany, 'mohsilence' => $mohsilence, 'outcid' => $outcid, 'outcid_mode' => $outcid_mode, 'time_group_id' => $time_group_id, 'route_seq' => $route_seq, 'routename' => $routename, 'dest' => $dest, 'hooks' => \FreePBX::Core()->hookTabs($request['display']));
        } else {
            $route_seq = $last_seq + 1;
            if (!isset($dialpattern_array)) {
                $dialpattern_array = array();
            }
            $viewinfo = array('formAction' => 'addroute', 'route_seq' => $route_seq, 'dialpattern_array' => $dialpattern_array, 'trunkpriority' => $trunkpriority, 'hooks' => \FreePBX::Core()->hookTabs($request['display']));
        }
        $content = load_view(__DIR__ . '/views/routing/form.php', $viewinfo);
        $pageinfo = '';
        break;
    default:
        //$pageinfo = '';
        $routelist = core_routing_list();
        $content = load_view(__DIR__ . '/views/routing/grid.php', array('routelist' => $routelist));
        break;
}
?>

<div class="container-fluid">
	<h1><?php 
echo _('Outbound Routes');
开发者ID:lidl,项目名称:core,代码行数:31,代码来源:page.routing.php

示例10: accountcodepreserve_hookGet_config

function accountcodepreserve_hookGet_config($engine)
{
    global $ext;
    global $astman;
    global $active_modules;
    switch ($engine) {
        case "asterisk":
            /* set the inheritable channel variable to the callee's accountcode if there is one. Then it will be available in any outbound
                 trunk calls replacing the code of the user who is making the call. This way a CF situation results in the CF user's account code.
                 With typical calls, the callee will be ARG2 of macro-exten-vm so if coming from there, use that. Otherwise it will be the
                 EXTEN that called this macro (such as a followme) so we use MACRO_EXTEN.
               */
            $priority = 'report2';
            $ext->splice('macro-user-callerid', 's', $priority, new ext_execif('$["${CALLEE_ACCOUNCODE}" = ""]', 'Set', '__CALLEE_ACCOUNCODE=${DB(AMPUSER/${IF($["${MACRO_CONTEXT}"="macro-exten-vm"]?${ARG2}:${MACRO_EXTEN})}/accountcode)}'));
            /* check and set the account code in every route (so we don't have to do it in every trunk in case there are fail-over trunks
             */
            if (function_exists('core_routing_getroutepatternsbyid')) {
                // 2.8+ schema version
                //
                $routes = core_routing_list();
                foreach ($routes as $route) {
                    $patterns = core_routing_getroutepatternsbyid($route['route_id']);
                    $context = 'outrt-' . $route['route_id'];
                    foreach ($patterns as $pattern) {
                        $fpattern = core_routing_formatpattern($pattern);
                        $extension = $fpattern['dial_pattern'];
                        $ext->splice($context, $extension, 2, new ext_execif('$[ "${CALLEE_ACCOUNCODE}" != "" ] ', 'Set', 'CDR(accountcode)=${CALLEE_ACCOUNCODE}'));
                    }
                }
            } else {
                // 2.7- schema version
                //
                $route_list = core_routing_getroutenames();
                foreach ($route_list as $route) {
                    $context = 'outrt-' . $route[0];
                    $patterns = core_routing_getroutepatterns($route[0]);
                    foreach ($patterns as $rt) {
                        //strip the pipe out as that's what we use for the dialplan extension
                        $extension = str_replace('|', '', $rt);
                        // If there are any wildcards in there, add a _ to the start
                        if (preg_match("/\\.|z|x|\\[|\\]/i", $extension)) {
                            $extension = "_" . $extension;
                        }
                        $ext->splice($context, $extension, 0, new ext_execif('$[ "${CALLEE_ACCOUNCODE}" != "" ] ', 'Set', 'CDR(accountcode)=${CALLEE_ACCOUNCODE}'));
                    }
                }
            }
            /* Now lookup each device that has an account code set and create the AMPUSER/user/accountcode key for that user based on the
                     first device that we see associated with them. If multiple devices point to the same user, the code used will only be one of them.
            
                     TODO: note this is fine for extension mode assuming there is always a 1-to-1 mapping of device/user. For deviceanduser mode
                           it would be necessary to have accountcodes stored with the user and not with the device. And then macro-user-callerid
                           would need to set the account code for each user on all calls, just like it does with the language module. (Meaning
                           a need to splice a new field into the user. This would not be hard to do, basically an almost exact cut-and-paste of
                           the language module code that handles the user gui hook for the language in extensions/users.
                   */
            $account_codes = array();
            $devices = FreePBX::Core()->getAllDevicesByType();
            if (!empty($devices) && is_array($devices)) {
                foreach ($devices as $device) {
                    if ($device['user'] != 'none' && $device['tech'] != 'custom') {
                        $dev_props = core_devices_get($device['user']);
                        if (isset($dev_props['accountcode']) && $dev_props['accountcode'] != '') {
                            $account_codes[$device['user']] = $dev_props['accountcode'];
                        }
                    }
                }
            }
            foreach ($account_codes as $user => $accountcode) {
                $astman->database_put("AMPUSER", $user . "/accountcode", $accountcode);
                /*
                				// database_put is expensive so read it first and only write if it's been changed
                				//
                				$old_code = trim($astman->database_get("AMPUSER",$user."/accountcode"));
                				if ($old_code != trim($accountcode)) {
                		  		$astman->database_put("AMPUSER",$user."/accountcode",$accountcode);
                				}
                */
            }
            unset($account_codes);
            unset($devices);
            break;
    }
}
开发者ID:ringfreejohn,项目名称:pbxframework,代码行数:84,代码来源:functions.inc.php

示例11: _

			</div>
		</div>
		<div class="row">
			<div class="col-md-12">
				<span id="agentannounce_id-help" class="help-block fpbx-help-block">' . _("Announcement played to the Agent prior to bridging in the caller <br><br> Example: \"the Following call is from the Sales Queue\" or \"This call is from the Technical Support Queue\".<br><br>To add additional recordings please use the \"System Recordings\" MENU. Compound recordings composed of 2 or more sound files are not displayed as options since this feature can not accept such recordings.") . '</span>
			</div>
		</div>
	</div>
	<!--END Agent Announcement-->
	';
} else {
    $ccahtml = '<input type="hidden" name="callconfirm_id" value="' . $default . '">';
}
//Used for the agent quick select boxes.
//$results = core_users_list();
$results = \FreePBX::Core()->listUsers();
$results = is_array($results) ? $results : array();
$qsagentlist = '';
foreach ($results as $result) {
    $qsagentlist .= "<option value='" . $result[0] . "'>" . $result[0] . " (" . $result[1] . ")</option>\n";
}
//Ring Strategy
$strategyhelphtml = '<b>' . _("ringall") . '</b>: ' . _("ring all available agents until one answers (default)") . '<br>';
$strategyhelphtml .= '<b>' . _("leastrecent") . '</b>: ' . _("ring agent which was least recently called by this queue") . '<br>';
$strategyhelphtml .= '<b>' . _("fewestcalls") . '</b>: ' . _("ring the agent with fewest completed calls from this queue") . '<br>';
$strategyhelphtml .= '<b>' . _("random") . '</b>: ' . _("ring random agent") . '<br>';
$strategyhelphtml .= '<b>' . _("rrmemory") . '</b>: ' . _("round robin with memory, remember where we left off last ring pass") . '<br>';
$strategyhelphtml .= '<b>' . _("rrordered") . '</b>: ' . _("same as rrmemory, except the queue member order from config file is preserved") . '<br>';
$strategyhelphtml .= '<b>' . _("linear") . '</b>: ' . _("rings agents in the order specified, for dynamic agents in the order they logged in") . '<br>';
$strategyhelphtml .= '<b>' . _("wrandom") . '</b>: ' . _("random using the member's penalty as a weighting factor, see asterisk documentation for specifics") . '<br>';
$default = isset($strategy) ? $strategy : 'ringall';
开发者ID:ringfreejohn,项目名称:pbxframework,代码行数:31,代码来源:form.php


注:本文中的FreePBX::Core方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。