Class: Spree::PermissionSets::UserDisplay
- Defined in:
- lib/spree/permission_sets/user_display.rb
Overview
Read-only permissions for users, roles and store credits.
This permission set allows users to view all related information about users, roles and store credits, also from the admin panel.
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Base
Constructor Details
This class inherits a constructor from Spree::PermissionSets::Base
Class Method Details
.category ⇒ Object
15 16 17 |
# File 'lib/spree/permission_sets/user_display.rb', line 15 def category :user end |
.privilege ⇒ Object
11 12 13 |
# File 'lib/spree/permission_sets/user_display.rb', line 11 def privilege :display end |
Instance Method Details
#activate! ⇒ Object
20 21 22 23 24 |
# File 'lib/spree/permission_sets/user_display.rb', line 20 def activate! can [:read, :admin, :edit, :addresses, :orders, :items], Spree.user_class can [:read, :admin], Spree::StoreCredit can :read, Spree::Role end |