diff --git a/src/cg/cg4301.cpp b/src/cg/cg4301.cpp index 9b869acc1..76c916007 100755 --- a/src/cg/cg4301.cpp +++ b/src/cg/cg4301.cpp @@ -4279,8 +4279,8 @@ void TLiquidazione_app::write_liq(int month, const char* codatts) // calcola nuovo prorata dal 1998 per ogni attivita' (miste: 1+2) if (_prorata_nd) { - rsd = _pla->get_real("R20") + num_amm; - rsn = _pla->get_real("R19"); + rsd = _pla->get_real("R20"); + rsn = _pla->get_real("R19") + num_amm; } else { diff --git a/src/cg/cg4304.cpp b/src/cg/cg4304.cpp index 3a3198288..51d425d96 100755 --- a/src/cg/cg4304.cpp +++ b/src/cg/cg4304.cpp @@ -1116,8 +1116,8 @@ void TLiquidazione_app::describe_pims(int month, const char* codatt, const bool if (_prorata_nd) { - rsd = _pla->get_real("R20") + num_amm; - rsn = _pla->get_real("R19"); + rsd = _pla->get_real("R20"); + rsn = _pla->get_real("R19") + num_amm; } else { @@ -1159,11 +1159,17 @@ void TLiquidazione_app::describe_pims(int month, const char* codatt, const bool round_imposta(num_amm); // segna flag prorata - if ((e1+e2+e3+e4) > ZERO) - { - dd->_f0 |= IS_PRORATA; - dd->_r18 = _pla->get_real("R18"); + if (_prorata_nd) + { + if (rsn != rsd) + dd->_f0 |= IS_PRORATA; } + else + if ((e1+e2+e3+e4) > ZERO) + { + dd->_f0 |= IS_PRORATA; + dd->_r18 = _pla->get_real("R18"); + } dd->_r0 = ris; dd->_r1 = e1; dd->_r2 = prorata; @@ -2804,8 +2810,9 @@ bool TLiquidazione_app::set_annual(_DescrItem& d) int row = get_maxrow()+1; if (row == 1) row = 4; - if ((d._r2 > ZERO) && (d._f0 & IS_PRORATA)) - { + // if ((d._r2 > ZERO) && (d._f0 & IS_PRORATA)) + if (d._f0 & IS_PRORATA) + { // non lo ha stampato prima se annuale, perche' Vladimiro il nefido pretende l'assurdo aggiornamento della perc. a quella nuova const int year_int = atoi(_year); @@ -2834,15 +2841,9 @@ bool TLiquidazione_app::set_annual(_DescrItem& d) if (_prorata_nd) { set_row(row++, FR(" - Numeratore pro-rata @69g%r"), &d._ra0); - set_row(row++, FR(" - cessioni esenti di beni ammortizzabili @69g%r"), &d._ra3); - const real tot = d._ra0 + d._ra3; + set_row(row++, FR(" - di cui cessioni esenti art.10 di beni ammortizzabili @69g%r"), &d._ra3); + const real diff = d._ra0 - d._ra3; - if (tot != ZERO) - { - set_row(row++, FR("@69g----------------")); - set_row(row++, FR("@6gTotale @69g%r"), &tot); - row++; - } set_row(row++, FR(" - Denominatore @69g%r"), &d._ra1); } else