Class: Spree::PermissionSets::DashboardDisplay

Inherits:
Base
  • Object
show all
Defined in:
lib/spree/permission_sets/dashboard_display.rb

Overview

Permissions for viewing the admin dashboard.

Roles with this permission set will be able to view the admin dashboard, which may or not contain sensitive information depending on customizations.

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Spree::PermissionSets::Base

Class Method Details

.categoryObject



16
17
18
# File 'lib/spree/permission_sets/dashboard_display.rb', line 16

def category
  :dashboard_display
end

.privilegeObject



12
13
14
# File 'lib/spree/permission_sets/dashboard_display.rb', line 12

def privilege
  :other
end

Instance Method Details

#activate!Object



21
22
23
24
25
# File 'lib/spree/permission_sets/dashboard_display.rb', line 21

def activate!
    Spree.deprecator.warn "The #{self.class.name} module is deprecated. " \
      "If you still use dashboards, please copy all controllers and views from #{self.class.name} to your application."
    can [:admin, :home], :dashboards
end