@fivenet-app/gen 2026.5.0 → 2026.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/codegen/perms/perms.ts +61 -39
  2. package/package.json +1 -1
  3. package/perms.ts +47 -41
  4. package/resources/accounts/accounts.ts +41 -30
  5. package/resources/audit/audit.ts +5 -1
  6. package/resources/citizens/labels/access.ts +1 -1
  7. package/resources/jobs/colleagues/activity/activity.ts +1 -1
  8. package/resources/laws/laws.ts +72 -50
  9. package/resources/permissions/attributes/attributes.ts +51 -39
  10. package/resources/permissions/permissions/permissions.ts +46 -34
  11. package/resources/sync/data/data.ts +9 -9
  12. package/resources/users/activity/activity.ts +69 -76
  13. package/services/auth/auth.ts +1 -1
  14. package/services/calendar/entries.ts +1 -1
  15. package/services/centrum/dispatches.ts +5 -5
  16. package/services/centrum/units.ts +6 -6
  17. package/services/citizens/labels.client.ts +26 -0
  18. package/services/citizens/labels.ts +283 -4
  19. package/services/completor/completor.client.ts +0 -13
  20. package/services/completor/completor.ts +2 -116
  21. package/services/documents/approval.ts +5 -5
  22. package/services/documents/categories.ts +1 -1
  23. package/services/documents/collab.ts +1 -1
  24. package/services/documents/comments.ts +4 -4
  25. package/services/documents/templates.ts +1 -1
  26. package/services/jobs/colleagues.ts +1 -1
  27. package/services/mailer/settings.ts +1 -1
  28. package/services/mailer/thread.ts +1 -1
  29. package/services/qualifications/exam.ts +5 -5
  30. package/services/settings/accounts.ts +14 -1
  31. package/services/settings/laws.client.ts +18 -5
  32. package/services/settings/laws.ts +128 -3
  33. package/services/wiki/collab.ts +1 -1
  34. package/svcs.ts +3 -1
@@ -21,23 +21,27 @@ export interface PermsOptions {
21
21
  */
22
22
  enabled: boolean;
23
23
  /**
24
- * @generated from protobuf field: optional string service = 2
24
+ * @generated from protobuf field: optional string namespace = 2
25
+ */
26
+ namespace?: string;
27
+ /**
28
+ * @generated from protobuf field: optional string service = 3
25
29
  */
26
30
  service?: string;
27
31
  /**
28
- * @generated from protobuf field: optional string name = 3
32
+ * @generated from protobuf field: optional string name = 4
29
33
  */
30
34
  name?: string;
31
35
  /**
32
- * @generated from protobuf field: repeated string names = 6
36
+ * @generated from protobuf field: repeated string names = 5
33
37
  */
34
38
  names: string[];
35
39
  /**
36
- * @generated from protobuf field: int32 order = 4
40
+ * @generated from protobuf field: int32 order = 6
37
41
  */
38
42
  order: number;
39
43
  /**
40
- * @generated from protobuf field: repeated codegen.perms.Attr attrs = 5
44
+ * @generated from protobuf field: repeated codegen.perms.Attr attrs = 7
41
45
  */
42
46
  attrs: Attr[];
43
47
  }
@@ -75,11 +79,15 @@ export interface ServiceOptions {
75
79
  */
76
80
  icon?: string;
77
81
  /**
78
- * @generated from protobuf field: optional string name = 4
82
+ * @generated from protobuf field: optional string namespace = 3
79
83
  */
80
- name?: string;
84
+ namespace?: string;
85
+ /**
86
+ * @generated from protobuf field: optional string service = 4
87
+ */
88
+ service?: string;
81
89
  /**
82
- * @generated from protobuf field: repeated codegen.perms.AdditionalServicePerm additional_perms = 3
90
+ * @generated from protobuf field: repeated codegen.perms.AdditionalServicePerm additional_perms = 5
83
91
  */
84
92
  additionalPerms: AdditionalServicePerm[];
85
93
  }
