@lilaquadrat/interfaces 1.51.1 → 1.54.0
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/CHANGELOG.md +28 -0
- package/lib/cjs/CustomersModelActions.d.ts +1 -1
- package/lib/cjs/EmployeeAbsence.d.ts +10 -0
- package/lib/cjs/EmployeeAbsenceFilters.d.ts +5 -0
- package/lib/cjs/EmployeeAbsenceInput.d.ts +2 -0
- package/lib/cjs/History.d.ts +1 -0
- package/lib/cjs/HistoryChange.d.ts +12 -0
- package/lib/cjs/HistorySeen.d.ts +15 -0
- package/lib/cjs/List.d.ts +5 -0
- package/lib/cjs/ListCategory.d.ts +6 -0
- package/lib/cjs/ListParticipantMatch.d.ts +12 -0
- package/lib/cjs/ListParticipantWithUser.d.ts +4 -1
- package/lib/cjs/ListParticipants.d.ts +5 -1
- package/lib/cjs/MemberProfileUpdate.d.ts +2 -0
- package/lib/cjs/MemberShift.d.ts +21 -0
- package/lib/cjs/MemberShiftFilters.d.ts +5 -0
- package/lib/cjs/PaymentProviderProduct.d.ts +20 -0
- package/lib/cjs/Shift.d.ts +19 -0
- package/lib/cjs/ShiftAssignment.d.ts +7 -0
- package/lib/cjs/ShiftAssignmentBreak.d.ts +4 -0
- package/lib/cjs/ShiftAssignmentInput.d.ts +6 -0
- package/lib/cjs/ShiftAssignmentsInput.d.ts +4 -0
- package/lib/cjs/ShiftCreateInput.d.ts +5 -0
- package/lib/cjs/ShiftInput.d.ts +12 -0
- package/lib/cjs/ShiftParticipant.d.ts +14 -0
- package/lib/cjs/ShiftPlan.d.ts +20 -0
- package/lib/cjs/ShiftPlanArea.d.ts +5 -0
- package/lib/cjs/ShiftPlanChangeInput.d.ts +14 -0
- package/lib/cjs/ShiftPlanCreateInput.d.ts +14 -0
- package/lib/cjs/ShiftPlanDay.d.ts +11 -0
- package/lib/cjs/ShiftPlanDayInput.d.ts +6 -0
- package/lib/cjs/ShiftPlanFilters.d.ts +9 -0
- package/lib/cjs/ShiftPlanResponse.d.ts +14 -0
- package/lib/cjs/ShiftPlanWorkArea.d.ts +6 -0
- package/lib/cjs/ShiftPlanWorkHours.d.ts +5 -0
- package/lib/cjs/ShiftPlanningCompanyOptions.d.ts +2 -0
- package/lib/cjs/ShiftPlanningFilters.d.ts +7 -0
- package/lib/cjs/ShiftPlanningPage.d.ts +7 -0
- package/lib/cjs/ShiftPlanningPolicy.d.ts +32 -0
- package/lib/cjs/ShiftPlanningPolicyOverrides.d.ts +2 -0
- package/lib/cjs/ShiftPlanningProjectOptions.d.ts +2 -0
- package/lib/cjs/ShiftPlanningSettings.d.ts +8 -0
- package/lib/cjs/ShiftPlanningSettingsInput.d.ts +4 -0
- package/lib/cjs/ShiftPlanningViolation.d.ts +7 -0
- package/lib/cjs/ShiftReportContext.d.ts +18 -0
- package/lib/cjs/ShiftResponse.d.ts +10 -0
- package/lib/cjs/ShiftWorkingTime.d.ts +6 -0
- package/lib/cjs/StructureCondition.d.ts +11 -0
- package/lib/cjs/StructureConditionConstraint.d.ts +1 -0
- package/lib/cjs/StructureConditionGrade.d.ts +1 -0
- package/lib/cjs/StructureConditionOperator.d.ts +1 -0
- package/lib/cjs/StructureConditionType.d.ts +1 -0
- package/lib/cjs/StructureMatchState.d.ts +1 -0
- package/lib/cjs/WithStructures.d.ts +2 -1
- package/lib/cjs/WorkArea.d.ts +14 -0
- package/lib/cjs/WorkAreaFilters.d.ts +4 -0
- package/lib/cjs/WorkAreaInput.d.ts +2 -0
- package/lib/cjs/index.d.ts +49 -0
- package/lib/esm/CustomersModelActions.d.ts +1 -1
- package/lib/esm/EmployeeAbsence.d.ts +10 -0
- package/lib/esm/EmployeeAbsence.js +2 -0
- package/lib/esm/EmployeeAbsence.js.map +1 -0
- package/lib/esm/EmployeeAbsenceFilters.d.ts +5 -0
- package/lib/esm/EmployeeAbsenceFilters.js +2 -0
- package/lib/esm/EmployeeAbsenceFilters.js.map +1 -0
- package/lib/esm/EmployeeAbsenceInput.d.ts +2 -0
- package/lib/esm/EmployeeAbsenceInput.js +2 -0
- package/lib/esm/EmployeeAbsenceInput.js.map +1 -0
- package/lib/esm/History.d.ts +1 -0
- package/lib/esm/HistoryChange.d.ts +12 -0
- package/lib/esm/HistoryChange.js +2 -0
- package/lib/esm/HistoryChange.js.map +1 -0
- package/lib/esm/HistorySeen.d.ts +15 -0
- package/lib/esm/HistorySeen.js +2 -0
- package/lib/esm/HistorySeen.js.map +1 -0
- package/lib/esm/List.d.ts +5 -0
- package/lib/esm/ListCategory.d.ts +6 -0
- package/lib/esm/ListParticipantMatch.d.ts +12 -0
- package/lib/esm/ListParticipantMatch.js +2 -0
- package/lib/esm/ListParticipantMatch.js.map +1 -0
- package/lib/esm/ListParticipantWithUser.d.ts +4 -1
- package/lib/esm/ListParticipants.d.ts +5 -1
- package/lib/esm/MemberProfileUpdate.d.ts +2 -0
- package/lib/esm/MemberProfileUpdate.js +2 -0
- package/lib/esm/MemberProfileUpdate.js.map +1 -0
- package/lib/esm/MemberShift.d.ts +21 -0
- package/lib/esm/MemberShift.js +2 -0
- package/lib/esm/MemberShift.js.map +1 -0
- package/lib/esm/MemberShiftFilters.d.ts +5 -0
- package/lib/esm/MemberShiftFilters.js +2 -0
- package/lib/esm/MemberShiftFilters.js.map +1 -0
- package/lib/esm/PaymentProviderProduct.d.ts +20 -0
- package/lib/esm/PaymentProviderProduct.js +2 -0
- package/lib/esm/PaymentProviderProduct.js.map +1 -0
- package/lib/esm/Shift.d.ts +19 -0
- package/lib/esm/Shift.js +2 -0
- package/lib/esm/Shift.js.map +1 -0
- package/lib/esm/ShiftAssignment.d.ts +7 -0
- package/lib/esm/ShiftAssignment.js +2 -0
- package/lib/esm/ShiftAssignment.js.map +1 -0
- package/lib/esm/ShiftAssignmentBreak.d.ts +4 -0
- package/lib/esm/ShiftAssignmentBreak.js +2 -0
- package/lib/esm/ShiftAssignmentBreak.js.map +1 -0
- package/lib/esm/ShiftAssignmentInput.d.ts +6 -0
- package/lib/esm/ShiftAssignmentInput.js +2 -0
- package/lib/esm/ShiftAssignmentInput.js.map +1 -0
- package/lib/esm/ShiftAssignmentsInput.d.ts +4 -0
- package/lib/esm/ShiftAssignmentsInput.js +2 -0
- package/lib/esm/ShiftAssignmentsInput.js.map +1 -0
- package/lib/esm/ShiftCreateInput.d.ts +5 -0
- package/lib/esm/ShiftCreateInput.js +2 -0
- package/lib/esm/ShiftCreateInput.js.map +1 -0
- package/lib/esm/ShiftInput.d.ts +12 -0
- package/lib/esm/ShiftInput.js +2 -0
- package/lib/esm/ShiftInput.js.map +1 -0
- package/lib/esm/ShiftParticipant.d.ts +14 -0
- package/lib/esm/ShiftParticipant.js +2 -0
- package/lib/esm/ShiftParticipant.js.map +1 -0
- package/lib/esm/ShiftPlan.d.ts +20 -0
- package/lib/esm/ShiftPlan.js +2 -0
- package/lib/esm/ShiftPlan.js.map +1 -0
- package/lib/esm/ShiftPlanArea.d.ts +5 -0
- package/lib/esm/ShiftPlanArea.js +2 -0
- package/lib/esm/ShiftPlanArea.js.map +1 -0
- package/lib/esm/ShiftPlanChangeInput.d.ts +14 -0
- package/lib/esm/ShiftPlanChangeInput.js +2 -0
- package/lib/esm/ShiftPlanChangeInput.js.map +1 -0
- package/lib/esm/ShiftPlanCreateInput.d.ts +14 -0
- package/lib/esm/ShiftPlanCreateInput.js +2 -0
- package/lib/esm/ShiftPlanCreateInput.js.map +1 -0
- package/lib/esm/ShiftPlanDay.d.ts +11 -0
- package/lib/esm/ShiftPlanDay.js +2 -0
- package/lib/esm/ShiftPlanDay.js.map +1 -0
- package/lib/esm/ShiftPlanDayInput.d.ts +6 -0
- package/lib/esm/ShiftPlanDayInput.js +2 -0
- package/lib/esm/ShiftPlanDayInput.js.map +1 -0
- package/lib/esm/ShiftPlanFilters.d.ts +9 -0
- package/lib/esm/ShiftPlanFilters.js +2 -0
- package/lib/esm/ShiftPlanFilters.js.map +1 -0
- package/lib/esm/ShiftPlanResponse.d.ts +14 -0
- package/lib/esm/ShiftPlanResponse.js +2 -0
- package/lib/esm/ShiftPlanResponse.js.map +1 -0
- package/lib/esm/ShiftPlanWorkArea.d.ts +6 -0
- package/lib/esm/ShiftPlanWorkArea.js +2 -0
- package/lib/esm/ShiftPlanWorkArea.js.map +1 -0
- package/lib/esm/ShiftPlanWorkHours.d.ts +5 -0
- package/lib/esm/ShiftPlanWorkHours.js +2 -0
- package/lib/esm/ShiftPlanWorkHours.js.map +1 -0
- package/lib/esm/ShiftPlanningCompanyOptions.d.ts +2 -0
- package/lib/esm/ShiftPlanningCompanyOptions.js +2 -0
- package/lib/esm/ShiftPlanningCompanyOptions.js.map +1 -0
- package/lib/esm/ShiftPlanningFilters.d.ts +7 -0
- package/lib/esm/ShiftPlanningFilters.js +2 -0
- package/lib/esm/ShiftPlanningFilters.js.map +1 -0
- package/lib/esm/ShiftPlanningPage.d.ts +7 -0
- package/lib/esm/ShiftPlanningPage.js +2 -0
- package/lib/esm/ShiftPlanningPage.js.map +1 -0
- package/lib/esm/ShiftPlanningPolicy.d.ts +32 -0
- package/lib/esm/ShiftPlanningPolicy.js +2 -0
- package/lib/esm/ShiftPlanningPolicy.js.map +1 -0
- package/lib/esm/ShiftPlanningPolicyOverrides.d.ts +2 -0
- package/lib/esm/ShiftPlanningPolicyOverrides.js +2 -0
- package/lib/esm/ShiftPlanningPolicyOverrides.js.map +1 -0
- package/lib/esm/ShiftPlanningProjectOptions.d.ts +2 -0
- package/lib/esm/ShiftPlanningProjectOptions.js +2 -0
- package/lib/esm/ShiftPlanningProjectOptions.js.map +1 -0
- package/lib/esm/ShiftPlanningSettings.d.ts +8 -0
- package/lib/esm/ShiftPlanningSettings.js +2 -0
- package/lib/esm/ShiftPlanningSettings.js.map +1 -0
- package/lib/esm/ShiftPlanningSettingsInput.d.ts +4 -0
- package/lib/esm/ShiftPlanningSettingsInput.js +2 -0
- package/lib/esm/ShiftPlanningSettingsInput.js.map +1 -0
- package/lib/esm/ShiftPlanningViolation.d.ts +7 -0
- package/lib/esm/ShiftPlanningViolation.js +2 -0
- package/lib/esm/ShiftPlanningViolation.js.map +1 -0
- package/lib/esm/ShiftReportContext.d.ts +18 -0
- package/lib/esm/ShiftReportContext.js +2 -0
- package/lib/esm/ShiftReportContext.js.map +1 -0
- package/lib/esm/ShiftResponse.d.ts +10 -0
- package/lib/esm/ShiftResponse.js +2 -0
- package/lib/esm/ShiftResponse.js.map +1 -0
- package/lib/esm/ShiftWorkingTime.d.ts +6 -0
- package/lib/esm/ShiftWorkingTime.js +2 -0
- package/lib/esm/ShiftWorkingTime.js.map +1 -0
- package/lib/esm/StructureCondition.d.ts +11 -0
- package/lib/esm/StructureCondition.js +2 -0
- package/lib/esm/StructureCondition.js.map +1 -0
- package/lib/esm/StructureConditionConstraint.d.ts +1 -0
- package/lib/esm/StructureConditionConstraint.js +2 -0
- package/lib/esm/StructureConditionConstraint.js.map +1 -0
- package/lib/esm/StructureConditionGrade.d.ts +1 -0
- package/lib/esm/StructureConditionGrade.js +2 -0
- package/lib/esm/StructureConditionGrade.js.map +1 -0
- package/lib/esm/StructureConditionOperator.d.ts +1 -0
- package/lib/esm/StructureConditionOperator.js +2 -0
- package/lib/esm/StructureConditionOperator.js.map +1 -0
- package/lib/esm/StructureConditionType.d.ts +1 -0
- package/lib/esm/StructureConditionType.js +2 -0
- package/lib/esm/StructureConditionType.js.map +1 -0
- package/lib/esm/StructureMatchState.d.ts +1 -0
- package/lib/esm/StructureMatchState.js +2 -0
- package/lib/esm/StructureMatchState.js.map +1 -0
- package/lib/esm/WithStructures.d.ts +2 -1
- package/lib/esm/WorkArea.d.ts +14 -0
- package/lib/esm/WorkArea.js +2 -0
- package/lib/esm/WorkArea.js.map +1 -0
- package/lib/esm/WorkAreaFilters.d.ts +4 -0
- package/lib/esm/WorkAreaFilters.js +2 -0
- package/lib/esm/WorkAreaFilters.js.map +1 -0
- package/lib/esm/WorkAreaInput.d.ts +2 -0
- package/lib/esm/WorkAreaInput.js +2 -0
- package/lib/esm/WorkAreaInput.js.map +1 -0
- package/lib/esm/index.d.ts +49 -0
- package/package.json +1 -1
- package/src/CustomersModelActions.ts +2 -1
- package/src/EmployeeAbsence.ts +11 -0
- package/src/EmployeeAbsenceFilters.ts +6 -0
- package/src/EmployeeAbsenceInput.ts +3 -0
- package/src/History.ts +2 -1
- package/src/HistoryChange.ts +16 -0
- package/src/HistorySeen.ts +16 -0
- package/src/List.ts +5 -0
- package/src/ListCategory.ts +6 -0
- package/src/ListParticipantMatch.ts +13 -0
- package/src/ListParticipantWithUser.ts +4 -1
- package/src/ListParticipants.ts +5 -1
- package/src/MemberProfileUpdate.ts +6 -0
- package/src/MemberShift.ts +15 -0
- package/src/MemberShiftFilters.ts +6 -0
- package/src/PaymentProviderProduct.ts +25 -0
- package/src/Shift.ts +20 -0
- package/src/ShiftAssignment.ts +8 -0
- package/src/ShiftAssignmentBreak.ts +4 -0
- package/src/ShiftAssignmentInput.ts +7 -0
- package/src/ShiftAssignmentsInput.ts +5 -0
- package/src/ShiftCreateInput.ts +6 -0
- package/src/ShiftInput.ts +13 -0
- package/src/ShiftParticipant.ts +15 -0
- package/src/ShiftPlan.ts +21 -0
- package/src/ShiftPlanArea.ts +6 -0
- package/src/ShiftPlanChangeInput.ts +15 -0
- package/src/ShiftPlanCreateInput.ts +15 -0
- package/src/ShiftPlanDay.ts +12 -0
- package/src/ShiftPlanDayInput.ts +7 -0
- package/src/ShiftPlanFilters.ts +10 -0
- package/src/ShiftPlanResponse.ts +15 -0
- package/src/ShiftPlanWorkArea.ts +7 -0
- package/src/ShiftPlanWorkHours.ts +5 -0
- package/src/ShiftPlanningCompanyOptions.ts +3 -0
- package/src/ShiftPlanningFilters.ts +8 -0
- package/src/ShiftPlanningPage.ts +8 -0
- package/src/ShiftPlanningPolicy.ts +14 -0
- package/src/ShiftPlanningPolicyOverrides.ts +4 -0
- package/src/ShiftPlanningProjectOptions.ts +3 -0
- package/src/ShiftPlanningSettings.ts +9 -0
- package/src/ShiftPlanningSettingsInput.ts +5 -0
- package/src/ShiftPlanningViolation.ts +7 -0
- package/src/ShiftReportContext.ts +19 -0
- package/src/ShiftResponse.ts +11 -0
- package/src/ShiftWorkingTime.ts +6 -0
- package/src/StructureCondition.ts +12 -0
- package/src/StructureConditionConstraint.ts +1 -0
- package/src/StructureConditionGrade.ts +1 -0
- package/src/StructureConditionOperator.ts +1 -0
- package/src/StructureConditionType.ts +1 -0
- package/src/StructureMatchState.ts +1 -0
- package/src/WithStructures.ts +2 -1
- package/src/WorkArea.ts +15 -0
- package/src/WorkAreaFilters.ts +4 -0
- package/src/WorkAreaInput.ts +3 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,34 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
## [1.54.0](https://github.com/lilaquadrat/interfaces/compare/v1.53.1...v1.54.0) (2026-10-13)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* **Customers:** allow the changeStructures action ([177207a](https://github.com/lilaquadrat/interfaces/commit/177207ae117723909003f58e60defedd4f5f192f))
|
|
11
|
+
* **History:** add history seen marker and change types ([6b1d09c](https://github.com/lilaquadrat/interfaces/commit/6b1d09c7732c87fcbc61980d2442790d401078cd))
|
|
12
|
+
* **PaymentProvider:** add provider product and category external product flag ([1fae4e7](https://github.com/lilaquadrat/interfaces/commit/1fae4e74fb6a19fb3e1c5bdb03360cec193c7ae9))
|
|
13
|
+
* **Shift:** add shift planning and employee absence interfaces ([cfb61fd](https://github.com/lilaquadrat/interfaces/commit/cfb61fd8ed304da93b7109a225f8e31ab8f2248e))
|
|
14
|
+
* **Shift:** rework planning around work areas, plan days and structure conditions ([90668de](https://github.com/lilaquadrat/interfaces/commit/90668deef55b64a0ee81c9d0129b939248b7fc23))
|
|
15
|
+
|
|
16
|
+
### [1.53.1](https://github.com/lilaquadrat/interfaces/compare/v1.53.0...v1.53.1) (2026-10-04)
|
|
17
|
+
|
|
18
|
+
## [1.53.0](https://github.com/lilaquadrat/interfaces/compare/v1.52.0...v1.53.0) (2026-10-02)
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
### Features
|
|
22
|
+
|
|
23
|
+
* **List:** add opt-in participants.selfService flag ([84cfc4b](https://github.com/lilaquadrat/interfaces/commit/84cfc4b764c80f27712649d80b53eb5c223b205d))
|
|
24
|
+
|
|
25
|
+
## [1.52.0](https://github.com/lilaquadrat/interfaces/compare/v1.51.1...v1.52.0) (2026-10-02)
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
### Features
|
|
29
|
+
|
|
30
|
+
* **customers:** add member profile update type and history origin ([7b4cae2](https://github.com/lilaquadrat/interfaces/commit/7b4cae203862369a8a1a7a53ba105bc6ab74af42))
|
|
31
|
+
* **ListParticipants:** add canceled state for member withdrawals ([a684c8f](https://github.com/lilaquadrat/interfaces/commit/a684c8fde6d30b02242de50be74221d577f24e2a))
|
|
32
|
+
|
|
5
33
|
### [1.51.1](https://github.com/lilaquadrat/interfaces/compare/v1.51.0...v1.51.1) (2026-10-01)
|
|
6
34
|
|
|
7
35
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type CustomersModelActions = 'createPersonMinimal' | 'createPersonExternal' | 'createPersonExternalWithAddress' | 'createCompanyMinimal' | 'changePersonMinimal' | 'changeCompanyMinimal' | 'connectPersonAccount' | 'disconnectPersonAccount' | 'confirmEmail' | 'setEmailConfirmationCode';
|
|
1
|
+
export type CustomersModelActions = 'createPersonMinimal' | 'createPersonExternal' | 'createPersonExternalWithAddress' | 'createCompanyMinimal' | 'changePersonMinimal' | 'changeCompanyMinimal' | 'connectPersonAccount' | 'disconnectPersonAccount' | 'confirmEmail' | 'setEmailConfirmationCode' | 'changeMemberProfile' | 'changeStructures';
|
package/lib/cjs/History.d.ts
CHANGED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export interface HistoryChange {
|
|
2
|
+
/**
|
|
3
|
+
* path of the changed field, nested objects are joined with a dot
|
|
4
|
+
*/
|
|
5
|
+
field: string;
|
|
6
|
+
/**
|
|
7
|
+
* human readable name of the field when the snapshot data knows it, e.g. the question of a structure
|
|
8
|
+
*/
|
|
9
|
+
label?: string;
|
|
10
|
+
from: unknown;
|
|
11
|
+
to: unknown;
|
|
12
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ObjectId } from "mongodb";
|
|
2
|
+
/**
|
|
3
|
+
* marks the newest history entry a user has seen for one scope (e.g. the participants of a single list).
|
|
4
|
+
* the number of unread entries is derived from this marker instead of being stored, so it can not go stale.
|
|
5
|
+
*/
|
|
6
|
+
export interface HistorySeen {
|
|
7
|
+
user: string;
|
|
8
|
+
company: string;
|
|
9
|
+
project?: string;
|
|
10
|
+
model: string;
|
|
11
|
+
/** identifies the watched subset of a model, e.g. the id of a list. */
|
|
12
|
+
scope: string;
|
|
13
|
+
lastSeenId: ObjectId;
|
|
14
|
+
seenAt: Date;
|
|
15
|
+
}
|
package/lib/cjs/List.d.ts
CHANGED
|
@@ -21,6 +21,11 @@ export interface List {
|
|
|
21
21
|
unique?: boolean;
|
|
22
22
|
addressRequired?: boolean;
|
|
23
23
|
totalPaid?: number;
|
|
24
|
+
/**
|
|
25
|
+
* opt-in: when true a member may edit the structure answers of, and cancel,
|
|
26
|
+
* their own list entry. absent/false means disabled.
|
|
27
|
+
*/
|
|
28
|
+
selfService?: boolean;
|
|
24
29
|
};
|
|
25
30
|
state: 'open' | 'closed' | 'waiting';
|
|
26
31
|
agreements: Agreement[];
|
|
@@ -1,11 +1,17 @@
|
|
|
1
1
|
import { ObjectId } from "mongodb";
|
|
2
2
|
import { Price } from "./Price";
|
|
3
|
+
import { PaymentProvider } from "./PaymentProvider";
|
|
3
4
|
export interface ListCategory {
|
|
4
5
|
_id: ObjectId;
|
|
5
6
|
id: string;
|
|
6
7
|
name: string;
|
|
7
8
|
description?: string;
|
|
8
9
|
externalId?: string;
|
|
10
|
+
/**
|
|
11
|
+
* request-only flag: creates the product at the given payment provider and stores
|
|
12
|
+
* its id as externalId. never persisted.
|
|
13
|
+
*/
|
|
14
|
+
createExternalProduct?: PaymentProvider['type'];
|
|
9
15
|
amount?: number;
|
|
10
16
|
disabled?: boolean;
|
|
11
17
|
price?: Price;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { StructureMatchState } from "./StructureMatchState";
|
|
2
|
+
/**
|
|
3
|
+
* How well a list participant matches a shift's structure conditions, resolved by the planning
|
|
4
|
+
* query so the candidate list can be ordered across all pages rather than just the loaded one.
|
|
5
|
+
* The state reports the hard constraints; the score grades the preferences.
|
|
6
|
+
*/
|
|
7
|
+
export interface ListParticipantMatch {
|
|
8
|
+
state: StructureMatchState;
|
|
9
|
+
score: number;
|
|
10
|
+
matched: number;
|
|
11
|
+
total: number;
|
|
12
|
+
}
|
|
@@ -2,8 +2,11 @@ import { ListParticipants } from "./ListParticipants";
|
|
|
2
2
|
import { Payment } from "./Payment";
|
|
3
3
|
import { BasicData } from "./BasicData";
|
|
4
4
|
import { CustomerMinimal } from "./CustomerMinimal";
|
|
5
|
+
import { WithStructures } from "./WithStructures";
|
|
6
|
+
import { ListParticipantMatch } from "./ListParticipantMatch";
|
|
5
7
|
export type ListParticipantWithCustomerAndPayment = BasicData<ListParticipants> & {
|
|
6
|
-
user: CustomerMinimal;
|
|
8
|
+
user: CustomerMinimal & WithStructures;
|
|
7
9
|
} & {
|
|
8
10
|
payment?: Pick<BasicData<Payment>, '_id' | 'state' | 'items' | 'provider' | 'currency' | 'amount'>;
|
|
11
|
+
match?: ListParticipantMatch;
|
|
9
12
|
};
|
|
@@ -53,8 +53,12 @@ export interface ListParticipants extends WithStructures {
|
|
|
53
53
|
```paid```
|
|
54
54
|
|
|
55
55
|
payment webhook confirmed
|
|
56
|
+
|
|
57
|
+
```canceled```
|
|
58
|
+
|
|
59
|
+
customer withdrew their own entry; the slot is freed and no email is sent
|
|
56
60
|
*/
|
|
57
|
-
state: 'unchecked' | 'paid' | 'notuseful' | 'confirmed' | 'enlisted' | 'reserved' | 'waiting' | 'blocked' | 'finalized';
|
|
61
|
+
state: 'unchecked' | 'paid' | 'notuseful' | 'confirmed' | 'enlisted' | 'reserved' | 'waiting' | 'blocked' | 'finalized' | 'canceled';
|
|
58
62
|
agreements: AgreementResponse[];
|
|
59
63
|
/**
|
|
60
64
|
* if the participants came from a payment webhook paid will have the amount of the whole payment
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { ObjectId } from 'mongodb';
|
|
2
|
+
import type { WorkArea } from './WorkArea';
|
|
3
|
+
import type { ShiftAssignmentBreak } from './ShiftAssignmentBreak';
|
|
4
|
+
export interface MemberShift {
|
|
5
|
+
_id: ObjectId;
|
|
6
|
+
day: string;
|
|
7
|
+
title: string;
|
|
8
|
+
start: string;
|
|
9
|
+
end: string;
|
|
10
|
+
plan: {
|
|
11
|
+
_id: ObjectId;
|
|
12
|
+
name: string;
|
|
13
|
+
timeZone: string;
|
|
14
|
+
};
|
|
15
|
+
list?: {
|
|
16
|
+
_id: ObjectId;
|
|
17
|
+
name: string;
|
|
18
|
+
};
|
|
19
|
+
area: Pick<WorkArea, '_id' | 'name' | 'description' | 'location' | 'address'>;
|
|
20
|
+
breaks: ShiftAssignmentBreak[];
|
|
21
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export interface PaymentProviderProduct {
|
|
2
|
+
id: string;
|
|
3
|
+
name: string;
|
|
4
|
+
description?: string;
|
|
5
|
+
/**
|
|
6
|
+
* false if the product is archived at the provider
|
|
7
|
+
*/
|
|
8
|
+
active: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* major units, like the prices stored in studio. missing if the product has no (flat) default price
|
|
11
|
+
*/
|
|
12
|
+
price?: {
|
|
13
|
+
amount: number;
|
|
14
|
+
currency: string;
|
|
15
|
+
};
|
|
16
|
+
/**
|
|
17
|
+
* link to the product in the provider's dashboard
|
|
18
|
+
*/
|
|
19
|
+
url?: string;
|
|
20
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { ObjectId } from 'mongodb';
|
|
2
|
+
import type { ShiftAssignment } from './ShiftAssignment';
|
|
3
|
+
import type { StructureCondition } from './StructureCondition';
|
|
4
|
+
export interface Shift {
|
|
5
|
+
_id?: ObjectId;
|
|
6
|
+
company: string;
|
|
7
|
+
project: string;
|
|
8
|
+
list?: ObjectId;
|
|
9
|
+
plan: ObjectId;
|
|
10
|
+
day: ObjectId;
|
|
11
|
+
area: ObjectId;
|
|
12
|
+
title: string;
|
|
13
|
+
start: string;
|
|
14
|
+
end: string;
|
|
15
|
+
structures?: StructureCondition[];
|
|
16
|
+
requiredPeople?: number;
|
|
17
|
+
matchingPeople?: number;
|
|
18
|
+
assignments: ShiftAssignment[];
|
|
19
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { ObjectId } from 'mongodb';
|
|
2
|
+
import type { StructureCondition } from './StructureCondition';
|
|
3
|
+
export interface ShiftInput {
|
|
4
|
+
day: ObjectId;
|
|
5
|
+
area: ObjectId;
|
|
6
|
+
title: string;
|
|
7
|
+
start: string;
|
|
8
|
+
end: string;
|
|
9
|
+
structures?: StructureCondition[];
|
|
10
|
+
requiredPeople?: number;
|
|
11
|
+
matchingPeople?: number;
|
|
12
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { ObjectId } from 'mongodb';
|
|
2
|
+
import type { CustomerMinimal } from './CustomerMinimal';
|
|
3
|
+
import type { WithStructures } from './WithStructures';
|
|
4
|
+
export interface ShiftParticipant extends WithStructures {
|
|
5
|
+
participant: ObjectId;
|
|
6
|
+
customer: ObjectId;
|
|
7
|
+
name: string;
|
|
8
|
+
email: string;
|
|
9
|
+
/**
|
|
10
|
+
* The assigned customer, carrying the customer's own structure answers and definitions
|
|
11
|
+
* so a shift's conditions can be evaluated client-side.
|
|
12
|
+
*/
|
|
13
|
+
user?: CustomerMinimal & WithStructures;
|
|
14
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { ObjectId } from 'mongodb';
|
|
2
|
+
import type { ShiftPlanningPolicyOverrides } from './ShiftPlanningPolicyOverrides';
|
|
3
|
+
import type { ShiftPlanWorkArea } from './ShiftPlanWorkArea';
|
|
4
|
+
import type { ShiftPlanWorkHours } from './ShiftPlanWorkHours';
|
|
5
|
+
import type { ListParticipants } from './ListParticipants';
|
|
6
|
+
export interface ShiftPlan {
|
|
7
|
+
_id?: ObjectId;
|
|
8
|
+
company: string;
|
|
9
|
+
project: string;
|
|
10
|
+
list?: ObjectId;
|
|
11
|
+
name: string;
|
|
12
|
+
timeZone: string;
|
|
13
|
+
settingsOverrides: ShiftPlanningPolicyOverrides;
|
|
14
|
+
/** One entry per work area used by the plan; binds employee-list categories to that area's shifts. */
|
|
15
|
+
workAreaCategories?: ShiftPlanWorkArea[];
|
|
16
|
+
/** Participant state the selection filter defaults to; null means no default. */
|
|
17
|
+
defaultParticipantState?: ListParticipants['state'] | null;
|
|
18
|
+
/** Visible scheduling window for each day; absent means the full day. */
|
|
19
|
+
workHours?: ShiftPlanWorkHours;
|
|
20
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { ObjectId } from 'mongodb';
|
|
2
|
+
import type { ShiftPlanningPolicyOverrides } from './ShiftPlanningPolicyOverrides';
|
|
3
|
+
import type { ShiftPlanWorkArea } from './ShiftPlanWorkArea';
|
|
4
|
+
import type { ShiftPlanWorkHours } from './ShiftPlanWorkHours';
|
|
5
|
+
import type { ListParticipants } from './ListParticipants';
|
|
6
|
+
export interface ShiftPlanChangeInput {
|
|
7
|
+
list?: ObjectId;
|
|
8
|
+
name: string;
|
|
9
|
+
timeZone: string;
|
|
10
|
+
settingsOverrides: ShiftPlanningPolicyOverrides;
|
|
11
|
+
workAreaCategories?: ShiftPlanWorkArea[];
|
|
12
|
+
defaultParticipantState?: ListParticipants['state'] | null;
|
|
13
|
+
workHours?: ShiftPlanWorkHours;
|
|
14
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { ObjectId } from 'mongodb';
|
|
2
|
+
import type { ShiftPlanningPolicyOverrides } from './ShiftPlanningPolicyOverrides';
|
|
3
|
+
import type { ShiftPlanWorkArea } from './ShiftPlanWorkArea';
|
|
4
|
+
import type { ShiftPlanWorkHours } from './ShiftPlanWorkHours';
|
|
5
|
+
import type { ListParticipants } from './ListParticipants';
|
|
6
|
+
export interface ShiftPlanCreateInput {
|
|
7
|
+
list?: ObjectId;
|
|
8
|
+
name: string;
|
|
9
|
+
timeZone: string;
|
|
10
|
+
settingsOverrides?: ShiftPlanningPolicyOverrides;
|
|
11
|
+
workAreaCategories?: ShiftPlanWorkArea[];
|
|
12
|
+
defaultParticipantState?: ListParticipants['state'] | null;
|
|
13
|
+
workHours?: ShiftPlanWorkHours;
|
|
14
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { ObjectId } from 'mongodb';
|
|
2
|
+
import type { ShiftPlanArea } from './ShiftPlanArea';
|
|
3
|
+
export interface ShiftPlanDay {
|
|
4
|
+
_id?: ObjectId;
|
|
5
|
+
company: string;
|
|
6
|
+
project: string;
|
|
7
|
+
plan: ObjectId;
|
|
8
|
+
date: string;
|
|
9
|
+
name?: string;
|
|
10
|
+
areas?: ShiftPlanArea[];
|
|
11
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { ShiftPlan } from './ShiftPlan';
|
|
2
|
+
import type { ShiftPlanDay } from './ShiftPlanDay';
|
|
3
|
+
import type { ShiftPlanningPolicy } from './ShiftPlanningPolicy';
|
|
4
|
+
import type { ShiftResponse } from './ShiftResponse';
|
|
5
|
+
import type { WorkArea } from './WorkArea';
|
|
6
|
+
import type { ListCategory } from './ListCategory';
|
|
7
|
+
export interface ShiftPlanResponse extends ShiftPlan {
|
|
8
|
+
days: ShiftPlanDay[];
|
|
9
|
+
effectiveSettings: ShiftPlanningPolicy | null;
|
|
10
|
+
workAreas: WorkArea[];
|
|
11
|
+
/** Categories of the linked employee list, for labelling the per-area category bindings. */
|
|
12
|
+
categories?: ListCategory[];
|
|
13
|
+
shifts?: ShiftResponse[];
|
|
14
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
export interface ShiftPlanningPolicy {
|
|
2
|
+
daytime: {
|
|
3
|
+
start: string;
|
|
4
|
+
end: string;
|
|
5
|
+
};
|
|
6
|
+
nighttime: {
|
|
7
|
+
start: string;
|
|
8
|
+
end: string;
|
|
9
|
+
};
|
|
10
|
+
maximumConsecutiveWorkingDays: {
|
|
11
|
+
enabled: boolean;
|
|
12
|
+
days: number;
|
|
13
|
+
};
|
|
14
|
+
maximumDailyWorkMinutes: {
|
|
15
|
+
enabled: boolean;
|
|
16
|
+
minutes: number;
|
|
17
|
+
};
|
|
18
|
+
minimumRest: {
|
|
19
|
+
enabled: boolean;
|
|
20
|
+
minutes: number;
|
|
21
|
+
};
|
|
22
|
+
breaks: {
|
|
23
|
+
enabled: boolean;
|
|
24
|
+
maximumContinuousWorkMinutes: number;
|
|
25
|
+
minimumQualifyingBreakMinutes: number;
|
|
26
|
+
requirements: Array<{
|
|
27
|
+
afterWorkMinutes: number;
|
|
28
|
+
minimumTotalBreakMinutes: number;
|
|
29
|
+
}>;
|
|
30
|
+
};
|
|
31
|
+
absenceEnforcement: boolean;
|
|
32
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { WithId } from 'mongodb';
|
|
2
|
+
import type { CustomerPerson } from './CustomerPerson';
|
|
3
|
+
import type { EmployeeAbsence } from './EmployeeAbsence';
|
|
4
|
+
import type { ListParticipantWithCustomerAndPayment } from './ListParticipantWithUser';
|
|
5
|
+
import type { ListParticipants } from './ListParticipants';
|
|
6
|
+
import type { Shift } from './Shift';
|
|
7
|
+
import type { ShiftPlan } from './ShiftPlan';
|
|
8
|
+
import type { ShiftPlanningPolicy } from './ShiftPlanningPolicy';
|
|
9
|
+
/** Diagnostic snapshots contain internal data; member responses use a separate restricted projection. */
|
|
10
|
+
export interface ShiftReportContext {
|
|
11
|
+
schedules: WithId<Shift>[];
|
|
12
|
+
plans: WithId<ShiftPlan>[];
|
|
13
|
+
settings: ShiftPlanningPolicy | undefined;
|
|
14
|
+
absences: WithId<EmployeeAbsence>[];
|
|
15
|
+
participants: WithId<ListParticipants>[];
|
|
16
|
+
participantDetails: ListParticipantWithCustomerAndPayment[];
|
|
17
|
+
customers: WithId<CustomerPerson>[];
|
|
18
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { Shift } from './Shift';
|
|
2
|
+
import type { ShiftParticipant } from './ShiftParticipant';
|
|
3
|
+
import type { ShiftPlanningViolation } from './ShiftPlanningViolation';
|
|
4
|
+
import type { ShiftWorkingTime } from './ShiftWorkingTime';
|
|
5
|
+
export interface ShiftResponse extends Shift {
|
|
6
|
+
participants: ShiftParticipant[];
|
|
7
|
+
unavailableParticipantIds: string[];
|
|
8
|
+
violations: ShiftPlanningViolation[];
|
|
9
|
+
workingTime: ShiftWorkingTime[];
|
|
10
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { StructureConditionConstraint } from './StructureConditionConstraint';
|
|
2
|
+
import type { StructureConditionGrade } from './StructureConditionGrade';
|
|
3
|
+
import type { StructureConditionOperator } from './StructureConditionOperator';
|
|
4
|
+
export interface StructureCondition {
|
|
5
|
+
structure: string;
|
|
6
|
+
constraint?: StructureConditionConstraint;
|
|
7
|
+
grade?: StructureConditionGrade;
|
|
8
|
+
/** Comparison for a `number` structure's value; ignored for other types. */
|
|
9
|
+
operator?: StructureConditionOperator;
|
|
10
|
+
value?: string | number | boolean;
|
|
11
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type StructureConditionConstraint = 'required' | 'forbidden';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type StructureConditionGrade = 'very-positive' | 'positive' | 'negative' | 'very-negative';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type StructureConditionOperator = 'lt' | 'lte' | 'eq' | 'gt' | 'gte';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type StructureConditionType = 'required' | 'forbidden' | 'very-positive' | 'positive' | 'negative' | 'very-negative';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type StructureMatchState = 'fulfilled' | 'unfit';
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
import { BasicData } from "./BasicData";
|
|
1
2
|
import { Structure } from "./Structure";
|
|
2
3
|
/**
|
|
3
4
|
* Base interface containing only the standard properties
|
|
4
5
|
*/
|
|
5
6
|
interface BaseWithStructures {
|
|
6
|
-
structures?: Structure[];
|
|
7
|
+
structures?: BasicData<Structure>[];
|
|
7
8
|
}
|
|
8
9
|
/**
|
|
9
10
|
* A utility type that can be extended by any interface to support
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { ObjectId } from 'mongodb';
|
|
2
|
+
import type { Address } from './Address';
|
|
3
|
+
import type { StructureCondition } from './StructureCondition';
|
|
4
|
+
export interface WorkArea {
|
|
5
|
+
_id: ObjectId;
|
|
6
|
+
id?: string;
|
|
7
|
+
company: string;
|
|
8
|
+
project: string;
|
|
9
|
+
name: string;
|
|
10
|
+
description?: string;
|
|
11
|
+
location?: string;
|
|
12
|
+
address?: Address;
|
|
13
|
+
structures?: StructureCondition[];
|
|
14
|
+
}
|