AccessControl: Modify provisioning to prevent built-in role assignment (#48031)
* Add basic and managed prefixes to avoid magic strings For now let's stick with grafana_builtins add function isBasic to RoleDTO add function isBasic to Role Co-authored-by: Jguer <joao.guerreiro@grafana.com> * Add team store to wire Co-authored-by: Jguer <joao.guerreiro@grafana.com> Co-authored-by: Jguer <joao.guerreiro@grafana.com>
This commit is contained in:
@@ -253,6 +253,7 @@ var wireSet = wire.NewSet(
|
||||
wireBasicSet,
|
||||
sqlstore.ProvideService,
|
||||
wire.Bind(new(alerting.AlertStore), new(*sqlstore.SQLStore)),
|
||||
wire.Bind(new(sqlstore.TeamStore), new(*sqlstore.SQLStore)),
|
||||
ngmetrics.ProvideService,
|
||||
wire.Bind(new(notifications.TempUserStore), new(*sqlstore.SQLStore)),
|
||||
wire.Bind(new(notifications.Service), new(*notifications.NotificationService)),
|
||||
@@ -268,6 +269,7 @@ var wireTestSet = wire.NewSet(
|
||||
sqlstore.ProvideServiceForTests,
|
||||
ngmetrics.ProvideServiceForTest,
|
||||
wire.Bind(new(alerting.AlertStore), new(*sqlstore.SQLStore)),
|
||||
wire.Bind(new(sqlstore.TeamStore), new(*sqlstore.SQLStore)),
|
||||
|
||||
notifications.MockNotificationService,
|
||||
wire.Bind(new(notifications.TempUserStore), new(*mockstore.SQLStoreMock)),
|
||||
|
||||
Reference in New Issue
Block a user