i am just working on a plugin for the NopCommerce 2.40 for MISC category and followed various articles about that.
I am done with the plugin (Include some table creation in database). Code for the RegisterRoute Function for newly created route
routes.MapRoute("Plugin.Admin.Course.Backend",
"Course/Admin/{action}/{id}",
new { controller = "CourseAdmin", action = "Index", id = "" },
new[] { "Nop.Plugin.Misc.CourseSystem.Controllers" }
).DataTokens.Add("Area", "Admin");
everything was ok until i try to implement the delete operation (as it always look for the /admin/CourseSystem/Delete/{ID} as i am doing it with the help of DeleteConfirmation from HTMLExtensions which adds a form inside a div with action="admin/courseAdmin/Delete/{Id}" so when we click on the Delete button) and there are other inbuild functionality get affected when we do this. Is there anyway we can register/call our Routes like admin/courseAdmin/{Action}/{Id}.
I tried to do it but still not able to get it working. Is there any way to get this working or should i have to inpliment the Delete functionality from scratch in plugin.
Any type of help will be appreciated.
thanks