broke and fixed db at the same time

This commit is contained in:
2025-01-24 09:06:32 -06:00
parent 9892684ebc
commit b7aa576727
10 changed files with 7 additions and 519 deletions
+2 -2
View File
@@ -53,7 +53,7 @@ inventoryGroup.MapGet("", async (BarkContext db) =>
inventoryGroup.MapGet("/{id}", async (int id, BarkContext db) =>
{
var item = await db.Inventory
.Include(item => item.StatusId)
.Include(item => item.Status)
.FirstOrDefaultAsync(i => i.Id == id);
if (item == null)
@@ -75,7 +75,7 @@ inventoryGroup.MapPut("/{id}", async (int id, InventoryItems updatedItem, BarkCo
existingItem.Name = updatedItem.Name;
existingItem.Brand = updatedItem.Brand;
existingItem.SerialNumber = updatedItem.SerialNumber;
existingItem.StatusId = updatedItem.StatusId;
existingItem.Status = updatedItem.Status;
existingItem.RentalPrice = updatedItem.RentalPrice;
existingItem.ReplacementCost = updatedItem.ReplacementCost;
existingItem.Notes = updatedItem.Notes;