@page "/admin/npcs/shops/edit" @model Npcs.ShopEditModel @using System.Text.Json @{ ViewData["Title"] = Model.IsNew ? "Create NPC Shop" : $"Edit Shop: {Model.Shop.Name}"; var itemCatalog = JsonSerializer.Serialize(Model.ItemDefinitions.Select(i => new { id = i.Id, name = i.Name, rarity = i.Rarity.ToString(), type = i.Type.ToString(), search = ($"{i.Name} {i.Rarity} {i.Type} {i.Id}").ToLowerInvariant() })); }
@(Model.IsNew ? "Create a slot-based shop inventory" : $"ID: {Model.Shop.Id}")
| Slot | Item | Qty | Price | Restock | Interval | Actions |
|---|---|---|---|---|---|---|
| @i.SlotIndex |
@i.ItemDefinition?.Name
ID: @i.ItemDefinitionId
|
@i.Quantity | @i.PriceGold | @(i.Restocks ? "Yes" : "No") | @i.RestockIntervalSeconds s |
|
| No slot items yet. | ||||||