diff options
author | Valery Sizov <vsv2711@gmail.com> | 2012-10-03 12:17:48 +0000 |
---|---|---|
committer | Valery Sizov <vsv2711@gmail.com> | 2012-10-03 12:17:48 +0000 |
commit | 9e80d2d4f79edf81185461a34a50adcd251073f1 (patch) | |
tree | 591cc21b8f48b9cafda4fbf7554bb093300bc8e9 /app/controllers/dashboard_controller.rb | |
parent | dc22dd8aded81f10b8b9fc06f8c423043aa01d0a (diff) | |
parent | c8412bc9edbbed7a38cc4880f0d8cbb9091eb1d9 (diff) | |
download | gitlab-ce-9e80d2d4f79edf81185461a34a50adcd251073f1.tar.gz |
Merge branch 'feature/groups' of dev.gitlabhq.com:gitlabhq
Diffstat (limited to 'app/controllers/dashboard_controller.rb')
-rw-r--r-- | app/controllers/dashboard_controller.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/app/controllers/dashboard_controller.rb b/app/controllers/dashboard_controller.rb index 7696e97a7b2..1f142dae4c4 100644 --- a/app/controllers/dashboard_controller.rb +++ b/app/controllers/dashboard_controller.rb @@ -2,7 +2,10 @@ class DashboardController < ApplicationController respond_to :html def index - @projects = current_user.projects_with_events.page(params[:page]).per(40) + @groups = Group.where(id: current_user.projects.pluck(:group_id)) + @projects = current_user.projects_with_events + @projects = @projects.page(params[:page]).per(40) + @events = Event.recent_for_user(current_user).limit(20).offset(params[:offset] || 0) @last_push = current_user.recent_push |