Patch level :

Files correlati     :
Ricompilazione Demo : [ ]
Commento            :


git-svn-id: svn://10.65.10.50/trunk@20512 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
luca83 2010-05-28 07:16:55 +00:00
parent a8fb67dd68
commit ae42a8ea83
2 changed files with 31 additions and 8 deletions

View File

@ -106,6 +106,7 @@ long TImporta_spese_app::genera_movcg()
mov.put(MOV_NUMREG, numreg);
mov.put(MOV_DATACOMP, datareg);
mov.put(MOV_DATAREG, datareg);
mov.put(MOV_CODCAUS, _msk->get(F_CODCAU));
mov.write();
return numreg;
@ -232,6 +233,9 @@ bool TImporta_spese_app::transfer()
chiudi_movimento(configfile, tot_doc, data, numreg, righean);
numreg = genera_movcg();
TLocalisamfile mov(LF_MOV);
mov.put(MOV_NUMREG, numreg);
mov.remove();
TFilename filename(nomeini);
filename.fremove();
@ -258,7 +262,7 @@ bool TImporta_spese_app::transfer()
tot_doc -= importo;
TString8 paragraph;
paragraph.format("%d,%d",LF_RMOV,nriga++);
paragraph.format("%d,%d", LF_RMOV, nriga++);
configfile.set_paragraph(paragraph);
configfile.set(RMV_IMPORTO, importo.valore().string());

View File

@ -202,6 +202,7 @@ long TImporta_fat_for_app::genera_movcg()
mov.put(MOV_NUMREG, numreg);
mov.put(MOV_DATACOMP, _msk->get_date(F_DATAREG));
mov.put(MOV_DATAREG, _msk->get_date(F_DATAREG));
mov.write();
return numreg;
@ -374,10 +375,16 @@ void TImporta_fat_for_app::importa_fat(TAssoc_array& righecg, TCommessa_string&
real rimposta = imp * iva / CENTO; rimposta.round(2);
TCommessa comm(idlav);
TCommessa_string cmsstr = comm.cmsstr();
configfile->set(RMI_ANNOES, anno);
configfile->set(RMI_IMPONIBILE, importo.valore().string());
configfile->set(RMI_CODIVA, codiva);
configfile->set(RMI_IMPOSTA, rimposta.string());
configfile->set(RMI_GRUPPO, cmsstr.gruppo());
configfile->set(RMI_CONTO, cmsstr.conto());
configfile->set(RMI_SOTTOCONTO, cmsstr.sotco());
configfile->set(RMI_TIPOATT, 1);
}
}
@ -398,6 +405,9 @@ void TImporta_fat_for_app::importa_fat(TAssoc_array& righecg, TCommessa_string&
configfile->set(RMI_IMPONIBILE, importo.valore().string());
configfile->set(RMI_CODIVA, codiva);
configfile->set(RMI_IMPOSTA, rimposta.string());
configfile->set(RMI_GRUPPO, kmax.gruppo());
configfile->set(RMI_CONTO, kmax.conto());
configfile->set(RMI_SOTTOCONTO, kmax.sotco());
configfile->set(RMI_TIPOATT, 1);
}
@ -448,6 +458,11 @@ void TImporta_fat_for_app::importa_fat_ric(TAssoc_array& righecg, TCommessa_stri
configfile->set(RMV_SEZIONE, causale.get("SEZIONE"));
configfile->set(RMV_IMPORTO, importo.valore().string());
configfile->set(RMV_TIPOC, causale.get("TIPOCF"));
configfile->set(RMV_GRUPPO, causale.get("GRUPPO"));
configfile->set(RMV_CONTO, causale.get("CONTO"));
configfile->set(RMV_SOTTOCONTO, _msk->get_long(F_CODFOR));
configfile->set(RMV_TIPOC, "F");
configfile->set(RMV_ROWTYPE, "T");
key.add(2,1);
const TRectype& causale2 = cache().get(LF_RCAUSALI, key);
@ -500,6 +515,10 @@ void TImporta_fat_for_app::importa_fat_ric(TAssoc_array& righecg, TCommessa_stri
//GESTIONE_INI: metodo che si occupa di generare il file ini e di importarlo effettivamente
void TImporta_fat_for_app::gestione_ini(TAssoc_array& righe, TCommessa_string& kmax, const real& quad, const long numregcg)
{
TLocalisamfile mov(LF_MOV);
mov.put(MOV_NUMREG, numregcg);
mov.remove();
TConfig* configfile = NULL;
TFilename tmpdir; tmpdir.tempdir();
@ -509,7 +528,7 @@ void TImporta_fat_for_app::gestione_ini(TAssoc_array& righe, TCommessa_string& k
configfile = new TConfig(filename, "Transaction"); //setto il paragrafo [Transaction] del file ini
configfile->set_paragraph("Transaction");
configfile->set("Action","MODIFY");
configfile->set("Action","INSERT");
configfile->set("Mode","AUTO");
const int tipofat = _msk->get_int(F_TIPOFAT);