Adding the QUEUENAME variable to the variables set using the setqueuevar option
authorMark Michelson <mmichelson@digium.com>
Mon, 21 Jan 2008 22:32:13 +0000 (22:32 +0000)
committerMark Michelson <mmichelson@digium.com>
Mon, 21 Jan 2008 22:32:13 +0000 (22:32 +0000)
in queues.conf.

Suggestion comes from Shaun2222 on IRC.

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@99406 65c4cc65-6c06-0410-ace0-fbb531ad65f3

apps/app_queue.c
configs/queues.conf.sample

index a2db787..a6b2d3f 100644 (file)
@@ -570,8 +570,8 @@ static void set_queue_variables(struct queue_ent *qe)
                sl = 100 * ((float) qe->parent->callscompletedinsl / (float) qe->parent->callscompleted);
 
        snprintf(interfacevar,sizeof(interfacevar),
-               "QUEUEMAX=%d|QUEUESTRATEGY=%s|QUEUECALLS=%d|QUEUEHOLDTIME=%d|QUEUECOMPLETED=%d|QUEUEABANDONED=%d|QUEUESRVLEVEL=%d|QUEUESRVLEVELPERF=%2.1f",
-               qe->parent->maxlen, int2strat(qe->parent->strategy), qe->parent->count, qe->parent->holdtime, qe->parent->callscompleted,
+               "QUEUENAME=%s|QUEUEMAX=%d|QUEUESTRATEGY=%s|QUEUECALLS=%d|QUEUEHOLDTIME=%d|QUEUECOMPLETED=%d|QUEUEABANDONED=%d|QUEUESRVLEVEL=%d|QUEUESRVLEVELPERF=%2.1f",
+               qe->parent->name, qe->parent->maxlen, int2strat(qe->parent->strategy), qe->parent->count, qe->parent->holdtime, qe->parent->callscompleted,
                qe->parent->callsabandoned,  qe->parent->servicelevel, sl);
        
        pbx_builtin_setvar(qe->chan, interfacevar); 
index 92c3237..fb4e9bd 100644 (file)
@@ -173,6 +173,7 @@ shared_lastcall=no
 ; If set to yes, the following variables will be set
 ; just prior to the caller being bridged with a queue member
 ; and just prior to the caller leaving the queue
+; QUEUENAME name of the queue
 ; QUEUEMAX maxmimum number of calls allowed
 ; QUEUESTRATEGY the strategy of the queue; 
 ; QUEUECALLS number of calls currently in the queue