Programación de horarios
This commit is contained in:
parent
8a85fef499
commit
7456bda3ff
|
@ -1,4 +1,4 @@
|
|||
vn-asterisk (1.008-deb7) stable; urgency=low
|
||||
vn-asterisk (1.009-deb7) stable; urgency=low
|
||||
|
||||
* Initial Release.
|
||||
|
||||
|
|
15
incoming.php
15
incoming.php
|
@ -40,6 +40,21 @@ if (date ('N') == 7 && $sundayFestive)
|
|||
exit ();
|
||||
}
|
||||
|
||||
// Checks schedules
|
||||
|
||||
$hasSchedule = $db->getValue (
|
||||
'SELECT COUNT(*) > 0 FROM pbx.schedule
|
||||
WHERE weekDay = WEEKDAY(CURDATE())
|
||||
AND CURTIME() BETWEEN timeStart AND timeEnd'
|
||||
);
|
||||
|
||||
if ($hasSchedule)
|
||||
{
|
||||
Agi::exec ('SET VARIABLE MACRO queue');
|
||||
Agi::exec ('SET VARIABLE ARG1 1200');
|
||||
exit ();
|
||||
}
|
||||
|
||||
// Gets the customer from the phone number
|
||||
|
||||
$customer = $db->getValue ('SELECT clientFromPhone(#)', [$callerId]);
|
||||
|
|
Loading…
Reference in New Issue