Merge pull request 'fixes bug AL-2125' (#27) from AL-2125 into master

Reviewed-on: http://18.235.188.113:3000/adm/ModelWeb/pulls/27
Reviewed-by: Valdir Cordeiro <valdir.cordeiro@totvs.com.br>
Reviewed-by: Gleison da Cruz <gleison.cruz@totvs.com.br>
master
pinheiro 2023-02-03 12:50:47 +00:00
commit 671280488c
2 changed files with 6 additions and 1 deletions

View File

@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>br.com.rjconsultores</groupId>
<artifactId>ModelWeb</artifactId>
<version>1.0.29</version>
<version>1.0.30</version>
<distributionManagement>
<repository>
<id>rj-releases</id>

View File

@ -75,6 +75,11 @@ public class CategoriaDescuentoHibernateDAO
query.setParameter("categoriaId", categoriaId );
List<Boolean> retorno = (List<Boolean>)query.list();
//Caso não encontre categoria desconto com indnaoaplica deve se aplicar caso exista
if(retorno ==null || retorno.isEmpty()) {
return true;
}
return retorno !=null && !retorno.isEmpty() && Boolean.TRUE.equals(retorno.get(0)) ? Boolean.TRUE : Boolean.FALSE;
}