Conversione per pulire le testate dei movimenti di incasso immediato
git-svn-id: svn://10.65.10.50/trunk@1532 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
3e1932aaf4
commit
9775ccaaac
57
ba/bacnv.cpp
57
ba/bacnv.cpp
@ -1,6 +1,7 @@
|
||||
#include <xvt.h>
|
||||
|
||||
#include <applicat.h>
|
||||
#include <assoc.h>
|
||||
#include <isam.h>
|
||||
#include <mailbox.h>
|
||||
#include <progind.h>
|
||||
@ -331,26 +332,33 @@ void TConversione_archivi::convert_patty()
|
||||
if (doc.read(_isequal, _lock) == NOERR)
|
||||
doc.remove();
|
||||
}
|
||||
TDir d;
|
||||
d.get(LF_CAUSALI);
|
||||
if (d.eod() > 0L)
|
||||
TAssoc_array causarr;
|
||||
|
||||
TLocalisamfile caus(LF_CAUSALI);
|
||||
|
||||
if (caus.items() > 0L)
|
||||
{
|
||||
TLocalisamfile caus(LF_CAUSALI);
|
||||
|
||||
for (caus.first(_lock); caus.good(); caus.next(_lock))
|
||||
{
|
||||
const TString16 tpd = caus.get("TIPODOC");
|
||||
const TString16 tpd(caus.get("TIPODOC"));
|
||||
const TString16 incimm(caus.get("CODCAUSIM"));
|
||||
|
||||
if (incimm.not_empty())
|
||||
causarr.add(incimm, incimm);
|
||||
if (tpd == "AN") caus.zero("TIPODOC");
|
||||
else
|
||||
if (tpd == "IN") caus.zero("TIPODOC");
|
||||
else
|
||||
if (tpd == "PG") caus.zero("TIPODOC");
|
||||
else
|
||||
if (tpd == "NA") caus.put("TIPODOC","NC");
|
||||
if (tpd == "NA") caus.put("TIPODOC","NC");
|
||||
|
||||
caus.rewrite();
|
||||
}
|
||||
}
|
||||
}
|
||||
TDir d;
|
||||
const bool topatch = causarr.items() > 0;
|
||||
|
||||
d.get(LF_MOV);
|
||||
if (d.eod() > 0L)
|
||||
{
|
||||
@ -358,8 +366,32 @@ if (d.eod() > 0L)
|
||||
|
||||
for (mov.first(_lock); mov.good(); mov.next(_lock))
|
||||
{
|
||||
const TString16 tpd = mov.get("TIPODOC");
|
||||
|
||||
const TString16 tpd(mov.get("TIPODOC"));
|
||||
if (topatch)
|
||||
{
|
||||
const TString16 codcaus(mov.get("CODCAUS"));
|
||||
|
||||
if (causarr.objptr(codcaus) != NULL)
|
||||
{
|
||||
mov.zero("DATA74TER");
|
||||
mov.zero("REG");
|
||||
mov.zero("PROTIVA");
|
||||
mov.zero("UPROTIVA");
|
||||
mov.zero("REGST");
|
||||
mov.zero("TIPO");
|
||||
mov.zero("CODCF");
|
||||
mov.zero("TOTDOC");
|
||||
mov.zero("RITFIS");
|
||||
mov.zero("RITSOC");
|
||||
mov.zero("PROVVIS");
|
||||
mov.zero("CODVALI");
|
||||
mov.zero("CAMBIOI");
|
||||
mov.zero("CORRLIRE");
|
||||
mov.zero("CORRVALUTA");
|
||||
mov.zero("OCFPI");
|
||||
mov.zero("CODPAG");
|
||||
}
|
||||
}
|
||||
if (tpd == "AN") mov.zero("TIPODOC");
|
||||
else
|
||||
if (tpd == "IN") mov.zero("TIPODOC");
|
||||
@ -369,7 +401,10 @@ if (d.eod() > 0L)
|
||||
if (tpd == "NA") mov.put("TIPODOC","NC");
|
||||
mov.rewrite();
|
||||
}
|
||||
}
|
||||
}
|
||||
{
|
||||
|
||||
}
|
||||
if (_codditta == 0)
|
||||
{
|
||||
TSystemisamfile f(LF_FORM);
|
||||
|
Loading…
x
Reference in New Issue
Block a user