@feedmepos/mf-hrm-portal 2.2.5-dev.7 → 2.2.5-dev.9
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/{ApprovalCodeList-dn-WwNAd.js → ApprovalCodeList-D5l9vIsE.js} +2 -2
- package/dist/{AuditLogList-BqVp9fxD.js → AuditLogList-ByTa5UJY.js} +3 -3
- package/dist/{ConditionBuilderForm.vue_vue_type_script_setup_true_lang-DnAet2oc.js → ConditionBuilderForm.vue_vue_type_script_setup_true_lang-mNdn1TYV.js} +2 -2
- package/dist/{EmployeeList-BwTJre5k.js → EmployeeList-Bv6ANk-P.js} +8 -9
- package/dist/{GrantUserList-CZek1r4F.js → GrantUserList-Bt8w3p4j.js} +3 -3
- package/dist/{Main-MjSYZdOq.js → Main-DHJcgePj.js} +5 -5
- package/dist/{Main-CbmA-SYo.js → Main-DkP8dWgn.js} +9 -9
- package/dist/{Main-DVA51sj2.js → Main-DqiGpT4v.js} +2 -2
- package/dist/{PermissionSetList-lkHmXhNm.js → PermissionSetList-BIGv1u67.js} +10 -11
- package/dist/{PortalPermissionEditor.vue_vue_type_script_setup_true_lang-cFQDQCal.js → PortalPermissionEditor.vue_vue_type_script_setup_true_lang-niywl_DX.js} +687 -688
- package/dist/{RoleList-BSs0SmFo.js → RoleList-CH6NDKPU.js} +7 -7
- package/dist/ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-T1ACkX_6.js +426 -0
- package/dist/ScheduleButton.vue_vue_type_script_setup_true_lang-BzQuLLf5.js +690 -0
- package/dist/ScheduleGeneralPage-DJPENJZ2.js +320 -0
- package/dist/SchedulePage-C1egcbIC.js +14421 -0
- package/dist/SchedulePositionPage-OhL_hsqG.js +293 -0
- package/dist/ScheduleSelect.vue_vue_type_script_setup_true_lang-B8W4sTsA.js +242 -0
- package/dist/{TeamMemberList-Dit_nV6d.js → TeamMemberList-BwfG3go2.js} +8 -9
- package/dist/{TimesheetList-B-FlRO7E.js → TimesheetList-DcoqzbLO.js} +5 -5
- package/dist/{TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-DZUJR8K_.js → TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-RyhiKTSd.js} +2 -2
- package/dist/{app-BpnOPodL.js → app-BcZ6C8M8.js} +8 -8
- package/dist/app.js +1 -1
- package/dist/{dayjs.min-4GLfSOGZ.js → dayjs.min-Ch0iysTG.js} +1 -1
- package/dist/employee-DwYHFacQ.js +204 -0
- package/dist/{index-DYoVJQTd.js → iteration-D1uWLp0V.js} +726 -698
- package/dist/{lodash-CcFIMCiJ.js → lodash-DErxm7xf.js} +1 -1
- package/dist/{role-OXCiWTVq.js → role-B9VanAny.js} +3 -4
- package/dist/{rule-8iyCO_LZ.js → rule-C4f_Ilzr.js} +36 -37
- package/dist/src/api/schedule/index.d.ts +0 -3
- package/dist/src/views/scheduling/ScheduleGeneralPage.vue.d.ts +1 -2
- package/dist/src/views/scheduling/SchedulePage.vue.d.ts +1 -2
- package/dist/src/views/scheduling/SchedulePositionPage.vue.d.ts +1 -2
- package/dist/src/views/scheduling/components/ScheduleAddEmployeeModal.vue.d.ts +5 -1
- package/dist/src/views/scheduling/components/ScheduleAddEmployeePositionsSection.vue.d.ts +5 -1
- package/dist/src/views/scheduling/components/ScheduleAddPositionModal.vue.d.ts +6 -0
- package/dist/src/views/scheduling/components/ScheduleAutoScheduleModal.vue.d.ts +5 -1
- package/dist/src/views/scheduling/components/ScheduleButton.vue.d.ts +23 -0
- package/dist/src/views/scheduling/components/ScheduleConfirmModal.vue.d.ts +1 -1
- package/dist/src/views/scheduling/components/ScheduleEmployeeMenu.vue.d.ts +6 -0
- package/dist/src/views/scheduling/components/ScheduleGridSkeleton.vue.d.ts +2 -0
- package/dist/src/views/scheduling/components/ScheduleLeaveEditModal.vue.d.ts +4 -2
- package/dist/src/views/scheduling/components/ScheduleOnboardingWizard.vue.d.ts +3 -0
- package/dist/src/views/scheduling/components/ScheduleSelect.vue.d.ts +32 -2
- package/dist/src/views/scheduling/components/ScheduleShiftCell.vue.d.ts +4 -0
- package/dist/src/views/scheduling/components/ScheduleShiftHeadcountEditor.vue.d.ts +5 -1
- package/dist/src/views/scheduling/components/ScheduleShiftPopover.vue.d.ts +2 -0
- package/dist/src/views/scheduling/components/ScheduleStaffRail.vue.d.ts +4 -2
- package/dist/src/views/scheduling/components/ScheduleStaffRows.vue.d.ts +8 -2
- package/dist/src/views/scheduling/components/ScheduleTopbar.vue.d.ts +4 -6
- package/dist/src/views/scheduling/composables/schedule-add-employee-form.d.ts +5 -0
- package/dist/src/views/scheduling/composables/schedule-popover-position.d.ts +16 -0
- package/dist/src/views/scheduling/composables/scheduleAutoSolver.d.ts +21 -0
- package/dist/src/views/scheduling/composables/useCollapsedList.d.ts +9 -0
- package/dist/src/views/scheduling/composables/useScheduleAddEmployee.d.ts +12 -0
- package/dist/src/views/scheduling/composables/useScheduleAddPick.d.ts +14 -7
- package/dist/src/views/scheduling/composables/useScheduleAssign.d.ts +11 -2
- package/dist/src/views/scheduling/composables/useScheduleAutoSchedule.d.ts +18 -11
- package/dist/src/views/scheduling/composables/useScheduleBoard.d.ts +11 -0
- package/dist/src/views/scheduling/composables/useScheduleCopyWeek.d.ts +5 -3
- package/dist/src/views/scheduling/composables/useScheduleDayTimeline.d.ts +0 -5
- package/dist/src/views/scheduling/composables/useScheduleDemand.d.ts +12 -4
- package/dist/src/views/scheduling/composables/useScheduleDemandSheet.d.ts +7 -1
- package/dist/src/views/scheduling/composables/useScheduleEmployeeIdentity.d.ts +11 -2
- package/dist/src/views/scheduling/composables/useScheduleEmployeeMenu.d.ts +35 -0
- package/dist/src/views/scheduling/composables/useScheduleGapPopover.d.ts +2 -0
- package/dist/src/views/scheduling/composables/useScheduleLeave.d.ts +53 -3
- package/dist/src/views/scheduling/composables/useScheduleOnboardingWizard.d.ts +1192 -55
- package/dist/src/views/scheduling/composables/useScheduleOutlet.d.ts +1 -0
- package/dist/src/views/scheduling/composables/useSchedulePositionModal.d.ts +50 -0
- package/dist/src/views/scheduling/composables/useSchedulePublish.d.ts +2 -0
- package/dist/src/views/scheduling/composables/useScheduleRangeCalendar.d.ts +10 -1
- package/dist/src/views/scheduling/composables/useScheduleRoster.d.ts +6 -0
- package/dist/src/views/scheduling/composables/useScheduleSetupBanner.d.ts +5 -5
- package/dist/src/views/scheduling/composables/useScheduleShiftActions.d.ts +6 -0
- package/dist/src/views/scheduling/composables/useScheduleShiftPopover.d.ts +7 -0
- package/dist/src/views/scheduling/composables/useScheduleStaffRail.d.ts +4 -1
- package/dist/src/views/scheduling/composables/useScheduleTimePicker.d.ts +6 -1
- package/dist/src/views/scheduling/composables/useScheduleViewportFit.d.ts +9 -0
- package/dist/src/views/scheduling/data.d.ts +6 -1
- package/dist/src/views/scheduling/schedule-store.d.ts +36 -1
- package/dist/src/views/scheduling/types.d.ts +14 -1
- package/dist/style.css +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{useReportPermissions-C3fuFTUC.js → useReportPermissions-CTr56kBo.js} +3 -3
- package/package.json +1 -1
- package/dist/ScheduleGeneralPage-DD9n2TUe.js +0 -242
- package/dist/SchedulePage-B0X97zVC.js +0 -10761
- package/dist/SchedulePositionPage-BXz1USn3.js +0 -220
- package/dist/ScheduleSelect.vue_vue_type_script_setup_true_lang-DAHke2rH.js +0 -201
- package/dist/employee-ChdVnSmd.js +0 -139
- package/dist/index-CilJxsY7.js +0 -70
- package/dist/iteration-CcXrOMQe.js +0 -30
- package/dist/useScheduleOutlet-TPZJHgSY.js +0 -546
- package/dist/useSchedulePositions-DCkaKHQm.js +0 -103
|
@@ -14,6 +14,7 @@ export declare function useScheduleOutlet(): {
|
|
|
14
14
|
ready: import("vue").Ref<boolean, boolean>;
|
|
15
15
|
outletId: import("vue").Ref<string, string>;
|
|
16
16
|
resolve: () => Promise<string>;
|
|
17
|
+
resolveOutlet: () => Promise<string>;
|
|
17
18
|
switchTo: (restaurantId: string, weekStart: Date) => Promise<boolean>;
|
|
18
19
|
};
|
|
19
20
|
export type ScheduleOutletApi = ReturnType<typeof useScheduleOutlet>;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
export interface PositionModalPerson {
|
|
2
|
+
employeeId: string;
|
|
3
|
+
name: string;
|
|
4
|
+
initials: string;
|
|
5
|
+
/** Positions they already hold, main first — the row's second line. */
|
|
6
|
+
held: string[];
|
|
7
|
+
}
|
|
8
|
+
export interface PositionModalDone {
|
|
9
|
+
name: string;
|
|
10
|
+
assigned: number;
|
|
11
|
+
failed: number;
|
|
12
|
+
}
|
|
13
|
+
/** The "Add position" popup: a name, plus who on this outlet's roster can work it.
|
|
14
|
+
*
|
|
15
|
+
* Saving creates the (business-wide) position, then adds it to each ticked person's profile —
|
|
16
|
+
* as their main position when they have none yet, otherwise as one more they are trained in.
|
|
17
|
+
* The profile write replaces `secondaryPositions` wholesale, so a person's existing ones are
|
|
18
|
+
* sent back with the new one rather than being dropped. */
|
|
19
|
+
export declare function useSchedulePositionModal(onCreated?: (positionName: string) => void): {
|
|
20
|
+
open: import("vue").Ref<boolean, boolean>;
|
|
21
|
+
name: import("vue").Ref<string, string>;
|
|
22
|
+
search: import("vue").Ref<string, string>;
|
|
23
|
+
picks: Record<string, boolean>;
|
|
24
|
+
saving: import("vue").Ref<boolean, boolean>;
|
|
25
|
+
error: import("vue").Ref<string | null, string | null>;
|
|
26
|
+
done: import("vue").Ref<{
|
|
27
|
+
name: string;
|
|
28
|
+
assigned: number;
|
|
29
|
+
failed: number;
|
|
30
|
+
} | null, PositionModalDone | {
|
|
31
|
+
name: string;
|
|
32
|
+
assigned: number;
|
|
33
|
+
failed: number;
|
|
34
|
+
} | null>;
|
|
35
|
+
nameError: import("vue").Ref<boolean, boolean>;
|
|
36
|
+
people: import("vue").ComputedRef<PositionModalPerson[]>;
|
|
37
|
+
visible: import("vue").ComputedRef<PositionModalPerson[]>;
|
|
38
|
+
pickedIds: import("vue").ComputedRef<string[]>;
|
|
39
|
+
allPicked: import("vue").ComputedRef<boolean>;
|
|
40
|
+
nameTaken: import("vue").ComputedRef<boolean>;
|
|
41
|
+
canSave: import("vue").ComputedRef<boolean>;
|
|
42
|
+
openNew: () => void;
|
|
43
|
+
close: () => void;
|
|
44
|
+
toggle: (employeeId: string) => void;
|
|
45
|
+
toggleAll: () => void;
|
|
46
|
+
save: () => Promise<boolean>;
|
|
47
|
+
saveAndAnother: () => Promise<void>;
|
|
48
|
+
another: () => void;
|
|
49
|
+
};
|
|
50
|
+
export type SchedulePositionModalApi = ReturnType<typeof useSchedulePositionModal>;
|
|
@@ -53,6 +53,8 @@ export declare function useSchedulePublish(board: ScheduleBoardApi): {
|
|
|
53
53
|
reason: string;
|
|
54
54
|
half?: boolean | undefined;
|
|
55
55
|
halfPart?: "AM" | "PM" | undefined;
|
|
56
|
+
from?: string | undefined;
|
|
57
|
+
to?: string | undefined;
|
|
56
58
|
appliedOn?: string | undefined;
|
|
57
59
|
note?: string | undefined;
|
|
58
60
|
cert?: {
|
|
@@ -3,7 +3,11 @@ import type { ScheduleBoardApi } from './useScheduleBoard';
|
|
|
3
3
|
* week/Next week presets, matching the mockup's range calendar. */
|
|
4
4
|
export declare function useScheduleRangeCalendar(board: ScheduleBoardApi): {
|
|
5
5
|
open: import("vue").Ref<boolean, boolean>;
|
|
6
|
-
|
|
6
|
+
pos: {
|
|
7
|
+
left: number;
|
|
8
|
+
top: number;
|
|
9
|
+
};
|
|
10
|
+
toggle: (anchor?: HTMLElement) => void;
|
|
7
11
|
close: () => void;
|
|
8
12
|
cursorMonth: import("vue").Ref<Date, Date>;
|
|
9
13
|
shiftMonth: (delta: number) => void;
|
|
@@ -12,6 +16,11 @@ export declare function useScheduleRangeCalendar(board: ScheduleBoardApi): {
|
|
|
12
16
|
date: Date | null;
|
|
13
17
|
}[]>;
|
|
14
18
|
isInRange: (date: Date) => boolean;
|
|
19
|
+
isStart: (date: Date) => boolean;
|
|
20
|
+
isEnd: (date: Date) => boolean;
|
|
21
|
+
isToday: (date: Date) => boolean;
|
|
22
|
+
rangeLabel: import("vue").ComputedRef<string>;
|
|
23
|
+
rangeDays: import("vue").ComputedRef<number>;
|
|
15
24
|
pickDate: (date: Date) => void;
|
|
16
25
|
presetToday: () => void;
|
|
17
26
|
presetNextWeek: () => void;
|
|
@@ -40,6 +40,8 @@ export declare function useScheduleRoster(board: ScheduleBoardApi): {
|
|
|
40
40
|
reason: string;
|
|
41
41
|
half?: boolean | undefined;
|
|
42
42
|
halfPart?: "AM" | "PM" | undefined;
|
|
43
|
+
from?: string | undefined;
|
|
44
|
+
to?: string | undefined;
|
|
43
45
|
appliedOn?: string | undefined;
|
|
44
46
|
note?: string | undefined;
|
|
45
47
|
cert?: {
|
|
@@ -82,6 +84,7 @@ export declare function useScheduleRoster(board: ScheduleBoardApi): {
|
|
|
82
84
|
payAmount?: number | undefined;
|
|
83
85
|
maxHours?: number | undefined;
|
|
84
86
|
maxOtHours?: number | undefined;
|
|
87
|
+
minHours?: number | undefined;
|
|
85
88
|
otAfterDaily?: number | undefined;
|
|
86
89
|
preferences?: string[] | undefined;
|
|
87
90
|
seniority?: "senior" | "junior" | "" | undefined;
|
|
@@ -124,6 +127,8 @@ export declare function useScheduleRoster(board: ScheduleBoardApi): {
|
|
|
124
127
|
reason: string;
|
|
125
128
|
half?: boolean | undefined;
|
|
126
129
|
halfPart?: "AM" | "PM" | undefined;
|
|
130
|
+
from?: string | undefined;
|
|
131
|
+
to?: string | undefined;
|
|
127
132
|
appliedOn?: string | undefined;
|
|
128
133
|
note?: string | undefined;
|
|
129
134
|
cert?: {
|
|
@@ -166,6 +171,7 @@ export declare function useScheduleRoster(board: ScheduleBoardApi): {
|
|
|
166
171
|
payAmount?: number | undefined;
|
|
167
172
|
maxHours?: number | undefined;
|
|
168
173
|
maxOtHours?: number | undefined;
|
|
174
|
+
minHours?: number | undefined;
|
|
169
175
|
otAfterDaily?: number | undefined;
|
|
170
176
|
preferences?: string[] | undefined;
|
|
171
177
|
seniority?: "senior" | "junior" | "" | undefined;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/** "Set it up" banner —
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
* unconfigured.
|
|
1
|
+
/** "Set it up" banner — shown while the outlet has not finished scheduling setup, i.e. while
|
|
2
|
+
* `scheduleSetupCompleted` (schedule-store) is false. That flag is a placeholder until the
|
|
3
|
+
* backend settings carry it. Dismissing is a session choice: the banner is cheap enough to see
|
|
4
|
+
* again on the next visit while the outlet really is unconfigured.
|
|
5
5
|
*
|
|
6
6
|
* The welcome dialog answers a different question — "has this outlet's owner seen the
|
|
7
7
|
* onboarding greeting" — and is deliberately NOT tied to whether positions currently exist:
|
|
8
|
-
* the board's
|
|
8
|
+
* the board's data lands from an async fetch, so gating the dialog on it
|
|
9
9
|
* meant a fast response for an outlet that already had positions saved could yank the dialog
|
|
10
10
|
* shut within the same tick it opened, before anyone could read it. `localStorage`, keyed per
|
|
11
11
|
* outlet, is what makes "seen" durable and independent of that fetch. */
|
|
@@ -68,6 +68,8 @@ export declare function useScheduleShiftActions(board: ScheduleBoardApi): {
|
|
|
68
68
|
reason: string;
|
|
69
69
|
half?: boolean | undefined;
|
|
70
70
|
halfPart?: "AM" | "PM" | undefined;
|
|
71
|
+
from?: string | undefined;
|
|
72
|
+
to?: string | undefined;
|
|
71
73
|
appliedOn?: string | undefined;
|
|
72
74
|
note?: string | undefined;
|
|
73
75
|
cert?: {
|
|
@@ -110,6 +112,7 @@ export declare function useScheduleShiftActions(board: ScheduleBoardApi): {
|
|
|
110
112
|
payAmount?: number | undefined;
|
|
111
113
|
maxHours?: number | undefined;
|
|
112
114
|
maxOtHours?: number | undefined;
|
|
115
|
+
minHours?: number | undefined;
|
|
113
116
|
otAfterDaily?: number | undefined;
|
|
114
117
|
preferences?: string[] | undefined;
|
|
115
118
|
seniority?: "senior" | "junior" | "" | undefined;
|
|
@@ -162,6 +165,8 @@ export declare function useScheduleShiftActions(board: ScheduleBoardApi): {
|
|
|
162
165
|
reason: string;
|
|
163
166
|
half?: boolean | undefined;
|
|
164
167
|
halfPart?: "AM" | "PM" | undefined;
|
|
168
|
+
from?: string | undefined;
|
|
169
|
+
to?: string | undefined;
|
|
165
170
|
appliedOn?: string | undefined;
|
|
166
171
|
note?: string | undefined;
|
|
167
172
|
cert?: {
|
|
@@ -204,6 +209,7 @@ export declare function useScheduleShiftActions(board: ScheduleBoardApi): {
|
|
|
204
209
|
payAmount?: number | undefined;
|
|
205
210
|
maxHours?: number | undefined;
|
|
206
211
|
maxOtHours?: number | undefined;
|
|
212
|
+
minHours?: number | undefined;
|
|
207
213
|
otAfterDaily?: number | undefined;
|
|
208
214
|
preferences?: string[] | undefined;
|
|
209
215
|
seniority?: "senior" | "junior" | "" | undefined;
|
|
@@ -43,6 +43,9 @@ export declare function useScheduleShiftPopover(board: ScheduleBoardApi, demand:
|
|
|
43
43
|
}[]>;
|
|
44
44
|
impact: import("vue").ComputedRef<{
|
|
45
45
|
when: string;
|
|
46
|
+
pctBefore: number;
|
|
47
|
+
pctAfter: number;
|
|
48
|
+
stillShort: number;
|
|
46
49
|
before: {
|
|
47
50
|
required: number;
|
|
48
51
|
scheduled: number;
|
|
@@ -100,6 +103,8 @@ export declare function useScheduleShiftPopover(board: ScheduleBoardApi, demand:
|
|
|
100
103
|
reason: string;
|
|
101
104
|
half?: boolean | undefined;
|
|
102
105
|
halfPart?: "AM" | "PM" | undefined;
|
|
106
|
+
from?: string | undefined;
|
|
107
|
+
to?: string | undefined;
|
|
103
108
|
appliedOn?: string | undefined;
|
|
104
109
|
note?: string | undefined;
|
|
105
110
|
cert?: {
|
|
@@ -142,6 +147,7 @@ export declare function useScheduleShiftPopover(board: ScheduleBoardApi, demand:
|
|
|
142
147
|
payAmount?: number | undefined;
|
|
143
148
|
maxHours?: number | undefined;
|
|
144
149
|
maxOtHours?: number | undefined;
|
|
150
|
+
minHours?: number | undefined;
|
|
145
151
|
otAfterDaily?: number | undefined;
|
|
146
152
|
preferences?: string[] | undefined;
|
|
147
153
|
seniority?: "senior" | "junior" | "" | undefined;
|
|
@@ -160,6 +166,7 @@ export declare function useScheduleShiftPopover(board: ScheduleBoardApi, demand:
|
|
|
160
166
|
isSingleOpenRecord: import("vue").ComputedRef<boolean>;
|
|
161
167
|
totalHours: import("vue").ComputedRef<number>;
|
|
162
168
|
totalLabel: import("vue").ComputedRef<string>;
|
|
169
|
+
warnings: import("vue").ComputedRef<string[]>;
|
|
163
170
|
openForEmployee: (forEmpId: number, day: number, roleHint?: string, hours?: ScheduleShiftSegment) => void;
|
|
164
171
|
openForNewOpenShift: (day: number, roleHint?: string, hours?: ScheduleShiftSegment) => void;
|
|
165
172
|
openForEditOpenShift: (openShiftId: number) => void;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Proposal } from '../types';
|
|
1
2
|
import type { ScheduleBoardApi } from './useScheduleBoard';
|
|
2
3
|
import type { ScheduleEmployeeLoad } from './useScheduleEmployeeIdentity';
|
|
3
4
|
export type ScheduleRailSort = 'load' | 'name' | 'hours' | 'cost';
|
|
@@ -8,7 +9,9 @@ export type ScheduleRailRow = ScheduleEmployeeLoad;
|
|
|
8
9
|
* column shows, plus each person's load bar and an "Open shifts" jump summary. Ported from
|
|
9
10
|
* the mockup's renderStaffRail()/orderedRoster()/staffLoad(), scoped to a single week (no
|
|
10
11
|
* day/area combination — Daily view stays employee-only for now). */
|
|
11
|
-
export declare function useScheduleStaffRail(board: ScheduleBoardApi
|
|
12
|
+
export declare function useScheduleStaffRail(board: ScheduleBoardApi,
|
|
13
|
+
/** Lazy: the auto-scheduler is built after the rail, and only read when rows are computed. */
|
|
14
|
+
proposalAt?: () => ((empId: number, dayIdx: number) => Proposal | undefined) | undefined): {
|
|
12
15
|
search: import("vue").Ref<string, string>;
|
|
13
16
|
sort: import("vue").Ref<ScheduleRailSort, ScheduleRailSort>;
|
|
14
17
|
rows: import("vue").ComputedRef<ScheduleEmployeeLoad[]>;
|
|
@@ -15,6 +15,8 @@ export interface ScheduleTimePickerState {
|
|
|
15
15
|
* value gets read from to appear in the list at all. */
|
|
16
16
|
value: string;
|
|
17
17
|
query: string;
|
|
18
|
+
/** Which trigger button opened it, so only that one wears the open state. */
|
|
19
|
+
key: string;
|
|
18
20
|
left: number;
|
|
19
21
|
top: number;
|
|
20
22
|
}
|
|
@@ -29,6 +31,7 @@ export declare function useScheduleTimePicker(): {
|
|
|
29
31
|
open: boolean;
|
|
30
32
|
value: string;
|
|
31
33
|
query: string;
|
|
34
|
+
key: string;
|
|
32
35
|
left: number;
|
|
33
36
|
top: number;
|
|
34
37
|
};
|
|
@@ -36,7 +39,9 @@ export declare function useScheduleTimePicker(): {
|
|
|
36
39
|
amOptions: import("vue").ComputedRef<ScheduleTimePickerOption[]>;
|
|
37
40
|
pmOptions: import("vue").ComputedRef<ScheduleTimePickerOption[]>;
|
|
38
41
|
typedValue: import("vue").ComputedRef<string | null>;
|
|
39
|
-
openFor: (anchor: HTMLElement, value: string, pick: (hhmm: string) => void) => void;
|
|
42
|
+
openFor: (anchor: HTMLElement, value: string, pick: (hhmm: string) => void, key?: string) => void;
|
|
43
|
+
anchorRect: () => DOMRect | null;
|
|
44
|
+
isOpenFor: (key: string) => boolean;
|
|
40
45
|
close: () => void;
|
|
41
46
|
pick: (value: string) => void;
|
|
42
47
|
submitQuery: () => void;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type Ref } from 'vue';
|
|
2
|
+
/** Pins the scheduling screen to the viewport so only the grid scrolls.
|
|
3
|
+
*
|
|
4
|
+
* `PortalShell` wraps every route in two unstyled divs, and the height chain above them is the
|
|
5
|
+
* host app's, not ours: with no definite height anywhere up there, `.sch { height: 100% }` has
|
|
6
|
+
* nothing to resolve against, the whole page grows to its content and the browser scrolls it —
|
|
7
|
+
* header rows included. Measuring where the shell starts and giving it the rest of the viewport
|
|
8
|
+
* is the one thing that does not depend on how the host lays itself out. */
|
|
9
|
+
export declare function useScheduleViewportFit(rootEl: Ref<HTMLElement | null | undefined>): void;
|
|
@@ -2,7 +2,6 @@ import type { CompGroupMeta, Employee, ExistingStaffCandidate, OpenShift, Schedu
|
|
|
2
2
|
import type { FdtoSchedulePosition, FdtoSchedulePositionSelectorReq } from '@/types/schedule';
|
|
3
3
|
export declare const UNASSIGNED = "unassigned";
|
|
4
4
|
export declare const WEEKDAYS: string[];
|
|
5
|
-
export declare const DEFAULT_POSITION = "Any position";
|
|
6
5
|
export declare const ALL_STATIONS = "All Stations";
|
|
7
6
|
/** Employment seniority is a closed set in the model, not something an outlet configures. */
|
|
8
7
|
export declare const SENIORITY_OPTIONS: Array<'senior' | 'junior'>;
|
|
@@ -36,6 +35,9 @@ export declare const OUTLET: {
|
|
|
36
35
|
/** Outlets a person may be rostered at. Filled by useScheduleOutlet from the restaurant store
|
|
37
36
|
* — the board payload only ever describes the one outlet it was asked for. */
|
|
38
37
|
export declare const LOCATION_OPTIONS: string[];
|
|
38
|
+
/** Outlet id → name, so a person's POS `restaurantRole` (outlet ids) can be shown as the same
|
|
39
|
+
* labels LOCATION_OPTIONS offers. Filled alongside it by useScheduleOutlet. */
|
|
40
|
+
export declare const LOCATION_LABEL_BY_ID: Record<string, string>;
|
|
39
41
|
/** No Mongo source: departments and compensation groups are not modelled. The Add Employee
|
|
40
42
|
* form renders these as empty pickers rather than offering choices nobody configured. */
|
|
41
43
|
export declare const DEPT_OPTIONS: string[];
|
|
@@ -74,6 +76,9 @@ export declare function gridDayIdx(dayOfWeek: number): number;
|
|
|
74
76
|
export declare function jsDayOfWeek(gridIdx: number): number;
|
|
75
77
|
export declare function employeeIdOf(num: number): string | undefined;
|
|
76
78
|
export declare function employeeNumberOf(employeeId: string): number;
|
|
79
|
+
/** The outlets a person is rostered at, by name, from the POS roster's `restaurantRole`. */
|
|
80
|
+
/** The outlet being scheduled goes first in a list of locations; the rest keep their order. */
|
|
81
|
+
export declare function currentLocationFirst(locations: string[]): string[];
|
|
77
82
|
export declare function createScheduleEmployees(dates?: Date[]): Employee[];
|
|
78
83
|
/** Open shifts backed by a persisted Shift requirement never shipped — the backend never
|
|
79
84
|
* carried that collection, so this always produced an empty list in practice. Kept as a stub,
|
|
@@ -6,7 +6,15 @@ import type { FdtoScheduleAssignment, FdtoScheduleAutoScheduleReq, FdtoScheduleA
|
|
|
6
6
|
export declare function isoDate(d: Date): string;
|
|
7
7
|
export declare const payload: import("vue").ShallowRef<FdtoScheduleBoard | null, FdtoScheduleBoard | null>;
|
|
8
8
|
export declare const loading: import("vue").Ref<boolean, boolean>;
|
|
9
|
+
/** The POS roster (who the board's rows are) is fetched separately from the board window. */
|
|
10
|
+
export declare const rosterLoading: import("vue").Ref<boolean, boolean>;
|
|
9
11
|
export declare const loadError: import("vue").Ref<string | null, string | null>;
|
|
12
|
+
/** Whether this outlet has finished setting up scheduling (onboarding). The schedule settings
|
|
13
|
+
* will carry this, but the backend has no such field yet, so it is a plain flag that defaults to
|
|
14
|
+
* "not finished" — the setup banner keys off it. TODO: when the field exists, set it from the
|
|
15
|
+
* settings payload where `payload` is applied (and flip it when the onboarding wizard finishes);
|
|
16
|
+
* nothing else needs to change. */
|
|
17
|
+
export declare const scheduleSetupCompleted: import("vue").Ref<boolean, boolean>;
|
|
10
18
|
/** Bumped every time `payload` is replaced. Anything that caches a derived view of the data
|
|
11
19
|
* — the board's per-week buckets above all — watches this and rebuilds. */
|
|
12
20
|
export declare const dataVersion: import("vue").Ref<number, number>;
|
|
@@ -53,6 +61,28 @@ export declare function setOutlet(restaurantId: string): boolean;
|
|
|
53
61
|
* separate invalidation path. A generous page size rather than looping pages: real restaurant
|
|
54
62
|
* headcounts sit nowhere near it. */
|
|
55
63
|
export declare function ensureRestaurantEmployeesLoaded(restaurantId: string): Promise<void>;
|
|
64
|
+
/** Re-reads this outlet's POS roster. The roster is what the board's rows are built from and is
|
|
65
|
+
* otherwise fetched once per outlet, so any write that changes who works here (add, remove)
|
|
66
|
+
* has to call this for the grid to show it. */
|
|
67
|
+
export declare function refreshRestaurantEmployees(): Promise<void>;
|
|
68
|
+
/** Gives an existing POS user a role at this outlet, so they land on its roster. */
|
|
69
|
+
export declare function addEmployeeToOutlet(employeeId: string, roleId: string): Promise<void>;
|
|
70
|
+
/** Takes a POS user off the given outlets' rosters; their other outlets are untouched. */
|
|
71
|
+
export declare function removeEmployeeFromOutlets(employeeId: string, restaurantIds: string[]): Promise<void>;
|
|
72
|
+
/** Takes a POS user off this outlet's roster only. */
|
|
73
|
+
export declare function removeEmployeeFromOutlet(employeeId: string): Promise<void>;
|
|
74
|
+
/** Every outlet each person works at (POS user id → outlet ids). The roster above is fetched
|
|
75
|
+
* FILTERED to one outlet, and a filtered read describes a person by that outlet alone, so the
|
|
76
|
+
* full list has to come from an unfiltered read. Paged until the total is covered. A failure
|
|
77
|
+
* leaves the map empty rather than failing the board: locations are display-only here. */
|
|
78
|
+
export declare const employeeOutletIds: import("vue").ShallowRef<Record<string, string[]>, Record<string, string[]>>;
|
|
79
|
+
/** Everyone in the business (POS user summaries: name, passcode, outlet roles), kept once and
|
|
80
|
+
* shared by the locations map, "select existing employee", passcode prefill and the role edits —
|
|
81
|
+
* the plain `/pos-users` read they used before returns every user-outlet row in one slow call. */
|
|
82
|
+
export declare const businessEmployees: import("vue").ShallowRef<IFdtoPosUserSummary[], IFdtoPosUserSummary[]>;
|
|
83
|
+
/** The cached business roster, fetched on first use. `force` re-reads it (after a write, or to
|
|
84
|
+
* refresh a list that is already on screen). Concurrent callers share one request. */
|
|
85
|
+
export declare function ensureBusinessEmployees(force?: boolean): Promise<IFdtoPosUserSummary[]>;
|
|
56
86
|
/** Guarantees the week starting `weekStart` is in memory, fetching a padded window around it
|
|
57
87
|
* if it is not. Safe to call on every navigation: a week already covered costs nothing. */
|
|
58
88
|
export declare function ensureWeekLoaded(weekStart: Date): Promise<void>;
|
|
@@ -98,6 +128,12 @@ export declare function saveScheduleDay(date: string, req: FdtoScheduleSaveSched
|
|
|
98
128
|
* Position-specific headcount becomes its own row; any remaining headcount becomes an
|
|
99
129
|
* unpositioned row for the same time range. */
|
|
100
130
|
export declare function saveDemand(req: ScheduleReplaceDemandReq): Promise<void>;
|
|
131
|
+
/** Copies one date's own demand rows onto another date, as that date's own rows. A date that
|
|
132
|
+
* already has demand of its own is left alone (nothing is overwritten), and a source date with
|
|
133
|
+
* none has nothing to copy: the standing weekday rule already covers the same weekday in every
|
|
134
|
+
* week, so repeating it per date would only shadow later edits to the rule. Returns how many rows
|
|
135
|
+
* were written. */
|
|
136
|
+
export declare function copyDateDemand(fromDate: string, toDate: string): Promise<number>;
|
|
101
137
|
export declare function generateAutoSchedule(req: FdtoScheduleAutoScheduleReq): Promise<FdtoScheduleAutoScheduleResult>;
|
|
102
138
|
/** A one-off shift assignment — someone working these hours on this date, not answering any
|
|
103
139
|
* Shift requirement. Deliberately does not reload: unlike `createEmployeeProfile` above, there
|
|
@@ -113,4 +149,3 @@ export declare function deleteAssignments(ids: string[]): Promise<void>;
|
|
|
113
149
|
/** Flips a batch of existing assignments to one status in a single request — see
|
|
114
150
|
* `ScheduleAPI.bulkUpdateAssignmentStatus`. */
|
|
115
151
|
export declare function bulkUpdateAssignmentStatus(req: FdtoScheduleBulkUpdateAssignmentStatusReq): Promise<FdtoScheduleAssignment[]>;
|
|
116
|
-
export declare function devResetOutlet(): Promise<number>;
|
|
@@ -34,6 +34,9 @@ export interface LeaveSlot {
|
|
|
34
34
|
reason: string;
|
|
35
35
|
half?: boolean;
|
|
36
36
|
halfPart?: 'AM' | 'PM';
|
|
37
|
+
/** Specific hours (HH:MM), for leave that is neither all day nor a morning / afternoon. */
|
|
38
|
+
from?: string;
|
|
39
|
+
to?: string;
|
|
37
40
|
appliedOn?: string;
|
|
38
41
|
note?: string;
|
|
39
42
|
cert?: {
|
|
@@ -87,6 +90,9 @@ export interface Employee {
|
|
|
87
90
|
payAmount?: number;
|
|
88
91
|
maxHours?: number;
|
|
89
92
|
maxOtHours?: number;
|
|
93
|
+
/** Shortest shift, in hours, this person will come in for. Asking for less is allowed but
|
|
94
|
+
* warned about in the shift popover. */
|
|
95
|
+
minHours?: number;
|
|
90
96
|
otAfterDaily?: number;
|
|
91
97
|
preferences?: string[];
|
|
92
98
|
seniority?: 'senior' | 'junior' | '';
|
|
@@ -235,6 +241,8 @@ export interface ExistingStaffCandidate {
|
|
|
235
241
|
* scheduling profile there, just enough context to tell two same-named people apart and to
|
|
236
242
|
* warn against loaning someone who's clearly based elsewhere. */
|
|
237
243
|
otherOutlets: string[];
|
|
244
|
+
/** Every outlet the person works at, by name (this one included when the POS lists it). */
|
|
245
|
+
locations: string[];
|
|
238
246
|
}
|
|
239
247
|
export interface CompGroupMeta {
|
|
240
248
|
basis: 'Hourly' | 'Monthly';
|
|
@@ -287,7 +295,7 @@ export interface CoverageSegment {
|
|
|
287
295
|
/** Nothing was asked for in these hours — an absence of a question, not a gap in one. */
|
|
288
296
|
none: boolean;
|
|
289
297
|
}
|
|
290
|
-
export type DemandApplyMode = 'day' | 'weekday' | 'weekdays' | 'custom';
|
|
298
|
+
export type DemandApplyMode = 'day' | 'every' | 'weekday' | 'weekdays' | 'custom';
|
|
291
299
|
export interface NoticeBanner {
|
|
292
300
|
variant: 'holiday' | 'info' | 'warning';
|
|
293
301
|
dayIdx: number;
|
|
@@ -308,4 +316,9 @@ export interface Proposal {
|
|
|
308
316
|
/** Set when this proposal would fill a named OpenShift record. */
|
|
309
317
|
openId?: number;
|
|
310
318
|
status: 'pending' | 'rejected';
|
|
319
|
+
/** The week these belong to: its first day's date. Proposals are day positions, so without
|
|
320
|
+
* this they would appear on whichever week is showing. */
|
|
321
|
+
weekKey?: string;
|
|
322
|
+
/** Why this person, for the card's tooltip. */
|
|
323
|
+
reason?: string;
|
|
311
324
|
}
|