@@ -24,6 +24,8 @@ const (
24
24
UnifiedRoleEditorID = "fb6c3e19-e378-47e5-b277-9732f9de6e21"
25
25
// UnifiedRoleEditorListGrantsID Unified role editor id.
26
26
UnifiedRoleEditorListGrantsID = "e8ea8b21-abd4-45d2-b893-8d1546378e9e"
27
+ // UnifiedRoleEditorListGrantsWithVersionsID Unified role editor with versions id.
28
+ UnifiedRoleEditorListGrantsWithVersionsID = "0911d62b-1e3f-4778-8b1b-903b7e4e8476"
27
29
// UnifiedRoleSpaceEditorID Unified role space editor id.
28
30
UnifiedRoleSpaceEditorID = "58c63c02-1d89-4572-916a-870abc5a1b7d"
29
31
// UnifiedRoleSpaceEditorWithoutVersionsID Unified role space editor without list/restore versions id.
@@ -32,6 +34,8 @@ const (
32
34
UnifiedRoleFileEditorID = "2d00ce52-1fc2-4dbc-8b95-a73b73395f5a"
33
35
// UnifiedRoleFileEditorListGrantsID Unified role file editor id.
34
36
UnifiedRoleFileEditorListGrantsID = "c1235aea-d106-42db-8458-7d5610fb0a67"
37
+ // UnifiedRoleFileEditorListGrantsWithVersionsID Unified role file editor id.
38
+ UnifiedRoleFileEditorListGrantsWithVersionsID = "b173329d-cf2e-42f0-a595-ee410645d840"
35
39
// UnifiedRoleEditorLiteID Unified role editor-lite id.
36
40
UnifiedRoleEditorLiteID = "1c996275-f1c9-4e71-abdf-a42f6495e960"
37
41
// UnifiedRoleManagerID Unified role manager id.
@@ -121,6 +125,12 @@ var (
121
125
// UnifiedRole EditorListGrants, Role DisplayName (resolves directly)
122
126
_editorListGrantsUnifiedRoleDisplayName = l10n .Template ("Can edit" )
123
127
128
+ // UnifiedRoleListGrants Editor, Role Description (resolves directly)
129
+ _editorListGrantsWithVersionsUnifiedRoleDescription = l10n .Template ("View, download, upload, edit, delete and show all invited people, show all versions." )
130
+
131
+ // UnifiedRole EditorListGrants, Role DisplayName (resolves directly)
132
+ _editorListGrantsWithVersionsUnifiedRoleDisplayName = l10n .Template ("Can edit" )
133
+
124
134
// UnifiedRole SpaseEditor, Role Description (resolves directly)
125
135
_spaceEditorUnifiedRoleDescription = l10n .Template ("View, download, upload, edit, add, delete including the history." )
126
136
@@ -145,6 +155,12 @@ var (
145
155
// UnifiedRole FileEditorListGrants, Role DisplayName (resolves directly)
146
156
_fileEditorListGrantsUnifiedRoleDisplayName = l10n .Template ("Can edit" )
147
157
158
+ // UnifiedRole FileEditorListGrants, Role Description (resolves directly)
159
+ _fileEditorListGrantsWithVersionsUnifiedRoleDescription = l10n .Template ("View, download, edit and show all invited people, show all versions." )
160
+
161
+ // UnifiedRole FileEditorListGrants, Role DisplayName (resolves directly)
162
+ _fileEditorListGrantsWithVersionsUnifiedRoleDisplayName = l10n .Template ("Can edit" )
163
+
148
164
// UnifiedRole EditorLite, Role Description (resolves directly)
149
165
_editorLiteUnifiedRoleDescription = l10n .Template ("View, download and upload." )
150
166
@@ -191,10 +207,12 @@ var (
191
207
roleSpaceViewer ,
192
208
roleEditor ,
193
209
roleEditorListGrants ,
210
+ roleEditorListGrantsWithVersions ,
194
211
roleSpaceEditor ,
195
212
roleSpaceEditorWithoutVersions ,
196
213
roleFileEditor ,
197
214
roleFileEditorListGrants ,
215
+ roleFileEditorListGrantsWithVersions ,
198
216
roleEditorLite ,
199
217
roleManager ,
200
218
roleSecureViewer ,
@@ -318,6 +336,27 @@ var (
318
336
}
319
337
}()
320
338
339
+ // roleEditorListGrantsWithVersions creates an editor role.
340
+ roleEditorListGrantsWithVersions = func () * libregraph.UnifiedRoleDefinition {
341
+ r := conversions .NewEditorListGrantsWithVersionsRole ()
342
+ return & libregraph.UnifiedRoleDefinition {
343
+ Id : proto .String (UnifiedRoleEditorListGrantsWithVersionsID ),
344
+ Description : proto .String (_editorListGrantsWithVersionsUnifiedRoleDescription ),
345
+ DisplayName : proto .String (cs3RoleToDisplayName (r )),
346
+ RolePermissions : []libregraph.UnifiedRolePermission {
347
+ {
348
+ AllowedResourceActions : CS3ResourcePermissionsToLibregraphActions (r .CS3ResourcePermissions ()),
349
+ Condition : proto .String (UnifiedRoleConditionFolder ),
350
+ },
351
+ {
352
+ AllowedResourceActions : CS3ResourcePermissionsToLibregraphActions (r .CS3ResourcePermissions ()),
353
+ Condition : proto .String (UnifiedRoleConditionFolderFederatedUser ),
354
+ },
355
+ },
356
+ LibreGraphWeight : proto .Int32 (0 ),
357
+ }
358
+ }()
359
+
321
360
// roleSpaceEditor creates an editor role
322
361
roleSpaceEditor = func () * libregraph.UnifiedRoleDefinition {
323
362
r := conversions .NewSpaceEditorRole ()
@@ -394,6 +433,27 @@ var (
394
433
}
395
434
}()
396
435
436
+ // roleFileEditorListGrantsWithVersions creates a file-editor role
437
+ roleFileEditorListGrantsWithVersions = func () * libregraph.UnifiedRoleDefinition {
438
+ r := conversions .NewFileEditorListGrantsWithVersionsRole ()
439
+ return & libregraph.UnifiedRoleDefinition {
440
+ Id : proto .String (UnifiedRoleFileEditorListGrantsWithVersionsID ),
441
+ Description : proto .String (_fileEditorListGrantsWithVersionsUnifiedRoleDescription ),
442
+ DisplayName : proto .String (cs3RoleToDisplayName (r )),
443
+ RolePermissions : []libregraph.UnifiedRolePermission {
444
+ {
445
+ AllowedResourceActions : CS3ResourcePermissionsToLibregraphActions (r .CS3ResourcePermissions ()),
446
+ Condition : proto .String (UnifiedRoleConditionFile ),
447
+ },
448
+ {
449
+ AllowedResourceActions : CS3ResourcePermissionsToLibregraphActions (r .CS3ResourcePermissions ()),
450
+ Condition : proto .String (UnifiedRoleConditionFileFederatedUser ),
451
+ },
452
+ },
453
+ LibreGraphWeight : proto .Int32 (0 ),
454
+ }
455
+ }()
456
+
397
457
// roleEditorLite creates an editor-lite role
398
458
roleEditorLite = func () * libregraph.UnifiedRoleDefinition {
399
459
r := conversions .NewEditorLiteRole ()
0 commit comments