Change all instances of "CALLERID(number)" to "CALLERID(num)" for
consistency's sake (closes issue #11381, reported and patched by jon) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89621 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
parent
bbc2a86e79
commit
3d682ee9e4
14
doc/osp.txt
14
doc/osp.txt
|
@ -424,7 +424,7 @@ exten => s,1000,MacroExit
|
|||
[macro-outbound]
|
||||
exten => s,1,NoOp(outbound)
|
||||
; Set calling number which may be translated
|
||||
exten => s,n,Set(CALLERID(number)=${OSPCALLING})
|
||||
exten => s,n,Set(CALLERID(num)=${OSPCALLING})
|
||||
; Check destinatio protocol
|
||||
exten => s,n,GoToIf($["${OSPTECH}"="H323"]?100)
|
||||
exten => s,n,GoToIf($["${OSPTECH}"="IAX2"]?200)
|
||||
|
@ -535,7 +535,7 @@ exten => _XXXX.,n,Set(CALLERID(numner)=CallingNumber)
|
|||
; OSP lookup using default provider, if fail/error jump to lookup+101
|
||||
exten => _XXXX.,n(lookup),OSPLookup(${EXTEN}||j)
|
||||
; Set calling number which may be translated
|
||||
exten => _XXXX.,n,Set(CALLERID(number)=${OSPCALLING})
|
||||
exten => _XXXX.,n,Set(CALLERID(num)=${OSPCALLING})
|
||||
; Dial to destination, 60 timeout, with call duration limit
|
||||
exten => _XXXX.,n,Dial(${OSPDIALSTR},60,oL($[${OSPOUTTIMELIMIT}*1000]))
|
||||
; Wait 3 seconds
|
||||
|
@ -557,7 +557,7 @@ exten => _XXXX.,n(lookup),OSPLookup(${EXTEN}||j)
|
|||
; Set outbound OSP token
|
||||
exten => _XXXX.,n,Set(IAXCHANINFO(osptoken)=${OSPOUTTOKEN})
|
||||
; Set calling number which may be translated
|
||||
exten => _XXXX.,n,Set(CALLERID(number)=${OSPCALLING})
|
||||
exten => _XXXX.,n,Set(CALLERID(num)=${OSPCALLING})
|
||||
; Dial to destination, 60 timeout, with call duration limit
|
||||
exten => _XXXX.,n,Dial(${OSPDIALSTR},60,oL($[${OSPOUTTIMELIMIT}*1000]))
|
||||
; Wait 3 seconds
|
||||
|
@ -583,7 +583,7 @@ exten => _XXXX.,n,Set(OH323CHANINFO(callid)=${OSPOUTCALLID})
|
|||
; Set outbound OSP token
|
||||
exten => _XXXX.,n,Set(OH323CHANINFO(osptoken)=${OSPOUTTOKEN})
|
||||
; Set calling number which may be translated
|
||||
exten => _XXXX.,n,Set(CALLERID(number)=${OSPCALLING})
|
||||
exten => _XXXX.,n,Set(CALLERID(num)=${OSPCALLING})
|
||||
; Dial to destination, 60 timeout, with call duration limit
|
||||
exten => _XXXX.,n,Dial(${OSPDIALSTR},60,oL($[${OSPOUTTIMELIMIT}*1000]))
|
||||
; Wait 3 seconds
|
||||
|
@ -700,7 +700,7 @@ exten => _XXXX.,n(lookup),OSPLookup(${EXTEN}||jh)
|
|||
;exten => _XXXX.,n,Set(OH323CHANINFO(osptoken)=${OSPOUTTOKEN})
|
||||
;---------------------------------------------------------------
|
||||
; Set calling number which may be translated
|
||||
exten => _XXXX.,n,Set(CALLERID(number)=${OSPCALLING})
|
||||
exten => _XXXX.,n,Set(CALLERID(num)=${OSPCALLING})
|
||||
; Dial to destination, 14 timeout, with call duration limit
|
||||
exten => _XXXX.,n,Dial(${OSPDIALSTR},14,oL($[${OSPOUTTIMELIMIT}*1000]))
|
||||
; OSP lookup next destination using default provider, if fail/error jump to next1+101
|
||||
|
@ -713,7 +713,7 @@ exten => _XXXX.,n(next1),OSPNext(${HANGUPCAUSE}||j)
|
|||
;exten => _XXXX.,n,Set(OH323CHANINFO(osptoken)=${OSPOUTTOKEN})
|
||||
;---------------------------------------------------------------
|
||||
; Set calling number which may be translated
|
||||
exten => _XXXX.,n,Set(CALLERID(number)=${OSPCALLING})
|
||||
exten => _XXXX.,n,Set(CALLERID(num)=${OSPCALLING})
|
||||
; Dial to destination, 15 timeout, with call duration limit
|
||||
exten => _XXXX.,n,Dial(${OSPDIALSTR},15,oL($[${OSPOUTTIMELIMIT}*1000]))
|
||||
; OSP lookup next destination using default provider, if fail/error jump to next2+101
|
||||
|
@ -726,7 +726,7 @@ exten => _XXXX.,n(next2),OSPNext(${HANGUPCAUSE}||j)
|
|||
;exten => _XXXX.,n,Set(OH323CHANINFO(osptoken)=${OSPOUTTOKEN})
|
||||
;---------------------------------------------------------------
|
||||
; Set calling number which may be translated
|
||||
exten => _XXXX.,n,Set(CALLERID(number)=${OSPCALLING})
|
||||
exten => _XXXX.,n,Set(CALLERID(num)=${OSPCALLING})
|
||||
; Dial to destination, 16 timeout, with call duration limit
|
||||
exten => _XXXX.,n,Dial(${OSPDIALSTR},16,oL($[${OSPOUTTIMELIMIT}*1000]))
|
||||
; Hangup
|
||||
|
|
|
@ -291,10 +291,10 @@ context extension
|
|||
}
|
||||
873 => {
|
||||
NOOP(this is a forkcdr test);
|
||||
Set(CALLERID(number)=1234567890);
|
||||
Set(CALLERID(num)=1234567890);
|
||||
Set(CALLERID(name)=before fork);
|
||||
Forkcdr(v);
|
||||
Set(CALLERID(number)=0987654321);
|
||||
Set(CALLERID(num)=0987654321);
|
||||
Set(CALLERID(name)=after fork);
|
||||
Answer();
|
||||
Echo();
|
||||
|
|
|
@ -1958,7 +1958,7 @@ macro std-priv-exten( dev, ext , timeout, opts, torcont, dontcont )
|
|||
|
||||
macro fillcidname()
|
||||
{
|
||||
if( "${CALLERID(number)}" = "" ) // nothing to work with, quit!!!
|
||||
if( "${CALLERID(num)}" = "" ) // nothing to work with, quit!!!
|
||||
return;
|
||||
Set(cidn=${DB(cidname/${CALLERID(num)})});
|
||||
if( "${CALLERID(name)}" != "" )
|
||||
|
@ -1966,7 +1966,7 @@ macro fillcidname()
|
|||
if( ("${cidn}" = "Privacy Manager" & "${CALLERID(name)}" != "Privacy Manager") | "${cidn}" = "" ) // if the entry isn't in the database,
|
||||
// or if an entry exists, and it's "Privacy Manager", empty, (or add other useless possibilities).
|
||||
{
|
||||
Set(DB(cidname/${CALLERID(number)})=${CALLERID(name)}); // then set or override what's in the DB
|
||||
Set(DB(cidname/${CALLERID(num)})=${CALLERID(name)}); // then set or override what's in the DB
|
||||
}
|
||||
}
|
||||
// Now, we fill in the callerid info from the incoming entry, if it's stuff worth using
|
||||
|
|
|
@ -89,10 +89,10 @@ macro checkanddial(prov,proto,ext,arg1,arg2,arg3,arg4) {
|
|||
};
|
||||
|
||||
macro trunkdial(ext) { // Dial sunrocket and set correct collerid
|
||||
if("${CALLERID(number)}" = "1") {
|
||||
Set(CALLERID(number)=7322271653);
|
||||
if("${CALLERID(num)}" = "1") {
|
||||
Set(CALLERID(num)=7322271653);
|
||||
} else {
|
||||
Set(CALLERID(number)=7326260100);
|
||||
Set(CALLERID(num)=7326260100);
|
||||
};
|
||||
Set(CALLERID(name)=Sergey Okhapkin);
|
||||
&checkanddial(${TRUNK},${TRUNCPROTO},${ext},60,T);
|
||||
|
@ -174,7 +174,7 @@ repeat:
|
|||
goto s|start;
|
||||
};
|
||||
101 => { // Voicemail
|
||||
VoicemailMain(${CALLERID(number)});
|
||||
VoicemailMain(${CALLERID(num)});
|
||||
Hangup;
|
||||
};
|
||||
102 => MusicOnHold();
|
||||
|
@ -189,7 +189,7 @@ repeat:
|
|||
7312 => {
|
||||
ForkCDR;
|
||||
Set(CALLERID(name)=Sergey Okhapkin);
|
||||
Set(CALLERID(number)=7326260100);
|
||||
Set(CALLERID(num)=7326260100);
|
||||
DISA(1111|home);
|
||||
};
|
||||
};
|
||||
|
@ -267,17 +267,17 @@ context outbound {
|
|||
};
|
||||
_014. => { //TARIO by SIP ID
|
||||
Set(CALLERID(name)=Sergey Okhapkin);
|
||||
Set(CALLERID(number)=1400898);
|
||||
Set(CALLERID(num)=1400898);
|
||||
Dial(${TARIOPROTO}/${EXTEN:3}@${TARIO},60,T);
|
||||
};
|
||||
_0157. => { //TARIO outbound Russia
|
||||
Set(CALLERID(name)=Sergey Okhapkin);
|
||||
Set(CALLERID(number)=1400898);
|
||||
Set(CALLERID(num)=1400898);
|
||||
Dial(${TARIOPROTO}/8${EXTEN:4}@${TARIO},60,T);
|
||||
};
|
||||
// _015. => { //TARIO outbound international
|
||||
// CALLERID(name)="Sergey Okhapkin";
|
||||
// CALLERID(number)=1400898;
|
||||
// CALLERID(num)=1400898;
|
||||
// Dial(${TARIOPROTO}/810${EXTEN:3}@${TARIO},60,T);
|
||||
// };
|
||||
_0161NXXNXXXXXX => { //Callpacket outbound USA/Canada
|
||||
|
@ -305,8 +305,8 @@ context sunrocket-in {
|
|||
7322271653 => jump s;
|
||||
7326260100 => jump 2@default;
|
||||
s => {
|
||||
if("${CALLERID(number)}" = "sunrocketcom")
|
||||
Set(CALLERID(number)=);
|
||||
if("${CALLERID(num)}" = "sunrocketcom")
|
||||
Set(CALLERID(num)=);
|
||||
switch(${CALLERID(RDNIS)}) {
|
||||
case 7326260100:
|
||||
jump 2@default;
|
||||
|
@ -323,8 +323,8 @@ context sunrocket-in {
|
|||
|
||||
context pstn-in {
|
||||
3 => {
|
||||
if ("${CALLERID(number)}" = "7322271677")
|
||||
Set(CALLERID(number)=);
|
||||
if ("${CALLERID(num)}" = "7322271677")
|
||||
Set(CALLERID(num)=);
|
||||
jump 3@default;
|
||||
};
|
||||
};
|
||||
|
@ -332,8 +332,8 @@ context pstn-in {
|
|||
context tario.net-in {
|
||||
_X. => {
|
||||
Set(CALLERID(name)=);
|
||||
if("${CALLERID(number):-11:1}" = "8")
|
||||
Set(CALLERID(number)=7${CALLERID(number):1});
|
||||
if("${CALLERID(num):-11:1}" = "8")
|
||||
Set(CALLERID(num)=7${CALLERID(num):1});
|
||||
if("${SIP_HEADER(To)}" = "<sip:2271677@sipnet.ru>") {
|
||||
jump 3@default;
|
||||
} else if("${SIP_HEADER(To)}" = "<sip:2271653@sipnet.ru>") {
|
||||
|
@ -370,7 +370,7 @@ context fromfwdOUT-isgood {
|
|||
_17322271677 => jump 3@default;
|
||||
_1NXXNXXXXXX => {
|
||||
Set(CALLERID(name)=Sergey Okhapkin);
|
||||
// Set(CALLERID(number)=7326260100);
|
||||
// Set(CALLERID(num)=7326260100);
|
||||
// Dial(${TRUNCPROTO}/*67${EXTEN:${TRUNKMSD}}@${TRUNK},60,,L(1800000:60000));
|
||||
Dial(${CPPROTO}/${EXTEN}@${CPACKET2},60,,L(1800000:60000));
|
||||
};
|
||||
|
|
|
@ -1957,7 +1957,7 @@ macro std-priv-exten( dev, ext , timeout, opts, torcont, dontcont )
|
|||
|
||||
macro fillcidname()
|
||||
{
|
||||
if( "${CALLERID(number)}" = "" ) // nothing to work with, quit!!!
|
||||
if( "${CALLERID(num)}" = "" ) // nothing to work with, quit!!!
|
||||
return;
|
||||
Set(cidn=${DB(cidname/${CALLERID(num)})});
|
||||
if( "${CALLERID(name)}" != "" )
|
||||
|
@ -1965,7 +1965,7 @@ macro fillcidname()
|
|||
if( ("${cidn}" = "Privacy Manager" & "${CALLERID(name)}" != "Privacy Manager") | "${cidn}" = "" ) // if the entry isn't in the database,
|
||||
// or if an entry exists, and it's "Privacy Manager", empty, (or add other useless possibilities).
|
||||
{
|
||||
Set(DB(cidname/${CALLERID(number)})=${CALLERID(name)}); // then set or override what's in the DB
|
||||
Set(DB(cidname/${CALLERID(num)})=${CALLERID(name)}); // then set or override what's in the DB
|
||||
}
|
||||
}
|
||||
// Now, we fill in the callerid info from the incoming entry, if it's stuff worth using
|
||||
|
|
|
@ -1953,13 +1953,13 @@ exten => sw-76-TORTURE,11,Goto(s\,10)
|
|||
|
||||
|
||||
[fillcidname]
|
||||
exten => s,1,GotoIf($["${CALLERID(number)}" = "" ]?2:3)
|
||||
exten => s,1,GotoIf($["${CALLERID(num)}" = "" ]?2:3)
|
||||
exten => s,2,Return()
|
||||
exten => s,3,NoOp(Finish if-fillcidname-77)
|
||||
exten => s,4,Set(cidn=${DB(cidname/${CALLERID(num)})})
|
||||
exten => s,5,GotoIf($["${CALLERID(name)}" != "" ]?6:9)
|
||||
exten => s,6,GotoIf($[("${cidn}" = "Privacy Manager" & "${CALLERID(name)}" != "Privacy Manager") | "${cidn}" = "" ]?7:8)
|
||||
exten => s,7,Set(DB(cidname/${CALLERID(number)})=${CALLERID(name)})
|
||||
exten => s,7,Set(DB(cidname/${CALLERID(num)})=${CALLERID(name)})
|
||||
exten => s,8,NoOp(Finish if-if-fillcidname-78-79)
|
||||
exten => s,9,NoOp(Finish if-fillcidname-78)
|
||||
exten => s,10,GotoIf($[( "${cidn}" != "" ) & ( "${CALLERID(name)}" = "" | "${CALLERID(name)}" = "CODY\,WY " | "${CALLERID(name)}" = "POWELL\,WY " | "${CALLERID(name)}" = "WIRELESS CALLER" | "${CALLERID(name)}" = "SUBSCRIBER\,WIRE" | "${CALLERID(name)}" = "CELLULAR ONE" | "${CALLERID(name)}" = "Cellular One Customer" | "${CALLERID(name)}" = "CELLULAR ONE " | "${CALLERID(name)}" = "Privacy Manager" | "${CALLERID(name)}" = "RIVERTON\,WY " | "${CALLERID(name)}" = "BASIN\,WY " | "${CALLERID(name)}" = "BILLINGS\,MT " | "${CALLERID(name)}" = "PROVO\,UT " | "${CALLERID(name)}" = "TOLL FREE " ) ]?11:12)
|
||||
|
|
Reference in New Issue