summaryrefslogtreecommitdiff
path: root/app/controllers/dashboard/projects_controller.rb
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2015-09-08 14:49:20 +0100
committerDouwe Maan <douwe@gitlab.com>2015-09-08 14:49:20 +0100
commit5d785457db3017a17722314a52433543dd925164 (patch)
treea030699b752fcd1f161118be70a9df0f625fa0ef /app/controllers/dashboard/projects_controller.rb
parent260fcd45209b59ace6b3fd6dcca6c32c2c75a8f1 (diff)
downloadgitlab-ce-5d785457db3017a17722314a52433543dd925164.tar.gz
Clean up overlap between dashboard and explore.
- Split up SnippetsController into separate dashboard and explore sections. - Use consistent page titles, header titles and sidebars between dashboard and explore sections when signed in or not.
Diffstat (limited to 'app/controllers/dashboard/projects_controller.rb')
-rw-r--r--app/controllers/dashboard/projects_controller.rb15
1 files changed, 15 insertions, 0 deletions
diff --git a/app/controllers/dashboard/projects_controller.rb b/app/controllers/dashboard/projects_controller.rb
index da96171e885..467d0f81aca 100644
--- a/app/controllers/dashboard/projects_controller.rb
+++ b/app/controllers/dashboard/projects_controller.rb
@@ -1,6 +1,21 @@
class Dashboard::ProjectsController < Dashboard::ApplicationController
before_action :event_filter
+ def index
+ @projects = current_user.authorized_projects.sorted_by_activity.non_archived
+ @projects = @projects.includes(:namespace)
+ @last_push = current_user.recent_push
+
+ respond_to do |format|
+ format.html
+ format.atom do
+ event_filter
+ load_events
+ render layout: false
+ end
+ end
+ end
+
def starred
@projects = current_user.starred_projects
@projects = @projects.includes(:namespace, :forked_from_project, :tags)