@fivenet-app/gen 2026.8.0 → 2026.8.5
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.
- package/google/protobuf/descriptor.ts +3 -11
- package/google/protobuf/timestamp.ts +6 -7
- package/package.json +1 -1
- package/perms.ts +17 -4
- package/resources/calendar/calendar.ts +11 -0
- package/resources/calendar/entries/entries.ts +23 -0
- package/resources/centrum/dispatches/dispatches.ts +8 -8
- package/resources/centrum/units/units.ts +5 -5
- package/resources/citizens/labels/access.ts +10 -6
- package/resources/dbsync/state.ts +192 -0
- package/resources/documents/stamps/access.ts +25 -0
- package/resources/documents/stamps/stamp.ts +0 -21
- package/resources/documents/templates/templates.ts +61 -59
- package/resources/documents/workflow/workflow.ts +61 -1
- package/resources/jobs/groups/access/access.ts +29 -0
- package/resources/jobs/groups/activity.ts +332 -0
- package/resources/jobs/groups/group.ts +1666 -0
- package/resources/jobs/user_selector.ts +184 -0
- package/resources/settings/status.ts +197 -105
- package/services/calendar/calendar.ts +1 -1
- package/services/calendar/entries.ts +3 -3
- package/services/centrum/units.ts +3 -3
- package/services/completor/completor.ts +2 -2
- package/services/documents/approval.ts +2 -2
- package/services/documents/documents.ts +9 -9
- package/services/documents/templates.ts +13 -13
- package/services/jobs/colleagues.client.ts +34 -8
- package/services/jobs/colleagues.ts +263 -74
- package/services/jobs/conduct.ts +11 -19
- package/services/jobs/groups.client.ts +311 -0
- package/services/jobs/groups.ts +3596 -1
- package/services/jobs/timeclock.ts +30 -27
- package/services/qualifications/qualifications.ts +26 -4
- package/services/settings/settings.ts +1 -1
- package/services/sync/sync.client.ts +69 -33
- package/services/sync/sync.ts +442 -6
- package/services/vehicles/vehicles.ts +2 -2
- package/svcs.ts +29 -1
|
@@ -0,0 +1,1666 @@
|
|
|
1
|
+
// @generated by protobuf-ts 2.11.1 with parameter force_server_none,long_type_number,optimize_speed,ts_nocheck
|
|
2
|
+
// @generated from protobuf file "resources/jobs/groups/group.proto" (package "resources.jobs.groups", syntax proto3)
|
|
3
|
+
// tslint:disable
|
|
4
|
+
// @ts-nocheck
|
|
5
|
+
import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
|
|
6
|
+
import type { IBinaryWriter } from "@protobuf-ts/runtime";
|
|
7
|
+
import { WireType } from "@protobuf-ts/runtime";
|
|
8
|
+
import type { BinaryReadOptions } from "@protobuf-ts/runtime";
|
|
9
|
+
import type { IBinaryReader } from "@protobuf-ts/runtime";
|
|
10
|
+
import { UnknownFieldHandler } from "@protobuf-ts/runtime";
|
|
11
|
+
import type { PartialMessage } from "@protobuf-ts/runtime";
|
|
12
|
+
import { reflectionMergePartial } from "@protobuf-ts/runtime";
|
|
13
|
+
import { MessageType } from "@protobuf-ts/runtime";
|
|
14
|
+
import { QualificationShort } from "../../qualifications/qualifications";
|
|
15
|
+
import { Timestamp } from "../../timestamp/timestamp";
|
|
16
|
+
import { Colleague } from "../colleagues/colleagues";
|
|
17
|
+
import { File } from "../../file/file";
|
|
18
|
+
/**
|
|
19
|
+
* @generated from protobuf message resources.jobs.groups.Group
|
|
20
|
+
*/
|
|
21
|
+
export interface Group {
|
|
22
|
+
/**
|
|
23
|
+
* @generated from protobuf field: int64 id = 1
|
|
24
|
+
*/
|
|
25
|
+
id: number;
|
|
26
|
+
/**
|
|
27
|
+
* Job this group belongs to. Groups are job-local.
|
|
28
|
+
*
|
|
29
|
+
* @generated from protobuf field: string job = 2
|
|
30
|
+
*/
|
|
31
|
+
job: string;
|
|
32
|
+
/**
|
|
33
|
+
* Main display name, e.g. "Traffic Unit" or "Command Staff".
|
|
34
|
+
*
|
|
35
|
+
* @generated from protobuf field: string name = 3
|
|
36
|
+
*/
|
|
37
|
+
name: string;
|
|
38
|
+
/**
|
|
39
|
+
* Optional longer explanation of the group's purpose.
|
|
40
|
+
*
|
|
41
|
+
* @generated from protobuf field: optional string description = 4
|
|
42
|
+
*/
|
|
43
|
+
description?: string;
|
|
44
|
+
/**
|
|
45
|
+
* Optional compact display name, e.g. "TRF" or "CMD".
|
|
46
|
+
*
|
|
47
|
+
* @generated from protobuf field: optional string short_name = 5
|
|
48
|
+
*/
|
|
49
|
+
shortName?: string;
|
|
50
|
+
/**
|
|
51
|
+
* Optional file/avatar/logo ID reference.
|
|
52
|
+
*
|
|
53
|
+
* @generated from protobuf field: optional int64 logo_file_id = 6
|
|
54
|
+
*/
|
|
55
|
+
logoFileId?: number;
|
|
56
|
+
/**
|
|
57
|
+
* Optional file/avatar/logo reference.
|
|
58
|
+
*
|
|
59
|
+
* @generated from protobuf field: optional resources.file.File logo_file = 7
|
|
60
|
+
*/
|
|
61
|
+
logoFile?: File;
|
|
62
|
+
/**
|
|
63
|
+
* Optional UI color, e.g. hex color or predefined token depending on frontend convention.
|
|
64
|
+
*
|
|
65
|
+
* @generated from protobuf field: optional string color = 8
|
|
66
|
+
*/
|
|
67
|
+
color?: string;
|
|
68
|
+
/**
|
|
69
|
+
* Describes the broad membership behavior.
|
|
70
|
+
* This can also be derived from rules/manual members, but storing it can simplify UI.
|
|
71
|
+
*
|
|
72
|
+
* @generated from protobuf field: resources.jobs.groups.GroupType type = 9
|
|
73
|
+
*/
|
|
74
|
+
type: GroupType;
|
|
75
|
+
/**
|
|
76
|
+
* Current lifecycle state.
|
|
77
|
+
*
|
|
78
|
+
* @generated from protobuf field: resources.jobs.groups.GroupState state = 10
|
|
79
|
+
*/
|
|
80
|
+
state: GroupState;
|
|
81
|
+
/**
|
|
82
|
+
* Controls whether manually added members must satisfy smart membership rules.
|
|
83
|
+
*
|
|
84
|
+
* @generated from protobuf field: resources.jobs.groups.GroupMembershipMode membership_mode = 11
|
|
85
|
+
*/
|
|
86
|
+
membershipMode: GroupMembershipMode;
|
|
87
|
+
/**
|
|
88
|
+
* Lexicographic rank for manual group ordering.
|
|
89
|
+
*
|
|
90
|
+
* @generated from protobuf field: string sort_rank = 12
|
|
91
|
+
*/
|
|
92
|
+
sortRank: string;
|
|
93
|
+
/**
|
|
94
|
+
* Cached/resolved count of current non-excluded members.
|
|
95
|
+
*
|
|
96
|
+
* @generated from protobuf field: int32 members_count = 13
|
|
97
|
+
*/
|
|
98
|
+
membersCount: number;
|
|
99
|
+
/**
|
|
100
|
+
* Cached count of assigned group leaders.
|
|
101
|
+
*
|
|
102
|
+
* @generated from protobuf field: int32 leaders_count = 14
|
|
103
|
+
*/
|
|
104
|
+
leadersCount: number;
|
|
105
|
+
/**
|
|
106
|
+
* Cached count of enabled/defined membership rules.
|
|
107
|
+
*
|
|
108
|
+
* @generated from protobuf field: int32 rules_count = 15
|
|
109
|
+
*/
|
|
110
|
+
rulesCount: number;
|
|
111
|
+
/**
|
|
112
|
+
* Cached count of manual exclusions.
|
|
113
|
+
*
|
|
114
|
+
* @generated from protobuf field: int32 exclusions_count = 16
|
|
115
|
+
*/
|
|
116
|
+
exclusionsCount: number;
|
|
117
|
+
/**
|
|
118
|
+
* User who created the group.
|
|
119
|
+
*
|
|
120
|
+
* @generated from protobuf field: optional int32 created_by_user_id = 17
|
|
121
|
+
*/
|
|
122
|
+
createdByUserId?: number;
|
|
123
|
+
/**
|
|
124
|
+
* @generated from protobuf field: optional resources.jobs.colleagues.Colleague created_by = 18
|
|
125
|
+
*/
|
|
126
|
+
createdBy?: Colleague;
|
|
127
|
+
/**
|
|
128
|
+
* User who last updated the group metadata.
|
|
129
|
+
*
|
|
130
|
+
* @generated from protobuf field: optional int32 updated_by_user_id = 19
|
|
131
|
+
*/
|
|
132
|
+
updatedByUserId?: number;
|
|
133
|
+
/**
|
|
134
|
+
* @generated from protobuf field: resources.timestamp.Timestamp created_at = 20
|
|
135
|
+
*/
|
|
136
|
+
createdAt?: Timestamp;
|
|
137
|
+
/**
|
|
138
|
+
* @generated from protobuf field: optional resources.timestamp.Timestamp updated_at = 21
|
|
139
|
+
*/
|
|
140
|
+
updatedAt?: Timestamp;
|
|
141
|
+
/**
|
|
142
|
+
* Set when the group is "archived"/deleted.
|
|
143
|
+
*
|
|
144
|
+
* @generated from protobuf field: optional resources.timestamp.Timestamp deleted_at = 22
|
|
145
|
+
*/
|
|
146
|
+
deletedAt?: Timestamp;
|
|
147
|
+
}
|
|
148
|
+
/**
|
|
149
|
+
* @generated from protobuf message resources.jobs.groups.GroupLeader
|
|
150
|
+
*/
|
|
151
|
+
export interface GroupLeader {
|
|
152
|
+
/**
|
|
153
|
+
* Group this leader relation belongs to.
|
|
154
|
+
*
|
|
155
|
+
* @generated from protobuf field: int64 group_id = 1
|
|
156
|
+
*/
|
|
157
|
+
groupId: number;
|
|
158
|
+
/**
|
|
159
|
+
* User who can manage/supervise the group.
|
|
160
|
+
* A leader does not automatically have to be a member.
|
|
161
|
+
*
|
|
162
|
+
* @generated from protobuf field: int32 user_id = 2
|
|
163
|
+
*/
|
|
164
|
+
userId: number;
|
|
165
|
+
/**
|
|
166
|
+
* @generated from protobuf field: optional resources.jobs.colleagues.Colleague colleague = 3
|
|
167
|
+
*/
|
|
168
|
+
colleague?: Colleague;
|
|
169
|
+
/**
|
|
170
|
+
* User who assigned this leader.
|
|
171
|
+
*
|
|
172
|
+
* @generated from protobuf field: optional int32 created_by_user_id = 4
|
|
173
|
+
*/
|
|
174
|
+
createdByUserId?: number;
|
|
175
|
+
/**
|
|
176
|
+
* @generated from protobuf field: optional resources.jobs.colleagues.Colleague created_by = 5
|
|
177
|
+
*/
|
|
178
|
+
createdBy?: Colleague;
|
|
179
|
+
/**
|
|
180
|
+
* @generated from protobuf field: resources.timestamp.Timestamp created_at = 6
|
|
181
|
+
*/
|
|
182
|
+
createdAt?: Timestamp;
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* @generated from protobuf message resources.jobs.groups.GroupManualMember
|
|
186
|
+
*/
|
|
187
|
+
export interface GroupManualMember {
|
|
188
|
+
/**
|
|
189
|
+
* Group this manual member relation belongs to.
|
|
190
|
+
*
|
|
191
|
+
* @generated from protobuf field: int64 group_id = 1
|
|
192
|
+
*/
|
|
193
|
+
groupId: number;
|
|
194
|
+
/**
|
|
195
|
+
* User explicitly added to the group.
|
|
196
|
+
*
|
|
197
|
+
* @generated from protobuf field: int32 user_id = 2
|
|
198
|
+
*/
|
|
199
|
+
userId: number;
|
|
200
|
+
/**
|
|
201
|
+
* @generated from protobuf field: optional resources.jobs.colleagues.Colleague colleague = 3
|
|
202
|
+
*/
|
|
203
|
+
colleague?: Colleague;
|
|
204
|
+
/**
|
|
205
|
+
* Optional admin/leader-provided reason for the manual assignment.
|
|
206
|
+
*
|
|
207
|
+
* @generated from protobuf field: optional string reason = 4
|
|
208
|
+
*/
|
|
209
|
+
reason?: string;
|
|
210
|
+
/**
|
|
211
|
+
* User who added this manual member.
|
|
212
|
+
*
|
|
213
|
+
* @generated from protobuf field: optional int32 created_by_user_id = 5
|
|
214
|
+
*/
|
|
215
|
+
createdByUserId?: number;
|
|
216
|
+
/**
|
|
217
|
+
* @generated from protobuf field: optional resources.jobs.colleagues.Colleague created_by = 6
|
|
218
|
+
*/
|
|
219
|
+
createdBy?: Colleague;
|
|
220
|
+
/**
|
|
221
|
+
* @generated from protobuf field: resources.timestamp.Timestamp created_at = 7
|
|
222
|
+
*/
|
|
223
|
+
createdAt?: Timestamp;
|
|
224
|
+
}
|
|
225
|
+
/**
|
|
226
|
+
* @generated from protobuf message resources.jobs.groups.GroupMemberExclusion
|
|
227
|
+
*/
|
|
228
|
+
export interface GroupMemberExclusion {
|
|
229
|
+
/**
|
|
230
|
+
* Group this exclusion belongs to.
|
|
231
|
+
*
|
|
232
|
+
* @generated from protobuf field: int64 group_id = 1
|
|
233
|
+
*/
|
|
234
|
+
groupId: number;
|
|
235
|
+
/**
|
|
236
|
+
* User excluded from resolved group membership.
|
|
237
|
+
*
|
|
238
|
+
* @generated from protobuf field: int32 user_id = 2
|
|
239
|
+
*/
|
|
240
|
+
userId: number;
|
|
241
|
+
/**
|
|
242
|
+
* @generated from protobuf field: optional resources.jobs.colleagues.Colleague colleague = 3
|
|
243
|
+
*/
|
|
244
|
+
colleague?: Colleague;
|
|
245
|
+
/**
|
|
246
|
+
* Structured exclusion reason.
|
|
247
|
+
*
|
|
248
|
+
* @generated from protobuf field: resources.jobs.groups.GroupExclusionReason reason_type = 4
|
|
249
|
+
*/
|
|
250
|
+
reasonType: GroupExclusionReason;
|
|
251
|
+
/**
|
|
252
|
+
* Optional human-readable reason.
|
|
253
|
+
*
|
|
254
|
+
* @generated from protobuf field: optional string reason = 5
|
|
255
|
+
*/
|
|
256
|
+
reason?: string;
|
|
257
|
+
/**
|
|
258
|
+
* User who created the exclusion.
|
|
259
|
+
*
|
|
260
|
+
* @generated from protobuf field: optional int32 created_by_user_id = 6
|
|
261
|
+
*/
|
|
262
|
+
createdByUserId?: number;
|
|
263
|
+
/**
|
|
264
|
+
* @generated from protobuf field: optional resources.jobs.colleagues.Colleague created_by = 7
|
|
265
|
+
*/
|
|
266
|
+
createdBy?: Colleague;
|
|
267
|
+
/**
|
|
268
|
+
* @generated from protobuf field: resources.timestamp.Timestamp created_at = 8
|
|
269
|
+
*/
|
|
270
|
+
createdAt?: Timestamp;
|
|
271
|
+
}
|
|
272
|
+
/**
|
|
273
|
+
* @generated from protobuf message resources.jobs.groups.GroupGradeRule
|
|
274
|
+
*/
|
|
275
|
+
export interface GroupGradeRule {
|
|
276
|
+
/**
|
|
277
|
+
* Determines which grade fields are used.
|
|
278
|
+
*
|
|
279
|
+
* @generated from protobuf field: resources.jobs.groups.GroupGradeRuleType type = 1
|
|
280
|
+
*/
|
|
281
|
+
type: GroupGradeRuleType;
|
|
282
|
+
/**
|
|
283
|
+
* Used by MINIMUM and EXACT.
|
|
284
|
+
*
|
|
285
|
+
* @generated from protobuf field: optional int32 grade = 2
|
|
286
|
+
*/
|
|
287
|
+
grade?: number;
|
|
288
|
+
/**
|
|
289
|
+
* Used by RANGE.
|
|
290
|
+
*
|
|
291
|
+
* @generated from protobuf field: optional int32 min_grade = 3
|
|
292
|
+
*/
|
|
293
|
+
minGrade?: number;
|
|
294
|
+
/**
|
|
295
|
+
* Used by RANGE.
|
|
296
|
+
*
|
|
297
|
+
* @generated from protobuf field: optional int32 max_grade = 4
|
|
298
|
+
*/
|
|
299
|
+
maxGrade?: number;
|
|
300
|
+
/**
|
|
301
|
+
* Label for grade, used by MINIMUM and EXACT.
|
|
302
|
+
*
|
|
303
|
+
* @generated from protobuf field: optional string grade_label = 5
|
|
304
|
+
*/
|
|
305
|
+
gradeLabel?: string;
|
|
306
|
+
/**
|
|
307
|
+
* Label for min_grade, used by RANGE.
|
|
308
|
+
*
|
|
309
|
+
* @generated from protobuf field: optional string min_grade_label = 6
|
|
310
|
+
*/
|
|
311
|
+
minGradeLabel?: string;
|
|
312
|
+
/**
|
|
313
|
+
* Label for max_grade, used by RANGE.
|
|
314
|
+
*
|
|
315
|
+
* @generated from protobuf field: optional string max_grade_label = 7
|
|
316
|
+
*/
|
|
317
|
+
maxGradeLabel?: string;
|
|
318
|
+
}
|
|
319
|
+
/**
|
|
320
|
+
* @generated from protobuf message resources.jobs.groups.GroupQualificationRule
|
|
321
|
+
*/
|
|
322
|
+
export interface GroupQualificationRule {
|
|
323
|
+
/**
|
|
324
|
+
* Determines whether all or any listed qualifications are required.
|
|
325
|
+
*
|
|
326
|
+
* @generated from protobuf field: resources.jobs.groups.GroupQualificationRuleType type = 1
|
|
327
|
+
*/
|
|
328
|
+
type: GroupQualificationRuleType;
|
|
329
|
+
/**
|
|
330
|
+
* Qualification IDs checked by this rule.
|
|
331
|
+
*
|
|
332
|
+
* @generated from protobuf field: repeated int64 qualification_ids = 2
|
|
333
|
+
*/
|
|
334
|
+
qualificationIds: number[];
|
|
335
|
+
/**
|
|
336
|
+
* If true, only completed/successful qualifications count.
|
|
337
|
+
*
|
|
338
|
+
* @generated from protobuf field: bool require_completed = 3
|
|
339
|
+
*/
|
|
340
|
+
requireCompleted: boolean;
|
|
341
|
+
/**
|
|
342
|
+
* Hydrated display data for the UI.
|
|
343
|
+
*
|
|
344
|
+
* @generated from protobuf field: repeated resources.qualifications.QualificationShort qualifications = 4
|
|
345
|
+
*/
|
|
346
|
+
qualifications: QualificationShort[];
|
|
347
|
+
}
|
|
348
|
+
/**
|
|
349
|
+
* @generated from protobuf message resources.jobs.groups.GroupRule
|
|
350
|
+
*/
|
|
351
|
+
export interface GroupRule {
|
|
352
|
+
/**
|
|
353
|
+
* @generated from protobuf field: int64 id = 1
|
|
354
|
+
*/
|
|
355
|
+
id: number;
|
|
356
|
+
/**
|
|
357
|
+
* Group this rule belongs to.
|
|
358
|
+
*
|
|
359
|
+
* @generated from protobuf field: int64 group_id = 2
|
|
360
|
+
*/
|
|
361
|
+
groupId: number;
|
|
362
|
+
/**
|
|
363
|
+
* Disabled rules remain stored but do not affect resolved membership.
|
|
364
|
+
*
|
|
365
|
+
* @generated from protobuf field: bool enabled = 3
|
|
366
|
+
*/
|
|
367
|
+
enabled: boolean;
|
|
368
|
+
/**
|
|
369
|
+
* Stored rule body discriminator. This duplicates the oneof for DB/query mapping.
|
|
370
|
+
*
|
|
371
|
+
* @generated from protobuf field: resources.jobs.groups.GroupRuleType type = 4
|
|
372
|
+
*/
|
|
373
|
+
type: GroupRuleType;
|
|
374
|
+
/**
|
|
375
|
+
* @generated from protobuf oneof: rule
|
|
376
|
+
*/
|
|
377
|
+
rule: {
|
|
378
|
+
oneofKind: "grade";
|
|
379
|
+
/**
|
|
380
|
+
* Grade/rank-based membership rule.
|
|
381
|
+
*
|
|
382
|
+
* @generated from protobuf field: resources.jobs.groups.GroupGradeRule grade = 5
|
|
383
|
+
*/
|
|
384
|
+
grade: GroupGradeRule;
|
|
385
|
+
} | {
|
|
386
|
+
oneofKind: "qualification";
|
|
387
|
+
/**
|
|
388
|
+
* Qualification-based membership rule.
|
|
389
|
+
*
|
|
390
|
+
* @generated from protobuf field: resources.jobs.groups.GroupQualificationRule qualification = 6
|
|
391
|
+
*/
|
|
392
|
+
qualification: GroupQualificationRule;
|
|
393
|
+
} | {
|
|
394
|
+
oneofKind: undefined;
|
|
395
|
+
};
|
|
396
|
+
/**
|
|
397
|
+
* User who created the rule.
|
|
398
|
+
*
|
|
399
|
+
* @generated from protobuf field: optional int32 created_by_user_id = 7
|
|
400
|
+
*/
|
|
401
|
+
createdByUserId?: number;
|
|
402
|
+
/**
|
|
403
|
+
* @generated from protobuf field: optional resources.jobs.colleagues.Colleague created_by = 8
|
|
404
|
+
*/
|
|
405
|
+
createdBy?: Colleague;
|
|
406
|
+
/**
|
|
407
|
+
* @generated from protobuf field: resources.timestamp.Timestamp created_at = 9
|
|
408
|
+
*/
|
|
409
|
+
createdAt?: Timestamp;
|
|
410
|
+
/**
|
|
411
|
+
* @generated from protobuf field: optional resources.timestamp.Timestamp updated_at = 10
|
|
412
|
+
*/
|
|
413
|
+
updatedAt?: Timestamp;
|
|
414
|
+
}
|
|
415
|
+
/**
|
|
416
|
+
* @generated from protobuf message resources.jobs.groups.GroupMembershipReason
|
|
417
|
+
*/
|
|
418
|
+
export interface GroupMembershipReason {
|
|
419
|
+
/**
|
|
420
|
+
* Source category that explains why the user appears in the resolved view.
|
|
421
|
+
*
|
|
422
|
+
* @generated from protobuf field: resources.jobs.groups.GroupMemberSource source = 1
|
|
423
|
+
*/
|
|
424
|
+
source: GroupMemberSource;
|
|
425
|
+
/**
|
|
426
|
+
* Rule that caused the membership, if source is RULE.
|
|
427
|
+
*
|
|
428
|
+
* @generated from protobuf field: optional int64 rule_id = 2
|
|
429
|
+
*/
|
|
430
|
+
ruleId?: number;
|
|
431
|
+
/**
|
|
432
|
+
* Structured reason for UI display/translation.
|
|
433
|
+
*
|
|
434
|
+
* @generated from protobuf field: resources.jobs.groups.GroupMembershipReasonType type = 3
|
|
435
|
+
*/
|
|
436
|
+
type: GroupMembershipReasonType;
|
|
437
|
+
/**
|
|
438
|
+
* Optional free-form detail such as a manually entered reason.
|
|
439
|
+
*
|
|
440
|
+
* @generated from protobuf field: optional string detail = 4
|
|
441
|
+
*/
|
|
442
|
+
detail?: string;
|
|
443
|
+
}
|
|
444
|
+
/**
|
|
445
|
+
* @generated from protobuf message resources.jobs.groups.GroupResolvedMember
|
|
446
|
+
*/
|
|
447
|
+
export interface GroupResolvedMember {
|
|
448
|
+
/**
|
|
449
|
+
* Group this resolved membership belongs to.
|
|
450
|
+
*
|
|
451
|
+
* @generated from protobuf field: int64 group_id = 1
|
|
452
|
+
*/
|
|
453
|
+
groupId: number;
|
|
454
|
+
/**
|
|
455
|
+
* User being described.
|
|
456
|
+
*
|
|
457
|
+
* @generated from protobuf field: int32 user_id = 2
|
|
458
|
+
*/
|
|
459
|
+
userId: number;
|
|
460
|
+
/**
|
|
461
|
+
* @generated from protobuf field: optional resources.jobs.colleagues.Colleague colleague = 3
|
|
462
|
+
*/
|
|
463
|
+
colleague?: Colleague;
|
|
464
|
+
/**
|
|
465
|
+
* True if the user is part of the final operational member set.
|
|
466
|
+
*
|
|
467
|
+
* @generated from protobuf field: bool is_member = 4
|
|
468
|
+
*/
|
|
469
|
+
isMember: boolean;
|
|
470
|
+
/**
|
|
471
|
+
* True if the user is a group leader.
|
|
472
|
+
*
|
|
473
|
+
* @generated from protobuf field: bool is_leader = 5
|
|
474
|
+
*/
|
|
475
|
+
isLeader: boolean;
|
|
476
|
+
/**
|
|
477
|
+
* True if the user was excluded from final membership.
|
|
478
|
+
*
|
|
479
|
+
* @generated from protobuf field: bool is_excluded = 6
|
|
480
|
+
*/
|
|
481
|
+
isExcluded: boolean;
|
|
482
|
+
/**
|
|
483
|
+
* High-level membership sources that apply to this user.
|
|
484
|
+
*
|
|
485
|
+
* @generated from protobuf field: repeated resources.jobs.groups.GroupMemberSource sources = 7
|
|
486
|
+
*/
|
|
487
|
+
sources: GroupMemberSource[];
|
|
488
|
+
/**
|
|
489
|
+
* Detailed explanations for the UI/admin view.
|
|
490
|
+
*
|
|
491
|
+
* @generated from protobuf field: repeated resources.jobs.groups.GroupMembershipReason reasons = 8
|
|
492
|
+
*/
|
|
493
|
+
reasons: GroupMembershipReason[];
|
|
494
|
+
}
|
|
495
|
+
/**
|
|
496
|
+
* @generated from protobuf enum resources.jobs.groups.GroupType
|
|
497
|
+
*/
|
|
498
|
+
export enum GroupType {
|
|
499
|
+
/**
|
|
500
|
+
* @generated from protobuf enum value: GROUP_TYPE_UNSPECIFIED = 0;
|
|
501
|
+
*/
|
|
502
|
+
UNSPECIFIED = 0,
|
|
503
|
+
/**
|
|
504
|
+
* Membership is only based on explicitly added manual members.
|
|
505
|
+
*
|
|
506
|
+
* @generated from protobuf enum value: GROUP_TYPE_MANUAL = 1;
|
|
507
|
+
*/
|
|
508
|
+
MANUAL = 1,
|
|
509
|
+
/**
|
|
510
|
+
* Membership is derived from rules, such as grade/rank or qualifications.
|
|
511
|
+
*
|
|
512
|
+
* @generated from protobuf enum value: GROUP_TYPE_SMART = 2;
|
|
513
|
+
*/
|
|
514
|
+
SMART = 2,
|
|
515
|
+
/**
|
|
516
|
+
* Membership is derived from rules and adjusted by manual includes/exclusions.
|
|
517
|
+
*
|
|
518
|
+
* @generated from protobuf enum value: GROUP_TYPE_MIXED = 3;
|
|
519
|
+
*/
|
|
520
|
+
MIXED = 3
|
|
521
|
+
}
|
|
522
|
+
/**
|
|
523
|
+
* @generated from protobuf enum resources.jobs.groups.GroupState
|
|
524
|
+
*/
|
|
525
|
+
export enum GroupState {
|
|
526
|
+
/**
|
|
527
|
+
* @generated from protobuf enum value: GROUP_STATE_UNSPECIFIED = 0;
|
|
528
|
+
*/
|
|
529
|
+
UNSPECIFIED = 0,
|
|
530
|
+
/**
|
|
531
|
+
* Group is active and appears in normal group filters/lists.
|
|
532
|
+
*
|
|
533
|
+
* @generated from protobuf enum value: GROUP_STATE_ACTIVE = 1;
|
|
534
|
+
*/
|
|
535
|
+
ACTIVE = 1,
|
|
536
|
+
/**
|
|
537
|
+
* Group still exists but is hidden from default operational views.
|
|
538
|
+
*
|
|
539
|
+
* @generated from protobuf enum value: GROUP_STATE_INACTIVE = 2;
|
|
540
|
+
*/
|
|
541
|
+
INACTIVE = 2,
|
|
542
|
+
/**
|
|
543
|
+
* Group is no longer used for current operations, but remains available for history/activity logs.
|
|
544
|
+
*
|
|
545
|
+
* @generated from protobuf enum value: GROUP_STATE_ARCHIVED = 3;
|
|
546
|
+
*/
|
|
547
|
+
ARCHIVED = 3
|
|
548
|
+
}
|
|
549
|
+
/**
|
|
550
|
+
* @generated from protobuf enum resources.jobs.groups.GroupMembershipMode
|
|
551
|
+
*/
|
|
552
|
+
export enum GroupMembershipMode {
|
|
553
|
+
/**
|
|
554
|
+
* @generated from protobuf enum value: GROUP_MEMBERSHIP_MODE_UNSPECIFIED = 0;
|
|
555
|
+
*/
|
|
556
|
+
UNSPECIFIED = 0,
|
|
557
|
+
/**
|
|
558
|
+
* Manual members may be added even if they do not match the group's rules.
|
|
559
|
+
*
|
|
560
|
+
* @generated from protobuf enum value: GROUP_MEMBERSHIP_MODE_FLEXIBLE = 1;
|
|
561
|
+
*/
|
|
562
|
+
FLEXIBLE = 1,
|
|
563
|
+
/**
|
|
564
|
+
* Manual members must satisfy the group's rules.
|
|
565
|
+
*
|
|
566
|
+
* @generated from protobuf enum value: GROUP_MEMBERSHIP_MODE_STRICT = 2;
|
|
567
|
+
*/
|
|
568
|
+
STRICT = 2
|
|
569
|
+
}
|
|
570
|
+
/**
|
|
571
|
+
* @generated from protobuf enum resources.jobs.groups.GroupExclusionReason
|
|
572
|
+
*/
|
|
573
|
+
export enum GroupExclusionReason {
|
|
574
|
+
/**
|
|
575
|
+
* @generated from protobuf enum value: GROUP_EXCLUSION_REASON_UNSPECIFIED = 0;
|
|
576
|
+
*/
|
|
577
|
+
UNSPECIFIED = 0,
|
|
578
|
+
/**
|
|
579
|
+
* Generic manual exclusion.
|
|
580
|
+
*
|
|
581
|
+
* @generated from protobuf enum value: GROUP_EXCLUSION_REASON_MANUAL = 1;
|
|
582
|
+
*/
|
|
583
|
+
MANUAL = 1,
|
|
584
|
+
/**
|
|
585
|
+
* Temporary exclusion, e.g. paused assignment or temporary reassignment.
|
|
586
|
+
*
|
|
587
|
+
* @generated from protobuf enum value: GROUP_EXCLUSION_REASON_TEMPORARY = 2;
|
|
588
|
+
*/
|
|
589
|
+
TEMPORARY = 2,
|
|
590
|
+
/**
|
|
591
|
+
* User technically matches a rule but should not be considered eligible.
|
|
592
|
+
*
|
|
593
|
+
* @generated from protobuf enum value: GROUP_EXCLUSION_REASON_NOT_ELIGIBLE = 3;
|
|
594
|
+
*/
|
|
595
|
+
NOT_ELIGIBLE = 3,
|
|
596
|
+
/**
|
|
597
|
+
* Any other reason described in the free-text reason field.
|
|
598
|
+
*
|
|
599
|
+
* @generated from protobuf enum value: GROUP_EXCLUSION_REASON_OTHER = 4;
|
|
600
|
+
*/
|
|
601
|
+
OTHER = 4
|
|
602
|
+
}
|
|
603
|
+
/**
|
|
604
|
+
* @generated from protobuf enum resources.jobs.groups.GroupGradeRuleType
|
|
605
|
+
*/
|
|
606
|
+
export enum GroupGradeRuleType {
|
|
607
|
+
/**
|
|
608
|
+
* @generated from protobuf enum value: GROUP_GRADE_RULE_TYPE_UNSPECIFIED = 0;
|
|
609
|
+
*/
|
|
610
|
+
UNSPECIFIED = 0,
|
|
611
|
+
/**
|
|
612
|
+
* Match users with grade >= grade.
|
|
613
|
+
*
|
|
614
|
+
* @generated from protobuf enum value: GROUP_GRADE_RULE_TYPE_MINIMUM = 1;
|
|
615
|
+
*/
|
|
616
|
+
MINIMUM = 1,
|
|
617
|
+
/**
|
|
618
|
+
* Match users with grade == grade.
|
|
619
|
+
*
|
|
620
|
+
* @generated from protobuf enum value: GROUP_GRADE_RULE_TYPE_EXACT = 2;
|
|
621
|
+
*/
|
|
622
|
+
EXACT = 2,
|
|
623
|
+
/**
|
|
624
|
+
* Match users with min_grade <= grade <= max_grade.
|
|
625
|
+
*
|
|
626
|
+
* @generated from protobuf enum value: GROUP_GRADE_RULE_TYPE_RANGE = 3;
|
|
627
|
+
*/
|
|
628
|
+
RANGE = 3
|
|
629
|
+
}
|
|
630
|
+
/**
|
|
631
|
+
* @generated from protobuf enum resources.jobs.groups.GroupQualificationRuleType
|
|
632
|
+
*/
|
|
633
|
+
export enum GroupQualificationRuleType {
|
|
634
|
+
/**
|
|
635
|
+
* @generated from protobuf enum value: GROUP_QUALIFICATION_RULE_TYPE_UNSPECIFIED = 0;
|
|
636
|
+
*/
|
|
637
|
+
UNSPECIFIED = 0,
|
|
638
|
+
/**
|
|
639
|
+
* User must have all listed qualifications.
|
|
640
|
+
*
|
|
641
|
+
* @generated from protobuf enum value: GROUP_QUALIFICATION_RULE_TYPE_ALL = 1;
|
|
642
|
+
*/
|
|
643
|
+
ALL = 1,
|
|
644
|
+
/**
|
|
645
|
+
* User must have at least one listed qualification.
|
|
646
|
+
*
|
|
647
|
+
* @generated from protobuf enum value: GROUP_QUALIFICATION_RULE_TYPE_ANY = 2;
|
|
648
|
+
*/
|
|
649
|
+
ANY = 2
|
|
650
|
+
}
|
|
651
|
+
/**
|
|
652
|
+
* @generated from protobuf enum resources.jobs.groups.GroupRuleType
|
|
653
|
+
*/
|
|
654
|
+
export enum GroupRuleType {
|
|
655
|
+
/**
|
|
656
|
+
* @generated from protobuf enum value: GROUP_RULE_TYPE_UNSPECIFIED = 0;
|
|
657
|
+
*/
|
|
658
|
+
UNSPECIFIED = 0,
|
|
659
|
+
/**
|
|
660
|
+
* Rule has a grade/rank-based rule body.
|
|
661
|
+
*
|
|
662
|
+
* @generated from protobuf enum value: GROUP_RULE_TYPE_GRADE = 1;
|
|
663
|
+
*/
|
|
664
|
+
GRADE = 1,
|
|
665
|
+
/**
|
|
666
|
+
* Rule has a qualification-based rule body.
|
|
667
|
+
*
|
|
668
|
+
* @generated from protobuf enum value: GROUP_RULE_TYPE_QUALIFICATION = 2;
|
|
669
|
+
*/
|
|
670
|
+
QUALIFICATION = 2
|
|
671
|
+
}
|
|
672
|
+
/**
|
|
673
|
+
* @generated from protobuf enum resources.jobs.groups.GroupMemberSource
|
|
674
|
+
*/
|
|
675
|
+
export enum GroupMemberSource {
|
|
676
|
+
/**
|
|
677
|
+
* @generated from protobuf enum value: GROUP_MEMBER_SOURCE_UNSPECIFIED = 0;
|
|
678
|
+
*/
|
|
679
|
+
UNSPECIFIED = 0,
|
|
680
|
+
/**
|
|
681
|
+
* User was explicitly added to the group.
|
|
682
|
+
*
|
|
683
|
+
* @generated from protobuf enum value: GROUP_MEMBER_SOURCE_MANUAL = 1;
|
|
684
|
+
*/
|
|
685
|
+
MANUAL = 1,
|
|
686
|
+
/**
|
|
687
|
+
* User matched one or more group rules.
|
|
688
|
+
*
|
|
689
|
+
* @generated from protobuf enum value: GROUP_MEMBER_SOURCE_RULE = 2;
|
|
690
|
+
*/
|
|
691
|
+
RULE = 2,
|
|
692
|
+
/**
|
|
693
|
+
* User is a group leader.
|
|
694
|
+
* Usually informational; leader status does not necessarily mean membership.
|
|
695
|
+
*
|
|
696
|
+
* @generated from protobuf enum value: GROUP_MEMBER_SOURCE_LEADER = 3;
|
|
697
|
+
*/
|
|
698
|
+
LEADER = 3
|
|
699
|
+
}
|
|
700
|
+
/**
|
|
701
|
+
* @generated from protobuf enum resources.jobs.groups.GroupMembershipReasonType
|
|
702
|
+
*/
|
|
703
|
+
export enum GroupMembershipReasonType {
|
|
704
|
+
/**
|
|
705
|
+
* @generated from protobuf enum value: GROUP_MEMBERSHIP_REASON_TYPE_UNSPECIFIED = 0;
|
|
706
|
+
*/
|
|
707
|
+
UNSPECIFIED = 0,
|
|
708
|
+
/**
|
|
709
|
+
* @generated from protobuf enum value: GROUP_MEMBERSHIP_REASON_TYPE_MANUAL = 1;
|
|
710
|
+
*/
|
|
711
|
+
MANUAL = 1,
|
|
712
|
+
/**
|
|
713
|
+
* @generated from protobuf enum value: GROUP_MEMBERSHIP_REASON_TYPE_RULE = 2;
|
|
714
|
+
*/
|
|
715
|
+
RULE = 2,
|
|
716
|
+
/**
|
|
717
|
+
* @generated from protobuf enum value: GROUP_MEMBERSHIP_REASON_TYPE_EXCLUSION = 3;
|
|
718
|
+
*/
|
|
719
|
+
EXCLUSION = 3,
|
|
720
|
+
/**
|
|
721
|
+
* @generated from protobuf enum value: GROUP_MEMBERSHIP_REASON_TYPE_LEADER = 4;
|
|
722
|
+
*/
|
|
723
|
+
LEADER = 4
|
|
724
|
+
}
|
|
725
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
726
|
+
class Group$Type extends MessageType<Group> {
|
|
727
|
+
constructor() {
|
|
728
|
+
super("resources.jobs.groups.Group", [
|
|
729
|
+
{ no: 1, name: "id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
730
|
+
{ no: 2, name: "job", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "20" } } } },
|
|
731
|
+
{ no: 3, name: "name", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
732
|
+
{ no: 4, name: "description", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
|
|
733
|
+
{ no: 5, name: "short_name", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
|
|
734
|
+
{ no: 6, name: "logo_file_id", kind: "scalar", opt: true, T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
735
|
+
{ no: 7, name: "logo_file", kind: "message", T: () => File, options: { "tagger.tags": "alias:\"logo_file\"" } },
|
|
736
|
+
{ no: 8, name: "color", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
|
|
737
|
+
{ no: 9, name: "type", kind: "enum", T: () => ["resources.jobs.groups.GroupType", GroupType, "GROUP_TYPE_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } },
|
|
738
|
+
{ no: 10, name: "state", kind: "enum", T: () => ["resources.jobs.groups.GroupState", GroupState, "GROUP_STATE_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } },
|
|
739
|
+
{ no: 11, name: "membership_mode", kind: "enum", T: () => ["resources.jobs.groups.GroupMembershipMode", GroupMembershipMode, "GROUP_MEMBERSHIP_MODE_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } },
|
|
740
|
+
{ no: 12, name: "sort_rank", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "32" } } } },
|
|
741
|
+
{ no: 13, name: "members_count", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
|
|
742
|
+
{ no: 14, name: "leaders_count", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
|
|
743
|
+
{ no: 15, name: "rules_count", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
|
|
744
|
+
{ no: 16, name: "exclusions_count", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
|
|
745
|
+
{ no: 17, name: "created_by_user_id", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/ },
|
|
746
|
+
{ no: 18, name: "created_by", kind: "message", T: () => Colleague },
|
|
747
|
+
{ no: 19, name: "updated_by_user_id", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/ },
|
|
748
|
+
{ no: 20, name: "created_at", kind: "message", T: () => Timestamp },
|
|
749
|
+
{ no: 21, name: "updated_at", kind: "message", T: () => Timestamp },
|
|
750
|
+
{ no: 22, name: "deleted_at", kind: "message", T: () => Timestamp }
|
|
751
|
+
]);
|
|
752
|
+
}
|
|
753
|
+
create(value?: PartialMessage<Group>): Group {
|
|
754
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
755
|
+
message.id = 0;
|
|
756
|
+
message.job = "";
|
|
757
|
+
message.name = "";
|
|
758
|
+
message.type = 0;
|
|
759
|
+
message.state = 0;
|
|
760
|
+
message.membershipMode = 0;
|
|
761
|
+
message.sortRank = "";
|
|
762
|
+
message.membersCount = 0;
|
|
763
|
+
message.leadersCount = 0;
|
|
764
|
+
message.rulesCount = 0;
|
|
765
|
+
message.exclusionsCount = 0;
|
|
766
|
+
if (value !== undefined)
|
|
767
|
+
reflectionMergePartial<Group>(this, message, value);
|
|
768
|
+
return message;
|
|
769
|
+
}
|
|
770
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Group): Group {
|
|
771
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
772
|
+
while (reader.pos < end) {
|
|
773
|
+
let [fieldNo, wireType] = reader.tag();
|
|
774
|
+
switch (fieldNo) {
|
|
775
|
+
case /* int64 id */ 1:
|
|
776
|
+
message.id = reader.int64().toNumber();
|
|
777
|
+
break;
|
|
778
|
+
case /* string job */ 2:
|
|
779
|
+
message.job = reader.string();
|
|
780
|
+
break;
|
|
781
|
+
case /* string name */ 3:
|
|
782
|
+
message.name = reader.string();
|
|
783
|
+
break;
|
|
784
|
+
case /* optional string description */ 4:
|
|
785
|
+
message.description = reader.string();
|
|
786
|
+
break;
|
|
787
|
+
case /* optional string short_name */ 5:
|
|
788
|
+
message.shortName = reader.string();
|
|
789
|
+
break;
|
|
790
|
+
case /* optional int64 logo_file_id */ 6:
|
|
791
|
+
message.logoFileId = reader.int64().toNumber();
|
|
792
|
+
break;
|
|
793
|
+
case /* optional resources.file.File logo_file */ 7:
|
|
794
|
+
message.logoFile = File.internalBinaryRead(reader, reader.uint32(), options, message.logoFile);
|
|
795
|
+
break;
|
|
796
|
+
case /* optional string color */ 8:
|
|
797
|
+
message.color = reader.string();
|
|
798
|
+
break;
|
|
799
|
+
case /* resources.jobs.groups.GroupType type */ 9:
|
|
800
|
+
message.type = reader.int32();
|
|
801
|
+
break;
|
|
802
|
+
case /* resources.jobs.groups.GroupState state */ 10:
|
|
803
|
+
message.state = reader.int32();
|
|
804
|
+
break;
|
|
805
|
+
case /* resources.jobs.groups.GroupMembershipMode membership_mode */ 11:
|
|
806
|
+
message.membershipMode = reader.int32();
|
|
807
|
+
break;
|
|
808
|
+
case /* string sort_rank */ 12:
|
|
809
|
+
message.sortRank = reader.string();
|
|
810
|
+
break;
|
|
811
|
+
case /* int32 members_count */ 13:
|
|
812
|
+
message.membersCount = reader.int32();
|
|
813
|
+
break;
|
|
814
|
+
case /* int32 leaders_count */ 14:
|
|
815
|
+
message.leadersCount = reader.int32();
|
|
816
|
+
break;
|
|
817
|
+
case /* int32 rules_count */ 15:
|
|
818
|
+
message.rulesCount = reader.int32();
|
|
819
|
+
break;
|
|
820
|
+
case /* int32 exclusions_count */ 16:
|
|
821
|
+
message.exclusionsCount = reader.int32();
|
|
822
|
+
break;
|
|
823
|
+
case /* optional int32 created_by_user_id */ 17:
|
|
824
|
+
message.createdByUserId = reader.int32();
|
|
825
|
+
break;
|
|
826
|
+
case /* optional resources.jobs.colleagues.Colleague created_by */ 18:
|
|
827
|
+
message.createdBy = Colleague.internalBinaryRead(reader, reader.uint32(), options, message.createdBy);
|
|
828
|
+
break;
|
|
829
|
+
case /* optional int32 updated_by_user_id */ 19:
|
|
830
|
+
message.updatedByUserId = reader.int32();
|
|
831
|
+
break;
|
|
832
|
+
case /* resources.timestamp.Timestamp created_at */ 20:
|
|
833
|
+
message.createdAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.createdAt);
|
|
834
|
+
break;
|
|
835
|
+
case /* optional resources.timestamp.Timestamp updated_at */ 21:
|
|
836
|
+
message.updatedAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.updatedAt);
|
|
837
|
+
break;
|
|
838
|
+
case /* optional resources.timestamp.Timestamp deleted_at */ 22:
|
|
839
|
+
message.deletedAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.deletedAt);
|
|
840
|
+
break;
|
|
841
|
+
default:
|
|
842
|
+
let u = options.readUnknownField;
|
|
843
|
+
if (u === "throw")
|
|
844
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
845
|
+
let d = reader.skip(wireType);
|
|
846
|
+
if (u !== false)
|
|
847
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
848
|
+
}
|
|
849
|
+
}
|
|
850
|
+
return message;
|
|
851
|
+
}
|
|
852
|
+
internalBinaryWrite(message: Group, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
853
|
+
/* int64 id = 1; */
|
|
854
|
+
if (message.id !== 0)
|
|
855
|
+
writer.tag(1, WireType.Varint).int64(message.id);
|
|
856
|
+
/* string job = 2; */
|
|
857
|
+
if (message.job !== "")
|
|
858
|
+
writer.tag(2, WireType.LengthDelimited).string(message.job);
|
|
859
|
+
/* string name = 3; */
|
|
860
|
+
if (message.name !== "")
|
|
861
|
+
writer.tag(3, WireType.LengthDelimited).string(message.name);
|
|
862
|
+
/* optional string description = 4; */
|
|
863
|
+
if (message.description !== undefined)
|
|
864
|
+
writer.tag(4, WireType.LengthDelimited).string(message.description);
|
|
865
|
+
/* optional string short_name = 5; */
|
|
866
|
+
if (message.shortName !== undefined)
|
|
867
|
+
writer.tag(5, WireType.LengthDelimited).string(message.shortName);
|
|
868
|
+
/* optional int64 logo_file_id = 6; */
|
|
869
|
+
if (message.logoFileId !== undefined)
|
|
870
|
+
writer.tag(6, WireType.Varint).int64(message.logoFileId);
|
|
871
|
+
/* optional resources.file.File logo_file = 7; */
|
|
872
|
+
if (message.logoFile)
|
|
873
|
+
File.internalBinaryWrite(message.logoFile, writer.tag(7, WireType.LengthDelimited).fork(), options).join();
|
|
874
|
+
/* optional string color = 8; */
|
|
875
|
+
if (message.color !== undefined)
|
|
876
|
+
writer.tag(8, WireType.LengthDelimited).string(message.color);
|
|
877
|
+
/* resources.jobs.groups.GroupType type = 9; */
|
|
878
|
+
if (message.type !== 0)
|
|
879
|
+
writer.tag(9, WireType.Varint).int32(message.type);
|
|
880
|
+
/* resources.jobs.groups.GroupState state = 10; */
|
|
881
|
+
if (message.state !== 0)
|
|
882
|
+
writer.tag(10, WireType.Varint).int32(message.state);
|
|
883
|
+
/* resources.jobs.groups.GroupMembershipMode membership_mode = 11; */
|
|
884
|
+
if (message.membershipMode !== 0)
|
|
885
|
+
writer.tag(11, WireType.Varint).int32(message.membershipMode);
|
|
886
|
+
/* string sort_rank = 12; */
|
|
887
|
+
if (message.sortRank !== "")
|
|
888
|
+
writer.tag(12, WireType.LengthDelimited).string(message.sortRank);
|
|
889
|
+
/* int32 members_count = 13; */
|
|
890
|
+
if (message.membersCount !== 0)
|
|
891
|
+
writer.tag(13, WireType.Varint).int32(message.membersCount);
|
|
892
|
+
/* int32 leaders_count = 14; */
|
|
893
|
+
if (message.leadersCount !== 0)
|
|
894
|
+
writer.tag(14, WireType.Varint).int32(message.leadersCount);
|
|
895
|
+
/* int32 rules_count = 15; */
|
|
896
|
+
if (message.rulesCount !== 0)
|
|
897
|
+
writer.tag(15, WireType.Varint).int32(message.rulesCount);
|
|
898
|
+
/* int32 exclusions_count = 16; */
|
|
899
|
+
if (message.exclusionsCount !== 0)
|
|
900
|
+
writer.tag(16, WireType.Varint).int32(message.exclusionsCount);
|
|
901
|
+
/* optional int32 created_by_user_id = 17; */
|
|
902
|
+
if (message.createdByUserId !== undefined)
|
|
903
|
+
writer.tag(17, WireType.Varint).int32(message.createdByUserId);
|
|
904
|
+
/* optional resources.jobs.colleagues.Colleague created_by = 18; */
|
|
905
|
+
if (message.createdBy)
|
|
906
|
+
Colleague.internalBinaryWrite(message.createdBy, writer.tag(18, WireType.LengthDelimited).fork(), options).join();
|
|
907
|
+
/* optional int32 updated_by_user_id = 19; */
|
|
908
|
+
if (message.updatedByUserId !== undefined)
|
|
909
|
+
writer.tag(19, WireType.Varint).int32(message.updatedByUserId);
|
|
910
|
+
/* resources.timestamp.Timestamp created_at = 20; */
|
|
911
|
+
if (message.createdAt)
|
|
912
|
+
Timestamp.internalBinaryWrite(message.createdAt, writer.tag(20, WireType.LengthDelimited).fork(), options).join();
|
|
913
|
+
/* optional resources.timestamp.Timestamp updated_at = 21; */
|
|
914
|
+
if (message.updatedAt)
|
|
915
|
+
Timestamp.internalBinaryWrite(message.updatedAt, writer.tag(21, WireType.LengthDelimited).fork(), options).join();
|
|
916
|
+
/* optional resources.timestamp.Timestamp deleted_at = 22; */
|
|
917
|
+
if (message.deletedAt)
|
|
918
|
+
Timestamp.internalBinaryWrite(message.deletedAt, writer.tag(22, WireType.LengthDelimited).fork(), options).join();
|
|
919
|
+
let u = options.writeUnknownFields;
|
|
920
|
+
if (u !== false)
|
|
921
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
922
|
+
return writer;
|
|
923
|
+
}
|
|
924
|
+
}
|
|
925
|
+
/**
|
|
926
|
+
* @generated MessageType for protobuf message resources.jobs.groups.Group
|
|
927
|
+
*/
|
|
928
|
+
export const Group = new Group$Type();
|
|
929
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
930
|
+
class GroupLeader$Type extends MessageType<GroupLeader> {
|
|
931
|
+
constructor() {
|
|
932
|
+
super("resources.jobs.groups.GroupLeader", [
|
|
933
|
+
{ no: 1, name: "group_id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
934
|
+
{ no: 2, name: "user_id", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
|
|
935
|
+
{ no: 3, name: "colleague", kind: "message", T: () => Colleague },
|
|
936
|
+
{ no: 4, name: "created_by_user_id", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/ },
|
|
937
|
+
{ no: 5, name: "created_by", kind: "message", T: () => Colleague },
|
|
938
|
+
{ no: 6, name: "created_at", kind: "message", T: () => Timestamp }
|
|
939
|
+
]);
|
|
940
|
+
}
|
|
941
|
+
create(value?: PartialMessage<GroupLeader>): GroupLeader {
|
|
942
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
943
|
+
message.groupId = 0;
|
|
944
|
+
message.userId = 0;
|
|
945
|
+
if (value !== undefined)
|
|
946
|
+
reflectionMergePartial<GroupLeader>(this, message, value);
|
|
947
|
+
return message;
|
|
948
|
+
}
|
|
949
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GroupLeader): GroupLeader {
|
|
950
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
951
|
+
while (reader.pos < end) {
|
|
952
|
+
let [fieldNo, wireType] = reader.tag();
|
|
953
|
+
switch (fieldNo) {
|
|
954
|
+
case /* int64 group_id */ 1:
|
|
955
|
+
message.groupId = reader.int64().toNumber();
|
|
956
|
+
break;
|
|
957
|
+
case /* int32 user_id */ 2:
|
|
958
|
+
message.userId = reader.int32();
|
|
959
|
+
break;
|
|
960
|
+
case /* optional resources.jobs.colleagues.Colleague colleague */ 3:
|
|
961
|
+
message.colleague = Colleague.internalBinaryRead(reader, reader.uint32(), options, message.colleague);
|
|
962
|
+
break;
|
|
963
|
+
case /* optional int32 created_by_user_id */ 4:
|
|
964
|
+
message.createdByUserId = reader.int32();
|
|
965
|
+
break;
|
|
966
|
+
case /* optional resources.jobs.colleagues.Colleague created_by */ 5:
|
|
967
|
+
message.createdBy = Colleague.internalBinaryRead(reader, reader.uint32(), options, message.createdBy);
|
|
968
|
+
break;
|
|
969
|
+
case /* resources.timestamp.Timestamp created_at */ 6:
|
|
970
|
+
message.createdAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.createdAt);
|
|
971
|
+
break;
|
|
972
|
+
default:
|
|
973
|
+
let u = options.readUnknownField;
|
|
974
|
+
if (u === "throw")
|
|
975
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
976
|
+
let d = reader.skip(wireType);
|
|
977
|
+
if (u !== false)
|
|
978
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
979
|
+
}
|
|
980
|
+
}
|
|
981
|
+
return message;
|
|
982
|
+
}
|
|
983
|
+
internalBinaryWrite(message: GroupLeader, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
984
|
+
/* int64 group_id = 1; */
|
|
985
|
+
if (message.groupId !== 0)
|
|
986
|
+
writer.tag(1, WireType.Varint).int64(message.groupId);
|
|
987
|
+
/* int32 user_id = 2; */
|
|
988
|
+
if (message.userId !== 0)
|
|
989
|
+
writer.tag(2, WireType.Varint).int32(message.userId);
|
|
990
|
+
/* optional resources.jobs.colleagues.Colleague colleague = 3; */
|
|
991
|
+
if (message.colleague)
|
|
992
|
+
Colleague.internalBinaryWrite(message.colleague, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
993
|
+
/* optional int32 created_by_user_id = 4; */
|
|
994
|
+
if (message.createdByUserId !== undefined)
|
|
995
|
+
writer.tag(4, WireType.Varint).int32(message.createdByUserId);
|
|
996
|
+
/* optional resources.jobs.colleagues.Colleague created_by = 5; */
|
|
997
|
+
if (message.createdBy)
|
|
998
|
+
Colleague.internalBinaryWrite(message.createdBy, writer.tag(5, WireType.LengthDelimited).fork(), options).join();
|
|
999
|
+
/* resources.timestamp.Timestamp created_at = 6; */
|
|
1000
|
+
if (message.createdAt)
|
|
1001
|
+
Timestamp.internalBinaryWrite(message.createdAt, writer.tag(6, WireType.LengthDelimited).fork(), options).join();
|
|
1002
|
+
let u = options.writeUnknownFields;
|
|
1003
|
+
if (u !== false)
|
|
1004
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1005
|
+
return writer;
|
|
1006
|
+
}
|
|
1007
|
+
}
|
|
1008
|
+
/**
|
|
1009
|
+
* @generated MessageType for protobuf message resources.jobs.groups.GroupLeader
|
|
1010
|
+
*/
|
|
1011
|
+
export const GroupLeader = new GroupLeader$Type();
|
|
1012
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1013
|
+
class GroupManualMember$Type extends MessageType<GroupManualMember> {
|
|
1014
|
+
constructor() {
|
|
1015
|
+
super("resources.jobs.groups.GroupManualMember", [
|
|
1016
|
+
{ no: 1, name: "group_id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
1017
|
+
{ no: 2, name: "user_id", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
|
|
1018
|
+
{ no: 3, name: "colleague", kind: "message", T: () => Colleague },
|
|
1019
|
+
{ no: 4, name: "reason", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
|
|
1020
|
+
{ no: 5, name: "created_by_user_id", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/ },
|
|
1021
|
+
{ no: 6, name: "created_by", kind: "message", T: () => Colleague },
|
|
1022
|
+
{ no: 7, name: "created_at", kind: "message", T: () => Timestamp }
|
|
1023
|
+
]);
|
|
1024
|
+
}
|
|
1025
|
+
create(value?: PartialMessage<GroupManualMember>): GroupManualMember {
|
|
1026
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1027
|
+
message.groupId = 0;
|
|
1028
|
+
message.userId = 0;
|
|
1029
|
+
if (value !== undefined)
|
|
1030
|
+
reflectionMergePartial<GroupManualMember>(this, message, value);
|
|
1031
|
+
return message;
|
|
1032
|
+
}
|
|
1033
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GroupManualMember): GroupManualMember {
|
|
1034
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1035
|
+
while (reader.pos < end) {
|
|
1036
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1037
|
+
switch (fieldNo) {
|
|
1038
|
+
case /* int64 group_id */ 1:
|
|
1039
|
+
message.groupId = reader.int64().toNumber();
|
|
1040
|
+
break;
|
|
1041
|
+
case /* int32 user_id */ 2:
|
|
1042
|
+
message.userId = reader.int32();
|
|
1043
|
+
break;
|
|
1044
|
+
case /* optional resources.jobs.colleagues.Colleague colleague */ 3:
|
|
1045
|
+
message.colleague = Colleague.internalBinaryRead(reader, reader.uint32(), options, message.colleague);
|
|
1046
|
+
break;
|
|
1047
|
+
case /* optional string reason */ 4:
|
|
1048
|
+
message.reason = reader.string();
|
|
1049
|
+
break;
|
|
1050
|
+
case /* optional int32 created_by_user_id */ 5:
|
|
1051
|
+
message.createdByUserId = reader.int32();
|
|
1052
|
+
break;
|
|
1053
|
+
case /* optional resources.jobs.colleagues.Colleague created_by */ 6:
|
|
1054
|
+
message.createdBy = Colleague.internalBinaryRead(reader, reader.uint32(), options, message.createdBy);
|
|
1055
|
+
break;
|
|
1056
|
+
case /* resources.timestamp.Timestamp created_at */ 7:
|
|
1057
|
+
message.createdAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.createdAt);
|
|
1058
|
+
break;
|
|
1059
|
+
default:
|
|
1060
|
+
let u = options.readUnknownField;
|
|
1061
|
+
if (u === "throw")
|
|
1062
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1063
|
+
let d = reader.skip(wireType);
|
|
1064
|
+
if (u !== false)
|
|
1065
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1066
|
+
}
|
|
1067
|
+
}
|
|
1068
|
+
return message;
|
|
1069
|
+
}
|
|
1070
|
+
internalBinaryWrite(message: GroupManualMember, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1071
|
+
/* int64 group_id = 1; */
|
|
1072
|
+
if (message.groupId !== 0)
|
|
1073
|
+
writer.tag(1, WireType.Varint).int64(message.groupId);
|
|
1074
|
+
/* int32 user_id = 2; */
|
|
1075
|
+
if (message.userId !== 0)
|
|
1076
|
+
writer.tag(2, WireType.Varint).int32(message.userId);
|
|
1077
|
+
/* optional resources.jobs.colleagues.Colleague colleague = 3; */
|
|
1078
|
+
if (message.colleague)
|
|
1079
|
+
Colleague.internalBinaryWrite(message.colleague, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
1080
|
+
/* optional string reason = 4; */
|
|
1081
|
+
if (message.reason !== undefined)
|
|
1082
|
+
writer.tag(4, WireType.LengthDelimited).string(message.reason);
|
|
1083
|
+
/* optional int32 created_by_user_id = 5; */
|
|
1084
|
+
if (message.createdByUserId !== undefined)
|
|
1085
|
+
writer.tag(5, WireType.Varint).int32(message.createdByUserId);
|
|
1086
|
+
/* optional resources.jobs.colleagues.Colleague created_by = 6; */
|
|
1087
|
+
if (message.createdBy)
|
|
1088
|
+
Colleague.internalBinaryWrite(message.createdBy, writer.tag(6, WireType.LengthDelimited).fork(), options).join();
|
|
1089
|
+
/* resources.timestamp.Timestamp created_at = 7; */
|
|
1090
|
+
if (message.createdAt)
|
|
1091
|
+
Timestamp.internalBinaryWrite(message.createdAt, writer.tag(7, WireType.LengthDelimited).fork(), options).join();
|
|
1092
|
+
let u = options.writeUnknownFields;
|
|
1093
|
+
if (u !== false)
|
|
1094
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1095
|
+
return writer;
|
|
1096
|
+
}
|
|
1097
|
+
}
|
|
1098
|
+
/**
|
|
1099
|
+
* @generated MessageType for protobuf message resources.jobs.groups.GroupManualMember
|
|
1100
|
+
*/
|
|
1101
|
+
export const GroupManualMember = new GroupManualMember$Type();
|
|
1102
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1103
|
+
class GroupMemberExclusion$Type extends MessageType<GroupMemberExclusion> {
|
|
1104
|
+
constructor() {
|
|
1105
|
+
super("resources.jobs.groups.GroupMemberExclusion", [
|
|
1106
|
+
{ no: 1, name: "group_id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
1107
|
+
{ no: 2, name: "user_id", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
|
|
1108
|
+
{ no: 3, name: "colleague", kind: "message", T: () => Colleague },
|
|
1109
|
+
{ no: 4, name: "reason_type", kind: "enum", T: () => ["resources.jobs.groups.GroupExclusionReason", GroupExclusionReason, "GROUP_EXCLUSION_REASON_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } },
|
|
1110
|
+
{ no: 5, name: "reason", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
|
|
1111
|
+
{ no: 6, name: "created_by_user_id", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/ },
|
|
1112
|
+
{ no: 7, name: "created_by", kind: "message", T: () => Colleague },
|
|
1113
|
+
{ no: 8, name: "created_at", kind: "message", T: () => Timestamp }
|
|
1114
|
+
]);
|
|
1115
|
+
}
|
|
1116
|
+
create(value?: PartialMessage<GroupMemberExclusion>): GroupMemberExclusion {
|
|
1117
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1118
|
+
message.groupId = 0;
|
|
1119
|
+
message.userId = 0;
|
|
1120
|
+
message.reasonType = 0;
|
|
1121
|
+
if (value !== undefined)
|
|
1122
|
+
reflectionMergePartial<GroupMemberExclusion>(this, message, value);
|
|
1123
|
+
return message;
|
|
1124
|
+
}
|
|
1125
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GroupMemberExclusion): GroupMemberExclusion {
|
|
1126
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1127
|
+
while (reader.pos < end) {
|
|
1128
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1129
|
+
switch (fieldNo) {
|
|
1130
|
+
case /* int64 group_id */ 1:
|
|
1131
|
+
message.groupId = reader.int64().toNumber();
|
|
1132
|
+
break;
|
|
1133
|
+
case /* int32 user_id */ 2:
|
|
1134
|
+
message.userId = reader.int32();
|
|
1135
|
+
break;
|
|
1136
|
+
case /* optional resources.jobs.colleagues.Colleague colleague */ 3:
|
|
1137
|
+
message.colleague = Colleague.internalBinaryRead(reader, reader.uint32(), options, message.colleague);
|
|
1138
|
+
break;
|
|
1139
|
+
case /* resources.jobs.groups.GroupExclusionReason reason_type */ 4:
|
|
1140
|
+
message.reasonType = reader.int32();
|
|
1141
|
+
break;
|
|
1142
|
+
case /* optional string reason */ 5:
|
|
1143
|
+
message.reason = reader.string();
|
|
1144
|
+
break;
|
|
1145
|
+
case /* optional int32 created_by_user_id */ 6:
|
|
1146
|
+
message.createdByUserId = reader.int32();
|
|
1147
|
+
break;
|
|
1148
|
+
case /* optional resources.jobs.colleagues.Colleague created_by */ 7:
|
|
1149
|
+
message.createdBy = Colleague.internalBinaryRead(reader, reader.uint32(), options, message.createdBy);
|
|
1150
|
+
break;
|
|
1151
|
+
case /* resources.timestamp.Timestamp created_at */ 8:
|
|
1152
|
+
message.createdAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.createdAt);
|
|
1153
|
+
break;
|
|
1154
|
+
default:
|
|
1155
|
+
let u = options.readUnknownField;
|
|
1156
|
+
if (u === "throw")
|
|
1157
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1158
|
+
let d = reader.skip(wireType);
|
|
1159
|
+
if (u !== false)
|
|
1160
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1161
|
+
}
|
|
1162
|
+
}
|
|
1163
|
+
return message;
|
|
1164
|
+
}
|
|
1165
|
+
internalBinaryWrite(message: GroupMemberExclusion, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1166
|
+
/* int64 group_id = 1; */
|
|
1167
|
+
if (message.groupId !== 0)
|
|
1168
|
+
writer.tag(1, WireType.Varint).int64(message.groupId);
|
|
1169
|
+
/* int32 user_id = 2; */
|
|
1170
|
+
if (message.userId !== 0)
|
|
1171
|
+
writer.tag(2, WireType.Varint).int32(message.userId);
|
|
1172
|
+
/* optional resources.jobs.colleagues.Colleague colleague = 3; */
|
|
1173
|
+
if (message.colleague)
|
|
1174
|
+
Colleague.internalBinaryWrite(message.colleague, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
1175
|
+
/* resources.jobs.groups.GroupExclusionReason reason_type = 4; */
|
|
1176
|
+
if (message.reasonType !== 0)
|
|
1177
|
+
writer.tag(4, WireType.Varint).int32(message.reasonType);
|
|
1178
|
+
/* optional string reason = 5; */
|
|
1179
|
+
if (message.reason !== undefined)
|
|
1180
|
+
writer.tag(5, WireType.LengthDelimited).string(message.reason);
|
|
1181
|
+
/* optional int32 created_by_user_id = 6; */
|
|
1182
|
+
if (message.createdByUserId !== undefined)
|
|
1183
|
+
writer.tag(6, WireType.Varint).int32(message.createdByUserId);
|
|
1184
|
+
/* optional resources.jobs.colleagues.Colleague created_by = 7; */
|
|
1185
|
+
if (message.createdBy)
|
|
1186
|
+
Colleague.internalBinaryWrite(message.createdBy, writer.tag(7, WireType.LengthDelimited).fork(), options).join();
|
|
1187
|
+
/* resources.timestamp.Timestamp created_at = 8; */
|
|
1188
|
+
if (message.createdAt)
|
|
1189
|
+
Timestamp.internalBinaryWrite(message.createdAt, writer.tag(8, WireType.LengthDelimited).fork(), options).join();
|
|
1190
|
+
let u = options.writeUnknownFields;
|
|
1191
|
+
if (u !== false)
|
|
1192
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1193
|
+
return writer;
|
|
1194
|
+
}
|
|
1195
|
+
}
|
|
1196
|
+
/**
|
|
1197
|
+
* @generated MessageType for protobuf message resources.jobs.groups.GroupMemberExclusion
|
|
1198
|
+
*/
|
|
1199
|
+
export const GroupMemberExclusion = new GroupMemberExclusion$Type();
|
|
1200
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1201
|
+
class GroupGradeRule$Type extends MessageType<GroupGradeRule> {
|
|
1202
|
+
constructor() {
|
|
1203
|
+
super("resources.jobs.groups.GroupGradeRule", [
|
|
1204
|
+
{ no: 1, name: "type", kind: "enum", T: () => ["resources.jobs.groups.GroupGradeRuleType", GroupGradeRuleType, "GROUP_GRADE_RULE_TYPE_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } },
|
|
1205
|
+
{ no: 2, name: "grade", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/ },
|
|
1206
|
+
{ no: 3, name: "min_grade", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/ },
|
|
1207
|
+
{ no: 4, name: "max_grade", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/ },
|
|
1208
|
+
{ no: 5, name: "grade_label", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
|
|
1209
|
+
{ no: 6, name: "min_grade_label", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
|
|
1210
|
+
{ no: 7, name: "max_grade_label", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ }
|
|
1211
|
+
]);
|
|
1212
|
+
}
|
|
1213
|
+
create(value?: PartialMessage<GroupGradeRule>): GroupGradeRule {
|
|
1214
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1215
|
+
message.type = 0;
|
|
1216
|
+
if (value !== undefined)
|
|
1217
|
+
reflectionMergePartial<GroupGradeRule>(this, message, value);
|
|
1218
|
+
return message;
|
|
1219
|
+
}
|
|
1220
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GroupGradeRule): GroupGradeRule {
|
|
1221
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1222
|
+
while (reader.pos < end) {
|
|
1223
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1224
|
+
switch (fieldNo) {
|
|
1225
|
+
case /* resources.jobs.groups.GroupGradeRuleType type */ 1:
|
|
1226
|
+
message.type = reader.int32();
|
|
1227
|
+
break;
|
|
1228
|
+
case /* optional int32 grade */ 2:
|
|
1229
|
+
message.grade = reader.int32();
|
|
1230
|
+
break;
|
|
1231
|
+
case /* optional int32 min_grade */ 3:
|
|
1232
|
+
message.minGrade = reader.int32();
|
|
1233
|
+
break;
|
|
1234
|
+
case /* optional int32 max_grade */ 4:
|
|
1235
|
+
message.maxGrade = reader.int32();
|
|
1236
|
+
break;
|
|
1237
|
+
case /* optional string grade_label */ 5:
|
|
1238
|
+
message.gradeLabel = reader.string();
|
|
1239
|
+
break;
|
|
1240
|
+
case /* optional string min_grade_label */ 6:
|
|
1241
|
+
message.minGradeLabel = reader.string();
|
|
1242
|
+
break;
|
|
1243
|
+
case /* optional string max_grade_label */ 7:
|
|
1244
|
+
message.maxGradeLabel = reader.string();
|
|
1245
|
+
break;
|
|
1246
|
+
default:
|
|
1247
|
+
let u = options.readUnknownField;
|
|
1248
|
+
if (u === "throw")
|
|
1249
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1250
|
+
let d = reader.skip(wireType);
|
|
1251
|
+
if (u !== false)
|
|
1252
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1253
|
+
}
|
|
1254
|
+
}
|
|
1255
|
+
return message;
|
|
1256
|
+
}
|
|
1257
|
+
internalBinaryWrite(message: GroupGradeRule, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1258
|
+
/* resources.jobs.groups.GroupGradeRuleType type = 1; */
|
|
1259
|
+
if (message.type !== 0)
|
|
1260
|
+
writer.tag(1, WireType.Varint).int32(message.type);
|
|
1261
|
+
/* optional int32 grade = 2; */
|
|
1262
|
+
if (message.grade !== undefined)
|
|
1263
|
+
writer.tag(2, WireType.Varint).int32(message.grade);
|
|
1264
|
+
/* optional int32 min_grade = 3; */
|
|
1265
|
+
if (message.minGrade !== undefined)
|
|
1266
|
+
writer.tag(3, WireType.Varint).int32(message.minGrade);
|
|
1267
|
+
/* optional int32 max_grade = 4; */
|
|
1268
|
+
if (message.maxGrade !== undefined)
|
|
1269
|
+
writer.tag(4, WireType.Varint).int32(message.maxGrade);
|
|
1270
|
+
/* optional string grade_label = 5; */
|
|
1271
|
+
if (message.gradeLabel !== undefined)
|
|
1272
|
+
writer.tag(5, WireType.LengthDelimited).string(message.gradeLabel);
|
|
1273
|
+
/* optional string min_grade_label = 6; */
|
|
1274
|
+
if (message.minGradeLabel !== undefined)
|
|
1275
|
+
writer.tag(6, WireType.LengthDelimited).string(message.minGradeLabel);
|
|
1276
|
+
/* optional string max_grade_label = 7; */
|
|
1277
|
+
if (message.maxGradeLabel !== undefined)
|
|
1278
|
+
writer.tag(7, WireType.LengthDelimited).string(message.maxGradeLabel);
|
|
1279
|
+
let u = options.writeUnknownFields;
|
|
1280
|
+
if (u !== false)
|
|
1281
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1282
|
+
return writer;
|
|
1283
|
+
}
|
|
1284
|
+
}
|
|
1285
|
+
/**
|
|
1286
|
+
* @generated MessageType for protobuf message resources.jobs.groups.GroupGradeRule
|
|
1287
|
+
*/
|
|
1288
|
+
export const GroupGradeRule = new GroupGradeRule$Type();
|
|
1289
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1290
|
+
class GroupQualificationRule$Type extends MessageType<GroupQualificationRule> {
|
|
1291
|
+
constructor() {
|
|
1292
|
+
super("resources.jobs.groups.GroupQualificationRule", [
|
|
1293
|
+
{ no: 1, name: "type", kind: "enum", T: () => ["resources.jobs.groups.GroupQualificationRuleType", GroupQualificationRuleType, "GROUP_QUALIFICATION_RULE_TYPE_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } },
|
|
1294
|
+
{ no: 2, name: "qualification_ids", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/, options: { "buf.validate.field": { repeated: { items: { int64: { gt: "0" } } } } } },
|
|
1295
|
+
{ no: 3, name: "require_completed", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
|
|
1296
|
+
{ no: 4, name: "qualifications", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => QualificationShort, options: { "buf.validate.field": { repeated: { maxItems: "4" } } } }
|
|
1297
|
+
]);
|
|
1298
|
+
}
|
|
1299
|
+
create(value?: PartialMessage<GroupQualificationRule>): GroupQualificationRule {
|
|
1300
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1301
|
+
message.type = 0;
|
|
1302
|
+
message.qualificationIds = [];
|
|
1303
|
+
message.requireCompleted = false;
|
|
1304
|
+
message.qualifications = [];
|
|
1305
|
+
if (value !== undefined)
|
|
1306
|
+
reflectionMergePartial<GroupQualificationRule>(this, message, value);
|
|
1307
|
+
return message;
|
|
1308
|
+
}
|
|
1309
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GroupQualificationRule): GroupQualificationRule {
|
|
1310
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1311
|
+
while (reader.pos < end) {
|
|
1312
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1313
|
+
switch (fieldNo) {
|
|
1314
|
+
case /* resources.jobs.groups.GroupQualificationRuleType type */ 1:
|
|
1315
|
+
message.type = reader.int32();
|
|
1316
|
+
break;
|
|
1317
|
+
case /* repeated int64 qualification_ids */ 2:
|
|
1318
|
+
if (wireType === WireType.LengthDelimited)
|
|
1319
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
1320
|
+
message.qualificationIds.push(reader.int64().toNumber());
|
|
1321
|
+
else
|
|
1322
|
+
message.qualificationIds.push(reader.int64().toNumber());
|
|
1323
|
+
break;
|
|
1324
|
+
case /* bool require_completed */ 3:
|
|
1325
|
+
message.requireCompleted = reader.bool();
|
|
1326
|
+
break;
|
|
1327
|
+
case /* repeated resources.qualifications.QualificationShort qualifications */ 4:
|
|
1328
|
+
message.qualifications.push(QualificationShort.internalBinaryRead(reader, reader.uint32(), options));
|
|
1329
|
+
break;
|
|
1330
|
+
default:
|
|
1331
|
+
let u = options.readUnknownField;
|
|
1332
|
+
if (u === "throw")
|
|
1333
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1334
|
+
let d = reader.skip(wireType);
|
|
1335
|
+
if (u !== false)
|
|
1336
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1337
|
+
}
|
|
1338
|
+
}
|
|
1339
|
+
return message;
|
|
1340
|
+
}
|
|
1341
|
+
internalBinaryWrite(message: GroupQualificationRule, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1342
|
+
/* resources.jobs.groups.GroupQualificationRuleType type = 1; */
|
|
1343
|
+
if (message.type !== 0)
|
|
1344
|
+
writer.tag(1, WireType.Varint).int32(message.type);
|
|
1345
|
+
/* repeated int64 qualification_ids = 2; */
|
|
1346
|
+
if (message.qualificationIds.length) {
|
|
1347
|
+
writer.tag(2, WireType.LengthDelimited).fork();
|
|
1348
|
+
for (let i = 0; i < message.qualificationIds.length; i++)
|
|
1349
|
+
writer.int64(message.qualificationIds[i]);
|
|
1350
|
+
writer.join();
|
|
1351
|
+
}
|
|
1352
|
+
/* bool require_completed = 3; */
|
|
1353
|
+
if (message.requireCompleted !== false)
|
|
1354
|
+
writer.tag(3, WireType.Varint).bool(message.requireCompleted);
|
|
1355
|
+
/* repeated resources.qualifications.QualificationShort qualifications = 4; */
|
|
1356
|
+
for (let i = 0; i < message.qualifications.length; i++)
|
|
1357
|
+
QualificationShort.internalBinaryWrite(message.qualifications[i], writer.tag(4, WireType.LengthDelimited).fork(), options).join();
|
|
1358
|
+
let u = options.writeUnknownFields;
|
|
1359
|
+
if (u !== false)
|
|
1360
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1361
|
+
return writer;
|
|
1362
|
+
}
|
|
1363
|
+
}
|
|
1364
|
+
/**
|
|
1365
|
+
* @generated MessageType for protobuf message resources.jobs.groups.GroupQualificationRule
|
|
1366
|
+
*/
|
|
1367
|
+
export const GroupQualificationRule = new GroupQualificationRule$Type();
|
|
1368
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1369
|
+
class GroupRule$Type extends MessageType<GroupRule> {
|
|
1370
|
+
constructor() {
|
|
1371
|
+
super("resources.jobs.groups.GroupRule", [
|
|
1372
|
+
{ no: 1, name: "id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
1373
|
+
{ no: 2, name: "group_id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
1374
|
+
{ no: 3, name: "enabled", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
|
|
1375
|
+
{ no: 4, name: "type", kind: "enum", T: () => ["resources.jobs.groups.GroupRuleType", GroupRuleType, "GROUP_RULE_TYPE_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } },
|
|
1376
|
+
{ no: 5, name: "grade", kind: "message", oneof: "rule", T: () => GroupGradeRule },
|
|
1377
|
+
{ no: 6, name: "qualification", kind: "message", oneof: "rule", T: () => GroupQualificationRule },
|
|
1378
|
+
{ no: 7, name: "created_by_user_id", kind: "scalar", opt: true, T: 5 /*ScalarType.INT32*/ },
|
|
1379
|
+
{ no: 8, name: "created_by", kind: "message", T: () => Colleague },
|
|
1380
|
+
{ no: 9, name: "created_at", kind: "message", T: () => Timestamp },
|
|
1381
|
+
{ no: 10, name: "updated_at", kind: "message", T: () => Timestamp }
|
|
1382
|
+
]);
|
|
1383
|
+
}
|
|
1384
|
+
create(value?: PartialMessage<GroupRule>): GroupRule {
|
|
1385
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1386
|
+
message.id = 0;
|
|
1387
|
+
message.groupId = 0;
|
|
1388
|
+
message.enabled = false;
|
|
1389
|
+
message.type = 0;
|
|
1390
|
+
message.rule = { oneofKind: undefined };
|
|
1391
|
+
if (value !== undefined)
|
|
1392
|
+
reflectionMergePartial<GroupRule>(this, message, value);
|
|
1393
|
+
return message;
|
|
1394
|
+
}
|
|
1395
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GroupRule): GroupRule {
|
|
1396
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1397
|
+
while (reader.pos < end) {
|
|
1398
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1399
|
+
switch (fieldNo) {
|
|
1400
|
+
case /* int64 id */ 1:
|
|
1401
|
+
message.id = reader.int64().toNumber();
|
|
1402
|
+
break;
|
|
1403
|
+
case /* int64 group_id */ 2:
|
|
1404
|
+
message.groupId = reader.int64().toNumber();
|
|
1405
|
+
break;
|
|
1406
|
+
case /* bool enabled */ 3:
|
|
1407
|
+
message.enabled = reader.bool();
|
|
1408
|
+
break;
|
|
1409
|
+
case /* resources.jobs.groups.GroupRuleType type */ 4:
|
|
1410
|
+
message.type = reader.int32();
|
|
1411
|
+
break;
|
|
1412
|
+
case /* resources.jobs.groups.GroupGradeRule grade */ 5:
|
|
1413
|
+
message.rule = {
|
|
1414
|
+
oneofKind: "grade",
|
|
1415
|
+
grade: GroupGradeRule.internalBinaryRead(reader, reader.uint32(), options, (message.rule as any).grade)
|
|
1416
|
+
};
|
|
1417
|
+
break;
|
|
1418
|
+
case /* resources.jobs.groups.GroupQualificationRule qualification */ 6:
|
|
1419
|
+
message.rule = {
|
|
1420
|
+
oneofKind: "qualification",
|
|
1421
|
+
qualification: GroupQualificationRule.internalBinaryRead(reader, reader.uint32(), options, (message.rule as any).qualification)
|
|
1422
|
+
};
|
|
1423
|
+
break;
|
|
1424
|
+
case /* optional int32 created_by_user_id */ 7:
|
|
1425
|
+
message.createdByUserId = reader.int32();
|
|
1426
|
+
break;
|
|
1427
|
+
case /* optional resources.jobs.colleagues.Colleague created_by */ 8:
|
|
1428
|
+
message.createdBy = Colleague.internalBinaryRead(reader, reader.uint32(), options, message.createdBy);
|
|
1429
|
+
break;
|
|
1430
|
+
case /* resources.timestamp.Timestamp created_at */ 9:
|
|
1431
|
+
message.createdAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.createdAt);
|
|
1432
|
+
break;
|
|
1433
|
+
case /* optional resources.timestamp.Timestamp updated_at */ 10:
|
|
1434
|
+
message.updatedAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.updatedAt);
|
|
1435
|
+
break;
|
|
1436
|
+
default:
|
|
1437
|
+
let u = options.readUnknownField;
|
|
1438
|
+
if (u === "throw")
|
|
1439
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1440
|
+
let d = reader.skip(wireType);
|
|
1441
|
+
if (u !== false)
|
|
1442
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1443
|
+
}
|
|
1444
|
+
}
|
|
1445
|
+
return message;
|
|
1446
|
+
}
|
|
1447
|
+
internalBinaryWrite(message: GroupRule, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1448
|
+
/* int64 id = 1; */
|
|
1449
|
+
if (message.id !== 0)
|
|
1450
|
+
writer.tag(1, WireType.Varint).int64(message.id);
|
|
1451
|
+
/* int64 group_id = 2; */
|
|
1452
|
+
if (message.groupId !== 0)
|
|
1453
|
+
writer.tag(2, WireType.Varint).int64(message.groupId);
|
|
1454
|
+
/* bool enabled = 3; */
|
|
1455
|
+
if (message.enabled !== false)
|
|
1456
|
+
writer.tag(3, WireType.Varint).bool(message.enabled);
|
|
1457
|
+
/* resources.jobs.groups.GroupRuleType type = 4; */
|
|
1458
|
+
if (message.type !== 0)
|
|
1459
|
+
writer.tag(4, WireType.Varint).int32(message.type);
|
|
1460
|
+
/* resources.jobs.groups.GroupGradeRule grade = 5; */
|
|
1461
|
+
if (message.rule.oneofKind === "grade")
|
|
1462
|
+
GroupGradeRule.internalBinaryWrite(message.rule.grade, writer.tag(5, WireType.LengthDelimited).fork(), options).join();
|
|
1463
|
+
/* resources.jobs.groups.GroupQualificationRule qualification = 6; */
|
|
1464
|
+
if (message.rule.oneofKind === "qualification")
|
|
1465
|
+
GroupQualificationRule.internalBinaryWrite(message.rule.qualification, writer.tag(6, WireType.LengthDelimited).fork(), options).join();
|
|
1466
|
+
/* optional int32 created_by_user_id = 7; */
|
|
1467
|
+
if (message.createdByUserId !== undefined)
|
|
1468
|
+
writer.tag(7, WireType.Varint).int32(message.createdByUserId);
|
|
1469
|
+
/* optional resources.jobs.colleagues.Colleague created_by = 8; */
|
|
1470
|
+
if (message.createdBy)
|
|
1471
|
+
Colleague.internalBinaryWrite(message.createdBy, writer.tag(8, WireType.LengthDelimited).fork(), options).join();
|
|
1472
|
+
/* resources.timestamp.Timestamp created_at = 9; */
|
|
1473
|
+
if (message.createdAt)
|
|
1474
|
+
Timestamp.internalBinaryWrite(message.createdAt, writer.tag(9, WireType.LengthDelimited).fork(), options).join();
|
|
1475
|
+
/* optional resources.timestamp.Timestamp updated_at = 10; */
|
|
1476
|
+
if (message.updatedAt)
|
|
1477
|
+
Timestamp.internalBinaryWrite(message.updatedAt, writer.tag(10, WireType.LengthDelimited).fork(), options).join();
|
|
1478
|
+
let u = options.writeUnknownFields;
|
|
1479
|
+
if (u !== false)
|
|
1480
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1481
|
+
return writer;
|
|
1482
|
+
}
|
|
1483
|
+
}
|
|
1484
|
+
/**
|
|
1485
|
+
* @generated MessageType for protobuf message resources.jobs.groups.GroupRule
|
|
1486
|
+
*/
|
|
1487
|
+
export const GroupRule = new GroupRule$Type();
|
|
1488
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1489
|
+
class GroupMembershipReason$Type extends MessageType<GroupMembershipReason> {
|
|
1490
|
+
constructor() {
|
|
1491
|
+
super("resources.jobs.groups.GroupMembershipReason", [
|
|
1492
|
+
{ no: 1, name: "source", kind: "enum", T: () => ["resources.jobs.groups.GroupMemberSource", GroupMemberSource, "GROUP_MEMBER_SOURCE_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } },
|
|
1493
|
+
{ no: 2, name: "rule_id", kind: "scalar", opt: true, T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
1494
|
+
{ no: 3, name: "type", kind: "enum", T: () => ["resources.jobs.groups.GroupMembershipReasonType", GroupMembershipReasonType, "GROUP_MEMBERSHIP_REASON_TYPE_"], options: { "buf.validate.field": { enum: { definedOnly: true } } } },
|
|
1495
|
+
{ no: 4, name: "detail", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ }
|
|
1496
|
+
]);
|
|
1497
|
+
}
|
|
1498
|
+
create(value?: PartialMessage<GroupMembershipReason>): GroupMembershipReason {
|
|
1499
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1500
|
+
message.source = 0;
|
|
1501
|
+
message.type = 0;
|
|
1502
|
+
if (value !== undefined)
|
|
1503
|
+
reflectionMergePartial<GroupMembershipReason>(this, message, value);
|
|
1504
|
+
return message;
|
|
1505
|
+
}
|
|
1506
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GroupMembershipReason): GroupMembershipReason {
|
|
1507
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1508
|
+
while (reader.pos < end) {
|
|
1509
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1510
|
+
switch (fieldNo) {
|
|
1511
|
+
case /* resources.jobs.groups.GroupMemberSource source */ 1:
|
|
1512
|
+
message.source = reader.int32();
|
|
1513
|
+
break;
|
|
1514
|
+
case /* optional int64 rule_id */ 2:
|
|
1515
|
+
message.ruleId = reader.int64().toNumber();
|
|
1516
|
+
break;
|
|
1517
|
+
case /* resources.jobs.groups.GroupMembershipReasonType type */ 3:
|
|
1518
|
+
message.type = reader.int32();
|
|
1519
|
+
break;
|
|
1520
|
+
case /* optional string detail */ 4:
|
|
1521
|
+
message.detail = reader.string();
|
|
1522
|
+
break;
|
|
1523
|
+
default:
|
|
1524
|
+
let u = options.readUnknownField;
|
|
1525
|
+
if (u === "throw")
|
|
1526
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1527
|
+
let d = reader.skip(wireType);
|
|
1528
|
+
if (u !== false)
|
|
1529
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1530
|
+
}
|
|
1531
|
+
}
|
|
1532
|
+
return message;
|
|
1533
|
+
}
|
|
1534
|
+
internalBinaryWrite(message: GroupMembershipReason, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1535
|
+
/* resources.jobs.groups.GroupMemberSource source = 1; */
|
|
1536
|
+
if (message.source !== 0)
|
|
1537
|
+
writer.tag(1, WireType.Varint).int32(message.source);
|
|
1538
|
+
/* optional int64 rule_id = 2; */
|
|
1539
|
+
if (message.ruleId !== undefined)
|
|
1540
|
+
writer.tag(2, WireType.Varint).int64(message.ruleId);
|
|
1541
|
+
/* resources.jobs.groups.GroupMembershipReasonType type = 3; */
|
|
1542
|
+
if (message.type !== 0)
|
|
1543
|
+
writer.tag(3, WireType.Varint).int32(message.type);
|
|
1544
|
+
/* optional string detail = 4; */
|
|
1545
|
+
if (message.detail !== undefined)
|
|
1546
|
+
writer.tag(4, WireType.LengthDelimited).string(message.detail);
|
|
1547
|
+
let u = options.writeUnknownFields;
|
|
1548
|
+
if (u !== false)
|
|
1549
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1550
|
+
return writer;
|
|
1551
|
+
}
|
|
1552
|
+
}
|
|
1553
|
+
/**
|
|
1554
|
+
* @generated MessageType for protobuf message resources.jobs.groups.GroupMembershipReason
|
|
1555
|
+
*/
|
|
1556
|
+
export const GroupMembershipReason = new GroupMembershipReason$Type();
|
|
1557
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1558
|
+
class GroupResolvedMember$Type extends MessageType<GroupResolvedMember> {
|
|
1559
|
+
constructor() {
|
|
1560
|
+
super("resources.jobs.groups.GroupResolvedMember", [
|
|
1561
|
+
{ no: 1, name: "group_id", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
1562
|
+
{ no: 2, name: "user_id", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
|
|
1563
|
+
{ no: 3, name: "colleague", kind: "message", T: () => Colleague },
|
|
1564
|
+
{ no: 4, name: "is_member", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
|
|
1565
|
+
{ no: 5, name: "is_leader", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
|
|
1566
|
+
{ no: 6, name: "is_excluded", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
|
|
1567
|
+
{ no: 7, name: "sources", kind: "enum", repeat: 1 /*RepeatType.PACKED*/, T: () => ["resources.jobs.groups.GroupMemberSource", GroupMemberSource, "GROUP_MEMBER_SOURCE_"], options: { "buf.validate.field": { repeated: { maxItems: "4", items: { enum: { definedOnly: true } } } } } },
|
|
1568
|
+
{ no: 8, name: "reasons", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => GroupMembershipReason, options: { "buf.validate.field": { repeated: { maxItems: "8" } } } }
|
|
1569
|
+
]);
|
|
1570
|
+
}
|
|
1571
|
+
create(value?: PartialMessage<GroupResolvedMember>): GroupResolvedMember {
|
|
1572
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1573
|
+
message.groupId = 0;
|
|
1574
|
+
message.userId = 0;
|
|
1575
|
+
message.isMember = false;
|
|
1576
|
+
message.isLeader = false;
|
|
1577
|
+
message.isExcluded = false;
|
|
1578
|
+
message.sources = [];
|
|
1579
|
+
message.reasons = [];
|
|
1580
|
+
if (value !== undefined)
|
|
1581
|
+
reflectionMergePartial<GroupResolvedMember>(this, message, value);
|
|
1582
|
+
return message;
|
|
1583
|
+
}
|
|
1584
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GroupResolvedMember): GroupResolvedMember {
|
|
1585
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1586
|
+
while (reader.pos < end) {
|
|
1587
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1588
|
+
switch (fieldNo) {
|
|
1589
|
+
case /* int64 group_id */ 1:
|
|
1590
|
+
message.groupId = reader.int64().toNumber();
|
|
1591
|
+
break;
|
|
1592
|
+
case /* int32 user_id */ 2:
|
|
1593
|
+
message.userId = reader.int32();
|
|
1594
|
+
break;
|
|
1595
|
+
case /* optional resources.jobs.colleagues.Colleague colleague */ 3:
|
|
1596
|
+
message.colleague = Colleague.internalBinaryRead(reader, reader.uint32(), options, message.colleague);
|
|
1597
|
+
break;
|
|
1598
|
+
case /* bool is_member */ 4:
|
|
1599
|
+
message.isMember = reader.bool();
|
|
1600
|
+
break;
|
|
1601
|
+
case /* bool is_leader */ 5:
|
|
1602
|
+
message.isLeader = reader.bool();
|
|
1603
|
+
break;
|
|
1604
|
+
case /* bool is_excluded */ 6:
|
|
1605
|
+
message.isExcluded = reader.bool();
|
|
1606
|
+
break;
|
|
1607
|
+
case /* repeated resources.jobs.groups.GroupMemberSource sources */ 7:
|
|
1608
|
+
if (wireType === WireType.LengthDelimited)
|
|
1609
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
1610
|
+
message.sources.push(reader.int32());
|
|
1611
|
+
else
|
|
1612
|
+
message.sources.push(reader.int32());
|
|
1613
|
+
break;
|
|
1614
|
+
case /* repeated resources.jobs.groups.GroupMembershipReason reasons */ 8:
|
|
1615
|
+
message.reasons.push(GroupMembershipReason.internalBinaryRead(reader, reader.uint32(), options));
|
|
1616
|
+
break;
|
|
1617
|
+
default:
|
|
1618
|
+
let u = options.readUnknownField;
|
|
1619
|
+
if (u === "throw")
|
|
1620
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1621
|
+
let d = reader.skip(wireType);
|
|
1622
|
+
if (u !== false)
|
|
1623
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1624
|
+
}
|
|
1625
|
+
}
|
|
1626
|
+
return message;
|
|
1627
|
+
}
|
|
1628
|
+
internalBinaryWrite(message: GroupResolvedMember, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1629
|
+
/* int64 group_id = 1; */
|
|
1630
|
+
if (message.groupId !== 0)
|
|
1631
|
+
writer.tag(1, WireType.Varint).int64(message.groupId);
|
|
1632
|
+
/* int32 user_id = 2; */
|
|
1633
|
+
if (message.userId !== 0)
|
|
1634
|
+
writer.tag(2, WireType.Varint).int32(message.userId);
|
|
1635
|
+
/* optional resources.jobs.colleagues.Colleague colleague = 3; */
|
|
1636
|
+
if (message.colleague)
|
|
1637
|
+
Colleague.internalBinaryWrite(message.colleague, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
1638
|
+
/* bool is_member = 4; */
|
|
1639
|
+
if (message.isMember !== false)
|
|
1640
|
+
writer.tag(4, WireType.Varint).bool(message.isMember);
|
|
1641
|
+
/* bool is_leader = 5; */
|
|
1642
|
+
if (message.isLeader !== false)
|
|
1643
|
+
writer.tag(5, WireType.Varint).bool(message.isLeader);
|
|
1644
|
+
/* bool is_excluded = 6; */
|
|
1645
|
+
if (message.isExcluded !== false)
|
|
1646
|
+
writer.tag(6, WireType.Varint).bool(message.isExcluded);
|
|
1647
|
+
/* repeated resources.jobs.groups.GroupMemberSource sources = 7; */
|
|
1648
|
+
if (message.sources.length) {
|
|
1649
|
+
writer.tag(7, WireType.LengthDelimited).fork();
|
|
1650
|
+
for (let i = 0; i < message.sources.length; i++)
|
|
1651
|
+
writer.int32(message.sources[i]);
|
|
1652
|
+
writer.join();
|
|
1653
|
+
}
|
|
1654
|
+
/* repeated resources.jobs.groups.GroupMembershipReason reasons = 8; */
|
|
1655
|
+
for (let i = 0; i < message.reasons.length; i++)
|
|
1656
|
+
GroupMembershipReason.internalBinaryWrite(message.reasons[i], writer.tag(8, WireType.LengthDelimited).fork(), options).join();
|
|
1657
|
+
let u = options.writeUnknownFields;
|
|
1658
|
+
if (u !== false)
|
|
1659
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1660
|
+
return writer;
|
|
1661
|
+
}
|
|
1662
|
+
}
|
|
1663
|
+
/**
|
|
1664
|
+
* @generated MessageType for protobuf message resources.jobs.groups.GroupResolvedMember
|
|
1665
|
+
*/
|
|
1666
|
+
export const GroupResolvedMember = new GroupResolvedMember$Type();
|