Patch level : 10.0 580

Files correlati     :  mg1.exe
Ricompilazione Demo : [ ]
Commento            :

COrretto riporto clifogiac nell'anno successivo


git-svn-id: svn://10.65.10.50/trunk@19926 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
alex 2010-01-14 14:26:33 +00:00
parent eb46e8eb56
commit 2e6051c20c

View File

@ -946,13 +946,16 @@ HIDDEN bool rel_reset_clifogiac(const TRelation& rel, void* pJolly)
{
TRectype & rec = rel.curr();
TBalance_params & p = *((TBalance_params *)pJolly);
TRectype oldrec(rec);
TRectype newrec(rec);
oldrec.put(CLIFOGIAC_ANNOES, p.codesprec);
if (oldrec.read(rel.lfile()) != NOERR)
oldrec.zero();
reset_clifogiac(rec, oldrec);
return rec.rewrite(rel.lfile()) == NOERR;
newrec.put(CLIFOGIAC_ANNOES, p.codes);
if (newrec.read(rel.lfile()) != NOERR)
{
newrec = rec;
newrec.put(CLIFOGIAC_ANNOES, p.codes);
}
reset_clifogiac(newrec, rec);
return newrec.write_rewrite(rel.lfile()) == NOERR;
}
bool recalc_mov(const TRelation& rel, void* pJolly)
@ -990,7 +993,7 @@ bool rebuild_balances(int codes, const TTipo_valorizz tipo_valorizz,
msg.format(FR("Ricostruzione saldi esercizio %04d : azzeramento..."), codes);
anamag_cur.scan(reset_giac, (void *) &p, msg);
TString filter; filter << CLIFOGIAC_ANNOES << "==" << codes;
TString filter; filter << CLIFOGIAC_ANNOES << "==" << p.codesprec;
TCursor c(new TRelation(LF_CLIFOGIAC), filter);
msg.format(FR("Ricostruzione saldi esercizio %04d : azzeramento giacenze clienti..."), codes);