19073 allow plugins to be marked as hidden or disabled in plugins table (#19087)
* 19073 allow plugins to be marked as hidden or disabled in plugins table * 19073 allow plugins to be marked as hidden or disabled in plugins table * 19073 allow plugins to be marked as hidden or disabled in plugins table * 19073 review changes * Rename 'unlinked' to 'static' & update docs --------- Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
This commit is contained in:
@@ -109,6 +109,13 @@ def get_local_plugins(plugins=None):
|
||||
else:
|
||||
plugins[k] = v
|
||||
|
||||
# Update plugin table config for hidden and static plugins
|
||||
hidden = settings.PLUGINS_CATALOG_CONFIG.get('hidden', [])
|
||||
static = settings.PLUGINS_CATALOG_CONFIG.get('static', [])
|
||||
for k, v in plugins.items():
|
||||
v.hidden = k in hidden
|
||||
v.static = k in static
|
||||
|
||||
return plugins
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user