[Freeswitch-svn] [commit] r12916 - in freeswitch/trunk: conf/autoload_configs src/mod/applications/mod_voicemail
FreeSWITCH SVN
mrene at freeswitch.org
Mon Apr 6 09:36:33 PDT 2009
Author: mrene
Date: Mon Apr 6 11:36:33 2009
New Revision: 12916
Log:
MODAPP-251
Modified:
freeswitch/trunk/conf/autoload_configs/voicemail.conf.xml
freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c
Modified: freeswitch/trunk/conf/autoload_configs/voicemail.conf.xml
==============================================================================
--- freeswitch/trunk/conf/autoload_configs/voicemail.conf.xml (original)
+++ freeswitch/trunk/conf/autoload_configs/voicemail.conf.xml Mon Apr 6 11:36:33 2009
@@ -15,6 +15,7 @@
<param name="callback-context" value="default"/>
<param name="play-new-messages-key" value="1"/>
<param name="play-saved-messages-key" value="2"/>
+ <param name="login-keys" value="0"/>
<param name="main-menu-key" value="0"/>
<param name="config-menu-key" value="5"/>
<param name="record-greeting-key" value="1"/>
Modified: freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c
==============================================================================
--- freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c (original)
+++ freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c Mon Apr 6 11:36:33 2009
@@ -73,6 +73,7 @@
char play_new_messages_key[2];
char play_saved_messages_key[2];
+ char login_keys[16];
char main_menu_key[2];
char skip_greet_key[2];
char config_menu_key[2];
@@ -283,6 +284,7 @@
char *play_new_messages_key = "1";
char *play_saved_messages_key = "2";
+ char *login_keys = "0";
char *main_menu_key = "0";
char *skip_greet_key = "#";
char *config_menu_key = "5";
@@ -464,6 +466,8 @@
play_new_messages_key = val;
} else if (!strcasecmp(var, "play-saved-messages-key") && !switch_strlen_zero(val)) {
play_saved_messages_key = val;
+ } else if (!strcasecmp(var, "login-keys") && !switch_strlen_zero(val)) {
+ login_keys = val;
} else if (!strcasecmp(var, "main-menu-key") && !switch_strlen_zero(val)) {
main_menu_key = val;
} else if (!strcasecmp(var, "skip-greet-key") && val && (!*val || is_dtmf(*val))) {
@@ -762,6 +766,7 @@
*profile->terminator_key = *terminator_key;
*profile->play_new_messages_key = *play_new_messages_key;
*profile->play_saved_messages_key = *play_saved_messages_key;
+ switch_set_string(profile->login_keys, login_keys);
*profile->main_menu_key = *main_menu_key;
*profile->skip_greet_key = *skip_greet_key;
*profile->config_menu_key = *config_menu_key;
@@ -2925,7 +2930,7 @@
if (*buf != '\0') {
greet_key_press:
- if (!strcasecmp(buf, profile->main_menu_key)) {
+ if (switch_stristr(buf, profile->login_keys)) {
voicemail_check_main(session, profile_name, domain_name, id, 0);
} else if (!strcasecmp(buf, profile->operator_key) && !switch_strlen_zero(profile->operator_key)) {
int argc;
More information about the Freeswitch-svn
mailing list