app_queue: Reset all queue defaults before reload.

Several queue fields were not being set to their default value during
a reload.

Additionally added some sample configuration options that were missing
from queues.conf.sample.

Change-Id: I3a88c7877af91752b1b46a0c087384f7eb9c47e4
This commit is contained in:
Sean Bright 2023-01-31 09:40:54 -05:00 committed by Friendly Automation
parent 58636a6ea6
commit aef0c0ce0e
2 changed files with 18 additions and 0 deletions

View File

@ -2956,7 +2956,11 @@ static void init_queue(struct call_queue *q)
q->timeout = DEFAULT_TIMEOUT; q->timeout = DEFAULT_TIMEOUT;
q->maxlen = 0; q->maxlen = 0;
ast_string_field_set(q, announce, "");
ast_string_field_set(q, context, ""); ast_string_field_set(q, context, "");
ast_string_field_set(q, membermacro, "");
ast_string_field_set(q, membergosub, "");
ast_string_field_set(q, defaultrule, "");
q->announcefrequency = 0; q->announcefrequency = 0;
q->minannouncefrequency = DEFAULT_MIN_ANNOUNCE_FREQUENCY; q->minannouncefrequency = DEFAULT_MIN_ANNOUNCE_FREQUENCY;
@ -2985,7 +2989,10 @@ static void init_queue(struct call_queue *q)
q->periodicannouncefrequency = 0; q->periodicannouncefrequency = 0;
q->randomperiodicannounce = 0; q->randomperiodicannounce = 0;
q->numperiodicannounce = 0; q->numperiodicannounce = 0;
q->relativeperiodicannounce = 0;
q->autopause = QUEUE_AUTOPAUSE_OFF; q->autopause = QUEUE_AUTOPAUSE_OFF;
q->autopausebusy = 0;
q->autopauseunavail = 0;
q->timeoutpriority = TIMEOUT_PRIORITY_APP; q->timeoutpriority = TIMEOUT_PRIORITY_APP;
q->autopausedelay = 0; q->autopausedelay = 0;
if (!q->members) { if (!q->members) {
@ -3010,6 +3017,7 @@ static void init_queue(struct call_queue *q)
ast_string_field_set(q, sound_minute, "queue-minute"); ast_string_field_set(q, sound_minute, "queue-minute");
ast_string_field_set(q, sound_seconds, "queue-seconds"); ast_string_field_set(q, sound_seconds, "queue-seconds");
ast_string_field_set(q, sound_thanks, "queue-thankyou"); ast_string_field_set(q, sound_thanks, "queue-thankyou");
ast_string_field_set(q, sound_callerannounce, "");
ast_string_field_set(q, sound_reporthold, "queue-reporthold"); ast_string_field_set(q, sound_reporthold, "queue-reporthold");
if (!q->sound_periodicannounce[0]) { if (!q->sound_periodicannounce[0]) {

View File

@ -78,6 +78,12 @@ monitor-type = MixMonitor
; ;
;announce = queue-markq ;announce = queue-markq
; ;
; An announcement may be specified which is played to the caller just
; before they are bridged with an agent. The default is to not play an
; announcement to the caller.
;
;queue-callerannounce = you-are-being-connected
;
; A strategy may be specified. Valid strategies include: ; A strategy may be specified. Valid strategies include:
; ;
; ringall - ring all available channels until one answers (default) ; ringall - ring all available channels until one answers (default)
@ -354,6 +360,10 @@ monitor-type = MixMonitor
;queue-thereare = queue-thereare ;queue-thereare = queue-thereare
; ("calls waiting.") ; ("calls waiting.")
;queue-callswaiting = queue-callswaiting ;queue-callswaiting = queue-callswaiting
; ("Currently there are more than")
;queue-quantity1 = queue-quantity1
; ("callers waiting to speak with a representative")
;queue-quantity2 = queue-quantity2
; ("The current est. holdtime is") ; ("The current est. holdtime is")
;queue-holdtime = queue-holdtime ;queue-holdtime = queue-holdtime
; ("minute.") ; ("minute.")