Merge pull request 'fixes bug#AL-3278' (!275) from AL-3278 into master
Reviewed-on: adm/VentaBoletosAdm#275 Reviewed-by: Julio Heredia <julio@rjconsultores.com.br> Reviewed-by: aristides <aristides@rjconsultores.com.br>master 1.21.2
commit
5d542afb85
2
pom.xml
2
pom.xml
|
@ -4,7 +4,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>br.com.rjconsultores</groupId>
|
||||
<artifactId>ventaboletosadm</artifactId>
|
||||
<version>1.21.1</version>
|
||||
<version>1.21.2</version>
|
||||
<packaging>war</packaging>
|
||||
|
||||
<properties>
|
||||
|
|
|
@ -83,12 +83,12 @@ public class RelatorioQuadroDemonstrativoMovimentoPassageirosNovoLayout extends
|
|||
agrupar = true;
|
||||
if (ida == 0) {
|
||||
map.put("totalida", rset.getLong("totalida"));
|
||||
total = total.add(rset.getBigDecimal("totalReceita"));
|
||||
total = total.add(limpaNulo(rset.getBigDecimal("totalReceita")));
|
||||
map.put("totalReceita", total);
|
||||
}
|
||||
else {
|
||||
map.put("totalvolta", rset.getLong("totalvolta") + volta);
|
||||
total = total.add(rset.getBigDecimal("totalReceita"));
|
||||
total = total.add(limpaNulo(rset.getBigDecimal("totalReceita")));
|
||||
map.put("totalReceita", total);
|
||||
}
|
||||
|
||||
|
@ -219,4 +219,12 @@ public class RelatorioQuadroDemonstrativoMovimentoPassageirosNovoLayout extends
|
|||
return semelhancas;
|
||||
}
|
||||
|
||||
private BigDecimal limpaNulo( BigDecimal val ) {
|
||||
if( val == null ) {
|
||||
return BigDecimal.ZERO;
|
||||
}else {
|
||||
return val;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue