mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
feat: Introduce IsDataPanel attribute to plugin.json
This commit is contained in:
@@ -145,6 +145,7 @@ func (hs *HTTPServer) getFrontendSettingsMap(c *m.ReqContext) (map[string]interf
|
||||
"info": panel.Info,
|
||||
"hideFromList": panel.HideFromList,
|
||||
"sort": getPanelSort(panel.Id),
|
||||
"isDataPanel": panel.IsDataPanel,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -47,6 +47,7 @@ type PluginBase struct {
|
||||
BaseUrl string `json:"baseUrl"`
|
||||
HideFromList bool `json:"hideFromList,omitempty"`
|
||||
State PluginState `json:"state,omitempty"`
|
||||
IsDataPanel bool `json:"isDataPanel"`
|
||||
|
||||
IncludedInAppId string `json:"-"`
|
||||
PluginDir string `json:"-"`
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
"type": "panel",
|
||||
"name": "Gauge",
|
||||
"id": "gauge",
|
||||
"isDataPanel": true,
|
||||
|
||||
"info": {
|
||||
"author": {
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"type": "panel",
|
||||
"name": "React Graph",
|
||||
"id": "graph2",
|
||||
|
||||
"isDataPanel": true,
|
||||
"state": "alpha",
|
||||
|
||||
"info": {
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
"type": "panel",
|
||||
"name": "Text v2",
|
||||
"id": "text2",
|
||||
|
||||
"state": "alpha",
|
||||
"isDataPanel": false,
|
||||
|
||||
"info": {
|
||||
"author": {
|
||||
|
||||
@@ -9,6 +9,7 @@ export interface PanelPlugin {
|
||||
info: any;
|
||||
sort: number;
|
||||
exports?: PluginExports;
|
||||
isDataPanel?: boolean;
|
||||
}
|
||||
|
||||
export interface Plugin {
|
||||
|
||||
Reference in New Issue
Block a user