diff --git a/WebfrontCore/Controllers/HomeController.cs b/WebfrontCore/Controllers/HomeController.cs index 35674695..54e095ca 100644 --- a/WebfrontCore/Controllers/HomeController.cs +++ b/WebfrontCore/Controllers/HomeController.cs @@ -52,16 +52,20 @@ namespace WebfrontCore.Controllers public IActionResult Help() { ViewBag.IsFluid = true; + ViewBag.Title = Localization["WEBFRONT_NAV_HELP"]; + + // we don't need to the name of the shared library assembly var excludedAssembly = typeof(BaseController).Assembly; var commands = Manager.GetCommands() + .Where(_cmd => _cmd.Permission <= Client.Level) .OrderByDescending(_cmd => _cmd.Permission) .GroupBy(_cmd => { - + // we need the plugin type the command is defined in var pluginType = _cmd.GetType().Assembly.GetTypes().FirstOrDefault(_type => _type.Assembly != excludedAssembly && typeof(IPlugin).IsAssignableFrom(_type)); return pluginType == null ? - Utilities.CurrentLocalization.LocalizationIndex["WEBFRONT_HELP_COMMAND_NATIVE"] : - SharedLibraryCore.Plugins.PluginImporter.ActivePlugins.First(_plugin => _plugin.GetType() == pluginType).Name; + Utilities.CurrentLocalization.LocalizationIndex["WEBFRONT_HELP_COMMAND_NATIVE"] : + SharedLibraryCore.Plugins.PluginImporter.ActivePlugins.First(_plugin => _plugin.GetType() == pluginType).Name; // for now we're just returning the name of the plugin, maybe later we'll include more info }) .Select(_grp => (_grp.Key, _grp.AsEnumerable())); diff --git a/WebfrontCore/Views/Home/Help.cshtml b/WebfrontCore/Views/Home/Help.cshtml index 9270fcf3..5c3a25ab 100644 --- a/WebfrontCore/Views/Home/Help.cshtml +++ b/WebfrontCore/Views/Home/Help.cshtml @@ -4,12 +4,12 @@ } @foreach ((var pluginName, var commandList) in Model) { -
@loc["WEBFRONT_HELP_COMMAND_DESC_NAME"] | @loc["WEBFRONT_HELP_COMMAND_DESC_ALIAS"] | @loc["WEBFRONT_HELP_COMMAND_DESC_DESCRIPTION"] | @@ -71,5 +71,4 @@ }
---|