From 0c619f7d4f583ff6ff4694cb501e718769058475 Mon Sep 17 00:00:00 2001 From: villa Date: Mon, 9 Jan 1995 08:40:57 +0000 Subject: [PATCH] Aggiunto interesse trimestrale nelle deleghe git-svn-id: svn://10.65.10.50/trunk@833 c028cbd2-c16b-5b4b-a496-9718f37d4682 --- cg/cg4301.cpp | 12 +++++++++--- cg/cg4305.cpp | 6 ++++++ cg/cg5500d.uml | 2 +- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/cg/cg4301.cpp b/cg/cg4301.cpp index 3cc5882de..42837e192 100755 --- a/cg/cg4301.cpp +++ b/cg/cg4301.cpp @@ -846,9 +846,15 @@ void TLiquidazione_app::write_liq(int month, const char* codatts) risultato -= dt; ris_cred += dt; - _lim->put("R0",risultato); - _lim->put("R7",ris_cred); - _lim->put("R8",ris_deb); + _lim->put("R0",risultato); + + if (_freqviva == "T" && risultato.sign() > 0) + { + real interesse = interesse_trimestrale(_month); + real ivi = risultato * interesse / CENTO; ivi.ceil(ROUND_LIRA); + _lim->put("R7",ivi); + } + _lim->put("B0","X"); _lim->rewrite(); diff --git a/cg/cg4305.cpp b/cg/cg4305.cpp index e0c72cb8a..36cdd0985 100755 --- a/cg/cg4305.cpp +++ b/cg/cg4305.cpp @@ -116,24 +116,30 @@ bool TLiquidazione_app::extract_delega(int month) if (look_lim(month)) { real topay = _lim->get_real("R0"); + real intr = _lim->get_real("R7"); + if (topay.sign() <= 0) return TRUE; + if (_isannual) { if (look_del(12,7)) { topay -= _del->get_real("R0"); + intr -= _del->get_real("R1"); } } else { // importo rettifiche solo se non e' annuale topay += _lim->get_real("R5"); + intr += _del->get_real("R1"); } if (topay.sign() > 0) { look_del(month, _isannual ? 2 : 1, TRUE); _del->put("R0",topay); + _del->put("R1",intr); _del->rewrite(); } } diff --git a/cg/cg5500d.uml b/cg/cg5500d.uml index 5a448aee9..29f7f024b 100755 --- a/cg/cg5500d.uml +++ b/cg/cg5500d.uml @@ -2,7 +2,7 @@ TOOLBAR "" 0 20 0 2 -#include +#include "cg5500t.h" ENDPAGE