@fivenet-app/gen 2026.5.1 → 2026.7.2

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 (80) hide show
  1. package/clients.ts +6 -0
  2. package/codegen/perms/perms.ts +14 -2
  3. package/codegen/sanitizer/sanitizer.ts +6 -0
  4. package/google/protobuf/descriptor.ts +11 -3
  5. package/google/protobuf/timestamp.ts +7 -6
  6. package/package.json +1 -1
  7. package/perms.ts +352 -8
  8. package/resources/access/access.ts +481 -0
  9. package/resources/calendar/access/access.ts +0 -330
  10. package/resources/calendar/calendar.ts +307 -25
  11. package/resources/calendar/entries/entries.ts +204 -11
  12. package/resources/centrum/units/access/access.ts +0 -373
  13. package/resources/centrum/units/units.ts +20 -8
  14. package/resources/citizens/labels/access.ts +0 -191
  15. package/resources/citizens/labels/labels.ts +20 -8
  16. package/resources/clientconfig/clientconfig.ts +11 -0
  17. package/resources/common/content/diff_activity.ts +1 -1
  18. package/resources/cron/cron.ts +1 -1
  19. package/resources/documents/access/access.ts +0 -329
  20. package/resources/documents/activity/activity.ts +49 -45
  21. package/resources/documents/documents.ts +1 -1
  22. package/resources/documents/requests/requests.ts +1 -1
  23. package/resources/documents/stamps/stamp.ts +40 -210
  24. package/resources/documents/templates/templates.ts +158 -318
  25. package/resources/jobs/colleagues/activity/activity.ts +1 -1
  26. package/resources/jobs/conduct/conduct.ts +2 -2
  27. package/resources/jobs/labels/labels.ts +9 -9
  28. package/resources/laws/laws.ts +24 -0
  29. package/resources/livemap/markers/marker_marker.ts +311 -4
  30. package/resources/mailer/access/access.ts +0 -457
  31. package/resources/mailer/emails/email.ts +4 -4
  32. package/resources/notifications/events/events.ts +37 -2
  33. package/resources/qualifications/access/access.ts +0 -248
  34. package/resources/qualifications/qualifications.ts +9 -9
  35. package/resources/settings/config.ts +64 -5
  36. package/resources/settings/data.ts +1 -1
  37. package/resources/stats/stats.ts +32 -20
  38. package/resources/sync/data/data.ts +26 -1
  39. package/resources/timestamp/timestamp.ts +1 -1
  40. package/resources/userinfo/userinfo.ts +202 -51
  41. package/resources/users/activity/activity.ts +1 -1
  42. package/resources/vehicles/activity/activity.ts +146 -10
  43. package/resources/wiki/access/access.ts +0 -330
  44. package/resources/wiki/activity/activity.ts +45 -45
  45. package/resources/wiki/page.ts +9 -9
  46. package/services/auth/auth.client.ts +15 -2
  47. package/services/auth/auth.ts +135 -0
  48. package/services/calendar/calendar.ts +1 -1
  49. package/services/calendar/entries.ts +12 -1
  50. package/services/centrum/dispatches.ts +27 -7
  51. package/services/centrum/units.client.ts +15 -2
  52. package/services/centrum/units.ts +231 -123
  53. package/services/citizens/citizens.ts +1 -1
  54. package/services/citizens/labels.client.ts +7 -20
  55. package/services/citizens/labels.ts +35 -183
  56. package/services/documents/approval.ts +15 -4
  57. package/services/documents/collab.ts +1 -1
  58. package/services/documents/documents.ts +38 -38
  59. package/services/documents/stats.ts +14 -2
  60. package/services/filestore/filestore.ts +4 -4
  61. package/services/jobs/colleagues.ts +3 -3
  62. package/services/jobs/conduct.ts +15 -4
  63. package/services/jobs/groups.client.ts +22 -0
  64. package/services/jobs/groups.ts +9 -0
  65. package/services/jobs/timeclock.ts +2 -2
  66. package/services/mailer/thread.ts +2 -2
  67. package/services/qualifications/qualifications.ts +52 -34
  68. package/services/settings/accounts.ts +5 -5
  69. package/services/settings/config.ts +2 -2
  70. package/services/settings/cron.ts +2 -2
  71. package/services/settings/laws.client.ts +28 -2
  72. package/services/settings/laws.ts +229 -1
  73. package/services/settings/system.ts +6 -6
  74. package/services/sync/sync.client.ts +129 -20
  75. package/services/sync/sync.ts +262 -19
  76. package/services/vehicles/vehicles.client.ts +13 -0
  77. package/services/vehicles/vehicles.ts +181 -13
  78. package/services/wiki/wiki.client.ts +15 -2
  79. package/services/wiki/wiki.ts +122 -0
  80. package/svcs.ts +21 -2
