Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-09-07 21:08:32 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-09-07 21:08:32 +0300
commitdff0f3475c8dc49daccb1f9fd2399b881e6cc1f0 (patch)
treef61feff669dfa72bb8f03e8c3d0d38df45be5263 /config
parentcf24d183b3f71f091a02f12b211f3001be5b5085 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'config')
-rw-r--r--config/routes/project.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/config/routes/project.rb b/config/routes/project.rb
index 4ba1f14222e..3361193581e 100644
--- a/config/routes/project.rb
+++ b/config/routes/project.rb
@@ -25,7 +25,10 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
# Use this scope for all new project routes.
scope '-' do
get 'archive/*id', constraints: { format: Gitlab::PathRegex.archive_formats_regex, id: /.+?/ }, to: 'repositories#archive', as: 'archive'
- get 'metrics(/:dashboard_path)(/:page)', constraints: { dashboard_path: /.+\.yml/, page: 'panel/new' },
+ # Since the page parameter can contain slashes (panel/new), use Rails'
+ # "Route Globbing" syntax (/*page) so that the route helpers do not encode
+ # the slash character.
+ get 'metrics(/:dashboard_path)(/*page)', constraints: { dashboard_path: /.+\.yml/, page: 'panel/new' },
to: 'metrics_dashboard#show', as: :metrics_dashboard, format: false
namespace :metrics, module: :metrics do