[asterisk-dev] Which channel answer call in Queue
Mark Michelson
mmichelson at digium.com
Fri Mar 6 15:49:11 CST 2009
Milad Rastian wrote:
> Hi,
> In a project we need know which channel answer call in Queue
> I patch app/app_queue.c
>
> I add line
> pbx_builtin_setvar_helper(qe->chan, "AGENT_CHANNEL", member->membername);
>
> after line
> app = pbx_findapp("agi");
> about line 2976
>
> I think this info is important in many case
> It's simple an useful feature
>
> If you add this it's nice.
> what's your opinion ?
>
This functionality already exists. Look in the try_calling function in app_queue
for "setinterfacevar" . If you're using Asterisk 1.4, you'll see that this sets
the channel variable MEMBERINTERFACE to the interface of the queue member that
answered the call. If you're using Asterisk 1.6, there are a bunch of other
channel variables set as well, one of which is MEMBERNAME. MEMBERNAME contains
exactly what you are proposing in your message.
Mark Michelson
More information about the asterisk-dev
mailing list