Changeset 1618
- Timestamp:
- 04/16/06 23:03:42 (7 years ago)
- Files:
-
- modules/branches/2.1/queues/functions.inc.php (modified) (2 diffs)
- modules/branches/2.1/queues/page.queues.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
modules/branches/2.1/queues/functions.inc.php
r1433 r1618 38 38 $ext->add('ext-queues', $exten, '', new ext_setcidname($q['prefix'].'${CALLERIDNAME}')); 39 39 $ext->add('ext-queues', $exten, '', new ext_setvar('MONITOR_FILENAME','/var/spool/asterisk/monitor/q${EXTEN}-${TIMESTAMP}-${UNIQUEID}')); 40 if(function_exists('recordings_list') && isset($q['joinannounce']) && $q['joinannounce'] != "") { 41 $filename = recordings_get($q['joinannounce']); 42 $ext->add('ext-queues', $exten, '', new ext_playback($filename['filename'])); 43 } else { 44 $filename['filename'] = null; 40 $joinannounce = (isset($q['joinannounce'])?$q['joinannounce']:''); 41 if($joinannounce != "") { 42 $ext->add('ext-queues', $exten, '', new ext_playback($joinannounce)); 45 43 } 46 if(function_exists('recordings_list')) 47 $filename = recordings_get($q['agentannounce']); 48 $ext->add('ext-queues', $exten, '', new ext_queue($exten,'t','',$filename['filename'],$q['maxwait'])); 44 $agentannounce = (isset($q['agentannounce'])?$q['agentannounce']:''); 45 $ext->add('ext-queues', $exten, '', new ext_queue($exten,'t','',$agentannounce,$q['maxwait'])); 49 46 50 47 // destination field in 'incoming' database is backwards from what ext_goto expects … … 129 126 $context = ''; 130 127 } else { 131 $arr = ivr_get_details($_REQUEST['announcemenu']);132 if( function_exists('recordings_list')) {133 $rec = recordings_get($arr['announcement']);128 $arr = (ivr_get_details($_REQUEST['announcemenu'])); 129 if( (isset($arr['announcement'])?$arr['announcement']:'') != '' ) { 130 $rec = $arr['announcement']; 134 131 $qthanku = $rec['filename']; 135 132 } else { modules/branches/2.1/queues/page.queues.php
r1334 r1618 184 184 if (isset($tresults[0])) { 185 185 foreach ($tresults as $tresult) { 186 echo '<option value="'.$tresult[ 0].'"'.($tresult[0] == $default ? ' SELECTED' : '').'>'.$tresult[1]."</option>\n";186 echo '<option value="'.$tresult[2].'"'.($tresult[2] == $default ? ' SELECTED' : '').'>'.$tresult[1]."</option>\n"; 187 187 } 188 188 } … … 191 191 </td> 192 192 </tr> 193 <?php } if(function_exists('music_list')) { //only include if music module is enabled?> 193 194 <?php } else { ?> 195 <tr> 196 <td><a href="#" class="info"><?php echo _("Agent Announcement:")?><span><?php echo _("Announcement played to the Agent prior to bridging in the caller <br><br> Example: \"the Following call is from the Sales Queue\" or \"This call is from the Technical Support Queue\".<br><br>You must install and enable the \"Systems Recordings\" Module to edit this option")?></span></a></td> 197 <td> 198 <?php 199 $default = (isset($agentannounce) ? $agentannounce : ''); 200 ?> 201 <input type="hidden" name="agentannounce" value="<?php echo $default; ?>"><?php echo ($default != '' ? $default : 'None'); ?> 202 </td> 203 </tr> 204 <?php } ?> 205 206 <?php if(function_exists('music_list')) { //only include if music module is enabled?> 194 207 <tr> 195 208 <td><a href="#" class="info"><?php echo _("Hold Music Category:")?><span><?php echo _("Music (or Commercial) played to the caller while they wait in line for an available agent.<br><br> This music is defined in the \"On Hold Music\" Menu to the left.")?></span></a></td> … … 426 439 if (isset($tresults[0])) { 427 440 foreach ($tresults as $tresult) { 428 echo '<option value="'.$tresult[ 0].'" '.($tresult[0] == $default ? 'SELECTED' : '').'>'.$tresult[1]."</option>\n";;441 echo '<option value="'.$tresult[2].'" '.($tresult[2] == $default ? 'SELECTED' : '').'>'.$tresult[1]."</option>\n";; 429 442 } 430 443 } … … 433 446 </td> 434 447 </tr> 448 <?php } else { ?> 449 <tr> 450 <td><a href="#" class="info"><?php echo _("Join Announcement:")?><span><?php echo _("Announcement played to callers once prior to joining the queue.<br><br>You must install and enable the \"Systems Recordings\" Module to edit this option")?></span></a></td> 451 <td> 452 <?php 453 $default = (isset($joinannounce) ? $joinannounce : ''); 454 ?> 455 <input type="hidden" name="joinannounce" value="<?php echo $default; ?>"><?php echo ($default != '' ? $default : 'None'); ?> 456 </td> 457 </tr> 435 458 <?php } ?> 436 437 459 <tr><td colspan="2"><br><h5><?php echo _("Fail Over Destination")?><hr></h5></td></tr> 438 460
