diff --git a/InvenTree/plugin/templatetags/plugin_extras.py b/InvenTree/plugin/templatetags/plugin_extras.py index e1043a9aa0..f9557c84ff 100644 --- a/InvenTree/plugin/templatetags/plugin_extras.py +++ b/InvenTree/plugin/templatetags/plugin_extras.py @@ -15,31 +15,41 @@ register = template.Library() @register.simple_tag() def plugin_list(*args, **kwargs): - """ Return a list of all installed integration plugins """ + """ + List of all installed integration plugins + """ return registry.plugins @register.simple_tag() def inactive_plugin_list(*args, **kwargs): - """ Return a list of all inactive integration plugins """ + """ + List of all inactive integration plugins + """ return registry.plugins_inactive @register.simple_tag() def plugin_settings(plugin, *args, **kwargs): - """ Return a list of all custom settings for a plugin """ + """ + List of all settings for the plugin + """ return registry.mixins_settings.get(plugin) @register.simple_tag() def mixin_enabled(plugin, key, *args, **kwargs): - """ Return if the mixin is existant and configured in the plugin """ + """ + Is the mixin registerd and configured in the plugin? + """ return plugin.mixin_enabled(key) @register.simple_tag() def navigation_enabled(*args, **kwargs): - """Return if plugin navigation is enabled""" + """ + Is plugin navigation enabled? + """ if djangosettings.PLUGIN_TESTING: return True return InvenTreeSetting.get_setting('ENABLE_PLUGINS_NAVIGATION') @@ -47,7 +57,10 @@ def navigation_enabled(*args, **kwargs): @register.simple_tag() def safe_url(view_name, *args, **kwargs): - """ safe lookup for urls """ + """ + Safe lookup fnc for URLs + Returns None if not found + """ try: return reverse(view_name, args=args, kwargs=kwargs) except: @@ -56,5 +69,7 @@ def safe_url(view_name, *args, **kwargs): @register.simple_tag() def plugin_errors(*args, **kwargs): - """Return all plugin errors""" + """ + All plugin errors in the current session + """ return registry.errors