Sha256: 9fc1ba997bec07277ddd01df9fff3a824da141005a85d85214fd2f1f70da519f

Contents?: true

Size: 612 Bytes

Versions: 2

Compression:

Stored size: 612 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Admin
    # Controller that shows a simple dashboard.
    #
    class LogsController < Decidim::Admin::ApplicationController
      authorize_resource :admin_log, class: false

      helper_method :logs

      private

      def logs
        @logs ||= Decidim::ActionLog
                  .where(organization: current_organization)
                  .order(created_at: :desc)
                  .includes(:participatory_space, :user, :resource, :feature, :version)
                  .page(params[:page])
                  .per(20)
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
decidim-admin-0.10.1 app/controllers/decidim/admin/logs_controller.rb
decidim-admin-0.10.0 app/controllers/decidim/admin/logs_controller.rb