@hed-hog/operations 0.0.294 → 0.0.296
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/dist/operations.controller.d.ts +415 -0
- package/dist/operations.controller.d.ts.map +1 -0
- package/dist/operations.controller.js +333 -0
- package/dist/operations.controller.js.map +1 -0
- package/dist/operations.module.d.ts.map +1 -1
- package/dist/operations.module.js +4 -3
- package/dist/operations.module.js.map +1 -1
- package/dist/operations.service.d.ts +589 -153
- package/dist/operations.service.d.ts.map +1 -1
- package/dist/operations.service.js +2229 -100
- package/dist/operations.service.js.map +1 -1
- package/hedhog/data/menu.yaml +198 -251
- package/hedhog/data/role.yaml +23 -14
- package/hedhog/data/route.yaml +317 -143
- package/hedhog/frontend/app/_components/collaborator-details-screen.tsx.ejs +310 -0
- package/hedhog/frontend/app/_components/collaborator-form-screen.tsx.ejs +631 -0
- package/hedhog/frontend/app/_components/contract-details-screen.tsx.ejs +132 -0
- package/hedhog/frontend/app/_components/contract-form-screen.tsx.ejs +558 -0
- package/hedhog/frontend/app/_components/project-details-screen.tsx.ejs +291 -0
- package/hedhog/frontend/app/_components/project-form-screen.tsx.ejs +689 -0
- package/hedhog/frontend/app/_lib/api.ts.ejs +32 -0
- package/hedhog/frontend/app/_lib/hooks/use-operations-access.ts.ejs +44 -0
- package/hedhog/frontend/app/_lib/types.ts.ejs +360 -0
- package/hedhog/frontend/app/_lib/utils/format.ts.ejs +129 -25
- package/hedhog/frontend/app/_lib/utils/forms.ts.ejs +14 -0
- package/hedhog/frontend/app/approvals/page.tsx.ejs +386 -147
- package/hedhog/frontend/app/collaborators/[id]/edit/page.tsx.ejs +11 -0
- package/hedhog/frontend/app/collaborators/[id]/page.tsx.ejs +11 -0
- package/hedhog/frontend/app/collaborators/new/page.tsx.ejs +5 -0
- package/hedhog/frontend/app/collaborators/page.tsx.ejs +261 -0
- package/hedhog/frontend/app/contracts/[id]/edit/page.tsx.ejs +11 -0
- package/hedhog/frontend/app/contracts/[id]/page.tsx.ejs +11 -108
- package/hedhog/frontend/app/contracts/new/page.tsx.ejs +17 -0
- package/hedhog/frontend/app/contracts/page.tsx.ejs +262 -181
- package/hedhog/frontend/app/page.tsx.ejs +319 -177
- package/hedhog/frontend/app/projects/[id]/edit/page.tsx.ejs +11 -0
- package/hedhog/frontend/app/projects/[id]/page.tsx.ejs +11 -936
- package/hedhog/frontend/app/projects/new/page.tsx.ejs +5 -0
- package/hedhog/frontend/app/projects/page.tsx.ejs +236 -1074
- package/hedhog/frontend/app/schedule-adjustments/page.tsx.ejs +418 -0
- package/hedhog/frontend/app/team/page.tsx.ejs +339 -0
- package/hedhog/frontend/app/time-off/page.tsx.ejs +328 -0
- package/hedhog/frontend/app/timesheets/page.tsx.ejs +636 -126
- package/hedhog/frontend/messages/en.json +648 -454
- package/hedhog/frontend/messages/pt.json +647 -454
- package/hedhog/table/operations_approval.yaml +49 -0
- package/hedhog/table/operations_approval_history.yaml +29 -0
- package/hedhog/table/{operations_employee.yaml → operations_collaborator.yaml} +67 -64
- package/hedhog/table/operations_collaborator_schedule_day.yaml +34 -0
- package/hedhog/table/operations_contract.yaml +100 -48
- package/hedhog/table/operations_contract_document.yaml +39 -0
- package/hedhog/table/operations_contract_financial_term.yaml +40 -0
- package/hedhog/table/operations_contract_history.yaml +27 -0
- package/hedhog/table/operations_contract_party.yaml +46 -0
- package/hedhog/table/operations_contract_revision.yaml +38 -0
- package/hedhog/table/operations_contract_signature.yaml +38 -0
- package/hedhog/table/operations_project.yaml +54 -50
- package/hedhog/table/{operations_allocation.yaml → operations_project_assignment.yaml} +55 -52
- package/hedhog/table/operations_schedule_adjustment_day.yaml +34 -0
- package/hedhog/table/operations_schedule_adjustment_request.yaml +53 -0
- package/hedhog/table/operations_time_off_request.yaml +57 -0
- package/hedhog/table/operations_timesheet.yaml +41 -36
- package/hedhog/table/operations_timesheet_entry.yaml +40 -50
- package/package.json +7 -6
- package/src/operations.controller.ts +182 -0
- package/src/operations.module.ts +22 -21
- package/src/operations.service.ts +3595 -137
- package/hedhog/data/operations_career_level.yaml +0 -102
- package/hedhog/data/operations_career_track.yaml +0 -8
- package/hedhog/data/operations_certification.yaml +0 -38
- package/hedhog/data/operations_evaluation_cycle.yaml +0 -18
- package/hedhog/data/operations_performance_criterion.yaml +0 -48
- package/hedhog/frontend/app/_components/allocation-calendar.tsx.ejs +0 -56
- package/hedhog/frontend/app/_components/kanban-board.tsx.ejs +0 -626
- package/hedhog/frontend/app/_components/timesheet-entry-dialog.tsx.ejs +0 -142
- package/hedhog/frontend/app/_lib/hooks/use-operations-data.ts.ejs +0 -41
- package/hedhog/frontend/app/_lib/hooks/use-operations-growth-data.ts.ejs +0 -63
- package/hedhog/frontend/app/_lib/mocks/allocations.mock.ts.ejs +0 -74
- package/hedhog/frontend/app/_lib/mocks/contracts.mock.ts.ejs +0 -74
- package/hedhog/frontend/app/_lib/mocks/operations-growth.mock.ts.ejs +0 -824
- package/hedhog/frontend/app/_lib/mocks/projects.mock.ts.ejs +0 -455
- package/hedhog/frontend/app/_lib/mocks/tasks.mock.ts.ejs +0 -117
- package/hedhog/frontend/app/_lib/mocks/timesheets.mock.ts.ejs +0 -84
- package/hedhog/frontend/app/_lib/mocks/users.mock.ts.ejs +0 -67
- package/hedhog/frontend/app/_lib/services/contracts.service.ts.ejs +0 -10
- package/hedhog/frontend/app/_lib/services/operations-growth.service.ts.ejs +0 -31
- package/hedhog/frontend/app/_lib/services/projects.service.ts.ejs +0 -10
- package/hedhog/frontend/app/_lib/services/tasks.service.ts.ejs +0 -10
- package/hedhog/frontend/app/_lib/services/timesheets.service.ts.ejs +0 -10
- package/hedhog/frontend/app/_lib/types/operations-growth.ts.ejs +0 -209
- package/hedhog/frontend/app/_lib/types/operations.ts.ejs +0 -156
- package/hedhog/frontend/app/_lib/utils/growth.ts.ejs +0 -62
- package/hedhog/frontend/app/_lib/utils/metrics.ts.ejs +0 -103
- package/hedhog/frontend/app/_lib/utils/status.ts.ejs +0 -80
- package/hedhog/frontend/app/allocations/page.tsx.ejs +0 -155
- package/hedhog/frontend/app/career/page.tsx.ejs +0 -143
- package/hedhog/frontend/app/certifications/page.tsx.ejs +0 -202
- package/hedhog/frontend/app/evaluations/page.tsx.ejs +0 -278
- package/hedhog/frontend/app/goals/page.tsx.ejs +0 -171
- package/hedhog/frontend/app/growth/page.tsx.ejs +0 -288
- package/hedhog/frontend/app/manager/page.tsx.ejs +0 -175
- package/hedhog/frontend/app/rewards/page.tsx.ejs +0 -196
- package/hedhog/frontend/app/tasks/page.tsx.ejs +0 -999
- package/hedhog/table/operations_calibration_item.yaml +0 -61
- package/hedhog/table/operations_calibration_session.yaml +0 -25
- package/hedhog/table/operations_career_level.yaml +0 -75
- package/hedhog/table/operations_career_track.yaml +0 -21
- package/hedhog/table/operations_certification.yaml +0 -48
- package/hedhog/table/operations_employee_certification.yaml +0 -43
- package/hedhog/table/operations_employee_connect.yaml +0 -61
- package/hedhog/table/operations_employee_evaluation.yaml +0 -113
- package/hedhog/table/operations_employee_evaluation_item.yaml +0 -39
- package/hedhog/table/operations_employee_profile.yaml +0 -80
- package/hedhog/table/operations_employee_skill_matrix.yaml +0 -30
- package/hedhog/table/operations_evaluation_cycle.yaml +0 -31
- package/hedhog/table/operations_goal.yaml +0 -67
- package/hedhog/table/operations_goal_progress.yaml +0 -31
- package/hedhog/table/operations_performance_criterion.yaml +0 -29
- package/hedhog/table/operations_promotion_readiness.yaml +0 -49
- package/hedhog/table/operations_promotion_recommendation.yaml +0 -63
- package/hedhog/table/operations_public_recognition.yaml +0 -46
- package/hedhog/table/operations_reward.yaml +0 -100
- package/hedhog/table/operations_score_event.yaml +0 -81
- package/hedhog/table/operations_task.yaml +0 -60
- package/src/operations-data.controller.ts +0 -54
- package/src/operations-growth.controller.ts +0 -44
|
@@ -1,178 +1,614 @@
|
|
|
1
|
+
import { PrismaService } from '@hed-hog/api-prisma';
|
|
2
|
+
import { IntegrationDeveloperApiService } from '@hed-hog/core';
|
|
3
|
+
type CollaboratorPayload = {
|
|
4
|
+
userId: number;
|
|
5
|
+
code: string;
|
|
6
|
+
displayName: string;
|
|
7
|
+
collaboratorType?: 'clt' | 'pj' | 'freelancer' | 'intern' | 'other';
|
|
8
|
+
department?: string | null;
|
|
9
|
+
title?: string | null;
|
|
10
|
+
levelLabel?: string | null;
|
|
11
|
+
supervisorCollaboratorId?: number | null;
|
|
12
|
+
weeklyCapacityHours?: number | null;
|
|
13
|
+
status?: 'active' | 'on_leave' | 'inactive';
|
|
14
|
+
joinedAt?: string | null;
|
|
15
|
+
leftAt?: string | null;
|
|
16
|
+
compensationAmount?: number | null;
|
|
17
|
+
contractDescription?: string | null;
|
|
18
|
+
autoGenerateContractDraft?: boolean;
|
|
19
|
+
weeklySchedule?: Array<{
|
|
20
|
+
weekday: 'monday' | 'tuesday' | 'wednesday' | 'thursday' | 'friday' | 'saturday' | 'sunday';
|
|
21
|
+
isWorkingDay?: boolean;
|
|
22
|
+
startTime?: string | null;
|
|
23
|
+
endTime?: string | null;
|
|
24
|
+
breakMinutes?: number | null;
|
|
25
|
+
}>;
|
|
26
|
+
notes?: string | null;
|
|
27
|
+
};
|
|
28
|
+
type ContractPayload = {
|
|
29
|
+
code: string;
|
|
30
|
+
name: string;
|
|
31
|
+
clientName: string;
|
|
32
|
+
contractCategory?: 'employee' | 'contractor' | 'client' | 'supplier' | 'vendor' | 'partner' | 'internal' | 'other';
|
|
33
|
+
contractType?: 'clt' | 'pj' | 'freelancer_agreement' | 'service_agreement' | 'fixed_term' | 'recurring_service' | 'nda' | 'amendment' | 'addendum' | 'other';
|
|
34
|
+
billingModel?: 'time_and_material' | 'monthly_retainer' | 'fixed_price';
|
|
35
|
+
signatureStatus?: 'not_started' | 'pending' | 'partially_signed' | 'signed' | 'expired';
|
|
36
|
+
isActive?: boolean;
|
|
37
|
+
accountManagerCollaboratorId?: number | null;
|
|
38
|
+
relatedCollaboratorId?: number | null;
|
|
39
|
+
originType?: 'manual' | 'employee_hiring' | 'client_project';
|
|
40
|
+
originId?: number | null;
|
|
41
|
+
startDate: string;
|
|
42
|
+
endDate?: string | null;
|
|
43
|
+
signedAt?: string | null;
|
|
44
|
+
effectiveDate?: string | null;
|
|
45
|
+
budgetAmount?: number | null;
|
|
46
|
+
monthlyHourCap?: number | null;
|
|
47
|
+
status?: 'draft' | 'under_review' | 'active' | 'renewal' | 'expired' | 'closed' | 'archived';
|
|
48
|
+
description?: string | null;
|
|
49
|
+
contentHtml?: string | null;
|
|
50
|
+
parties?: Array<{
|
|
51
|
+
partyRole?: 'employee' | 'employer' | 'client' | 'supplier' | 'vendor' | 'partner' | 'witness' | 'internal_owner' | 'other';
|
|
52
|
+
partyType?: 'individual' | 'company' | 'internal_team' | 'other';
|
|
53
|
+
displayName: string;
|
|
54
|
+
documentNumber?: string | null;
|
|
55
|
+
email?: string | null;
|
|
56
|
+
phone?: string | null;
|
|
57
|
+
isPrimary?: boolean;
|
|
58
|
+
}>;
|
|
59
|
+
signatures?: Array<{
|
|
60
|
+
signerName: string;
|
|
61
|
+
signerRole?: string | null;
|
|
62
|
+
signerEmail?: string | null;
|
|
63
|
+
status?: 'pending' | 'signed' | 'rejected';
|
|
64
|
+
signedAt?: string | null;
|
|
65
|
+
}>;
|
|
66
|
+
financialTerms?: Array<{
|
|
67
|
+
termType?: 'value' | 'payment' | 'revenue' | 'fine' | 'other';
|
|
68
|
+
label: string;
|
|
69
|
+
amount: number;
|
|
70
|
+
recurrence?: 'one_time' | 'monthly' | 'quarterly' | 'yearly' | 'other';
|
|
71
|
+
dueDay?: number | null;
|
|
72
|
+
notes?: string | null;
|
|
73
|
+
}>;
|
|
74
|
+
revisions?: Array<{
|
|
75
|
+
revisionType?: 'amendment' | 'renewal' | 'revision' | 'addendum' | 'other';
|
|
76
|
+
title: string;
|
|
77
|
+
effectiveDate?: string | null;
|
|
78
|
+
status?: 'draft' | 'active' | 'completed' | 'cancelled';
|
|
79
|
+
summary?: string | null;
|
|
80
|
+
}>;
|
|
81
|
+
replaceUploadedPdfDocument?: {
|
|
82
|
+
fileName: string;
|
|
83
|
+
mimeType: string;
|
|
84
|
+
fileContentBase64: string;
|
|
85
|
+
notes?: string | null;
|
|
86
|
+
} | null;
|
|
87
|
+
};
|
|
88
|
+
type ProjectPayload = {
|
|
89
|
+
contractId?: number | null;
|
|
90
|
+
managerCollaboratorId?: number | null;
|
|
91
|
+
code: string;
|
|
92
|
+
name: string;
|
|
93
|
+
clientName?: string | null;
|
|
94
|
+
summary?: string | null;
|
|
95
|
+
status?: 'planning' | 'active' | 'at_risk' | 'paused' | 'completed' | 'archived';
|
|
96
|
+
progressPercent?: number | null;
|
|
97
|
+
deliveryModel?: 'dedicated_team' | 'shared_team' | 'project_delivery' | 'support';
|
|
98
|
+
budgetAmount?: number | null;
|
|
99
|
+
startDate?: string | null;
|
|
100
|
+
endDate?: string | null;
|
|
101
|
+
billingModel?: 'time_and_material' | 'monthly_retainer' | 'fixed_price';
|
|
102
|
+
monthlyHourCap?: number | null;
|
|
103
|
+
contractCode?: string | null;
|
|
104
|
+
contractName?: string | null;
|
|
105
|
+
contractDescription?: string | null;
|
|
106
|
+
autoGenerateContractDraft?: boolean;
|
|
107
|
+
teamAssignments?: Array<{
|
|
108
|
+
collaboratorId: number;
|
|
109
|
+
roleLabel?: string | null;
|
|
110
|
+
allocationPercent?: number | null;
|
|
111
|
+
weeklyHours?: number | null;
|
|
112
|
+
isBillable?: boolean;
|
|
113
|
+
startDate?: string | null;
|
|
114
|
+
endDate?: string | null;
|
|
115
|
+
status?: 'planned' | 'active' | 'completed' | 'cancelled';
|
|
116
|
+
}>;
|
|
117
|
+
};
|
|
118
|
+
type TimesheetEntryPayload = {
|
|
119
|
+
projectAssignmentId?: number | null;
|
|
120
|
+
activityLabel?: string | null;
|
|
121
|
+
workDate: string;
|
|
122
|
+
hours: number;
|
|
123
|
+
description?: string | null;
|
|
124
|
+
};
|
|
125
|
+
type TimesheetPayload = {
|
|
126
|
+
collaboratorId?: number | null;
|
|
127
|
+
weekStartDate: string;
|
|
128
|
+
weekEndDate: string;
|
|
129
|
+
notes?: string | null;
|
|
130
|
+
entries?: TimesheetEntryPayload[];
|
|
131
|
+
};
|
|
132
|
+
type TimeOffPayload = {
|
|
133
|
+
collaboratorId?: number | null;
|
|
134
|
+
requestType?: 'vacation' | 'personal_time' | 'sick_leave' | 'unpaid_leave' | 'other';
|
|
135
|
+
startDate: string;
|
|
136
|
+
endDate: string;
|
|
137
|
+
totalDays?: number | null;
|
|
138
|
+
reason?: string | null;
|
|
139
|
+
};
|
|
140
|
+
type ScheduleAdjustmentDayPayload = {
|
|
141
|
+
weekday: 'monday' | 'tuesday' | 'wednesday' | 'thursday' | 'friday' | 'saturday' | 'sunday';
|
|
142
|
+
isWorkingDay?: boolean;
|
|
143
|
+
startTime?: string | null;
|
|
144
|
+
endTime?: string | null;
|
|
145
|
+
breakMinutes?: number | null;
|
|
146
|
+
};
|
|
147
|
+
type ScheduleAdjustmentPayload = {
|
|
148
|
+
collaboratorId?: number | null;
|
|
149
|
+
requestScope?: 'temporary' | 'permanent';
|
|
150
|
+
effectiveStartDate: string;
|
|
151
|
+
effectiveEndDate?: string | null;
|
|
152
|
+
reason?: string | null;
|
|
153
|
+
days: ScheduleAdjustmentDayPayload[];
|
|
154
|
+
};
|
|
155
|
+
type DecisionPayload = {
|
|
156
|
+
note?: string | null;
|
|
157
|
+
};
|
|
158
|
+
type PublishAccountsPayableReferencePayload = {
|
|
159
|
+
sourceEntityId: string;
|
|
160
|
+
sourceEntityType?: string;
|
|
161
|
+
personId: number;
|
|
162
|
+
dueDate: string;
|
|
163
|
+
totalAmount: number;
|
|
164
|
+
documentNumber: string;
|
|
165
|
+
description?: string | null;
|
|
166
|
+
paymentChannel?: string | null;
|
|
167
|
+
financeCategoryId?: number | null;
|
|
168
|
+
costCenterId?: number | null;
|
|
169
|
+
locale?: string;
|
|
170
|
+
};
|
|
1
171
|
export declare class OperationsService {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
};
|
|
47
|
-
evaluations: {
|
|
48
|
-
id: number;
|
|
49
|
-
employeeId: number;
|
|
50
|
-
cycle: string;
|
|
51
|
-
status: string;
|
|
52
|
-
generatedScore: number;
|
|
53
|
-
}[];
|
|
54
|
-
goals: {
|
|
55
|
-
id: number;
|
|
56
|
-
employeeId: number;
|
|
57
|
-
title: string;
|
|
58
|
-
status: string;
|
|
59
|
-
progressPercent: number;
|
|
60
|
-
}[];
|
|
61
|
-
certifications: {
|
|
62
|
-
id: number;
|
|
63
|
-
slug: string;
|
|
64
|
-
status: string;
|
|
65
|
-
}[];
|
|
66
|
-
rewards: {
|
|
67
|
-
id: number;
|
|
68
|
-
employeeId: number;
|
|
69
|
-
rewardType: string;
|
|
70
|
-
status: string;
|
|
71
|
-
}[];
|
|
72
|
-
career: {
|
|
73
|
-
id: number;
|
|
74
|
-
track: string;
|
|
75
|
-
currentLevel: string;
|
|
76
|
-
nextLevel: string;
|
|
77
|
-
}[];
|
|
78
|
-
manager: {
|
|
79
|
-
summary: {
|
|
80
|
-
promotionEligible: number;
|
|
81
|
-
goalsAtRisk: number;
|
|
82
|
-
pendingCertifications: number;
|
|
83
|
-
};
|
|
84
|
-
};
|
|
85
|
-
};
|
|
86
|
-
};
|
|
87
|
-
listContracts(): {
|
|
172
|
+
private readonly prisma;
|
|
173
|
+
private readonly integrationApi;
|
|
174
|
+
constructor(prisma: PrismaService, integrationApi: IntegrationDeveloperApiService);
|
|
175
|
+
getDashboard(userId: number): Promise<{
|
|
176
|
+
actor: {
|
|
177
|
+
roleScope: string;
|
|
178
|
+
collaboratorId: number;
|
|
179
|
+
collaboratorName: string;
|
|
180
|
+
teamSize: number;
|
|
181
|
+
};
|
|
182
|
+
cards: {
|
|
183
|
+
projectsTotal: number;
|
|
184
|
+
activeProjects: number;
|
|
185
|
+
visibleTimesheets: number;
|
|
186
|
+
pendingTimesheets: number;
|
|
187
|
+
timeOffRequests: number;
|
|
188
|
+
scheduleAdjustmentRequests: number;
|
|
189
|
+
pendingApprovals: number;
|
|
190
|
+
};
|
|
191
|
+
recentTimesheets: {
|
|
192
|
+
id: number;
|
|
193
|
+
collaboratorName: string;
|
|
194
|
+
weekStartDate: string;
|
|
195
|
+
weekEndDate: string;
|
|
196
|
+
totalHours: number | null;
|
|
197
|
+
status: string;
|
|
198
|
+
}[];
|
|
199
|
+
}>;
|
|
200
|
+
listCollaborators(userId: number): Promise<Record<string, unknown>[]>;
|
|
201
|
+
getMyCollaborator(userId: number): Promise<{
|
|
202
|
+
assignedProjects: Record<string, unknown>[];
|
|
203
|
+
relatedContracts: Record<string, unknown>[];
|
|
204
|
+
weeklySchedule: Record<string, unknown>[];
|
|
205
|
+
timesheetSummary: {
|
|
206
|
+
totalTimesheets: number;
|
|
207
|
+
pendingTimesheets: number;
|
|
208
|
+
totalHours: number;
|
|
209
|
+
};
|
|
210
|
+
timeOffSummary: {
|
|
211
|
+
totalRequests: number;
|
|
212
|
+
pendingRequests: number;
|
|
213
|
+
approvedRequests: number;
|
|
214
|
+
};
|
|
215
|
+
scheduleAdjustmentRequests: Record<string, unknown>[];
|
|
88
216
|
id: number;
|
|
217
|
+
userId: number;
|
|
89
218
|
code: string;
|
|
90
|
-
|
|
219
|
+
collaboratorType: string;
|
|
220
|
+
displayName: string;
|
|
221
|
+
department: string | null;
|
|
222
|
+
title: string | null;
|
|
223
|
+
levelLabel: string | null;
|
|
224
|
+
weeklyCapacityHours: number | null;
|
|
91
225
|
status: string;
|
|
92
|
-
|
|
93
|
-
|
|
226
|
+
joinedAt: string | null;
|
|
227
|
+
leftAt: string | null;
|
|
228
|
+
notes: string | null;
|
|
229
|
+
supervisorId: number | null;
|
|
230
|
+
supervisorName: string | null;
|
|
231
|
+
contractId: number | null;
|
|
232
|
+
contractStatus: string | null;
|
|
233
|
+
activeAssignments: number;
|
|
234
|
+
}>;
|
|
235
|
+
getCollaboratorByIdForUser(userId: number, collaboratorId: number): Promise<{
|
|
236
|
+
assignedProjects: Record<string, unknown>[];
|
|
237
|
+
relatedContracts: Record<string, unknown>[];
|
|
238
|
+
weeklySchedule: Record<string, unknown>[];
|
|
239
|
+
timesheetSummary: {
|
|
240
|
+
totalTimesheets: number;
|
|
241
|
+
pendingTimesheets: number;
|
|
242
|
+
totalHours: number;
|
|
243
|
+
};
|
|
244
|
+
timeOffSummary: {
|
|
245
|
+
totalRequests: number;
|
|
246
|
+
pendingRequests: number;
|
|
247
|
+
approvedRequests: number;
|
|
248
|
+
};
|
|
249
|
+
scheduleAdjustmentRequests: Record<string, unknown>[];
|
|
94
250
|
id: number;
|
|
251
|
+
userId: number;
|
|
95
252
|
code: string;
|
|
96
|
-
|
|
253
|
+
collaboratorType: string;
|
|
254
|
+
displayName: string;
|
|
255
|
+
department: string | null;
|
|
256
|
+
title: string | null;
|
|
257
|
+
levelLabel: string | null;
|
|
258
|
+
weeklyCapacityHours: number | null;
|
|
97
259
|
status: string;
|
|
98
|
-
|
|
99
|
-
|
|
260
|
+
joinedAt: string | null;
|
|
261
|
+
leftAt: string | null;
|
|
262
|
+
notes: string | null;
|
|
263
|
+
supervisorId: number | null;
|
|
264
|
+
supervisorName: string | null;
|
|
265
|
+
contractId: number | null;
|
|
266
|
+
contractStatus: string | null;
|
|
267
|
+
activeAssignments: number;
|
|
268
|
+
}>;
|
|
269
|
+
getTeam(userId: number): Promise<{
|
|
270
|
+
teamMembers: Record<string, unknown>[];
|
|
271
|
+
projectCount: number;
|
|
272
|
+
pendingApprovals: number;
|
|
273
|
+
pendingItems: {
|
|
274
|
+
timesheets: number;
|
|
275
|
+
timeOffRequests: number;
|
|
276
|
+
scheduleAdjustmentRequests: number;
|
|
277
|
+
};
|
|
278
|
+
teamProjects: Record<string, unknown>[];
|
|
279
|
+
pendingApprovalQueue: Record<string, unknown>[];
|
|
280
|
+
pendingTimeOffRequests: Record<string, unknown>[];
|
|
281
|
+
pendingScheduleAdjustmentRequests: Record<string, unknown>[];
|
|
282
|
+
}>;
|
|
283
|
+
createCollaborator(userId: number, data: CollaboratorPayload): Promise<{
|
|
284
|
+
assignedProjects: Record<string, unknown>[];
|
|
285
|
+
relatedContracts: Record<string, unknown>[];
|
|
286
|
+
weeklySchedule: Record<string, unknown>[];
|
|
287
|
+
timesheetSummary: {
|
|
288
|
+
totalTimesheets: number;
|
|
289
|
+
pendingTimesheets: number;
|
|
290
|
+
totalHours: number;
|
|
291
|
+
};
|
|
292
|
+
timeOffSummary: {
|
|
293
|
+
totalRequests: number;
|
|
294
|
+
pendingRequests: number;
|
|
295
|
+
approvedRequests: number;
|
|
296
|
+
};
|
|
297
|
+
scheduleAdjustmentRequests: Record<string, unknown>[];
|
|
100
298
|
id: number;
|
|
299
|
+
userId: number;
|
|
101
300
|
code: string;
|
|
102
|
-
|
|
301
|
+
collaboratorType: string;
|
|
302
|
+
displayName: string;
|
|
303
|
+
department: string | null;
|
|
304
|
+
title: string | null;
|
|
305
|
+
levelLabel: string | null;
|
|
306
|
+
weeklyCapacityHours: number | null;
|
|
103
307
|
status: string;
|
|
104
|
-
|
|
105
|
-
|
|
308
|
+
joinedAt: string | null;
|
|
309
|
+
leftAt: string | null;
|
|
310
|
+
notes: string | null;
|
|
311
|
+
supervisorId: number | null;
|
|
312
|
+
supervisorName: string | null;
|
|
313
|
+
contractId: number | null;
|
|
314
|
+
contractStatus: string | null;
|
|
315
|
+
activeAssignments: number;
|
|
316
|
+
}>;
|
|
317
|
+
updateCollaborator(userId: number, collaboratorId: number, data: Partial<CollaboratorPayload>): Promise<{
|
|
318
|
+
assignedProjects: Record<string, unknown>[];
|
|
319
|
+
relatedContracts: Record<string, unknown>[];
|
|
320
|
+
weeklySchedule: Record<string, unknown>[];
|
|
321
|
+
timesheetSummary: {
|
|
322
|
+
totalTimesheets: number;
|
|
323
|
+
pendingTimesheets: number;
|
|
324
|
+
totalHours: number;
|
|
325
|
+
};
|
|
326
|
+
timeOffSummary: {
|
|
327
|
+
totalRequests: number;
|
|
328
|
+
pendingRequests: number;
|
|
329
|
+
approvedRequests: number;
|
|
330
|
+
};
|
|
331
|
+
scheduleAdjustmentRequests: Record<string, unknown>[];
|
|
106
332
|
id: number;
|
|
333
|
+
userId: number;
|
|
107
334
|
code: string;
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
projectId: number;
|
|
115
|
-
weeklyHours: number;
|
|
116
|
-
allocationPercent: number;
|
|
117
|
-
}[];
|
|
118
|
-
listTasks(): {
|
|
119
|
-
id: number;
|
|
120
|
-
title: string;
|
|
335
|
+
collaboratorType: string;
|
|
336
|
+
displayName: string;
|
|
337
|
+
department: string | null;
|
|
338
|
+
title: string | null;
|
|
339
|
+
levelLabel: string | null;
|
|
340
|
+
weeklyCapacityHours: number | null;
|
|
121
341
|
status: string;
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
342
|
+
joinedAt: string | null;
|
|
343
|
+
leftAt: string | null;
|
|
344
|
+
notes: string | null;
|
|
345
|
+
supervisorId: number | null;
|
|
346
|
+
supervisorName: string | null;
|
|
347
|
+
contractId: number | null;
|
|
348
|
+
contractStatus: string | null;
|
|
349
|
+
activeAssignments: number;
|
|
350
|
+
}>;
|
|
351
|
+
listProjects(userId: number): Promise<Record<string, unknown>[]>;
|
|
352
|
+
getProjectById(userId: number, projectId: number): Promise<{
|
|
353
|
+
assignments: {
|
|
354
|
+
id: number;
|
|
355
|
+
collaboratorId: number;
|
|
356
|
+
collaboratorName: string;
|
|
357
|
+
roleLabel: string | null;
|
|
358
|
+
allocationPercent: number | null;
|
|
359
|
+
weeklyHours: number | null;
|
|
360
|
+
isBillable: boolean;
|
|
361
|
+
startDate: string | null;
|
|
362
|
+
endDate: string | null;
|
|
363
|
+
status: string;
|
|
364
|
+
}[];
|
|
365
|
+
relatedContract: any;
|
|
366
|
+
timesheetSummary: {
|
|
367
|
+
totalTimesheets: number;
|
|
368
|
+
pendingTimesheets: number;
|
|
369
|
+
totalHours: number;
|
|
370
|
+
};
|
|
371
|
+
operationalIndicators: {
|
|
372
|
+
activeAssignments: number;
|
|
373
|
+
billableAssignments: number;
|
|
374
|
+
averageAllocation: number;
|
|
375
|
+
totalWeeklyHours: number;
|
|
376
|
+
};
|
|
130
377
|
id: number;
|
|
131
|
-
|
|
378
|
+
contractId: number | null;
|
|
379
|
+
managerCollaboratorId: number | null;
|
|
380
|
+
code: string;
|
|
381
|
+
name: string;
|
|
382
|
+
clientName: string | null;
|
|
383
|
+
summary: string | null;
|
|
132
384
|
status: string;
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
385
|
+
progressPercent: number | null;
|
|
386
|
+
deliveryModel: string | null;
|
|
387
|
+
budgetAmount: number | null;
|
|
388
|
+
startDate: string | null;
|
|
389
|
+
endDate: string | null;
|
|
390
|
+
contractName: string | null;
|
|
391
|
+
contractStatus: string | null;
|
|
392
|
+
contractCategory: string | null;
|
|
393
|
+
managerName: string | null;
|
|
394
|
+
myAssignmentId: number | null;
|
|
395
|
+
myRoleLabel: string | null;
|
|
396
|
+
teamSize: number;
|
|
397
|
+
}>;
|
|
398
|
+
createProject(userId: number, data: ProjectPayload): Promise<{
|
|
399
|
+
assignments: {
|
|
400
|
+
id: number;
|
|
401
|
+
collaboratorId: number;
|
|
402
|
+
collaboratorName: string;
|
|
403
|
+
roleLabel: string | null;
|
|
404
|
+
allocationPercent: number | null;
|
|
405
|
+
weeklyHours: number | null;
|
|
406
|
+
isBillable: boolean;
|
|
407
|
+
startDate: string | null;
|
|
408
|
+
endDate: string | null;
|
|
409
|
+
status: string;
|
|
410
|
+
}[];
|
|
411
|
+
relatedContract: any;
|
|
412
|
+
timesheetSummary: {
|
|
413
|
+
totalTimesheets: number;
|
|
414
|
+
pendingTimesheets: number;
|
|
415
|
+
totalHours: number;
|
|
416
|
+
};
|
|
417
|
+
operationalIndicators: {
|
|
418
|
+
activeAssignments: number;
|
|
419
|
+
billableAssignments: number;
|
|
420
|
+
averageAllocation: number;
|
|
421
|
+
totalWeeklyHours: number;
|
|
422
|
+
};
|
|
140
423
|
id: number;
|
|
141
|
-
|
|
142
|
-
|
|
424
|
+
contractId: number | null;
|
|
425
|
+
managerCollaboratorId: number | null;
|
|
426
|
+
code: string;
|
|
427
|
+
name: string;
|
|
428
|
+
clientName: string | null;
|
|
429
|
+
summary: string | null;
|
|
143
430
|
status: string;
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
431
|
+
progressPercent: number | null;
|
|
432
|
+
deliveryModel: string | null;
|
|
433
|
+
budgetAmount: number | null;
|
|
434
|
+
startDate: string | null;
|
|
435
|
+
endDate: string | null;
|
|
436
|
+
contractName: string | null;
|
|
437
|
+
contractStatus: string | null;
|
|
438
|
+
contractCategory: string | null;
|
|
439
|
+
managerName: string | null;
|
|
440
|
+
myAssignmentId: number | null;
|
|
441
|
+
myRoleLabel: string | null;
|
|
442
|
+
teamSize: number;
|
|
443
|
+
}>;
|
|
444
|
+
updateProject(userId: number, projectId: number, data: Partial<ProjectPayload>): Promise<{
|
|
445
|
+
assignments: {
|
|
446
|
+
id: number;
|
|
447
|
+
collaboratorId: number;
|
|
448
|
+
collaboratorName: string;
|
|
449
|
+
roleLabel: string | null;
|
|
450
|
+
allocationPercent: number | null;
|
|
451
|
+
weeklyHours: number | null;
|
|
452
|
+
isBillable: boolean;
|
|
453
|
+
startDate: string | null;
|
|
454
|
+
endDate: string | null;
|
|
455
|
+
status: string;
|
|
456
|
+
}[];
|
|
457
|
+
relatedContract: any;
|
|
458
|
+
timesheetSummary: {
|
|
459
|
+
totalTimesheets: number;
|
|
460
|
+
pendingTimesheets: number;
|
|
461
|
+
totalHours: number;
|
|
462
|
+
};
|
|
463
|
+
operationalIndicators: {
|
|
464
|
+
activeAssignments: number;
|
|
465
|
+
billableAssignments: number;
|
|
466
|
+
averageAllocation: number;
|
|
467
|
+
totalWeeklyHours: number;
|
|
468
|
+
};
|
|
147
469
|
id: number;
|
|
148
|
-
|
|
149
|
-
|
|
470
|
+
contractId: number | null;
|
|
471
|
+
managerCollaboratorId: number | null;
|
|
472
|
+
code: string;
|
|
473
|
+
name: string;
|
|
474
|
+
clientName: string | null;
|
|
475
|
+
summary: string | null;
|
|
150
476
|
status: string;
|
|
151
|
-
progressPercent: number;
|
|
152
|
-
|
|
153
|
-
|
|
477
|
+
progressPercent: number | null;
|
|
478
|
+
deliveryModel: string | null;
|
|
479
|
+
budgetAmount: number | null;
|
|
480
|
+
startDate: string | null;
|
|
481
|
+
endDate: string | null;
|
|
482
|
+
contractName: string | null;
|
|
483
|
+
contractStatus: string | null;
|
|
484
|
+
contractCategory: string | null;
|
|
485
|
+
managerName: string | null;
|
|
486
|
+
myAssignmentId: number | null;
|
|
487
|
+
myRoleLabel: string | null;
|
|
488
|
+
teamSize: number;
|
|
489
|
+
}>;
|
|
490
|
+
listContracts(userId: number): Promise<Record<string, unknown>[]>;
|
|
491
|
+
getContractById(userId: number, contractId: number): Promise<{
|
|
492
|
+
mainRelatedPartyName: unknown;
|
|
493
|
+
projects: Record<string, unknown>[];
|
|
494
|
+
scheduleSummary: any[];
|
|
495
|
+
parties: Record<string, unknown>[];
|
|
496
|
+
signatures: Record<string, unknown>[];
|
|
497
|
+
financialTerms: Record<string, unknown>[];
|
|
498
|
+
documents: Record<string, unknown>[];
|
|
499
|
+
revisions: Record<string, unknown>[];
|
|
500
|
+
history: Record<string, unknown>[];
|
|
501
|
+
}>;
|
|
502
|
+
createContract(userId: number, data: ContractPayload): Promise<{
|
|
503
|
+
mainRelatedPartyName: unknown;
|
|
504
|
+
projects: Record<string, unknown>[];
|
|
505
|
+
scheduleSummary: any[];
|
|
506
|
+
parties: Record<string, unknown>[];
|
|
507
|
+
signatures: Record<string, unknown>[];
|
|
508
|
+
financialTerms: Record<string, unknown>[];
|
|
509
|
+
documents: Record<string, unknown>[];
|
|
510
|
+
revisions: Record<string, unknown>[];
|
|
511
|
+
history: Record<string, unknown>[];
|
|
512
|
+
}>;
|
|
513
|
+
updateContract(userId: number, contractId: number, data: Partial<ContractPayload>): Promise<{
|
|
514
|
+
mainRelatedPartyName: unknown;
|
|
515
|
+
projects: Record<string, unknown>[];
|
|
516
|
+
scheduleSummary: any[];
|
|
517
|
+
parties: Record<string, unknown>[];
|
|
518
|
+
signatures: Record<string, unknown>[];
|
|
519
|
+
financialTerms: Record<string, unknown>[];
|
|
520
|
+
documents: Record<string, unknown>[];
|
|
521
|
+
revisions: Record<string, unknown>[];
|
|
522
|
+
history: Record<string, unknown>[];
|
|
523
|
+
}>;
|
|
524
|
+
listTimesheets(userId: number): Promise<{
|
|
154
525
|
id: number;
|
|
155
|
-
|
|
526
|
+
collaboratorId: number;
|
|
527
|
+
collaboratorName: string;
|
|
528
|
+
approverCollaboratorId: number | null;
|
|
529
|
+
approverName: string | null;
|
|
530
|
+
weekStartDate: string;
|
|
531
|
+
weekEndDate: string;
|
|
532
|
+
totalHours: number | null;
|
|
156
533
|
status: string;
|
|
157
|
-
|
|
158
|
-
|
|
534
|
+
submittedAt: string | null;
|
|
535
|
+
reviewedAt: string | null;
|
|
536
|
+
notes: string | null;
|
|
537
|
+
decisionNote: string | null;
|
|
538
|
+
}[]>;
|
|
539
|
+
createTimesheet(userId: number, data: TimesheetPayload): Promise<any>;
|
|
540
|
+
updateTimesheet(userId: number, timesheetId: number, data: Partial<TimesheetPayload>): Promise<any>;
|
|
541
|
+
submitTimesheet(userId: number, timesheetId: number): Promise<any>;
|
|
542
|
+
listTimeOffRequests(userId: number): Promise<Record<string, unknown>[]>;
|
|
543
|
+
createTimeOffRequest(userId: number, data: TimeOffPayload): Promise<Record<string, unknown>>;
|
|
544
|
+
listScheduleAdjustments(userId: number): Promise<{
|
|
159
545
|
id: number;
|
|
160
|
-
|
|
161
|
-
|
|
546
|
+
collaboratorId: number;
|
|
547
|
+
collaboratorName: string;
|
|
548
|
+
approverCollaboratorId: number | null;
|
|
549
|
+
approverName: string | null;
|
|
550
|
+
requestScope: string;
|
|
551
|
+
effectiveStartDate: string;
|
|
552
|
+
effectiveEndDate: string | null;
|
|
162
553
|
status: string;
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
554
|
+
reason: string | null;
|
|
555
|
+
submittedAt: string | null;
|
|
556
|
+
reviewedAt: string | null;
|
|
557
|
+
approverNote: string | null;
|
|
558
|
+
}[]>;
|
|
559
|
+
createScheduleAdjustmentRequest(userId: number, data: ScheduleAdjustmentPayload): Promise<Record<string, unknown>>;
|
|
560
|
+
listApprovals(userId: number): Promise<Record<string, unknown>[]>;
|
|
561
|
+
approve(userId: number, approvalId: number, data: DecisionPayload): Promise<Record<string, unknown>>;
|
|
562
|
+
reject(userId: number, approvalId: number, data: DecisionPayload): Promise<Record<string, unknown>>;
|
|
563
|
+
publishAccountsPayableReference(userId: number, data: PublishAccountsPayableReferencePayload): Promise<{
|
|
564
|
+
queued: boolean;
|
|
565
|
+
eventId: string;
|
|
566
|
+
eventName: string;
|
|
567
|
+
sourceEntityType: string;
|
|
568
|
+
sourceEntityId: string;
|
|
569
|
+
}>;
|
|
570
|
+
private decideApproval;
|
|
571
|
+
private getActorContext;
|
|
572
|
+
private getCollaboratorByUserId;
|
|
573
|
+
private getCollaboratorById;
|
|
574
|
+
private getProjectDetails;
|
|
575
|
+
private getCollaboratorDetails;
|
|
576
|
+
private getDirectReportIds;
|
|
577
|
+
private getAssignedProjectIds;
|
|
578
|
+
private getTimesheetById;
|
|
579
|
+
private replaceTimesheetEntries;
|
|
580
|
+
private refreshTimesheetTotal;
|
|
581
|
+
private upsertApproval;
|
|
582
|
+
private insertApprovalHistory;
|
|
583
|
+
private assertProjectAccess;
|
|
584
|
+
private ensureCollaboratorAccess;
|
|
585
|
+
private listSingleTimesheet;
|
|
586
|
+
private ensureDirector;
|
|
587
|
+
private ensureSupervisor;
|
|
588
|
+
private ensureCollaborator;
|
|
589
|
+
private defaultWeeklySchedule;
|
|
590
|
+
private replaceCollaboratorScheduleDays;
|
|
591
|
+
private replaceProjectAssignments;
|
|
592
|
+
private mapContractCategoryForCollaboratorType;
|
|
593
|
+
private mapBillingModelForCollaboratorType;
|
|
594
|
+
private mapContractTypeForCollaboratorType;
|
|
595
|
+
private createHiringContractDraft;
|
|
596
|
+
private createProjectContractDraft;
|
|
597
|
+
private replaceContractParties;
|
|
598
|
+
private replaceContractSignatures;
|
|
599
|
+
private replaceContractFinancialTerms;
|
|
600
|
+
private replaceContractRevisions;
|
|
601
|
+
private replaceContractPdfDocument;
|
|
602
|
+
private insertContractHistory;
|
|
603
|
+
private requireFields;
|
|
604
|
+
private buildIdFilter;
|
|
605
|
+
private uniqueNumbers;
|
|
606
|
+
private pushUpdate;
|
|
607
|
+
private param;
|
|
608
|
+
private groupBy;
|
|
609
|
+
private queryRows;
|
|
610
|
+
private querySingle;
|
|
611
|
+
private execute;
|
|
177
612
|
}
|
|
613
|
+
export {};
|
|
178
614
|
//# sourceMappingURL=operations.service.d.ts.map
|