Backend: Fix organization API endpoints and RBAC

- Fix member list API response format to match frontend expectations
- Fix join requests API response format
- Add proper JSON tags to Invitation struct
- Grant OrgManage permission to admin role for proper RBAC

These changes ensure frontend-backend API contracts are aligned and admins can manage organizations.
This commit is contained in:
Leon Bösche
2026-01-23 23:48:10 +01:00
parent bfe2d1d521
commit e10e499b6c
4 changed files with 72 additions and 11 deletions

View File

@@ -22,7 +22,7 @@ const (
var rolePermissions = map[string][]Permission{
"owner": {FileRead, FileWrite, FileDelete, DocumentView, DocumentEdit, OrgManage},
"admin": {FileRead, FileWrite, FileDelete, DocumentView, DocumentEdit},
"admin": {FileRead, FileWrite, FileDelete, DocumentView, DocumentEdit, OrgManage},
"member": {FileRead, DocumentView},
}