Outgoing calls route Time and day

Status
Not open for further replies.

mevans1974

New Member
Jan 23, 2022
22
0
1
49
Hi All,
I am implementing fusion PBX we have a lot of mobile users with soft-phones but we only want them to be able to make calls during working hours.
is it possible to use something like time and day routing for outgoing calls?


Any help would be greatly appreciated
 

rabbidiesel

Member
Aug 28, 2020
32
5
8
9x9tech.com
Hi,

I have actually just set up something like this for a school where they want the boys to only make calls at specific time.

You will have to make a separate outbound route for each time.

First you will need toll_allow.
As you can see from the pictures I attached , you can put whatever you want here.

Then you will need to calculate the Time of Day. The way I found to do this is take 60 (minutes) and times it by the 24 hour time. So for instance, if you want the phones blocked from 3-4pm, you would do 15x60=900 and then for 4 pm you do 16x60=960. So for you minute-of-day you would put 900-960.

In may case I upload a recording that will play during these times, and then the call will hang up.

After making all these outbound routes, you will need to put toll_allow on the extensions that you want to run on this schedule.

Make sure that your outbound routes have a lower number than your regular catch all routes, otherwise this won’t work.

Good Luck
 

Attachments

  • IMG_9259.jpeg
    IMG_9259.jpeg
    228.6 KB · Views: 27
  • IMG_9258.jpeg
    IMG_9258.jpeg
    484.4 KB · Views: 27
  • Like
Reactions: mevans1974

rabbidiesel

Member
Aug 28, 2020
32
5
8
9x9tech.com
@mevans1974 I am guessing that you are asking were the minute-of-day is in the dropdown, or how I was able to get it in there.
I typed it in manually. First select anything from the "Type" dropdown and then you will be able to type it in manually.
Then I made a copy of my original limiting outbound route, and just changed the minute of day and the name for each one.

Hope this clarifies what you are asking for.
 
  • Like
Reactions: mevans1974

mevans1974

New Member
Jan 23, 2022
22
0
1
49
@rabbidiesel I was able to get it to work however, there is a issue. All extension seems to be using this route whether or not I put the toll_allow on the extension. SBC_01 is the route all other extension should be using
Can you look at the photo and see if i'm doing anything wrong

Thanks in advance.
 

Attachments

  • Untitled 3.png
    Untitled 3.png
    48.7 KB · Views: 14
  • Untitled 2.png
    Untitled 2.png
    78.7 KB · Views: 14

rabbidiesel

Member
Aug 28, 2020
32
5
8
9x9tech.com
Hi,

@mevans1974, you don’t seem to have a toll_allow on the outbound route.
If you look under the pictures I originally sent, you will see that the second item on the outbound route is a condition with a type of toll_allow.
Please try adding that and let me know.
Best Reguards,
 
  • Like
Reactions: mevans1974

mevans1974

New Member
Jan 23, 2022
22
0
1
49
@rabbidiesel _ Thank you very much, that worked like a charm.

I have one question I need the user blocked from 12am - 6:30 and 10:30pm - 11:29 PM. Can I add both times in the route or I have to create a route for each time?
 

mevans1974

New Member
Jan 23, 2022
22
0
1
49
@rabbidiesel Hi I though I had this thing working until I went to implement it and I can't dial out. I get a busy when dialing out

Can you please look at this and let me know if you see anything wrong.
 

Attachments

  • Untitled 2.png
    Untitled 2.png
    75 KB · Views: 8

DigitalDaz

Administrator
Staff member
Sep 29, 2016
3,044
565
113
I have only had a quick look but about halfway down that dialplan I see an Action Hangup, is that not going to hangup the call?
 
  • Like
Reactions: mevans1974

mevans1974

New Member
Jan 23, 2022
22
0
1
49
I have only had a quick look but about halfway down that dial plan I see an Action Hangup, is that not going to hangup the call?
The hang up is there for when the announcement play tell the users" you can't make calls during off hours. If the hangup was not there the announcement would have played and if you waited on the call for a few more seconds the call would have proceed. The hang only come in to play when the announcement played. Like I said it was working until I try to implement it.
 

Architect

New Member
Jun 1, 2021
26
4
3
52
We've added a Time Zone table based on Area Code to our instance which covers Canada and the US. We call al lua script (timezone.lua) when the toll_allow "timezone" is present on the user's extension. We did this because we wanted to be able to control by Area Code within each Time Zone. If the Area Code of the phone number being dialed matches an entry in the table, and the caller has "timezone" under their extension "Toll Allow", then the person calling out will hear the messages "You are attempting to dial a phone number in a time zone which is presently closed. Hang up and try your call when the time zone is open." and then the call is terminated.

We are now implementing a Statutory Holiday table which will also be based on Area Code within each Province (for Canada) and state (US). If the current date matches a date in the table, and the Area Code matches, and the caller has "stat_holiday" under their extension "Toll Allow", then the person calling out will hear the messages "You are attempting to dial a phone number in a location presently observing a holiday. Due to compliance rules, this is not permitted." and then the call is terminated.

In both instances we have a screen that permitted users can access to add / modify / delete entries as required.
This method works extremely well for us.

Screen Shot 2024-03-19 at 9.13.16 AM.png
 
  • Like
Reactions: mevans1974
Status
Not open for further replies.