diff --git a/Controllers/BundleController.cs b/Controllers/BundleController.cs index 8e72dd3..fe52a6e 100644 --- a/Controllers/BundleController.cs +++ b/Controllers/BundleController.cs @@ -8,7 +8,6 @@ namespace MyDarling.Controllers public class BundleController : Controller { private DataContext context; - public bool TryUpdateModel { get; private set; } public BundleController(DataContext context) { @@ -46,7 +45,7 @@ namespace MyDarling.Controllers public async Task Details(int id) { - return View(await context.UnderwearBundles.FindAsync(id)); + return View(await context.UnderwearBundles.Include(b => b.Figures).Where(b => b.Id == id).FirstOrDefaultAsync()); } public async Task Edit(int id) @@ -71,7 +70,7 @@ namespace MyDarling.Controllers if (await TryUpdateModelAsync( bundle, "", - b => b.Name, b => b.Description, b => b.Price)) + b => b.Name, b => b.Description, b => b.Figures, b => b.Price)) { try {