'Adição de multa itau feat bug#AL-3283' (!106) from AL-3283 into master
Reviewed-on: adm/ModelWeb#106 Reviewed-by: Valdir Cordeiro <valdir.cordeiro@totvs.com.br>master
commit
872895eb8b
4
pom.xml
4
pom.xml
|
@ -3,7 +3,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>br.com.rjconsultores</groupId>
|
||||
<artifactId>ModelWeb</artifactId>
|
||||
<version>1.18.0</version>
|
||||
<version>1.19.0</version>
|
||||
|
||||
<distributionManagement>
|
||||
<repository>
|
||||
|
@ -176,7 +176,7 @@
|
|||
<dependency>
|
||||
<groupId>br.com.rjconsultores</groupId>
|
||||
<artifactId>GeneradorBoletosCNAB</artifactId>
|
||||
<version>1.1.2</version>
|
||||
<version>1.2.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
|
|
|
@ -27,6 +27,7 @@ import org.springframework.stereotype.Repository;
|
|||
import com.rjconsultores.ventaboletos.ArquivoRemessa;
|
||||
import com.rjconsultores.ventaboletos.ArquivoRemessaItem;
|
||||
import com.rjconsultores.ventaboletos.ArquivoRemessaItemInteface;
|
||||
import com.rjconsultores.ventaboletos.blocos.DetalheMulta;
|
||||
import com.rjconsultores.ventaboletos.blocos.DetalheObrigatorio;
|
||||
import com.rjconsultores.ventaboletos.blocos.DetalheRetorno;
|
||||
import com.rjconsultores.ventaboletos.blocos.RodapeRemessaPadrao;
|
||||
|
@ -70,6 +71,7 @@ import com.rjconsultores.ventaboletos.enuns.TipoInscricaoPagador;
|
|||
import com.rjconsultores.ventaboletos.exception.ValidacaoRemessaException;
|
||||
import com.rjconsultores.ventaboletos.utilerias.ApplicationProperties;
|
||||
import com.rjconsultores.ventaboletos.utilerias.CustomEnum;
|
||||
import com.rjconsultores.ventaboletos.utilerias.DateUtil;
|
||||
|
||||
@Repository("remessaCNABBancosDAO")
|
||||
@SuppressWarnings({"unchecked"})
|
||||
|
@ -691,7 +693,9 @@ public class RemessaCNABBancosHibernateDAO extends GenericHibernateDAO<Fechament
|
|||
sb.append("pl.NOMBPLAZA AS \"bairroPagador\", ");
|
||||
sb.append("pv.CODPOSTAL AS \"cepPagador\", ");
|
||||
sb.append("ci.NOMBCIUDAD AS \"cidadePagador\", ");
|
||||
sb.append("es.cveestado AS \"estadoPagador\" ");
|
||||
sb.append("es.cveestado AS \"estadoPagador\", ");
|
||||
sb.append("nvl(fb.porc_mora, 0) AS \"porcentagemMora\", ");
|
||||
sb.append("nvl(fb.porc_multa, 0) AS \"porcentagemMulta\" ");
|
||||
writeFROMClause(sb, dataDe != null && dataAte != null, reenviar);
|
||||
|
||||
Query query = getSession().createSQLQuery(sb.toString());
|
||||
|
@ -762,16 +766,27 @@ public class RemessaCNABBancosHibernateDAO extends GenericHibernateDAO<Fechament
|
|||
detalhe.setDataDesconto(null);
|
||||
detalhe.setIOF_Devido(BigDecimal.ZERO);
|
||||
detalhe.setNomeSacado(tupla[21].toString());
|
||||
detalhe.setTipoInscricaoSacado(TipoInscricaoPagador.CNPJ);
|
||||
detalhe.setDataDeMora(null);
|
||||
detalhe.setTipoInscricaoSacado(TipoInscricaoPagador.CNPJ);
|
||||
detalhe.setPrazo(00);
|
||||
detalhe.setNumeroSequencialRegistro(++contador);
|
||||
detalhe.setSacadorAvalista(tupla[21].toString());
|
||||
|
||||
try{
|
||||
detalhe.setJurosDeMora(new BigDecimal(tupla[16].toString().replace(",", ".")));
|
||||
DetalheMulta multa = new DetalheMulta();
|
||||
multa.setCodigoMulta("2");
|
||||
multa.setDataMulta(DateUtil.somarDias((Date) tupla[10], 1));
|
||||
multa.setPercentualMulta(new BigDecimal(tupla[28].toString().replace(",", ".")));
|
||||
multa.setNumeroSequencial(++contador);
|
||||
detalhe.setDetalheMulta(multa);
|
||||
}catch(Exception e){
|
||||
}
|
||||
|
||||
try{
|
||||
detalhe.setJurosDeMora(new BigDecimal(tupla[27].toString().replace(",", ".")));
|
||||
detalhe.setDataDeMora(DateUtil.somarDias((Date) tupla[10], 1));
|
||||
}catch(Exception e){
|
||||
detalhe.setJurosDeMora(BigDecimal.ZERO);
|
||||
detalhe.setDataDeMora(null);
|
||||
}
|
||||
|
||||
try{
|
||||
|
|
Loading…
Reference in New Issue