blob: 6e467197c3c5e4960d51e495593904bb3914ab7c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
class NodeActionsController < ApplicationController
before_action :login_required
layout 'admin'
def index
@actions = NodeAction.order(:occurred_at => :desc, :id => :desc)
@actions = @actions.where(:node_id => params[:node_id]) if params[:node_id].present?
@actions = @actions.where(:user_id => params[:user_id]) if params[:user_id].present?
@actions = @actions.includes(:node, :user)
.paginate(:page => params[:page], :per_page => 50)
end
end
|