Patch level :

Files correlati     :
Ricompilazione Demo : [ ]
Commento            : Stampa sospesi: possibilita' di 5 motivi + scelta data sospensione da a + configurazione stampante per etichette


git-svn-id: svn://10.65.10.50/trunk@7695 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
cris 1999-01-26 13:59:56 +00:00
parent 311165f3b9
commit d2557814b4
3 changed files with 304 additions and 75 deletions

View File

@ -6,14 +6,16 @@
#include "soggetti.h" #include "soggetti.h"
#include "contsan.h" #include "contsan.h"
#include "sezioni.h" #include "sezioni.h"
#include <comuni.h>
#include "at2.h" #include "at2.h"
#include "at2100a.h" #include "at2100a.h"
#include "atlib.h"
#define ALIAS_LCP 100 #define ALIAS_LCPDOM 100
#define ALIAS_TCS 200 #define ALIAS_TCS 200
enum ts { undefined = 0, elenco = 1, etichette = 2 }; enum ts { undefined=0, sintetico=1, completo=2, etichette=3, lettere=4 };
// definizione form per etichette // definizione form per etichette
class TEti_sospesi_form : public TForm class TEti_sospesi_form : public TForm
@ -35,13 +37,15 @@ class TStampaSospesi : public TPrintapp
TMask* _msk; TMask* _msk;
TLocalisamfile* _contsan; TLocalisamfile* _contsan;
TEti_sospesi_form* _form_eti; TEti_sospesi_form* _form_eti;
TEti_sospesi_form* _form_let;
TAssoc_array _categorie; TAssoc_array _categorie;
TParagraph_string _cognome_nome; TParagraph_string _cognome_nome, _dencom, _motivo;
TDate _data_stampa; TDate _data_stampa;
TDate _dataini, _datafin; TDate _dataini, _datafin, _sodataini, _sodatafin;
ts _tipostampa; ts _tipostampa;
TString16 _codsez, _codsot, _motivo; TString16 _codsez, _codsot, _motivo1, _motivo2, _motivo3, _motivo4, _motivo5;
int _etlarghezza, _etcolonne; int _etlarghezza, _etcolonne;
bool _motivi;
static bool filter_func_sospesi(const TRelation* rel); static bool filter_func_sospesi(const TRelation* rel);
@ -51,13 +55,14 @@ protected:
virtual bool set_print(int m); virtual bool set_print(int m);
virtual void set_page(int file, int cnt); virtual void set_page(int file, int cnt);
virtual bool preprocess_page(int file, int counter); virtual bool preprocess_page(int file, int counter);
virtual print_action postprocess_print(int file, int counter);
public: public:
void crea_intestazione(); void crea_intestazione();
void filtra_sezioni(); void filtra_sezioni();
void header_sezione(const TString16 codsez, const TString16 codsot); void header_sezione(const TString16 codsez, const TString16 codsot);
TMask& app_mask() { return *_msk; } TMask& app_mask() { return *_msk; }
TStampaSospesi() : _data_stampa(TODAY), _cognome_nome("",25) {} TStampaSospesi() : _data_stampa(TODAY), _cognome_nome("",25), _dencom("",30), _motivo("",5) {}
}; };
HIDDEN inline TStampaSospesi& app() { return (TStampaSospesi&) main_app(); } HIDDEN inline TStampaSospesi& app() { return (TStampaSospesi&) main_app(); }
@ -103,7 +108,20 @@ void TStampaSospesi::set_page(int file, int cnt)
// altrimenti stampa sempre la stessa etichetta // altrimenti stampa sempre la stessa etichetta
} }
break; break;
case elenco: case lettere:
{
TPrint_section& corpo = _form_let->get_body();
corpo.update();
for (word i = 0; i < corpo.height(); i++)
{
TPrintrow& riga = corpo.row(i);
set_row(i+1,riga);
}
force_setpage(TRUE); // serve perchè alla prossima etichetta rifaccia la setpage
// altrimenti stampa sempre la stessa etichetta
}
break;
case sintetico:
{ {
set_row(1,"@0g@pn", FLD(LF_SOGGETTI,SOG_CODICE,"########")); set_row(1,"@0g@pn", FLD(LF_SOGGETTI,SOG_CODICE,"########"));
set_row(2,"@0g@8,rs", FLD(LF_SOGGETTI,SOG_TESSAVIS)); set_row(2,"@0g@8,rs", FLD(LF_SOGGETTI,SOG_TESSAVIS));
@ -125,39 +143,89 @@ void TStampaSospesi::set_page(int file, int cnt)
set_row(3,""); set_row(3,"");
} }
break; break;
case completo:
{
set_row(1,"@0g@pn", FLD(LF_SOGGETTI,SOG_CODICE,"########"));
set_row(2,"@0g@8,rs", FLD(LF_SOGGETTI,SOG_TESSAVIS));
set_row(3,"@0g@8,rs", FLD(LF_SOGGETTI,SOG_CATDON));
set_row(1,"@9g@S",FLD(LF_SOGGETTI,SOG_COGNOME));
set_row(2,"@9g@S",FLD(LF_SOGGETTI,SOG_NOME));
set_row(3,"@9g@ld", FLD(LF_SOGGETTI,SOG_DATANASC));
set_row(1,"@35g@S", FLD(LF_SOGGETTI,SOG_DOM_INDIR));
set_row(2,"@35g#a", &_dencom);
set_row(1,"@66g@S", FLD(LF_SOGGETTI,SOG_TELABI));
set_row(2,"@66g@S", FLD(LF_SOGGETTI,SOG_TELLAV));
set_row(3,"@66g@S", FLD(LF_SOGGETTI,SOG_TELALT));
set_row(1,"@82gGr @S", FLD(LF_SOGGETTI,SOG_GRUPPOAB0));
set_row(2,"@82gRh @S", FLD(LF_SOGGETTI,SOG_RHANTID));
set_row(3,"@82gFe @S", FLD(LF_SOGGETTI,SOG_FENOTIPORH));
set_row(4,"@82gKe @S", FLD(LF_SOGGETTI,SOG_KELL));
set_row(5,"@82gDu @S", FLD(LF_SOGGETTI,SOG_DU));
set_row(1,"@94g@S", FLD(LF_SOGGETTI,SOG_STATO));
set_row(2,"@94g@ld", FLD(LF_SOGGETTI,SOG_DATASTATO));
set_row(3,"@94g@S", FLD(LF_SOGGETTI,SOG_PROS_STATO));
set_row(4,"@94g@ld", FLD(LF_SOGGETTI,SOG_DATA_PROS));
set_row(5,"@94g#a", &_motivo);
set_row(1,"@105g@ld", FLD(LF_SOGGETTI,SOG_DATAULTID));
set_row(2,"@105g@S", FLD(LF_SOGGETTI,SOG_TIPOULTID));
set_row(3,"@105g@pn", FLD(LF_SOGGETTI,SOG_INTSI,"###"));
set_row(4,"@105g@pn", FLD(LF_SOGGETTI,SOG_INTAF,"###"));
set_row(1,"@116g@ld", FLD(LF_SOGGETTI,SOG_DATAULTDON));
set_row(2,"@116g@S", FLD(LF_SOGGETTI,SOG_TIPOULTDON));
set_row(2,"@116g@pn", FLD(LF_SOGGETTI,SOG_TOTDON));
set_row(6,"");
}
break;
} }
} }
bool TStampaSospesi::filter_func_sospesi(const TRelation* rel) bool TStampaSospesi::filter_func_sospesi(const TRelation* rel)
{ {
bool filtrato = TRUE; bool filtrato = TRUE;
TLocalisamfile& sog = rel->lfile(); TRectype recsog = rel->lfile().curr();
// filtro per categorie // filtro per categorie
TAssoc_array& categorie = app()._categorie; TAssoc_array& categorie = app()._categorie;
if (categorie.items() != 0) if (categorie.items() != 0)
{ {
const TString16 cat = sog.get(SOG_CATDON); const TString16 cat = recsog.get(SOG_CATDON);
filtrato = categorie.is_key((const char*) cat); filtrato = categorie.is_key((const char*) cat);
} }
if ((filtrato) && (app()._sodataini.ok()))
{
const TDate datastato = recsog.get_date(SOG_DATASTATO);
filtrato = (datastato >= app()._sodataini);
}
if ((filtrato) && (app()._sodatafin.ok()))
{
const TDate datastato = recsog.get_date(SOG_STATO);
filtrato = (datastato <= app()._sodatafin);
}
if ((filtrato) && (app()._dataini.ok())) if ((filtrato) && (app()._dataini.ok()))
{ {
const TDate datapross = sog.get_date(SOG_DATA_PROS); const TDate datapross = recsog.get_date(SOG_DATA_PROS);
filtrato = (datapross >= app()._dataini); filtrato = (datapross >= app()._dataini);
} }
if ((filtrato) && (app()._datafin.ok())) if ((filtrato) && (app()._datafin.ok()))
{ {
const TDate datapross = sog.get_date(SOG_DATA_PROS); const TDate datapross = recsog.get_date(SOG_DATA_PROS);
filtrato = (datapross <= app()._datafin); filtrato = (datapross <= app()._datafin);
} }
if ((filtrato) && (app()._motivo.not_empty())) if ((filtrato) && app()._motivi)
{ {
TLocalisamfile contsan(LF_CONTSAN); TLocalisamfile contsan(LF_CONTSAN);
contsan.setkey(2); contsan.setkey(2);
contsan.put(CON_DATACON, sog.get(SOG_DATASTATO)); contsan.put(CON_DATACON, recsog.get(SOG_DATASTATO));
contsan.put(CON_CODICE, sog.get(SOG_CODICE)); contsan.put(CON_CODICE, recsog.get(SOG_CODICE));
if (contsan.read() == NOERR) if (contsan.read() == NOERR)
{ {
if (app()._motivo == contsan.get(CON_MOTIVO)) const TString16 motivo = contsan.get(CON_MOTIVO);
if ((app()._motivo1==motivo) || (app()._motivo2==motivo) || (app()._motivo3==motivo) || (app()._motivo4==motivo) || (app()._motivo5==motivo))
filtrato = TRUE; filtrato = TRUE;
else else
filtrato = FALSE; filtrato = FALSE;
@ -170,13 +238,31 @@ bool TStampaSospesi::filter_func_sospesi(const TRelation* rel)
bool TStampaSospesi::preprocess_page(int file, int counter) bool TStampaSospesi::preprocess_page(int file, int counter)
{ {
if (_tipostampa == elenco) if ((_tipostampa==sintetico) || (_tipostampa==completo))
{ {
TRectype& recsog = current_cursor()->curr(); TRectype& recsog = current_cursor()->curr();
TString80 nome = recsog.get(SOG_COGNOME); TString80 nome = recsog.get(SOG_COGNOME);
nome << " "; nome << " ";
nome << recsog.get(SOG_NOME); nome << recsog.get(SOG_NOME);
_cognome_nome = nome; _cognome_nome = nome;
TString256 localita = "";
localita << recsog.get(SOG_DOM_CAP);
localita << " ";
if (recsog.get(SOG_DOM_CODLOC).empty())
localita << current_cursor()->curr(-ALIAS_LCPDOM).get("S0");
else
localita << current_cursor()->curr(LF_COMUNI).get(COM_DENCOM);
localita << ' ' << current_cursor()->curr(LF_COMUNI).get(COM_PROVCOM);
localita.trim();
_dencom = localita;
TString16 motivo = "";
TLocalisamfile contsan(LF_CONTSAN);
contsan.setkey(2);
contsan.put(CON_DATACON, recsog.get(SOG_DATASTATO));
contsan.put(CON_CODICE, recsog.get(SOG_CODICE));
if (contsan.read() == NOERR)
motivo = contsan.get(CON_MOTIVO);
_motivo = motivo;
// salto pagina se cambio sezione // salto pagina se cambio sezione
const TString16 codsez = recsog.get(SOG_CODSEZ); const TString16 codsez = recsog.get(SOG_CODSEZ);
const TString16 codsot = recsog.get(SOG_CODSOT); const TString16 codsot = recsog.get(SOG_CODSOT);
@ -195,6 +281,12 @@ bool TStampaSospesi::preprocess_page(int file, int counter)
return TRUE; return TRUE;
} }
print_action TStampaSospesi::postprocess_print(int file, int counter)
{
printer().formfeed();
return NEXT_PAGE;
}
void TStampaSospesi::header_sezione(const TString16 codsez, const TString16 codsot) void TStampaSospesi::header_sezione(const TString16 codsez, const TString16 codsot)
{ {
const TString80 densez = current_cursor()->curr(LF_SEZIONI).get(SEZ_DENSEZ); const TString80 densez = current_cursor()->curr(LF_SEZIONI).get(SEZ_DENSEZ);
@ -202,11 +294,14 @@ void TStampaSospesi::header_sezione(const TString16 codsez, const TString16 cods
TString intestazione(132); TString intestazione(132);
intestazione = "Sezione: "; intestazione = "Sezione: ";
intestazione << codsez; intestazione << codsez;
intestazione << "/"; if (codsot.not_empty())
intestazione << codsot; {
intestazione << "/";
intestazione << codsot;
}
intestazione << " "; intestazione << " ";
intestazione << densez; intestazione << densez;
if ((densot.ok())&& (densot.not_empty())) if (densot.not_empty())
{ {
intestazione << "/"; intestazione << "/";
intestazione << densot; intestazione << densot;
@ -217,32 +312,49 @@ void TStampaSospesi::header_sezione(const TString16 codsez, const TString16 cods
} }
bool TStampaSospesi::set_print(int m) bool TStampaSospesi::set_print(int m)
{ {
TPrinter& p = printer();
p.read_configuration();
_tipostampa = undefined; _tipostampa = undefined;
KEY tasto; KEY tasto;
tasto = _msk->run(); tasto = _msk->run();
switch (tasto) switch (tasto)
{ {
case F_ELENCO: case F_SINTETICO:
_tipostampa = elenco; {
_codsez = "**"; _tipostampa = sintetico;
_codsot = "**"; _codsez = _codsot = "**";
break; }
break;
case F_COMPLETO:
{
_tipostampa = completo;
_codsez = _codsot = "**";
}
break;
case F_ETICHETTE: case F_ETICHETTE:
_tipostampa = etichette; _tipostampa = (configura_stampante(p, "AT_ETICHETTE", "etichette")) ? etichette : undefined;
break; break;
case F_LETTERE:
_tipostampa = lettere;
break;
} }
if (_tipostampa != undefined) if (_tipostampa != undefined)
{ {
reset_files(); reset_files();
add_file(LF_SOGGETTI); add_file(LF_SOGGETTI);
// filtro per sezioni selezionati // filtro per sezioni selezionate
filtra_sezioni(); filtra_sezioni();
_motivo = _msk->get(F_MOTIVO); _motivo1 = _msk->get(F_MOTIVO1);
_motivo2 = _msk->get(F_MOTIVO2);
_motivo3 = _msk->get(F_MOTIVO3);
_motivo4 = _msk->get(F_MOTIVO4);
_motivo5 = _msk->get(F_MOTIVO5);
_motivi = (_motivo1.not_empty() || _motivo2.not_empty() || _motivo3.not_empty() || _motivo4.not_empty() || _motivo5.not_empty());
TString filtro; TString filtro;
// filtro per tipo sospensione // filtro per tipo sospensione
const TString16 tiposo = _msk->get(F_TIPO); const TString16 tiposo = _msk->get(F_TIPO);
if (tiposo.not_empty() && tiposo.ok()) if (tiposo.not_empty())
filtro << '(' << SOG_STATO << "== \"" << tiposo << "\")"; filtro << '(' << SOG_STATO << "== \"" << tiposo << "\")";
else else
filtro << "TCS->S6 == \"S\""; filtro << "TCS->S6 == \"S\"";
@ -258,20 +370,22 @@ bool TStampaSospesi::set_print(int m)
const TString16 catqua = _msk->get(F_CAT4); const TString16 catqua = _msk->get(F_CAT4);
const TString16 catqui = _msk->get(F_CAT5); const TString16 catqui = _msk->get(F_CAT5);
const TString16 catses = _msk->get(F_CAT6); const TString16 catses = _msk->get(F_CAT6);
if (catpri.not_empty() && catpri.ok()) if (catpri.not_empty())
_categorie.add((const char*) catpri); _categorie.add((const char*) catpri);
if (catsec.not_empty() && catsec.ok()) if (catsec.not_empty())
_categorie.add((const char*) catsec); _categorie.add((const char*) catsec);
if (catter.not_empty() && catter.ok()) if (catter.not_empty())
_categorie.add((const char*) catter); _categorie.add((const char*) catter);
if (catqua.not_empty() && catqua.ok()) if (catqua.not_empty())
_categorie.add((const char*) catqua); _categorie.add((const char*) catqua);
if (catqui.not_empty() && catqui.ok()) if (catqui.not_empty())
_categorie.add((const char*) catqui); _categorie.add((const char*) catqui);
if (catses.not_empty() && catses.ok()) if (catses.not_empty())
_categorie.add((const char*) catses); _categorie.add((const char*) catses);
_dataini = _msk->get_date(F_DATAINI); _dataini = _msk->get_date(F_DATAINI);
_datafin = _msk->get_date(F_DATAFIN); _datafin = _msk->get_date(F_DATAFIN);
_sodataini = _msk->get_date(F_SODATAINI);
_sodatafin = _msk->get_date(F_SODATAFIN);
current_cursor()->set_filterfunction(filter_func_sospesi); current_cursor()->set_filterfunction(filter_func_sospesi);
reset_print(); reset_print();
crea_intestazione(); crea_intestazione();
@ -284,19 +398,17 @@ bool TStampaSospesi::set_print(int m)
void TStampaSospesi::crea_intestazione() void TStampaSospesi::crea_intestazione()
{ {
reset_header(); reset_header();
if (_tipostampa==sintetico || _tipostampa==completo)
if (_tipostampa == elenco)
{ {
TString sep(132); TString sep(132);
sep = "ELENCO SOSPESI"; sep = "SOGGETTI SOSPESI";
const TString16 tipo = _msk->get(F_TIPO); const TString16 tipo = _msk->get(F_TIPO);
if ((tipo.ok()) && (tipo.not_empty())) if (tipo.not_empty())
{ {
sep << ": tipo "; sep << ": tipo ";
sep << tipo; sep << tipo;
const TString80 dtipo = _msk->get(F_D_TIPO);
sep << " "; sep << " ";
sep << dtipo; sep << _msk->get(F_D_TIPO);
} }
sep.center_just(); sep.center_just();
set_header(2, "@0g%s", (const char*) sep); set_header(2, "@0g%s", (const char*) sep);
@ -318,7 +430,7 @@ bool TStampaSospesi::user_create()
{ {
_rel = new TRelation(LF_SOGGETTI); _rel = new TRelation(LF_SOGGETTI);
_rel->add("TCS", "CODTAB==STATO",1,0,ALIAS_TCS); _rel->add("TCS", "CODTAB==STATO",1,0,ALIAS_TCS);
_rel->add("LCP", "CODTAB==DOM_CODLOC",1,0,ALIAS_LCP); _rel->add("LCP", "CODTAB==DOM_CODLOC",1,0,ALIAS_LCPDOM);
_rel->add(LF_COMUNI, "COM==DOM_CODCOM"); _rel->add(LF_COMUNI, "COM==DOM_CODCOM");
_rel->add(LF_SEZIONI, "CODSEZ==CODSEZ|CODSOT==CODSOT"); _rel->add(LF_SEZIONI, "CODSEZ==CODSEZ|CODSOT==CODSOT");
_contsan = new TLocalisamfile(LF_CONTSAN); _contsan = new TLocalisamfile(LF_CONTSAN);
@ -329,11 +441,13 @@ bool TStampaSospesi::user_create()
_etlarghezza = config.get_int("EtLarghezza"); _etlarghezza = config.get_int("EtLarghezza");
_etcolonne = config.get_int("EtColonne"); _etcolonne = config.get_int("EtColonne");
_form_eti = new TEti_sospesi_form(etformato); _form_eti = new TEti_sospesi_form(etformato);
_form_let = new TEti_sospesi_form("ATLETTER");
return TRUE; return TRUE;
} }
bool TStampaSospesi::user_destroy() bool TStampaSospesi::user_destroy()
{ {
delete _form_let;
delete _form_eti; delete _form_eti;
delete _msk; delete _msk;
delete _contsan; delete _contsan;

View File

@ -25,12 +25,24 @@
#define F_TIPO 301 #define F_TIPO 301
#define F_D_TIPO 302 #define F_D_TIPO 302
#define F_PROSSTIPO 303 #define F_SODATAINI 303
#define F_D_PROSSTIPO 304 #define F_SODATAFIN 304
#define F_DATAINI 305 #define F_PROSSTIPO 305
#define F_DATAFIN 306 #define F_D_PROSSTIPO 306
#define F_MOTIVO 307 #define F_DATAINI 307
#define F_D_MOTIVO 308 #define F_DATAFIN 308
#define F_MOTIVO1 309
#define F_D_MOTIVO1 310
#define F_MOTIVO2 311
#define F_D_MOTIVO2 312
#define F_MOTIVO3 313
#define F_D_MOTIVO3 314
#define F_MOTIVO4 315
#define F_D_MOTIVO4 316
#define F_MOTIVO5 317
#define F_D_MOTIVO5 318
#define F_ELENCO 401 #define F_SINTETICO 401
#define F_ETICHETTE 402 #define F_COMPLETO 402
#define F_ETICHETTE 403
#define F_LETTERE 404

View File

@ -1,31 +1,40 @@
#include "at2100a.h" #include "at2100a.h"
TOOLBAR "" 0 20 0 2 TOOLBAR "" 0 20 0 2
BUTTON F_SINTETICO 9 2
BUTTON F_ELENCO 9 2
BEGIN BEGIN
PROMPT -13 -11 "E~lenco" PROMPT -15 -11 "~Sintetico"
MESSAGE EXIT,F_ELENCO MESSAGE EXIT,F_SINTETICO
END
BUTTON F_COMPLETO 9 2
BEGIN
PROMPT -25 -11 "~Completo"
MESSAGE EXIT,F_COMPLETO
END END
BUTTON F_ETICHETTE 9 2 BUTTON F_ETICHETTE 9 2
BEGIN BEGIN
PROMPT -23 -11 "~Etichette" PROMPT -35 -11 "~Etichette"
MESSAGE EXIT,F_ETICHETTE MESSAGE EXIT,F_ETICHETTE
END
BUTTON F_LETTERE 9 2
BEGIN
PROMPT -45 -11 "~Lettere"
MESSAGE EXIT,F_LETTERE
END END
BUTTON DLG_QUIT 9 2 BUTTON DLG_QUIT 9 2
BEGIN BEGIN
PROMPT -33 -11 "" PROMPT -55 -11 ""
END END
ENDPAGE ENDPAGE
PAGE "Stampa soggetti sospesi" -1 -1 78 20 PAGE "Stampa soggetti sospesi" -1 -1 78 20
GROUPBOX DLG_NULL 77 4 GROUPBOX DLG_NULL 77 4
BEGIN BEGIN
PROMPT 1 1 "Scelta sezioni/sottogruppi" PROMPT 1 1 "Scelta sezioni/sottogruppi"
END END
STRING F_SEZINI 2 STRING F_SEZINI 2
@ -265,7 +274,7 @@ BEGIN
FLAGS "D" FLAGS "D"
END END
GROUPBOX DLG_NULL 77 6 GROUPBOX DLG_NULL 77 11
BEGIN BEGIN
PROMPT 1 10 "Opzioni per la stampa" PROMPT 1 10 "Opzioni per la stampa"
END END
@ -291,9 +300,19 @@ BEGIN
FLAGS "D" FLAGS "D"
END END
DATE F_SODATAINI
BEGIN
PROMPT 2 12 "Data sosp. dal "
END
DATE F_SODATAFIN
BEGIN
PROMPT 33 12 "al "
END
STRING F_PROSSTIPO 2 STRING F_PROSSTIPO 2
BEGIN BEGIN
PROMPT 2 12 "Prossimo tipo " PROMPT 2 13 "Prossimo tipo "
FLAGS "U" FLAGS "U"
USE TCS USE TCS
INPUT CODTAB F_PROSSTIPO INPUT CODTAB F_PROSSTIPO
@ -308,38 +327,122 @@ END
STRING F_D_PROSSTIPO 30 STRING F_D_PROSSTIPO 30
BEGIN BEGIN
PROMPT 27 12 "" PROMPT 27 13 ""
FLAGS "D" FLAGS "D"
END END
DATE F_DATAINI DATE F_DATAINI
BEGIN BEGIN
PROMPT 2 13 "Data pross. tipo dal " PROMPT 2 14 "Data pross. dal "
END END
DATE F_DATAFIN DATE F_DATAFIN
BEGIN BEGIN
PROMPT 34 13 "al " PROMPT 33 14 "al "
END END
STRING F_MOTIVO 4 STRING F_MOTIVO1 4
BEGIN BEGIN
PROMPT 2 14 "Motivo " PROMPT 2 15 "Motivi "
FLAGS "U" FLAGS "U"
USE MTC USE MTC
INPUT CODTAB F_MOTIVO INPUT CODTAB F_MOTIVO1
DISPLAY "Codice" CODTAB DISPLAY "Codice" CODTAB
DISPLAY "Descrizione@30" S0 DISPLAY "Descrizione@30" S0
OUTPUT F_MOTIVO CODTAB OUTPUT F_MOTIVO1 CODTAB
OUTPUT F_D_MOTIVO S0 OUTPUT F_D_MOTIVO1 S0
CHECKTYPE NORMAL CHECKTYPE NORMAL
WARNING "Codice non presente" WARNING "Codice non presente"
HELP "Motivo del controllo: vuoto = tutti" HELP "Motivo del controllo: vuoto = tutti"
END END
STRING F_D_MOTIVO 30 STRING F_D_MOTIVO1 30
BEGIN BEGIN
PROMPT 27 14 "" PROMPT 27 15 ""
FLAGS "D"
END
STRING F_MOTIVO2 4
BEGIN
PROMPT 2 16 " "
FLAGS "U"
USE MTC
INPUT CODTAB F_MOTIVO2
DISPLAY "Codice" CODTAB
DISPLAY "Descrizione@30" S0
OUTPUT F_MOTIVO2 CODTAB
OUTPUT F_D_MOTIVO2 S0
CHECKTYPE NORMAL
WARNING "Codice non presente"
HELP "Motivo del controllo: vuoto = tutti"
END
STRING F_D_MOTIVO2 30
BEGIN
PROMPT 27 16 ""
FLAGS "D"
END
STRING F_MOTIVO3 4
BEGIN
PROMPT 2 17 " "
FLAGS "U"
USE MTC
INPUT CODTAB F_MOTIVO3
DISPLAY "Codice" CODTAB
DISPLAY "Descrizione@30" S0
OUTPUT F_MOTIVO3 CODTAB
OUTPUT F_D_MOTIVO3 S0
CHECKTYPE NORMAL
WARNING "Codice non presente"
HELP "Motivo del controllo: vuoto = tutti"
END
STRING F_D_MOTIVO3 30
BEGIN
PROMPT 27 17 ""
FLAGS "D"
END
STRING F_MOTIVO4 4
BEGIN
PROMPT 2 18 " "
FLAGS "U"
USE MTC
INPUT CODTAB F_MOTIVO4
DISPLAY "Codice" CODTAB
DISPLAY "Descrizione@30" S0
OUTPUT F_MOTIVO4 CODTAB
OUTPUT F_D_MOTIVO4 S0
CHECKTYPE NORMAL
WARNING "Codice non presente"
HELP "Motivo del controllo: vuoto = tutti"
END
STRING F_D_MOTIVO4 30
BEGIN
PROMPT 27 18 ""
FLAGS "D"
END
STRING F_MOTIVO5 4
BEGIN
PROMPT 2 19 " "
FLAGS "U"
USE MTC
INPUT CODTAB F_MOTIVO5
DISPLAY "Codice" CODTAB
DISPLAY "Descrizione@30" S0
OUTPUT F_MOTIVO5 CODTAB
OUTPUT F_D_MOTIVO5 S0
CHECKTYPE NORMAL
WARNING "Codice non presente"
HELP "Motivo del controllo: vuoto = tutti"
END
STRING F_D_MOTIVO5 30
BEGIN
PROMPT 27 19 ""
FLAGS "D" FLAGS "D"
END END