jhfgjsd
git-svn-id: svn://10.65.10.50/trunk@2709 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
b13b944326
commit
172900c7b3
@ -1098,7 +1098,27 @@ bool TRic_tab::occasionali(TString& ocfpi)
|
|||||||
ocfpi = chiave;
|
ocfpi = chiave;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
ric = FALSE;
|
{
|
||||||
|
_occas->setkey(1);
|
||||||
|
_occas->zero();
|
||||||
|
_occas->put("CFPI", ocfpi);
|
||||||
|
if (_occas->read() == NOERR)
|
||||||
|
{
|
||||||
|
TRecnotype rec = _occas->recno();
|
||||||
|
_occas->setkey(1);
|
||||||
|
_occas->zero();
|
||||||
|
for (_occas->first(); !_occas->eof(); _occas->next())
|
||||||
|
{
|
||||||
|
TString cfpi = _occas->get(OCC_CFPI);
|
||||||
|
if (cfpi.mid(0,3) == "RIC")
|
||||||
|
prog = atol(cfpi.mid(3,13));
|
||||||
|
}
|
||||||
|
prog++;
|
||||||
|
chiave = format("%3s%13ld", (const char*) "RIC", prog);
|
||||||
|
ocfpi = chiave;
|
||||||
|
_occas->readat(rec);
|
||||||
|
}
|
||||||
|
}
|
||||||
// }
|
// }
|
||||||
// else
|
// else
|
||||||
// {
|
// {
|
||||||
@ -1122,8 +1142,7 @@ bool TRic_tab::occasionali(TString& ocfpi)
|
|||||||
_occas->rewrite();
|
_occas->rewrite();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (ric)
|
_occas->put(OCC_CFPI, ocfpi);
|
||||||
_occas->put(OCC_CFPI, chiave);
|
|
||||||
_occas->write();
|
_occas->write();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -55,7 +55,7 @@ class TRic_ListaMov : public TPrintapp
|
|||||||
TString _record;
|
TString _record;
|
||||||
bool _mov_sez, _errore_grave, _esiste_conto, _is_exist, _risposta, _continua;
|
bool _mov_sez, _errore_grave, _esiste_conto, _is_exist, _risposta, _continua;
|
||||||
char _sdt, _sezione, _tipocf;
|
char _sdt, _sezione, _tipocf;
|
||||||
int _ae, _anno, _gruppo, _conto, _tipocr, _tipod, _tiporeg;
|
int _ae, _anno, _gruppo, _conto, _tipocr, _tipod, _tiporeg, _annoese;
|
||||||
int _gruppoc, _contoc, _gruppocr, _contocr, _annoiva;
|
int _gruppoc, _contoc, _gruppocr, _contocr, _annoiva;
|
||||||
TDate _datacomp, _datadoc, _datareg, _data74tr;
|
TDate _datacomp, _datadoc, _datareg, _data74tr;
|
||||||
real _importo, _impo, _impos, _tot_dare, _tot_avere, _tot_doc;
|
real _importo, _impo, _impos, _tot_dare, _tot_avere, _tot_doc;
|
||||||
@ -381,6 +381,9 @@ bool TRic_ListaMov::controlla_mov()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int pp;
|
||||||
|
_annoese = date2esc(_datacomp, &pp); // Esercizio in corso
|
||||||
|
|
||||||
if ( !TDate::isdate(_datacomp.string()) )
|
if ( !TDate::isdate(_datacomp.string()) )
|
||||||
{
|
{
|
||||||
_errore_grave = TRUE;
|
_errore_grave = TRUE;
|
||||||
@ -1149,6 +1152,8 @@ void TRic_ListaMov::aggiorna_mov()
|
|||||||
{
|
{
|
||||||
TLocalisamfile& mov = current_cursor()->file(LF_MOV);
|
TLocalisamfile& mov = current_cursor()->file(LF_MOV);
|
||||||
|
|
||||||
|
if (_anno == 0)
|
||||||
|
mov.put(MOV_ANNOES, _annoese);
|
||||||
mov.put(MOV_DATACOMP, _datacomp);
|
mov.put(MOV_DATACOMP, _datacomp);
|
||||||
mov.put(MOV_ANNOIVA, _annoiva);
|
mov.put(MOV_ANNOIVA, _annoiva);
|
||||||
mov.put(MOV_REG, _registro);
|
mov.put(MOV_REG, _registro);
|
||||||
@ -1165,7 +1170,9 @@ void TRic_ListaMov::aggiorna_rmov(char tipoc, char tipocc)
|
|||||||
{
|
{
|
||||||
TLocalisamfile& rmov = current_cursor()->file(LF_RMOV);
|
TLocalisamfile& rmov = current_cursor()->file(LF_RMOV);
|
||||||
|
|
||||||
// rmov.put(RMV_ANNOES, _annoese);
|
if (_anno == 0)
|
||||||
|
rmov.put(RMV_ANNOES, _annoese);
|
||||||
|
|
||||||
rmov.put(RMV_TIPOC, tipoc);
|
rmov.put(RMV_TIPOC, tipoc);
|
||||||
rmov.put(RMV_TIPOCC, tipocc);
|
rmov.put(RMV_TIPOCC, tipocc);
|
||||||
|
|
||||||
@ -1176,7 +1183,9 @@ void TRic_ListaMov::aggiorna_iva(char tipo)
|
|||||||
{
|
{
|
||||||
TLocalisamfile& riva = current_cursor()->file(LF_RMOVIVA);
|
TLocalisamfile& riva = current_cursor()->file(LF_RMOVIVA);
|
||||||
|
|
||||||
// riva.put(RMI_ANNOES, _annoese);
|
if (_anno == 0)
|
||||||
|
riva.put(RMI_ANNOES, _annoese);
|
||||||
|
|
||||||
if (_tipodoc == "NC" || _tipodoc == "ST")
|
if (_tipodoc == "NC" || _tipodoc == "ST")
|
||||||
{
|
{
|
||||||
_impo = _impo * -1;
|
_impo = _impo * -1;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user