Sha256: 49c9d009351886955348137b5efffe1e171adaf5e078a04654d0e43156d5414f
Contents?: true
Size: 433 Bytes
Versions: 16
Compression:
Stored size: 433 Bytes
Contents
# frozen_string_literal: true module G5Authenticatable # A user role (e.g. admin, viewer), optionally scoped to a client or location class Role < ActiveRecord::Base has_and_belongs_to_many :users, join_table: :g5_authenticatable_users_roles if Rails::VERSION::MAJOR >= 5 belongs_to :resource, polymorphic: true, optional: true else belongs_to :resource, polymorphic: true end scopify end end
Version data entries
16 entries across 16 versions & 1 rubygems