Dashboard: Redirects for old edit & view panel urls (#25653)
This commit is contained in:
+3
-2
@@ -18,6 +18,7 @@ func (hs *HTTPServer) registerRoutes() {
|
||||
reqSnapshotPublicModeOrSignedIn := middleware.SnapshotPublicModeOrSignedIn()
|
||||
redirectFromLegacyDashboardURL := middleware.RedirectFromLegacyDashboardURL()
|
||||
redirectFromLegacyDashboardSoloURL := middleware.RedirectFromLegacyDashboardSoloURL()
|
||||
redirectFromLegacyPanelEditURL := middleware.RedirectFromLegacyPanelEditURL()
|
||||
quota := middleware.Quota(hs.QuotaService)
|
||||
bind := binding.Bind
|
||||
|
||||
@@ -65,8 +66,8 @@ func (hs *HTTPServer) registerRoutes() {
|
||||
r.Get("/plugins/:id/page/:page", reqSignedIn, hs.Index)
|
||||
r.Get("/a/:id/*", reqSignedIn, hs.Index) // App Root Page
|
||||
|
||||
r.Get("/d/:uid/:slug", reqSignedIn, hs.Index)
|
||||
r.Get("/d/:uid", reqSignedIn, hs.Index)
|
||||
r.Get("/d/:uid/:slug", reqSignedIn, redirectFromLegacyPanelEditURL, hs.Index)
|
||||
r.Get("/d/:uid", reqSignedIn, redirectFromLegacyPanelEditURL, hs.Index)
|
||||
r.Get("/dashboard/db/:slug", reqSignedIn, redirectFromLegacyDashboardURL, hs.Index)
|
||||
r.Get("/dashboard/script/*", reqSignedIn, hs.Index)
|
||||
r.Get("/dashboard-solo/snapshot/*", hs.Index)
|
||||
|
||||
Reference in New Issue
Block a user