Sha256: 244be48b9e949771ba8c91a484ced86ca1e85e70d6340f650327169e1f87cf14

Contents?: true

Size: 535 Bytes

Versions: 3

Compression:

Stored size: 535 Bytes

Contents

# frozen_string_literal: true

module Spree
  module PermissionSets
    # Full permissions for stock management.
    #
    # This permission set grants full control over all stock items and read
    # access to locations.
    class StockManagement < PermissionSets::Base
      class << self
        def privilege
          :management
        end

        def category
          :stock
        end
      end

      def activate!
        can :manage, Spree::StockItem
        can :read, Spree::StockLocation
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
solidus_core-4.4.2 lib/spree/permission_sets/stock_management.rb
solidus_core-4.4.1 lib/spree/permission_sets/stock_management.rb
solidus_core-4.4.0 lib/spree/permission_sets/stock_management.rb