forked from Claudio/integracao
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
1.2 KiB
41 lines
1.2 KiB
<?php |
|
|
|
require_once 'TopSapp.php'; |
|
|
|
$registros = array( |
|
"id" => '', |
|
"reg_ura" => $ura, |
|
"reg_tronco" => $tronco, |
|
"reg_uniqueid" => $uid, |
|
"reg_id_metodo" => $idMetodo, |
|
"reg_uniqueid" => $uid, |
|
"reg_uniqueid_old" => $uidOld, |
|
"reg_fone" => $numero, |
|
"reg_status_exec" => '1', |
|
"reg_inicio" => date()); |
|
|
|
|
|
$tsap = new TopSapp(); |
|
$tsap->db()->setRegistros($registros); |
|
|
|
if (CONF_AUDIO_ERROR) { |
|
$tsap->db()->setIdAudioError(CONF_AUDIO_ERROR); |
|
} |
|
|
|
$retorno = $tsap->PendenciaFinanceira($tsap->agi()->get_variable('CODCLIENTE', true)); |
|
|
|
$itgcTela = array( |
|
"NOME" => $tsap->agi()->get_variable('NOME', true), |
|
"DOCUMENTO" => $tsap->agi()->get_variable('DOCUMENTO', true), |
|
"ENDERECO" => $tsap->agi()->get_variable('ENDERECO', true) |
|
); |
|
$tsap->integracaoAgente($itgcTela, array('NOME', 'DOCUMENTO', 'ENDERECO')); |
|
|
|
if (!$retorno) { |
|
$tsap->agi()->exec_goto($tsap->db()->getURA('INT_TP_SELECIONA_ATENDIMENTO')); |
|
} else { |
|
$tsap->agi()->exec_goto($tsap->db()->getAnuncio('INT_TP_PENDENCIA')); |
|
} |
|
|
|
$tsap->db()->atualizaIntegracao(); |
|
?>
|