From 5ef72775213884f427e170ab6cc960f9544ae6cc Mon Sep 17 00:00:00 2001 From: Joram Wilander Date: Wed, 8 Nov 2017 11:39:30 -0500 Subject: PLT-7709 Add UI settings to plugin manifest (#7794) * Add UI settings to plugin manifest * Add another test case * Add options field to setting * Updates per feedback * Report diagnostics on if plugins have settings set * Add regenerate_help_text field --- app/diagnostics.go | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'app/diagnostics.go') diff --git a/app/diagnostics.go b/app/diagnostics.go index b74af8914..18a54e484 100644 --- a/app/diagnostics.go +++ b/app/diagnostics.go @@ -499,6 +499,7 @@ func (a *App) trackPlugins() { totalInactiveCount := -1 // -1 to indicate disabled or error webappInactiveCount := 0 backendInactiveCount := 0 + settingsCount := 0 plugins, _ := a.GetPluginManifests() @@ -513,6 +514,10 @@ func (a *App) trackPlugins() { if plugin.Backend != nil { backendActiveCount += 1 } + + if plugin.SettingsSchema != nil { + settingsCount += 1 + } } totalInactiveCount = len(plugins.Inactive) @@ -525,6 +530,10 @@ func (a *App) trackPlugins() { if plugin.Backend != nil { backendInactiveCount += 1 } + + if plugin.SettingsSchema != nil { + settingsCount += 1 + } } } @@ -535,6 +544,7 @@ func (a *App) trackPlugins() { "inactive_plugins": totalInactiveCount, "inactive_webapp_plugins": webappInactiveCount, "inactive_backend_plugins": backendInactiveCount, + "plugins_with_settings": settingsCount, }) } } -- cgit v1.2.3-1-g7c22