2016-09-08 17:25:45 +08:00
|
|
|
package dtos
|
|
|
|
|
|
|
|
import "github.com/grafana/grafana/pkg/components/simplejson"
|
|
|
|
|
|
|
|
type Annotation struct {
|
2016-09-09 17:30:55 +08:00
|
|
|
AlertId int64 `json:"alertId"`
|
|
|
|
DashboardId int64 `json:"dashboardId"`
|
|
|
|
PanelId int64 `json:"panelId"`
|
|
|
|
NewState string `json:"newState"`
|
|
|
|
PrevState string `json:"prevState"`
|
|
|
|
Time int64 `json:"time"`
|
|
|
|
Title string `json:"title"`
|
|
|
|
Text string `json:"text"`
|
|
|
|
Metric string `json:"metric"`
|
2017-04-12 22:26:34 +08:00
|
|
|
RegionId int64 `json:"regionId"`
|
2017-05-22 19:02:19 +08:00
|
|
|
Type string `json:"type"`
|
2016-09-08 17:25:45 +08:00
|
|
|
|
|
|
|
Data *simplejson.Json `json:"data"`
|
|
|
|
}
|
2016-10-14 15:33:16 +08:00
|
|
|
|
2017-04-11 01:22:58 +08:00
|
|
|
type PostAnnotationsCmd struct {
|
|
|
|
DashboardId int64 `json:"dashboardId"`
|
|
|
|
PanelId int64 `json:"panelId"`
|
2017-04-12 21:46:41 +08:00
|
|
|
CategoryId int64 `json:"categoryId"`
|
2017-04-11 01:22:58 +08:00
|
|
|
Time int64 `json:"time"`
|
|
|
|
Title string `json:"title"`
|
|
|
|
Text string `json:"text"`
|
2017-04-12 22:26:34 +08:00
|
|
|
|
|
|
|
FillColor string `json:"fillColor"`
|
|
|
|
IsRegion bool `json:"isRegion"`
|
2017-04-14 17:41:02 +08:00
|
|
|
TimeEnd int64 `json:"timeEnd"`
|
2017-04-11 01:22:58 +08:00
|
|
|
}
|
|
|
|
|
2016-10-14 15:33:16 +08:00
|
|
|
type DeleteAnnotationsCmd struct {
|
|
|
|
AlertId int64 `json:"alertId"`
|
|
|
|
DashboardId int64 `json:"dashboardId"`
|
|
|
|
PanelId int64 `json:"panelId"`
|
|
|
|
}
|