[Freeswitch-users] Destination number
Miha Zoubek
miha at softnet.si
Wed Mar 7 15:57:56 MSK 2012
On 03/07/2012 01:26 PM, Christian Benke wrote:
> On 7 March 2012 11:48, Miha Zoubek<miha at softnet.si> wrote:
>> I would like that destiantion number is just number so, in this calse
>> 1232456.
>>
>> IS that possible?
> You have several options:
>
> You can always manipulate destination_number to whatever you want it
> to look like and use a different variable in the dialstring, e.g.:
>
> <extension name="Local_Extension">
> <condition>
> <action application="set" data="dialed_extension=$1"/>
> <action application="set"
> data="destination_number=${regex(${dialed_extension}|^([0-9]{3,}).freeswitch.si$|%1)}"/>
> <action application="bridge"
> data="user/${dialed_extension}@${domain_name}"/>
> </condition>
> </extension>
>
>
> You could use accountcode as an indicator:
> http://wiki.freeswitch.org/wiki/Variable_accountcode
>
> Or you can modify the values in the cdrs alltogether in
> conf/autoload_configs/cdr_csv.conf.xml, see
> http://wiki.freeswitch.org/wiki/Mod_cdr_csv
>
> Best regards,
> Christian
>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
>
>
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://wiki.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
Hi @Christian,
I have set in my dialplan <action application="set"
data="accountcode=custom"/>
in my dialplan fs set:
2012-03-07 13:47:11.179122 [NOTICE] switch_core_session.c:2365 Execute
set(accountcode=custom)
EXECUTE
sofia/internal/018108500.fs_kabelvoip1 at fs_kabelvoip1.fs1.softnet.si
set(accountcode=custom)
In my cdr.conf.xml file:
<template
name="custom">"","${caller_id_name}","${caller_id_number}","${destination_prvi}","${context}","${start_stamp}","${answer_stamp}","${end_stamp}","${duration}","${billsec}","${hangup_cause}","${uuid}","${bleg_uuid}","${accountcode}","${read_codec}","${write_codec}"</template>
Must I comment this: <param name="default-template" value="example"/>
Because for default template is stil executed?
Thanks!
Miha
Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users
mailing list