我的全局文件中有两条路线。propertydetails 的路线运行良好,但不适用于预订 我使用的链接是。知道为什么它不起作用
@Html.ActionLinkWithSpan("BookNow", "Create", "Booking", new {item.ProductId,item.ProductName},"gradient-button")
@Html.ActionLinkWithSpan("MoreDetails", "Index", "PropertyDetails", new {item.ProductId,item.ProductName},"")
routes.MapRoute(
"Booking",
"Book/{ProductId}/{ProductName}",
new { controller = "BookingController", action = "Create", ProductName = UrlParameter.Optional }
);
routes.MapRoute(
"PropertyDetails",
"Details/{ProductId}/{ProductName}",
new { controller = "PropertyDetails", action = "Index", ProductName = UrlParameter.Optional }
);