From 36e3e49f9b30b04c9399c95d312f1ca5fd9a790d Mon Sep 17 00:00:00 2001 From: alex Date: Tue, 16 Feb 2010 12:08:01 +0000 Subject: [PATCH] Patch level : 10.0 640 Files correlati : ve0.exe Ricompilazione Demo : [ ] Commento : Bug 0001560: Errore Gestione archivi provvigioni Ho creato un archivio provv. con codice numerico. Chiave Cliente-Articolo. Dopo averlo associato all'agente non riporta la % di provv. git-svn-id: svn://10.65.10.50/trunk@20126 c028cbd2-c16b-5b4b-a496-9718f37d4682 --- ve/sconti.cpp | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/ve/sconti.cpp b/ve/sconti.cpp index 3b00ed945..c7e5bff44 100755 --- a/ve/sconti.cpp +++ b/ve/sconti.cpp @@ -619,7 +619,6 @@ void TCond_vendita::ricerca(bool load_um_only, bool load_scagl_only) break; } - TString16 codric; if (_riga && _riga->id2pos(FR_PERCPROV) >= 0 && _riga->field(FR_PERCPROV).active()) { const TString & codage = _testa->get(F_CODAG); @@ -643,16 +642,20 @@ void TCond_vendita::ricerca(bool load_um_only, bool load_scagl_only) _load_mask |= load_scagl_only && cv_um; for (i = 0; percprovv.is_zero() && seqric[i] != '\0' && seqric[i] != '-'; i++) { + TString16 codric; + if (isdigit(seqric[i])) - const TString codric = age.get(format("CODRICPR%d", i+1)); + codric = age.get(format("CODRICPR%d", i+1)); percprovv = get_percprovv(seqric[i], codric, true, age); } real percalt; seqric = age.get(AGE_SEQALT); for (i = 0; percalt.is_zero() && seqric[i] != '\0' && seqric[i] != '-'; i++) { + TString16 codric; + if (isdigit(seqric[i])) - const TString & codric = age.get(format("CODALTPR%d", i+1)); + codric = age.get(format("CODALTPR%d", i+1)); percalt = get_percprovv(seqric[i], codric, true, age); } percprovv += percalt; @@ -683,16 +686,20 @@ void TCond_vendita::ricerca(bool load_um_only, bool load_scagl_only) _load_mask |= load_scagl_only && cv_um; for (i = 0; percprovv.is_zero() && seqric[i] != '\0' && seqric[i] != '-'; i++) { - if (isdigit(seqric[i])) - const TString & codric = age.get(format("CODRICPR%d", i+1)); + TString16 codric; + + if (isdigit(seqric[i])) + codric = age.get(format("CODRICPR%d", i+1)); percprovv = get_percprovv(seqric[i], codric, false, age); } real percalt; seqric = age.get(AGE_SEQALT); for (i = 0; percalt.is_zero() && seqric[i] != '\0' && seqric[i] != '-'; i++) { - if (isdigit(seqric[i])) - const TString & codric = age.get(format("CODALTPR%d", i+1)); + TString16 codric; + + if (isdigit(seqric[i])) + codric = age.get(format("CODALTPR%d", i+1)); percalt = get_percprovv(seqric[i], codric, false, age); } percprovv += percalt;