diff --git a/MP-ADM/WebUserControls/mod_planCreate.ascx b/MP-ADM/WebUserControls/mod_planCreate.ascx
index f8eedfa7..0f5367df 100644
--- a/MP-ADM/WebUserControls/mod_planCreate.ascx
+++ b/MP-ADM/WebUserControls/mod_planCreate.ascx
@@ -114,11 +114,14 @@
-
- CREA PODL Gruppo
- Selezionare LA MACCHINA ESATTA su cui creare...
- SPLIT PODL
- ...con split deve chiedere NUM PEZZI...
+
+
CREA PODL Gruppo
+ Selezionare LA MACCHINA ESATTA su cui creare...
+
+
+
SPLIT PODL
+ ...con split deve chiedere NUM PEZZI...
+
ricordarsi che deve salvare dati come data/ora creazione + utente creazione
diff --git a/MP-ADM/WebUserControls/mod_planCreate.ascx.cs b/MP-ADM/WebUserControls/mod_planCreate.ascx.cs
index a2220c57..0c752403 100644
--- a/MP-ADM/WebUserControls/mod_planCreate.ascx.cs
+++ b/MP-ADM/WebUserControls/mod_planCreate.ascx.cs
@@ -107,12 +107,12 @@ namespace MP_ADM.WebUserControls
private void calcTotali()
{
- // update valori calcolati in base a selezione...
+ // update valori calcolati in base a selezione...
+ int numOrd = 0;
int numPzOrd = 0;
decimal tempoMinOrd = 0;
int numPzTot = 0;
decimal tempoMinTot = 0;
- int idxPromessa = 0;
foreach (GridViewRow riga in grView.Rows)
{
numPzOrd = 0;
@@ -125,17 +125,19 @@ namespace MP_ADM.WebUserControls
// idxPromessa = Convert.ToInt32(((Label)riga.FindControl("lblIdxODL")).Text);
int.TryParse(((Label)riga.FindControl("lblNumPezzi")).Text.Replace(".", ""), out numPzOrd);
decimal.TryParse(((Label)riga.FindControl("lblTotMinuti")).Text, out tempoMinOrd);
+ if (numPzOrd > 0) numOrd++;
}
catch
{ }
numPzTot += numPzOrd;
tempoMinTot += tempoMinOrd;
- //MapoDb.DataLayer.obj.taAs400.insProdAs400(IdxODL, DataRif);
}
}
- //grView.DataBind();
lblNumPzTot.Text = $"{numPzTot:N0}";
lblOreTot.Text = $"{tempoMinTot / 60:N2}";
+ // controllo SE abilitare il crea gruppo o split...
+ divSplitOdl.Visible = numOrd == 1;
+ divCreaGrp.Visible = numOrd > 0;
}
}
}
\ No newline at end of file
diff --git a/MP-ADM/WebUserControls/mod_planCreate.ascx.designer.cs b/MP-ADM/WebUserControls/mod_planCreate.ascx.designer.cs
index 49d73485..54e97d04 100644
--- a/MP-ADM/WebUserControls/mod_planCreate.ascx.designer.cs
+++ b/MP-ADM/WebUserControls/mod_planCreate.ascx.designer.cs
@@ -111,6 +111,15 @@ namespace MP_ADM.WebUserControls {
///
protected global::System.Web.UI.WebControls.Label lblOreTot;
+ ///
+ /// Controllo divCreaGrp.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlGenericControl divCreaGrp;
+
///
/// Controllo lbtCreaGrp.
///
@@ -120,6 +129,15 @@ namespace MP_ADM.WebUserControls {
///
protected global::System.Web.UI.WebControls.LinkButton lbtCreaGrp;
+ ///
+ /// Controllo divSplitOdl.
+ ///
+ ///
+ /// Campo generato automaticamente.
+ /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind.
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlGenericControl divSplitOdl;
+
///
/// Controllo lbtSplit.
///