[Asterisk-Dev] AgentCallBackLogin passthru.
Russell Bryant
russell at digium.com
Tue Oct 25 14:07:11 MST 2005
On Oct 25, 2005, at 3:47 PM, José Pablo Ezequiel Fernández wrote:
> [outgoing]
> exten => _.,1,AgentCallbackLogin(|${CALLERIDNUM}@sip|p)
> exten => _.,2,Dial(Zap/1,${EXTEN})
> exten => _.,102,hangup
>
> When you are logged in, it will jump to the Dial, if not it'll ask
> you to log
> in. If you log in successfully it'll go to the Dial, if not, to the
> hangup.
>
> I believe this won't need a lot of changes to the source code, but
> please,
> send me any feedback or comments regarding this.
> Thanks.
We are deprecating the use of priority jumping in applications, but
there are still ways that we could do this. What we probably need is
an AGENT dialplan function, similar to the SIPPEER or IAXPEER
dialplan functions. With this function, you could check the state of
the agent, as well as whatever other information we wanted to
expose. Then, you could have the functionality you want in the
following line:
exten => whatever,1,GotoIf($[${AGENT(1234|state)} = loggedin]?103:3)
--
Russell Bryant
More information about the asterisk-dev
mailing list