text stringlengths 0 152 |
|---|
; Note that we've used '^' as our delimiter |
same => n,Set(WorkingQueue=${CUT(AvailableQueues,^,${QueueCounter})}) |
; While the WorkingQueue channel variable contains a value, loop |
same => n,While($[${EXISTS(${WorkingQueue})}]) |
; AddQueueMember(queuename[,interface[,penalty[,options[,membername |
; [,stateinterface]]]]]) |
; Add the channel to a queue, setting the interface for calling |
; and the interface for monitoring of device state |
; *** This should all be on a single line |
same => n,AddQueueMember( |
${WorkingQueue},${MemberChanType}/${MemberChannel},,,${MemberChanType}/${MemberChannel}) |
same => n,Set(QueueCounter=$[${QueueCounter} + 1]) ; increase our counter |
; get the next available queue; if it is null our loop will end |
same => n,Set(WorkingQueue=${CUT(AvailableQueues,^,${QueueCounter})}) |
same => n,EndWhile() |
; let the agent know they were logged in okay |
same => n,Playback(silence/1&agent-loginok) |
same => n,Hangup() |
Queue Members |
| |
221 |
exten => no_queues_available,1,Verbose(2,No queues available for ${MemberChannel}) |
same => n,Playback(silence/1&channel¬-yet-assigned) |
same => n,Hangup() |
; Used for logging agents out of all configured queues per the AstDB |
exten => *737,1,Verbose(2,Logging out of multiple queues) |
; Because we reused some code, we've placed the duplicate code into a subroutine |
same => n,GoSub(subSetupAvailableQueues,start,1()) |
same => n,Set(QueueCounter=1) |
same => n,Set(WorkingQueue=${CUT(AvailableQueues,^,${QueueCounter})}) |
same => n,While($[${EXISTS(${WorkingQueue})}]) |
same => n,RemoveQueueMember(${WorkingQueue},${MemberChanType}/${MemberChannel}) |
same => n,Set(QueueCounter=$[${QueueCounter} + 1]) |
same => n,Set(WorkingQueue=${CUT(AvailableQueues,^,${QueueCounter})}) |
same => n,EndWhile() |
same => n,Playback(silence/1&agent-loggedoff) |
same => n,Hangup() |
; Used for pausing agents in all available queues |
exten => *738,1,Verbose(2,Pausing member in all queues) |
same => n,GoSub(subSetupAvailableQueues,start,1()) |
; if we don't define a queue, the member is paused in all queues |
same => n,PauseQueueMember(,${MemberChanType}/${MemberChannel}) |
same => n,GotoIf($[${PQMSTATUS} = PAUSED]?agent_paused,1:agent_not_found,1) |
exten => agent_paused,1,Verbose(2,Agent paused successfully) |
same => n,Playback(dictate/paused) |
same => n,Hangup() |
; Used for unpausing agents in all available queues |
exten => *739,1,Verbose(2,UnPausing member in all queues) |
same => n,GoSub(subSetupAvailableQueues,start,1()) |
; if we don't define a queue, then the member is unpaused from all queues |
same => n,UnPauseQueueMember(,${MemberChanType}/${MemberChannel}) |
same => n,GotoIf($[${UPQMSTATUS} = UNPAUSED]?agent_unpaused,1:agent_not_found,1) |
exten => agent_unpaused,1,Verbose(2,Agent paused successfully) |
same => n,Playback(silence/1&available) |
; Used by both pausing and unpausing dialplan functionality |
exten => agent_not_found,1,Verbose(2,Agent was not found) |
same => n,Playback(silence/1&cannot-complete-as-dialed) |
You could further refine these login and logout routines to take into account that the |
AQMSTATUS and RQMSTATUS channel variables are set each time AddQueueMember() and |
RemoveQueueMember() are used. For example, you could set a flag that lets the queue |
member know they have not been added to a queue, or even add recordings or text- |
to-speech systems to play back the particular queue that is producing the problem. |
Or, if you’re monitoring this via the Asterisk Manager Interface, you could have a |
screen pop, or use JabberSend() to inform the queue member via instant messaging, |
or…(ain’t Asterisk fun?). |
222 |
| |
Chapter 12: Automatic Call Distribution Queues |
Advanced Queues |
In this section we’ll take a look at some of the finer-grained queue controls, such as |
options for controlling announcements and when callers should be placed into (or |
removed from) the queue. We’ll also look at penalties and priorities, exploring how |
we can control the agents in our queue by giving preference to a pool of agents, and |
then increasing that pool dynamically based on the wait times in the queue. Finally, |
we’ll look at using local channels as queue members, which gives us the ability to per‐ |
form dialplan tricks prior to connecting the caller to an agent. |
Priority Queue (Queue Weighting) |
Sometimes you need to add people to a queue at a higher priority than that given to |
other callers. Perhaps the caller has already spent time waiting in a queue, and an |
agent has taken some information but realized the caller needed to be transferred to |
another queue. In this case, to minimize the caller’s overall wait time, it might be |
desirable to transfer the call to a priority queue that has a higher weight (and thus a |
higher preference), so it will be answered quickly. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.