diff --git a/agc_2-X/trunk/UPGRADE b/agc_2-X/trunk/UPGRADE index 5cd2dd91..af48894e 100644 --- a/agc_2-X/trunk/UPGRADE +++ b/agc_2-X/trunk/UPGRADE @@ -22,8 +22,10 @@ NOTE: Upgrading from 1.1.12-3 to 2.0.1 is at the bottom 3. Added new method for monitoring from the Real-time screen using a phone entry -4. Outbound Survey option for using Cepstral Text-to-speech. Requires some - manual configuration and tweaking of TTS scripts. +4. Outbound Survey option for using Cepstral Text-to-speech. Requires Cepstral + to be installed and configured with proper licenses in place to use. + You must enable TTS in the System Settings screen, then you can access + the TTS section of the web administration. 5. Added RANDOM and LAST CALL TIME lead order options to campaigns diff --git a/agc_2-X/trunk/agi/agi-VDAD_ALL_outbound.agi b/agc_2-X/trunk/agi/agi-VDAD_ALL_outbound.agi index 7d57e66b..909ea306 100644 --- a/agc_2-X/trunk/agi/agi-VDAD_ALL_outbound.agi +++ b/agc_2-X/trunk/agi/agi-VDAD_ALL_outbound.agi @@ -62,6 +62,7 @@ # 90202-0505 - Added CPD AMD detection and routing options # 90214-0831 - Added CPD Fax detection option # 90410-1645 - Added SURVEYCAMPCEP call handling method and cleaned up formatting +# 90628-1138 - Added more variable options for Cepstral TTS generation # $script = 'agi-VDAD_ALL_outbound.agi'; @@ -457,7 +458,7 @@ if ($affected_rows > 0) ### if there are TTS audio files run this if ($t > 0) { - $stmtA = "SELECT first_name,last_name,title FROM vicidial_list where lead_id='$CIDlead_id';"; + $stmtA = "SELECT lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time FROM vicidial_list where lead_id='$CIDlead_id';"; $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; $sthA->execute or die "executing: $stmtA ", $dbhA->errstr; $sthArows=$sthA->rows; @@ -465,9 +466,35 @@ if ($affected_rows > 0) if ($sthArows > 0) { @aryA = $sthA->fetchrow_array; - $TTS_first_name = $aryA[0]; - $TTS_last_name = $aryA[1]; - $TTS_title = $aryA[2]; + $TTS_lead_id = $aryA[0]; + $TTS_entry_date = $aryA[1]; + $TTS_modify_date = $aryA[2]; + $TTS_status = $aryA[3]; + $TTS_user = $aryA[4]; + $TTS_vendor_lead_code = $aryA[5]; + $TTS_source_id = $aryA[6]; + $TTS_list_id = $aryA[7]; + $TTS_phone_number = $aryA[8]; + $TTS_title = $aryA[9]; + $TTS_first_name = $aryA[10]; + $TTS_middle_initial = $aryA[11]; + $TTS_last_name = $aryA[12]; + $TTS_address1 = $aryA[13]; + $TTS_address2 = $aryA[14]; + $TTS_address3 = $aryA[15]; + $TTS_city = $aryA[16]; + $TTS_state = $aryA[17]; + $TTS_province = $aryA[18]; + $TTS_postal_code = $aryA[19]; + $TTS_country_code = $aryA[20]; + $TTS_gender = $aryA[21]; + $TTS_date_of_birth = $aryA[22]; + $TTS_alt_phone = $aryA[23]; + $TTS_email = $aryA[24]; + $TTS_security_phrase = $aryA[25]; + $TTS_comments = $aryA[26]; + $TTS_called_count = $aryA[27]; + $TTS_last_local_call_time = $aryA[28]; } $sthA->finish(); @@ -485,9 +512,35 @@ if ($affected_rows > 0) { @aryA = $sthA->fetchrow_array; $TTS_text[$s] = $aryA[0]; - $TTS_text[$s] =~ s/--A--first_name--B--/$TTS_first_name/gi; - $TTS_text[$s] =~ s/--A--last_name--B--/$TTS_last_name/gi; + $TTS_text[$s] =~ s/--A--lead_id--B--/$TTS_lead_id/gi; + $TTS_text[$s] =~ s/--A--entry_date--B--/$TTS_entry_date/gi; + $TTS_text[$s] =~ s/--A--modify_date--B--/$TTS_modify_date/gi; + $TTS_text[$s] =~ s/--A--status--B--/$TTS_status/gi; + $TTS_text[$s] =~ s/--A--user--B--/$TTS_user/gi; + $TTS_text[$s] =~ s/--A--vendor_lead_code--B--/$TTS_vendor_lead_code/gi; + $TTS_text[$s] =~ s/--A--source_id--B--/$TTS_source_id/gi; + $TTS_text[$s] =~ s/--A--list_id--B--/$TTS_list_id/gi; + $TTS_text[$s] =~ s/--A--phone_number--B--/$TTS_phone_number/gi; $TTS_text[$s] =~ s/--A--title--B--/$TTS_title/gi; + $TTS_text[$s] =~ s/--A--first_name--B--/$TTS_first_name/gi; + $TTS_text[$s] =~ s/--A--middle_initial--B--/$TTS_middle_initial/gi; + $TTS_text[$s] =~ s/--A--last_name--B--/$TTS_last_name/gi; + $TTS_text[$s] =~ s/--A--address1--B--/$TTS_address1/gi; + $TTS_text[$s] =~ s/--A--address2--B--/$TTS_address2/gi; + $TTS_text[$s] =~ s/--A--address3--B--/$TTS_address3/gi; + $TTS_text[$s] =~ s/--A--city--B--/$TTS_city/gi; + $TTS_text[$s] =~ s/--A--state--B--/$TTS_state/gi; + $TTS_text[$s] =~ s/--A--province--B--/$TTS_province/gi; + $TTS_text[$s] =~ s/--A--postal_code--B--/$TTS_postal_code/gi; + $TTS_text[$s] =~ s/--A--country_code--B--/$TTS_country_code/gi; + $TTS_text[$s] =~ s/--A--gender--B--/$TTS_gender/gi; + $TTS_text[$s] =~ s/--A--date_of_birth--B--/$TTS_date_of_birth/gi; + $TTS_text[$s] =~ s/--A--alt_phone--B--/$TTS_alt_phone/gi; + $TTS_text[$s] =~ s/--A--email--B--/$TTS_email/gi; + $TTS_text[$s] =~ s/--A--security_phrase--B--/$TTS_security_phrase/gi; + $TTS_text[$s] =~ s/--A--comments--B--/$TTS_comments/gi; + $TTS_text[$s] =~ s/--A--called_count--B--/$TTS_called_count/gi; + $TTS_text[$s] =~ s/--A--last_local_call_time--B--/$TTS_last_local_call_time/gi; $TTS_text[$s] =~ s/[^,\.\<\>\'\/\=\_ 0-9a-zA-Z]//gi; $TTS_textRAW[$s] = $TTS_text[$s]; $TTS_text[$s] =~ s/ /\\ /gi; diff --git a/agc_2-X/trunk/install.pl b/agc_2-X/trunk/install.pl index b8832c95..9da80814 100644 --- a/agc_2-X/trunk/install.pl +++ b/agc_2-X/trunk/install.pl @@ -2238,6 +2238,7 @@ if ($NOWEB < 1) `cp -f -R ./www/* $PATHweb/`; print "setting web scripts to executable...\n"; + `chmod 0666 $PATHweb`; `chmod -R 0755 $PATHweb/agc/`; `chmod -R 0755 $PATHweb/astguiclient/`; `chmod -R 0755 $PATHweb/vicidial/`; diff --git a/agc_2-X/trunk/translations/raw_translation_files/TO_BE_TRANSLATED_2.2.0.txt b/agc_2-X/trunk/translations/raw_translation_files/TO_BE_TRANSLATED_2.2.0.txt index 264776fa..70787342 100644 --- a/agc_2-X/trunk/translations/raw_translation_files/TO_BE_TRANSLATED_2.2.0.txt +++ b/agc_2-X/trunk/translations/raw_translation_files/TO_BE_TRANSLATED_2.2.0.txt @@ -190,6 +190,36 @@ Quick Transfer Button|| This option will add a Quick Transfer button to the agent screen below the Transfer-Conf button that will allow one click blind transferring of calls to the selected In-Group or number. IN_GROUP will send calls to the Default Xfer Group for this Campaign, or In-Group if there was an inbound call. The PRESET options will send the calls to the preset selected. Default is N for disabled|| PrePopulate Transfer Preset|| This option will fill in the Number to Dial field in the Transfer Conference frame of the agent screen if defined. Default is N for disabled|| +Enable TTS Integration|| +This setting allows you to enable Text To Speech integration with Cepstral. This is currently only available for outbound Survey type campaigns. Default is 0 for disabled|| +ADD NEW TTS ENTRY|| +ADDING NEW TTS ENTRY|| +MODIFY TTS ENTRY|| +DELETE TTS ENTRY|| +TTS ENTRY LIST|| +TEXT-TO-SPEECH(TTS) LISTINGS|| +Text To Speech|| +Show TTS Entries|| +Add A New TTS Entry|| +TTS ID|| +TTS Name|| +TTS Text|| +TTS ENTRY NOT ADDED|| +there is already a tts entry in the system with this ID|| +TTS ENTRY ADDED|| +MODIFY A TTS RECORD|| +Click here to see Admin chages to this TTS entry|| +DELETE THIS TTS ENTRY|| +TTS ENTRY NOT MODIFIED|| +TTS ENTRY MODIFIED|| +TTS ENTRY NOT DELETED|| +TTS ENTRY DELETION CONFIRMATION|| +Click here to delete tts entry|| +This is the short name of a TTS entry. This needs to be a unique identifier. Do not use any spaces or punctuation for this field. max 50 characters, minimum of 2 characters|| +This is a more descriptive name of the TTS entry. This is a short summary of the TTS definition. max 100 characters, minimum of 2 characters|| +This option allows you to set the TTS entry to active or inactive|| +This is the actual Text To Speech data field that is sent to Cepstral for creation of the audio file to be played to the customer. you can use Speech Synthesis Markup Language -SSML- in this field, for example|| +for a 1 second break. You can also use several variables such as first name, last name and title as ViciDial variables just like you do in a Script: --A--first_name--B--. Here is a list of the available variables: || add-file: user_territories.php diff --git a/agc_2-X/trunk/www/vicidial/admin.php b/agc_2-X/trunk/www/vicidial/admin.php index bf864f92..2820e537 100644 --- a/agc_2-X/trunk/www/vicidial/admin.php +++ b/agc_2-X/trunk/www/vicidial/admin.php @@ -38,6 +38,7 @@ $reports_color = '#99FF33'; $carriers_color = '#FF33FF'; $settings_color = '#FF33FF'; $status_color = '#FF33FF'; + $tts_color = '#FF33FF'; $subcamp_color = '#FF9933'; $users_font = 'BLACK'; $campaigns_font = 'BLACK'; @@ -55,6 +56,7 @@ $reports_font = 'BLACK'; $server_font = 'BLACK'; $settings_font = 'BLACK'; $status_font = 'BLACK'; + $tts_font = 'BLACK'; $subcamp_font = 'BLACK'; ### comment this section out for colorful section headings @@ -77,6 +79,7 @@ $reports_color = '#E6E6E6'; $carriers_color = '#C6C6C6'; $settings_color = '#C6C6C6'; $status_color = '#C6C6C6'; + $tts_color = '#C6C6C6'; $subcamp_color = '#C6C6C6'; ### @@ -1054,6 +1057,14 @@ if (isset($_GET["quick_transfer_button"])) {$quick_transfer_button=$_GET["quic elseif (isset($_POST["quick_transfer_button"])) {$quick_transfer_button=$_POST["quick_transfer_button"];} if (isset($_GET["prepopulate_transfer_preset"])) {$prepopulate_transfer_preset=$_GET["prepopulate_transfer_preset"];} elseif (isset($_POST["prepopulate_transfer_preset"])) {$prepopulate_transfer_preset=$_POST["prepopulate_transfer_preset"];} +if (isset($_GET["enable_tts_integration"])) {$enable_tts_integration=$_GET["enable_tts_integration"];} + elseif (isset($_POST["enable_tts_integration"])) {$enable_tts_integration=$_POST["enable_tts_integration"];} +if (isset($_GET["tts_id"])) {$tts_id=$_GET["tts_id"];} + elseif (isset($_POST["tts_id"])) {$tts_id=$_POST["tts_id"];} +if (isset($_GET["tts_name"])) {$tts_name=$_GET["tts_name"];} + elseif (isset($_POST["tts_name"])) {$tts_name=$_POST["tts_name"];} +if (isset($_GET["tts_text"])) {$tts_text=$_GET["tts_text"];} + elseif (isset($_POST["tts_text"])) {$tts_text=$_POST["tts_text"];} if (isset($script_id)) {$script_id= strtoupper($script_id);} if (isset($lead_filter_id)) {$lead_filter_id = strtoupper($lead_filter_id);} @@ -1248,6 +1259,7 @@ if ($non_latin < 1) $vicidial_recording_limit = ereg_replace("[^0-9]","",$vicidial_recording_limit); $allow_custom_dialplan = ereg_replace("[^0-9]","",$allow_custom_dialplan); $phone_ring_timeout = ereg_replace("[^0-9]","",$phone_ring_timeout); + $enable_tts_integration = ereg_replace("[^0-9]","",$enable_tts_integration); ### DIGITS and COLONS $shift_length = ereg_replace("[^\:0-9]","",$shift_length); @@ -1265,7 +1277,6 @@ if ($non_latin < 1) $phone_numbers = ereg_replace("[^\n0-9]","",$phone_numbers); ### Y or N ONLY ### - $active = ereg_replace("[^NY]","",$active); $allow_closers = ereg_replace("[^NY]","",$allow_closers); $reset_hopper = ereg_replace("[^NY]","",$reset_hopper); $amd_send_to_vmx = ereg_replace("[^NY]","",$amd_send_to_vmx); @@ -1309,6 +1320,7 @@ if ($non_latin < 1) $carrier_logging_active = ereg_replace("[^NY]","",$carrier_logging_active); $qc_enabled = ereg_replace("[^0-9NY]","",$qc_enabled); + $active = ereg_replace("[^0-9NY]","",$active); ### ALPHA-NUMERIC ONLY ### @@ -1486,6 +1498,7 @@ if ($non_latin < 1) $no_agent_action = ereg_replace("[^-_0-9a-zA-Z]","",$no_agent_action); $quick_transfer_button = ereg_replace("[^-_0-9a-zA-Z]","",$quick_transfer_button); $prepopulate_transfer_preset = ereg_replace("[^-_0-9a-zA-Z]","",$prepopulate_transfer_preset); + $tts_id = ereg_replace("[^-_0-9a-zA-Z]","",$tts_id); ### ALPHA-NUMERIC and underscore and dash and slash and dot $menu_prompt = ereg_replace("[^-\/\|\._0-9a-zA-Z]","",$menu_prompt); @@ -1555,6 +1568,7 @@ if ($non_latin < 1) $caller_id_name = ereg_replace("[^ \.\,-\_0-9a-zA-Z]","",$caller_id_name); $user_code = ereg_replace("[^ \.\,-\_0-9a-zA-Z]","",$user_code); $territory = ereg_replace("[^ \.\,-\_0-9a-zA-Z]","",$territory); + $tts_name = ereg_replace("[^ \.\,-\_0-9a-zA-Z]","",$tts_name); ### ALPHA-NUMERIC and underscore and dash and slash and at and dot $call_out_number_group = ereg_replace("[^-\.\:\/\@\_0-9a-zA-Z]","",$call_out_number_group); @@ -1601,6 +1615,10 @@ if ($non_latin < 1) $custom_dialplan_entry = ereg_replace("\\\\","",$custom_dialplan_entry); $custom_dialplan_entry = ereg_replace(";","",$custom_dialplan_entry); $custom_dialplan_entry = ereg_replace("\r","",$custom_dialplan_entry); + $tts_text = ereg_replace("\\\\","",$tts_text); + $tts_text = ereg_replace(";","",$tts_text); + $tts_text = ereg_replace("\r","",$tts_text); + $tts_text = ereg_replace("\"","",$tts_text); ### VARIABLES TO BE mysql_real_escape_string ### # $web_form_address @@ -1624,7 +1642,7 @@ else ##### END VARIABLE FILTERING FOR SECURITY ##### -# AST GUI database administration +# ViciDial database administration # admin.php # # CHANGELOG: @@ -1834,15 +1852,16 @@ else # 90612-0909 - Added audio prompt selection feature to survey screen # 90614-0827 - Added In-Group routing to Call Menu screen, Added pull-down Call Menu option to DID screen # 90617-0733 - Added phone ring timeout and call menu custom dialplan entries -# 90621-0821 - Added phon Conf File Secret field to use a separate password from the user interface for a phone +# 90621-0821 - Added phone Conf File Secret field to use a separate password from the user interface for a phone # 90621-1220 - Added Call Menu logging tracking_group # 90627-0547 - Added no-agent-no-queue options # 90627-2333 - Added default transfer button and prepopulate preset options +# 90628-0924 - Added Text To Speech(TTS) fields # # make sure you have added a user to the vicidial_users MySQL table with at least user_level 8 to access this page the first time -$admin_version = '2.2.0-201'; -$build = '90627-2333'; +$admin_version = '2.2.0-202'; +$build = '90628-0924'; $STARTtime = date("U"); $SQLdate = date("Y-m-d H:i:s"); @@ -2033,6 +2052,7 @@ if ($ADD==13111111111) {$hh='admin'; $sh='phones'; echo "ADD NEW GROUP ALIAS";} if ($ADD==111111111111) {$hh='admin'; $sh='server'; echo "ADD NEW SERVER";} if ($ADD==131111111111) {$hh='admin'; $sh='templates'; echo "ADD NEW CONF TEMPLATE";} if ($ADD==141111111111) {$hh='admin'; $sh='carriers'; echo "ADD NEW CARRIER";} +if ($ADD==151111111111) {$hh='admin'; $sh='tts'; echo "ADD NEW TTS ENTRY";} if ($ADD==1111111111111) {$hh='admin'; $sh='conference'; echo "ADD NEW CONFERENCE";} if ($ADD==11111111111111) {$hh='admin'; $sh='conference'; echo "ADD NEW VICIDIAL CONFERENCE";} if ($ADD=='2') {$hh='users'; echo "New User Addition";} @@ -2067,6 +2087,7 @@ if ($ADD==211111111111) {$hh='admin'; $sh='server'; echo "ADDING NEW SERVER";} if ($ADD==221111111111) {$hh='admin'; $sh='server'; echo "ADDING NEW SERVER VICIDIAL TRUNK RECORD";} if ($ADD==231111111111) {$hh='admin'; $sh='templates'; echo "ADDING NEW CONF TEMPLATE";} if ($ADD==241111111111) {$hh='admin'; $sh='carriers'; echo "ADDING NEW CARRIER";} +if ($ADD==251111111111) {$hh='admin'; $sh='tts'; echo "ADDING NEW TTS ENTRY";} if ($ADD==2111111111111) {$hh='admin'; $sh='conference'; echo "ADDING NEW CONFERENCE";} if ($ADD==21111111111111) {$hh='admin'; $sh='conference'; echo "ADDING NEW VICIDIAL CONFERENCE";} if ($ADD==221111111111111) {$hh='admin'; $sh='status'; echo "ADDING VICIDIAL SYSTEM STATUSES";} @@ -2123,6 +2144,7 @@ if ($ADD==33111111111) {$hh='admin'; $sh='phones'; echo "MODIFY GROUP ALIAS";} if ($ADD==311111111111) {$hh='admin'; $sh='server'; echo "MODIFY SERVER";} if ($ADD==331111111111) {$hh='admin'; $sh='templates'; echo "MODIFY CONF TEMPLATE";} if ($ADD==341111111111) {$hh='admin'; $sh='carriers'; echo "MODIFY CARRIER";} +if ($ADD==351111111111) {$hh='admin'; $sh='tts'; echo "MODIFY TTS ENTRY";} if ($ADD==3111111111111) {$hh='admin'; $sh='conference'; echo "MODIFY CONFERENCE";} if ($ADD==31111111111111) {$hh='admin'; $sh='conference'; echo "MODIFY VICIDIAL CONFERENCE";} if ($ADD==311111111111111) {$hh='admin'; $sh='settings'; echo "MODIFY VICIDIAL SYSTEM SETTINGS";} @@ -2159,6 +2181,7 @@ if ($ADD==411111111111) {$hh='admin'; $sh='server'; echo "MODIFY SERVER";} if ($ADD==421111111111) {$hh='admin'; $sh='server'; echo "MODIFY SERVER VICIDIAL TRUNK RECORD";} if ($ADD==431111111111) {$hh='admin'; $sh='templates'; echo "MODIFY CONF TEMPLATE";} if ($ADD==441111111111) {$hh='admin'; $sh='carriers'; echo "MODIFY CARRIER";} +if ($ADD==451111111111) {$hh='admin'; $sh='tts'; echo "MODIFY TTS ENTRY";} if ($ADD==4111111111111) {$hh='admin'; $sh='conference'; echo "MODIFY CONFERENCE";} if ($ADD==41111111111111) {$hh='admin'; $sh='conference'; echo "MODIFY VICIDIAL CONFERENCE";} if ($ADD==411111111111111) {$hh='admin'; $sh='settings'; echo "MODIFY VICIDIAL SYSTEM SETTINGS";} @@ -2186,6 +2209,7 @@ if ($ADD==53111111111) {$hh='admin'; $sh='phones'; echo "DELETE GROUP ALIAS";} if ($ADD==511111111111) {$hh='admin'; $sh='server'; echo "DELETE SERVER";} if ($ADD==531111111111) {$hh='admin'; $sh='templates'; echo "DELETE CONF TEMPLATE";} if ($ADD==541111111111) {$hh='admin'; $sh='carriers'; echo "DELETE CARRIER";} +if ($ADD==551111111111) {$hh='admin'; $sh='tts'; echo "DELETE TTS ENTRY";} if ($ADD==5111111111111) {$hh='admin'; $sh='conference'; echo "DELETE CONFERENCE";} if ($ADD==51111111111111) {$hh='admin'; $sh='conference'; echo "DELETE VICIDIAL CONFERENCE";} if ($ADD==6) {$hh='users'; echo "Delete User";} @@ -2213,8 +2237,9 @@ if ($ADD==62111111111) {$hh='admin'; $sh='phones'; echo "DELETE PHONE ALIAS";} if ($ADD==63111111111) {$hh='admin'; $sh='phones'; echo "DELETE GROUP ALIAS";} if ($ADD==611111111111) {$hh='admin'; $sh='server'; echo "DELETE SERVER";} if ($ADD==621111111111) {$hh='admin'; $sh='server'; echo "DELETE SERVER VICIDIAL TRUNK RECORD";} -if ($ADD==621111111111) {$hh='admin'; $sh='templates'; echo "DELETE CONF TEMPLATE";} -if ($ADD==621111111111) {$hh='admin'; $sh='carriers'; echo "DELETE CARRIER";} +if ($ADD==631111111111) {$hh='admin'; $sh='templates'; echo "DELETE CONF TEMPLATE";} +if ($ADD==641111111111) {$hh='admin'; $sh='carriers'; echo "DELETE CARRIER";} +if ($ADD==651111111111) {$hh='admin'; $sh='tts'; echo "DELETE TTS ENTRY";} if ($ADD==6111111111111) {$hh='admin'; $sh='conference'; echo "DELETE CONFERENCE";} if ($ADD==61111111111111) {$hh='admin'; $sh='conference'; echo "DELETE VICIDIAL CONFERENCE";} if ($ADD==73) {$hh='campaigns'; echo "Dialable Lead Count";} @@ -2246,6 +2271,7 @@ if ($ADD==13000000000) {$hh='admin'; $sh='phones'; echo "GROUP ALIAS LIST";} if ($ADD==100000000000) {$hh='admin'; $sh='server'; echo "SERVER LIST";} if ($ADD==130000000000) {$hh='admin'; $sh='templates'; echo "CONF TEMPLATE LIST";} if ($ADD==140000000000) {$hh='admin'; $sh='carriers'; echo "CARRIER LIST";} +if ($ADD==150000000000) {$hh='admin'; $sh='tts'; echo "TTS ENTRY LIST";} if ($ADD==1000000000000) {$hh='admin'; $sh='conference'; echo "CONFERENCE LIST";} if ($ADD==10000000000000) {$hh='admin'; $sh='conference'; echo "VICIDIAL CONFERENCE LIST";} if ($ADD==550) {$hh='users'; echo "Search Form";} @@ -4510,12 +4536,34 @@ if ($SSoutbound_autodial_active > 0) -
+



