Correzioni varie

git-svn-id: svn://10.65.10.50/trunk@3761 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
nik 1996-10-11 15:03:18 +00:00
parent 8dc7c199a2
commit bd05f22fa1
11 changed files with 129 additions and 114 deletions

View File

@ -6,8 +6,8 @@ JOIN 7 TO 9 INTO CODANAGR=CODANAGR
JOIN 8 TO 6 ALIAS 118 INTO CODANAGR=CODANAGR JOIN 8 TO 6 ALIAS 118 INTO CODANAGR=CODANAGR
JOIN 13 TO 8 ALIAS 113 INTO COM=COMNASC JOIN 13 TO 8 ALIAS 113 INTO COM=COMNASC
JOIN 13 TO 6 ALIAS 213 INTO COM=COMRF(COMRES) JOIN 13 TO 6 ALIAS 213 INTO COM=COMRF(COMRES)
JOIN 6 TO 36 ALIAS 216 INTO CODANAGR==RAPPR JOIN 6 TO 36 ALIAS 216 INTO TIPOA=="F" CODANAGR==RAPPR
JOIN 8 TO 216@ ALIAS 218 INTO CODANAGR==CODANAGR JOIN 8 TO 216@ ALIAS 218 INTO CODANAGR==CODANAGR
JOIN 13 TO 218@ ALIAS 313 INTO COM==COMNASC JOIN 13 TO 218@ ALIAS 313 INTO COM==COMNASC
JOIN 13 TO 216@ ALIAS 413 INTO COM==COMRF(COMRES) JOIN 13 TO 216@ ALIAS 413 INTO COM==COMRF(COMRES)
JOIN 10 TO 9 INTO CODDITTA==CODDITTA CODATT==CODATTPREV JOIN 10 TO 9 INTO CODDITTA==CODDITTA CODATT==CODATTPREV
@ -353,7 +353,6 @@ STRINGA 34
BEGIN BEGIN
KEY "CAP SEDE LEGALE" KEY "CAP SEDE LEGALE"
PROMPT 121 17 "" PROMPT 121 17 ""
FIELD 116@->CAPRF
FIELD 116@->CAPRES FIELD 116@->CAPRES
GROUP 2 GROUP 2
END END
@ -709,7 +708,6 @@ BEGIN
KEY "LUOGO CONSERVAZIONE S.C. - COM" KEY "LUOGO CONSERVAZIONE S.C. - COM"
PROMPT 25 39 "" PROMPT 25 39 ""
FIELD 513@->DENCOM FIELD 513@->DENCOM
FIEDL 213@->DENCOM
END END
STRINGA 80 STRINGA 80
@ -717,7 +715,6 @@ BEGIN
KEY "LUOGO CONSERVAZIONE S.C. - PROV" KEY "LUOGO CONSERVAZIONE S.C. - PROV"
PROMPT 92 39 "" PROMPT 92 39 ""
FIELD 513@->PROVCOM FIELD 513@->PROVCOM
FIELD 213@->PROVCOM
END END
STRINGA 81 STRINGA 81

View File

@ -591,7 +591,7 @@ END
NUMERO 827 NUMERO 827
BEGIN BEGIN
KEY "NUMERO ISCRIZIONE ALBO" KEY "NUMERO ISCRIZIONE ALBO"
PROMPT 122 18 "" PROMPT 126 18 ""
FIELD 104@->NISCRAA FIELD 104@->NISCRAA
PICTURE "#####" PICTURE "#####"
END END

View File

