@feedmepos/mf-hrm-portal 2.3.0-dev.10 → 2.3.0-dev.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/dist/{ApprovalCodeList-BLA2rhLB.js → ApprovalCodeList--NA0toYU.js} +2 -2
  2. package/dist/{AuditLogList-DBYdZhZl.js → AuditLogList-B-NaB6OX.js} +3 -3
  3. package/dist/{ConditionBuilderForm.vue_vue_type_script_setup_true_lang-CtCEzPbE.js → ConditionBuilderForm.vue_vue_type_script_setup_true_lang-AEr2bDPY.js} +2 -2
  4. package/dist/{EmployeeList-CA7DWLmy.js → EmployeeList-idO38m7y.js} +23 -22
  5. package/dist/{GrantUserList-BYnegeEr.js → GrantUserList-B1S7yDKu.js} +3 -3
  6. package/dist/{Main-NDK7LUmm.js → Main-D5cWrqP3.js} +9 -9
  7. package/dist/{Main-Dh-gZSaa.js → Main-cdf9NV8P.js} +2 -2
  8. package/dist/{Main-BeXx0hAc.js → Main-mcCvBPvJ.js} +5 -5
  9. package/dist/{PermissionSetList-DDIacDpQ.js → PermissionSetList-3_f6sJpK.js} +17 -16
  10. package/dist/{PortalPermissionEditor.vue_vue_type_script_setup_true_lang-ONMn3v_f.js → PortalPermissionEditor.vue_vue_type_script_setup_true_lang-Cmin3rlY.js} +873 -873
  11. package/dist/ResponsiveContextMenu.vue_vue_type_script_setup_true_lang-mSJFKo7r.js +132 -0
  12. package/dist/{RoleList-B30FHIzu.js → RoleList-ByQelhuG.js} +19 -18
  13. package/dist/{ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-CRRguWTG.js → ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-e4YOu59G.js} +1 -1
  14. package/dist/{ScheduleGeneralPage-8gEeZbFR.js → ScheduleGeneralPage-TKWgkAoE.js} +130 -128
  15. package/dist/{ScheduleModal.vue_vue_type_script_setup_true_lang-TfxTAjO8.js → ScheduleModal.vue_vue_type_script_setup_true_lang-6bTAsmpp.js} +527 -491
  16. package/dist/SchedulePage-BpvgQYqL.js +17985 -0
  17. package/dist/{SchedulePositionPage-oGIDGneA.js → SchedulePositionPage-BjvKTHyY.js} +3 -3
  18. package/dist/{TeamMemberList-Drj6R4Y3.js → TeamMemberList-CJzF0wNK.js} +20 -19
  19. package/dist/{TimesheetList-CDQfN5LE.js → TimesheetList-CJcSs_B1.js} +5 -5
  20. package/dist/{TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-Bx-6hjs7.js → TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-zttvxhi-.js} +2 -2
  21. package/dist/{app-DWe_4-ct.js → app-DLiYhsK2.js} +8 -8
  22. package/dist/app.js +1 -1
  23. package/dist/{dayjs.min-QSwC9dtX.js → dayjs.min-ar-wg1yi.js} +1 -1
  24. package/dist/{employee-Bb2b3dP6.js → employee-CmUfaF0i.js} +3 -3
  25. package/dist/{iteration-TDU7bFxZ.js → iteration-uWvyRKkX.js} +1 -1
  26. package/dist/{lodash-D3Ns5VMN.js → lodash-BzVEbSHJ.js} +1 -1
  27. package/dist/{role-D57Le_-U.js → role-R2KDFlIY.js} +1 -1
  28. package/dist/{rule-DzesUEX7.js → rule-C6ELRd3E.js} +2 -2
  29. package/dist/src/composables/useDiscardConfirm.d.ts +3 -1
  30. package/dist/src/views/scheduling/components/ScheduleConfirmModal.vue.d.ts +2 -1
  31. package/dist/src/views/scheduling/composables/useScheduleAddEmployee.d.ts +1 -0
  32. package/dist/src/views/scheduling/composables/useScheduleAutoSchedule.d.ts +0 -3
  33. package/dist/src/views/scheduling/composables/useScheduleBoard.d.ts +2 -0
  34. package/dist/src/views/scheduling/composables/useScheduleDemandSheet.d.ts +7 -0
  35. package/dist/src/views/scheduling/composables/useScheduleEmployeeCandidates.d.ts +2 -2
  36. package/dist/src/views/scheduling/composables/useScheduleOnboardingEmployees.d.ts +1 -0
  37. package/dist/src/views/scheduling/composables/useScheduleOnboardingWizard.d.ts +7 -0
  38. package/dist/src/views/scheduling/composables/useScheduleOutlet.d.ts +10 -8
  39. package/dist/src/views/scheduling/composables/useScheduleRoster.d.ts +2 -0
  40. package/dist/src/views/scheduling/composables/useScheduleShiftActions.d.ts +1 -0
  41. package/dist/src/views/scheduling/composables/useScheduleShiftPopover.d.ts +6 -1
  42. package/dist/src/views/scheduling/schedule-store.d.ts +13 -0
  43. package/dist/src/views/scheduling/types.d.ts +2 -0
  44. package/dist/style.css +1 -1
  45. package/dist/tsconfig.app.tsbuildinfo +1 -1
  46. package/dist/useDiscardConfirm-CzZSPyvh.js +28 -0
  47. package/dist/{useReportPermissions-Cmuead1K.js → useReportPermissions-B2U347Ey.js} +3 -3
  48. package/package.json +3 -3
  49. package/dist/SchedulePage-DQ0VXWWi.js +0 -17832
  50. package/dist/useDiscardConfirm-DPhEV6v0.js +0 -157
