diff --git a/ve/ve1300.alx b/ve/ve1300.alx index ce3c989d6..b580fb1fd 100755 --- a/ve/ve1300.alx +++ b/ve/ve1300.alx @@ -1,6 +1,4 @@ -\ Utility - -\ Messaggi specifici per stampa documenti +\ Messaggi specifici per stampa documenti (ve1 -2) : MESSAGE_DESCRIGA ( ... -- ) "34.DESCR" @ \ Legge campo descrizione riga @@ -20,29 +18,29 @@ ; : MESSAGE_CLIENTE ( s1 -- ) - DOC_CLIENTE \ user defined word + DOC_CLIENTE \ user defined word in ve1.exe ; : MESSAGE_DITTA ( s1 -- ) - DOC_DITTA \ user defined word + DOC_DITTA \ user defined word in ve1.exe ; : MESSAGE_PARENTDOC ( [b1] s1 n1 -- ) - DOC_PARENT_DOC \ user defined word + DOC_PARENT_DOC \ user defined word in ve1.exe ; : MESSAGE_PARENTROW ( [b1] s1 n1 -- ) - DOC_PARENT_ROW \ user defined word + DOC_PARENT_ROW \ user defined word in ve1.exe ; : MESSAGE_RIEPILOGOIVA ( b1 s1 n1 -- ) - DOC_RIEPILOGO_IVA + DOC_RIEPILOGO_IVA \ user defined word in ve1.exe ; : MESSAGE_SCADENZE ( b1 s1 -- ) - DOC_SCADENZE + DOC_SCADENZE \ user defined word in ve1.exe ; : MESSAGE_TOTIMPONIBILI ( [n1] -- ) - DOC_TOT_IMPONIBILI + DOC_TOT_IMPONIBILI \ user defined word in ve1.exe ; diff --git a/ve/ve1300.cpp b/ve/ve1300.cpp index a38b48c35..867f62b60 100755 --- a/ve/ve1300.cpp +++ b/ve/ve1300.cpp @@ -808,7 +808,7 @@ bool TReport_doc_app::print_loop(const TString& query) if (docs <= 0) return false; - const bool is_definitive = yesno_box(TR("Stampa in definitiva?")); + const bool is_definitive = yesno_box(TR("Stampare in definitiva %d documenti?"), docs); TReport_doc* report = NULL; TReport_book book; diff --git a/ve/velib06a.cpp b/ve/velib06a.cpp index 7d5780dd5..abe3c5b79 100755 --- a/ve/velib06a.cpp +++ b/ve/velib06a.cpp @@ -177,43 +177,39 @@ bool condpag_hndl( TMask_field& field, KEY key ) bool note_hndl( TMask_field& f, KEY key ) { - TDocumento_mask & m = (TDocumento_mask &) f.mask(); + TDocumento_mask& m = (TDocumento_mask &) f.mask(); if (key == K_TAB && (f.focusdirty() || !m.is_running())) { - TTable & note = (TTable &) ((TEdit_field &) f).browse()->cursor()->file(); -// gestione del campo con descrizione estesa - TString stringone; - TRectype& rec = note.curr(); - TString4 fieldname; - for (int i = 0; i < 6; i++) + const TRectype& note = cache().get("%NOT", f.get()); + if (!note.empty()) { - fieldname.format("S%d", i); - stringone << rec.get(fieldname); - } - stringone.replace((char)0xB6, '\n'); - m.set(F_NOTECLI, stringone); + if (m.is_running() || m.field(F_NOTECLI).empty()) // Preserva descrizione presente in caricamento + { + // gestione del campo con descrizione estesa + TString stringone; + for (int i = 0; i < 6; i++) + { + const char fieldname[3] = { 'S', i, '\0' }; + stringone << note.get(fieldname); + } + stringone.replace(char(0xB6), '\n'); + m.set(F_NOTECLI, stringone); + } - note.setkey(1); - const TString16 cod(f.get()); - - if (cod != note.get("CODTAB")) - { - note.zero(); - note.put("CODTAB", cod); - if (note.read() != NOERR) - note.zero(); - } - if (m.doc().modificabile() && m.field(DLG_SAVEREC).enabled()) - { - const bool reg_disabled = note.get_bool("B0"); - - if (reg_disabled) - message_box("Registrazione disabilitata : %s", (const char *) note.get("S0")); - m.enable(DLG_SAVEREC, !reg_disabled); + if (m.doc().modificabile() && m.field(DLG_SAVEREC).enabled()) + { + const bool reg_disabled = note.get_bool("B0"); + if (reg_disabled) + { + message_box(FR("Registrazione disabilitata : %s"), (const char*)note.get("S0")); + m.disable(DLG_SAVEREC); + } + } } } - return TRUE; + + return true; } // Handler per il calcolo delle date di pagamento