@ -8,7 +8,7 @@ JOIN 13 TO 6 ALIAS 213 INTO COM=COMRF(COMRES)
JOIN 6 TO 61 ALIAS 216 INTO TIPOA=TIPOA CODANAGR=CODANAGR JOIN 6 TO 61 ALIAS 216 INTO TIPOA=TIPOA CODANAGR=CODANAGR
JOIN 8 TO 216@ ALIAS 218 INTO CODANAGR=CODANAGR JOIN 8 TO 216@ ALIAS 218 INTO CODANAGR=CODANAGR
JOIN 13 TO 218@ ALIAS 313 INTO COM=COMNASC JOIN 13 TO 218@ ALIAS 313 INTO COM=COMNASC
JOIN 13 TO 216@ ALIAS 413 INTO STATO=STATORES COM=COMRES JOIN 13 TO 216@ ALIAS 413 INTO COM=COMRES
JOIN %STA TO 216@ ALIAS 24 INTO CODTAB=STATORES JOIN %STA TO 216@ ALIAS 24 INTO CODTAB=STATORES
END END
@ -50,14 +50,14 @@ END
STRINGA 1 STRINGA 1
BEGIN BEGIN
KEY "CODICE FISCALE" KEY "CODICE FISCALE"
PROMPT 3 9 "" PROMPT 3 10 ""
FIELD 116@->COFI FIELD 116@->COFI
END END
STRINGA 2 STRINGA 2
BEGIN BEGIN
KEY "RAGIONE SOCIALE" KEY "RAGIONE SOCIALE"
PROMPT 39 9 "" PROMPT 39 10 ""
FIELD 116@->RAGSOC FIELD 116@->RAGSOC
GROUP 2 GROUP 2
END END
@ -65,7 +65,7 @@ END
STRINGA 3 STRINGA 3
BEGIN BEGIN
KEY "COGNOME" KEY "COGNOME"
PROMPT 39 9 "" PROMPT 39 10 ""
FIELD 116@->RAGSOC[1,30] FIELD 116@->RAGSOC[1,30]
GROUP 1 GROUP 1
END END
@ -73,7 +73,7 @@ END
STRINGA 4 STRINGA 4
BEGIN BEGIN
KEY "NOME" KEY "NOME"
PROMPT 17 11 "" PROMPT 17 12 ""
FIELD 116@->RAGSOC[31,50] FIELD 116@->RAGSOC[31,50]
GROUP 1 GROUP 1
END END
@ -81,7 +81,7 @@ END
STRINGA 5 STRINGA 5
BEGIN BEGIN
KEY "SESSO" KEY "SESSO"
PROMPT 59 11 "" PROMPT 59 12 ""
FIELD 118@->SESSO FIELD 118@->SESSO
GROUP 1 GROUP 1
END END
@ -89,7 +89,7 @@ END
STRINGA 6 STRINGA 6
BEGIN BEGIN
KEY "DATA DI NASCITA" KEY "DATA DI NASCITA"
PROMPT 67 11 "" PROMPT 63 12 ""
FIELD 118@->DATANASC FIELD 118@->DATANASC
GROUP 1 GROUP 1
END END
@ -97,7 +97,7 @@ END
STRINGA 7 STRINGA 7
BEGIN BEGIN
KEY "COMUNE DI NASCITA" KEY "COMUNE DI NASCITA"
PROMPT 83 11 "" PROMPT 83 12 ""
FIELD 113@->DENCOM FIELD 113@->DENCOM
GROUP 1 GROUP 1
END END
@ -105,7 +105,7 @@ END
STRINGA 8 STRINGA 8
BEGIN BEGIN
KEY "PROV. DI NASCITA" KEY "PROV. DI NASCITA"
PROMPT 125 11 "" PROMPT 125 12 ""
FIELD 113@->PROVCOM FIELD 113@->PROVCOM
GROUP 1 GROUP 1
END END
@ -113,21 +113,21 @@ END
STRINGA 10 STRINGA 10
BEGIN BEGIN
KEY "COMUNE DI RES.FISCALE" KEY "COMUNE DI RES.FISCALE"
PROMPT 17 13 "" PROMPT 17 14 ""
FIELD 213@->DENCOM FIELD 213@->DENCOM
END END
STRINGA 11 STRINGA 11
BEGIN BEGIN
KEY "PROV DI RES.FISCALE" KEY "PROV DI RES.FISCALE"
PROMPT 59 13 "" PROMPT 59 14 ""
FIELD 213@->PROVCOM FIELD 213@->PROVCOM
END END
STRINGA 12 STRINGA 12
BEGIN BEGIN
KEY "VIA di RES." KEY "VIA di RES."
PROMPT 67 13 "" PROMPT 67 14 ""
FIELD 116@->INDRF FIELD 116@->INDRF
FIELD 116@->INDRES FIELD 116@->INDRES
FLAGS "H" FLAGS "H"
@ -137,7 +137,7 @@ END
STRINGA 15 STRINGA 15
BEGIN BEGIN
KEY "NUM. CIVICO di RES." KEY "NUM. CIVICO di RES."
PROMPT 103 13 "" PROMPT 103 14 ""
FIELD 116@->CIVRF FIELD 116@->CIVRF
FIELD 116@->CIVRES FIELD 116@->CIVRES
FLAGS "H" FLAGS "H"
@ -147,13 +147,13 @@ END
STRINGA 17 STRINGA 17
BEGIN BEGIN
KEY "VIA + NUM CIV. DI RES." KEY "VIA + NUM CIV. DI RES."
PROMPT 67 13 "" PROMPT 67 14 ""
END END
STRINGA 16 STRINGA 16
BEGIN BEGIN
KEY "CAP" KEY "CAP"
PROMPT 124 13 "" PROMPT 124 14 ""
FIELD 116@->CAPRF FIELD 116@->CAPRF
FIELD 116@->CAPRES FIELD 116@->CAPRES
END END
@ -161,13 +161,13 @@ END
STRINGA 13 STRINGA 13
BEGIN BEGIN
KEY "CODICE FISCALE DICHIARANTE" KEY "CODICE FISCALE DICHIARANTE"
PROMPT 105 16 "" PROMPT 105 17 ""
END END
NUMBER 14 NUMBER 14
BEGIN BEGIN
KEY "NUM. FOGLIO" KEY "NUM. FOGLIO"
PROMPT 125 19 "" PROMPT 125 20 ""
END END
END END
@ -329,7 +329,7 @@ BEGIN
PROMPT 91 5 "" PROMPT 91 5 ""
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
MESSAGE ADD,FL->17 MESSAGE ADD,FL->17
// FIELD 61->IMPONIBILE FIELD 61->IMPONIBILE
END END
NUMBER 18 NUMBER 18
@ -338,7 +338,7 @@ BEGIN
PROMPT 105 5 "" PROMPT 105 5 ""
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
MESSAGE ADD,FL->18 MESSAGE ADD,FL->18
// FIELD 61->RITENUTE FIELD 61->RITENUTE
END END
NUMBER 19 NUMBER 19
@ -347,7 +347,7 @@ BEGIN
PROMPT 120 5 "" PROMPT 120 5 ""
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
MESSAGE ADD,FL->19 MESSAGE ADD,FL->19
// FIELD 61->NETTO FIELD 61->NETTO
END END
END END
@ -395,12 +395,5 @@ BEGIN
PROMPT 120 1 "" PROMPT 120 1 ""
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
END END
STRINGA 2
BEGIN
KEY "FIRMA"
PROMPT 83 5 ""
FIELD 116@->RAGSOC
END
END END

