Friday, 23 August 2013

Route pattern matches but desired action Method is not getting called - Orchard 1.7

Route pattern matches but desired action Method is not getting called -
Orchard 1.7

I have a set of questions each having several tags to it. Each tag is
clickable and supposed to filter the questions based on it.
I have a Route for the tag:
new RouteDescriptor
{
Priority = -29,
Route = new Route(
"questions/tagged/{tag}",
new RouteValueDictionary {
{"area","xxx.Intrust"},
{"controller","Question"},
{"action","DisplayByTag"},
{"tag", ""}
},
new RouteValueDictionary {
{"tag",@"\w*/*"}
},
new RouteValueDictionary{
{"area","xxx.Intrust"}
},
new MvcRouteHandler())
},
A typical Tag url looks like this:
http://local.intrustknowsbusiness.com/lendinng/questions/tagged/minimum%20opening%20deposit
But I am always getting 404 error.
I debugged the code, but no Action method in the controller (typically I
like to see "DisplayByTag" is being invoked) is called.
What wrong I am doing? My other Routes are working fine and corresponding
methods are also getting invoked as they should.
I am completely stuck. Please help!

No comments:

Post a Comment