- Limpa o cache de configuração de imposto a cada execução de relatório.

git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@30987 d1611594-4594-4d17-8e1d-87c2c4800839
master
bruno 2013-09-17 14:16:59 +00:00
parent 234acbf14c
commit 4dd10cbf71
3 changed files with 6 additions and 0 deletions

View File

@ -33,6 +33,7 @@ public class RelatorioReceitaDiariaAgencia extends Relatorio {
super(parametros, conexao);
CalculoImposto.limpaCache();
this.mapCacheConfigComissao = new HashMap<String, HashMap<String, Object>>();
this.setCustomDataSource(new ArrayDataSource(this) {

View File

@ -30,6 +30,7 @@ public class RelatorioTaxasLinha extends Relatorio {
*/
public RelatorioTaxasLinha(Map<String, Object> parametros, Connection conexao) throws Exception {
super(parametros, conexao);
CalculoImposto.limpaCache();
this.setCustomDataSource(new DataSource(this) {

View File

@ -20,6 +20,10 @@ import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement;
public class CalculoImposto {
static Map<String, HashMap<String, Object>> mapCacheConfigImposto = new HashMap<String, HashMap<String, Object>>();
public static void limpaCache(){
mapCacheConfigImposto = new HashMap<String, HashMap<String, Object>>();
}
public static BigDecimal getValorImpostoRelatorioReceitaDiaria(Connection conexao, Integer estadoId, Integer empresaId, String indInterestadual, BigDecimal tarifa, BigDecimal seguro, BigDecimal embarque, BigDecimal pedagio, BigDecimal bagagem, Boolean indBaseTarifa, Boolean indBaseSeguro, Boolean indBaseEmbarque, Boolean indBasePedagio, Boolean indBaseBagagem) throws Exception {
HashMap<String, Object> configImposto = new HashMap<String, Object>();