View File

@ -8,8 +8,8 @@ JOIN 13 TO 6 ALIAS 213 INTO COM=COMRF(COMRES)
JOIN 6 TO 62 ALIAS 216 INTO TIPOA=TIPOA CODANAGR=CODANAGR JOIN 6 TO 62 ALIAS 216 INTO TIPOA=TIPOA CODANAGR=CODANAGR
JOIN 8 TO 216@ ALIAS 218 INTO CODANAGR=CODANAGR JOIN 8 TO 216@ ALIAS 218 INTO CODANAGR=CODANAGR
JOIN 13 TO 218@ ALIAS 313 INTO COM=COMNASC JOIN 13 TO 218@ ALIAS 313 INTO COM=COMNASC
JOIN 13 TO 216@ ALIAS 413 INTO STATO=STATORES COM=COMRES JOIN 13 TO 216@ ALIAS 413 INTO COM=COMRES
JOIN 13 TO 216@ ALIAS 513 INTO STATO=""(STATORES) COM=COMRF(COMRES) JOIN 13 TO 216@ ALIAS 513 INTO COM=COMRF(COMRES)
JOIN %STA TO 216@ ALIAS 24 INTO CODTAB=STATORES JOIN %STA TO 216@ ALIAS 24 INTO CODTAB=STATORES
END END
@ -37,7 +37,7 @@ BEGIN
FI 131 FI 131
END END
SECTION HEADER FIRST 20 SECTION HEADER FIRST 19
LISTA 9 LISTA 9
BEGIN BEGIN
@ -348,14 +348,14 @@ END
STRING 15 STRING 15
BEGIN BEGIN
KEY "DESCR. CAUSALE" KEY "DESCR. CAUSALE"
PROMPT 12 7 "" PROMPT 11 7 ""
FIELD 14@->S2 FIELD 14@->S0[1,20]
END END
NUMBER 16 NUMBER 16
BEGIN BEGIN
KEY "TOTALE" KEY "TOTALE"
PROMPT 26 7 "" PROMPT 42 7 ""
// FIELD 62->TOTALE // FIELD 62->TOTALE
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
MESSAGE ADD,FL->16 MESSAGE ADD,FL->16
@ -364,7 +364,7 @@ END
NUMBER 17 NUMBER 17
BEGIN BEGIN
KEY "SOMME NON SOGGETTE A RITENUTA" KEY "SOMME NON SOGGETTE A RITENUTA"
PROMPT 47 7 "" PROMPT 61 7 ""
// FIELD 62->SOMME // FIELD 62->SOMME
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
MESSAGE ADD,FL->17 MESSAGE ADD,FL->17
@ -373,7 +373,7 @@ END
NUMBER 18 NUMBER 18
BEGIN BEGIN
KEY "IMPONIBILE" KEY "IMPONIBILE"
PROMPT 67 7 "" PROMPT 82 7 ""
// FIELD 62->IMPONIBILE // FIELD 62->IMPONIBILE
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
MESSAGE ADD,FL->18 MESSAGE ADD,FL->18
@ -382,7 +382,7 @@ END
STRING 19 STRING 19
BEGIN BEGIN
KEY "ALIQUOTA" KEY "ALIQUOTA"
PROMPT 84 7 "" PROMPT 93 7 ""
FIELD 62->PERC FIELD 62->PERC
PICTURE "###@@" PICTURE "###@@"
END END
@ -390,7 +390,7 @@ END
NUMBER 20 NUMBER 20
BEGIN BEGIN
KEY "IMPORTO" KEY "IMPORTO"
PROMPT 100 7 "" PROMPT 106 7 ""
// FIELD 62->IMPORTO // FIELD 62->IMPORTO
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
MESSAGE ADD,FL->20 MESSAGE ADD,FL->20
@ -399,7 +399,7 @@ END
NUMBER 21 NUMBER 21
BEGIN BEGIN
KEY "NETTO" KEY "NETTO"
PROMPT 120 7 "" PROMPT 126 7 ""
// FIELD 62->NETTO // FIELD 62->NETTO
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
MESSAGE ADD,FL->21 MESSAGE ADD,FL->21
@ -407,33 +407,33 @@ END
END END
SECTION FOOTER LAST 5 SECTION FOOTER LAST 1
NUMBER 16 NUMBER 16
BEGIN BEGIN
KEY "TOTALE TOTALE" KEY "TOTALE TOTALE"
PROMPT 26 1 "" PROMPT 36 1 ""
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
END END
NUMBER 17 NUMBER 17
BEGIN BEGIN
KEY "TOTALE SOMME NON SOGGETTE" KEY "TOTALE SOMME NON SOGGETTE"
PROMPT 47 1 "" PROMPT 55 1 ""
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
END END
NUMBER 18 NUMBER 18
BEGIN BEGIN
KEY "TOTALE IMPONIBILE" KEY "TOTALE IMPONIBILE"
PROMPT 67 1 "" PROMPT 75 1 ""
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
END END
NUMBER 20 NUMBER 20
BEGIN BEGIN
KEY "TOTALE IMPORTO" KEY "TOTALE IMPORTO"
PROMPT 100 1 "" PROMPT 101 1 ""
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
END END
@ -444,12 +444,4 @@ BEGIN
PICTURE "###.###.###^^^" PICTURE "###.###.###^^^"
END END
STRINGA 2
BEGIN
KEY "FIRMA"
PROMPT 83 5 ""
FIELD 116@->RAGSOC
GROUP 2
END
END END

