From c1db794940bbb2da97797cfeb0a3ea953dc7a487 Mon Sep 17 00:00:00 2001 From: luca83 Date: Fri, 31 Jul 2009 14:12:14 +0000 Subject: [PATCH] =?UTF-8?q?Patch=20level=20=20=20=20=20=20=20=20=20:=2010.?= =?UTF-8?q?0=20patch=2040=3F=20Files=20correlati=20=20=20=20=20:=20lv2=20R?= =?UTF-8?q?icompilazione=20Demo=20:=20[=20]=20Commento=20=20=20=20=20=20?= =?UTF-8?q?=20=20=20=20=20=20:=20Aggiunto=20il=20log=20che=20elenca=20i=20?= =?UTF-8?q?documenti=20non=20evasi=20perch=C3=A8=20mancava=20la=20data=20d?= =?UTF-8?q?i=20prevista=20consegna?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: svn://10.65.10.50/trunk@19176 c028cbd2-c16b-5b4b-a496-9718f37d4682 --- lv/lv2400.cpp | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/lv/lv2400.cpp b/lv/lv2400.cpp index 9d1c242d6..019f05a00 100755 --- a/lv/lv2400.cpp +++ b/lv/lv2400.cpp @@ -1,5 +1,7 @@ #include #include +#include +#include #include "lvlib.h" #include "../ve/velib.h" @@ -706,7 +708,9 @@ bool TGenera_documenti_app::transfer() TString4 tpdoc; TString4 statoi; TString4 statof; - bool err; +// bool err; + + TLog_report *rep = new TLog_report("Documenti non evasi"); numerazione_drit(0, codnum, tpdoc, statoi, statof); @@ -760,11 +764,24 @@ bool TGenera_documenti_app::transfer() query << "TO DTCONS=" << adatacons << "\n"; TISAM_recordset plan(query); - plan.move_first(); - crea_documento(plan); + if (!plan.move_first()) + { + TString str; + str << "Il documento " << docritiri.get(DOC_CODNUM) << ' ' << docritiri.get(DOC_TIPODOC) << " del cliente " + << docritiri.get(DOC_CODCF) << " non è stato evaso (manca data di prevista consegna)"; + rep->log(0, str); + } + else + crea_documento(plan); } + TReport_book buc; + buc.add(*rep); + if (buc.pages() > 0) + buc.preview(); + else + message_box(TR("Generazione terminata")); return true; } void TGenera_documenti_app::main_loop()