ATech Machine LIBRA-02 M Informazioni Techniche Pagina 557

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 734
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 556
; End of our loop
same => n,EndWhile()
same => n,Playback(silence/1)
same => n,Playback(vm-goodbye)
same => n,Hangup()
; If no results were found, execute this dialplan
exten => NoResults,1,Verbose(2,No results were found)
same => n,Playback(silence/1)
same => n,Playback(invalid)
same => n,Hangup()
Our example dialplan performs a lookup using the DUNDIQUERY() function and stores
the resulting ID value in the DUNDI_ID channel variable. Using the DUNDIRESULT() func-
tion and the getnum option, we store the total number of returned results in the Number
OfResults channel variable. We then set the ResultCounter channel variable to 1 as our
starting position in the loop.
Using GotoIf(), we check if the ${NumberOfResults} returned is less than one and, if so,
jump to the NoResults extension, where we Playback() “Invalid extension”. If at least
one extension is found, we continue on in the dialplan.
Using the While() application, we check if the ${ResultCounter} is less than or equal
to the value of ${NumberOfResults}. If that is true, we continue on in the dialplan, and
otherwise, we jump to the EndWhile() application.
For each iteration of our loop, the DUNDIRESULT() function is used to save the value at
position ${ResultCounter} to the thisResult channel variable. After storing the value,
we output it to the Asterisk console using the Verbose() application. Following that,
we increase the value of ResultCounter by one using the INC() function. Our loop test
is then done again within the While() loop, and the loop will continue while the value
of ${ResultCounter} is less than or equal to the value of ${Number OfResults}.
Using the same type of logic, we could check for values other than None and, if such a
value is found, ExitWhile() and continue in the dialplan to perform a call to the end-
point. The dialplan logic might look something like this:
[subLookupExtension]
exten => _1XXX,1,Verbose(2,Looking up results for extension ${EXTEN})
; Perform our lookup and save the resulting ID to DUNDI_ID
same => n,Set(DUNDI_ID=${DUNDIQUERY(${EXTEN},extensions,b)})
same => n,Set(NumberOfResults=${DUNDIRESULT(${DUNDI_ID},getnum)})
same => n,Set(ResultCounter=1)
; If no results are found, return 'None'
same => n,GotoIf($[${NumberOfResults} < 1]?NoResults,1)
; Perform our loop
same => n,While($[${ResultCounter} <= ${NumberOfResults}])
; Get the current value
Configuring Asterisk for Use with DUNDi | 521
Vedere la pagina 556
1 2 ... 552 553 554 555 556 557 558 559 560 561 562 ... 733 734

Commenti su questo manuale

Nessun commento

LG RH188H manuály

Uživatelské manuály a uživatelské příručky pro LCD televizory LG RH188H.
Poskytujeme 1 manuály pdf LG RH188H ke stažení zdarma podle typů dokumentů: Uživatelský manuál






Další produkty a příručky pro LCD televizory LG

Modely Typ Dokumentu
32LM3410 Uživatelský manuál   LG 32LM3400 Owner's manual, 87 stránky
65UK6470PLC Uživatelský manuál   LG 49UK6470PLC Owner's manual [ar] , 30 stránky
50PK760N Uživatelský manuál LG 50PK950,60PK950,50PK760N,50PK950N,60PK950N Användar manual [it] , 249 stránky
22LU4000 Uživatelský manuál   LG 22LU4000 Owner's manual, 194 stránky
43LW310C-ASIA Uživatelský manuál   LG 43LW310C Owner’s Manual, 40 stránky
RZ-20LA90 Uživatelský manuál LG RZ-20LA90 Användar manual [es] , 36 stránky
RT-14CA57M Uživatelský manuál   LG RT-14CA57M Руководство пользователя, 32 stránky
39LN5400-CA Uživatelský manuál   LG 32LN540B-CA,39LN5400-CA,42LN5400-CA,47LN5400-CA,55LN5400-CA 产品说明书, 39 stránky
50PF95 Uživatelský manuál LG 37LF75,37LY95,50PF95 Brukermanual, 116 stránky
65LA97000 Uživatelský manuál   LG 65LA9650 Owner's manual, 205 stránky
43UJ651V Uživatelský manuál   LG 43UJ651V Owner's manual, 36 stránky
CF-29H90NM Uživatelský manuál   LG CF-29H90NM Owner’s Manual [ur] , 25 stránky
OLED77W8PLA Uživatelský manuál   LG OLED65W8PLA,OLED77W8,OLED77W8PLA Руководство пользователя, 32 stránky
32LE4600 Uživatelský manuál   LG 55LE7500 Owner’s Manual, 242 stránky
42PB2RR Uživatelský manuál   LG 42PB2RR Owner's manual, 96 stránky
M2780D-PZ Uživatelský manuál   LG M2380DB-PZ Owner's manual, 158 stránky
M2794DP-PZ Uživatelský manuál LG M2794DP-PZ Användar manual, 111 stránky
32LY750H Uživatelský manuál   LG 32LY750H Owner’s Manual, 36 stránky
49LJ594V Uživatelský manuál   LG 49LJ594V Owner's manual, 38 stránky
50PY2R Uživatelský manuál   LG 50PY2R Owner's manual, 64 stránky