Skip to content

Commit 2ec0eaf

Browse files
committed
Add SystemAgent distinct from User to represent a different kind of Actor
1 parent 90428bb commit 2ec0eaf

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

dbschema/user.esdl

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
module default {
2-
type User extending Resource, Mixin::Pinnable {
2+
abstract type Actor {
3+
multi roles: Role;
4+
}
5+
6+
type User extending Resource, Actor, Mixin::Pinnable {
37
email: str {
48
constraint exclusive;
59
};
@@ -19,7 +23,6 @@ module default {
1923
required status: User::Status {
2024
default := User::Status.Active;
2125
};
22-
multi roles: Role;
2326
title: str;
2427
multi link pins: Mixin::Pinnable {
2528
on target delete allow;
@@ -34,6 +37,10 @@ module default {
3437
}
3538
multi locations: Location;
3639
}
40+
41+
type SystemAgent extending Actor, Mixin::Named {
42+
overloaded name { constraint exclusive };
43+
}
3744
}
3845

3946
module User {

0 commit comments

Comments
 (0)