Revert "Revert "RBAC: remove dashboard ACL logic from dash store, service #78130" (#78203)

Revert "Revert "RBAC: remove dashboard ACL logic from dash store, service #78130 (#78198)"

This reverts commit 8057b9298d.
This commit is contained in:
Ieva
2023-11-15 16:45:49 +00:00
committed by GitHub
parent 210ec8247b
commit 2c73f15839
14 changed files with 27 additions and 926 deletions
@@ -1188,21 +1188,6 @@ func insertTestDashboardForPlugin(t *testing.T, dashboardStore dashboards.Store,
return dash
}
func updateDashboardACL(t *testing.T, dashboardStore dashboards.Store, dashboardID int64,
items ...dashboards.DashboardACL) error {
t.Helper()
var itemPtrs []*dashboards.DashboardACL
for _, it := range items {
item := it
item.Created = time.Now()
item.Updated = time.Now()
itemPtrs = append(itemPtrs, &item)
}
return dashboardStore.UpdateDashboardACL(context.Background(), dashboardID, itemPtrs)
}
// testSearchDashboards is a (near) copy of the dashboard service
// SearchDashboards, which is a wrapper around FindDashboards.
func testSearchDashboards(d dashboards.Store, query *dashboards.FindPersistedDashboardsQuery) (model.HitList, error) {