From: Travis Cross Date: Mon, 18 Jul 2011 09:39:11 +0000 (+0000) Subject: mod_callcenter: set cc_exit_key channel variable X-Git-Tag: v1.2-rc1~19^2^2~68^2~24 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b2aa332090e24f6412bd07d0a6278ffd44d90ef6;p=thirdparty%2Ffreeswitch.git mod_callcenter: set cc_exit_key channel variable If a member of a queue presses a digit specified in cc_exit_keys, the caller will exit the queue and the variable cc_exit_key will be set to the digit the caller pressed. --- diff --git a/src/mod/applications/mod_callcenter/mod_callcenter.c b/src/mod/applications/mod_callcenter/mod_callcenter.c index 9133a0c0a9..49fb76f9d7 100644 --- a/src/mod/applications/mod_callcenter/mod_callcenter.c +++ b/src/mod/applications/mod_callcenter/mod_callcenter.c @@ -2577,12 +2577,16 @@ SWITCH_STANDARD_APP(callcenter_function) switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(member_session), SWITCH_LOG_WARNING, "Couldn't play file '%s', continuing wait with no audio\n", cur_moh); moh_valid = SWITCH_FALSE; } else if (status == SWITCH_STATUS_BREAK) { + char buf[2] = { ht.dtmf, 0 }; + switch_channel_set_variable(member_channel, "cc_exit_key", buf); break; } else if (!SWITCH_READ_ACCEPTABLE(status)) { break; } } else { if ((switch_ivr_collect_digits_callback(member_session, &args, 0, 0)) == SWITCH_STATUS_BREAK) { + char buf[2] = { ht.dtmf, 0 }; + switch_channel_set_variable(member_channel, "cc_exit_key", buf); break; } }