View File

@ -8,8 +8,8 @@ JOIN 13 TO 6 ALIAS 213 INTO COM=COMRF(COMRES)
JOIN 6 TO 63 ALIAS 216 INTO TIPOA=TIPOA CODANAGR=CODANAGR JOIN 6 TO 63 ALIAS 216 INTO TIPOA=TIPOA CODANAGR=CODANAGR
JOIN 8 TO 216@ ALIAS 218 INTO CODANAGR=CODANAGR JOIN 8 TO 216@ ALIAS 218 INTO CODANAGR=CODANAGR
JOIN 13 TO 218@ ALIAS 313 INTO COM=COMNASC JOIN 13 TO 218@ ALIAS 313 INTO COM=COMNASC
JOIN 13 TO 216@ ALIAS 413 INTO STATO=STATORES COM=COMRES JOIN 13 TO 216@ ALIAS 413 INTO COM=COMRES
JOIN 13 TO 216@ ALIAS 513 INTO STATO=""(STATORES) COM=COMRF(COMRES) JOIN 13 TO 216@ ALIAS 513 INTO COM=COMRF(COMRES)
JOIN %STA TO 216@ ALIAS 24 INTO CODTAB=STATORES JOIN %STA TO 216@ ALIAS 24 INTO CODTAB=STATORES
END END

