如何在包含区域的 ASP.NET MVC 应用程序中将视图设置为域的主页。我需要一个特定区域的视图作为主页。怎么可能做到这一点?
我尝试使用以下代码但没有成功。
public static void RegisterRoutes(RouteCollection routes) {
routes.MapRoute(
name: "Home",
url: "",
defaults: new { controller = "Home", action = "Index" },
namespaces: new string[] { "WebApp.Areas.UI.Controllers" }
);
}