Atualizando financial_movements_save.php

This commit is contained in:
Kenio 2025-08-20 10:47:42 -03:00
parent 4614615770
commit a5707f9101

View file

@ -67,8 +67,8 @@ try{
/** Carrega o resultado da consulta */
$response = $ApiSicoob->getResponseObject();
/** Pega o total de históricos */
$total = count($response->resultado->listaHistorico)-1;
// /** Pega o total de históricos */
// $total = count($response->resultado->listaHistorico)-1;
for($i=0; $i<count($response->resultado->listaHistorico); $i++){
@ -76,15 +76,15 @@ try{
if($response->resultado->listaHistorico[$i]->tipoHistorico == 4){
/** Verifica se é uma tarifa de entrada */
if( strstr($response->resultado->listaHistorico[$total]->descricaoHistorico, 'TAR. ENTRADA') ){
if( strstr($response->resultado->listaHistorico[$i]->descricaoHistorico, 'TAR. ENTRADA') ){
echo $movement_value_registration_tariff = $Main->MoeadDB(str_replace('R$', '', strstr($response->resultado->listaHistorico[$total]->descricaoHistorico, 'R$')));
echo $movement_value_registration_tariff = $Main->MoeadDB(str_replace('R$', '', strstr($response->resultado->listaHistorico[$i]->descricaoHistorico, 'R$')));
}
/** Verifica se é uma tarifa de liquidação */
if( strstr($response->resultado->listaHistorico[$total]->descricaoHistorico, 'TAR. LIQUIDAÇÃO') ){
if( strstr($response->resultado->listaHistorico[$i]->descricaoHistorico, 'TAR. LIQUIDAÇÃO') ){
echo $movement_value_settlement_tariff = $Main->MoeadDB(str_replace('R$', '', strstr($response->resultado->listaHistorico[$total]->descricaoHistorico, 'R$')));
echo $movement_value_settlement_tariff = $Main->MoeadDB(str_replace('R$', '', strstr($response->resultado->listaHistorico[$i]->descricaoHistorico, 'R$')));
}
}