diff --git a/Lux.API/Lux.API.csproj b/Lux.API/Lux.API.csproj index bf579d19..cac0e4f9 100644 --- a/Lux.API/Lux.API.csproj +++ b/Lux.API/Lux.API.csproj @@ -4,7 +4,7 @@ net8.0 enable enable - 1.1.2604.2310 + 1.1.2604.2311 diff --git a/Lux.UI/Components/Compo/Warehouse/MatReqList.razor b/Lux.UI/Components/Compo/Warehouse/MatReqList.razor index 9f5ef4ab..12717dc1 100644 --- a/Lux.UI/Components/Compo/Warehouse/MatReqList.razor +++ b/Lux.UI/Components/Compo/Warehouse/MatReqList.razor @@ -2,14 +2,26 @@
- Fabbisogni Attivi + Fabbisogni
-
-
+
+
+
+ Ord + +
+
+
- +
diff --git a/Lux.UI/Components/Compo/Warehouse/MatReqList.razor.cs b/Lux.UI/Components/Compo/Warehouse/MatReqList.razor.cs index f888fda8..cde91848 100644 --- a/Lux.UI/Components/Compo/Warehouse/MatReqList.razor.cs +++ b/Lux.UI/Components/Compo/Warehouse/MatReqList.razor.cs @@ -29,6 +29,9 @@ namespace Lux.UI.Components.Compo.Warehouse private Dictionary> GroupDict = new(); private Dictionary> SelectDict = new(); + private List AvailOrdList = new(); + private List AvailOrdRowList = new(); + #endregion Private Fields @@ -58,7 +61,7 @@ namespace Lux.UI.Components.Compo.Warehouse // sistemo il dizionario selezioni if (SelectDict.ContainsKey(currData.GroupName)) { - if(currData.ListItemIds.Count > 0) + if (currData.ListItemIds.Count > 0) { SelectDict[currData.GroupName] = currData.ListItemIds; } @@ -76,35 +79,47 @@ namespace Lux.UI.Components.Compo.Warehouse private void UpdateDetail() { - if (string.IsNullOrEmpty(SearchVal)) + // calcolo liste ordini e righeOrd disponibili... + AvailOrdList = AllRecords.Select(x => x.OrderNav!.OrderCode).Distinct().ToList(); + AvailOrdRowList = AllRecords.Select(x => x.OrderRowNav!.OrderRowCode).Distinct().ToList(); + IEnumerable query = AllRecords; + + // filtro ordini + if (!string.IsNullOrEmpty(selOrd)) { - // calcolo dati derivati - GroupDict = AllRecords - .GroupBy(x => x.CodGroup) - .ToDictionary(g => g.Key, g => g.ToList()); + query = query.Where(x => x.OrderNav!.OrderCode == selOrd); } - else if(SearchVal.StartsWith("POR")) + + if (!string.IsNullOrEmpty(searchVal) && searchVal.Length >= 3) { - // calcolo dati derivati - GroupDict = AllRecords - .Where(x => x.OrderRowNav!.OrderRowCode.Equals(SearchVal, StringComparison.InvariantCultureIgnoreCase)) - .GroupBy(x => x.CodGroup) - .ToDictionary(g => g.Key, g => g.ToList()); - } - else if (SearchVal.StartsWith("PO")) - { - // calcolo dati derivati - GroupDict = AllRecords - .Where(x => x.OrderNav!.OrderCode.Equals(SearchVal, StringComparison.InvariantCultureIgnoreCase)) - .GroupBy(x => x.CodGroup) - .ToDictionary(g => g.Key, g => g.ToList()); + if (searchVal.StartsWith("POR")) + { + query = query.Where(x => x.OrderRowNav!.OrderRowCode.Equals(searchVal, StringComparison.OrdinalIgnoreCase)); + } + else if (searchVal.StartsWith("PO")) + { + query = query.Where(x => x.OrderNav!.OrderCode.Equals(searchVal, StringComparison.OrdinalIgnoreCase)); + } + else + { + query = query.Where(x => x.ItemCode.Contains(searchVal, StringComparison.OrdinalIgnoreCase) || (x.ItemID != null && x.ItemNav.Description.Contains(searchVal, StringComparison.OrdinalIgnoreCase))); + } } + // effettuo search + var searchRecords = query.ToList(); + + // calcolo dati derivati + GroupDict = searchRecords + .GroupBy(x => x.CodGroup) + .ToDictionary(g => g.Key, g => g.ToList()); } private void ResetSearch() { SearchVal = ""; } + private string selOrd = ""; + #endregion Private Methods } } \ No newline at end of file diff --git a/Lux.UI/Lux.UI.csproj b/Lux.UI/Lux.UI.csproj index d4e71e43..43d3193d 100644 --- a/Lux.UI/Lux.UI.csproj +++ b/Lux.UI/Lux.UI.csproj @@ -5,7 +5,7 @@ enable enable aspnet-Lux.UI-a758c101-a2f4-4e38-977d-1c4887dbbd50 - 1.1.2604.2310 + 1.1.2604.2311 diff --git a/Resources/ChangeLog.html b/Resources/ChangeLog.html index 21945449..1c764a1d 100644 --- a/Resources/ChangeLog.html +++ b/Resources/ChangeLog.html @@ -1,6 +1,6 @@ LUX - Web Windows MES -

Versione: 1.1.2604.2310

+

Versione: 1.1.2604.2311


Note di rilascio:
  • diff --git a/Resources/VersNum.txt b/Resources/VersNum.txt index d0f208bd..1ad1d005 100644 --- a/Resources/VersNum.txt +++ b/Resources/VersNum.txt @@ -1 +1 @@ -1.1.2604.2310 +1.1.2604.2311 diff --git a/Resources/manifest.xml b/Resources/manifest.xml index a15f0302..2907b935 100644 --- a/Resources/manifest.xml +++ b/Resources/manifest.xml @@ -1,6 +1,6 @@ - 1.1.2604.2310 + 1.1.2604.2311 http://nexus.steamware.net/repository/SWS/GPW/stable/GPW.UI.zip http://nexus.steamware.net/repository/SWS/GPW/stable/ChangeLog.html false