From f7e109f7a4c8ca419b651fb4be110550460631e2 Mon Sep 17 00:00:00 2001 From: alex Date: Thu, 21 Apr 2011 12:41:19 +0000 Subject: [PATCH] Patch level : 10.982 Files correlati : ve0.exe ve2.exe Ricompilazione Demo : [ ] Commento : Bug 0001838: Aggiungere descrizione alternativa nei codici corrispondenti Aggiungere descrizione alternativa nei codici corrispondenti in modo tale da poter ricodificare l'articolo e la descrizione con quelle volute dal cliente git-svn-id: svn://10.65.10.50/branches/R_10_00@22013 c028cbd2-c16b-5b4b-a496-9718f37d4682 --- mg/codcorr.h | 1 + ve/f48.dir | 2 +- ve/f48.trr | 3 ++- ve/ve2400.h | 1 + ve/ve2400.uml | 1 + ve/ve2400c.uml | 6 ++++++ ve/velib06.cpp | 16 ---------------- ve/velib06a.cpp | 9 ++++++--- 8 files changed, 18 insertions(+), 21 deletions(-) diff --git a/mg/codcorr.h b/mg/codcorr.h index 790bd354c..fc05b5cff 100755 --- a/mg/codcorr.h +++ b/mg/codcorr.h @@ -12,5 +12,6 @@ #define CODCORR_LIV4 "LIV4" #define CODCORR_TIPOCF "TIPOCF" #define CODCORR_CODCF "CODCF" +#define CODCORR_DESCR "DESCR" #endif diff --git a/ve/f48.dir b/ve/f48.dir index 6ede4553e..87993c367 100755 --- a/ve/f48.dir +++ b/ve/f48.dir @@ -1,3 +1,3 @@ 48 0 -$codcorr|0|0|114|0|Codici corrispondenti|#47|| +$codcorr|0|0|164|0|Codici corrispondenti|#47|| diff --git a/ve/f48.trr b/ve/f48.trr index 8e27981eb..bed99563c 100755 --- a/ve/f48.trr +++ b/ve/f48.trr @@ -1,5 +1,5 @@ 48 -11 +12 CODARTALT|1|20|0|Codice articolo alternativo NRIGA|2|3|0|Numero di riga TIPO|1|1|0|Tipo di codice (ormale,<8>EAN8,<1>EAN13,<3>3/9,Codabar) @@ -11,6 +11,7 @@ LIV3|1|15|0|Livello di giacenza 3 LIV4|1|15|0|Livello di giacenza 4 TIPOCF|1|1|0|Tipo liente ornitore CODCF|3|6|0|Codice +DESCR|1|50|0|Descrizione codice corrispondente 2 CODART+NRIGA| CODARTALT|X diff --git a/ve/ve2400.h b/ve/ve2400.h index e47bf51c5..60301bfce 100755 --- a/ve/ve2400.h +++ b/ve/ve2400.h @@ -236,6 +236,7 @@ #define FS_TIPOCF 108 #define FS_CODCF 109 #define FS_RAGCF 110 +#define FS_DESCRC 111 // definizioni per l'archivio giacenze #include "ve2400d.h" diff --git a/ve/ve2400.uml b/ve/ve2400.uml index eb0dc11d8..26f6f3492 100755 --- a/ve/ve2400.uml +++ b/ve/ve2400.uml @@ -148,6 +148,7 @@ BEGIN ITEM "Tipo C/F" ITEM "Codice C/F" ITEM "Ragiore Sociale@50" + ITEM "Descrizione@50" END TEXT DLG_NULL diff --git a/ve/ve2400c.uml b/ve/ve2400c.uml index 35b7c7542..5585ae1c0 100755 --- a/ve/ve2400c.uml +++ b/ve/ve2400c.uml @@ -139,6 +139,12 @@ BEGIN GROUP 1 END +STRING FS_DESCRC 50 +BEGIN + PROMPT 2 13 "Descrizione " + FIELD DESCR +END + BUTTON DLG_OK 10 2 BEGIN PROMPT -13 -1 "" diff --git a/ve/velib06.cpp b/ve/velib06.cpp index e53ac25fa..9d68e420d 100755 --- a/ve/velib06.cpp +++ b/ve/velib06.cpp @@ -235,22 +235,6 @@ TDocumento_mask::TDocumento_mask(const char* td) hide(204); disable(204); - /* Metodo poco raccomandabile: da eliminare e dimenticare :-) - TBrowse * nb = efield(F_CODNOTE).browse(); - if (nb != NULL) // da eliminare - { - nb->remove_output_field(); - nb->add_output_field(TOSTRING(F_CODNOTE), "CODTAB"); - } - TBrowse * nbd = efield(F_CODNOTE).browse(); - if (nbd != NULL) // da eliminare - { - nbd->remove_output_field(); - nbd->add_output_field(TOSTRING(F_CODNOTE), "CODTAB"); - } - */ - - // Metodo apparentemente corretto, che non usa funzioni assurde con copia/incolla errati for (int n = 0; n < 2; n++) { const short id = n == 0 ? F_CODNOTE : F_NOTECLI; diff --git a/ve/velib06a.cpp b/ve/velib06a.cpp index 536869552..db4135c9f 100755 --- a/ve/velib06a.cpp +++ b/ve/velib06a.cpp @@ -1596,7 +1596,8 @@ bool codart_handler(TMask_field& f, KEY key ) TRectype anamag = cache().get(LF_ANAMAG, codart); // anamag puo' cambiare bool found = !anamag.empty(); TString4 umcorr; - + TString desc; + if (found) row_mask.set(FR_CODARTMAG, codart, true); else @@ -1608,6 +1609,7 @@ bool codart_handler(TMask_field& f, KEY key ) if (codalt.read() == NOERR) { codart = codalt.get(CODCORR_CODART); + desc = codalt.get(CODCORR_DESCR); anamag = cache().get(LF_ANAMAG, codart); found = !anamag.empty(); if (found) @@ -1639,7 +1641,6 @@ bool codart_handler(TMask_field& f, KEY key ) } row_mask.set(FR_CHECKED, "X"); - TString desc; if (!found) { row_mask.set(FR_CODARTMAG, "", true); @@ -1657,7 +1658,9 @@ bool codart_handler(TMask_field& f, KEY key ) { const TString4 lingua = mask.get(F_CODLIN); const TCodice_articolo codart = row_mask.get(FR_CODARTMAG); - desc = anamag.get(ANAMAG_DESCR); + + if (desc.blank()) + desc = anamag.get(ANAMAG_DESCR); if (mask.doc()[current_doc_row].is_omaggio()) {