Audio Store - This utility allows you to upload audio files to the web server so that they can be distributed to all of the ViciDial servers in a multi-server cluster. An important note, only two audio file types will work, .wav files that are PCM 16bit 8k and .gsm files that are 8bit 8k. Please verify that your files are properly formatted before uploading them here. +



+ +VICIDIAL_TTS_PROMPTS TABLE

+
+
+TTS ID - This is the short name of a TTS entry. This needs to be a unique identifier. Do not use any spaces or punctuation for this field. max 50 characters, minimum of 2 characters. + +
+
+TTS Name - This is a more descriptive name of the TTS entry. This is a short summary of the TTS definition. max 100 characters, minimum of 2 characters. + +
+
+Active - This option allows you to set the TTS entry to active or inactive. + +
+
+TTS Text - This is the actual Text To Speech data field that is sent to Cepstral for creation of the audio file to be played to the customer. you can use Speech Synthesis Markup Language -SSML- in this field, for example, <break time='1000ms'/> for a 1 second break. You can also use several variables such as first name, last name and title as ViciDial variables just like you do in a Script: --A--first_name--B--. Here is a list of the available variables: lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time + + + + 0) { @@ -5396,6 +5444,11 @@ FR_SPAC 00 00 00 00 00 - France space separated phone number

User Territories Active - This setting allows you to enable the User Territories setttings from the user modification screen. This feature was added to allow for more integration with a customized Vtiger installation but can have applications in a pure ViciDial system as well. Default is 0 for disabled. +
+
+
+Enable TTS Integration - This setting allows you to enable Text To Speech integration with Cepstral. This is currently only available for outbound Survey type campaigns. Default is 0 for disabled. +

@@ -7191,6 +7244,36 @@ if ($ADD==141111111111) } +###################### +# ADD=151111111111 display the ADD NEW TTS ENTRY SCREEN +###################### + +if ($ADD==151111111111) + { + if ($LOGmodify_servers==1) + { + echo "
\n"; + echo ""; + + echo "
ADD NEW TTS ENTRY
\n"; + echo "\n"; + echo "
\n"; + + echo "\n"; + echo "\n"; + echo "\n"; + + echo "\n"; + echo "
TTS ID: $NWB#vicidial_tts_prompts-tts_id$NWE
TTS Name: $NWB#vicidial_tts_prompts-tts_name$NWE
Active:
\n"; + } + else + { + echo "You do not have permission to view this page\n"; + exit; + } + } + + ###################### # ADD=1111111111111 display the ADD NEW CONFERENCE SCREEN ###################### @@ -9356,6 +9439,42 @@ if ($ADD==241111111111) } +###################### +# ADD=251111111111 adds new tts entry to the system +###################### + +if ($ADD==251111111111) + { + echo ""; + $stmt="SELECT count(*) from vicidial_tts_prompts where tts_id='$tts_id';"; + $rslt=mysql_query($stmt, $link); + $row=mysql_fetch_row($rslt); + if ($row[0] > 0) + {echo "
TTS ENTRY NOT ADDED - there is already a tts entry in the system with this ID\n";} + else + { + if ( (strlen($tts_id) < 2) or (strlen($tts_name) < 3) ) + {echo "
TTS ENTRY NOT ADDED - Please go back and look at the data you entered\n";} + else + { + echo "
TTS ENTRY ADDED\n"; + + $stmt="INSERT INTO vicidial_tts_prompts SET tts_id='$tts_id',tts_name='$tts_name',active='$active';"; + $rslt=mysql_query($stmt, $link); + + ### LOG INSERTION Admin Log Table ### + $SQL_log = "$stmt|"; + $SQL_log = ereg_replace(';','',$SQL_log); + $SQL_log = addslashes($SQL_log); + $stmt="INSERT INTO vicidial_admin_log set event_date='$SQLdate', user='$PHP_AUTH_USER', ip_address='$ip', event_section='TTS', event_type='ADD', record_id='$carrier_id', event_code='ADMIN ADD TTS', event_sql=\"$SQL_log\", event_notes='';"; + if ($DB) {echo "|$stmt|\n";} + $rslt=mysql_query($stmt, $link); + } + } + $ADD=351111111111; + } + + ###################### # ADD=2111111111111 adds new conference to the system ###################### @@ -12179,6 +12298,44 @@ $ADD=341111111111; # go to carrier modification form below } + +###################### +# ADD=451111111111 modify tts record in the system +###################### + +if ($ADD==451111111111) +{ + if ($LOGmodify_servers==1) + { + echo ""; + + if ( (strlen($tts_id) < 2) or (strlen($tts_name) < 5) ) + {echo "
TTS ENTRY NOT MODIFIED - Please go back and look at the data you entered\n";} + else + { + echo "
TTS ENTRY MODIFIED: $tts_id\n"; + + $stmt="UPDATE vicidial_tts_prompts set tts_name='$tts_name',active='$active',tts_text=\"$tts_text\" where tts_id='$tts_id';"; + $rslt=mysql_query($stmt, $link); + + ### LOG INSERTION Admin Log Table ### + $SQL_log = "$stmt|"; + $SQL_log = ereg_replace(';','',$SQL_log); + $SQL_log = addslashes($SQL_log); + $stmt="INSERT INTO vicidial_admin_log set event_date='$SQLdate', user='$PHP_AUTH_USER', ip_address='$ip', event_section='TTS', event_type='MODIFY', record_id='$tts_id', event_code='ADMIN MODIFY TTS', event_sql=\"$SQL_log\", event_notes='';"; + if ($DB) {echo "|$stmt|\n";} + $rslt=mysql_query($stmt, $link); + } + } + else + { + echo "You do not have permission to view this page\n"; + exit; + } +$ADD=351111111111; # go to tts entry modification form below +} + + ###################### # ADD=4111111111111 modify conference record in the system ###################### @@ -12267,7 +12424,7 @@ if ($ADD==411111111111111) echo "
VICIDIAL SYSTEM SETTINGS MODIFIED\n"; - $stmt="UPDATE system_settings set use_non_latin='$use_non_latin',webroot_writable='$webroot_writable',enable_queuemetrics_logging='$enable_queuemetrics_logging',queuemetrics_server_ip='$queuemetrics_server_ip',queuemetrics_dbname='$queuemetrics_dbname',queuemetrics_login='$queuemetrics_login',queuemetrics_pass='$queuemetrics_pass',queuemetrics_url='$queuemetrics_url',queuemetrics_log_id='$queuemetrics_log_id',queuemetrics_eq_prepend='$queuemetrics_eq_prepend',vicidial_agent_disable='$vicidial_agent_disable',allow_sipsak_messages='$allow_sipsak_messages',admin_home_url='$admin_home_url',enable_agc_xfer_log='$enable_agc_xfer_log',timeclock_end_of_day='$timeclock_end_of_day',vdc_header_date_format='$vdc_header_date_format',vdc_customer_date_format='$vdc_customer_date_format',vdc_header_phone_format='$vdc_header_phone_format',vdc_agent_api_active='$vdc_agent_api_active',enable_vtiger_integration='$enable_vtiger_integration',vtiger_server_ip='$vtiger_server_ip',vtiger_dbname='$vtiger_dbname',vtiger_login='$vtiger_login',vtiger_pass='$vtiger_pass',vtiger_url='$vtiger_url',qc_features_active='$qc_features_active',outbound_autodial_active='$outbound_autodial_active',outbound_calls_per_second='$outbound_calls_per_second',agentonly_callback_campaign_lock='$agentonly_callback_campaign_lock',sounds_central_control_active='$sounds_central_control_active',sounds_web_server='$sounds_web_server',sounds_web_directory='$sounds_web_directory',active_voicemail_server='$active_voicemail_server',auto_dial_limit='$auto_dial_limit',user_territories_active='$user_territories_active',allow_custom_dialplan='$allow_custom_dialplan';"; + $stmt="UPDATE system_settings set use_non_latin='$use_non_latin',webroot_writable='$webroot_writable',enable_queuemetrics_logging='$enable_queuemetrics_logging',queuemetrics_server_ip='$queuemetrics_server_ip',queuemetrics_dbname='$queuemetrics_dbname',queuemetrics_login='$queuemetrics_login',queuemetrics_pass='$queuemetrics_pass',queuemetrics_url='$queuemetrics_url',queuemetrics_log_id='$queuemetrics_log_id',queuemetrics_eq_prepend='$queuemetrics_eq_prepend',vicidial_agent_disable='$vicidial_agent_disable',allow_sipsak_messages='$allow_sipsak_messages',admin_home_url='$admin_home_url',enable_agc_xfer_log='$enable_agc_xfer_log',timeclock_end_of_day='$timeclock_end_of_day',vdc_header_date_format='$vdc_header_date_format',vdc_customer_date_format='$vdc_customer_date_format',vdc_header_phone_format='$vdc_header_phone_format',vdc_agent_api_active='$vdc_agent_api_active',enable_vtiger_integration='$enable_vtiger_integration',vtiger_server_ip='$vtiger_server_ip',vtiger_dbname='$vtiger_dbname',vtiger_login='$vtiger_login',vtiger_pass='$vtiger_pass',vtiger_url='$vtiger_url',qc_features_active='$qc_features_active',outbound_autodial_active='$outbound_autodial_active',outbound_calls_per_second='$outbound_calls_per_second',enable_tts_integration='$enable_tts_integration',agentonly_callback_campaign_lock='$agentonly_callback_campaign_lock',sounds_central_control_active='$sounds_central_control_active',sounds_web_server='$sounds_web_server',sounds_web_directory='$sounds_web_directory',active_voicemail_server='$active_voicemail_server',auto_dial_limit='$auto_dial_limit',user_territories_active='$user_territories_active',allow_custom_dialplan='$allow_custom_dialplan';"; $rslt=mysql_query($stmt, $link); ### LOG INSERTION Admin Log Table ### @@ -12973,6 +13130,28 @@ if ($ADD==541111111111) } +###################### +# ADD=551111111111 confirmation before deletion of tts record +###################### + +if ($ADD==551111111111) + { + echo ""; + + if (strlen($tts_id) < 2) + { + echo "
TTS ENTRY NOT DELETED - Please go back and look at the data you entered\n"; + echo "
TTS ID be at least 2 characters in length\n"; + } + else + { + echo "
TTS ENTRY DELETION CONFIRMATION: $tts_id - $tts_name\n"; + echo "

