Two points, this is where the XML dialplan falls down and you may want to implement the call flow in code such as mod_managed, or whatever language you like. There are ways to do multiple conditions, but remember the actions are all done before execution, so your best bet is using a scripting language.
On 05/14/2014 06:23 PM, Seven Du wrote:
group is implemented as an endpoint so I think it is possible if you find out the right syntax.
That is the problem - the syntax does not seem to lend itself to this.
will send it to the group - but I need to test ${digits} as '30' if true do <action application="att_xfer" data="${group_call(sales@${domain_name})}"/> - else do
<action application="att_xfer" data="${digits} XML default"/>
My understanding is that the dial plan does not execute like code and I can't nest conditions.
I'm already inside one condition in order to get the digits - and when they are available I need to test a second condition.
For reference - the call gets answered in the sales group and - this is what I have right now (no matter which 2 digits - it goes back to the sales group) :
<extension name="att_xfer"> <condition field="destination_number" expression="^att_xfer$"> <action application="set" data="call_timeout=300"/> <action application="set" data="transfer_ringback=$${hold_music}"/> <action application="read" data="2 2 'tone_stream://%(10000,0,350,440)' digits 30000 #"/> <action application="set" data="origination_cancel_key=#"/>
<action application="att_xfer" data="${group_call(sales@${domain_name})}"/> <!-- <action application="att_xfer" data="${digits} XML default"/>-->
</condition> </extension>
-------------------------------------------------------------------------------- Karl Schmidt EMail Karl@xtronics.com Transtronics, Inc. WEB http://secure.transtronics.com 3209 West 9th Street Ph (785) 841-3089 Lawrence, KS 66049 FAX (785) 841-0434
Opportunity is missed by most people because it is dressed in overalls and looks like work. Thomas Alva Edison
--------------------------------------------------------------------------------
_________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org http://www.freeswitchsolutions.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com
Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- Your life is like a penny. You're going to lose it. The question is: How do you spend it? John Covici covici@ccs.covici.com