fix gestione lotto esterno

This commit is contained in:
zaccaria.majid
2022-12-13 11:28:01 +01:00
parent 5c39a67488
commit 6fbb3afc4d
+13 -9
View File
@@ -53,7 +53,8 @@ namespace MP.INVE.Components
protected ScanDataModel? alreadyScan;
protected AnagUdcModel? currUdc;
protected AnagLottoModel? currLotto;
protected AnagLottoModel? currLottoInterno;
protected AnagLottiArca? currLottoEsterno;
protected bool alertScan;
protected bool isScannedLotto;
protected bool firstMsg = false;
@@ -94,7 +95,7 @@ namespace MP.INVE.Components
}
alreadyScan = elencoScansioni.Where(x => x.ScanValue == lastScan).FirstOrDefault();
currUdc = null;
currLotto = null;
currLottoInterno = null;
}
}
@@ -133,7 +134,7 @@ namespace MP.INVE.Components
if (lottoInterno != null)
{
tipo = "LOTTO";
currLotto = lottoInterno;
currLottoInterno = lottoInterno;
lottoScan = lottoInterno.Lotto;
articoloScan = lottoInterno.CodArt;
quantitaScan = 0;
@@ -143,11 +144,14 @@ namespace MP.INVE.Components
if (lottoEsterno != null)
{
tipo = "LOTTO EXT";
currLottoEsterno = lottoEsterno;
lottoScan = lottoEsterno.Cd_ARLotto;
articoloScan = lottoEsterno.Cd_AR;
quantitaScan = 0;
}
else
{
currLotto = null;
currLottoInterno = null;
currUdc = null;
alreadyScan = null;
lottoScan = lastScan;
@@ -202,7 +206,7 @@ namespace MP.INVE.Components
await MIService.InsertNewScansione(newScan);
NavManager.NavigateTo(NavManager.Uri, true);
}
else if (currLotto != null)
else if (currLottoInterno != null)
{
ScanDataModel newScan = new ScanDataModel()
{
@@ -210,11 +214,11 @@ namespace MP.INVE.Components
UserScan = userScan,
ScanValue = lastScan,
IsForced = true,
CodArticolo = currLotto.CodArt,
Lotto = currLotto.Lotto,
RifExt = currLotto.RifExt,
CodArticolo = currLottoInterno.CodArt,
Lotto = currLottoInterno.Lotto,
RifExt = currLottoInterno.RifExt,
Qty = qtaLotto,
Note = currLotto.Note,
Note = currLottoInterno.Note,
IsKnown = true,
IsUnique = false,
InveSessID = sessID