Changeset 10718

Show
Ignore:
Timestamp:
12/18/10 23:48:51 (3 years ago)
Author:
p_lindheimer
Message:

change FORCE_CONFIRM so setting it to anything not empty is treated as true re #4701

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • modules/branches/2.9/core/functions.inc.php

    r10715 r10718  
    19021902 
    19031903      $exten = '1'; 
    1904       $ext->add($context, $exten, '', new ext_gotoif('$["${FORCE_CONFIRM}" = "ENABLED"]', 'skip')); 
     1904      $ext->add($context, $exten, '', new ext_gotoif('$["${FORCE_CONFIRM}" != ""]', 'skip')); 
    19051905      $ext->add($context, $exten, '', new ext_gotoif('$["${DB_EXISTS(RG/${ARG3}/${UNIQCHAN})}" = "0"]', 'toolate,1')); 
    19061906      $ext->add($context, $exten, '', new ext_dbdel('RG/${ARG3}/${UNIQCHAN}')); 
     
    19151915      $exten = '3'; 
    19161916      $ext->add($context, $exten, '', new ext_saydigits('${CALLCONFIRMCID}')); 
    1917       $ext->add($context, $exten, '', new ext_gotoif('$["${DB_EXISTS(RG/${ARG3}/${UNIQCHAN})}"="0" & "${FORCE_CONFIRM}"!="ENABLED"]', 'toolate,1','s,start')); 
     1917      $ext->add($context, $exten, '', new ext_gotoif('$["${DB_EXISTS(RG/${ARG3}/${UNIQCHAN})}"="0" & "${FORCE_CONFIRM}"=""]', 'toolate,1','s,start')); 
    19181918 
    19191919      $exten = 't'; 
    1920       $ext->add($context, $exten, '', new ext_gotoif('$["${DB_EXISTS(RG/${ARG3}/${UNIQCHAN})}"="0" & "${FORCE_CONFIRM}"!="ENABLED"]', 'toolate,1')); 
     1920      $ext->add($context, $exten, '', new ext_gotoif('$["${DB_EXISTS(RG/${ARG3}/${UNIQCHAN})}"="0" & "${FORCE_CONFIRM}"=""]', 'toolate,1')); 
    19211921      $ext->add($context, $exten, '', new ext_setvar('LOOPCOUNT','$[ ${LOOPCOUNT} + 1 ]')); 
    19221922      $ext->add($context, $exten, '', new ext_gotoif('$[ ${LOOPCOUNT} < 5 ]', 's,start','noanswer,1')); 
     
    19281928        $ext->add($context, $exten, '', new ext_background('invalid,m,${LANGUAGE},macro-confirm')); 
    19291929      } 
    1930       $ext->add($context, $exten, '', new ext_gotoif('$["${DB_EXISTS(RG/${ARG3}/${UNIQCHAN})}"="0" & "${FORCE_CONFIRM}"!="ENABLED"]', 'toolate,1')); 
     1930      $ext->add($context, $exten, '', new ext_gotoif('$["${DB_EXISTS(RG/${ARG3}/${UNIQCHAN})}"="0" & "${FORCE_CONFIRM}"=""]', 'toolate,1')); 
    19311931      $ext->add($context, $exten, '', new ext_setvar('LOOPCOUNT','$[ ${LOOPCOUNT} + 1 ]')); 
    19321932      $ext->add($context, $exten, '', new ext_gotoif('$[ ${LOOPCOUNT} < 5 ]', 's,start','noanswer,1')); 
     
    20432043      // But add the macro-setmusic if we don't want music on this outbound call 
    20442044      // if FORCE_CONFIRM then that macro will set any necessary MOHCLASS, and we will also call the confirm macro 
    2045       $ext->add($context, $exten, '', new ext_execif('$["${MOHCLASS}"!="default" & "${MOHCLASS}"!="" & "${FORCE_CONFIRM}"!="ENABLED" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(setmusic^${MOHCLASS})${DIAL_TRUNK_OPTIONS}')); 
    2046       $ext->add($context, $exten, '', new ext_execif('$["${FORCE_CONFIRM}"="ENABLED" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(confirm)${DIAL_TRUNK_OPTIONS}')); 
     2045      $ext->add($context, $exten, '', new ext_execif('$["${MOHCLASS}"!="default" & "${MOHCLASS}"!="" & "${FORCE_CONFIRM}"="" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(setmusic^${MOHCLASS})${DIAL_TRUNK_OPTIONS}')); 
     2046      $ext->add($context, $exten, '', new ext_execif('$["${FORCE_CONFIRM}"!="" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(confirm)${DIAL_TRUNK_OPTIONS}')); 
    20472047     
    20482048      // This macro call will always be blank and is provided as a hook for customization required prior to making a call 
     
    21762176      // Back to normal processing, whether intracompany or not. 
    21772177      // But add the macro-setmusic if we don't want music on this outbound call 
    2178       $ext->add($context, $exten, '', new ext_execif('$["${MOHCLASS}"!="default" & "${MOHCLASS}"!="" & "${FORCE_CONFIRM}"!="ENABLED" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(setmusic^${MOHCLASS})${DIAL_TRUNK_OPTIONS}')); 
    2179       $ext->add($context, $exten, '', new ext_execif('$["${FORCE_CONFIRM}"="ENABLED" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(confirm)${DIAL_TRUNK_OPTIONS}')); 
     2178      $ext->add($context, $exten, '', new ext_execif('$["${MOHCLASS}"!="default" & "${MOHCLASS}"!="" & "${FORCE_CONFIRM}"="" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(setmusic^${MOHCLASS})${DIAL_TRUNK_OPTIONS}')); 
     2179      $ext->add($context, $exten, '', new ext_execif('$["${FORCE_CONFIRM}"!="" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(confirm)${DIAL_TRUNK_OPTIONS}')); 
    21802180     
    21812181      // This macro call will always be blank and is provided as a hook for customization required prior to making a call 
     
    23512351      // Loop through them trying them in order. 
    23522352      $ext->add($context, $exten, 'dialloop', new ext_gotoif('$["foo${DIALARR}"="foo"]', 's-${DIALSTATUS},1')); 
    2353       $ext->add($context, $exten, '', new ext_execif('$["${MOHCLASS}"!="default" & "${MOHCLASS}"!="" & "${FORCE_CONFIRM}"!="ENABLED" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(setmusic^${MOHCLASS})${DIAL_TRUNK_OPTIONS}')); 
    2354       $ext->add($context, $exten, '', new ext_execif('$["${FORCE_CONFIRM}"="ENABLED" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(confirm)${DIAL_TRUNK_OPTIONS}')); 
     2353      $ext->add($context, $exten, '', new ext_execif('$["${MOHCLASS}"!="default" & "${MOHCLASS}"!="" & "${FORCE_CONFIRM}"="" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(setmusic^${MOHCLASS})${DIAL_TRUNK_OPTIONS}')); 
     2354      $ext->add($context, $exten, '', new ext_execif('$["${FORCE_CONFIRM}"!="" ]', 'Set', 'DIAL_TRUNK_OPTIONS=M(confirm)${DIAL_TRUNK_OPTIONS}')); 
    23552355      $ext->add($context, $exten, '', new ext_set('TRYDIAL', '${CUT(DIALARR,%,1)}')); 
    23562356      $ext->add($context, $exten, '', new ext_set('DIALARR', '${CUT(DIALARR,%,2-)}')); 
  • modules/branches/2.9/findmefollow/functions.inc.php

    r10710 r10718  
    180180          // If grpconf == ENABLED call with confirmation ELSE call normal 
    181181          $ext->add($contextname, $grpnum, 'DIALGRP', new  
    182               ext_gotoif('$[("${DB(AMPUSER/'.$grpnum.'/followme/grpconf)}"="ENABLED") | ("FORCE_CONFIRM"="ENABLED") ]', 'doconfirm')); 
     182              ext_gotoif('$[("${DB(AMPUSER/'.$grpnum.'/followme/grpconf)}"="ENABLED") | ("FORCE_CONFIRM"!="") ]', 'doconfirm')); 
    183183 
    184184          // Normal call