Sha256: b6682f275700a3238c08704722671e0e1e9eed1e06c7627b1e1da99a3f00e7d4
Contents?: true
Size: 474 Bytes
Versions: 15
Compression:
Stored size: 474 Bytes
Contents
module Applicaster class Accounts class User include Virtus.model attribute :id, String attribute :name, String attribute :email, String attribute :global_roles, Array[String] attribute :permissions, Array[Permission] attribute :admin, Boolean def admin? !!admin end def permission_for_account_id(account_id) permissions.find { |p| p.account_id == account_id } end end end end
Version data entries
15 entries across 15 versions & 1 rubygems