diff --git a/cg/cg2100p.h b/cg/cg2100p.h index 884c925fe..c1815e6e5 100755 --- a/cg/cg2100p.h +++ b/cg/cg2100p.h @@ -1,10 +1,6 @@ #ifndef __CG2100P_H #define __CG2100P_H -#define P_TIPOC 101 -#define P_GRUPPO 102 -#define P_CONTO 103 -#define P_SOTTOCONTO 104 #define P_DESCR 105 #define P_RESIDUO 106 #define P_ANNO 107 diff --git a/cg/cg2100p.uml b/cg/cg2100p.uml index c6d5e9775..02f25761a 100755 --- a/cg/cg2100p.uml +++ b/cg/cg2100p.uml @@ -18,37 +18,9 @@ ENDPAGE PAGE "PARTITE" -1 -1 77 20 -LIST P_TIPOC 1 12 +TEXT P_DESCR 78 BEGIN - PROMPT 1 0 "" - ITEM " |Conto" - ITEM "C|Cliente" - ITEM "F|Fornitore" - FLAGS "D" -END - -NUMBER P_GRUPPO 3 -BEGIN - PROMPT 14 0 "" - FLAGS "D" -END - -NUMBER P_CONTO 3 -BEGIN - PROMPT 19 0 "" - FLAGS "D" -END - -NUMBER P_SOTTOCONTO 6 -BEGIN - PROMPT 24 0 "" - FLAGS "D" -END - -STRING P_DESCR 50 38 -BEGIN - PROMPT 33 0 "" - FLAGS "D" + PROMPT 1 0 "@BConto G C S D" END STRING P_VALUTA 3 diff --git a/cg/cg2105.cpp b/cg/cg2105.cpp index 536304011..28377ce45 100755 --- a/cg/cg2105.cpp +++ b/cg/cg2105.cpp @@ -271,13 +271,25 @@ TGame_mask::TGame_mask(const TBill& bill, long numreg, int riga) : TMask("cg2100p"), _conto(bill), _numreg(numreg), _numrig(riga), _changed(FALSE), _causali(LF_CAUSALI, "CODCAUS", "DESCR") { + TString descr(80); + switch (_conto.tipo()) + { + case 'C': descr = "Cliente"; break; + case 'F': descr = "Fornitore"; break; + default: descr = "Conto"; break; + } + descr << ' ' << _conto.gruppo() << ' ' << _conto.conto() + << ' ' << _conto.sottoconto() << ' ' << ((TBill&)_conto).descrizione(); + set(P_DESCR, descr); + +/* const char tipocf[2] = { _conto.tipo(), '\0' }; set(P_TIPOC, tipocf); set(P_GRUPPO, _conto.gruppo()); set(P_CONTO, _conto.conto()); set(P_SOTTOCONTO, _conto.sottoconto()); set(P_DESCR, ((TBill&)_conto).descrizione()); - +*/ TValuta val; #ifndef __EXTRA__ TMask& cm = app().curr_mask(); @@ -1148,7 +1160,7 @@ void TGame_mask::update_saldo_clifo() add_importo(r, imp.normalize()); r.add("Saldo "); - if (get(P_TIPOC)[0] == 'C') + if (conto().tipo() == 'C') r << "cliente"; else r << "fornitore";