@@ -105,11 +113,12 @@ class PermsOptions$Type extends MessageType<PermsOptions> {
105
113
  constructor() {
106
114
  super("codegen.perms.PermsOptions", [
107
115
  { no: 1, name: "enabled", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
108
- { no: 2, name: "service", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
109
- { no: 3, name: "name", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
110
- { no: 6, name: "names", kind: "scalar", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ },
111
- { no: 4, name: "order", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
112
- { no: 5, name: "attrs", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Attr }
116
+ { no: 2, name: "namespace", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
117
+ { no: 3, name: "service", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
118
+ { no: 4, name: "name", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
119
+ { no: 5, name: "names", kind: "scalar", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ },
120
+ { no: 6, name: "order", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
121
+ { no: 7, name: "attrs", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Attr }
113
122
  ]);
114
123
  }
115
124
  create(value?: PartialMessage<PermsOptions>): PermsOptions {
@@ -130,19 +139,22 @@ class PermsOptions$Type extends MessageType<PermsOptions> {
130
139
  case /* bool enabled */ 1:
131
140
  message.enabled = reader.bool();
132
141
  break;
133
- case /* optional string service */ 2:
142
+ case /* optional string namespace */ 2:
143
+ message.namespace = reader.string();
144
+ break;
145
+ case /* optional string service */ 3:
134
146
  message.service = reader.string();
135
147
  break;
136
- case /* optional string name */ 3:
148
+ case /* optional string name */ 4:
137
149
  message.name = reader.string();
138
150
  break;
139
- case /* repeated string names */ 6:
151
+ case /* repeated string names */ 5:
140
152
  message.names.push(reader.string());
141
153
  break;
142
- case /* int32 order */ 4:
154
+ case /* int32 order */ 6:
143
155
  message.order = reader.int32();
144
156
  break;
145
- case /* repeated codegen.perms.Attr attrs */ 5:
157
+ case /* repeated codegen.perms.Attr attrs */ 7:
146
158
  message.attrs.push(Attr.internalBinaryRead(reader, reader.uint32(), options));
147
159
  break;
148
160
  default:
@@ -160,21 +172,24 @@ class PermsOptions$Type extends MessageType<PermsOptions> {
160
172
  /* bool enabled = 1; */
161
173
  if (message.enabled !== false)
162
174
  writer.tag(1, WireType.Varint).bool(message.enabled);
163
- /* optional string service = 2; */
175
+ /* optional string namespace = 2; */
176
+ if (message.namespace !== undefined)
177
+ writer.tag(2, WireType.LengthDelimited).string(message.namespace);
178
+ /* optional string service = 3; */
164
179
  if (message.service !== undefined)
165
- writer.tag(2, WireType.LengthDelimited).string(message.service);
166
- /* optional string name = 3; */
180
+ writer.tag(3, WireType.LengthDelimited).string(message.service);
181
+ /* optional string name = 4; */
167
182
  if (message.name !== undefined)
168
- writer.tag(3, WireType.LengthDelimited).string(message.name);
169
- /* int32 order = 4; */
183
+ writer.tag(4, WireType.LengthDelimited).string(message.name);
184
+ /* repeated string names = 5; */
185
+ for (let i = 0; i < message.names.length; i++)
186
+ writer.tag(5, WireType.LengthDelimited).string(message.names[i]);
187
+ /* int32 order = 6; */
170
188
  if (message.order !== 0)
171
- writer.tag(4, WireType.Varint).int32(message.order);
172
- /* repeated codegen.perms.Attr attrs = 5; */
189
+ writer.tag(6, WireType.Varint).int32(message.order);
190
+ /* repeated codegen.perms.Attr attrs = 7; */
173
191
  for (let i = 0; i < message.attrs.length; i++)
174
- Attr.internalBinaryWrite(message.attrs[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join();
175
- /* repeated string names = 6; */
176
- for (let i = 0; i < message.names.length; i++)
177
- writer.tag(6, WireType.LengthDelimited).string(message.names[i]);
192
+ Attr.internalBinaryWrite(message.attrs[i], writer.tag(7, WireType.LengthDelimited).fork(), options).join();
178
193
  let u = options.writeUnknownFields;
179
194
  if (u !== false)
180
195
  (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
@@ -262,8 +277,9 @@ class ServiceOptions$Type extends MessageType<ServiceOptions> {
262
277
  super("codegen.perms.ServiceOptions", [
263
278
  { no: 1, name: "order", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
264
279
  { no: 2, name: "icon", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
265
- { no: 4, name: "name", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
266
- { no: 3, name: "additional_perms", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => AdditionalServicePerm }
280
+ { no: 3, name: "namespace", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
281
+ { no: 4, name: "service", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
282
+ { no: 5, name: "additional_perms", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => AdditionalServicePerm }
267
283
  ]);
268
284
  }
269
285
  create(value?: PartialMessage<ServiceOptions>): ServiceOptions {
@@ -285,10 +301,13 @@ class ServiceOptions$Type extends MessageType<ServiceOptions> {
285
301
  case /* optional string icon */ 2:
286
302
  message.icon = reader.string();
287
303
  break;
288
- case /* optional string name */ 4:
289
- message.name = reader.string();
304
+ case /* optional string namespace */ 3:
305
+ message.namespace = reader.string();
306
+ break;
307
+ case /* optional string service */ 4:
308
+ message.service = reader.string();
290
309
  break;
291
- case /* repeated codegen.perms.AdditionalServicePerm additional_perms */ 3:
310
+ case /* repeated codegen.perms.AdditionalServicePerm additional_perms */ 5:
292
311
  message.additionalPerms.push(AdditionalServicePerm.internalBinaryRead(reader, reader.uint32(), options));
293
312
  break;
294
313
  default:
@@ -309,12 +328,15 @@ class ServiceOptions$Type extends MessageType<ServiceOptions> {
309
328
  /* optional string icon = 2; */
310
329
  if (message.icon !== undefined)
311
330
  writer.tag(2, WireType.LengthDelimited).string(message.icon);
312
- /* repeated codegen.perms.AdditionalServicePerm additional_perms = 3; */
331
+ /* optional string namespace = 3; */
332
+ if (message.namespace !== undefined)
333
+ writer.tag(3, WireType.LengthDelimited).string(message.namespace);
334
+ /* optional string service = 4; */
335
+ if (message.service !== undefined)
336
+ writer.tag(4, WireType.LengthDelimited).string(message.service);
337
+ /* repeated codegen.perms.AdditionalServicePerm additional_perms = 5; */
313
338
  for (let i = 0; i < message.additionalPerms.length; i++)
314
- AdditionalServicePerm.internalBinaryWrite(message.additionalPerms[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join();
315
- /* optional string name = 4; */
316
- if (message.name !== undefined)
317
- writer.tag(4, WireType.LengthDelimited).string(message.name);
339
+ AdditionalServicePerm.internalBinaryWrite(message.additionalPerms[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join();
318
340
  let u = options.writeUnknownFields;
319
341
  if (u !== false)
320
342
  (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@fivenet-app/gen",
3
3
  "private": false,
4
- "version": "2026.5.0",
4
+ "version": "2026.5.1",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
7
7
  "homepage": "https://fivenet.app",
package/perms.ts CHANGED
@@ -44,48 +44,45 @@
44
44
 
45
45
  export type Perms = SystemPerms | GRPCServicePerms;
46
46
 
47
- export type SystemPerms = 'Superuser/CanBeSuperuser' | 'Superuser/Superuser' | 'TODOService/TODOMethod';
47
+ export type SystemPerms = 'internal.Superuser/CanBeSuperuser' | 'internal.Superuser/Superuser' | 'TODOService/TODOMethod';
48
48
 
49
49
  export type GRPCServicePerms =
50
50
  | 'auth.AuthService/ChooseCharacter'
51
51
  | 'calendar.CalendarService/CreateCalendar'
52
- | 'centrum.CentrumService/CreateDispatch'
53
- | 'centrum.CentrumService/CreateOrUpdateUnit'
54
- | 'centrum.CentrumService/DeleteDispatch'
55
- | 'centrum.CentrumService/DeleteUnit'
56
52
  | 'centrum.CentrumService/Stream'
57
53
  | 'centrum.CentrumService/TakeControl'
58
- | 'centrum.CentrumService/TakeDispatch'
59
- | 'centrum.CentrumService/UpdateDispatch'
60
54
  | 'centrum.CentrumService/UpdateDispatchers'
61
55
  | 'centrum.CentrumService/UpdateSettings'
56
+ | 'centrum.DispatchesService/CreateDispatch'
57
+ | 'centrum.DispatchesService/DeleteDispatch'
58
+ | 'centrum.DispatchesService/TakeDispatch'
59
+ | 'centrum.DispatchesService/UpdateDispatch'
60
+ | 'centrum.UnitsService/CreateOrUpdateUnit'
61
+ | 'centrum.UnitsService/DeleteUnit'
62
62
  | 'citizens.CitizensService/GetUser'
63
63
  | 'citizens.CitizensService/ListCitizens'
64
64
  | 'citizens.CitizensService/ListUserActivity'
65
65
  | 'citizens.CitizensService/SetUserProps'
66
66
  | 'citizens.LabelsService/CreateOrUpdateLabel'
67
67
  | 'citizens.LabelsService/DeleteLabel'
68
- | 'completor.CompletorService/CompleteCitizenLabels'
68
+ | 'citizens.LabelsService/ListLabels'
69
69
  | 'documents.ApprovalService/DeleteApprovalTasks'
70
70
  | 'documents.ApprovalService/RevokeApproval'
71
71
  | 'documents.ApprovalService/UpsertApprovalPolicy'
72
72
  | 'documents.ApprovalService/UpsertApprovalTasks'
73
+ | 'documents.CategoriesService/CreateOrUpdateCategory'
74
+ | 'documents.CategoriesService/DeleteCategory'
75
+ | 'documents.CategoriesService/ListCategories'
76
+ | 'documents.CommentsService/DeleteComment'
73
77
  | 'documents.DocumentsService/AddDocumentReference'
74
78
  | 'documents.DocumentsService/AddDocumentRelation'
75
79
  | 'documents.DocumentsService/ChangeDocumentOwner'
76
80
  | 'documents.DocumentsService/CreateDocumentReq'
77
- | 'documents.DocumentsService/CreateOrUpdateCategory'
78
- | 'documents.DocumentsService/CreateTemplate'
79
- | 'documents.DocumentsService/DeleteCategory'
80
- | 'documents.DocumentsService/DeleteComment'
81
81
  | 'documents.DocumentsService/DeleteDocument'
82
82
  | 'documents.DocumentsService/DeleteDocumentReq'
83
- | 'documents.DocumentsService/DeleteTemplate'
84
- | 'documents.DocumentsService/ListCategories'
85
83
  | 'documents.DocumentsService/ListDocumentActivity'
86
84
  | 'documents.DocumentsService/ListDocumentReqs'
87
85
  | 'documents.DocumentsService/ListDocuments'
88
- | 'documents.DocumentsService/ListTemplates'
89
86
  | 'documents.DocumentsService/ListUserDocuments'
90
87
  | 'documents.DocumentsService/SetDocumentReminder'
91
88
  | 'documents.DocumentsService/ToggleDocument'
@@ -95,16 +92,19 @@ export type GRPCServicePerms =
95
92
  | 'documents.StampsService/ListUsableStamps'
96
93
  | 'documents.StampsService/UpsertStamp'
97
94
  | 'documents.StatsService/GetStats'
95
+ | 'documents.TemplatesService/CreateTemplate'
96
+ | 'documents.TemplatesService/DeleteTemplate'
97
+ | 'documents.TemplatesService/ListTemplates'
98
+ | 'jobs.ColleaguesService/GetColleague'
99
+ | 'jobs.ColleaguesService/ListColleagueActivity'
100
+ | 'jobs.ColleaguesService/ListColleagues'
101
+ | 'jobs.ColleaguesService/ManageLabels'
102
+ | 'jobs.ColleaguesService/SetColleagueProps'
98
103
  | 'jobs.ConductService/CreateConductEntry'
99
104
  | 'jobs.ConductService/DeleteConductEntry'
100
105
  | 'jobs.ConductService/ListConductEntries'
101
106
  | 'jobs.ConductService/UpdateConductEntry'
102
107
  | 'jobs.ConductService/UploadFile'
103
- | 'jobs.JobsService/GetColleague'
104
- | 'jobs.JobsService/ListColleagueActivity'
105
- | 'jobs.JobsService/ListColleagues'
106
- | 'jobs.JobsService/ManageLabels'
107
- | 'jobs.JobsService/SetColleagueProps'
108
108
  | 'jobs.JobsService/SetMOTD'
109
109
  | 'jobs.StatsService/GetStats'
110
110
  | 'jobs.TimeclockService/ListInactiveEmployees'
@@ -140,13 +140,18 @@ export const GRPCServices = [
140
140
  'auth.AuthService',
141
141
  'calendar.CalendarService',
142
142
  'centrum.CentrumService',
143
+ 'centrum.DispatchesService',
144
+ 'centrum.UnitsService',
143
145
  'citizens.CitizensService',
144
146
  'citizens.LabelsService',
145
- 'completor.CompletorService',
146
147
  'documents.ApprovalService',
148
+ 'documents.CategoriesService',
149
+ 'documents.CommentsService',
147
150
  'documents.DocumentsService',
148
151
  'documents.StampsService',
149
152
  'documents.StatsService',
153
+ 'documents.TemplatesService',
154
+ 'jobs.ColleaguesService',
150
155
  'jobs.ConductService',
151
156
  'jobs.JobsService',
152
157
  'jobs.StatsService',
@@ -163,43 +168,40 @@ export const GRPCServices = [
163
168
  export const GRPCServiceMethods = [
164
169
  'auth.AuthService/ChooseCharacter',
165
170
  'calendar.CalendarService/CreateCalendar',
166
- 'centrum.CentrumService/CreateDispatch',
167
- 'centrum.CentrumService/CreateOrUpdateUnit',
168
- 'centrum.CentrumService/DeleteDispatch',
169
- 'centrum.CentrumService/DeleteUnit',
170
171
  'centrum.CentrumService/Stream',
171
172
  'centrum.CentrumService/TakeControl',
172
- 'centrum.CentrumService/TakeDispatch',
173
- 'centrum.CentrumService/UpdateDispatch',
174
173
  'centrum.CentrumService/UpdateDispatchers',
175
174
  'centrum.CentrumService/UpdateSettings',
175
+ 'centrum.DispatchesService/CreateDispatch',
176
+ 'centrum.DispatchesService/DeleteDispatch',
177
+ 'centrum.DispatchesService/TakeDispatch',
178
+ 'centrum.DispatchesService/UpdateDispatch',
179
+ 'centrum.UnitsService/CreateOrUpdateUnit',
180
+ 'centrum.UnitsService/DeleteUnit',
176
181
  'citizens.CitizensService/GetUser',
177
182
  'citizens.CitizensService/ListCitizens',
178
183
  'citizens.CitizensService/ListUserActivity',
179
184
  'citizens.CitizensService/SetUserProps',
180
185
  'citizens.LabelsService/CreateOrUpdateLabel',
181
186
  'citizens.LabelsService/DeleteLabel',
182
- 'completor.CompletorService/CompleteCitizenLabels',
187
+ 'citizens.LabelsService/ListLabels',
183
188
  'documents.ApprovalService/DeleteApprovalTasks',
184
189
  'documents.ApprovalService/RevokeApproval',
185
190
  'documents.ApprovalService/UpsertApprovalPolicy',
186
191
  'documents.ApprovalService/UpsertApprovalTasks',
192
+ 'documents.CategoriesService/CreateOrUpdateCategory',
193
+ 'documents.CategoriesService/DeleteCategory',
194
+ 'documents.CategoriesService/ListCategories',
195
+ 'documents.CommentsService/DeleteComment',
187
196
  'documents.DocumentsService/AddDocumentReference',
188
197
  'documents.DocumentsService/AddDocumentRelation',
189
198
  'documents.DocumentsService/ChangeDocumentOwner',
190
199
  'documents.DocumentsService/CreateDocumentReq',
191
- 'documents.DocumentsService/CreateOrUpdateCategory',
192
- 'documents.DocumentsService/CreateTemplate',
193
- 'documents.DocumentsService/DeleteCategory',
194
- 'documents.DocumentsService/DeleteComment',
195
200
  'documents.DocumentsService/DeleteDocument',
196
201
  'documents.DocumentsService/DeleteDocumentReq',
197
- 'documents.DocumentsService/DeleteTemplate',
198
- 'documents.DocumentsService/ListCategories',
199
202
  'documents.DocumentsService/ListDocumentActivity',
200
203
  'documents.DocumentsService/ListDocumentReqs',
201
204
  'documents.DocumentsService/ListDocuments',
202
- 'documents.DocumentsService/ListTemplates',
203
205
  'documents.DocumentsService/ListUserDocuments',
204
206
  'documents.DocumentsService/SetDocumentReminder',
205
207
  'documents.DocumentsService/ToggleDocument',
@@ -209,16 +211,19 @@ export const GRPCServiceMethods = [
209
211
  'documents.StampsService/ListUsableStamps',
210
212
  'documents.StampsService/UpsertStamp',
211
213
  'documents.StatsService/GetStats',
214
+ 'documents.TemplatesService/CreateTemplate',
215
+ 'documents.TemplatesService/DeleteTemplate',
216
+ 'documents.TemplatesService/ListTemplates',
217
+ 'jobs.ColleaguesService/GetColleague',
218
+ 'jobs.ColleaguesService/ListColleagueActivity',
219
+ 'jobs.ColleaguesService/ListColleagues',
220
+ 'jobs.ColleaguesService/ManageLabels',
221
+ 'jobs.ColleaguesService/SetColleagueProps',
212
222
  'jobs.ConductService/CreateConductEntry',
213
223
  'jobs.ConductService/DeleteConductEntry',
214
224
  'jobs.ConductService/ListConductEntries',
215
225
  'jobs.ConductService/UpdateConductEntry',
216
226
  'jobs.ConductService/UploadFile',
217
- 'jobs.JobsService/GetColleague',
218
- 'jobs.JobsService/ListColleagueActivity',
219
- 'jobs.JobsService/ListColleagues',
220
- 'jobs.JobsService/ManageLabels',
221
- 'jobs.JobsService/SetColleagueProps',
222
227
  'jobs.JobsService/SetMOTD',
223
228
  'jobs.StatsService/GetStats',
224
229
  'jobs.TimeclockService/ListInactiveEmployees',
@@ -248,4 +253,5 @@ export const GRPCServiceMethods = [
248
253
  'wiki.WikiService/ListPageActivity',
249
254
  'wiki.WikiService/ListPages',
250
255
  'wiki.WikiService/UpdatePage',
251
- 'wiki.WikiService/UploadFile',];
256
+ 'wiki.WikiService/UploadFile',
257
+ ];
@@ -31,27 +31,31 @@ export interface Account {
31
31
  */
32
32
  updatedAt?: Timestamp;
33
33
  /**
34
- * @generated from protobuf field: bool enabled = 4
34
+ * @generated from protobuf field: optional resources.timestamp.Timestamp deleted_at = 4
35
+ */
36
+ deletedAt?: Timestamp;
37
+ /**
38
+ * @generated from protobuf field: bool enabled = 5
35
39
  */
36
40
  enabled: boolean;
37
41
  /**
38
- * @generated from protobuf field: string username = 5
42
+ * @generated from protobuf field: string username = 6
39
43
  */
40
44
  username: string;
41
45
  /**
42
- * @generated from protobuf field: string license = 6
46
+ * @generated from protobuf field: string license = 7
43
47
  */
44
48
  license: string;
45
49
  /**
46
- * @generated from protobuf field: optional resources.accounts.AccountGroups groups = 7
50
+ * @generated from protobuf field: optional resources.accounts.AccountGroups groups = 8
47
51
  */
48
52
  groups?: AccountGroups;
49
53
  /**
50
- * @generated from protobuf field: optional int32 last_char = 8
54
+ * @generated from protobuf field: optional int32 last_char = 9
51
55
  */
52
56
  lastChar?: number;
53
57
  /**
54
- * @generated from protobuf field: repeated resources.accounts.oauth2.OAuth2Account oauth2_accounts = 9
58
+ * @generated from protobuf field: repeated resources.accounts.oauth2.OAuth2Account oauth2_accounts = 10
55
59
  */
56
60
  oauth2Accounts: OAuth2Account[];
57
61
  }
@@ -88,12 +92,13 @@ class Account$Type extends MessageType<Account> {
88
92
  { no: 1, name: "id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/, options: { "tagger.tags": "sql:\"primary_key\"" } },
89
93
  { no: 2, name: "created_at", kind: "message", T: () => Timestamp },
90
94
  { no: 3, name: "updated_at", kind: "message", T: () => Timestamp },
91
- { no: 4, name: "enabled", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
92
- { no: 5, name: "username", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "24" } } } },
93
- { no: 6, name: "license", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "64" } } } },
94
- { no: 7, name: "groups", kind: "message", T: () => AccountGroups },
95
- { no: 8, name: "last_char", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/, options: { "buf.validate.field": { int32: { gt: 0 } } } },
96
- { no: 9, name: "oauth2_accounts", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => OAuth2Account, options: { "buf.validate.field": { repeated: { maxItems: "10" } }, "tagger.tags": "alias:\"oauth2_account\"" } }
95
+ { no: 4, name: "deleted_at", kind: "message", T: () => Timestamp },
96
+ { no: 5, name: "enabled", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
97
+ { no: 6, name: "username", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "24" } } } },
98
+ { no: 7, name: "license", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "64" } } } },
99
+ { no: 8, name: "groups", kind: "message", T: () => AccountGroups },
100
+ { no: 9, name: "last_char", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/, options: { "buf.validate.field": { int32: { gt: 0 } } } },
101
+ { no: 10, name: "oauth2_accounts", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => OAuth2Account, options: { "buf.validate.field": { repeated: { maxItems: "10" } }, "tagger.tags": "alias:\"oauth2_account\"" } }
97
102
  ]);
98
103
  }
99
104
  create(value?: PartialMessage<Account>): Account {
@@ -121,22 +126,25 @@ class Account$Type extends MessageType<Account> {
121
126
  case /* optional resources.timestamp.Timestamp updated_at */ 3:
122
127
  message.updatedAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.updatedAt);
123
128
  break;
124
- case /* bool enabled */ 4:
129
+ case /* optional resources.timestamp.Timestamp deleted_at */ 4:
130
+ message.deletedAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.deletedAt);
131
+ break;
132
+ case /* bool enabled */ 5:
125
133
  message.enabled = reader.bool();
126
134
  break;
127
- case /* string username */ 5:
135
+ case /* string username */ 6:
128
136
  message.username = reader.string();
129
137
  break;
130
- case /* string license */ 6:
138
+ case /* string license */ 7:
131
139
  message.license = reader.string();
132
140
  break;
133
- case /* optional resources.accounts.AccountGroups groups */ 7:
141
+ case /* optional resources.accounts.AccountGroups groups */ 8:
134
142
  message.groups = AccountGroups.internalBinaryRead(reader, reader.uint32(), options, message.groups);
135
143
  break;
136
- case /* optional int32 last_char */ 8:
144
+ case /* optional int32 last_char */ 9:
137
145
  message.lastChar = reader.int32();
138
146
  break;
139
- case /* repeated resources.accounts.oauth2.OAuth2Account oauth2_accounts */ 9:
147
+ case /* repeated resources.accounts.oauth2.OAuth2Account oauth2_accounts */ 10:
140
148
  message.oauth2Accounts.push(OAuth2Account.internalBinaryRead(reader, reader.uint32(), options));
141
149
  break;
142
150
  default:
@@ -160,24 +168,27 @@ class Account$Type extends MessageType<Account> {
160
168
  /* optional resources.timestamp.Timestamp updated_at = 3; */
161
169
  if (message.updatedAt)
162
170
  Timestamp.internalBinaryWrite(message.updatedAt, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
163
- /* bool enabled = 4; */
171
+ /* optional resources.timestamp.Timestamp deleted_at = 4; */
172
+ if (message.deletedAt)
173
+ Timestamp.internalBinaryWrite(message.deletedAt, writer.tag(4, WireType.LengthDelimited).fork(), options).join();
174
+ /* bool enabled = 5; */
164
175
  if (message.enabled !== false)
165
- writer.tag(4, WireType.Varint).bool(message.enabled);
166
- /* string username = 5; */
176
+ writer.tag(5, WireType.Varint).bool(message.enabled);
177
+ /* string username = 6; */
167
178
  if (message.username !== "")
168
- writer.tag(5, WireType.LengthDelimited).string(message.username);
169
- /* string license = 6; */
179
+ writer.tag(6, WireType.LengthDelimited).string(message.username);
180
+ /* string license = 7; */
170
181
  if (message.license !== "")
171
- writer.tag(6, WireType.LengthDelimited).string(message.license);
172
- /* optional resources.accounts.AccountGroups groups = 7; */
182
+ writer.tag(7, WireType.LengthDelimited).string(message.license);
183
+ /* optional resources.accounts.AccountGroups groups = 8; */
173
184
  if (message.groups)
174
- AccountGroups.internalBinaryWrite(message.groups, writer.tag(7, WireType.LengthDelimited).fork(), options).join();
175
- /* optional int32 last_char = 8; */
185
+ AccountGroups.internalBinaryWrite(message.groups, writer.tag(8, WireType.LengthDelimited).fork(), options).join();
186
+ /* optional int32 last_char = 9; */
176
187
  if (message.lastChar !== undefined)
177
- writer.tag(8, WireType.Varint).int32(message.lastChar);
178
- /* repeated resources.accounts.oauth2.OAuth2Account oauth2_accounts = 9; */
188
+ writer.tag(9, WireType.Varint).int32(message.lastChar);
189
+ /* repeated resources.accounts.oauth2.OAuth2Account oauth2_accounts = 10; */
179
190
  for (let i = 0; i < message.oauth2Accounts.length; i++)
180
- OAuth2Account.internalBinaryWrite(message.oauth2Accounts[i], writer.tag(9, WireType.LengthDelimited).fork(), options).join();
191
+ OAuth2Account.internalBinaryWrite(message.oauth2Accounts[i], writer.tag(10, WireType.LengthDelimited).fork(), options).join();
181
192
  let u = options.writeUnknownFields;
182
193
  if (u !== false)
183
194
  (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
@@ -112,7 +112,11 @@ export enum EventAction {
112
112
  /**
113
113
  * @generated from protobuf enum value: EVENT_ACTION_DELETED = 5;
114
114
  */
115
- DELETED = 5
115
+ DELETED = 5,
116
+ /**
117
+ * @generated from protobuf enum value: EVENT_ACTION_RESTORED = 6;
118
+ */
119
+ RESTORED = 6
116
120
  }
117
121
  /**
118
122
  * @generated from protobuf enum resources.audit.EventResult
@@ -79,7 +79,7 @@ class LabelAccess$Type extends MessageType<LabelAccess> {
79
79
  constructor() {
80
80
  super("resources.citizens.labels.LabelAccess", [
81
81
  { no: 1, name: "jobs", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => JobAccess, options: { "buf.validate.field": { repeated: { maxItems: "20" } }, "tagger.tags": "alias:\"job_access\"" } }
82
- ]);
82
+ ], { "codegen.dbscanner.dbscanner": { enabled: true } });
83
83
  }
84
84
  create(value?: PartialMessage<LabelAccess>): LabelAccess {
85
85
  const message = globalThis.Object.create((this.messagePrototype!));
@@ -131,7 +131,7 @@ export interface LabelsChange {
131
131
  /**
132
132
  * @generated from protobuf field: repeated resources.jobs.labels.Label removed = 2
133
133
  */
134
- removed: Label[];
134
+ removed: Label[]; // TODO switch to storing label ids instead of the whole label (resolve labels on client-side)
135
135
  }
136
136
  /**
137
137
  * @generated from protobuf message resources.jobs.colleagues.activity.NameChange