* Bugfixes

This commit is contained in:
2025-06-17 22:17:03 +02:00
parent 30d2984add
commit 52439e73cb

View File

@@ -100,10 +100,6 @@
<p>Błąd: Nie Wszystkie linie mają wypełniony <b>NUMER PALETY</b>.<br/>Packing List nie zostanie <p>Błąd: Nie Wszystkie linie mają wypełniony <b>NUMER PALETY</b>.<br/>Packing List nie zostanie
wygenerowany!</p> wygenerowany!</p>
} }
else if (!_notValidatedNumber)
{
<p>Błąd: Proszę zeskanować poprawny Numer Partii SL (istniejący w tabeli) lub poprawny numer Partii Meyle zaczynający się od <b>@($"{DateTime.Now.Year - 2001}X")</b>!</p>
}
</Content> </Content>
</DialogTemplates> </DialogTemplates>
<DialogButtons> <DialogButtons>
@@ -141,7 +137,6 @@
private WzRowMeyleDto? SelectedRow { get; set; } private WzRowMeyleDto? SelectedRow { get; set; }
private bool _isValid; private bool _isValid;
private bool _notValidatedNumber;
private bool Visibility { get; set; } private bool Visibility { get; set; }
private bool VisibilityValidation { get; set; } private bool VisibilityValidation { get; set; }
@@ -217,8 +212,6 @@
private async Task ScanValue(ChangedEventArgs obj) private async Task ScanValue(ChangedEventArgs obj)
{ {
_notValidatedNumber = false;
if (string.IsNullOrWhiteSpace(obj.Value)) return; if (string.IsNullOrWhiteSpace(obj.Value)) return;
TransactionModelsByPartNumber.TryGetValue(obj.Value.Trim(), out List<TransactionModel>? materialTransactionsByPartNumber); TransactionModelsByPartNumber.TryGetValue(obj.Value.Trim(), out List<TransactionModel>? materialTransactionsByPartNumber);
@@ -228,7 +221,18 @@
if (materialTransactionByPartNumber != null) if (materialTransactionByPartNumber != null)
{ {
var rowIndex = WzRowsMeyle.FindIndex(x => x.FaIndex == materialTransactionByPartNumber.ItemNumber && x.Quantity == materialTransactionByPartNumber.Quantity); var rowIndex = WzRowsMeyle.FindIndex(x => x.FaIndex == materialTransactionByPartNumber.ItemNumber && x.Quantity == materialTransactionByPartNumber.Quantity);
rowIndex = WzRowsMeyle.FindIndex(x => x.FaIndex == "FA23956.18" && x.Quantity == 130); //rowIndex = WzRowsMeyle.FindIndex(x => x.FaIndex == "FA23956.18" && x.Quantity == 130);
if (rowIndex == -1)
{
VisibilityValidation = true;
LastScannedValue = ScannedValue;
ScannedValue = string.Empty;
await _scanner.FocusAsync();
return;
}
SelectedRow = WzRowsMeyle[rowIndex]; SelectedRow = WzRowsMeyle[rowIndex];
@@ -275,7 +279,6 @@
} }
else else
{ {
_notValidatedNumber = true;
VisibilityValidation = true; VisibilityValidation = true;
ScannedValue = obj.Value.Trim(); ScannedValue = obj.Value.Trim();