mirror of
https://github.com/grafana/grafana.git
synced 2024-11-26 02:40:26 -06:00
Auth: Change UI route, add frontend endpoints to api.go (#80671)
Delete advanced from UI route, fix 404
This commit is contained in:
parent
4d6069583e
commit
6752a512f3
@ -107,7 +107,6 @@ func (hs *HTTPServer) registerRoutes() {
|
||||
r.Get("/admin/orgs", authorizeInOrg(ac.UseGlobalOrg, ac.OrgsAccessEvaluator), hs.Index)
|
||||
r.Get("/admin/orgs/edit/:id", authorizeInOrg(ac.UseGlobalOrg, ac.OrgsAccessEvaluator), hs.Index)
|
||||
r.Get("/admin/stats", authorize(ac.EvalPermission(ac.ActionServerStatsRead)), hs.Index)
|
||||
r.Get("/admin/authentication/ldap", authorize(ac.EvalPermission(ac.ActionLDAPStatusRead)), hs.Index)
|
||||
if hs.Features.IsEnabledGlobally(featuremgmt.FlagStorage) {
|
||||
r.Get("/admin/storage", reqSignedIn, hs.Index)
|
||||
r.Get("/admin/storage/*", reqSignedIn, hs.Index)
|
||||
@ -223,6 +222,11 @@ func (hs *HTTPServer) registerRoutes() {
|
||||
}
|
||||
|
||||
r.Get("/admin/authentication/", authorize(evalAuthenticationSettings()), hs.Index)
|
||||
r.Get("/admin/authentication/ldap", authorize(ac.EvalPermission(ac.ActionLDAPStatusRead)), hs.Index)
|
||||
if hs.Features.IsEnabledGlobally(featuremgmt.FlagSsoSettingsApi) {
|
||||
providerParam := ac.Parameter("provider")
|
||||
r.Get("/admin/authentication/:provider", authorize(ac.EvalPermission(ac.ActionSettingsRead, ac.ScopeSettingsOAuth(providerParam))), hs.Index)
|
||||
}
|
||||
|
||||
// authed api
|
||||
r.Group("/api", func(apiRoute routing.RouteRegister) {
|
||||
|
@ -288,7 +288,7 @@ export function getAppRoutes(): RouteDescriptor[] {
|
||||
: () => <Redirect to="/admin" />,
|
||||
},
|
||||
{
|
||||
path: '/admin/authentication/advanced/:provider',
|
||||
path: '/admin/authentication/:provider',
|
||||
roles: () => contextSrv.evaluatePermission([AccessControlAction.SettingsWrite]),
|
||||
component: config.featureToggles.ssoSettingsApi
|
||||
? SafeDynamicImport(
|
||||
|
Loading…
Reference in New Issue
Block a user