@feedmepos/mf-hrm-portal 2.3.0-dev.13 → 2.3.0-dev.14

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 (40) hide show
  1. package/dist/{ApprovalCodeList-D3egZFML.js → ApprovalCodeList-C9dauQ81.js} +4 -4
  2. package/dist/{AuditLogList-BzbaEsSj.js → AuditLogList-zW_N_ECT.js} +17 -18
  3. package/dist/{ConditionBuilderForm.vue_vue_type_script_setup_true_lang-Do52KbKm.js → ConditionBuilderForm.vue_vue_type_script_setup_true_lang-DJuO1qPX.js} +2 -2
  4. package/dist/{EmployeeList-BiM8dRwZ.js → EmployeeList-8jkHTd7q.js} +255 -267
  5. package/dist/{FormItem.vue_vue_type_script_setup_true_lang-CUnlKsxk.js → FormItem.vue_vue_type_script_setup_true_lang-CJc_g0tW.js} +6 -6
  6. package/dist/{GrantUserList-Dj2ms20E.js → GrantUserList-Dj55GA7O.js} +5 -5
  7. package/dist/{Main-C2z7Jf9A.js → Main-0TfvGJ4N.js} +5 -5
  8. package/dist/{Main-DmpwTPaI.js → Main-BQNkTyET.js} +9 -9
  9. package/dist/{Main-DklZWoKj.js → Main-CuUG6svQ.js} +2 -2
  10. package/dist/{PermissionSetList-C-qgCcRO.js → PermissionSetList-BsLi-TOK.js} +5 -5
  11. package/dist/{PortalPermissionEditor.vue_vue_type_script_setup_true_lang-ggZB5zWW.js → PortalPermissionEditor.vue_vue_type_script_setup_true_lang-C2l8nWx2.js} +1014 -1014
  12. package/dist/{RoleList-ohfin77B.js → RoleList-DLDcyVWT.js} +7 -7
  13. package/dist/{ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-diuWysro.js → ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-CUXUPfRc.js} +190 -181
  14. package/dist/{ScheduleGeneralPage-aCljFf21.js → ScheduleGeneralPage-BhYI6O9g.js} +132 -133
  15. package/dist/{ScheduleModal.vue_vue_type_script_setup_true_lang-x_-BYkcc.js → ScheduleModal.vue_vue_type_script_setup_true_lang-BLBLBtNG.js} +669 -646
  16. package/dist/{SchedulePage-DdMHF6kX.js → SchedulePage-DPU4taJt.js} +7407 -7359
  17. package/dist/{SchedulePositionPage-CID91orD.js → SchedulePositionPage-Byt6nmUj.js} +82 -84
  18. package/dist/{SelectFilter-CG13h83-.js → SelectFilter-1fh00OZW.js} +1 -1
  19. package/dist/{TeamMemberList-DJIKL4dE.js → TeamMemberList-CyUX8Afk.js} +35 -36
  20. package/dist/{TimesheetList-BPXWPNfT.js → TimesheetList-Q4FeNgOT.js} +52 -53
  21. package/dist/{TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-DVcV0knM.js → TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-C3iU4Zmc.js} +2 -2
  22. package/dist/{app-Bz8568j8.js → app-TuHQoM7K.js} +676 -666
  23. package/dist/app.js +1 -1
  24. package/dist/{dayjs.min-DhSRKSu4.js → dayjs.min-DXnA8GYn.js} +1 -1
  25. package/dist/{employee-BM44u8b-.js → employee-Ctnil3cD.js} +3 -3
  26. package/dist/{iteration-BHDxs89d.js → iteration-BxOzv27y.js} +1 -1
  27. package/dist/{lodash-DgSYLwYD.js → lodash-CKT_RxJs.js} +1 -1
  28. package/dist/object-Dwyg2LgX.js +16 -0
  29. package/dist/{role-BMJ7LEHN.js → role-CNEJPyaD.js} +1 -1
  30. package/dist/{rule-CCo7_ckA.js → rule-FbuHv6Gh.js} +2 -2
  31. package/dist/src/views/scheduling/composables/onboarding-types.d.ts +2 -1
  32. package/dist/src/views/scheduling/composables/useScheduleCostRail.d.ts +3 -1
  33. package/dist/src/views/scheduling/composables/useScheduleOnboardingEmployees.d.ts +2 -0
  34. package/dist/src/views/scheduling/composables/useScheduleOnboardingWizard.d.ts +3 -1
  35. package/dist/src/views/scheduling/data.d.ts +17 -0
  36. package/dist/style.css +1 -1
  37. package/dist/tsconfig.app.tsbuildinfo +1 -1
  38. package/dist/{useReportPermissions-C_Cd__n1.js → useReportPermissions-lemBrd1S.js} +3 -3
  39. package/package.json +1 -1
  40. package/dist/_plugin-vue_export-helper-CHgC5LLL.js +0 -9
