Class: ErrorsController

Inherits:
ApplicationController show all
Defined in:
app/controllers/errors_controller.rb

Instance Method Summary collapse

Methods inherited from ApplicationController

#after_sign_in_path_for, #api_authenticate!, #authenticated_via_token?, #current_project, #expire_revision!, #followed_projects, #no_cache, #oauth_authorize!, #read_revision, #require_login, #return_or_cache_revision!, #revision, #token_authenticate!, #unfurling?, #with_current_project

Methods included from UrlHelper

#feature_path, #link_to_project_feature

Instance Method Details

#indexObject



3
4
5
6
7
8
# File 'app/controllers/errors_controller.rb', line 3

def index
  authorize! :read, Action
  @actions = Action.where.not(error_id: nil).preload(:error).limit(50)
  @actions = @actions.where(Action.arel_table[:created_at].lt(params[:before])) if params[:before]
  render partial: "actions/actions" if request.xhr?
end