diff --git a/MP-TAB-SERV/Components/MachSel.razor.cs b/MP-TAB-SERV/Components/MachSel.razor.cs
index 755f933f..b328ed09 100644
--- a/MP-TAB-SERV/Components/MachSel.razor.cs
+++ b/MP-TAB-SERV/Components/MachSel.razor.cs
@@ -57,7 +57,9 @@ namespace MP_TAB_SERV.Components
{
var listMulti = await TDataService.VMSFDGetAll();
- ListMacchine = listMulti.Where(x => x.IdxMacchina.Contains($"{RecMSE?.IdxMacchina}#")).ToDictionary(x => x.IdxMacchina, x => $"{x.IdxMacchina.Replace($"{RecMSE?.IdxMacchina}#", "")}");
+ ListMacchine = listMulti
+ .Where(x => x.IdxMacchina.Contains($"{RecMSE?.IdxMacchina}#"))
+ .ToDictionary(x => x.IdxMacchina, x => x.CodMaccArticolo);
if (ListMacchine.Count > 0 && string.IsNullOrEmpty(idxMaccSel))
{
diff --git a/MP-TAB-SERV/Components/OdlMan.razor b/MP-TAB-SERV/Components/OdlMan.razor
new file mode 100644
index 00000000..4aeb60be
--- /dev/null
+++ b/MP-TAB-SERV/Components/OdlMan.razor
@@ -0,0 +1,28 @@
+
+
+
+
+
+ @if (needConfProd)
+ {
+
+
@lblWarnHead
+
@lblWarnBody @numPz2Conf
+
+ @if (!odlOk)
+ {
+
+
+
+ }
+ }
+
+ Slave machine man
+
+ @if (!needConfProd)
+ {
+
+ ODL setup (full)
+
+ }
+
\ No newline at end of file
diff --git a/MP-TAB-SERV/Components/OdlMan.razor.cs b/MP-TAB-SERV/Components/OdlMan.razor.cs
new file mode 100644
index 00000000..8e51ff3f
--- /dev/null
+++ b/MP-TAB-SERV/Components/OdlMan.razor.cs
@@ -0,0 +1,138 @@
+using global::Microsoft.AspNetCore.Components;
+using MP.Data.DatabaseModels;
+
+namespace MP_TAB_SERV.Components
+{
+ public partial class OdlMan
+ {
+ #region Public Properties
+
+ ///
+ /// Post update restituisco nuova lista dati
+ ///
+ [Parameter]
+ public EventCallback> E_Updated { get; set; }
+
+ ///
+ /// Verifica ODL OK (ovvero caricato x macchina...)
+ ///
+ public bool odlOk
+ {
+ get => (RecMSE != null && RecMSE.IdxOdl > 0);
+ }
+
+ [Parameter]
+ public MappaStatoExpl? RecMSE { get; set; } = null;
+
+ #endregion Public Properties
+
+ #region Protected Methods
+
+ ///
+ /// Aggiorno...
+ ///
+ ///
+ protected async Task DoUpdate()
+ {
+ isProcessing = true;
+ await Task.Delay(1);
+ isProcessing = false;
+ await Task.Delay(1);
+ }
+
+ protected override async Task OnParametersSetAsync()
+ {
+ await Task.Delay(1);
+ checkAll();
+ }
+
+ protected async Task SetMacc(string selIdxMacc)
+ {
+ isProcessing = true;
+ await Task.Delay(10);
+ IdxMaccSel = selIdxMacc;
+ await DoUpdate();
+ isProcessing = false;
+ await Task.Delay(10);
+ }
+
+ #endregion Protected Methods
+
+ #region Private Fields
+
+ private string lblWarnBody = "Pezzi da confermare: ";
+
+ private string lblWarnHead = "Attenzione";
+
+ private int numPz2Conf = 0;
+
+
+ #endregion Private Fields
+
+ #region Private Properties
+
+ private string IdxMaccSel { get; set; } = "";
+
+ private int IdxOdl
+ {
+ get => RecMSE != null ? RecMSE.IdxOdl ?? 0 : 0;
+ }
+
+ private bool isProcessing { get; set; } = false;
+
+ #endregion Private Properties
+
+ #region Private Methods
+
+ private void checkAll()
+ {
+ checkConfProd();
+ }
+
+ private bool needConfProd = true;
+ ///
+ /// verifica se sia necessario confermare la produzione PRIMA di operare sull'ODL
+ ///
+ private void checkConfProd()
+ {
+ // verifica se sia necessario confermare produzione
+ int pz2conf = 0;
+#if false
+ DS_ProdTempi.stp_PzProd_getByMacchinaRow rigaProd;
+ try
+ {
+ rigaProd = DataLayerObj.taPzProd2conf.GetData(idxMacchinaFix)[0];
+ pz2conf = rigaProd.pezziNonConfermati;
+ needConfProd = (pz2conf > 0 && !isSlave);
+ }
+ catch (Exception exc)
+ {
+ logger.lg.scriviLog(string.Format("Errore recupero pezzi da confermare per la macchina {0}{1}{2}", idxMacchinaFix, Environment.NewLine, exc), tipoLog.ERROR);
+ }
+ // se necessario mostro warning...
+ if (needConfProd)
+ {
+ // SE mancasse ODL mostro info x poter caricare ODL retrodatato
+ if (odlOk)
+ {
+ lblWarningHead.Text = traduci("ConfProdBeforeContinueHead");
+ lblWarningBody.Text = traduci("ConfProdBeforeContinueBody");
+ lblNumPz2Conf.Text = string.Format("{0} pz NC", pz2conf);
+ }
+ else
+ {
+ lblWarningHead.Text = traduci("setOdlBeforeContinueHead");
+ lblWarningBody.Text = traduci("setOdlBeforeContinueBody");
+ lblNumPz2Conf.Text = string.Format("{0} pz NC", pz2conf);
+ }
+ }
+ divPz2Conf.Visible = needConfProd;
+ divWarn.Visible = needConfProd;
+ lbtFixOdl.Visible = !odlOk;
+ mod_ODL1.isEnabled = !needConfProd;
+#endif
+ }
+
+ #endregion Private Methods
+ }
+}
\ No newline at end of file
diff --git a/MP-TAB-SERV/Components/OdlProdFix.razor b/MP-TAB-SERV/Components/OdlProdFix.razor
deleted file mode 100644
index 68d8acf5..00000000
--- a/MP-TAB-SERV/Components/OdlProdFix.razor
+++ /dev/null
@@ -1,5 +0,0 @@
-OdlProdFix
-
-@code {
-
-}
diff --git a/MP-TAB-SERV/Components/OdlSetup.razor b/MP-TAB-SERV/Components/OdlSetup.razor
deleted file mode 100644
index 1bcfd3cf..00000000
--- a/MP-TAB-SERV/Components/OdlSetup.razor
+++ /dev/null
@@ -1,5 +0,0 @@
-OdlSetup
-
-@code {
-
-}
diff --git a/MP-TAB-SERV/Components/ProdConfirm.razor.cs b/MP-TAB-SERV/Components/ProdConfirm.razor.cs
index 3de7c130..0206570d 100644
--- a/MP-TAB-SERV/Components/ProdConfirm.razor.cs
+++ b/MP-TAB-SERV/Components/ProdConfirm.razor.cs
@@ -18,13 +18,13 @@ namespace MP_TAB_SERV.Components
/// registrato nuovo valore
///
[Parameter]
- public EventCallback> E_Updated { get; set; }
+ public EventCallback E_reset { get; set; }
///
- /// registrato nuovo valore
+ /// Post update restituisco nuova lista dati
///
[Parameter]
- public EventCallback E_reset { get; set; }
+ public EventCallback> E_Updated { get; set; }
///
/// Verifica ODL OK (ovvero caricato x macchina...)
@@ -39,42 +39,17 @@ namespace MP_TAB_SERV.Components
#endregion Public Properties
- #region Public Methods
-
- ///
- /// Aggiorno valori produzione alla data richiesta...
- ///
- ///
- public async Task doUpdate()
- {
- isProcessing = true;
- await Task.Delay(1);
- datiProdAct = await TabDServ.StatoProdMacchina(IdxMaccSel, dtReqUpdate);
- // aggiorno visualizzazione...
- numPzProdotti = datiProdAct.PzTotODL;
- numPz2Rec = datiProdAct.Pz2RecTot;
- numPzScaConf = datiProdAct.PzConfScarto;
- numPzBuoniConf = datiProdAct.PzConfBuoni;
- numPzProdotti2Rec = datiProdAct.Pz2RecTot;
- numPzScarto2Rec = datiProdAct.Pz2RecScarto;
- dtInizio = RecMSE?.DataInizioOdl ?? DateTime.Today.AddMonths(-2);
- dtFine = dtReqUpdate;
- isProcessing = false;
- await Task.Delay(1);
- }
-
- #endregion Public Methods
-
#region Protected Properties
+ protected string ConfBg
+ {
+ get => showInnov ? "bg-warning text-dark" : "bg-success text-light";
+ }
+
protected string ConfTitle
{
get => showInnov ? "Nascondi conferma" : "Mostra conferma";
}
- protected string ConfBg
- {
- get => showInnov ? "bg-warning text-dark" : "bg-success text-light";
- }
///
/// Dati produzioen rilevati
@@ -130,8 +105,11 @@ namespace MP_TAB_SERV.Components
}
protected int numPzProdotti { get; set; } = 0;
+
protected int numPzProdotti2Rec { get; set; } = 0;
+
protected int numPzScaConf { get; set; } = 0;
+
protected int numPzScarto2Rec { get; set; } = 0;
[Inject]
@@ -144,6 +122,28 @@ namespace MP_TAB_SERV.Components
#region Protected Methods
+ ///
+ /// Aggiorno valori produzione alla data richiesta...
+ ///
+ ///
+ protected async Task DoUpdate()
+ {
+ isProcessing = true;
+ await Task.Delay(1);
+ datiProdAct = await TabDServ.StatoProdMacchina(IdxMaccSel, dtReqUpdate);
+ // aggiorno visualizzazione...
+ numPzProdotti = datiProdAct.PzTotODL;
+ numPz2Rec = datiProdAct.Pz2RecTot;
+ numPzScaConf = datiProdAct.PzConfScarto;
+ numPzBuoniConf = datiProdAct.PzConfBuoni;
+ numPzProdotti2Rec = datiProdAct.Pz2RecTot;
+ numPzScarto2Rec = datiProdAct.Pz2RecScarto;
+ dtInizio = RecMSE?.DataInizioOdl ?? DateTime.Today.AddMonths(-2);
+ dtFine = dtReqUpdate;
+ isProcessing = false;
+ await Task.Delay(1);
+ }
+
protected override async Task OnInitializedAsync()
{
lblOut = "";
@@ -154,7 +154,7 @@ namespace MP_TAB_SERV.Components
enablePzProdLasciati = SMServ.GetConfBool("enablePzProdLasciati");
confRett = SMServ.GetConfBool("confRett");
modoConfProd = SMServ.GetConfInt("modoConfProd");
- await doUpdate();
+ await DoUpdate();
}
}
@@ -182,19 +182,12 @@ namespace MP_TAB_SERV.Components
// sollevo evento!
dtReqUpdate = DateTime.Now;
numPzLasciati = 0;
- await doUpdate();
+ await DoUpdate();
await Task.Delay(1);
await RefreshData();
isProcessing = false;
}
- private async Task RefreshData()
- {
- List ListMSE = await MDataService.MseGetAll(true);
- await MServ.SaveMse(ListMSE);
- await E_Updated.InvokeAsync(ListMSE);
- }
-
protected void setConfirmBtn(bool newVal)
{
showConfirm = newVal;
@@ -205,7 +198,7 @@ namespace MP_TAB_SERV.Components
isProcessing = true;
await Task.Delay(10);
IdxMaccSel = selIdxMacc;
- await doUpdate();
+ await DoUpdate();
isProcessing = false;
await Task.Delay(10);
}
@@ -224,8 +217,11 @@ namespace MP_TAB_SERV.Components
#region Private Fields
private bool confRett = false;
+
private bool enablePzProdLasciati = false;
+
private string lblOut = "";
+
private int modoConfProd = 0;
#endregion Private Fields
@@ -233,7 +229,9 @@ namespace MP_TAB_SERV.Components
#region Private Properties
private DateTime dtReqUpdate { get; set; } = DateTime.Now;
+
private string IdxMaccSel { get; set; } = "";
+
private bool isProcessing { get; set; } = false;
private int MatrOpr
@@ -242,6 +240,7 @@ namespace MP_TAB_SERV.Components
}
private int numPzLasc { get; set; } = 0;
+
private bool showConfirm { get; set; } = true;
private bool showInnov { get; set; } = false;
@@ -269,6 +268,13 @@ namespace MP_TAB_SERV.Components
return fatto;
}
+ private async Task RefreshData()
+ {
+ List ListMSE = await MDataService.MseGetAll(true);
+ await MServ.SaveMse(ListMSE);
+ await E_Updated.InvokeAsync(ListMSE);
+ }
+
#endregion Private Methods
#if false
diff --git a/MP-TAB-SERV/MP-TAB-SERV.csproj b/MP-TAB-SERV/MP-TAB-SERV.csproj
index 5ff33e17..e1aa2a2e 100644
--- a/MP-TAB-SERV/MP-TAB-SERV.csproj
+++ b/MP-TAB-SERV/MP-TAB-SERV.csproj
@@ -3,7 +3,7 @@
net6.0
enable
- 6.16.2310.2718
+ 6.16.2310.2719
enable
MP_TAB_SERV
diff --git a/MP-TAB-SERV/Pages/ODL.razor b/MP-TAB-SERV/Pages/ODL.razor
index 165cecf4..d3b5fa95 100644
--- a/MP-TAB-SERV/Pages/ODL.razor
+++ b/MP-TAB-SERV/Pages/ODL.razor
@@ -8,7 +8,5 @@
else
{
- @* *@
-
-
+
}
diff --git a/MP-TAB-SERV/Resources/ChangeLog.html b/MP-TAB-SERV/Resources/ChangeLog.html
index 5f764a72..242547f1 100644
--- a/MP-TAB-SERV/Resources/ChangeLog.html
+++ b/MP-TAB-SERV/Resources/ChangeLog.html
@@ -1,6 +1,6 @@
Modulo MAPOSPEC
- Versione: 6.16.2310.2718
+ Versione: 6.16.2310.2719
Note di rilascio:
-
diff --git a/MP-TAB-SERV/Resources/VersNum.txt b/MP-TAB-SERV/Resources/VersNum.txt
index b7770a1c..26fed1e0 100644
--- a/MP-TAB-SERV/Resources/VersNum.txt
+++ b/MP-TAB-SERV/Resources/VersNum.txt
@@ -1 +1 @@
-6.16.2310.2718
+6.16.2310.2719
diff --git a/MP-TAB-SERV/Resources/manifest.xml b/MP-TAB-SERV/Resources/manifest.xml
index 2ec1aad7..e584f333 100644
--- a/MP-TAB-SERV/Resources/manifest.xml
+++ b/MP-TAB-SERV/Resources/manifest.xml
@@ -1,6 +1,6 @@
-
- 6.16.2310.2718
+ 6.16.2310.2719
https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip
https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html
false