Priority Calling: DND Override

rossiv

Guru
Joined
Oct 26, 2008
Messages
2,624
Reaction score
139
Is there a way to override DND ? Example:phone in room A is on DND because of a meeting. Receptionist has urgent message for attendee, needs to call. Could there be a way for "receptionist" to override the DND. I know it may not be possible on a softphone, but for asterisk it should be able to be done.
 

rossiv

Guru
Joined
Oct 26, 2008
Messages
2,624
Reaction score
139
I do not need a phone-only solution. I want to know of there is a feature in Asterisk for "VIP/Priority Calling". If not, I want to know if it could be created.
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
do_not_disturb.conf

Here's the code... just so we'll have it down the road:

HTML:
; do_not_disturb.conf:
; Handle the "do not disturb" feature

; If DND is on, the stdextension macro plays a recording like:
; "I am busy, but press # if this is an emergency"
; (assuming DND_OVERRIDE_EXTENSION is set to # in extensions.conf)
; Because of the way this works, the dnd-override context must be
; included in the context where the stdextension macro is called.

;[globals]
;DND_OVERRIDE_EXTENSION=

[macro-dnd-on]
exten = s,1,DBput(DND/${ARG1}=YES)
exten = s,2,Playback(beep)
exten = s,3,Macro(return_to_top)

[macro-dnd-off]
exten = s,1,DBdel(DND/${ARG1})
exten = s,2,Playback(beep)
exten = s,3,Macro(return_to_top)

[dnd-override]
; ----- Do Not Disturb Override ------
; Make all forwards non-immediate when overriding DND.
exten = ${DND_OVERRIDE_EXTENSION},1,GotoIf($["${dnd_exten}foo" = "foo"]?2:3)
exten = ${DND_OVERRIDE_EXTENSION},2,Macro(return_to_top)
exten = ${DND_OVERRIDE_EXTENSION},3,Goto(dnd-override-bans,1)

; Ban hypothetical abusers from DND system
exten = dnd-override-bans,1,GotoIf($["${CALLERIDNUM}" = "12223334444"]?20:2)
exten = dnd-override-bans,2,Goto(dnd-override-main,1)
; Dump straight to voicemail
exten = dnd-override-bans,20,Voicemail(${dnd_exten})

; Now re-run the original extension context, but this time
; dnd_override is set to YES, which will bypass the dnd
; prompt in stdextension macro and go straight through.
exten = dnd-override-main,1,SetVar(dnd_override=YES)
exten = dnd-override-main,2,Goto(${dnd_context},${dnd_exten},1)
 

MGD4me

Guru
Joined
Feb 3, 2009
Messages
505
Reaction score
109
Ok, but what can we do with it?

I guess you missed the part above where it says:

If DND is on, the stdextension macro plays a recording like:
"I am busy, but press # if this is an emergency"

This should pretty much do what you asked, no?
 

rossiv

Guru
Joined
Oct 26, 2008
Messages
2,624
Reaction score
139
Right, I saw that. How do we get it working?
 

tshif

Guru
Joined
Jan 3, 2008
Messages
1,240
Reaction score
4
Right, I saw that. How do we get it working?

How would it be put into action?

Ross -
It looks like the example is taken from a non FreePBX system. That means some assumptions are made in the code that can't necessarily be stuffed into one of our system as-is and be expected to work.

So - what does that mean to your questions?

Well - it suggests to me that it might be done by someone with a good knowledge of the internal workings of FreePBX, and a bit of time.

So - are you ready to dig in and contribute the code to do it? No?

Another option is to hire someone to create a way for you to accomplish this. Or, find a nice way of convincing someone with the skills to do it.

So -

How would it be put into action?

1. Roll up your sleeves and get started. We will all cheer you on! (Have you ever seen Ward or Joe or Me in a cheerleader outfit? Its really cool.)
cheer.jpg


2. Start waving around fist fulls of cash here in the forums. There's LOTS of talented people here, and every one of them likes to eat and live indoors. Nothing attracts talent like reward.

3. Wait for someone else to create it or sponsor it. Quietly. Encourage someone to take up the project - nicely, politely. Remember - your asking someone to do you a favor.

Good luck! Sounds like an interesting project. I almost wish I knew enough to make it happen.
 

wolfeman

New Member
Joined
Jan 16, 2008
Messages
25
Reaction score
0
Remote DND on/off

You could use ASTassistant to turn off the DND then when done turn the DND back on.

ASTassistant is freeware and can be found at:
www.astassistant.com

-Scott
 

mathewss

Guru
Joined
Sep 21, 2011
Messages
8
Reaction score
2
Is this still relevant for PIAF green?

I already have DND-ON contexts setup where the BLF button sends a *78 or *78 so the phone itself is not in DND mode.
Now I want to allow some way to enter a code while in VMX preferably. It seems odd I can not find where to make some changes to the VMX or somehow modify it. Otherwise would I have to "emulate" the VMX and handle did BUSY vs AWAY and play different messages myself to interact with the user and ask for a code to bypass DND?

Any help apprecaited just seems like I am missing some easy way to add this feature.


do_not_disturb.conf

Here's the code... just so we'll have it down the road:

HTML:
; do_not_disturb.conf:
; Handle the "do not disturb" feature

; If DND is on, the stdextension macro plays a recording like:
; "I am busy, but press # if this is an emergency"
; (assuming DND_OVERRIDE_EXTENSION is set to # in extensions.conf)
; Because of the way this works, the dnd-override context must be
; included in the context where the stdextension macro is called.

;[globals]
;DND_OVERRIDE_EXTENSION=

[macro-dnd-on]
exten = s,1,DBput(DND/${ARG1}=YES)
exten = s,2,Playback(beep)
exten = s,3,Macro(return_to_top)

[macro-dnd-off]
exten = s,1,DBdel(DND/${ARG1})
exten = s,2,Playback(beep)
exten = s,3,Macro(return_to_top)

[dnd-override]
; ----- Do Not Disturb Override ------
; Make all forwards non-immediate when overriding DND.
exten = ${DND_OVERRIDE_EXTENSION},1,GotoIf($["${dnd_exten}foo" = "foo"]?2:3)
exten = ${DND_OVERRIDE_EXTENSION},2,Macro(return_to_top)
exten = ${DND_OVERRIDE_EXTENSION},3,Goto(dnd-override-bans,1)

; Ban hypothetical abusers from DND system
exten = dnd-override-bans,1,GotoIf($["${CALLERIDNUM}" = "12223334444"]?20:2)
exten = dnd-override-bans,2,Goto(dnd-override-main,1)
; Dump straight to voicemail
exten = dnd-override-bans,20,Voicemail(${dnd_exten})

; Now re-run the original extension context, but this time
; dnd_override is set to YES, which will bypass the dnd
; prompt in stdextension macro and go straight through.
exten = dnd-override-main,1,SetVar(dnd_override=YES)
exten = dnd-override-main,2,Goto(${dnd_context},${dnd_exten},1)
 

Members online

Forum statistics

Threads
25,779
Messages
167,505
Members
19,199
Latest member
leocipriano
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top