[c5c522c] | 1 | #SYN-3 freepbx dialplan enhancements |
---|
| 2 | |
---|
| 3 | #include extensions_synapse.conf |
---|
| 4 | |
---|
| 5 | #custom destination: go to the voicemail of the person that was called. |
---|
| 6 | (usefull to give users an IVR where they can choose to goto voicemail) |
---|
| 7 | [voicemail-called-person] |
---|
| 8 | exten => s,1,VoiceMail(${EXTTOCALL}) |
---|
| 9 | |
---|
| 10 | |
---|
| 11 | #set callforwarding for specified extension to specified number |
---|
| 12 | #eg: *752000612345678 |
---|
| 13 | #sets callforwarding for 200 to 0622588835 |
---|
| 14 | [from-internal-custom] |
---|
| 15 | exten => _*75.,1,Answer |
---|
| 16 | exten => _*75.,n,Wait(1) |
---|
| 17 | exten => _*75.,n,Macro(user-callerid,) |
---|
| 18 | exten => _*75.,n,Set(fromext=${EXTEN:3:3}) |
---|
| 19 | exten => _*75.,n,Set(toext=${EXTEN:6}) |
---|
| 20 | exten => _*75.,n,Set(DB(CF/${fromext})=${toext}) |
---|
| 21 | exten => _*75.,n,Set(STATE=BUSY) |
---|
| 22 | exten => _*75.,n,Gosub(app-cf-on,sstate,1()) |
---|
| 23 | exten => _*75.,n(hook_2),Playback(call-fwd-unconditional&for&extension) |
---|
| 24 | exten => _*75.,n,SayDigits(${fromext}) |
---|
| 25 | exten => _*75.,n,Playback(is-set-to) |
---|
| 26 | exten => _*75.,n,SayDigits(${toext}) |
---|
| 27 | exten => _*75.,n,Macro(hangupcall,) |
---|
| 28 | |
---|
| 29 | |
---|