Correzione Mi2208 sul rimborso.

git-svn-id: svn://10.65.10.50/trunk@3960 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
angelo 1996-12-04 11:41:57 +00:00
parent f8c4c47c57
commit 5727cf5134

View File

@ -397,12 +397,6 @@ void TLiquidazione_app::recalc_ventilation(int month, const char* codatt)
//};
// defines per stabilire quale cazzo di metodo piace oggi alla prassi
// ------------------------------------------------------------------
// Considera tutti i mesi del trimestre fino a quello indicato
// se lasciato indefinito usa solo il mese passato
#define OGGI_GLI_TIRA_DI_USARE_TRE_MESI
_DescrItem* TLiquidazione_app::recalc_rimborso(int month, const char* codatts,
bool stliq)
{
@ -418,24 +412,24 @@ _DescrItem* TLiquidazione_app::recalc_rimborso(int month, const char* codatts,
const bool is_mens = _freqviva == "M";
real es_ni = 0.0;
real vol_aff = 0.0;;
real vol_aff = 0.0;
int m;
if (is_mens) m = month; // per le mensili considera solo il mese attuale
else m = next_trim(month)-2; // per le trimestrali considera i mesi del trimestre
if (month == 13) m = 1; // se annuale considera tutti i mesi
while ((tmpatt = atts.get()) != NULL)
{
att = tmpatt;
#ifdef OGGI_GLI_TIRA_DI_USARE_TRE_MESI
for (int m = (month == 13 ? 1 : (next_trim(month)-2)); m <= month; m++)
for (; m <= month; m++)
{
#else
int m = month;
#endif
if (!look_plm(m,att)) continue;
vol_aff += _pam->get_real("R1");
es_ni += _pum->get_real("R12");
#ifdef OGGI_GLI_TIRA_DI_USARE_TRE_MESI
}
#endif
}
// condizione 1