@@ -1,11 +1,11 @@
1
- import { ref as w, reactive as B, computed as N, defineComponent as T, createBlock as I, openBlock as p, withCtx as b, createElementVNode as e, createVNode as k, createElementBlock as m, Fragment as L, createTextVNode as H, toDisplayString as h, withDirectives as f, vModelText as g, createCommentVNode as A, renderList as V, onMounted as z, unref as o, normalizeClass as U } from "vue";
2
- import { useRouter as W } from "vue-router";
1
+ import { ref as w, reactive as W, computed as E, defineComponent as T, createBlock as I, openBlock as p, withCtx as b, createElementVNode as e, createVNode as k, createElementBlock as m, Fragment as L, createTextVNode as H, toDisplayString as h, withDirectives as f, vModelText as g, createCommentVNode as N, renderList as V, onMounted as B, unref as l, normalizeClass as U } from "vue";
2
+ import { useRouter as z } from "vue-router";
3
3
  import { useSnackbar as Y } from "@feedmepos/ui-library";
4
- import { R as q } from "./app-DWe_4-ct.js";
5
- import { b as v, o as M, M as E, g as G, aq as F, ao as x, as as j, at as J, ab as K, ap as Q } from "./ScheduleModal.vue_vue_type_script_setup_true_lang-TfxTAjO8.js";
6
- import "./iteration-TDU7bFxZ.js";
4
+ import { R as q } from "./app-DLiYhsK2.js";
5
+ import { b as v, o as M, M as A, g as G, aq as F, ao as x, as as j, at as J, ab as K, ap as Q } from "./ScheduleModal.vue_vue_type_script_setup_true_lang-6bTAsmpp.js";
6
+ import "./iteration-uWvyRKkX.js";
7
7
  import { useCoreStore as X } from "@feedmepos/mf-common";
8
- import "./employee-Bb2b3dP6.js";
8
+ import "./employee-CmUfaF0i.js";
9
9
  const Z = [
10
10
  { key: "payrates", label: "Pay rates" },
11
11
  { key: "overtime", label: "Overtime" },
@@ -25,99 +25,101 @@ function $() {
25
25
  });
26
26
  }
