-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrules.php
31 lines (29 loc) · 1.06 KB
/
rules.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<?php
use artkost\Module;
use artkost\rbac\rules\UserSuperAdminRule;
return [
'permissions' => [
'adminAssignmentView' => Module::t('rules', 'View Assignment'),
'adminAssignmentCreate' => Module::t('rules', 'Create Assignment'),
'adminAssignmentUpdate' => Module::t('rules', 'Update Assignment'),
'adminAssignmentDelete' => Module::t('rules', 'Delete Assignment')
],
'roles' => [
'superAdmin' => Module::t('rules', 'Super Administrator'),
'guest' => Module::t('rules', 'Guest'),
'adminAssignmentReader' => Module::t('rules', 'Read Assignments'),
'adminAssignmentManager' => Module::t('rules', 'Manage Assignments'),
],
'assignments' => [
'adminAssignmentReader' => ['adminAssignmentView'],
'adminAssignmentManager' => [
'adminAssignmentReader',
'adminAssignmentCreate',
'adminAssignmentUpdate',
'adminAssignmentDelete'
],
],
'rules' => [
'superAdmin' => new UserSuperAdminRule(['role' => 'superAdmin'])
]
];