@@ -11,6 +11,7 @@ import { UnknownFieldHandler } from "@protobuf-ts/runtime";
11
11
  import type { PartialMessage } from "@protobuf-ts/runtime";
12
12
  import { reflectionMergePartial } from "@protobuf-ts/runtime";
13
13
  import { MessageType } from "@protobuf-ts/runtime";
14
+ import { Access } from "../../access/access";
14
15
  import { Timestamp } from "../../timestamp/timestamp";
15
16
  /**
16
17
  * @generated from protobuf message resources.documents.stamps.Stamp
@@ -33,65 +34,27 @@ export interface Stamp {
33
34
  */
34
35
  createdAt?: Timestamp;
35
36
  /**
36
- * @generated from protobuf field: string name = 5
37
+ * @generated from protobuf field: optional resources.timestamp.Timestamp updated_at = 5
37
38
  */
38
- name: string;
39
- /**
40
- * Parameterized SVG with slots
41
- *
42
- * @generated from protobuf field: string svg_template = 6
43
- */
44
- svgTemplate: string;
45
- /**
46
- * @generated from protobuf field: resources.documents.stamps.StampAccess access = 7
47
- */
48
- access?: StampAccess;
49
- }
50
- /**
51
- * @generated from protobuf message resources.documents.stamps.StampAccess
52
- */
53
- export interface StampAccess {
54
- /**
55
- * @generated from protobuf field: repeated resources.documents.stamps.StampJobAccess jobs = 1
56
- */
57
- jobs: StampJobAccess[];
58
- }
59
- /**
60
- * @generated from protobuf message resources.documents.stamps.StampJobAccess
61
- */
62
- export interface StampJobAccess {
63
- /**
64
- * @generated from protobuf field: int64 id = 1
65
- */
66
- id: number;
67
- /**
68
- * @generated from protobuf field: optional resources.timestamp.Timestamp created_at = 2
69
- */
70
- createdAt?: Timestamp;
39
+ updatedAt?: Timestamp;
71
40
  /**
72
- * @generated from protobuf field: int64 target_id = 3
41
+ * @generated from protobuf field: optional resources.timestamp.Timestamp deleted_at = 6
73
42
  */
74
- targetId: number;
43
+ deletedAt?: Timestamp;
75
44
  /**
76
- * @generated from protobuf field: string job = 4
45
+ * @generated from protobuf field: string name = 7
77
46
  */
78
- job: string;
79
- /**
80
- * @generated from protobuf field: optional string job_label = 5
81
- */
82
- jobLabel?: string;
83
- /**
84
- * @generated from protobuf field: int32 minimum_grade = 6
85
- */
86
- minimumGrade: number;
47
+ name: string;
87
48
  /**
88
- * @generated from protobuf field: optional string job_grade_label = 7
49
+ * Parameterized SVG with slots
50
+ *
51
+ * @generated from protobuf field: string svg_template = 8
89
52
  */
90
- jobGradeLabel?: string;
53
+ svgTemplate: string;
91
54
  /**
92
- * @generated from protobuf field: resources.documents.stamps.StampAccessLevel access = 8
55
+ * @generated from protobuf field: resources.access.Access access = 9
93
56
  */
94
- access: StampAccessLevel;
57
+ access?: Access;
95
58
  }
