Changeset 65

Show
Ignore:
Timestamp:
11/29/07 20:38:27 (1 year ago)
Author:
root
Message:

Add support for channel in voicemailext, so you can use it to launch a macro via local when double clicking on the mailbox icon

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/ming-source/operator_panel.pl

    r62 r65  
    1009710097                                origen_number = origen; 
    1009810098                        } 
    10099                         //logea("Origen "+origen_number); 
    10100                         //logea("Destino "+destino); 
    10101                         //logea("Restrict "+_global.restrict); 
     10099                        logea("Origen "+origen_number); 
     10100                        logea("Destino "+destino); 
     10101                        logea("Restrict "+_global.restrict); 
    1010210102                        if(_global.restrict != undefined) { 
    10103                             if (_global.restrict == origen_number ) { 
     10103                            if (_global.restrict == origen_number || _global.restrict == destino ) { 
    1010410104                                    logea("Authorized envia_comando"); 
    1010510105                            } else { 
  • trunk/op_server.pl

    r64 r65  
    75377537            } 
    75387538            elsif ( $accion =~ /^voicemail/ ) { 
    7539                 my $vext     = ""; 
    7540                 my $vcontext = ""; 
     7539                my $vext       = ""; 
     7540                my $vmext      = ""; 
     7541                my $vcontext   = ""; 
     7542                my $orichannel = ""; 
    75417543 
    75427544                if ( defined( $config->{$panelcontext}{voicemail_extension} ) ) { 
    75437545                    my $voicemailext = $config->{$panelcontext}{voicemail_extension}; 
    7544                     ( $vext, $vcontext ) = split( /\@/, $voicemailext ); 
     7546                    ( $vmext, $orichannel ) = split( /\^/, $voicemailext ); 
     7547                    ( $vext, $vcontext ) = split( /\@/, $vmext ); 
    75457548                } 
    75467549                else { 
     
    75487551                    $tab = substr( $tab, 0, -1 ) if DEBUG; 
    75497552                    return; 
     7553                } 
     7554 
     7555                if (!defined($orichannel)) { 
     7556                                $orichannel = $origin_channel; 
    75507557                } 
    75517558 
     
    75587565 
    75597566                $comando = "Action: Originate\r\n"; 
    7560                 $comando .= "Channel: $origin_channel\r\n"; 
     7567                $comando .= "Channel: $orichannel\r\n"; 
    75617568                $comando .= "Callerid: $vclid <$vclid>\r\n"; 
    75627569                $comando .= "Async: True\r\n";