Time Conditions

Have never found a good answer to this so I thought I would ask again.
How do the time groups/conditions actually work?
I am setup with normal mon-fri 8-5 and all else is after hours.
I get this no problem.
What I would like to do is kind of preconfigure my public holidays and have the system automatically do the switching for me.

For example:
Over the change of the month I want to have a week away.
My “break” will start on Friday the 29th March at 5pm and I will come back to work on Monday 8th April at 8am.
What would be the right thing to fill out in the time groups/conditions?

The reason I ask is that when I have done this in the past, I have had some really strange outcomes.

Logically I would fill out time groups with:
Time Group : MarchLeave
Time to start: :17:00
Time to finish: :08:00
Week Day start: : Friday
Week Day finish: Monday
Month Day start: 29
Month Day finish: 8
Month start: March
Month finish: April

Next I would set a time condition to use this called “March_Leave” with time if destination matches to “Announcements” - “awayonleavemessage” which would then send caller to voicemail.
Time if destination doesn’t match would go to Time conditions “Normal Hours”

Does this seem right?
I have had it in the past where it looks at part of the group but not the whole group and routes the call based on this part information.
For example in the above if a call came in at 10am then the system would see it as out of the time range regardless of the dates and send it to the “Normal Hours” time condition.

Admittedly I have not used this feature in the last couple of months but have not seen any module updates to do with time so not sure if this is still a problem.

I am using FreePBX Distro 1.815.210.58-1.

Thanks in advance.

It would seem your times defined in the “Normal Hours” would address this.

You are changing the destination of the inbound route (for the extension) to Time Condition - MarchLeave?

Yes inbound route goes to MarchLeave.
I have in the past left the time slots empty and that seems to help but in the example above I have had it where it looks at the Days next and the following Tuesday goes “Today is Tuesday” (ignoring 2nd April - which is inside Leave time) and therefore sends call to "NormalHours"
The only time I got this to work was to just use Month Day Start and Month Day Finish, Month Start and Month Finish values only. The next month it auto switched over again ignoring the Month Start and Month Finish part of the argument.

For now I use a button to Call Flow Control and do it manually but would be nice to automate.

I used an appliance PBX the other day that runs on Asterisk that actually had a module for Holidays. In there you can add start Date and Time and finish Date and Time and it auto switches to after hours on those times. (you then use something on the inbound route to direct where it goes if it is in the holiday time).

Maybe a feature request???

When you consider there are really only 2 that are common to international industries (New Years and Christmas…Easter doesn’t really impact “business hours”). Then, in the US you have holidays “observed” (versus actual dates of holidays) at different levels (Federal, State, local, private). There would always be someone complaining about having to tweak things for their own needs anyway. So, it is probably best just to do it ourselves. ;]

Unless you take the “MarchLeave” every year(?), you will have to modify the inbound route every time you leave. In which case, why wouldn’t you just call it “OutofOffice” (or whatever) and just adjust the time group?

(BTW-Just to clarify, you are saying that for instance on April 30th, the “MarchLeave” was still forwarding to your out of office announcement?)

I have a similar scenario wherein the inbound route points to the first time condition (TC) which checks the first holiday time group (TG), which is defined with month and dates only (no weekdates or times). If it matches, it plays the closed announcement. If it does not, it goes to the next TC pointing to the next holiday TG and so on, with the last holiday TC directing to the business hours TC. If it matches, it forwards to the IVR, if not forwards to the closed announcement. It has been working great!

Since your “normal hours” are going to address after 5pm on Friday and through the weekend, your time group really only needs to be April 1 to April 5. (?) So, day start 1, day finish 5, month start April, month finish April.

It all gets too confusing. This is why i only revisit it every 6 or 12 months…
would be nice to have some kind of application like when you set your out of office replies on MS Outlook (Start Time / Date - Finish Time / Date) then no one needs to remember to dial *280.
In the mean time, this works so will just keep going with that.
Thanks TreadingWater.

The time conditions module does this for you. Take a look.

As I said at the beginning of the post I had not tried this for a while and was pointing out the problems I had last time.
Over the weekend I will do some more testing but had issues when criteria A would be met but not criteria B I would still get the outcome as if both had been met.
For example 29th March to 8th April go to MarchLeave… on 30th March at 0:00 it would go to a message saying away on leave, leave a message". On 8th April at 0:00 it would go back to normal “After hours” time condition and then at 09:00 it would got back to "Normal Hours"
Problem is at 0:00 on 30th April it would flick back to MarchLeave until 8th May as it has seen Criteria A to be 30th and ignored Criteria B of March.
Am I clear in this?
I have been trying to make this work properly since Trixbox days but never had a full system where at begining of year I could sit down, work out holidays, make recordings and create the time condidtions.

This could very easily be a lack of undesrtanding something here but so far I have not found anything really explaining how Time conditions work and how they can be used effectively.
Thanks.

I think what you are missing is you have to nest the time conditions, if one doesn’t match go on to the next. Always start with the most generic to least generic, like an access list.

Maybe that is where I went wrong, I have always gone from least generic to most generic.
Will give it a try.
Thanks

No I typed that wrong, surprised nobody yelled at me.

If you start with the most generic it will catch it and never go any further.

So if you have single day events they go before a weekly event, etc.