96
59
  /**
97
60
  * @generated from protobuf enum resources.documents.stamps.StampAccessLevel
@@ -122,9 +85,11 @@ class Stamp$Type extends MessageType<Stamp> {
122
85
  { no: 2, name: "job", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "20" } } } },
123
86
  { no: 3, name: "job_label", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
124
87
  { no: 4, name: "created_at", kind: "message", T: () => Timestamp },
125
- { no: 5, name: "name", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "120" } }, "codegen.sanitizer.sanitizer": { enabled: true, stripHtmlTags: true } } },
126
- { no: 6, name: "svg_template", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "codegen.sanitizer.sanitizer": { enabled: true, method: "SanitizeSVG" } } },
127
- { no: 7, name: "access", kind: "message", T: () => StampAccess }
88
+ { no: 5, name: "updated_at", kind: "message", T: () => Timestamp },
89
+ { no: 6, name: "deleted_at", kind: "message", T: () => Timestamp },
90
+ { no: 7, name: "name", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "120" } }, "codegen.sanitizer.sanitizer": { enabled: true, stripHtmlTags: true } } },
91
+ { no: 8, name: "svg_template", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "codegen.sanitizer.sanitizer": { enabled: true, method: "SanitizeSVG" } } },
92
+ { no: 9, name: "access", kind: "message", T: () => Access }
128
93
  ]);
129
94
  }
130
95
  create(value?: PartialMessage<Stamp>): Stamp {
@@ -154,14 +119,20 @@ class Stamp$Type extends MessageType<Stamp> {
154
119
  case /* resources.timestamp.Timestamp created_at */ 4:
155
120
  message.createdAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.createdAt);
156
121
  break;
157
- case /* string name */ 5:
122
+ case /* optional resources.timestamp.Timestamp updated_at */ 5:
123
+ message.updatedAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.updatedAt);
124
+ break;
125
+ case /* optional resources.timestamp.Timestamp deleted_at */ 6:
126
+ message.deletedAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.deletedAt);
127
+ break;
128
+ case /* string name */ 7:
158
129
  message.name = reader.string();
159
130
  break;
160
- case /* string svg_template */ 6:
131
+ case /* string svg_template */ 8:
161
132
  message.svgTemplate = reader.string();
162
133
  break;
163
- case /* resources.documents.stamps.StampAccess access */ 7:
164
- message.access = StampAccess.internalBinaryRead(reader, reader.uint32(), options, message.access);
134
+ case /* resources.access.Access access */ 9:
135
+ message.access = Access.internalBinaryRead(reader, reader.uint32(), options, message.access);
165
136
  break;
166
137
  default:
167
138
  let u = options.readUnknownField;
