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:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2014-07-23 13:03:49 +0400
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2014-07-23 13:03:49 +0400
commit367445fdcde4d07a685610449a2ab4d43b1fc507 (patch)
tree5d720c3c76c02fe8539e5bdaca64f76a5549a043 /config
parent1df0345e9e642ca7e9d73c12430921b0fe62d25e (diff)
Refactor explore area
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'config')
-rw-r--r--config/routes.rb18
1 files changed, 13 insertions, 5 deletions
diff --git a/config/routes.rb b/config/routes.rb
index a8c782ecbf2..f54f9ea5341 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -47,15 +47,23 @@ Gitlab::Application.routes.draw do
get "/s/:username" => "snippets#user_index", as: :user_snippets, constraints: { username: /.*/ }
#
- # Public namespace
+ # Explroe area
#
- namespace :public do
- resources :projects, only: [:index]
+ namespace :explore do
+ resources :projects, only: [:index] do
+ collection do
+ get :trending
+ end
+ end
+
resources :groups, only: [:index]
- get 'explore' => 'explore#index'
- root to: "explore#index"
+ root to: "projects#trending"
end
+ # Compatibility with old routing
+ get 'public' => "explore/projects#index"
+ get 'public/projects' => "explore/projects#index"
+
#
# Attachments serving
#