View File

@ -45,7 +45,7 @@ END
NUMBER 14 NUMBER 14
BEGIN BEGIN
KEY "NUM. FOGLIO" KEY "NUM. FOGLIO"
PROMPT 123 5 "" PROMPT 123 6 ""
END END
END END

View File

@ -1,6 +1,6 @@
USE 42 USE 42
JOIN 37 INTO CODDITTA=CODDITTA JOIN 37 INTO CODDITTA==CODDITTA
JOIN 9 INTO CODDITTA=CODDITTA JOIN 9 INTO CODDITTA==CODDITTA
JOIN 6 TO 9 ALIAS 106 INTO TIPOA=TIPOA CODANAGR=CODANAGR JOIN 6 TO 9 ALIAS 106 INTO TIPOA=TIPOA CODANAGR=CODANAGR
JOIN 8 TO 106@ ALIAS 108 INTO CODANAGR=CODANAGR JOIN 8 TO 106@ ALIAS 108 INTO CODANAGR=CODANAGR
JOIN 13 TO 108@ ALIAS 113 INTO COM==COMNASC JOIN 13 TO 108@ ALIAS 113 INTO COM==COMNASC
@ -23,7 +23,7 @@ BEGIN
FI 131 FI 131
END END
SECTION HEADER FIRST 10 SECTION HEADER FIRST 14
NUMERO 18 NUMERO 18
BEGIN BEGIN

View File

