-
Notifications
You must be signed in to change notification settings - Fork 17
Expand file tree
/
Copy pathmodel.fga
More file actions
66 lines (59 loc) · 2.18 KB
/
model.fga
File metadata and controls
66 lines (59 loc) · 2.18 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
model
schema 1.1
type user
type organization
relations
define member: [user] or admin or instructor or student
define admin: [user]
define instructor: [user]
define student: [user]
type course
relations
define organization: [organization]
define owner: [user]
define enrolled_instructor: [user]
define enrolled_student: [user]
define organization_admin: admin from organization
define organization_instructor: instructor from organization
define organization_student: student from organization
define can_delete: organization_admin
define can_publish: owner or can_delete
define can_edit: enrolled_instructor or can_publish
define can_create_class: can_edit
define can_create_content: can_edit
define can_view: enrolled_student or organization_instructor or can_edit
type class
relations
define course: [course]
define instructor: [user]
define student: [user]
define organization_admin: organization_admin from course
define organization_instructor: organization_instructor from course
define can_delete: organization_admin
define can_enroll: instructor or can_delete
define can_edit: enrolled_instructor from course or can_enroll
define can_view: student or can_view from course or can_edit
type content
relations
define course: [course]
define author: [user]
define can_delete: author or organization_admin from course
define can_edit: organization_instructor from course or can_delete
define can_view: organization_student from course or can_edit
type collection
relations
define organization: [organization]
define owner: [user]
define can_delete: admin from organization
define can_edit: owner or instructor from organization or can_delete
define can_view: student from organization or can_edit
type activity
relations
define class: [class]
define creator: [user]
define assignee: [user]
define can_delete: organization_admin from class
define can_grade: creator or instructor from class or organization_instructor from class or can_delete
define can_edit: can_grade
define can_view: assignee or can_edit
define can_submit: assignee