From b7a989256f53d45e3361fa73d5516e05ae5c3450 Mon Sep 17 00:00:00 2001 From: Praburaj Date: Mon, 28 Apr 2014 18:02:21 -0700 Subject: [PATCH] Few changes with this checkin: 1. Enabling a work around to add an album to the store (Due to bug# https://github.com/aspnet/WebFx/issues/339) currently its not possible to create / edit an album in the store. 2. Removing a not necessary route from the webFx routes - A previous CR feedback. --- src/MusicStore/Controllers/StoreManagerController.cs | 6 ++++-- src/MusicStore/Startup.cs | 4 ---- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/src/MusicStore/Controllers/StoreManagerController.cs b/src/MusicStore/Controllers/StoreManagerController.cs index 8ee9353c8f..b69e7aee81 100644 --- a/src/MusicStore/Controllers/StoreManagerController.cs +++ b/src/MusicStore/Controllers/StoreManagerController.cs @@ -55,7 +55,8 @@ namespace MusicStore.Controllers // // GET: /StoreManager/Create - + //Bug: https://github.com/aspnet/WebFx/issues/339 + [HttpGet] public IActionResult Create() { ViewBag.GenreId = new SelectList(db.Genres, "GenreId", "Name"); @@ -81,7 +82,8 @@ namespace MusicStore.Controllers // // GET: /StoreManager/Edit/5 - + //Bug: https://github.com/aspnet/WebFx/issues/339 + [HttpGet] public IActionResult Edit(int id = 0) { Album album = db.Albums.Single(a => a.AlbumId == id); diff --git a/src/MusicStore/Startup.cs b/src/MusicStore/Startup.cs index 72aa5512d8..dc501f80c9 100644 --- a/src/MusicStore/Startup.cs +++ b/src/MusicStore/Startup.cs @@ -83,10 +83,6 @@ public class Startup routes.MapRoute( "{controller}/{action}", new { controller = "Home", action = "Index" }); - - routes.MapRoute( - "{controller}", - new { controller = "Home" }); }); SampleData.InitializeMusicStoreDatabaseAsync(app.ApplicationServices).Wait();