diff --git a/src/PowderCoating.Web/Controllers/JobsController.cs b/src/PowderCoating.Web/Controllers/JobsController.cs index 536df6a..b7f9840 100644 --- a/src/PowderCoating.Web/Controllers/JobsController.cs +++ b/src/PowderCoating.Web/Controllers/JobsController.cs @@ -501,7 +501,7 @@ public class JobsController : Controller // Inventory items for the manual log-material modal var inventoryItemsForModal = (await _unitOfWork.InventoryItems.GetAllAsync()) .OrderBy(i => i.Name) - .Select(i => new { i.Id, i.Name, i.UnitOfMeasure, i.QuantityOnHand }) + .Select(i => new { i.Id, i.Name, i.Manufacturer, i.UnitOfMeasure, i.QuantityOnHand }) .ToList(); ViewBag.InventoryItemsForModal = System.Text.Json.JsonSerializer.Serialize( inventoryItemsForModal, diff --git a/src/PowderCoating.Web/Views/Jobs/Details.cshtml b/src/PowderCoating.Web/Views/Jobs/Details.cshtml index 58da562..87746fd 100644 --- a/src/PowderCoating.Web/Views/Jobs/Details.cshtml +++ b/src/PowderCoating.Web/Views/Jobs/Details.cshtml @@ -1108,7 +1108,7 @@
diff --git a/src/PowderCoating.Web/wwwroot/js/log-material.js b/src/PowderCoating.Web/wwwroot/js/log-material.js index 7cc506a..e4c1b1c 100644 --- a/src/PowderCoating.Web/wwwroot/js/log-material.js +++ b/src/PowderCoating.Web/wwwroot/js/log-material.js @@ -40,6 +40,7 @@ if (!dd) return; const filtered = query ? _items.filter(it => it.name.toLowerCase().includes(query) || + (it.manufacturer && it.manufacturer.toLowerCase().includes(query)) || (it.unitOfMeasure && it.unitOfMeasure.toLowerCase().includes(query))) : _items; if (filtered.length === 0) { @@ -48,6 +49,7 @@ } dd.innerHTML = filtered.map(it => { const label = it.name + (it.unitOfMeasure ? ' (' + it.unitOfMeasure + ')' : ''); + const mfr = it.manufacturer ? `${escLm(it.manufacturer)}` : ''; return `
- ${escLm(label)} + ${escLm(label)}${mfr}
`; }).join(''); }