3
我使用nopCommmerce 3.40,MVC 5MVC路线返回错误:儿童的行为是不允许进行重定向操作
我必须做的插件,使路由一个路由的行动
但我得到错误的外观像:
Error executing child request for handler'System.Web.Mvc.HttpHandlerUtil+ServerExecuteHttpHandlerAsyncWrapper'.
Child actions are not allowed to perform redirect actions
我的代码
[AdminAuthorize]
public ActionResult Configure()
{
return RedirectToRoute("PluginName.ActionName");
}
public ActionResult ActionName()
{
// i want to call/ return this from Configure mathod
}
RouteProvider
routes.MapRoute("PluginName.ActionName", "Admin/Plugins",
new { controller = "Controller", action = "Action" },
new[] { "PluginName.ActionName.Controllers" }
).DataTokens.Add("area", "admin");