From bcc4dff1ea4e76ae482ddd9ae47c06514e0c8f31 Mon Sep 17 00:00:00 2001 From: "Samuele E. Locatelli" Date: Fri, 20 Dec 2019 17:52:11 +0100 Subject: [PATCH] abbozzati test in order manager --- NKC_WF/OrderManager.aspx.cs | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/NKC_WF/OrderManager.aspx.cs b/NKC_WF/OrderManager.aspx.cs index 86181a0..e8ab086 100644 --- a/NKC_WF/OrderManager.aspx.cs +++ b/NKC_WF/OrderManager.aspx.cs @@ -46,6 +46,7 @@ namespace NKC_WF catch (Exception exc) { logger.lg.scriviLog($"Eccezione in Copia SQL file:{Environment.NewLine}{exc}"); + DataLayer.man.taEL.insertQuery(DateTime.Now, "Copy CSV", $"{e.BatchName}", $"{e.BatchName}.{e.FileName}", $"Exception: {exc}"); } // chiamo stored caricamento try @@ -59,8 +60,31 @@ namespace NKC_WF // salvo log errore... DataLayer.man.taEL.insertQuery(DateTime.Now, "Upload CSV", $"{e.BatchName}", $"{e.BatchName}.{e.FileName}", $"Exception: {exc}"); } + doValidations(e.BatchName); doUpdate(); } + /// + /// Effettua validazione dati + /// + private void doValidations(string batchName) + { + // faccio un ciclo su OGNI record Part --> cerco se mancassero dei file dxf... + int batchID = 0; + int.TryParse(batchName, out batchID); + try + { + var tabParts = DataLayer.man.taIL.getByBatch(batchID); + if (tabParts.Count > 0) + { + foreach (var item in tabParts) + { + // cerco file! + } + } + } + catch + { } + } private void Cmp_fileUpload_eh_doRefresh(object sender, EventArgs e) { @@ -71,7 +95,9 @@ namespace NKC_WF { doUpdate(); } - + /// + /// Update interfaccia + /// public void doUpdate() {