diff --git a/ve/ve1100.cpp b/ve/ve1100.cpp index cfa52f87b..07ccb562c 100755 --- a/ve/ve1100.cpp +++ b/ve/ve1100.cpp @@ -1411,11 +1411,11 @@ void TStampaDoc_application::print_selected() void TStampaDoc_application::print_documento(TDocumento_form& f) { - TLocalisamfile& doc = f.cursor()->file(); + const TRectype& doc = f.cursor()->curr(); const bool is_vis = printer().printtype() == screenvis; if (!is_vis) { - TString status(TR("Documento: ")); + TString80 status(TR("Documento: ")); status << doc.get(DOC_CODNUM); status << '\\' << doc.get(DOC_NDOC); xvt_statbar_set(status); @@ -1934,9 +1934,10 @@ bool TStampaDoc_application::select() _ncopie = m.get_int(F_NCOPIE); if (_alnum == 0) _alnum = 9999999L; - +/* Per ora disabilitamo questa feature, che forse deve essere studiata meglio TString16 config; config << "NUM" << _codnum; printer().read_configuration(config); +*/ } _anno= m.get_int(F_ANNO); @@ -1952,7 +1953,7 @@ bool TStampaDoc_application::select() else _key = BY_NUM_KEY; } - return ok;; + return ok; } void TStampaDoc_application::main_loop() diff --git a/ve/velib06a.cpp b/ve/velib06a.cpp index 4e8fec2d1..682e54b93 100755 --- a/ve/velib06a.cpp +++ b/ve/velib06a.cpp @@ -520,23 +520,21 @@ bool codart_handler(TMask_field& f, KEY key ) row_mask.set(FR_CODARTMAG, "", TRUE); else { - const TString16 lingua = mask.get(F_CODLIN); - const TString codart(row_mask.get(FR_CODARTMAG)); + const TString8 lingua = mask.get(F_CODLIN); + const TCodice_articolo codart(row_mask.get(FR_CODARTMAG)); TString desc(anamag.get("DESCR")); if (mask.doc()[current_doc_row].is_omaggio()) { - static TString80 dicitura_omaggio("---"); - - if (dicitura_omaggio == "---") + static TString* dicitura_omaggio = NULL; + if (dicitura_omaggio == NULL) { - TConfig c(CONFIG_STUDIO); - - dicitura_omaggio = c.get("DESOMAGGI"); - if (dicitura_omaggio.empty()) - dicitura_omaggio = "(OMAGGIO)"; + TConfig c(CONFIG_STUDIO, "ve"); + dicitura_omaggio = new TString(c.get("DESOMAGGI")); + if (dicitura_omaggio->blank()) + *dicitura_omaggio = TR("(OMAGGIO)"); } - desc << " " << dicitura_omaggio; + desc << ' ' << *dicitura_omaggio; } if (lingua.not_empty()) { @@ -551,8 +549,7 @@ bool codart_handler(TMask_field& f, KEY key ) if (__lingua_only > 2) { - TConfig c(CONFIG_DITTA, "ve"); - + TConfig c(CONFIG_DITTA, "ve"); __lingua_only = c.get_bool("LINGUA_ONLY"); } if (__lingua_only) @@ -575,7 +572,7 @@ bool codart_handler(TMask_field& f, KEY key ) umart.put(UMART_CODART, codart); if (umart.read(_isgteq) == NOERR && codart == umart.get(UMART_CODART)) */ - TString key; key << codart << "|1"; + TString80 key; key << codart << "|1"; const TRectype& umart = cache().get(LF_UMART, key); if (!umart.empty()) { @@ -615,7 +612,7 @@ bool codart_handler(TMask_field& f, KEY key ) const TRectype & rec = cache().get(LF_ANAMAG, row_mask.get(FR_CODARTMAG)); if (rec.get_bool("SOSPESO")) - return error_box("Articolo %s sospeso, quindi non movmentabile", (const char *)codart); + return error_box(TR("Articolo %s sospeso, quindi non movimentabile"), (const char *)codart); } } }