Hello Folks,
today i’ve faced an issue and would like to know your oppinion about this.
I’ve created a Timegroup called lunch and entered a single Day, Thursday and entered a Time (13-14 o’clock). Then i created a corresponding Time Condition called lunch break. I’ve configured an inbound route to go directly to the Voicemail of an extension when matched. Everything is working like a charm.
But when i configure a BLF Key on my Yealink T46s the LED did not change to red when the condition was met.
I had a look with the schedtc.php debug command to see what is going on:
[[email protected] ~]# /var/lib/asterisk/bin/schedtc.php --debug
Time Now:13:28|Thu|16|Jan|Europe/Berlin
==Working with TimeCondition:lunch==
INVERTED BLF: true (NOT_INUSE = INUSE & INUSE = NOT_INUSE)
OVERRIDE MODE: not set
=>13:00-14:00|thu|*|*|Europe/Berlin is not now
TIME MATCHED: False (NOT_INUSE)
BLF MODE: False (NOT_INUSE)
Privilege: Command
Changing TC2 to NOT_INUSE
So it claims the condition is not met although the Server timezone is correct:
[[email protected] ~]# date
Thu Jan 16 13:28:56 CET 2020
[[email protected] ~]# ls -l /etc/localtime
lrwxrwxrwx 1 root root 33 Jan 13 09:11 /etc/localtime -> /usr/share/zoneinfo/Europe/Berlin
So i had a look at the Database:
MariaDB [asterisk]> select * from timegroups_details;
40 | 4 | 13:00-14:00|thu||
I’ve changed it to
MariaDB [asterisk]> select * from timegroups_details;
40 | 4 | 13:00-14:00|thu-thu||
Then i checked it again:
[[email protected] ~]# /var/lib/asterisk/bin/schedtc.php --debug
Time Now:13:33|Thu|16|Jan|Europe/Berlin
==Working with TimeCondition:lunch==
INVERTED BLF: true (NOT_INUSE = INUSE & INUSE = NOT_INUSE)
OVERRIDE MODE: not set
=>13:00-14:00|thu|*|*|Europe/Berlin is now
TIME MATCHED: True (INUSE)
BLF MODE: True (INUSE)
Privilege: Command
Changing TC2 to INUSE
After this, the BLF Key switched to Red
So it seems to get inserted the wrong way in the Database or did a made a configuration mistake?
Time Condition Module Version is 15.0.14 with FreePBX Version 15.0.16.38
Thanks for pointing me in the right direction.
Greetings