add pluginBundle support

A plugnBundle is meta plugin that has a set of dependent plugins
to enable.  This commit includes a plugin.json for a default
"core" bundle that enables all of the shipped panels and datasources.
This commit is contained in:
woodsaj
2015-12-03 15:52:37 +08:00
parent fd392a2422
commit bd4cb549d6
7 changed files with 107 additions and 10 deletions
+4 -1
View File
@@ -62,7 +62,10 @@ func setIndexViewData(c *middleware.Context) (*dtos.IndexViewData, error) {
})
}
for _, plugin := range plugins.ExternalPlugins {
//TODO(awoods): query DB to get list of the users plugin preferences.
orgPlugins := map[string]m.PluginBundle{}
enabledPlugins := plugins.GetEnabledPlugins(orgPlugins)
for _, plugin := range enabledPlugins.ExternalPlugins {
for _, js := range plugin.Js {
data.PluginJs = append(data.PluginJs, js.Module)
}