Click here to delete tts entry $tts_id - $tts_name


\n"; + } + $ADD='351111111111'; # go to tts entry modification below + } + + ###################### # ADD=5111111111111 confirmation before deletion of conference record ###################### @@ -14085,6 +14264,39 @@ if ($ADD==641111111111) } +###################### +# ADD=651111111111 delete tts record +###################### + +if ($ADD==651111111111) + { + echo ""; + + if ( (strlen($tts_id) < 2) or ($CoNfIrM != 'YES') ) + { + echo "
TTS ENTRY NOT DELETED - Please go back and look at the data you entered\n"; + echo "
TTS ID be at least 2 characters in length\n"; + } + else + { + $stmt="DELETE from vicidial_tts_prompts where tts_id='$tts_id';"; + $rslt=mysql_query($stmt, $link); + + ### LOG INSERTION Admin Log Table ### + $SQL_log = "$stmt|"; + $SQL_log = ereg_replace(';','',$SQL_log); + $SQL_log = addslashes($SQL_log); + $stmt="INSERT INTO vicidial_admin_log set event_date='$SQLdate', user='$PHP_AUTH_USER', ip_address='$ip', event_section='TTS', event_type='DELETE', record_id='$tts_id', event_code='ADMIN DELETE TTS', event_sql=\"$SQL_log\", event_notes='';"; + if ($DB) {echo "|$stmt|\n";} + $rslt=mysql_query($stmt, $link); + + echo "
CARRIER DELETION COMPLETED: $carrier_id\n"; + echo "

