Class: Spree::PermissionSets::ConfigurationDisplay

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

Overview

Read-only permissions for e-commerce settings.

Roles with this permission will be able to view information, also from the admin panel, about:

  • Tax categories

  • Tax rates

  • Zones

  • Countries

  • States

  • Payment methods

  • Taxonomies

  • Shipping methods

  • Shipping categories

  • Stock locations

  • Stock movements

  • Refund reasons

  • Reimbursement types

  • Return reasons

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

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

Instance Method Details

#activate!Object



25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# File 'lib/spree/permission_sets/configuration_display.rb', line 25

def activate!
    can [:read, :admin], Spree::TaxCategory
    can [:read, :admin], Spree::TaxRate
    can [:read, :admin], Spree::Zone
    can [:read, :admin], Spree::Country
    can [:read, :admin], Spree::State
    can [:read, :admin], Spree::PaymentMethod
    can [:read, :admin], Spree::Taxonomy
    can [:read, :admin], Spree::ShippingMethod
    can [:read, :admin], Spree::ShippingCategory
    can [:read, :admin], Spree::StockLocation
    can [:read, :admin], Spree::StockMovement
    can [:read, :admin], Spree::RefundReason
    can [:read, :admin], Spree::ReimbursementType
    can [:read, :admin], Spree::ReturnReason
end