27
27
  function _() {
28
- const l = X(), d = w(!1), a = w("payrates"), r = B($()), t = w(!1);
28
+ const r = X(), d = w(!1), a = w("payrates"), n = W($()), t = w(!1);
29
29
  let u = 0;
30
30
  async function C() {
31
31
  if (!M.value) return;
32
- const c = ++u, i = M.value;
32
+ const c = ++u, o = M.value;
33
33
  t.value = !0;
34
34
  try {
35
- const s = await E.getSettings(i);
36
- if (c !== u || M.value !== i) return;
37
- const n = G(l.currentCountry.value);
38
- v.payRate = structuredClone(s.settingsConfigured ? s.payRate : n.payRate), v.otCapHours = s.settingsConfigured ? s.overtime.maxHoursPerMonth : n.overtime.maxHoursPerMonth, v.workingHours = s.settingsConfigured ? structuredClone(s.workingHours) : {
35
+ const s = await A.getSettings(o);
36
+ if (c !== u || M.value !== o) return;
37
+ const i = G(r.currentCountry.value);
38
+ v.payRate = structuredClone(s.settingsConfigured ? s.payRate : i.payRate), v.otCapHours = s.settingsConfigured ? s.overtime.maxHoursPerMonth : i.overtime.maxHoursPerMonth, v.workingHours = s.settingsConfigured ? structuredClone(s.workingHours) : {
39
39
  minHoursPerDay: null,
40
- maxHoursPerDay: n.workingHours.maxHoursPerDay,
41
- maxHoursPerWeek: n.workingHours.maxHoursPerWeek
40
+ maxHoursPerDay: i.workingHours.maxHoursPerDay,
41
+ maxHoursPerWeek: i.workingHours.maxHoursPerWeek
42
42
  };
43
43
  } finally {
44
44
  c === u && (t.value = !1);
45
45
  }
46
46
  }
47
47
  function y(c) {
48
- Object.assign(r, $()), a.value = c ?? "payrates", d.value = !0;
48
+ Object.assign(n, $()), a.value = c ?? "payrates", d.value = !0;
49
49
  }
50
- const S = N(() => JSON.stringify(r) !== JSON.stringify($()));
50
+ const S = E(() => JSON.stringify(n) !== JSON.stringify($()));
51
51
  function P() {
52
52
  return S.value ? !1 : (d.value = !1, !0);
53
53
  }
54
54
  function D() {
55
- Object.assign(r, $()), d.value = !1;
55
+ Object.assign(n, $()), d.value = !1;
56
56
  }
57
57
  async function R() {
58
58
  if (!M.value) throw new Error("No outlet selected");
59
- const c = r.otCapHours === 0 ? null : r.otCapHours;
59
+ const c = n.otCapHours === 0 ? null : n.otCapHours;
60
60
  if (c != null && c <= 0)
61
61
  throw new Error("Maximum monthly overtime hours must be greater than zero");
62
- const i = {
63
- minHoursPerDay: r.workingHours.minHoursPerDay === 0 ? null : r.workingHours.minHoursPerDay,
64
- maxHoursPerDay: r.workingHours.maxHoursPerDay === 0 ? null : r.workingHours.maxHoursPerDay,
65
- maxHoursPerWeek: r.workingHours.maxHoursPerWeek === 0 ? null : r.workingHours.maxHoursPerWeek
62
+ const o = {
63
+ minHoursPerDay: n.workingHours.minHoursPerDay === 0 ? null : n.workingHours.minHoursPerDay,
64
+ maxHoursPerDay: n.workingHours.maxHoursPerDay === 0 ? null : n.workingHours.maxHoursPerDay,
65
+ maxHoursPerWeek: n.workingHours.maxHoursPerWeek === 0 ? null : n.workingHours.maxHoursPerWeek
66
66
  };
67
- if (i.minHoursPerDay != null && i.maxHoursPerDay != null && i.minHoursPerDay > i.maxHoursPerDay)
68
- throw new Error("Minimum daily working hours cannot exceed maximum daily working hours");
69
- const s = await E.saveSettings(M.value, {
70
- payRate: r.payRate,
67
+ if (o.minHoursPerDay != null && o.maxHoursPerDay != null && o.minHoursPerDay > o.maxHoursPerDay)
68
+ throw new Error("Working-hour limits must be in ascending order");
69
+ if (o.maxHoursPerDay != null && o.maxHoursPerWeek != null && o.maxHoursPerDay > o.maxHoursPerWeek)
70
+ throw new Error("Working-hour limits must be in ascending order");
71
+ const s = await A.saveSettings(M.value, {
72
+ payRate: n.payRate,
71
73
  overtime: { maxHoursPerMonth: c },
72
- workingHours: i
74
+ workingHours: o
73
75
  });
74
76
  v.payRate = structuredClone(s.payRate), v.otCapHours = s.overtime.maxHoursPerMonth, v.workingHours = structuredClone(s.workingHours), d.value = !1;
75
77
  }
76
- return { isOpen: d, activeSection: a, draft: r, dirty: S, loading: t, load: C, open: y, close: P, discard: D, save: R };
78
+ return { isOpen: d, activeSection: a, draft: n, dirty: S, loading: t, load: C, open: y, close: P, discard: D, save: R };
77
79
  }
78
- function ee(l, d = {}) {
79
- const a = w(!1), r = w(""), t = w(/* @__PURE__ */ new Set()), u = w(!1), C = w(null), y = N(
80
+ function ee(r, d = {}) {
81
+ const a = w(!1), n = w(""), t = w(/* @__PURE__ */ new Set()), u = w(!1), C = w(null), y = E(
80
82
  () => {
81
- var i;
82
- return ((i = l.options.value.find((s) => s.value === l.outletId.value)) == null ? void 0 : i.label) ?? "";
83
+ var o;
84
+ return ((o = r.options.value.find((s) => s.value === r.outletId.value)) == null ? void 0 : o.label) ?? "";
83
85
  }
84
- ), S = N(() => {
85
- const i = r.value.trim().toLowerCase();
86
- return l.options.value.filter(
87
- (s) => s.value !== l.outletId.value && (!i || s.label.toLowerCase().includes(i))
86
+ ), S = E(() => {
87
+ const o = n.value.trim().toLowerCase();
88
+ return r.options.value.filter(
89
+ (s) => s.value !== r.outletId.value && (!o || s.label.toLowerCase().includes(o))
88
90
  );
89
91
  });
90
92
  function P() {
91
- r.value = "", t.value = /* @__PURE__ */ new Set(), u.value = !1, C.value = null, a.value = !0;
93
+ n.value = "", t.value = /* @__PURE__ */ new Set(), u.value = !1, C.value = null, a.value = !0;
92
94
  }
93
95
  function D() {
94
96
  a.value = !1;
95
97
  }
96
- function R(i) {
98
+ function R(o) {
97
99
  const s = new Set(t.value);
98
- s.has(i) ? s.delete(i) : s.add(i), t.value = s;
100
+ s.has(o) ? s.delete(o) : s.add(o), t.value = s;
99
101
  }
100
102
  async function c() {
101
- var s, n;
102
- const i = [...t.value];
103
- if (!(!i.length || u.value)) {
103
+ var s, i;
104
+ const o = [...t.value];
105
+ if (!(!o.length || u.value)) {
104
106
  u.value = !0;
105
107
  try {
106
108
  await Promise.all(
107
- i.map(
108
- (O) => E.saveSettings(O, {
109
+ o.map(
110
+ (O) => A.saveSettings(O, {
109
111
  payRate: v.payRate,
110
112
  overtime: { maxHoursPerMonth: v.otCapHours },
111
113
  workingHours: v.workingHours
112
114
  })
113
115
  )
114
- ), C.value = i.length, (s = d.notify) == null || s.call(
116
+ ), C.value = o.length, (s = d.notify) == null || s.call(
115
117
  d,
116
- `Setup copied to ${i.length} outlet${i.length === 1 ? "" : "s"}`,
118
+ `Setup copied to ${o.length} outlet${o.length === 1 ? "" : "s"}`,
117
119
  "success"
118
120
  );
119
121
  } catch (O) {
120
- (n = d.notify) == null || n.call(
122
+ (i = d.notify) == null || i.call(
121
123
  d,
122
124
  O instanceof Error ? O.message : "Could not clone outlet setup",
123
125
  "error"
@@ -129,7 +131,7 @@ function ee(l, d = {}) {
129
131
  }
130
132
  return {
131
133
  open: a,
132
- query: r,
134
+ query: n,
133
135
  selected: t,
134
136
  saving: u,
135
137
  done: C,
@@ -155,13 +157,13 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
155
157
  props: {
156
158
  modal: {}
157
159
  },
158
- setup(l) {
160
+ setup(r) {
159
161
  return (d, a) => (p(), I(F, {
160
- open: l.modal.open.value,
162
+ open: r.modal.open.value,
161
163
  "panel-class": "ce-modal",
162
164
  "panel-style": "width: min(460px, 95vw)",
163
165
  "labelled-by": "schedule-clone-title",
164
- onClose: a[5] || (a[5] = (r) => l.modal.close())
166
+ onClose: a[5] || (a[5] = (n) => r.modal.close())
165
167
  }, {
166
168
  default: b(() => [
167
169
  e("div", se, [
@@ -176,7 +178,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
176
178
  class: "ce-close-x",
177
179
  type: "button",
178
180
  "aria-label": "Close",
179
- onClick: a[0] || (a[0] = (r) => l.modal.close())
181
+ onClick: a[0] || (a[0] = (n) => r.modal.close())
180
182
  }, {
181
183
  default: b(() => [...a[6] || (a[6] = [
182
184
  e("svg", {
@@ -196,10 +198,10 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
196
198
  })
197
199
  ]),
198
200
  e("div", te, [
199
- l.modal.done.value === null ? (p(), m(L, { key: 0 }, [
201
+ r.modal.done.value === null ? (p(), m(L, { key: 0 }, [
200
202
  e("div", ae, [
201
203
  a[8] || (a[8] = H(" Copy ", -1)),
202
- e("b", null, h(l.modal.sourceLabel.value), 1),
204
+ e("b", null, h(r.modal.sourceLabel.value), 1),
203
205
  a[9] || (a[9] = H("'s pay rates to: ", -1))
204
206
  ]),
205
207
  e("div", oe, [
@@ -225,32 +227,32 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
225
227
  })
226
228
  ], -1)),
227
229
  f(e("input", {
228
- "onUpdate:modelValue": a[1] || (a[1] = (r) => l.modal.query.value = r),
230
+ "onUpdate:modelValue": a[1] || (a[1] = (n) => r.modal.query.value = n),
229
231
  type: "search",
230
232
  placeholder: "Search outlets",
231
233
  "aria-label": "Search outlets",
232
234
  autocomplete: "off"
233
235
  }, null, 512), [
234
- [g, l.modal.query.value]
236
+ [g, r.modal.query.value]
235
237
  ])
236
238
  ]),
237
239
  e("div", le, [
238
- (p(!0), m(L, null, V(l.modal.targets.value, (r) => (p(), m("label", {
239
- key: r.value,
240
+ (p(!0), m(L, null, V(r.modal.targets.value, (n) => (p(), m("label", {
241
+ key: n.value,
240
242
  class: "asg-row"
241
243
  }, [
242
244
  e("input", {
243
245
  type: "checkbox",
244
246
  class: "sch-checkbox",
245
247
  "data-platform": "desktop",
246
- checked: l.modal.selected.value.has(r.value),
247
- onChange: (t) => l.modal.toggle(r.value)
248
+ checked: r.modal.selected.value.has(n.value),
249
+ onChange: (t) => r.modal.toggle(n.value)
248
250
  }, null, 40, re),
249
251
  e("span", ne, [
250
- e("span", ie, h(r.label), 1)
252
+ e("span", ie, h(n.label), 1)
251
253
  ])
252
254
  ]))), 128)),
253
- l.modal.targets.value.length ? A("", !0) : (p(), m("div", ue, h(l.modal.query.value ? "No outlet matches that search." : "No other outlets."), 1))
255
+ r.modal.targets.value.length ? N("", !0) : (p(), m("div", ue, h(r.modal.query.value ? "No outlet matches that search." : "No other outlets."), 1))
254
256
  ]),
255
257
  a[11] || (a[11] = e("div", {
256
258
  class: "ce-hint",
@@ -263,20 +265,20 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
263
265
  }, "✓", -1)),
264
266
  e("div", pe, [
265
267
  a[12] || (a[12] = e("b", null, "Pay rates copied", -1)),
266
- e("small", null, "Sent to " + h(l.modal.done.value) + " outlet" + h(l.modal.done.value === 1 ? "" : "s"), 1)
268
+ e("small", null, "Sent to " + h(r.modal.done.value) + " outlet" + h(r.modal.done.value === 1 ? "" : "s"), 1)
267
269
  ])
268
270
  ]))
269
271
  ]),
270
272
  e("div", ve, [
271
- e("div", me, h(l.modal.done.value === null && l.modal.selected.value.size ? `${l.modal.selected.value.size} outlet${l.modal.selected.value.size === 1 ? "" : "s"} selected` : ""), 1),
273
+ e("div", me, h(r.modal.done.value === null && r.modal.selected.value.size ? `${r.modal.selected.value.size} outlet${r.modal.selected.value.size === 1 ? "" : "s"} selected` : ""), 1),
272
274
  e("div", ce, [
273
- l.modal.done.value === null ? (p(), m(L, { key: 0 }, [
275
+ r.modal.done.value === null ? (p(), m(L, { key: 0 }, [
274
276
  k(x, {
275
277
  hierarchy: "secondary",
276
278
  size: "sm",
277
279
  class: "am-btn am-btn-sec",
278
280
  type: "button",
279
- onClick: a[2] || (a[2] = (r) => l.modal.close())
281
+ onClick: a[2] || (a[2] = (n) => r.modal.close())
280
282
  }, {
281
283
  default: b(() => [...a[14] || (a[14] = [
282
284
  H(" Cancel ", -1)
@@ -288,11 +290,11 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
288
290
  size: "sm",
289
291
  class: "am-btn am-btn-primary",
290
292
  type: "button",
291
- disabled: !l.modal.selected.value.size || l.modal.saving.value,
292
- onClick: a[3] || (a[3] = (r) => l.modal.confirm())
293
+ disabled: !r.modal.selected.value.size || r.modal.saving.value,
294
+ onClick: a[3] || (a[3] = (n) => r.modal.confirm())
293
295
  }, {
294
296
  default: b(() => [
295
- H(h(l.modal.saving.value ? "Copying…" : "Copy setup"), 1)
297
+ H(h(r.modal.saving.value ? "Copying…" : "Copy setup"), 1)
296
298
  ]),
297
299
  _: 1
298
300
  }, 8, ["disabled"])
@@ -302,7 +304,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
302
304
  size: "sm",
303
305
  class: "am-btn am-btn-primary",
304
306
  type: "button",
305
- onClick: a[4] || (a[4] = (r) => l.modal.close())
307
+ onClick: a[4] || (a[4] = (n) => r.modal.close())
306
308
  }, {
307
309
  default: b(() => [...a[15] || (a[15] = [
308
310
  H(" Done ", -1)
@@ -322,30 +324,30 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
322
324
  key: 0,
323
325
  id: "sp-payrates",
324
326
  class: "sp-sec"
325
- }, Pe = { class: "sp-card" }, De = { class: "sp-row" }, Re = { class: "sp-field" }, Oe = { class: "sp-row" }, Me = { class: "sp-field" }, $e = { class: "sp-row" }, Le = { class: "sp-field" }, Ne = { class: "sp-card" }, Ae = { class: "sp-row" }, Ee = { class: "sp-field" }, Ie = { class: "sp-row" }, Ue = { class: "sp-field" }, Te = {
327
+ }, Pe = { class: "sp-card" }, De = { class: "sp-row" }, Re = { class: "sp-field" }, Oe = { class: "sp-row" }, Me = { class: "sp-field" }, $e = { class: "sp-row" }, Le = { class: "sp-field" }, Ee = { class: "sp-card" }, Ne = { class: "sp-row" }, Ae = { class: "sp-field" }, Ie = { class: "sp-row" }, Ue = { class: "sp-field" }, Te = {
326
328
  key: 1,
327
329
  id: "sp-working-hours",
328
330
  class: "sp-sec"
329
- }, Ve = { class: "sp-card" }, Be = { class: "sp-row" }, ze = { class: "sp-field" }, We = { class: "sp-row" }, Ye = { class: "sp-field" }, qe = { class: "sp-row" }, Ge = { class: "sp-field" }, Fe = {
331
+ }, Ve = { class: "sp-card" }, We = { class: "sp-row" }, Be = { class: "sp-field" }, ze = { class: "sp-row" }, Ye = { class: "sp-field" }, qe = { class: "sp-row" }, Ge = { class: "sp-field" }, Fe = {
330
332
  key: 2,
331
333
  id: "sp-overtime",
332
334
  class: "sp-sec"
333
335
  }, je = { class: "sp-card" }, Je = { class: "sp-row" }, Ke = { class: "sp-save-txt" }, Qe = { key: 0 }, ls = /* @__PURE__ */ T({
334
336
  __name: "ScheduleGeneralPage",
335
- setup(l) {
337
+ setup(r) {
336
338
  const d = w(null);
337
339
  j(d);
338
- const a = W(), r = Y(), t = _(), u = J(), C = ee(u, {
339
- notify: (i, s) => r.open({ message: i, type: s })
340
+ const a = z(), n = Y(), t = _(), u = J(), C = ee(u, {
341
+ notify: (o, s) => n.open({ message: o, type: s })
340
342
  }), y = w(!1);
341
- z(async () => {
343
+ B(async () => {
342
344
  await u.resolve() && await K(/* @__PURE__ */ new Date()), await t.load(), t.open();
343
345
  });
344
- const S = N(
346
+ const S = E(
345
347
  () => u.options.value.length ? u.options.value : [{ value: "", label: "No outlet selected", disabled: !0 }]
346
348
  );
347
- async function P(i) {
348
- t.dirty.value || await u.switchTo(i, /* @__PURE__ */ new Date()) && (await t.load(), t.open());
349
+ async function P(o) {
350
+ t.dirty.value || await u.switchTo(o, /* @__PURE__ */ new Date()) && (await t.load(), t.open());
349
351
  }
350
352
  function D() {
351
353
  t.close() && a.push({ name: q.SCHEDULE });
@@ -359,15 +361,15 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
359
361
  }
360
362
  async function c() {
361
363
  try {
362
- await t.save(), r.open({ message: "General settings saved", type: "success" });
363
- } catch (i) {
364
- r.open({
365
- message: i instanceof Error ? i.message : "Could not save general settings",
364
+ await t.save(), n.open({ message: "General settings saved", type: "success" });
365
+ } catch (o) {
366
+ n.open({
367
+ message: o instanceof Error ? o.message : "Could not save general settings",
366
368
  type: "error"
367
369
  });
368
370
  }
369
371
  }
370
- return (i, s) => (p(), m("div", {
372
+ return (o, s) => (p(), m("div", {
371
373
  ref_key: "rootEl",
372
374
  ref: d,
373
375
  class: "sch"
@@ -410,9 +412,9 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
410
412
  class: "outlet-sel",
411
413
  "aria-label": "Outlet being configured",
412
414
  searchable: "",
413
- disabled: o(t).dirty.value || o(t).loading.value,
414
- title: o(t).dirty.value ? "Save or discard changes before switching outlets" : "Which outlet these pay rates apply to",
415
- "model-value": o(u).outletId.value,
415
+ disabled: l(t).dirty.value || l(t).loading.value,
416
+ title: l(t).dirty.value ? "Save or discard changes before switching outlets" : "Which outlet these pay rates apply to",
417
+ "model-value": l(u).outletId.value,
416
418
  options: S.value,
417
419
  "onUpdate:modelValue": P
418
420
  }, null, 8, ["disabled", "title", "model-value", "options"]),
@@ -421,9 +423,9 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
421
423
  size: "sm",
422
424
  class: "outlet-clone",
423
425
  type: "button",
424
- disabled: o(t).dirty.value || o(t).loading.value || !o(u).outletId.value,
425
- title: o(t).dirty.value ? "Save or discard changes before cloning" : "Copy this outlet's pay rates to other outlets",
426
- onClick: s[0] || (s[0] = (n) => o(C).openModal())
426
+ disabled: l(t).dirty.value || l(t).loading.value || !l(u).outletId.value,
427
+ title: l(t).dirty.value ? "Save or discard changes before cloning" : "Copy this outlet's pay rates to other outlets",
428
+ onClick: s[0] || (s[0] = (i) => l(C).openModal())
427
429
  }, {
428
430
  default: b(() => [...s[13] || (s[13] = [
429
431
  e("svg", {
@@ -457,17 +459,17 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
457
459
  ]),
458
460
  e("div", ke, [
459
461
  e("nav", be, [
460
- (p(!0), m(L, null, V(o(Z), (n) => (p(), m("button", {
461
- key: n.key,
462
+ (p(!0), m(L, null, V(l(Z), (i) => (p(), m("button", {
463
+ key: i.key,
462
464
  type: "button",
463
- class: U(["sch-tab sp-tab", { active: o(t).activeSection.value === n.key }]),
465
+ class: U(["sch-tab sp-tab", { active: l(t).activeSection.value === i.key }]),
464
466
  "data-active": "false",
465
- onClick: (O) => o(t).activeSection.value = n.key
466
- }, h(n.label), 11, He))), 128))
467
+ onClick: (O) => l(t).activeSection.value = i.key
468
+ }, h(i.label), 11, He))), 128))
467
469
  ]),
468
470
  e("div", Ce, [
469
471
  e("div", xe, [
470
- o(t).activeSection.value === "payrates" ? (p(), m("section", Se, [
472
+ l(t).activeSection.value === "payrates" ? (p(), m("section", Se, [
471
473
  s[29] || (s[29] = e("div", { class: "sp-sec-head" }, [
472
474
  e("div", { class: "sp-panel-title" }, "Pay rates")
473
475
  ], -1)),
@@ -484,7 +486,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
484
486
  ], -1)),
485
487
  e("div", Re, [
486
488
  f(e("input", {
487
- "onUpdate:modelValue": s[1] || (s[1] = (n) => o(t).draft.payRate.NORMAL.overtime = n),
489
+ "onUpdate:modelValue": s[1] || (s[1] = (i) => l(t).draft.payRate.NORMAL.overtime = i),
488
490
  class: "sch-input sp-num",
489
491
  type: "number",
490
492
  min: "1",
@@ -494,7 +496,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
494
496
  }, null, 512), [
495
497
  [
496
498
  g,
497
- o(t).draft.payRate.NORMAL.overtime,
499
+ l(t).draft.payRate.NORMAL.overtime,
498
500
  void 0,
499
501
  { number: !0 }
500
502
  ]
@@ -509,7 +511,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
509
511
  ], -1)),
510
512
  e("div", Me, [
511
513
  f(e("input", {
512
- "onUpdate:modelValue": s[2] || (s[2] = (n) => o(t).draft.payRate.REST_DAY.overtime = n),
514
+ "onUpdate:modelValue": s[2] || (s[2] = (i) => l(t).draft.payRate.REST_DAY.overtime = i),
513
515
  class: "sch-input sp-num",
514
516
  type: "number",
515
517
  min: "1",
@@ -519,7 +521,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
519
521
  }, null, 512), [
520
522
  [
521
523
  g,
522
- o(t).draft.payRate.REST_DAY.overtime,
524
+ l(t).draft.payRate.REST_DAY.overtime,
523
525
  void 0,
524
526
  { number: !0 }
525
527
  ]
@@ -534,7 +536,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
534
536
  ], -1)),
535
537
  e("div", Le, [
536
538
  f(e("input", {
537
- "onUpdate:modelValue": s[3] || (s[3] = (n) => o(t).draft.payRate.PUBLIC_HOLIDAY.overtime = n),
539
+ "onUpdate:modelValue": s[3] || (s[3] = (i) => l(t).draft.payRate.PUBLIC_HOLIDAY.overtime = i),
538
540
  class: "sch-input sp-num",
539
541
  type: "number",
540
542
  min: "1",
@@ -544,7 +546,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
544
546
  }, null, 512), [
545
547
  [
546
548
  g,
547
- o(t).draft.payRate.PUBLIC_HOLIDAY.overtime,
549
+ l(t).draft.payRate.PUBLIC_HOLIDAY.overtime,
548
550
  void 0,
549
551
  { number: !0 }
550
552
  ]
@@ -553,19 +555,19 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
553
555
  ])
554
556
  ])
555
557
  ]),
556
- e("div", Ne, [
558
+ e("div", Ee, [
557
559
  s[28] || (s[28] = e("div", { class: "sp-card-head" }, [
558
560
  e("div", { class: "sp-card-title" }, "Regular rate"),
559
561
  e("div", { class: "sp-card-note" }, "Multiplier on ordinary hours")
560
562
  ], -1)),
561
- e("div", Ae, [
563
+ e("div", Ne, [
562
564
  s[25] || (s[25] = e("div", { class: "sp-row-main" }, [
563
565
  e("div", { class: "sp-row-label" }, "Off day"),
564
566
  e("div", { class: "sp-row-hint" }, "Ordinary hours worked on the person's off day.")
565
567
  ], -1)),
566
- e("div", Ee, [
568
+ e("div", Ae, [
567
569
  f(e("input", {
568
- "onUpdate:modelValue": s[4] || (s[4] = (n) => o(t).draft.payRate.REST_DAY.regular = n),
570
+ "onUpdate:modelValue": s[4] || (s[4] = (i) => l(t).draft.payRate.REST_DAY.regular = i),
569
571
  class: "sch-input sp-num",
570
572
  type: "number",
571
573
  min: "1",
@@ -575,7 +577,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
575
577
  }, null, 512), [
576
578
  [
577
579
  g,
578
- o(t).draft.payRate.REST_DAY.regular,
580
+ l(t).draft.payRate.REST_DAY.regular,
579
581
  void 0,
580
582
  { number: !0 }
581
583
  ]
@@ -590,7 +592,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
590
592
  ], -1)),
591
593
  e("div", Ue, [
592
594
  f(e("input", {
593
- "onUpdate:modelValue": s[5] || (s[5] = (n) => o(t).draft.payRate.PUBLIC_HOLIDAY.regular = n),
595
+ "onUpdate:modelValue": s[5] || (s[5] = (i) => l(t).draft.payRate.PUBLIC_HOLIDAY.regular = i),
594
596
  class: "sch-input sp-num",
595
597
  type: "number",
596
598
  min: "1",
@@ -600,7 +602,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
600
602
  }, null, 512), [
601
603
  [
602
604
  g,
603
- o(t).draft.payRate.PUBLIC_HOLIDAY.regular,
605
+ l(t).draft.payRate.PUBLIC_HOLIDAY.regular,
604
606
  void 0,
605
607
  { number: !0 }
606
608
  ]
@@ -609,7 +611,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
609
611
  ])
610
612
  ])
611
613
  ])
612
- ])) : o(t).activeSection.value === "workingHours" ? (p(), m("section", Te, [
614
+ ])) : l(t).activeSection.value === "workingHours" ? (p(), m("section", Te, [
613
615
  s[38] || (s[38] = e("div", { class: "sp-sec-head" }, [
614
616
  e("div", { class: "sp-panel-title" }, "Working hours")
615
617
  ], -1)),
@@ -619,13 +621,13 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
619
621
  e("div", { class: "sp-card-title" }, "Default working hours"),
620
622
  e("div", { class: "sp-card-note" }, "Used as the employee default")
621
623
  ], -1)),
622
- e("div", Be, [
624
+ e("div", We, [
623
625
  s[32] || (s[32] = e("div", { class: "sp-row-main" }, [
624
626
  e("div", { class: "sp-row-label" }, "Min hours per day")
625
627
  ], -1)),
626
- e("div", ze, [
628
+ e("div", Be, [
627
629
  f(e("input", {
628
- "onUpdate:modelValue": s[6] || (s[6] = (n) => o(t).draft.workingHours.minHoursPerDay = n),
630
+ "onUpdate:modelValue": s[6] || (s[6] = (i) => l(t).draft.workingHours.minHoursPerDay = i),
629
631
  class: "sch-input sp-num",
630
632
  type: "number",
631
633
  min: "0",
@@ -636,7 +638,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
636
638
  }, null, 512), [
637
639
  [
638
640
  g,
639
- o(t).draft.workingHours.minHoursPerDay,
641
+ l(t).draft.workingHours.minHoursPerDay,
640
642
  void 0,
641
643
  { number: !0 }
642
644
  ]
@@ -644,13 +646,13 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
644
646
  s[31] || (s[31] = e("span", { class: "sp-unit" }, "hours / day", -1))
645
647
  ])
646
648
  ]),
647
- e("div", We, [
649
+ e("div", ze, [
648
650
  s[34] || (s[34] = e("div", { class: "sp-row-main" }, [
649
651
  e("div", { class: "sp-row-label" }, "Max hours per day")
650
652
  ], -1)),
651
653
  e("div", Ye, [
652
654
  f(e("input", {
653
- "onUpdate:modelValue": s[7] || (s[7] = (n) => o(t).draft.workingHours.maxHoursPerDay = n),
655
+ "onUpdate:modelValue": s[7] || (s[7] = (i) => l(t).draft.workingHours.maxHoursPerDay = i),
654
656
  class: "sch-input sp-num",
655
657
  type: "number",
656
658
  min: "0",
@@ -661,7 +663,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
661
663
  }, null, 512), [
662
664
  [
663
665
  g,
664
- o(t).draft.workingHours.maxHoursPerDay,
666
+ l(t).draft.workingHours.maxHoursPerDay,
665
667
  void 0,
666
668
  { number: !0 }
667
669
  ]
@@ -675,7 +677,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
675
677
  ], -1)),
676
678
  e("div", Ge, [
677
679
  f(e("input", {
678
- "onUpdate:modelValue": s[8] || (s[8] = (n) => o(t).draft.workingHours.maxHoursPerWeek = n),
680
+ "onUpdate:modelValue": s[8] || (s[8] = (i) => l(t).draft.workingHours.maxHoursPerWeek = i),
679
681
  class: "sch-input sp-num",
680
682
  type: "number",
681
683
  min: "0",
@@ -686,7 +688,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
686
688
  }, null, 512), [
687
689
  [
688
690
  g,
689
- o(t).draft.workingHours.maxHoursPerWeek,
691
+ l(t).draft.workingHours.maxHoursPerWeek,
690
692
  void 0,
691
693
  { number: !0 }
692
694
  ]
@@ -695,7 +697,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
695
697
  ])
696
698
  ])
697
699
  ])
698
- ])) : o(t).activeSection.value === "overtime" ? (p(), m("section", Fe, [
700
+ ])) : l(t).activeSection.value === "overtime" ? (p(), m("section", Fe, [
699
701
  s[42] || (s[42] = e("div", { class: "sp-sec-head" }, [
700
702
  e("div", { class: "sp-panel-title" }, "Overtime")
701
703
  ], -1)),
@@ -711,7 +713,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
711
713
  e("div", { class: "sp-row-hint" }, " Hours per person per month. Auto-Schedule never exceeds it. ")
712
714
  ], -1)),
713
715
  f(e("input", {
714
- "onUpdate:modelValue": s[9] || (s[9] = (n) => o(t).draft.otCapHours = n),
716
+ "onUpdate:modelValue": s[9] || (s[9] = (i) => l(t).draft.otCapHours = i),
715
717
  class: "sch-input sp-num",
716
718
  type: "number",
717
719
  min: "0",
@@ -722,29 +724,29 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
722
724
  }, null, 512), [
723
725
  [
724
726
  g,
725
- o(t).draft.otCapHours,
727
+ l(t).draft.otCapHours,
726
728
  void 0,
727
729
  { number: !0 }
728
730
  ]
729
731
  ])
730
732
  ])
731
733
  ])
732
- ])) : A("", !0)
734
+ ])) : N("", !0)
733
735
  ])
734
736
  ]),
735
737
  e("div", {
736
- class: U(["sp-save", { dirty: o(t).dirty.value, arming: y.value }])
738
+ class: U(["sp-save", { dirty: l(t).dirty.value, arming: y.value }])
737
739
  }, [
738
740
  e("div", Ke, [
739
741
  H(h(y.value ? "Discard unsaved changes?" : "Unsaved changes") + " ", 1),
740
- y.value ? A("", !0) : (p(), m("span", Qe, "— save or discard before leaving."))
742
+ y.value ? N("", !0) : (p(), m("span", Qe, "— save or discard before leaving."))
741
743
  ]),
742
744
  k(x, {
743
745
  hierarchy: "secondary",
744
746
  size: "sm",
745
747
  class: "am-btn am-btn-sec",
746
748
  type: "button",
747
- onClick: s[10] || (s[10] = (n) => R())
749
+ onClick: s[10] || (s[10] = (i) => R())
748
750
  }, {
749
751
  default: b(() => [
750
752
  H(h(y.value ? "Confirm discard" : "Discard"), 1)
@@ -756,7 +758,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
756
758
  size: "sm",
757
759
  class: "am-btn am-btn-primary",
758
760
  type: "button",
759
- onClick: s[11] || (s[11] = (n) => c())
761
+ onClick: s[11] || (s[11] = (i) => c())
760
762
  }, {
761
763
  default: b(() => [...s[44] || (s[44] = [
762
764
  H(" Save changes ", -1)
@@ -767,7 +769,7 @@ const se = { class: "am-head" }, te = { class: "ce-body" }, ae = {
767
769
  ])
768
770
  ])
769
771
  ]),
770
- k(ye, { modal: o(C) }, null, 8, ["modal"])
772
+ k(ye, { modal: l(C) }, null, 8, ["modal"])
771
773
  ], 512));
772
774
  }
773
775
  });