Commit bcaf86da authored by Marin Jankovski's avatar Marin Jankovski

Add a route to project audit_events.

parent b722baee
class AuditEventsController < ApplicationController
# Authorize
before_filter :repository, only: :project_log
before_filter :authorize_admin_project!, only: :project_log
layout "project_settings"
def project_log
@events = AuditEvent.where(entity_type: "Project", entity_id: project.id)
end
private
def audit_events_params
params.permit(:project_id)
end
end
...@@ -358,6 +358,8 @@ Gitlab::Application.routes.draw do ...@@ -358,6 +358,8 @@ Gitlab::Application.routes.draw do
end end
end end
end end
get "/audit_events" => "audit_events#project_log"
end end
get ':id' => "namespaces#show", constraints: {id: /(?:[^.]|\.(?!atom$))+/, format: /atom/} get ':id' => "namespaces#show", constraints: {id: /(?:[^.]|\.(?!atom$))+/, format: /atom/}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment