Some help understanding TimeGroup format

HI All,
I was writing a little Time group manager for adjusting for Holidays and such.

I was going for a simple Start and End date with optional times and have some code generate all the required time elements.

All sorted mostly, but I have a question on how freepbx looks at ODD timegroup_details.
Well not so odd perhaps, depending on your needs,
for Example:
Something normal : 17:00-17:25|*|23|dec
Simple enough…! Yer, we get worked hard.!

Something that looks odd to me, but Freepbx is happy to accept it.

15:00-10:00|thu-mon|14-6|sep-feb

So I wonder, does the time checker do any adjustments’ of logic.?
or would the result of the second example mean this.?

Hours between midnight and 10am AND 3pm thru to midnight, Same DAY ?
on Thursday thru to Monday, << that seems fine.
On dates 1st thru to 6th AND 14th thru to end of Month, Same MONTH ?
On Months Jan thru to feb AND September thru to end of year. Same Year ?

That seems plausible. I’m tempted to think it would be correct.?

OR

As I type the following it does not make sense.

Hours between 3pm thru to 10am next day, ?
on Thursday thru to Monday, << that seems fine.
On dates 14th thru to 6th of following month,?
On Months from September thru to February. ?

That does not seem right at all.! but then who knows such things.?

But perhaps it thinks the user is mad and corrects it to be like,
Hours between 10am thru to 3pm,
on Thursday thru to Monday,
On dates 6th thru to 14th,?
On Months from February thru to September. ?

Either result is messing with my mind.
I would assume it takes it as entered but then how does it resolve the example.?

15:00-10:00|*|14-6|sep-feb

Sorry, I realise that it will look for the match of the Date and Day.
Well I assume it would. ie only times where the days fall on the mentioned dates.
So I change that to * in the above example to avoid such confusion.
Or have I misunderstood that too.!

But it was more the reversed bit that puzzles.

For my own needs I don’t need to deal with such complications
but thought I should make it “to spec” as possible.
thus a need for some sort of understanding, I have not needed to so far. !

Any bright sparks gota moment to shed some light.?

just as a foot note:
the tool was part of a page developed to make it easy to select and shift a voicemail recording into the system recordings folder for use with a Holiday IVR or other such things.

With the “holiday” IVR pointing to a single file,
the user can change their recording without
the need to interact directly with the PBX interface.

The additional “setting of the time groups”
is only a once a year event but thought it would be nice to drop it in.

Hv.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.