@@ -187,15 +158,21 @@ class Stamp$Type extends MessageType<Stamp> {
187
158
  /* resources.timestamp.Timestamp created_at = 4; */
188
159
  if (message.createdAt)
189
160
  Timestamp.internalBinaryWrite(message.createdAt, writer.tag(4, WireType.LengthDelimited).fork(), options).join();
190
- /* string name = 5; */
161
+ /* optional resources.timestamp.Timestamp updated_at = 5; */
162
+ if (message.updatedAt)
163
+ Timestamp.internalBinaryWrite(message.updatedAt, writer.tag(5, WireType.LengthDelimited).fork(), options).join();
164
+ /* optional resources.timestamp.Timestamp deleted_at = 6; */
165
+ if (message.deletedAt)
166
+ Timestamp.internalBinaryWrite(message.deletedAt, writer.tag(6, WireType.LengthDelimited).fork(), options).join();
167
+ /* string name = 7; */
191
168
  if (message.name !== "")
192
- writer.tag(5, WireType.LengthDelimited).string(message.name);
193
- /* string svg_template = 6; */
169
+ writer.tag(7, WireType.LengthDelimited).string(message.name);
170
+ /* string svg_template = 8; */
194
171
  if (message.svgTemplate !== "")
195
- writer.tag(6, WireType.LengthDelimited).string(message.svgTemplate);
196
- /* resources.documents.stamps.StampAccess access = 7; */
172
+ writer.tag(8, WireType.LengthDelimited).string(message.svgTemplate);
173
+ /* resources.access.Access access = 9; */
197
174
  if (message.access)
198
- StampAccess.internalBinaryWrite(message.access, writer.tag(7, WireType.LengthDelimited).fork(), options).join();
175
+ Access.internalBinaryWrite(message.access, writer.tag(9, WireType.LengthDelimited).fork(), options).join();
199
176
  let u = options.writeUnknownFields;
200
177
  if (u !== false)
201
178
  (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
@@ -206,150 +183,3 @@ class Stamp$Type extends MessageType<Stamp> {
206
183
  * @generated MessageType for protobuf message resources.documents.stamps.Stamp
207
184
  */
208
185
  export const Stamp = new Stamp$Type();
209
- // @generated message type with reflection information, may provide speed optimized methods
210
- class StampAccess$Type extends MessageType<StampAccess> {
211
- constructor() {
212
- super("resources.documents.stamps.StampAccess", [
213
- { no: 1, name: "jobs", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => StampJobAccess, options: { "buf.validate.field": { repeated: { maxItems: "20" } }, "tagger.tags": "alias:\"job_access\"" } }
214
- ]);
215
- }
216
- create(value?: PartialMessage<StampAccess>): StampAccess {
217
- const message = globalThis.Object.create((this.messagePrototype!));
218
- message.jobs = [];
219
- if (value !== undefined)
220
- reflectionMergePartial<StampAccess>(this, message, value);
221
- return message;
222
- }
223
- internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: StampAccess): StampAccess {
224
- let message = target ?? this.create(), end = reader.pos + length;
225
- while (reader.pos < end) {
226
- let [fieldNo, wireType] = reader.tag();
227
- switch (fieldNo) {
228
- case /* repeated resources.documents.stamps.StampJobAccess jobs */ 1:
229
- message.jobs.push(StampJobAccess.internalBinaryRead(reader, reader.uint32(), options));
230
- break;
231
- default:
232
- let u = options.readUnknownField;
233
- if (u === "throw")
234
- throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
235
- let d = reader.skip(wireType);
236
- if (u !== false)
237
- (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
238
- }
239
- }
240
- return message;
241
- }
242
- internalBinaryWrite(message: StampAccess, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
243
- /* repeated resources.documents.stamps.StampJobAccess jobs = 1; */
244
- for (let i = 0; i < message.jobs.length; i++)
245
- StampJobAccess.internalBinaryWrite(message.jobs[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join();
246
- let u = options.writeUnknownFields;
247
- if (u !== false)
248
- (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
249
- return writer;
250
- }
251
- }
252
- /**
253
- * @generated MessageType for protobuf message resources.documents.stamps.StampAccess
254
- */
255
- export const StampAccess = new StampAccess$Type();
256
- // @generated message type with reflection information, may provide speed optimized methods
257
- class StampJobAccess$Type extends MessageType<StampJobAccess> {
258
- constructor() {
259
- super("resources.documents.stamps.StampJobAccess", [
260
- { no: 1, name: "id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
261
- { no: 2, name: "created_at", kind: "message", T: () => Timestamp },
262
- { no: 3, name: "target_id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
263
- { no: 4, name: "job", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "20" } } } },
264
- { no: 5, name: "job_label", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "50" } } } },
265
- { no: 6, name: "minimum_grade", kind: "scalar", T: 5 /*ScalarType.INT32*/, options: { "buf.validate.field": { int32: { gte: 0 } } } },
266
- { no: 7, name: "job_grade_label", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "50" } } } },
267
- { no: 8, name: "access", kind: "enum", T: () => ["resources.documents.stamps.StampAccessLevel", StampAccessLevel, "STAMP_ACCESS_LEVEL_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } }
268
- ]);
269
- }
270
- create(value?: PartialMessage<StampJobAccess>): StampJobAccess {
271
- const message = globalThis.Object.create((this.messagePrototype!));
272
- message.id = 0;
273
- message.targetId = 0;
274
- message.job = "";
275
- message.minimumGrade = 0;
276
- message.access = 0;
277
- if (value !== undefined)
278
- reflectionMergePartial<StampJobAccess>(this, message, value);
279
- return message;
280
- }
281
- internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: StampJobAccess): StampJobAccess {
282
- let message = target ?? this.create(), end = reader.pos + length;
283
- while (reader.pos < end) {
284
- let [fieldNo, wireType] = reader.tag();
285
- switch (fieldNo) {
286
- case /* int64 id */ 1:
287
- message.id = reader.int64().toNumber();
288
- break;
289
- case /* optional resources.timestamp.Timestamp created_at */ 2:
290
- message.createdAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.createdAt);
291
- break;
292
- case /* int64 target_id */ 3:
293
- message.targetId = reader.int64().toNumber();
294
- break;
295
- case /* string job */ 4:
296
- message.job = reader.string();
297
- break;
298
- case /* optional string job_label */ 5:
299
- message.jobLabel = reader.string();
300
- break;
301
- case /* int32 minimum_grade */ 6:
302
- message.minimumGrade = reader.int32();
303
- break;
304
- case /* optional string job_grade_label */ 7:
305
- message.jobGradeLabel = reader.string();
306
- break;
307
- case /* resources.documents.stamps.StampAccessLevel access */ 8:
308
- message.access = reader.int32();
309
- break;
310
- default:
311
- let u = options.readUnknownField;
312
- if (u === "throw")
313
- throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
314
- let d = reader.skip(wireType);
315
- if (u !== false)
316
- (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
317
- }
318
- }
319
- return message;
320
- }
321
- internalBinaryWrite(message: StampJobAccess, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
322
- /* int64 id = 1; */
323
- if (message.id !== 0)
324
- writer.tag(1, WireType.Varint).int64(message.id);
325
- /* optional resources.timestamp.Timestamp created_at = 2; */
326
- if (message.createdAt)
327
- Timestamp.internalBinaryWrite(message.createdAt, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
328
- /* int64 target_id = 3; */
329
- if (message.targetId !== 0)
330
- writer.tag(3, WireType.Varint).int64(message.targetId);
331
- /* string job = 4; */
332
- if (message.job !== "")
333
- writer.tag(4, WireType.LengthDelimited).string(message.job);
334
- /* optional string job_label = 5; */
335
- if (message.jobLabel !== undefined)
336
- writer.tag(5, WireType.LengthDelimited).string(message.jobLabel);
337
- /* int32 minimum_grade = 6; */
338
- if (message.minimumGrade !== 0)
339
- writer.tag(6, WireType.Varint).int32(message.minimumGrade);
340
- /* optional string job_grade_label = 7; */
341
- if (message.jobGradeLabel !== undefined)
342
- writer.tag(7, WireType.LengthDelimited).string(message.jobGradeLabel);
343
- /* resources.documents.stamps.StampAccessLevel access = 8; */
344
- if (message.access !== 0)
345
- writer.tag(8, WireType.Varint).int32(message.access);
346
- let u = options.writeUnknownFields;
347
- if (u !== false)
348
- (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
349
- return writer;
350
- }
351
- }
352
- /**
353
- * @generated MessageType for protobuf message resources.documents.stamps.StampJobAccess
354
- */
355
- export const StampJobAccess = new StampJobAccess$Type();