@ -45,11 +45,30 @@ TBase1::~TBase1()
delete c; delete c;
} }
void TBase1::compatta_depositario()
{
TPrint_section& totali = section('B', first_page);
TForm_item& signature = totali.find_field(78);
const int y = signature.y();
TString spazi(50); spazi.fill(' ');
TString cognome = signature.get();
if (cognome.len() > 30 && cognome[29] == ' ')
{
TString nome = cognome.mid(30, -1);
cognome.cut(30); cognome.trim();
cognome << ' ' << nome;
signature.set(cognome);
}
totali.row(y-1).put(spazi, signature.x()-1);
totali.row(y-1).put(cognome, signature.x()-1);
}
void TBase1::stampa_corpo(TPrinter& pr) void TBase1::stampa_corpo(TPrinter& pr)
{ {
TPrint_section& body = section('B', first_page); TPrint_section& body = section('B', first_page);
body.reset(); body.reset();
body.update(); body.update();
compatta_depositario();
const int body_righe = body.height(); const int body_righe = body.height();
for (int i = 0; i < body_righe; i++) for (int i = 0; i < body_righe; i++)
{ {
@ -450,17 +469,8 @@ int TRigheQT::fill(const long codditta,TLocalisamfile& qt)
int TRigaPS::compare(const TSortable& s) const int TRigaPS::compare(const TSortable& s) const
{ {
const TRigaPS& rec = (const TRigaPS&)s; const TRigaPS& rec = (const TRigaPS&)s;
TDate dtDataS = rec.dDataVers(); const long diff = _dDv-rec.dDataVers();
const int month=_dDv.month(); return (int)diff;
const int year=_dDv.year();
const int da = year - dtDataS.year();
const int dm = month - dtDataS.month();
if (da==0)
return dm;
else
return da;
return _dDv<rec.dDataVers();
} }
TRigaPS::TRigaPS(const TLocalisamfile& qt) TRigaPS::TRigaPS(const TLocalisamfile& qt)
@ -518,10 +528,9 @@ int TBase4::calcola_firma()
cognome.cut(30); cognome.trim(); cognome.cut(30); cognome.trim();
cognome << ' ' << nome; cognome << ' ' << nome;
signature.set(cognome); signature.set(cognome);
totali.row(y-1).put(spazi, signature.x()-1);
totali.row(y-1).put(cognome, signature.x()-1);
} }
totali.row(y-1).put(spazi, signature.x()-1);
totali.row(y-1).put(cognome, signature.x()-1);
return y; return y;
} }
@ -991,9 +1000,9 @@ void TQuadroL::stampa_testata(TPrinter& pr)
hh.reset(); hh.reset();
TForm_item& nf=hh.find_field(18); TForm_item& nf=hh.find_field(18);
_num_foglio++;
TString fstr(10); fstr << _num_foglio; TString fstr(10); fstr << _num_foglio;
nf.set(fstr); nf.set(fstr);
_num_foglio++;
hh.update(); hh.update();
const int hhr = hh.height(); const int hhr = hh.height();
@ -1023,20 +1032,20 @@ bool TQuadroL::stampa_L(TPrinter& pr,const long lStartRec,const int iRecL)
while (!finito) while (!finito)
{ {
body.update(); body.update();
const int body_righe = body.height(); const int body_righe = body.height();
for (int i = 0; i < body_righe; i++) for (int i = 0; i < body_righe; i++)
{ {
TPrintrow& rr=body.row(i); TPrintrow& rr=body.row(i);
pr.print(rr); pr.print(rr);
rr.reset(); rr.reset();
_RigaCorr++; _RigaCorr++;
} }
if (usa_progind()) if (usa_progind())
progind()->addstatus(1); progind()->addstatus(1);
righe++; righe++;
++cur; ++cur;
eof=cur.pos()==cur.items()-1; eof=cur.pos()==cur.items()-1;
finito = (righe==iRecL-1) || eof; finito = (righe==iRecL) || eof;
} }
return eof; return eof;
} }
@ -1066,6 +1075,7 @@ bool TQuadroL::print(const long codditta, const long NumFis, const long NumNoFis
{ {
TCursor* cur = cursor(); TCursor* cur = cursor();
TPrinter& pr = printer(); TPrinter& pr = printer();
_num_foglio=0;
if (!InitPrint(codditta)) if (!InitPrint(codditta))
return FALSE; return FALSE;
@ -1081,25 +1091,28 @@ bool TQuadroL::print(const long codditta, const long NumFis, const long NumNoFis
else else
cur->setkey(2); cur->setkey(2);
pr.formlen(dic_form_len());
int lOffsetL=_START_AGG_L; int lOffsetL=_START_AGG_L;
bool finito=FALSE; bool finito=FALSE;
while (!finito) while (!finito)
{ {
jump_to_line(pr, prima_riga(PRIMA)); jump_to_line(pr, prima_riga(PRIMA));
stampa_testata(pr); stampa_testata(pr);
finito=stampa_L(pr,lOffsetL,_REC_PRIMA_AGG_L); finito=stampa_L(pr,lOffsetL,_REC_PRIMA_AGG_L);
next_page(pr); next_page(pr);
if (!finito) _PaginaPosizionamento=FALSE;
{ pr.formlen(dic_form_len());
lOffsetL+=_REC_PRIMA_AGG_L; if (!finito)
jump_to_line(pr, prima_riga(SECONDA)); {
finito=stampa_L(pr,lOffsetL,_REC_SECONDA_AGG_L); lOffsetL+=_REC_PRIMA_AGG_L;
} jump_to_line(pr, prima_riga(SECONDA));
if (finito) finito=stampa_L(pr,lOffsetL,_REC_SECONDA_AGG_L);
{ }
jump_to_line(pr,_RIGA_TOTALI_AGG_L); if (finito)
stampa_totali_L(pr); {
} jump_to_line(pr,_RIGA_TOTALI_AGG_L);
stampa_totali_L(pr);
}
next_page(pr); next_page(pr);
} }
close_print(); close_print();
@ -1143,9 +1156,9 @@ void TQuadroN::stampa_testata(TPrinter& pr)
hh.reset(); hh.reset();
TForm_item& nf=hh.find_field(12); TForm_item& nf=hh.find_field(12);
_num_foglio++;
TString fstr(10); fstr << _num_foglio; TString fstr(10); fstr << _num_foglio;
nf.set(fstr); nf.set(fstr);
_num_foglio++;
hh.update(); hh.update();
const int hhr = hh.height(); const int hhr = hh.height();
@ -1428,6 +1441,7 @@ bool TQuadroN::print(const long codditta, const long NumFis, const long NumNoFis
{ {
TCursor* cur = cursor(); TCursor* cur = cursor();
TPrinter& pr = printer(); TPrinter& pr = printer();
_num_foglio=0;
_codditta=codditta; _codditta=codditta;
if (!InitPrint(codditta)) if (!InitPrint(codditta))
return FALSE; return FALSE;

View File

@ -15,6 +15,7 @@ class TBase1 : public TDicForm
bool _bAllegSoci; bool _bAllegSoci;
long iContaSoci(); long iContaSoci();
protected: protected:
void compatta_depositario();
void stampa_corpo(TPrinter& pr); void stampa_corpo(TPrinter& pr);
void stampa_soci(TPrinter& pr); void stampa_soci(TPrinter& pr);
bool bAllegSoci() const { return _bAllegSoci; } bool bAllegSoci() const { return _bAllegSoci; }

View File

@ -1124,10 +1124,10 @@ void TDistintaG::next_page(TPrinter& pr)
{ {
PaginaQuadro PagCorr = curr_page(); PaginaQuadro PagCorr = curr_page();
if (PagCorr == PRIMA) if (PagCorr == PRIMA)
jump_to_line(pr,57); jump_to_line(pr,58);
else else
if (PagCorr == SECONDA) if (PagCorr == SECONDA)
jump_to_line(pr,51); jump_to_line(pr,52);
stampa_totali(pr); stampa_totali(pr);
TPrint_section& body = section('F', last_page); TPrint_section& body = section('F', last_page);
body.reset(); body.reset();
@ -1205,7 +1205,9 @@ bool TDistintaG::print(const long codditta, const long NumFis, const long NumNoF
_RigaCorr = 0; _RigaCorr = 0;
const long items = filtra(codditta); const long items = filtra(codditta);
// Questo modulo non ha MAI il posizionamento
_PaginaPosizionamento=FALSE;
while (!_EndPrintDitta) while (!_EndPrintDitta)
{ {
for (int pagina=1; pagina <= QGD_PAGINE; pagina++, next_page(pr)) for (int pagina=1; pagina <= QGD_PAGINE; pagina++, next_page(pr))
@ -1216,6 +1218,8 @@ bool TDistintaG::print(const long codditta, const long NumFis, const long NumNoF
{ {
if (_modulaser) ClearFlagModulaser(); if (_modulaser) ClearFlagModulaser();
if (_EndPrintDitta) continue;
for (int righe=0; righe < QGD_RIGHE_PRIMA; righe++) for (int righe=0; righe < QGD_RIGHE_PRIMA; righe++)
{ {
// Stampa intestazione, solo sul primo foglio. // Stampa intestazione, solo sul primo foglio.
@ -1225,8 +1229,9 @@ bool TDistintaG::print(const long codditta, const long NumFis, const long NumNoF
stampa_testata(pr); stampa_testata(pr);
} }
_EndPrintDitta=_finite_fis && _finite_nofis; _EndPrintDitta=(_finite_fis && _finite_nofis) ||
cur->pos() >= cur->items()-1;
if (_finite_fis || StabilitaInesistenzaFis) if (_finite_fis || StabilitaInesistenzaFis)
break; break;
@ -1282,6 +1287,7 @@ bool TDistintaG::print(const long codditta, const long NumFis, const long NumNoF
if (_PaginaCorrente == SECONDA) if (_PaginaCorrente == SECONDA)
{ {
if (_EndPrintDitta) continue;
// Reset del flag di pagina con posiz. // Reset del flag di pagina con posiz.
if (_posiziona && _PaginaPosizionamento) _PaginaPosizionamento = FALSE; if (_posiziona && _PaginaPosizionamento) _PaginaPosizionamento = FALSE;
for (int righe=0; righe < QGD_RIGHE_SECONDA; righe++) for (int righe=0; righe < QGD_RIGHE_SECONDA; righe++)
@ -1293,6 +1299,9 @@ bool TDistintaG::print(const long codditta, const long NumFis, const long NumNoF
if (!righe) if (!righe)
fill_page(pr, HEADER_SECONDA_GD); fill_page(pr, HEADER_SECONDA_GD);
_EndPrintDitta=(_finite_fis && _finite_nofis) ||
(StabilitaInesistenzaNoFis && StabilitaInesistenzaFis);
if (_finite_nofis || StabilitaInesistenzaNoFis) if (_finite_nofis || StabilitaInesistenzaNoFis)
break; break;
@ -1323,6 +1332,9 @@ bool TDistintaG::print(const long codditta, const long NumFis, const long NumNoF
// Gestisce i casi in cui non ci sono percipienti nella distinta.. // Gestisce i casi in cui non ci sono percipienti nella distinta..
if (items==0) _EndPrintDitta=TRUE; if (items==0) _EndPrintDitta=TRUE;
_EndPrintDitta=(_finite_fis && _finite_nofis) ||
cur->pos() >= cur->items()-1;
if (StabilitaInesistenzaNoFis) if (StabilitaInesistenzaNoFis)
break; break;
@ -4030,6 +4042,10 @@ int stampa_quadro(int argc, char* argv[])
{ {
app = new TStampaQuadroAggL(quadro, livello); app = new TStampaQuadroAggL(quadro, livello);
} }
else if (quadro == "N")
{
app = new TStampaQuadroAggN(quadro, livello);
}
if (app != NULL) if (app != NULL)
{ {

View File

@ -100,6 +100,8 @@ typedef enum { fisiche, nofisiche } TipoPagina;
const char* get_ragsoc_anagr(char tipo, long codanagr); const char* get_ragsoc_anagr(char tipo, long codanagr);
const int FIRMADIC=2;
class TDicForm : public TForm class TDicForm : public TForm
{ {
private: private:
@ -129,7 +131,7 @@ class TDicForm : public TForm
long _codditta, _codditta_dic; // cod.ditta e cod.ditta dichiarante long _codditta, _codditta_dic; // cod.ditta e cod.ditta dichiarante
int _RigaCorr; // contatore riga corrente int _RigaCorr; // contatore riga corrente
TString16 _quadro; // codice quadro in stampa TString16 _quadro; // codice quadro in stampa
void firma_dichiarante();
void stampa_testata(TPrinter& pr); void stampa_testata(TPrinter& pr);
virtual bool ultima_pagina() const { return _PaginaCorrente==QUARTA; } virtual bool ultima_pagina() const { return _PaginaCorrente==QUARTA; }
virtual void stampa_totali(TPrinter& pr); virtual void stampa_totali(TPrinter& pr);