Add auditor role

Signed-off-by: Sacha Al Himdani <sacha@getprobo.com>
This commit is contained in:
Sacha Al Himdani
2025-12-10 14:41:54 +01:00
parent 9e5a775f66
commit f77676c88c
45 changed files with 1256 additions and 796 deletions

View File

@@ -220,7 +220,7 @@ var entityRegistry = map[uint16]EntityInfo{
Table: "trust_center_references",
},
TrustCenterDocumentAccessEntityType: {
Model: "",
Model: "TrustCenterDocumentAccess",
Table: "trust_center_document_accesses",
},
CustomDomainEntityType: {

View File

@@ -26,6 +26,7 @@ const (
MembershipRoleAdmin MembershipRole = "ADMIN"
MembershipRoleEmployee MembershipRole = "EMPLOYEE"
MembershipRoleViewer MembershipRole = "VIEWER"
MembershipRoleAuditor MembershipRole = "AUDITOR"
)
func (r MembershipRole) String() string {
@@ -52,6 +53,8 @@ func (r *MembershipRole) Scan(value any) error {
*r = MembershipRoleEmployee
case "VIEWER":
*r = MembershipRoleViewer
case "AUDITOR":
*r = MembershipRoleAuditor
default:
return fmt.Errorf("invalid MembershipRole value: %q", s)
}

View File

@@ -0,0 +1 @@
ALTER TYPE authz_role ADD VALUE 'AUDITOR';