mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Major refactorings around searching, moved to seperate package, trying to move stuff out of models package, extend search support searching different types of entities and different types of dashboards, #960
This commit is contained in:
@@ -126,3 +126,13 @@ type GetDashboardQuery struct {
|
||||
|
||||
Result *Dashboard
|
||||
}
|
||||
|
||||
type DashboardTagCloudItem struct {
|
||||
Term string `json:"term"`
|
||||
Count int `json:"count"`
|
||||
}
|
||||
|
||||
type GetDashboardTagsQuery struct {
|
||||
OrgId int64
|
||||
Result []*DashboardTagCloudItem
|
||||
}
|
||||
|
||||
@@ -1,12 +1,6 @@
|
||||
package models
|
||||
|
||||
type SearchResult struct {
|
||||
Dashboards []*DashboardSearchHit `json:"dashboards"`
|
||||
Tags []*DashboardTagCloudItem `json:"tags"`
|
||||
TagsOnly bool `json:"tagsOnly"`
|
||||
}
|
||||
|
||||
type DashboardSearchHit struct {
|
||||
type SearchHit struct {
|
||||
Id int64 `json:"id"`
|
||||
Title string `json:"title"`
|
||||
Uri string `json:"uri"`
|
||||
@@ -14,24 +8,3 @@ type DashboardSearchHit struct {
|
||||
Tags []string `json:"tags"`
|
||||
IsStarred bool `json:"isStarred"`
|
||||
}
|
||||
|
||||
type DashboardTagCloudItem struct {
|
||||
Term string `json:"term"`
|
||||
Count int `json:"count"`
|
||||
}
|
||||
|
||||
type SearchDashboardsQuery struct {
|
||||
Title string
|
||||
Tag string
|
||||
OrgId int64
|
||||
UserId int64
|
||||
Limit int
|
||||
IsStarred bool
|
||||
|
||||
Result []*DashboardSearchHit
|
||||
}
|
||||
|
||||
type GetDashboardTagsQuery struct {
|
||||
OrgId int64
|
||||
Result []*DashboardTagCloudItem
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user