Patch level : 10.0 912

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

Pr i movimenti provenitanti da AS400 prassi nei corrispettivi vengono passati ora come conti di ricavo i conti delle righe iva e non vengono piu' passati i degli eventuali giroconti che non sono identificabili


git-svn-id: svn://10.65.10.50/branches/R_10_00@21565 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
alex 2011-02-01 23:36:11 +00:00
parent 00c961b114
commit a5b316a786

View File

@ -219,8 +219,8 @@ bool TTS_textset::set(const char* field, const TVariant& var)
ok = set_field(*info, NULL_VARIANT);
else
{
real v = var.as_real(); v *= CENTO;
ok = set_field(*info, TVariant(v.integer()));
real v = var.as_real();;
ok = set_field(*info, v);
}
break;
default:
@ -748,36 +748,23 @@ void TTS_sender::add_diversi(const TRecordset& mov, const bool moviva)
}
else
{
const char sez = rmov.get(RMV_SEZIONE).as_string()[0];
if (as400 && corrispettivo && sez == 'D')
if (!corrispettivo)
{
field.format("TRF-CONTO_%d", j);
set(field, contoricl);
field.format("TRF-IMPORTO_%d", j);
set(field, rmov.get(RMV_IMPORTO));
field.format("TRF-DA_%d", j);
set(field, rmov.get(RMV_SEZIONE));
field.format("TRF-CAU-AGGIUNT_%d", j);
set(field, descr2agg(rmov.get(RMV_DESCR).as_string()));
j++;
}
else
{
if (k < 8)
{
const real importo = rmov.get(RMV_IMPORTO).as_real();
const char sez = rmov.get(RMV_SEZIONE).as_string()[0];
TImporto i(sez, importo);
if (k < 8)
{
const real importo = rmov.get(RMV_IMPORTO).as_real();
const char sez = rmov.get(RMV_SEZIONE).as_string()[0];
TImporto i(sez, importo);
i.normalize(seznor);
field.format("TRF-CONTORIC_%d", k);
set(field, contoricl);
field.format("TRF-IMP-RIC_%d", k);
set(field, i.valore());
k++;
}
else
log(2, TR("Registrazione con più di 8 conti di costo/ricavo"));
i.normalize(seznor);
field.format("TRF-CONTORIC_%d", k);
set(field, contoricl);
field.format("TRF-IMP-RIC_%d", k);
set(field, i.valore());
k++;
}
else
log(2, TR("Registrazione con più di 8 conti di costo/ricavo"));
}
continue;
}
@ -871,12 +858,12 @@ void TTS_sender::add_conti_ricavo_costo(const TRecordset& mov)
rmov.move_first();
const char tiporiga = rmov.get(RMV_ROWTYPE).as_string()[0];
if (tiporiga <= ' ')
TString16 codice = scod2ricl("TSREG", mov.get(MOV_REG));
const bool corrispettivo = codice[0] == 'C';
if (tiporiga <= ' ' && ! corrispettivo)
return;
TRecordset & riva = rivarecset(mov);
TString16 codice = scod2ricl("TSREG", mov.get(MOV_REG));
const bool corrispettivo = codice[0] == 'C';
const bool acquisto = mov.get(MOV_TIPO).as_string()[0] == 'F';
int i = 0, j = 0;
real fattore = UNO;