implemented queue for biding - highest bid is first in queue

This commit is contained in:
Your Name
2020-12-12 19:14:56 +00:00
parent d193a2ff9e
commit a02f02e99b
2 changed files with 17 additions and 8 deletions

View File

@@ -732,24 +732,24 @@ exten => _X.,n,Return()
[from-eventphone]
exten => s,1,Answer()
same => n,Wait(1)
same => n,Playback(hello)
same => n(start),Read(input,demo-enterkeywords,1,,1,7) ; play sample, ask for 1 number into input, max 1 attempts, 7 second timeout
same => n,GotoIf($[ "${input}" == "1" ]?record-bid,s,1)
same => n,GotoIf($[ "${input}" == "2" ]?take-question,s,1)
same => n(start),Background(/etc/asterisk/media/playback/start,m)
same => n,Goto(start)
exten => 1,1,Goto(record-bid,s,1)
exten => 2,1,Goto(take-question,s,1)
[record-bid]
exten => s,1,Playback(something-terribly-wrong)
same => n(start),Read(money,sorry-youre-having-problems,,,1,12)
exten => s,1,Noop()
same => n(start),Read(money,/etc/asterisk/media/playback/gebot-eingeben,,,1,12)
same => n,GotoIf($[ "${money}" == "" ]?start)
same => n,GotoIf($[ ${money} > 0 & ${money} < 10000 ]?:start)
same => n,Playback(you-entered)
same => n,SayNumber(${money})
same => n,Read(input,if-correct-press,1,,1,7)
same => n,Read(input,/etc/asterisk/media/playback/gebot-bestaetigen,1,,1,7)
same => n,GotoIf($[ "${input}" != "1" ]?start)
same => n,Set(FILE(/tmp/money.txt,,,al,u)=${money} ${CALLERID(num)})
same => n,Playback(queue-thankyou)
same => n,Playback(vm-goodbye)
same => n,Set(QUEUE_PRIO=${money})
same => n,Queue(auction)
same => n,Hangup()
[take-question]