diff --git a/.classpath b/.classpath
index dd1648116..772e70ca1 100644
--- a/.classpath
+++ b/.classpath
@@ -89,7 +89,7 @@
-
+
diff --git a/src/com/rjconsultores/ventaboletos/dao/hibernate/FiscalHibernateDAO.java b/src/com/rjconsultores/ventaboletos/dao/hibernate/FiscalHibernateDAO.java
index 4967eb8de..3ca8c442b 100644
--- a/src/com/rjconsultores/ventaboletos/dao/hibernate/FiscalHibernateDAO.java
+++ b/src/com/rjconsultores/ventaboletos/dao/hibernate/FiscalHibernateDAO.java
@@ -1,5 +1,6 @@
package com.rjconsultores.ventaboletos.dao.hibernate;
+import java.math.BigDecimal;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
@@ -534,11 +535,18 @@ public class FiscalHibernateDAO extends GenericHibernateDAO impl
return list;
}
+ private boolean validaValorExiste(BigDecimal valor) {
+ if (valor.equals(BigDecimal.ZERO) || valor == null)
+ return Boolean.FALSE;
+ else
+ return Boolean.TRUE;
+ }
+
private List validaItensFiscais(ImportacionFiscalVO fiscal, String codProduto) {
- boolean temTarifa = fiscal.getValorTarifa() != null ? true : false;
- boolean temPedagio = fiscal.getValorPedagio() != null ? true : false;
- boolean temEmbarque = fiscal.getValorEmbarque() != null ? true : false;
+ boolean temTarifa = validaValorExiste(fiscal.getValorTarifa()) ? true : false;
+ boolean temPedagio = validaValorExiste(fiscal.getValorPedagio()) ? true : false;
+ boolean temEmbarque = validaValorExiste(fiscal.getValorEmbarque()) ? true : false;
boolean tarifaCriada = false;
boolean pedagioCriada = false;