根目錄映射怎么寫,我這么寫只能調轉
app.UseEndpoints(endpoints =>
? ? ? ? ? ? {
? ? ? ? ? ? ? ? endpoints.Map("/", context =>
? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? context.Response.Redirect("Home/Index/");
? ? ? ? ? ? ? ? ? ? return Task.CompletedTask;
? ? ? ? ? ? ? ? });
? ? ? ? ? ? ? ? endpoints.MapControllerRoute(name: "default", pattern: "{controller=Home}/{action=Index}/{id?}");? ?
? ? ? ? ? ? });
2020-09-02
同問·?