From: Thadeu Lima de Souza Cascardo Date: Sun, 10 Apr 2016 15:33:54 +0000 (-0300) Subject: Não totaliza rendimentos de dependentes como de titular. X-Git-Url: http://git.cascardo.eti.br/?p=cascardo%2Fdeclara.git;a=commitdiff_plain;h=cdf0b367d0d48286bccd4c873a3c2de4554b77d3 Não totaliza rendimentos de dependentes como de titular. Os rendimentos de dependentes são adicionados a novos totais de rendimentos de dependentes. Os rendimentos de titular excluem tais rendimentos. --- diff --git a/lib/isento.c b/lib/isento.c index 4e7540e..af3700e 100644 --- a/lib/isento.c +++ b/lib/isento.c @@ -34,22 +34,38 @@ static int isento_totais_update(struct declaracao *dec, struct isento *isento) case 82: r = totais_add(dec, "DOACOES", isento->valor); r += totais_add(dec, "ISENTOS", isento->valor); - r += totais_add(dec, "ISENTOSTIT", isento->valor); + if (isento->dependente) { + r += totais_add(dec, "ISENTOSDEP", isento->valor); + } else { + r += totais_add(dec, "ISENTOSTIT", isento->valor); + } break; case 96: r = totais_add(dec, "PLR", isento->valor); r += totais_add(dec, "EXCLUSIVOS", isento->valor); - r += totais_add(dec, "EXCLUSIVOSTIT", isento->valor); + if (isento->dependente) { + r += totais_add(dec, "EXCLUSIVOSDEP", isento->valor); + } else { + r += totais_add(dec, "EXCLUSIVOSTIT", isento->valor); + } break; case 98: r = totais_add(dec, "POUPANCA", isento->valor); r += totais_add(dec, "ISENTOS", isento->valor); - r += totais_add(dec, "ISENTOSTIT", isento->valor); + if (isento->dependente) { + r += totais_add(dec, "ISENTOSDEP", isento->valor); + } else { + r += totais_add(dec, "ISENTOSTIT", isento->valor); + } break; case 99: r = totais_add(dec, "APLICACOES", isento->valor); r += totais_add(dec, "EXCLUSIVOS", isento->valor); - r += totais_add(dec, "EXCLUSIVOSTIT", isento->valor); + if (isento->dependente) { + r += totais_add(dec, "EXCLUSIVOSDEP", isento->valor); + } else { + r += totais_add(dec, "EXCLUSIVOSTIT", isento->valor); + } break; } return r;