diff --git a/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx b/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx
index 2fb9c67..f2bca66 100644
--- a/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx
+++ b/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx
@@ -22,6 +22,5 @@
-
\ No newline at end of file
diff --git a/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx.cs b/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx.cs
index 4bb2091..25b7a0f 100644
--- a/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx.cs
+++ b/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx.cs
@@ -12,24 +12,6 @@ namespace NKC_WF.WebUserControls
{
public partial class cmp_MU_svgViewer : System.Web.UI.UserControl
{
- ///
- /// Batch corrente...
- ///
- public int BatchId
- {
- set
- {
- hfBatchID.Value = value.ToString();
- calcSheet();
- doUpdate();
- }
- get
- {
- int answ = 0;
- int.TryParse(hfBatchID.Value, out answ);
- return answ;
- }
- }
///
/// Foglio corrente...
///
@@ -61,53 +43,12 @@ namespace NKC_WF.WebUserControls
hfFilename.Value = value;
}
}
- protected void calcSheet()
- {
- // base path
- string baseOrig = memLayer.ML.CRS("drawBaseBath").ToLower();
- string baseCurr = memLayer.ML.CRS("srvDrawBaseBath").ToLower();
- //SOLO SE ho batch != 0...
- if (BatchId > 0)
- {
- // FORSE 5/5?!?
- var sheetList = DataLayer.man.taSHL.getByMLStatus(BatchId, 3, 5);
- if (sheetList.Count > 0)
- {
- SheetId = sheetList[0].SheetID;
-#if false
- filename = sheetList[0].DrawFilePath.ToLower().Replace(baseOrig, baseCurr);
- // NON DOVREBEB SERVIRE MAP se è già share di rete... anche se è su MEDESIMA macchina
- //filename = Server.MapPath(filename);
-#endif
- }
- }
-#if false
- else if (SheetId > 0)
- {
- filename = DataLayer.man.taSHL.getByItemID(SheetId)[0].DrawFilePath.ToLower().Replace(baseOrig, baseCurr);
- }
-#endif
- }
public void doUpdate()
{
// recupero ID del foglio corrente
string answ = "";
try
{
-#if false
- // FORSE 5/5?!?
- var sheetList = DataLayer.man.taSHL.getByMLStatus(BatchId, 3, 5);
- if (sheetList.Count > 0)
- {
- SheetId = sheetList[0].SheetID;
- // lo leggo da file
- string baseOrig = memLayer.ML.CRS("drawBaseBath").ToLower();
- string baseCurr = memLayer.ML.CRS("srvDrawBaseBath").ToLower();
- filename = sheetList[0].DrawFilePath.ToLower().Replace(baseOrig, baseCurr);
- // NON DOVREBEB SERVIRE MAP se è già share di rete... anche se è su MEDESIMA macchina
- //filename = Server.MapPath(filename);
- }
-#endif
string baseOrig = memLayer.ML.CRS("drawBaseBath").ToLower();
string baseCurr = memLayer.ML.CRS("srvDrawBaseBath").ToLower();
var tabSheets = DataLayer.man.taSHL.getBySheetId(SheetId);
diff --git a/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx.designer.cs b/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx.designer.cs
index e9c5721..52b6bbd 100644
--- a/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx.designer.cs
+++ b/NKC_WF/WebUserControls/cmp_MU_svgViewer.ascx.designer.cs
@@ -23,15 +23,6 @@ namespace NKC_WF.WebUserControls
///
protected global::System.Web.UI.HtmlControls.HtmlGenericControl svgTable;
- ///
- /// Controllo hfBatchID.
- ///
- ///
- /// Campo generato automaticamente.
- /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
- ///
- protected global::System.Web.UI.WebControls.HiddenField hfBatchID;
-
///
/// Controllo hfSheetId.
///
diff --git a/NKC_WF/site/MachineUnload.aspx.cs b/NKC_WF/site/MachineUnload.aspx.cs
index 39ceaea..1a21799 100644
--- a/NKC_WF/site/MachineUnload.aspx.cs
+++ b/NKC_WF/site/MachineUnload.aspx.cs
@@ -38,9 +38,21 @@ namespace NKC_WF
BatchId = 242; // fixed x test!
// aggiorno child
cmp_MU_stats.BatchId = BatchId;
- cmp_MU_svgViewer.BatchId = BatchId;
cmp_MU_bins.BatchId = BatchId;
cmp_MU_carts.BatchId = BatchId;
+ // calcolo sheet x SVG viewer...
+ int SheetId = 0;
+ //SOLO SE ho batch != 0...
+ if (BatchId > 0)
+ {
+ // FORSE 5/5?!?
+ var sheetList = DataLayer.man.taSHL.getByMLStatus(BatchId, 3, 5);
+ if (sheetList.Count > 0)
+ {
+ SheetId = sheetList[0].SheetID;
+ }
+ }
+ cmp_MU_svgViewer.SheetId = SheetId;
}
}
}
\ No newline at end of file