hijacked route, so all I have controllers for all my views the same as in regular mvc
strong typed view models each Umbraco.Web.Mvc.RenderMvcController has its own custom strong typed modelview
virtualNodes I have a tree in which I have a node just to gather together goods, like this home - goodsCategory - category1, category2 etc..., so in order for a path not be shown like www.mysite.com/goodsCategory/category1, but just as www.mysite.com/category1 I use virtualNodes for umbraco, so when I publish my item the link does not include /goodsCategory/ path.
custom route because by using virtualNodes and hijacked route I destroyed maproute, so I need to create one, no problem, I created the one.
the problem
after creating custom route, my controller is hit, but the problem is because I destroyed umbraco path for request, my controller does not get any currentContext and I got an error
So how to handle this issue? I cannot cancel any of the mentioned above technics because I need all of them (strong typed view model + hijacked route + custom route + virtualNodes)
1) Create route handler which will look for a needed object in DB/cache by using URL segment, and then will pass that object to route for injecting into a controller.
2) In hijacked routes need to add route handler, so when route fires, then route handler inject model for the view.
strong typed view model + hijacked route + custom route + virtualNodes
Hello, guys! So my situation:
the problem
after creating custom route, my controller is hit, but the problem is because I destroyed umbraco path for request, my controller does not get any currentContext and I got an error
So how to handle this issue? I cannot cancel any of the mentioned above technics because I need all of them (strong typed view model + hijacked route + custom route + virtualNodes)
Well, the solution is this:
1) Create route handler which will look for a needed object in DB/cache by using URL segment, and then will pass that object to route for injecting into a controller. 2) In hijacked routes need to add route handler, so when route fires, then route handler inject model for the view.
is working on a reply...