@@ -1,36 +1,24 @@
1
- import { toRaw as Ke, defineComponent as Fe, ref as v, computed as h, watch as X, resolveComponent as E, createElementBlock as ee, openBlock as g, Fragment as Ie, renderSlot as Ge, createVNode as i, unref as l, withCtx as y, createElementVNode as f, createBlock as I, createCommentVNode as j, toDisplayString as q, onUnmounted as Be, isRef as we, normalizeClass as ke, createTextVNode as ge, withModifiers as je, resolveDynamicComponent as qe, h as ie } from "vue";
2
- import { useI18n as Re, useCoreStore as He } from "@feedmepos/mf-common";
3
- import { useSnackbar as Me, components as $e, useDialog as Je, useBreakpoints as We } from "@feedmepos/ui-library";
4
- import { S as ue } from "./SelectFilter-CG13h83-.js";
5
- import { _ as Qe, a as Ye } from "./app-Bz8568j8.js";
6
- import { _ as xe, u as Ze, H as Xe } from "./FormItem.vue_vue_type_script_setup_true_lang-CUnlKsxk.js";
7
- import { _ as ea } from "./ResponsiveContextMenu.vue_vue_type_script_setup_true_lang-mSJFKo7r.js";
8
- import { _ as aa } from "./TableEmptyState.vue_vue_type_script_setup_true_lang-IfAZmWr0.js";
9
- import { s as la, _ as sa, a as ta, b as oa, c as Ee } from "./PasscodePinField.vue_vue_type_script_setup_true_lang-CqG0v0Sz.js";
10
- import { u as ra } from "./useDebounce-B8ZPVS5C.js";
11
- import { n as na } from "./string-VNuQNweN.js";
12
- import { u as Le, E as ia } from "./employee-BM44u8b-.js";
13
- import { u as Pe } from "./restaurant-BbYRA_IT.js";
14
- import { l as ua } from "./lodash-DgSYLwYD.js";
15
- import { _ as Ve } from "./FormSection.vue_vue_type_script_setup_true_lang-DknXTYiK.js";
16
- import { u as ca } from "./useDiscardConfirm-CzZSPyvh.js";
17
- import { u as De } from "./useLoading-Ch1AUYT1.js";
18
- import { u as he } from "./role-BMJ7LEHN.js";
1
+ import { defineComponent as Ce, ref as v, computed as h, watch as Z, resolveComponent as E, createElementBlock as X, openBlock as g, Fragment as Ue, renderSlot as Ke, createVNode as i, unref as l, withCtx as y, createElementVNode as f, createBlock as I, createCommentVNode as B, toDisplayString as j, onUnmounted as Oe, isRef as be, normalizeClass as ke, createTextVNode as ye, withModifiers as Ge, resolveDynamicComponent as Be, h as ne } from "vue";
2
+ import { useI18n as Fe, useCoreStore as je } from "@feedmepos/mf-common";
3
+ import { useSnackbar as Ie, components as Me, useDialog as qe, useBreakpoints as He } from "@feedmepos/ui-library";
4
+ import { S as ie } from "./SelectFilter-1fh00OZW.js";
5
+ import { _ as We, b as Je, a as Qe } from "./app-TuHQoM7K.js";
6
+ import { _ as we, u as Ye, H as Ze } from "./FormItem.vue_vue_type_script_setup_true_lang-CJc_g0tW.js";
7
+ import { _ as Xe } from "./ResponsiveContextMenu.vue_vue_type_script_setup_true_lang-mSJFKo7r.js";
8
+ import { _ as ea } from "./TableEmptyState.vue_vue_type_script_setup_true_lang-IfAZmWr0.js";
9
+ import { s as aa, _ as la, a as sa, b as ta, c as xe } from "./PasscodePinField.vue_vue_type_script_setup_true_lang-CqG0v0Sz.js";
10
+ import { u as oa } from "./useDebounce-B8ZPVS5C.js";
11
+ import { n as ra } from "./string-VNuQNweN.js";
12
+ import { u as Re, E as na } from "./employee-Ctnil3cD.js";
13
+ import { u as $e } from "./restaurant-BbYRA_IT.js";
14
+ import { l as ia } from "./lodash-CKT_RxJs.js";
15
+ import { _ as Ee } from "./FormSection.vue_vue_type_script_setup_true_lang-DknXTYiK.js";
16
+ import { u as ua } from "./useDiscardConfirm-CzZSPyvh.js";
17
+ import { u as Le } from "./useLoading-Ch1AUYT1.js";
18
+ import { c as Ve } from "./object-Dwyg2LgX.js";
19
+ import { u as ge } from "./role-CNEJPyaD.js";
19
20
  /* empty css */
