<div dir="ltr">Hello everyone,<div><br></div><div>If I use the below syntax, it works fine. But since I'm using <b>$${<span style="font-size:13px;font-family:'courier new',monospace">variable</span>}</b> (two $-signs) it only works for static values defined at start-up.</div>
<div><div><br></div><div><div style="font-size:13px">
<font face="courier new, monospace"> <fifos><br></font></div><div><font><div style="font-size:13px"><font face="courier new, monospace"> <fifo name="emergency" importance="0"></font></div>
<div style="font-size:13px"><font face="courier new, monospace"> <member timeout="60" simo="1" lag="0">{member_wait=nowait,origination_callee_id_name=<b>$${variable}</b>}loopback/dequeue_emergency/default/XML</member></font></div>
<div style="font-size:13px"><font face="courier new, monospace"> </fifo></font></div><div style="font-size:13px"><font face="courier new, monospace"> </fifos></font></div><div style="font-family:arial,sans-serif;font-size:13px">
<br></div>
<div style="font-family:arial,sans-serif;font-size:13px"><span style="font-family:arial;font-size:small">If I use <b>${</b></span><b style="font-family:'courier new',monospace">variable</b><b style="font-family:arial;font-size:small">}</b><span style="font-family:arial;font-size:small"> (one $-sign) I get the error:</span></div>
<div style="font-family:arial,sans-serif;font-size:13px">
<span style="font-family:arial;font-size:small"><br></span></div><div> <i>Invalid data (${origination_callee_id_name} contains a variable)</i><br></div><div><i><br></i></div><div>Since I couldn't find a way of using a variable from the dialplan, I decided to solve the problem in my application.<br>
</div><div><br></div><div style>Whenever I need to get the list of <i>callers</i> and <i>bridges</i> in the fifo<i>, </i>first I get the list of UUIDs (with <i>fifo list <name></i>) and then I use <i>uuid_getvar <uuid> effective_caller_id_number</i></div>
<div><br></div><div style>I decided to share just in case someone has a similar requirement...</div><div style><br></div><div style>Regards,</div><div style><br></div><div style>Thierry Panthier</div><div style><br></div>
<div style><br></div><div><br></div></font></div></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Jun 12, 2013 at 6:21 PM, Thierry Panthier <span dir="ltr"><<a href="mailto:thierry.devel@gmail.com" target="_blank">thierry.devel@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><font face="arial, helvetica, sans-serif">Hello everyone,</font></div><div><font face="arial, helvetica, sans-serif"><br>
</font></div><div><font face="arial, helvetica, sans-serif">When a call leaves mod_fifo (and it gets bridged) if I do a <i>fifo list <myqueue></i>, I get:</font></div>
<div><font face="courier new, monospace"><br></font></div><div><font face="courier new, monospace"><div><bridges></div><div> <bridge fifo_name="emergency" bridge_start="2013-06-12 07:45:03" bridge_start_epoch="1371023103"></div>
<div> <caller uuid="a16767af-e252-43b5-ad33-cbd38a42bc64" caller_id_name=<b>"Outbound%20Call"</b> caller_id_number=<b>"XML"</b>></caller></div><div> <consumer></div>
<div> <uuid>4b84ab5e-f2a2-4d87-8295-7726663abeed</uuid></div><div> <outgoing_uuid>0b9fa586387efe4014e010bada4da9cc</outgoing_uuid></div><div> </consumer></div><div> </bridge></div>
<div></bridges></div></font></div><div><font face="courier new, monospace"><br></font></div><div><font face="arial, helvetica, sans-serif">However I need to get the <i>caller_id_name</i> and the <i>caller_id_number</i> of the entity that initiated the call and not "<b>Outbound Call</b>" or <b>"XML"</b>.</font></div>
<div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif">I read in a thread that I should set <i>origination_callee_id_name</i> and <i>origination_callee_num</i> but how do I do that?</font></div>
<div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif">I tried to set a variable in my dialplan and use it in <i>fifo.conf.xml </i>but I get the following error:</font></div>
<div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif"><i>[CRIT] switch_channel.c:1364 Invalid data (${origination_callee_id_name} contains a variable)</i><br>
</font></div><div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif"><br></font></div><div><span style="font-family:arial,helvetica,sans-serif">Here's my <u>original</u> </span><span style="font-family:arial,helvetica,sans-serif">fifo.conf.xml:</span><br>
</div><div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif"><div><span style="font-family:'courier new',monospace"><fifos></span><br></div>
</font></div><div><font face="courier new, monospace"><div> <fifo name="emergency" importance="0"></div><div> <member timeout="60" simo="1" lag="0">{member_wait=nowait}loopback/dequeue_emergency/default/XML</member></div>
<div> </fifo></div><div></fifos></div></font></div><div><font face="courier new, monospace"><br></font></div><div><font face="courier new, monospace"><br></font></div><div><span style="font-family:arial,helvetica,sans-serif">Here's part of my <u>original</u> dialplan:</span><font face="courier new, monospace"><br>
</font></div><div><b style="font-family:arial,helvetica,sans-serif"><br></b></div><div><font face="courier new, monospace"><extension name="queue_emergency"></font></div><div><span style="font-family:'courier new',monospace"> <action application="set" data="fifo_music=$${hold_ringing}"/></span><br>
</div><div><font face="courier new, monospace"> <action application="set" data="fifo_orbit_exten=timeout_emergency:$${emergency_queue_timeout}"/></font></div><div><font face="courier new, monospace"> <action application="answer"/></font></div>
<div><font face="courier new, monospace"> <action application="fifo" data="emergency in"/></font></div><div><span style="font-family:'courier new',monospace"></extension></span><br>
</div><div><span style="font-family:'courier new',monospace"><br></span></div><div><br></div><div><br></div><div><span style="font-family:arial,helvetica,sans-serif">Here's my <u>modified</u> </span><span style="font-family:arial,helvetica,sans-serif">fifo.conf.xml:</span><br>
</div><div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif"><span style="font-family:'courier new',monospace"><fifos></span><br></font></div><div><font face="courier new, monospace"><div>
<fifo name="emergency" importance="0"></div><div> <member timeout="60" simo="1" lag="0">{member_wait=nowait,origination_callee_id_name=${some_var_set in_the_dialplan}}loopback/dequeue_emergency/default/XML</member></div>
<div> </fifo></div><div></fifos></div></font></div><div><font face="courier new, monospace"><br></font></div><div><font face="courier new, monospace"><br></font></div><div>If I set to a fixed value instead of a variable, it works fine. But that's useless to me.</div>
<div><br></div><div>Any help would be greatly appreciated.</div><div><br></div><div>Regards,</div><div><br></div><div>Thierry Panthier</div></div>
</blockquote></div><br></div>