plugin with public store custom view getting page not found

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
6 years ago
I'm trying to add a custom page to the menu items using the mega menu from nop-templates's custom links.
this is my mapping for the route


            
routes.MapRoute("Plugin.interactions.Journal.PondCalculator",
                "Plugins/PondCalculator",
                new { controller = "JournalController", action = "PondCalculator" },
                new[] { "Nop.Plugin.Interactions.Journal.Controllers" }
            );


this is the method in the controller that does not get hit
        
public ActionResult PondCalculator()
        {
            return View("pond-calculator");
        }


in the mega menu item i have the Url set to Plugins/PondCalculator.

is there something else i need to do to make this view viable to the public store side of nop?
6 years ago
Hello Daniel,

You need to extend view engine context in your plugin.

Or another way is pass full path of your view in return View.
like
return View("~/Plugins/interactions.Journal.PondCalculator/Views/Journal/pond-calculator.cshtml");


It'll work.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.