Corretto errore

git-svn-id: svn://10.65.10.50/trunk@1653 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
nik 1995-07-27 14:09:58 +00:00
parent abbe16b456
commit 3821817225
2 changed files with 191 additions and 186 deletions

View File

@ -65,6 +65,11 @@ bool TAgg_tconto::set_print(int)
return FALSE;
}
void TAgg_tconto::postclose_print()
{
message_box("Aggiornamento tipo conto completato");
}
bool TAgg_tconto::preprocess_page(int file,int counter)
{
if (counter) return TRUE;
@ -100,18 +105,17 @@ bool TAgg_tconto::preprocess_page(int file,int counter)
numreg, nrigimp, gruppo, conto, sottoconto);
return TRUE;
}
int t = tc.tipo_cr();
TString16 reg = cur->curr().get(MOV_REG);
int annoiva = cur->curr().get_int(MOV_ANNOIVA);
if (look_reg(reg, annoiva) == 1) //cerca il tipo del registro
{
int t = tc.tipo_cr();
if (t == 2 || t == 3 || t == 8)
{
const int tipo = look_reg(reg, annoiva); //cerca il tipo del registro
//aggiorno sul movimento iva il tipo costo/ricavo
//con quello letto dal piano conti
_rel->lfile(LF_RMOVIVA).put(RMI_TIPOCR, t);
if (tipo == 1 && (t == 2 || t == 3))
_rel->lfile(LF_RMOVIVA).put(RMI_TIPOCR, 4);
_rel->lfile(LF_RMOVIVA).rewrite();
}
}
}
else
{
set_row(1, "@4g%7ld@23g%3d@31g%3d@37g%3d@45g%6ld ** Conto inesistente **",

View File

@ -18,6 +18,7 @@ public:
virtual bool user_destroy();
virtual bool set_print(int i);
virtual bool preprocess_page(int, int);
virtual void postclose_print();
void setta_intestazione();
const int look_reg(const char*, int);