Orchard Modules

Topics: Administration, General
Dec 11, 2013 at 8:12 AM
I need to develop a module which has multiple tabs or links inside for different purposes. lets say first tab says Product List which is when clicked shows a list of products and here i can have button at top to create new product and option to edit existing one. Similarly second tabs shows some other features. How can i manage this to add to on module in Orchard?
Dec 11, 2013 at 8:30 AM
You will do these things in Admin dashboard, right? Then you can handle the navigation by implementing a INavigationProvider. For tabs, use LocalNav() calls. It's decribed here: http://docs.orchardproject.net/Documentation/adding-admin-menu-items

LocalNav tabs will be rendered by the admin theme, so you won't need to deal with them. Inside tabs, you will be calling your MVC controller actions as described by you implemetation of INavigationProvider. So you need to design your actions/controllers the way you want to seperate what to be displayed in tabs.


Dec 11, 2013 at 8:43 AM
Edited Dec 11, 2013 at 8:48 AM
Is that necessary to develop a module here? can this be done by creating pages just we normally do in ASP.NET MVC web applications. i mean if i don't want to have these inside admin dashboard instead i want link next to dashboard on home page which is then linked to this area. Refering back to your reply, can you provide me some sample code or links which is similar to what i am trying to achieve.
Dec 11, 2013 at 9:14 AM
To make make it work with Orchard, yes, necessary. For this scenario, there is not much overhead, once you try you will see. Just put the controllers and views and everything else in the correct place as you do int plain MVC in a module folder, which will serve as a MVC controller. Code Generation module can be used to create the module essentials for you.

Why do you want to do it otherwise? What part of module development you don't want to deal with?


Marked as answer by mrhammad on 12/11/2013 at 1:46 AM
Dec 11, 2013 at 9:29 AM
i think i got the answer which is i need to follow module development in order to achieve the goal. Can you send me some useful link related to my scenario. Many thanks for guidance.
Dec 11, 2013 at 9:47 AM
Glad I could help. Here, and in other parts of the series of posts many things are explained well: http://skywalkersoftwaredevelopment.net/blog/writing-an-orchard-webshop-module-from-scratch-part-10


Dec 11, 2013 at 12:54 PM
I download the source code from the above link and i am having various library errors i think this is written for old version

error: cant find Orchard.Users.Models;
Dec 11, 2013 at 1:23 PM
The code there is not up to date as far as I know. This particular problem can be solved by adding a reference to Orchard.Users module in the module project I think.