Correzione MI3441: ora la discriminazione del periodo di liquidazione
tine conto anche dell'anno. git-svn-id: svn://10.65.10.50/trunk@3206 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
bbef7b6e4d
commit
e84654a9cc
@ -76,11 +76,12 @@ int TLiquidazione_app::next_trim(int x)
|
|||||||
bool TLiquidazione_app::is_in_liq_period(TDate& d)
|
bool TLiquidazione_app::is_in_liq_period(TDate& d)
|
||||||
{
|
{
|
||||||
bool ok = FALSE;
|
bool ok = FALSE;
|
||||||
if (_freqviva == "M") ok = d.month() == _month;
|
const int y = atoi(_year);
|
||||||
|
if (_freqviva == "M") ok = d.month() == _month && d.year() == y;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
int m = liq_month(_month);
|
int m = liq_month(_month);
|
||||||
ok = d.month() > m - 3 && d.month() <= m;
|
ok = d.month() > m - 3 && d.month() <= m && d.year() == y;
|
||||||
}
|
}
|
||||||
return ok;
|
return ok;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user