Необходимо сделать запись в БД, в момент ответа оператора, как это лучше реализовать за что зацепиться ?
Данные с базы берет самописное П.О., которое делает запросы каждые 3 сек.
-= Info about application 'Queue' =-
[Synopsis]
Queue a call for a call queue.
......
[Syntax]
Queue(queuename[,options[,URL[,announceoverride[,timeout[,AGI[,macro[,gosub[,rule[,position]]]]]]]]])
[Arguments]
......
AGI
Will setup an AGI script to be executed on the calling party's channel
once they are connected to a queue member.
macro
Will run a macro on the calling party's channel once they are
connected to a queue member.
gosub
Will run a gosub on the calling party's channel once they are
connected to a queue member.
.....
[See Also]
Queue(), QueueLog(), AddQueueMember(), RemoveQueueMember(), PauseQueueMember(),
UnpauseQueueMember(), QUEUE_VARIABLES, QUEUE_MEMBER, QUEUE_MEMBER_COUNT,
QUEUE_EXISTS, QUEUE_WAITING_COUNT, QUEUE_MEMBER_LIST, QUEUE_MEMBER_PENALT
Y
Код: Выделить всё
exten => XXXXXX,n,SET(_FN=${CALLERID(dnid)})
exten => XXXXXX,n,SET(_CID=${CALLERID(num)})
exten => XXXXXX,n,SET(_Time=${STRFTIME(${EPOCH},,%Y%m%d-%H%M%S)})
exten => XXXXXX,n,SET(Time2=${STRFTIME(${EPOCH},,%Y%m%d%H%M%S)})
exten => XXXXXX,n,MYSQL(Connect connid localhost astr 3-------------f asteriskrlt)
exten => XXXXXX,n,MYSQL(Query resultid ${connid} INSERT INTO pbxlog (`id`, `logdate`, `abon`, `src`, `dst`, `line`, `group`, `status`) VALUES (NULL, ${Time2}, 0, ${CID}, 0, ${FN}, 0, 2))
exten => XXXXXX,n,MYSQL(Disconnect ${connid})