\n"; + } + $ADD='150000000000'; # go to tts entry list + } + + ###################### # ADD=6111111111111 delete conference record ###################### @@ -19849,6 +20061,57 @@ if ($ADD==341111111111) } +###################### +# ADD=351111111111 modify tts record in the system +###################### + +if ($ADD==351111111111) +{ + if ($LOGast_admin_access==1) + { + echo "
\n"; + echo ""; + + $stmt="SELECT tts_id,tts_name,active,tts_text from vicidial_tts_prompts where tts_id='$tts_id';"; + $rslt=mysql_query($stmt, $link); + $row=mysql_fetch_row($rslt); + $tts_id = $row[0]; + $tts_name = $row[1]; + $active = $row[2]; + $tts_text = $row[3]; + + echo "
MODIFY A TTS RECORD: $row[0]\n"; + echo "\n"; + echo "\n"; + + echo "
\n"; + echo "\n"; + echo "\n"; + echo "\n"; + + echo "\n"; + + echo "\n"; + echo "
TTS ID: $tts_id
TTS Name: $NWB#vicidial_tts_prompts-tts_name$NWE
Active:
TTS Text: $NWB#vicidial_tts_prompts-tts_text$NWE
\n"; + + echo "
\n"; + if ($LOGast_delete_phones > 0) + { + echo "

