init
This commit is contained in:
commit
135b14c868
35 changed files with 1363 additions and 0 deletions
24
app/models/group/root.rb
Normal file
24
app/models/group/root.rb
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
# encoding: utf-8
|
||||
|
||||
# TODO: rename class to specific name and change all references
|
||||
class Group::Root < ::Group
|
||||
|
||||
self.layer = true
|
||||
|
||||
# TODO: define actual child group types
|
||||
children Group::Root
|
||||
|
||||
### ROLES
|
||||
|
||||
# TODO: define actual role types
|
||||
class Leader < ::Role
|
||||
self.permissions = [:layer_and_below_full, :admin]
|
||||
end
|
||||
|
||||
class Member < ::Role
|
||||
self.permissions = [:group_read]
|
||||
end
|
||||
|
||||
roles Leader, Member
|
||||
|
||||
end
|
||||
Reference in a new issue