20
- import { _ as ma } from "./_plugin-vue_export-helper-CHgC5LLL.js";
21
- function Se($) {
22
- return JSON.parse(JSON.stringify($));
23
- }
24
- function Ce($) {
25
- if (typeof structuredClone > "u")
26
- return Se($);
27
- try {
28
- return structuredClone(Ke($));
29
- } catch {
30
- return Se($);
31
- }
32
- }
33
- const da = { class: "flex w-full items-center justify-between" }, pa = { class: "fm-typo-en-title-md-600" }, fa = { class: "space-y-40" }, va = { class: "flex flex-row gap-16" }, ya = { class: "space-y-16" }, ga = { class: "flex gap-8 items-center justify-start" }, Ue = 4, ha = /* @__PURE__ */ Fe({
21
+ const ma = { class: "flex w-full items-center justify-between" }, ca = { class: "fm-typo-en-title-md-600" }, da = { class: "space-y-40" }, pa = { class: "flex flex-row gap-16" }, fa = { class: "space-y-16" }, va = { class: "flex gap-8 items-center justify-start" }, Se = 4, ya = /* @__PURE__ */ Ce({
34
22
  __name: "EmployeeForm",
35
23
  props: {
36
24
  roleErrorMessage: {
@@ -39,30 +27,30 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
39
27
  }
40
28
  },
41
29
  emits: ["submitted"],
42
- setup($, { expose: ce, emit: n }) {
43
- const k = he(), d = Pe(), C = Le(), me = Me(), U = De(me), de = n, { t: c } = Re(), V = v(!1), R = v(!0);
44
- function O() {
30
+ setup(Pe, { expose: ue, emit: n }) {
31
+ const w = ge(), d = $e(), C = Re(), me = Ie(), U = Le(me), ce = n, { t: m } = Fe(), V = v(!1), M = v(!0);
32
+ function A() {
45
33
  return {
46
34
  restaurantId: "",
47
35
  roleId: ""
48
36
  };
49
37
  }
50
- function pe(u) {
38
+ function de(u) {
51
39
  if (!u) return _();
52
- const o = Ce(u);
40
+ const o = Ve(u);
53
41
  return {
54
42
  code: o.code ?? "",
55
43
  isMasterUser: o.isMasterUser ?? !1,
56
44
  name: o.name ?? "",
57
45
  passcode: o.passcode ?? "",
58
- restaurants: o.restaurants.length > 0 ? o.restaurants.map(({ restaurantId: w, roleId: S }) => ({
59
- restaurantId: w,
46
+ restaurants: o.restaurants.length > 0 ? o.restaurants.map(({ restaurantId: k, roleId: S }) => ({
47
+ restaurantId: k,
60
48
  roleId: S
61
- })) : [O()]
49
+ })) : [A()]
62
50
  };
63
51
  }
64
- const ae = (u) => {
65
- s.value = pe(u), b.value = Ce(s.value), J.value = u == null ? void 0 : u._id, F.value = [], s.value.passcode ? (F.value = s.value.passcode.split(""), P.value = !0) : P.value = !1, R.value = !u, V.value = !0;
52
+ const ee = (u) => {
53
+ s.value = de(u), b.value = Ve(s.value), H.value = u == null ? void 0 : u._id, F.value = [], s.value.passcode ? (F.value = s.value.passcode.split(""), L.value = !0) : L.value = !1, M.value = !u, V.value = !0;
66
54
  };
67
55
  function _() {
68
56
  return {
@@ -70,41 +58,41 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
70
58
  isMasterUser: !1,
71
59
  name: "",
72
60
  passcode: "",
73
- restaurants: [O()]
61
+ restaurants: [A()]
74
62
  };
75
63
  }
76
- const T = h(() => R.value ? c("hr.employee.form.add") : c("hr.employee.form.update")), H = h(() => R.value ? c("common.create") : c("common.update")), b = v(_()), s = v(_()), J = v(void 0), L = h(
77
- () => la(s.value.restaurants)
64
+ const T = h(() => M.value ? m("hr.employee.form.add") : m("hr.employee.form.update")), q = h(() => M.value ? m("common.create") : m("common.update")), b = v(_()), s = v(_()), H = v(void 0), $ = h(
65
+ () => aa(s.value.restaurants)
78
66
  );
79
- function le(u) {
67
+ function ae(u) {
80
68
  var o;
81
- return u ? !((o = d.restaurants.value.find((w) => w._id === u)) != null && o.managable) : !1;
69
+ return u ? !((o = d.restaurants.value.find((k) => k._id === u)) != null && o.managable) : !1;
82
70
  }
83
- function se(u) {
71
+ function le(u) {
84
72
  return u.isUsable;
85
73
  }
86
- const F = v([]), P = v(!1), z = v(!1), W = v(!1), te = h(() => L.value.length > 0);
87
- async function D() {
88
- if (te.value)
74
+ const F = v([]), L = v(!1), z = v(!1), W = v(!1), se = h(() => $.value.length > 0);
75
+ async function P() {
76
+ if (se.value)
89
77
  try {
90
78
  const u = await U.custom(
91
- () => ia.generateEmployeePasscode({
92
- restaurantIds: L.value,
93
- excludePosUserId: J.value
79
+ () => na.generateEmployeePasscode({
80
+ restaurantIds: $.value,
81
+ excludePosUserId: H.value
94
82
  }),
95
83
  { isLoading: W }
96
84
  );
97
- P.value = !1, F.value = u.split(""), s.value.passcode = u;
85
+ L.value = !1, F.value = u.split(""), s.value.passcode = u;
98
86
  } catch {
99
87
  }
100
88
  }
101
- const K = ca(
102
- () => !ua.isEqual(s.value, b.value),
89
+ const K = ua(
90
+ () => !ia.isEqual(s.value, b.value),
103
91
  () => {
104
92
  V.value = !1;
105
93
  }
106
94
  );
107
- async function fe() {
95
+ async function pe() {
108
96
  const u = {
109
97
  user: {
110
98
  name: s.value.name,
@@ -115,9 +103,9 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
115
103
  };
116
104
  s.value.isMasterUser ? await C.createMasterEmployee(u) : (delete u.user.code, await C.createEmployee(u));
117
105
  }
118
- async function Q() {
119
- var S, M;
120
- const u = b.value, o = J.value, w = {
106
+ async function J() {
107
+ var S, R;
108
+ const u = b.value, o = H.value, k = {
121
109
  user: {
122
110
  name: s.value.name,
123
111
  passcode: s.value.passcode
@@ -129,7 +117,7 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
129
117
  }))
130
118
  };
131
119
  if (!s.value.isMasterUser)
132
- await C.updateEmployee(o, w);
120
+ await C.updateEmployee(o, k);
133
121
  else {
134
122
  const x = {
135
123
  user: {
@@ -138,51 +126,51 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
138
126
  code: s.value.code
139
127
  },
140
128
  roles: s.value.restaurants,
141
- previousRoles: (M = u.restaurants) == null ? void 0 : M.map((N) => ({
142
- restaurantId: N.restaurantId,
143
- roleId: N.roleId
129
+ previousRoles: (R = u.restaurants) == null ? void 0 : R.map((D) => ({
130
+ restaurantId: D.restaurantId,
131
+ roleId: D.roleId
144
132
  }))
145
133
  };
146
134
  b.value.isMasterUser ? await C.updateMasterEmployee(o, x) : await C.migrateToMasterUser(o, x);
147
135
  }
148
136
  }
149
- async function G() {
150
- R.value ? await U.minor(
137
+ async function O() {
138
+ M.value ? await U.minor(
151
139
  async () => {
152
- await fe();
140
+ await pe();
153
141
  },
154
142
  {
155
- successMessage: c("hr.employee.create.successMessage"),
143
+ successMessage: m("hr.employee.create.successMessage"),
156
144
  isLoading: z
157
145
  }
158
146
  ) : await U.minor(
159
147
  async () => {
160
- await Q();
148
+ await J();
161
149
  },
162
150
  {
163
- successMessage: c("hr.employee.update.successMessage"),
151
+ successMessage: m("hr.employee.update.successMessage"),
164
152
  isLoading: z
165
153
  }
166
- ), de("submitted"), V.value = !1;
154
+ ), ce("submitted"), V.value = !1;
167
155
  }
168
- return X(
156
+ return Z(
169
157
  () => V.value,
170
158
  (u) => {
171
159
  }
172
- ), ce({
160
+ ), ue({
173
161
  show: V,
174
- trigger: ae
162
+ trigger: ee
175
163
  }), (u, o) => {
176
- const w = E("FmIcon"), S = E("FmSwitch"), M = E("FmTextField"), x = E("FmFormGroup"), N = E("fm-button"), oe = E("fm-side-sheet");
177
- return g(), ee(Ie, null, [
178
- Ge(u.$slots, "default", { trigger: ae }),
179
- i(oe, {
164
+ const k = E("FmIcon"), S = E("FmSwitch"), R = E("FmTextField"), x = E("FmFormGroup"), D = E("fm-button"), te = E("fm-side-sheet");
165
+ return g(), X(Ue, null, [
166
+ Ke(u.$slots, "default", { trigger: ee }),
167
+ i(te, {
180
168
  id: "unit-form",
181
169
  modelValue: V.value,
182
170
  "onUpdate:modelValue": o[9] || (o[9] = (t) => V.value = t),
183
- "is-container": l($e).FmForm,
171
+ "is-container": l(Me).FmForm,
184
172
  "is-container-props": {
185
- onValidationSuccess: G,
173
+ onValidationSuccess: O,
186
174
  blameFormChildOnValidationFailed: !0
187
175
  },
188
176
  "max-width": 960,
@@ -190,9 +178,9 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
190
178
  "onOn:clickedAway": l(K)
191
179
  }, {
192
180
  "side-sheet-header": y(() => [
193
- f("div", da, [
194
- f("p", pa, q(T.value), 1),
195
- i(w, {
181
+ f("div", ma, [
182
+ f("p", ca, j(T.value), 1),
183
+ i(k, {
196
184
  name: "close",
197
185
  size: "md",
198
186
  class: "cursor-pointer",
@@ -201,16 +189,16 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
201
189
  ])
202
190
  ]),
203
191
  "side-sheet-footer": y(() => [
204
- f("div", ga, [
205
- i(N, {
206
- label: H.value,
192
+ f("div", va, [
193
+ i(D, {
194
+ label: q.value,
207
195
  size: "lg",
208
196
  type: "submit",
209
197
  variant: "primary",
210
198
  disabled: z.value
211
199
  }, null, 8, ["label", "disabled"]),
212
- i(N, {
213
- label: l(c)("common.cancel"),
200
+ i(D, {
201
+ label: l(m)("common.cancel"),
214
202
  size: "lg",
215
203
  variant: "tertiary",
216
204
  disabled: z.value,
@@ -219,72 +207,72 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
219
207
  ])
220
208
  ]),
221
209
  default: y(() => [
222
- f("div", fa, [
223
- i(Ve, {
224
- title: l(c)("hr.employee.form.employeeSetting")
210
+ f("div", da, [
211
+ i(Ee, {
212
+ title: l(m)("hr.employee.form.employeeSetting")
225
213
  }, {
226
214
  default: y(() => [
227
- i(xe, {
228
- label: l(c)("hr.employee.form.masterUserConfig")
215
+ i(we, {
216
+ label: l(m)("hr.employee.form.masterUserConfig")
229
217
  }, {
230
218
  default: y(() => [
231
219
  i(S, {
232
220
  modelValue: s.value.isMasterUser,
233
221
  "onUpdate:modelValue": o[0] || (o[0] = (t) => s.value.isMasterUser = t),
234
222
  value: "masterUser",
235
- label: l(c)("hr.employee.form.masterUser"),
236
- sublabel: l(c)("hr.employee.form.masterUserSublabel"),
223
+ label: l(m)("hr.employee.form.masterUser"),
224
+ sublabel: l(m)("hr.employee.form.masterUserSublabel"),
237
225
  "label-placement": "right"
238
226
  }, null, 8, ["modelValue", "label", "sublabel"])
239
227
  ]),
240
228
  _: 1
241
229
  }, 8, ["label"]),
242
- f("div", va, [
243
- s.value.isMasterUser ? (g(), I(M, {
230
+ f("div", pa, [
231
+ s.value.isMasterUser ? (g(), I(R, {
244
232
  key: 0,
245
233
  modelValue: s.value.code,
246
234
  "onUpdate:modelValue": o[1] || (o[1] = (t) => s.value.code = t),
247
- label: l(c)("hr.employee.form.code")
248
- }, null, 8, ["modelValue", "label"])) : j("", !0),
249
- i(M, {
235
+ label: l(m)("hr.employee.form.code")
236
+ }, null, 8, ["modelValue", "label"])) : B("", !0),
237
+ i(R, {
250
238
  modelValue: s.value.name,
251
239
  "onUpdate:modelValue": o[2] || (o[2] = (t) => s.value.name = t),
252
240
  class: "w-full",
253
- label: l(c)("hr.employee.form.name"),
254
- rules: [(t) => !!t || l(c)("hr.employee.form.required")]
241
+ label: l(m)("hr.employee.form.name"),
242
+ rules: [(t) => !!t || l(m)("hr.employee.form.required")]
255
243
  }, null, 8, ["modelValue", "label", "rules"])
256
244
  ]),
257
- i(xe, {
258
- label: l(c)("hr.employee.form.passcode")
245
+ i(we, {
246
+ label: l(m)("hr.employee.form.passcode")
259
247
  }, {
260
248
  default: y(() => [
261
- f("div", ya, [
249
+ f("div", fa, [
262
250
  i(x, {
263
251
  modelValue: F.value,
264
252
  "onUpdate:modelValue": o[6] || (o[6] = (t) => F.value = t),
265
253
  rules: [
266
- (t) => (t == null ? void 0 : t.filter((B) => !!B).length) !== Ue ? l(c)("hr.employee.form.passcodeRequired") : !0
254
+ (t) => (t == null ? void 0 : t.filter((G) => !!G).length) !== Se ? l(m)("hr.employee.form.passcodeRequired") : !0
267
255
  ]
268
256
  }, {
269
257
  default: y(() => [
270
- i(sa, {
258
+ i(la, {
271
259
  modelValue: F.value,
272
260
  "onUpdate:modelValue": o[3] || (o[3] = (t) => F.value = t),
273
- masked: P.value,
274
- "onUpdate:masked": o[4] || (o[4] = (t) => P.value = t),
275
- length: Ue,
276
- "toggle-label": l(c)("hr.employee.form.passcodeToggleVisibility"),
261
+ masked: L.value,
262
+ "onUpdate:masked": o[4] || (o[4] = (t) => L.value = t),
263
+ length: Se,
264
+ "toggle-label": l(m)("hr.employee.form.passcodeToggleVisibility"),
277
265
  onComplete: o[5] || (o[5] = (t) => s.value.passcode = t)
278
266
  }, null, 8, ["modelValue", "masked", "toggle-label"])
279
267
  ]),
280
268
  _: 1
281
269
  }, 8, ["modelValue", "rules"]),
282
- i(ta, {
283
- label: l(c)("hr.employee.form.passcodeGenerate"),
284
- hint: l(c)("hr.employee.form.passcodeSelectOutletFirst"),
270
+ i(sa, {
271
+ label: l(m)("hr.employee.form.passcodeGenerate"),
272
+ hint: l(m)("hr.employee.form.passcodeSelectOutletFirst"),
285
273
  loading: W.value,
286
- disabled: !te.value,
287
- onClick: D
274
+ disabled: !se.value,
275
+ onClick: P
288
276
  }, null, 8, ["label", "hint", "loading", "disabled"])
289
277
  ])
290
278
  ]),
@@ -293,31 +281,31 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
293
281
  ]),
294
282
  _: 1
295
283
  }, 8, ["title"]),
296
- i(Ve, null, {
284
+ i(Ee, null, {
297
285
  default: y(() => [
298
286
  i(x, {
299
287
  modelValue: s.value.restaurants,
300
288
  "onUpdate:modelValue": o[8] || (o[8] = (t) => s.value.restaurants = t),
301
289
  tag: "div",
302
290
  rules: [
303
- (t) => t.length > 0 || l(c)("hr.employee.form.atLeastOneRestaurant"),
304
- (t) => t.every((B) => B.restaurantId && B.roleId) || l(c)("hr.employee.form.roleRequired")
291
+ (t) => t.length > 0 || l(m)("hr.employee.form.atLeastOneRestaurant"),
292
+ (t) => t.every((G) => G.restaurantId && G.roleId) || l(m)("hr.employee.form.roleRequired")
305
293
  ]
306
294
  }, {
307
295
  default: y(() => [
308
- i(oa, {
296
+ i(ta, {
309
297
  modelValue: s.value.restaurants,
310
298
  "onUpdate:modelValue": o[7] || (o[7] = (t) => s.value.restaurants = t),
311
299
  restaurants: l(d).restaurants.value,
312
- roles: l(k).roles.value,
313
- "is-role-usable": se,
314
- "is-restaurant-locked": le,
315
- "create-row": O,
316
- title: l(c)("hr.employee.form.assignmentSection"),
317
- "restaurant-label": l(c)("hr.employee.columns.restaurants"),
318
- "role-label": l(c)("hr.employee.form.role"),
319
- "add-label": l(c)("hr.employee.form.addAnother"),
320
- "remove-label": l(c)("common.remove")
300
+ roles: l(w).roles.value,
301
+ "is-role-usable": le,
302
+ "is-restaurant-locked": ae,
303
+ "create-row": A,
304
+ title: l(m)("hr.employee.form.assignmentSection"),
305
+ "restaurant-label": l(m)("hr.employee.columns.restaurants"),
306
+ "role-label": l(m)("hr.employee.form.role"),
307
+ "add-label": l(m)("hr.employee.form.addAnother"),
308
+ "remove-label": l(m)("common.remove")
321
309
  }, null, 8, ["modelValue", "restaurants", "roles", "title", "restaurant-label", "role-label", "add-label", "remove-label"])
322
310
  ]),
323
311
  _: 1
@@ -332,70 +320,70 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
332
320
  ], 64);
333
321
  };
334
322
  }
335
- }), _a = {
323
+ }), ga = {
336
324
  class: "space-y-8"
337
- }, ba = {
325
+ }, ha = {
338
326
  key: 0,
339
327
  class: "flex w-full items-start justify-between"
340
- }, wa = {
328
+ }, _a = {
341
329
  class: "flex items-start gap-8"
342
- }, ka = {
330
+ }, ba = {
343
331
  class: "flex"
344
- }, xa = {
332
+ }, ka = {
345
333
  key: 1,
346
334
  class: "space-y-4"
347
- }, Ea = {
335
+ }, wa = {
348
336
  class: "px-16"
349
- }, Va = {
337
+ }, xa = {
350
338
  class: "px-16 flex items-start gap-8"
351
- }, Sa = {
339
+ }, Ea = {
352
340
  class: "flex h-full flex-col overflow-auto"
353
- }, Ca = {
341
+ }, Va = {
354
342
  class: "space-y-4"
355
- }, Ua = {
343
+ }, Sa = {
356
344
  class: "fm-typo-en-body-lg-600"
357
- }, Fa = {
345
+ }, Ca = {
358
346
  key: 0,
359
347
  class: "mr-4"
360
- }, Ia = {
348
+ }, Ua = {
361
349
  class: "text-fm-color-typo-secondary"
362
- }, Ra = {
350
+ }, Fa = {
363
351
  class: "line-clamp-2"
364
- }, Ma = {
352
+ }, Ia = {
365
353
  class: "font-bold"
366
- }, A = 200, $a = /* @__PURE__ */ Fe({
354
+ }, N = 200, Ma = /* @__PURE__ */ Ce({
367
355
  __name: "EmployeeList",
368
- setup($, {
369
- expose: ce
356
+ setup(Pe, {
357
+ expose: ue
370
358
  }) {
371
359
  const {
372
360
  t: n
373
- } = Re(), k = v(), d = Le(), C = Pe(), me = He(), {
361
+ } = Fe(), w = v(), d = Re(), C = $e(), me = je(), {
374
362
  currentBusiness: U,
375
- sessionUser: de
376
- } = me, c = he(), V = h(() => C.isLoading.value), R = v(c.roles.value.length === 0);
377
- X(C.restaurants, (e) => {
363
+ sessionUser: ce
364
+ } = me, m = ge(), V = h(() => C.isLoading.value), M = v(m.roles.value.length === 0);
365
+ Z(C.restaurants, (e) => {
378
366
  if (e.length > 0 && d.listEmployees.value.length > 0) {
379
367
  const a = new Map(e.map((r) => [r._id, r]));
380
368
  d.listEmployees.value = d.listEmployees.value.map((r) => ({
381
369
  ...r,
382
370
  restaurants: r.restaurants.map((p) => {
383
- var Y, Z;
371
+ var Q, Y;
384
372
  return {
385
373
  ...p,
386
- restaurantName: ((Y = a.get(p.restaurantId)) == null ? void 0 : Y.profile.name) || p.restaurantName,
387
- restaurantCode: ((Z = a.get(p.restaurantId)) == null ? void 0 : Z.profile.code) ?? void 0
374
+ restaurantName: ((Q = a.get(p.restaurantId)) == null ? void 0 : Q.profile.name) || p.restaurantName,
375
+ restaurantCode: ((Y = a.get(p.restaurantId)) == null ? void 0 : Y.profile.code) ?? void 0
388
376
  };
389
377
  })
390
378
  }));
391
379
  }
392
380
  });
393
- const O = h(() => C.restaurants.value.map((e) => ({
381
+ const A = h(() => C.restaurants.value.map((e) => ({
394
382
  label: `${e.profile.code ? `${e.profile.code} - ` : ""}${e.profile.name}`,
395
383
  value: e._id
396
- }))), pe = X(c.roles, (e) => {
384
+ }))), de = Z(m.roles, (e) => {
397
385
  if (e.length > 0) {
398
- if (R.value = !1, d.listEmployees.value.length > 0) {
386
+ if (M.value = !1, d.listEmployees.value.length > 0) {
399
387
  const a = new Map(e.map((r) => [r._id, r.name]));
400
388
  d.listEmployees.value = d.listEmployees.value.map((r) => ({
401
389
  ...r,
@@ -405,29 +393,29 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
405
393
  }))
406
394
  }));
407
395
  }
408
- pe();
396
+ de();
409
397
  }
410
- }), ae = h(() => d.listEmployees.value), {
398
+ }), ee = h(() => d.listEmployees.value), {
411
399
  searchKey: _
412
- } = Ze(), T = v(""), H = h(() => ae.value), b = h(() => d.totalEmployees.value), s = v(1), J = h(() => d.isLoading.value), L = v(!1), le = h(() => {
400
+ } = Ye(), T = v(""), q = h(() => ee.value), b = h(() => d.totalEmployees.value), s = v(1), H = h(() => d.isLoading.value), $ = v(!1), ae = h(() => {
413
401
  var e;
414
402
  return JSON.stringify({
415
403
  businessId: ((e = U.value) == null ? void 0 : e._id) ?? "",
416
404
  search: T.value.trim(),
417
- restaurantIds: [...k.value ?? []].sort(),
405
+ restaurantIds: [...w.value ?? []].sort(),
418
406
  roleIds: [...t.value ?? []].sort()
419
407
  });
420
- }), se = (e) => {
408
+ }), le = (e) => {
421
409
  const a = e.restaurantCode, r = e.restaurantName;
422
410
  return a ? `${a} - ${r}` : r;
423
411
  }, F = (e) => e.roleName || "-";
424
- function P(e) {
412
+ function L(e) {
425
413
  return [{
426
414
  label: n("hr.employee.form.update"),
427
- onClick: () => w(e)
415
+ onClick: () => k(e)
428
416
  }, {
429
417
  label: n("hr.employee.remove.title"),
430
- onClick: () => M(e),
418
+ onClick: () => R(e),
431
419
  itemClass: "text-fm-color-typo-error"
432
420
  }];
433
421
  }
@@ -439,8 +427,8 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
439
427
  onClick: (r) => {
440
428
  r.stopPropagation();
441
429
  }
442
- }, [i(ea, {
443
- items: P(e)
430
+ }, [i(Xe, {
431
+ items: L(e)
444
432
  }, null)]), W = [{
445
433
  accessorKey: "code",
446
434
  size: 100,
@@ -453,9 +441,9 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
453
441
  const a = e.row.original;
454
442
  return i("div", {
455
443
  class: "flex items-center gap-8"
456
- }, [i($e.FmAvatar, {
444
+ }, [i(Me.FmAvatar, {
457
445
  name: a.name,
458
- initials: na(a.name),
446
+ initials: ra(a.name),
459
447
  size: "sm",
460
448
  class: "shrink-0"
461
449
  }, null), i("span", {
@@ -468,9 +456,9 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
468
456
  header: () => n("hr.employee.columns.restaurants"),
469
457
  enableSorting: !1,
470
458
  cell(e) {
471
- return V.value || R.value ? ie(Ee) : e.row.original.restaurants.map((a, r) => {
472
- const p = se(a);
473
- return ie("div", {
459
+ return V.value || M.value ? ne(xe) : e.row.original.restaurants.map((a, r) => {
460
+ const p = le(a);
461
+ return ne("div", {
474
462
  key: a.restaurantId || r
475
463
  }, (r ? `
476
464
  ` : "") + p);
@@ -482,11 +470,11 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
482
470
  header: () => n("hr.employee.columns.assignedRole"),
483
471
  enableSorting: !1,
484
472
  cell(e) {
485
- return V.value || R.value ? ie(Ee, {
473
+ return V.value || M.value ? ne(xe, {
486
474
  width: "120px"
487
475
  }) : e.row.original.restaurants.map((a, r) => {
488
476
  const p = F(a);
489
- return ie("div", {
477
+ return ne("div", {
490
478
  key: a.restaurantId || r
491
479
  }, (r ? `
492
480
  ` : "") + p);
@@ -509,7 +497,7 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
509
497
  className: "flex w-full items-center justify-end"
510
498
  });
511
499
  }
512
- }], te = ({
500
+ }], se = ({
513
501
  employee: e
514
502
  }) => i("div", {
515
503
  class: "flex flex-col gap-4 grow p-8"
@@ -520,22 +508,22 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
520
508
  row: {
521
509
  original: e
522
510
  }
523
- }) : e[a.accessorKey]]))]), D = Me(), K = Je(), fe = De(D), Q = v(!1), G = v(), u = v();
511
+ }) : e[a.accessorKey]]))]), P = Ie(), K = qe(), pe = Le(P), J = v(!1), O = v(), u = v();
524
512
  function o(e) {
525
513
  const a = e.isRestricted;
526
- return a && D.open({
514
+ return a && P.open({
527
515
  message: n("hr.employee.cannotUpdateMasterUser", {
528
516
  name: e.name
529
517
  }),
530
518
  type: "error"
531
519
  }), a;
532
520
  }
533
- const w = (e) => {
521
+ const k = (e) => {
534
522
  var r;
535
523
  e && o(e) || (r = u.value) == null || r.trigger(e);
536
524
  }, {
537
525
  breakpoints: S
538
- } = We(), M = (e) => {
526
+ } = He(), R = (e) => {
539
527
  o(e) || K.open({
540
528
  title: n("hr.employee.remove.title"),
541
529
  message: n("hr.employee.remove.message", {
@@ -546,19 +534,19 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
546
534
  text: n("common.remove"),
547
535
  close: !1,
548
536
  variant: "destructive",
549
- isLoading: Q
537
+ isLoading: J
550
538
  },
551
539
  secondaryActions: {
552
540
  text: n("common.cancel"),
553
541
  close: !0
554
542
  }
555
543
  }).onPrimary(async () => {
556
- if (Q.value) return;
544
+ if (J.value) return;
557
545
  const r = e.isMasterUser ? d.deleteMasterEmployee : d.deleteEmployee;
558
- await fe.minor(async () => {
559
- await r(e), await ve();
546
+ await pe.minor(async () => {
547
+ await r(e), await fe();
560
548
  }, {
561
- isLoading: Q,
549
+ isLoading: J,
562
550
  successMessage: n("hr.employee.remove.successMessage", {
563
551
  name: e.name
564
552
  })
@@ -566,141 +554,141 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
566
554
  }), K.close();
567
555
  });
568
556
  }, x = v("");
569
- function N() {
557
+ function D() {
570
558
  var e;
571
559
  (e = u.value) == null || e.trigger();
572
560
  }
573
- const oe = h(() => he().roles.value.map((e) => ({
561
+ const te = h(() => ge().roles.value.map((e) => ({
574
562
  label: e.name,
575
563
  value: e._id
576
564
  }))), t = v();
577
- async function B() {
565
+ async function G() {
578
566
  try {
579
- await d.syncUsersMeta(), await ve(), D.open({
567
+ await d.syncUsersMeta(), await fe(), P.open({
580
568
  message: n("hr.employee.sync.successMessage"),
581
569
  type: "success"
582
570
  });
583
571
  } catch (e) {
584
- console.error("Error syncing users:", e), D.open({
572
+ console.error("Error syncing users:", e), P.open({
585
573
  message: n("hr.employee.sync.errorMessage"),
586
574
  type: "error"
587
575
  });
588
576
  }
589
577
  }
590
- async function re(e = s.value) {
578
+ async function oe(e = s.value) {
591
579
  var a, r;
592
580
  try {
593
581
  await d.readEmployeesPage({
594
- limit: A,
595
- offset: (e - 1) * A,
582
+ limit: N,
583
+ offset: (e - 1) * N,
596
584
  search: T.value.trim() || void 0,
597
- restaurantIds: (a = k.value) != null && a.length ? k.value : void 0,
585
+ restaurantIds: (a = w.value) != null && a.length ? w.value : void 0,
598
586
  roleIds: (r = t.value) != null && r.length ? t.value : void 0
599
587
  });
600
588
  } catch (p) {
601
- console.error("Failed to load employees:", p), D.open({
589
+ console.error("Failed to load employees:", p), P.open({
602
590
  message: p instanceof Error ? p.message : String(p),
603
591
  type: "error"
604
592
  });
605
593
  }
606
594
  }
607
- async function ve() {
595
+ async function fe() {
608
596
  var a;
609
597
  if (!((a = U.value) != null && a._id)) return;
610
- await re(s.value);
611
- const e = Math.max(1, Math.ceil(b.value / A));
612
- s.value > e && (s.value = e, await re(s.value));
598
+ await oe(s.value);
599
+ const e = Math.max(1, Math.ceil(b.value / N));
600
+ s.value > e && (s.value = e, await oe(s.value));
613
601
  }
614
- async function Ne() {
602
+ async function De() {
615
603
  var e, a;
616
604
  return await d.readAllEmployeesPage({
617
605
  search: T.value.trim() || void 0,
618
- restaurantIds: (e = k.value) != null && e.length ? k.value : void 0,
606
+ restaurantIds: (e = w.value) != null && e.length ? w.value : void 0,
619
607
  roleIds: (a = t.value) != null && a.length ? t.value : void 0
620
608
  }, b.value);
621
609
  }
622
- const Ae = ra(_, () => {
610
+ const Ne = oa(_, () => {
623
611
  T.value = _.value;
624
612
  }, 300);
625
- Be(Ae);
626
- let ye = !1;
627
- async function Oe({
613
+ Oe(Ne);
614
+ let ve = !1;
615
+ async function Ae({
628
616
  pageIndex: e
629
617
  }) {
630
618
  var a;
631
- if ((a = U.value) != null && a._id && !ye && !(e === 0 && s.value === 1 && H.value.length > 0)) {
632
- ye = !0, s.value = e + 1;
619
+ if ((a = U.value) != null && a._id && !ve && !(e === 0 && s.value === 1 && q.value.length > 0)) {
620
+ ve = !0, s.value = e + 1;
633
621
  try {
634
- await re(s.value);
622
+ await oe(s.value);
635
623
  } finally {
636
- ye = !1;
624
+ ve = !1;
637
625
  }
638
626
  }
639
627
  }
640
- X(le, async () => {
628
+ Z(ae, async () => {
641
629
  var e;
642
- s.value = 1, L.value = !1, (e = U.value) != null && e._id && (await re(1), L.value = !0);
630
+ s.value = 1, $.value = !1, (e = U.value) != null && e._id && (await oe(1), $.value = !0);
643
631
  }, {
644
632
  immediate: !0
645
- }), X(() => G.value && G.value.restaurants, (e) => {
633
+ }), Z(() => O.value && O.value.restaurants, (e) => {
646
634
  e && e.length > 0 && (x.value = "");
647
635
  });
648
- const Te = h(() => b.value > A);
649
- return ce({
650
- create: N,
651
- filteredEmployees: H,
652
- exportEmployees: Ne,
636
+ const Te = h(() => b.value > N);
637
+ return ue({
638
+ create: D,
639
+ filteredEmployees: q,
640
+ exportEmployees: De,
653
641
  getHasPaginationFooter: () => Te.value
654
642
  }), (e, a) => {
655
- var _e, be;
656
- const r = E("FmButton"), p = E("FmTooltip"), Y = E("FmSearch"), Z = E("FmListItem"), ze = E("FmTable");
657
- return g(), ee(Ie, null, [i(ha, {
643
+ var he, _e;
644
+ const r = E("FmButton"), p = E("FmTooltip"), Q = E("FmSearch"), Y = E("FmListItem"), ze = E("FmTable");
645
+ return g(), X(Ue, null, [i(ya, {
658
646
  ref_key: "employeeFormRef",
659
647
  ref: u,
660
- modelValue: G.value,
661
- "onUpdate:modelValue": a[0] || (a[0] = (m) => G.value = m),
648
+ modelValue: O.value,
649
+ "onUpdate:modelValue": a[0] || (a[0] = (c) => O.value = c),
662
650
  "role-error-message": x.value,
663
651
  class: "gap-8",
664
- onSubmitted: ve
665
- }, null, 8, ["modelValue", "role-error-message"]), f("div", _a, [l(S).xs ? (g(), ee("div", xa, [f("div", Ea, [i(Y, {
652
+ onSubmitted: fe
653
+ }, null, 8, ["modelValue", "role-error-message"]), f("div", ga, [l(S).xs ? (g(), X("div", ka, [f("div", wa, [i(Q, {
666
654
  modelValue: l(_),
667
- "onUpdate:modelValue": a[4] || (a[4] = (m) => we(_) ? _.value = m : null),
655
+ "onUpdate:modelValue": a[4] || (a[4] = (c) => be(_) ? _.value = c : null),
668
656
  placeholder: l(n)("hr.employee.search.placeholder")
669
- }, null, 8, ["modelValue", "placeholder"])]), i(Xe), f("div", Va, [i(ue, {
670
- modelValue: k.value,
671
- "onUpdate:modelValue": a[5] || (a[5] = (m) => k.value = m),
657
+ }, null, 8, ["modelValue", "placeholder"])]), i(Ze), f("div", xa, [i(ie, {
658
+ modelValue: w.value,
659
+ "onUpdate:modelValue": a[5] || (a[5] = (c) => w.value = c),
672
660
  multiple: "",
673
- items: O.value,
661
+ items: A.value,
674
662
  variant: "dark",
675
663
  "selected-prefix": l(n)("hr.role.columns.restaurants"),
676
664
  placeholder: l(n)("hr.role.columns.restaurants"),
677
665
  class: "!w-auto"
678
- }, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"]), i(ue, {
666
+ }, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"]), i(ie, {
679
667
  modelValue: t.value,
680
- "onUpdate:modelValue": a[6] || (a[6] = (m) => t.value = m),
668
+ "onUpdate:modelValue": a[6] || (a[6] = (c) => t.value = c),
681
669
  multiple: "",
682
- items: oe.value,
670
+ items: te.value,
683
671
  variant: "dark",
684
672
  "selected-prefix": l(n)("hr.employee.filter.selected_role_prefix"),
685
673
  placeholder: l(n)("hr.employee.filter.role_placeholder")
686
- }, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"])])])) : (g(), ee("div", ba, [f("div", wa, [i(ue, {
687
- modelValue: k.value,
688
- "onUpdate:modelValue": a[1] || (a[1] = (m) => k.value = m),
674
+ }, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"])])])) : (g(), X("div", ha, [f("div", _a, [i(ie, {
675
+ modelValue: w.value,
676
+ "onUpdate:modelValue": a[1] || (a[1] = (c) => w.value = c),
689
677
  multiple: "",
690
- items: O.value,
678
+ items: A.value,
691
679
  variant: "dark",
692
680
  "selected-prefix": l(n)("hr.role.columns.restaurants"),
693
681
  placeholder: l(n)("hr.role.columns.restaurants"),
694
682
  class: "!w-auto"
695
- }, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"]), i(ue, {
683
+ }, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"]), i(ie, {
696
684
  modelValue: t.value,
697
- "onUpdate:modelValue": a[2] || (a[2] = (m) => t.value = m),
685
+ "onUpdate:modelValue": a[2] || (a[2] = (c) => t.value = c),
698
686
  multiple: "",
699
687
  variant: "dark",
700
- items: oe.value,
688
+ items: te.value,
701
689
  "selected-prefix": l(n)("hr.employee.filter.selected_role_prefix"),
702
690
  placeholder: l(n)("hr.employee.filter.role_placeholder")
703
- }, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"])]), f("div", ka, [(_e = l(de)) != null && _e.role.isAdmin ? (g(), I(p, {
691
+ }, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"])]), f("div", ba, [(he = l(ce)) != null && he.role.isAdmin ? (g(), I(p, {
704
692
  key: 0,
705
693
  content: l(n)("hr.employee.sync.tooltip")
706
694
  }, {
@@ -708,21 +696,21 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
708
696
  icon: "refresh",
709
697
  label: l(n)("hr.employee.sync.tooltip"),
710
698
  variant: "tertiary",
711
- onClick: B
699
+ onClick: G
712
700
  }, null, 8, ["label"])]),
713
701
  _: 1
714
- }, 8, ["content"])) : j("", !0), i(Y, {
702
+ }, 8, ["content"])) : B("", !0), i(Q, {
715
703
  modelValue: l(_),
716
- "onUpdate:modelValue": a[3] || (a[3] = (m) => we(_) ? _.value = m : null),
704
+ "onUpdate:modelValue": a[3] || (a[3] = (c) => be(_) ? _.value = c : null),
717
705
  autofocus: "",
718
706
  class: "pl-4 w-[320px]",
719
707
  placeholder: l(n)("hr.employee.search.placeholder")
720
- }, null, 8, ["modelValue", "placeholder"])])])), (be = l(U)) != null && be._id ? (g(), I(Qe, {
708
+ }, null, 8, ["modelValue", "placeholder"])])])), (_e = l(U)) != null && _e._id ? (g(), I(We, {
721
709
  key: 2
722
710
  }, {
723
- default: y(() => [f("div", Sa, [!L.value && l(d).isLoading.value ? (g(), I(Ye, {
711
+ default: y(() => [f("div", Ea, [!$.value && l(d).isLoading.value ? (g(), I(Je, {
724
712
  key: 0
725
- })) : j("", !0), L.value ? (g(), I(aa, {
713
+ })) : B("", !0), $.value ? (g(), I(ea, {
726
714
  key: 1,
727
715
  "is-loading": l(d).isLoading.value,
728
716
  "is-empty": b.value === 0,
@@ -730,59 +718,59 @@ const da = { class: "flex w-full items-center justify-between" }, pa = { class:
730
718
  subtitle: l(n)("hr.employee.noData.subtitle")
731
719
  }, {
732
720
  default: y(() => [(g(), I(ze, {
733
- key: le.value,
721
+ key: ae.value,
734
722
  class: ke(["employee-list-table h-full", {
735
- "employee-list-table--pagination-loading": J.value
723
+ "employee-list-table--pagination-loading": H.value
736
724
  }]),
737
725
  "column-defs": W,
738
- "row-data": H.value,
739
- "page-size": A,
740
- "page-count": Math.ceil(b.value / A),
726
+ "row-data": q.value,
727
+ "page-size": N,
728
+ "page-count": Math.ceil(b.value / N),
741
729
  "row-count": b.value,
742
- "fetch-fn": Oe,
743
- "hide-footer": b.value <= A,
730
+ "fetch-fn": Ae,
731
+ "hide-footer": b.value <= N,
744
732
  loading: l(d).isLoading.value,
745
733
  virtual: !1,
746
734
  "pin-header-row": "",
747
- onRowClick: a[7] || (a[7] = (m) => w(m.original))
735
+ onRowClick: a[7] || (a[7] = (c) => k(c.original))
748
736
  }, {
749
- "list-row": y((m) => [l(S).xs ? (g(), I(Z, {
737
+ "list-row": y((c) => [l(S).xs ? (g(), I(Y, {
750
738
  key: 0,
751
739
  class: ke(["py-12 px-16 items-center justify-between", {
752
- "border-t border-fm-color-neutral-gray-100": m.index > 0
740
+ "border-t border-fm-color-neutral-gray-100": c.index > 0
753
741
  }]),
754
- onClick: (ne) => w(m.original)
742
+ onClick: (re) => k(c.original)
755
743
  }, {
756
- default: y(() => [f("div", Ca, [f("p", Ua, [m.original.code ? (g(), ee("span", Fa, q(m.original.code) + ".", 1)) : j("", !0), ge(q(m.original.name), 1)]), f("div", Ia, [f("p", Ra, [f("span", Ma, q(l(n)("hr.employee.columns.restaurants")) + ":", 1), ge(" " + q(m.original.restaurants.map((ne) => se(ne)).join(", ")), 1)]), f("p", null, [a[8] || (a[8] = f("span", {
744
+ default: y(() => [f("div", Va, [f("p", Sa, [c.original.code ? (g(), X("span", Ca, j(c.original.code) + ".", 1)) : B("", !0), ye(j(c.original.name), 1)]), f("div", Ua, [f("p", Fa, [f("span", Ia, j(l(n)("hr.employee.columns.restaurants")) + ":", 1), ye(" " + j(c.original.restaurants.map((re) => le(re)).join(", ")), 1)]), f("p", null, [a[8] || (a[8] = f("span", {
757
745
  class: "font-bold"
758
- }, "Since:", -1)), ge(" " + q(m.original.since), 1)])])]), i(r, {
746
+ }, "Since:", -1)), ye(" " + j(c.original.since), 1)])])]), i(r, {
759
747
  icon: "delete",
760
748
  variant: "tertiary",
761
749
  "text-color": "neutral-gray-400",
762
- onClick: je((ne) => M(m.original), ["stop"])
750
+ onClick: Ge((re) => R(c.original), ["stop"])
763
751
  }, null, 8, ["onClick"])]),
764
752
  _: 2
765
- }, 1032, ["class", "onClick"])) : (g(), I(Z, {
753
+ }, 1032, ["class", "onClick"])) : (g(), I(Y, {
766
754
  key: 1,
767
755
  style: {
768
756
  padding: "0"
769
757
  },
770
- onClick: (ne) => w(m.original)
758
+ onClick: (re) => k(c.original)
771
759
  }, {
772
- default: y(() => [(g(), I(qe(te), {
773
- employee: m.original
760
+ default: y(() => [(g(), I(Be(se), {
761
+ employee: c.original
774
762
  }, null, 8, ["employee"]))]),
775
763
  _: 2
776
764
  }, 1032, ["onClick"]))]),
777
765
  _: 1
778
766
  }, 8, ["class", "row-data", "page-count", "row-count", "hide-footer", "loading"]))]),
779
767
  _: 1
780
- }, 8, ["is-loading", "is-empty", "title", "subtitle"])) : j("", !0)])]),
768
+ }, 8, ["is-loading", "is-empty", "title", "subtitle"])) : B("", !0)])]),
781
769
  _: 1
782
- })) : j("", !0)])], 64);
770
+ })) : B("", !0)])], 64);
783
771
  };
784
772
  }
785
- }), el = /* @__PURE__ */ ma($a, [["__scopeId", "data-v-5aed0d1c"]]);
773
+ }), Za = /* @__PURE__ */ Qe(Ma, [["__scopeId", "data-v-5aed0d1c"]]);
786
774
  export {
787
- el as default
775
+ Za as default
788
776
  };