diff options
author | Tomasz Maczukin <tomasz@maczukin.pl> | 2016-01-14 10:58:40 +0100 |
---|---|---|
committer | Tomasz Maczukin <tomasz@maczukin.pl> | 2016-01-14 10:58:40 +0100 |
commit | 57a67c4fdb147b4b9eee9f8de35004b86fe9ed12 (patch) | |
tree | 43c2118bea0b973bb5ac6acb7a2b910ed9cab527 /app/controllers/projects_controller.rb | |
parent | 633ac13404a38bfa3901f515179dc795cded2fa9 (diff) | |
parent | d139276a3757d3df45232b557e1bb388d21268d0 (diff) | |
download | gitlab-ce-57a67c4fdb147b4b9eee9f8de35004b86fe9ed12.tar.gz |
Merge branch '8-4-stable' into ci/api-triggers
* 8-4-stable: (280 commits)
Add Changelog entry for build traces data integrity fix
Update doc_styleguide.md [ci skip]
Added hint that you can search users by name, username, or email.
Add changelog
Version 8.4.0.rc1
Randomize metrics sample intervals
Make the metrics sampler interval configurable
Don't automatically require awesome_print
Disable colorization if STDOUT is not a tty
Block the reported user before destroying the record
changes `$quote-gray` to `$secondary-text`
makes message plural for multiple MRs and removes from loop. Duh.
Prepare Installation and Update docs for 8.4 RC1
Mention channel/key bug in irkerd docs
Revert "Remove the `:coffee` and `:coffeescript` Haml filters"
gets merge request discussion working again
adds back in discussion.haml.html for issues commenting and closing/reopening properly.
removing last chunk of MR ajax changes, rest will be in another MR
reverting more MR ajax files, will appear in different commit
reverting MR ajax changes, which will be in a different MR
...
Diffstat (limited to 'app/controllers/projects_controller.rb')
-rw-r--r-- | app/controllers/projects_controller.rb | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index 3004722bce0..935f7d75c6a 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -8,7 +8,7 @@ class ProjectsController < ApplicationController before_action :assign_ref_vars, :tree, only: [:show], if: :repo_exists? # Authorize - before_action :authorize_admin_project!, only: [:edit, :update] + before_action :authorize_admin_project!, only: [:edit, :update, :housekeeping] before_action :event_filter, only: [:show, :activity] layout :determine_layout @@ -166,6 +166,15 @@ class ProjectsController < ApplicationController end end + def housekeeping + ::Projects::HousekeepingService.new(@project).execute + + respond_to do |format| + flash[:notice] = "Housekeeping successfully started." + format.html { redirect_to project_path(@project) } + end + end + def toggle_star current_user.toggle_star(@project) @project.reload |