Admin Plugins and Widgets

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
11 лет назад
Hello all,

I’m currently using nopCommerce 2.65 and I have a few questions (more like clarifications) regarding plugins and Admin plugins.

Question 1)
I’ve noticed that there is two plugins folder.
One is located at: Presentation\Nop.Web\Plugins
And the other is located at: Presentation\Nop.Web\Administration\Plugins

To the untrained eye, one could easily assume that plugins that are (and will be used) by the frontend should live inside the: Presentation\Nop.Web\Plugins folder and plugins that are (and will be used) by the backend (administration section) should live inside the: Presentation\Nop.Web\Administration\Plugins

Is this assumption TRUE or FALSE?
Is this assumption IRRELEVANT?
Should ALL plugins (regardless of being for the frontend or the backend) ONLY live inside the:
Presentation\Nop.Web\Plugins

Question 2)
Assuming I have an Admin plugin (only being used by the backend). If I wish to the view my plugin from the Admin menu section, I have two options:

Option 1) manually modify the sitemap.config file and hardcode my menu item where I want.
Option 2) make my plugin implement IAdminMenuPlugin but I will have no control on where my new menu item will be displayed inside the Admin menu.

Is this correct?

Question 3)
Is it possible to create widgets for the backend (administration section) ?

Thanks in advance for any clarification.
Sincerely
11 лет назад
Vlince wrote:
Hello all,

I’m currently using nopCommerce 2.65 and I have a few questions (more like clarifications) regarding plugins and Admin plugins.

Question 1)
I’ve noticed that there is two plugins folder.
One is located at: Presentation\Nop.Web\Plugins
And the other is located at: Presentation\Nop.Web\Administration\Plugins

To the untrained eye, one could easily assume that plugins that are (and will be used) by the frontend should live inside the: Presentation\Nop.Web\Plugins folder and plugins that are (and will be used) by the backend (administration section) should live inside the: Presentation\Nop.Web\Administration\Plugins

Is this assumption TRUE or FALSE?
Is this assumption IRRELEVANT?
Should ALL plugins (regardless of being for the frontend or the backend) ONLY live inside the:
Presentation\Nop.Web\Plugins

Question 2)
Assuming I have an Admin plugin (only being used by the backend). If I wish to the view my plugin from the Admin menu section, I have two options:

Option 1) manually modify the sitemap.config file and hardcode my menu item where I want.
Option 2) make my plugin implement IAdminMenuPlugin but I will have no control on where my new menu item will be displayed inside the Admin menu.

Is this correct?

Question 3)
Is it possible to create widgets for the backend (administration section) ?

Thanks in advance for any clarification.
Sincerely


Hi,

1. No. Don't care about the plugin folder in the administration folder. Just put your plugin under the Nop.Web. :)

2. I would say so. I have not tried to specify the position of an Admin menu item, and a look at the API doesn't provide any clue on this.

3. You can, but there is not much Widget Zones in the admin. Do a search of '@Html.Widget(' in the Nop.Admin project and you'll see the available zones.

:)
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.