DELETE THIS TTS ENTRY\n"; + } + if ($LOGuser_level >= 9) + { + echo "

Click here to see Admin chages to this TTS entry
\n"; + } + } + else + { + echo "You do not have permission to view this page\n"; + exit; + } +} + + ###################### # ADD=3111111111111 modify conference record in the system ###################### @@ -19953,7 +20216,7 @@ if ($ADD==311111111111111) echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; @@ -21670,6 +21936,50 @@ if ($ADD==140000000000) echo "
\n"; echo ""; - $stmt="SELECT version,install_date,use_non_latin,webroot_writable,enable_queuemetrics_logging,queuemetrics_server_ip,queuemetrics_dbname,queuemetrics_login,queuemetrics_pass,queuemetrics_url,queuemetrics_log_id,queuemetrics_eq_prepend,vicidial_agent_disable,allow_sipsak_messages,admin_home_url,enable_agc_xfer_log,db_schema_version,auto_user_add_value,timeclock_end_of_day,timeclock_last_reset_date,vdc_header_date_format,vdc_customer_date_format,vdc_header_phone_format,vdc_agent_api_active,qc_last_pull_time,enable_vtiger_integration,vtiger_server_ip,vtiger_dbname,vtiger_login,vtiger_pass,vtiger_url,qc_features_active,outbound_autodial_active,outbound_calls_per_second,agentonly_callback_campaign_lock,sounds_central_control_active,sounds_web_server,sounds_web_directory,active_voicemail_server,auto_dial_limit,user_territories_active,allow_custom_dialplan from system_settings;"; + $stmt="SELECT version,install_date,use_non_latin,webroot_writable,enable_queuemetrics_logging,queuemetrics_server_ip,queuemetrics_dbname,queuemetrics_login,queuemetrics_pass,queuemetrics_url,queuemetrics_log_id,queuemetrics_eq_prepend,vicidial_agent_disable,allow_sipsak_messages,admin_home_url,enable_agc_xfer_log,db_schema_version,auto_user_add_value,timeclock_end_of_day,timeclock_last_reset_date,vdc_header_date_format,vdc_customer_date_format,vdc_header_phone_format,vdc_agent_api_active,qc_last_pull_time,enable_vtiger_integration,vtiger_server_ip,vtiger_dbname,vtiger_login,vtiger_pass,vtiger_url,qc_features_active,outbound_autodial_active,outbound_calls_per_second,enable_tts_integration,agentonly_callback_campaign_lock,sounds_central_control_active,sounds_web_server,sounds_web_directory,active_voicemail_server,auto_dial_limit,user_territories_active,allow_custom_dialplan from system_settings;"; $rslt=mysql_query($stmt, $link); $row=mysql_fetch_row($rslt); $version = $row[0]; @@ -19990,14 +20253,15 @@ if ($ADD==311111111111111) $qc_features_active = $row[31]; $outbound_autodial_active = $row[32]; $outbound_calls_per_second = $row[33]; - $agentonly_callback_campaign_lock = $row[34]; - $sounds_central_control_active = $row[35]; - $sounds_web_server = $row[36]; - $sounds_web_directory = $row[37]; - $active_voicemail_server = $row[38]; - $auto_dial_limit = $row[39]; - $user_territories_active = $row[40]; - $allow_custom_dialplan = $row[41]; + $enable_tts_integration = $row[34]; + $agentonly_callback_campaign_lock = $row[35]; + $sounds_central_control_active = $row[36]; + $sounds_web_server = $row[37]; + $sounds_web_directory = $row[38]; + $active_voicemail_server = $row[39]; + $auto_dial_limit = $row[40]; + $user_territories_active = $row[41]; + $allow_custom_dialplan = $row[42]; echo "
MODIFY VICIDIAL SYSTEM SETTINGS\n"; echo "\n"; @@ -20139,6 +20403,8 @@ if ($ADD==311111111111111) echo "
User Territories Active: $NWB#settings-user_territories_active$NWE
Enable TTS Integration: $NWB#settings-enable_tts_integration$NWE
QC Features Active: $NWB#settings-qc_features_active$NWE
QC Last Pull Time: $qc_last_pull_time
\n"; } +###################### +# ADD=150000000000 display all tts entries +###################### +if ($ADD==150000000000) + { + echo "> @@ -1135,6 +1139,13 @@ $admin_home_url_LU = $row[0]; SIZE=> Audio Store + 0) + { ?> + > + + @@ -1197,6 +1208,10 @@ $admin_home_url_LU = $row[0]; ?> > 1) and (strlen($admin_hh) > 1) ) { + ?> + > + 1) { ?> >
\n"; + echo ""; + + $stmt="SELECT tts_id,tts_name,active,tts_text from vicidial_tts_prompts order by tts_id"; + $rslt=mysql_query($stmt, $link); + $tts_to_print = mysql_num_rows($rslt); + + echo "
TEXT-TO-SPEECH(TTS) LISTINGS:\n"; + echo "
\n"; + echo ""; + echo ""; + echo ""; + echo ""; + echo ""; + echo "\n"; + + $o=0; + while ($tts_to_print > $o) + { + $row=mysql_fetch_row($rslt); + $row[3]=ereg_replace(";|<|>","",$row[3]); + while(strlen($row[3]) > 50) {$row[3] = substr("$row[3]", 0, -1);} + if(strlen($row[3]) > 47) {$row[3] = "$row[3]...";} + + if (eregi("1$|3$|5$|7$|9$", $o)) + {$bgcolor='bgcolor="#B9CBFD"';} + else + {$bgcolor='bgcolor="#9BB9FB"';} + echo ""; + echo ""; + echo ""; + echo ""; + echo "\n"; + $o++; + } + + echo "
TTS IDTTS NameActiveTTS TextMODIFY
$row[0]$row[1]$row[2]$row[3]MODIFY
\n"; + } + ###################### # ADD=1000000000000 display all conferences ###################### diff --git a/agc_2-X/trunk/www/vicidial/admin_header.php b/agc_2-X/trunk/www/vicidial/admin_header.php index 2a58476a..2e3031c9 100644 --- a/agc_2-X/trunk/www/vicidial/admin_header.php +++ b/agc_2-X/trunk/www/vicidial/admin_header.php @@ -13,6 +13,7 @@ # 90612-0852 - Changed relative links # 90635-0943 - Added javascript for dynamic menus in In-Groups # 90627-0548 - Added no-agent-no-queue options +# 90628-1016 - Added Text-to-speech options # @@ -865,10 +866,11 @@ echo "\n"; echo "\n"; echo "\n"; -$stmt="SELECT admin_home_url from system_settings;"; +$stmt="SELECT admin_home_url,enable_tts_integration from system_settings;"; $rslt=mysql_query($stmt, $link); $row=mysql_fetch_row($rslt); $admin_home_url_LU = $row[0]; +$SSenable_tts_integration = $row[1]; ?>
@@ -1107,6 +1109,8 @@ $admin_home_url_LU = $row[0]; else {$status_sh=''; $status_fc='BLACK';} if ($sh=='audio') {$audio_sh="bgcolor=\"$audio_color\""; $audio_fc="$audio_font";} # pink else {$audio_sh=''; $audio_fc='BLACK';} + if ($sh=='tts') {$tts_sh="bgcolor=\"$tts_color\""; $tts_fc="$tts_font";} # pink + else {$tts_sh=''; $tts_fc='BLACK';} ?>
>   + SIZE=> Text To Speech
  > Show Carriers   |   > Add A New Carrier
  > Show TTS Entries   |   > Add A New TTS Entry
  > System Settings