@feedmepos/mf-hrm-portal 2.2.5-dev → 2.2.5-dev.4

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 (160) hide show
  1. package/dist/{ApprovalCodeList-DgcWZ3SZ.js → ApprovalCodeList-D0B_X3Sf.js} +4 -4
  2. package/dist/{AuditLogList-vWKMMGvd.js → AuditLogList-D9anf4YQ.js} +18 -17
  3. package/dist/{ConditionBuilderForm.vue_vue_type_script_setup_true_lang-DuhXogXK.js → ConditionBuilderForm.vue_vue_type_script_setup_true_lang-4oENMRO3.js} +2 -2
  4. package/dist/EmployeeList-DREDu3Ou.js +788 -0
  5. package/dist/{FormItem.vue_vue_type_script_setup_true_lang-DPT2FoIc.js → FormItem.vue_vue_type_script_setup_true_lang-CUnlKsxk.js} +1 -1
  6. package/dist/{GrantUserList-BAW0C1bA.js → GrantUserList-CLDshEN9.js} +5 -5
  7. package/dist/{Main-Wr6cTqfM.js → Main-DtMaG42L.js} +2 -2
  8. package/dist/{Main-NzpdRNB3.js → Main-QhQxU593.js} +5 -5
  9. package/dist/{Main-B7Nn8CLQ.js → Main-lqlb8tPw.js} +9 -9
  10. package/dist/PasscodePinField.vue_vue_type_script_setup_true_lang-CqG0v0Sz.js +243 -0
  11. package/dist/{PermissionSetList-D6AFOleD.js → PermissionSetList-BK8yBpJJ.js} +22 -21
  12. package/dist/{PortalPermissionEditor.vue_vue_type_script_setup_true_lang-Bzq2_BMn.js → PortalPermissionEditor.vue_vue_type_script_setup_true_lang-uSdvH81B.js} +924 -923
  13. package/dist/{RoleList-BuqpmXn_.js → RoleList-D6AX6BqB.js} +7 -7
  14. package/dist/ScheduleGeneralPage-DAECTCDu.js +242 -0
  15. package/dist/SchedulePage-CdFR7JuO.js +10751 -0
  16. package/dist/SchedulePositionPage-DTtKg0sx.js +220 -0
  17. package/dist/ScheduleSelect.vue_vue_type_script_setup_true_lang-BiuUrr50.js +199 -0
  18. package/dist/SelectFilter-CG13h83-.js +264 -0
  19. package/dist/TeamMemberList-BM5JoR6J.js +1155 -0
  20. package/dist/{TimesheetList-B5FyVyCz.js → TimesheetList-Ch_f_PD5.js} +54 -53
  21. package/dist/{TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-C99Jr6Ax.js → TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-CxqxqwyD.js} +2 -2
  22. package/dist/_plugin-vue_export-helper-CHgC5LLL.js +9 -0
  23. package/dist/{app-8samJY5z.js → app-tDHL6k4G.js} +3092 -2499
  24. package/dist/app.js +1 -1
  25. package/dist/{dayjs.min-Ba4X_9nY.js → dayjs.min-B_XWc0Hu.js} +1 -1
  26. package/dist/employee-Bs_2vqBY.js +139 -0
  27. package/dist/index-Cz2b95YF.js +70 -0
  28. package/dist/{iteration-Dhdew1jW.js → index-jxRluZiW.js} +698 -726
  29. package/dist/iteration-CcXrOMQe.js +30 -0
  30. package/dist/{lodash-CJ3mHku0.js → lodash-D5vM3paU.js} +1 -1
  31. package/dist/{role-BViYS7RK.js → role-7ccipEEe.js} +4 -3
  32. package/dist/{rule-Dxt1ZSQS.js → rule-7faruCdz.js} +282 -277
  33. package/dist/src/api/schedule/index.d.ts +44 -0
  34. package/dist/src/components/form/OutletRoleAssignment.vue.d.ts +16 -0
  35. package/dist/src/components/layout/AppSidebar.vue.d.ts +2 -0
  36. package/dist/src/components/layout/PortalShell.vue.d.ts +12 -0
  37. package/dist/src/components/layout/withShell.d.ts +14 -0
  38. package/dist/src/helpers/outlet-role-assignment.d.ts +40 -0
  39. package/dist/src/helpers/rule.d.ts +15 -0
  40. package/dist/src/router/shared.d.ts +4 -1
  41. package/dist/src/types/schedule.d.ts +232 -0
  42. package/dist/src/views/scheduling/ScheduleGeneralPage.vue.d.ts +4 -0
  43. package/dist/src/views/scheduling/SchedulePage.vue.d.ts +4 -0
  44. package/dist/src/views/scheduling/SchedulePositionPage.vue.d.ts +4 -0
  45. package/dist/src/views/scheduling/components/ScheduleAddEmployeeIdentitySection.vue.d.ts +6 -0
  46. package/dist/src/views/scheduling/components/ScheduleAddEmployeeModal.vue.d.ts +6 -0
  47. package/dist/src/views/scheduling/components/ScheduleAddEmployeeModeStep.vue.d.ts +6 -0
  48. package/dist/src/views/scheduling/components/ScheduleAddEmployeePosAccessSection.vue.d.ts +6 -0
  49. package/dist/src/views/scheduling/components/ScheduleAddEmployeePositionsSection.vue.d.ts +6 -0
  50. package/dist/src/views/scheduling/components/ScheduleAddEmployeeSchedulingSection.vue.d.ts +6 -0
  51. package/dist/src/views/scheduling/components/ScheduleAddPickPopover.vue.d.ts +6 -0
  52. package/dist/src/views/scheduling/components/ScheduleAllShiftsRow.vue.d.ts +22 -0
  53. package/dist/src/views/scheduling/components/ScheduleAreaRows.vue.d.ts +34 -0
  54. package/dist/src/views/scheduling/components/ScheduleAssignEmployeePopover.vue.d.ts +6 -0
  55. package/dist/src/views/scheduling/components/ScheduleAutoScheduleModal.vue.d.ts +6 -0
  56. package/dist/src/views/scheduling/components/ScheduleChangeEmployeeModal.vue.d.ts +8 -0
  57. package/dist/src/views/scheduling/components/ScheduleConfirmModal.vue.d.ts +24 -0
  58. package/dist/src/views/scheduling/components/ScheduleCostRail.vue.d.ts +8 -0
  59. package/dist/src/views/scheduling/components/ScheduleDateRangePopover.vue.d.ts +6 -0
  60. package/dist/src/views/scheduling/components/ScheduleDayNotePopover.vue.d.ts +6 -0
  61. package/dist/src/views/scheduling/components/ScheduleDayTimeline.vue.d.ts +12 -0
  62. package/dist/src/views/scheduling/components/ScheduleDemandRow.vue.d.ts +23 -0
  63. package/dist/src/views/scheduling/components/ScheduleDemandSheet.vue.d.ts +10 -0
  64. package/dist/src/views/scheduling/components/ScheduleDotsIcon.vue.d.ts +2 -0
  65. package/dist/src/views/scheduling/components/ScheduleEmployeeDetailPanel.vue.d.ts +12 -0
  66. package/dist/src/views/scheduling/components/ScheduleEmployeeIdentity.vue.d.ts +17 -0
  67. package/dist/src/views/scheduling/components/ScheduleFilterBar.vue.d.ts +18 -0
  68. package/dist/src/views/scheduling/components/ScheduleGapPopover.vue.d.ts +6 -0
  69. package/dist/src/views/scheduling/components/ScheduleGridHeader.vue.d.ts +18 -0
  70. package/dist/src/views/scheduling/components/ScheduleLeaveEditModal.vue.d.ts +6 -0
  71. package/dist/src/views/scheduling/components/ScheduleLegendBar.vue.d.ts +6 -0
  72. package/dist/src/views/scheduling/components/ScheduleOnboardingWelcome.vue.d.ts +12 -0
  73. package/dist/src/views/scheduling/components/ScheduleOnboardingWizard.vue.d.ts +6 -0
  74. package/dist/src/views/scheduling/components/ScheduleOpenShiftCardMenu.vue.d.ts +14 -0
  75. package/dist/src/views/scheduling/components/SchedulePdfPreview.vue.d.ts +6 -0
  76. package/dist/src/views/scheduling/components/SchedulePublishModal.vue.d.ts +8 -0
  77. package/dist/src/views/scheduling/components/ScheduleReviewBar.vue.d.ts +12 -0
  78. package/dist/src/views/scheduling/components/ScheduleSelect.vue.d.ts +24 -0
  79. package/dist/src/views/scheduling/components/ScheduleSelectExistingEmployeeModal.vue.d.ts +6 -0
  80. package/dist/src/views/scheduling/components/ScheduleShiftCardMenu.vue.d.ts +12 -0
  81. package/dist/src/views/scheduling/components/ScheduleShiftCell.vue.d.ts +31 -0
  82. package/dist/src/views/scheduling/components/ScheduleShiftHeadcountEditor.vue.d.ts +6 -0
  83. package/dist/src/views/scheduling/components/ScheduleShiftImpact.vue.d.ts +6 -0
  84. package/dist/src/views/scheduling/components/ScheduleShiftMoreOptions.vue.d.ts +6 -0
  85. package/dist/src/views/scheduling/components/ScheduleShiftPopover.vue.d.ts +14 -0
  86. package/dist/src/views/scheduling/components/ScheduleShiftRepeatDaysRow.vue.d.ts +8 -0
  87. package/dist/src/views/scheduling/components/ScheduleShiftSegmentsEditor.vue.d.ts +8 -0
  88. package/dist/src/views/scheduling/components/ScheduleShiftWhoPicker.vue.d.ts +25 -0
  89. package/dist/src/views/scheduling/components/ScheduleStackPopover.vue.d.ts +14 -0
  90. package/dist/src/views/scheduling/components/ScheduleStaffRail.vue.d.ts +16 -0
  91. package/dist/src/views/scheduling/components/ScheduleStaffRows.vue.d.ts +54 -0
  92. package/dist/src/views/scheduling/components/ScheduleStatsRow.vue.d.ts +12 -0
  93. package/dist/src/views/scheduling/components/ScheduleSwapShiftsModal.vue.d.ts +8 -0
  94. package/dist/src/views/scheduling/components/ScheduleTimePickerPopover.vue.d.ts +6 -0
  95. package/dist/src/views/scheduling/components/ScheduleTopbar.vue.d.ts +22 -0
  96. package/dist/src/views/scheduling/composables/schedule-add-employee-form.d.ts +67 -0
  97. package/dist/src/views/scheduling/composables/schedule-board-helpers.d.ts +38 -0
  98. package/dist/src/views/scheduling/composables/schedule-day-meta.d.ts +29 -0
  99. package/dist/src/views/scheduling/composables/schedule-employee-profile.d.ts +7 -0
  100. package/dist/src/views/scheduling/composables/schedule-shift-time.d.ts +14 -0
  101. package/dist/src/views/scheduling/composables/schedule-week-cache.d.ts +10 -0
  102. package/dist/src/views/scheduling/composables/useScheduleAddEmployee.d.ts +86 -0
  103. package/dist/src/views/scheduling/composables/useScheduleAddPick.d.ts +66 -0
  104. package/dist/src/views/scheduling/composables/useScheduleAllShiftsRow.d.ts +77 -0
  105. package/dist/src/views/scheduling/composables/useScheduleAreaBoard.d.ts +50 -0
  106. package/dist/src/views/scheduling/composables/useScheduleAreaDragDrop.d.ts +18 -0
  107. package/dist/src/views/scheduling/composables/useScheduleAssign.d.ts +113 -0
  108. package/dist/src/views/scheduling/composables/useScheduleAutoSchedule.d.ts +136 -0
  109. package/dist/src/views/scheduling/composables/useScheduleBoard.d.ts +415 -0
  110. package/dist/src/views/scheduling/composables/useScheduleCellState.d.ts +27 -0
  111. package/dist/src/views/scheduling/composables/useScheduleClashDetection.d.ts +18 -0
  112. package/dist/src/views/scheduling/composables/useScheduleCopyWeek.d.ts +17 -0
  113. package/dist/src/views/scheduling/composables/useScheduleCostRail.d.ts +43 -0
  114. package/dist/src/views/scheduling/composables/useScheduleDayNote.d.ts +48 -0
  115. package/dist/src/views/scheduling/composables/useScheduleDayTimeline.d.ts +82 -0
  116. package/dist/src/views/scheduling/composables/useScheduleDemand.d.ts +68 -0
  117. package/dist/src/views/scheduling/composables/useScheduleDemandRow.d.ts +45 -0
  118. package/dist/src/views/scheduling/composables/useScheduleDemandSheet.d.ts +139 -0
  119. package/dist/src/views/scheduling/composables/useScheduleDragDrop.d.ts +22 -0
  120. package/dist/src/views/scheduling/composables/useScheduleEmployeeIdentity.d.ts +32 -0
  121. package/dist/src/views/scheduling/composables/useScheduleEmployeeProfile.d.ts +16 -0
  122. package/dist/src/views/scheduling/composables/useScheduleExport.d.ts +26 -0
  123. package/dist/src/views/scheduling/composables/useScheduleFilterBar.d.ts +14 -0
  124. package/dist/src/views/scheduling/composables/useScheduleGapPopover.d.ts +80 -0
  125. package/dist/src/views/scheduling/composables/useScheduleLeave.d.ts +20 -0
  126. package/dist/src/views/scheduling/composables/useScheduleLegend.d.ts +15 -0
  127. package/dist/src/views/scheduling/composables/useScheduleLegendBar.d.ts +35 -0
  128. package/dist/src/views/scheduling/composables/useScheduleOnboardingWizard.d.ts +179 -0
  129. package/dist/src/views/scheduling/composables/useScheduleOpenShiftCard.d.ts +23 -0
  130. package/dist/src/views/scheduling/composables/useScheduleOutlet.d.ts +19 -0
  131. package/dist/src/views/scheduling/composables/useSchedulePositions.d.ts +32 -0
  132. package/dist/src/views/scheduling/composables/useSchedulePublish.d.ts +91 -0
  133. package/dist/src/views/scheduling/composables/useScheduleRangeCalendar.d.ts +18 -0
  134. package/dist/src/views/scheduling/composables/useScheduleRoster.d.ts +183 -0
  135. package/dist/src/views/scheduling/composables/useScheduleSettings.d.ts +54 -0
  136. package/dist/src/views/scheduling/composables/useScheduleSetupBanner.d.ts +18 -0
  137. package/dist/src/views/scheduling/composables/useScheduleShiftActions.d.ts +225 -0
  138. package/dist/src/views/scheduling/composables/useScheduleShiftPopover.d.ts +174 -0
  139. package/dist/src/views/scheduling/composables/useScheduleStaffRail.d.ts +20 -0
  140. package/dist/src/views/scheduling/composables/useScheduleStatsRow.d.ts +25 -0
  141. package/dist/src/views/scheduling/composables/useScheduleTimePicker.d.ts +44 -0
  142. package/dist/src/views/scheduling/composables/useScheduleTopbar.d.ts +10 -0
  143. package/dist/src/views/scheduling/data.d.ts +105 -0
  144. package/dist/src/views/scheduling/locales/index.d.ts +496 -0
  145. package/dist/src/views/scheduling/schedule-store.d.ts +116 -0
  146. package/dist/src/views/scheduling/types.d.ts +311 -0
  147. package/dist/src/views/team/components/PortalConditionForm.vue.d.ts +2 -2
  148. package/dist/src/views/team/condition-builders/ConditionBuilderForm.vue.d.ts +2 -2
  149. package/dist/src/views/team/member/TeamMemberMasterUser.vue.d.ts +12 -3
  150. package/dist/style.css +1 -1
  151. package/dist/tsconfig.app.tsbuildinfo +1 -1
  152. package/dist/{useReportPermissions-BiyAfGvZ.js → useReportPermissions-FieO4EAD.js} +3 -3
  153. package/dist/useScheduleOutlet-CmIG5dwQ.js +557 -0
  154. package/dist/useSchedulePositions-DPVAgdB2.js +103 -0
  155. package/package.json +1 -1
  156. package/dist/EmployeeList-Cu4RxVQX.js +0 -889
  157. package/dist/PasscodePinField.vue_vue_type_script_setup_true_lang-BUI0Xsgc.js +0 -85
  158. package/dist/SelectFilter-ATOm0hdn.js +0 -269
  159. package/dist/TeamMemberList-M6HA9BWu.js +0 -1248
  160. package/dist/employee-BcFgm8Rt.js +0 -204
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as r, openBlock as c, createElementVNode as o, ref as m, computed as f, defineComponent as p, renderSlot as a, createCommentVNode as _, toDisplayString as i } from "vue";
2
- import { _ as y } from "./SelectFilter-ATOm0hdn.js";
2
+ import { _ as y } from "./_plugin-vue_export-helper-CHgC5LLL.js";
3
3
  const h = {};
4
4
  function v(t, e) {
5
5
  return c(), r("div", null, [...e[0] || (e[0] = [
@@ -1,15 +1,15 @@
1
1
  import { defineComponent as X, ref as S, computed as f, watch as ue, resolveComponent as v, createElementBlock as D, openBlock as w, Fragment as E, renderSlot as de, createVNode as l, unref as s, withCtx as g, createElementVNode as o, toDisplayString as _, isRef as H, renderList as me, createBlock as pe, createCommentVNode as fe, withModifiers as W, createTextVNode as J, normalizeClass as ve, h as p } from "vue";
2
- import { d as ge } from "./dayjs.min-Ba4X_9nY.js";
2
+ import { d as ge } from "./dayjs.min-B_XWc0Hu.js";
3
3
  import { useI18n as Z } from "@feedmepos/mf-common";
4
4
  import { useSnackbar as ee, components as K, useDialog as _e, useBreakpoints as ye, FmButtonVariant as O } from "@feedmepos/ui-library";
5
- import { S as A } from "./SelectFilter-ATOm0hdn.js";
6
- import { _ as he } from "./app-8samJY5z.js";
7
- import { _ as Q, u as Ue, H as xe } from "./FormItem.vue_vue_type_script_setup_true_lang-DPT2FoIc.js";
5
+ import { S as A } from "./SelectFilter-CG13h83-.js";
6
+ import { _ as he } from "./app-tDHL6k4G.js";
7
+ import { _ as Q, u as Ue, H as xe } from "./FormItem.vue_vue_type_script_setup_true_lang-CUnlKsxk.js";
8
8
  import { _ as be } from "./TableEmptyState.vue_vue_type_script_setup_true_lang-IfAZmWr0.js";
9
9
  import { u as te } from "./useLoading-CXzTpIVv.js";
10
10
  import { u as ae } from "./grant-user-SNiDV22U.js";
11
11
  import { u as se } from "./restaurant-BTpBmfBV.js";
12
- import { u as re } from "./role-BViYS7RK.js";
12
+ import { u as re } from "./role-7ccipEEe.js";
13
13
  import { _ as Ve } from "./FormSection.vue_vue_type_script_setup_true_lang-DknXTYiK.js";
14
14
  const ke = { class: "fm-typo-en-title-md-600" }, Fe = { class: "space-y-40" }, we = { class: "flex gap-8 items-center justify-start" }, Se = /* @__PURE__ */ X({
15
15
  __name: "GrantUserForm",
@@ -5,10 +5,10 @@ import { useSnackbar as I } from "@feedmepos/ui-library";
5
5
  import { _ as z } from "./ResponsiveFabButton.vue_vue_type_script_setup_true_lang-QrqYEy8i.js";
6
6
  import { _ as M } from "./PageLayout.vue_vue_type_script_setup_true_lang-HKK4cbW8.js";
7
7
  import { u as j } from "./restaurant-BTpBmfBV.js";
8
- import { u as H } from "./role-BViYS7RK.js";
8
+ import { u as H } from "./role-7ccipEEe.js";
9
9
  import { u as J } from "./grant-user-SNiDV22U.js";
10
10
  import { u as K } from "./approval-code-jIjkeVEb.js";
11
- import { R as n } from "./app-8samJY5z.js";
11
+ import { R as n } from "./app-tDHL6k4G.js";
12
12
  const Q = { class: "space-y-24" }, ue = /* @__PURE__ */ D({
13
13
  __name: "Main",
14
14
  setup(W) {
@@ -5,12 +5,12 @@ import { _ as x } from "./ResponsiveFabButton.vue_vue_type_script_setup_true_lan
5
5
  import { _ as F } from "./PageLayout.vue_vue_type_script_setup_true_lang-HKK4cbW8.js";
6
6
  import { u as w } from "./restaurant-BTpBmfBV.js";
7
7
  import "@feedmepos/ui-library";
8
- import "./rule-Dxt1ZSQS.js";
9
- import "./lodash-CJ3mHku0.js";
10
- import "./iteration-Dhdew1jW.js";
8
+ import "./rule-7faruCdz.js";
9
+ import "./lodash-D5vM3paU.js";
10
+ import "./index-jxRluZiW.js";
11
11
  import "./useAppStore-DCwd8GWN.js";
12
- import { R as v } from "./app-8samJY5z.js";
13
- import "./role-BViYS7RK.js";
12
+ import { R as v } from "./app-tDHL6k4G.js";
13
+ import "./role-7ccipEEe.js";
14
14
  /* empty css */
15
15
  import "./PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-XHuHin8t.js";
16
16
  const $ = { class: "space-y-24" }, Z = /* @__PURE__ */ M({
@@ -5,18 +5,18 @@ import { useSnackbar as pf } from "@feedmepos/ui-library";
5
5
  import { _ as df } from "./ResponsiveFabButton.vue_vue_type_script_setup_true_lang-QrqYEy8i.js";
6
6
  import { _ as mf } from "./PageLayout.vue_vue_type_script_setup_true_lang-HKK4cbW8.js";
7
7
  import { u as gf } from "./restaurant-BTpBmfBV.js";
8
- import { u as _f } from "./role-BViYS7RK.js";
8
+ import { u as _f } from "./role-7ccipEEe.js";
9
9
  /* empty css */
10
- import "./employee-BcFgm8Rt.js";
11
- import "./lodash-CJ3mHku0.js";
10
+ import "./employee-Bs_2vqBY.js";
11
+ import "./lodash-D5vM3paU.js";
12
12
  import "./useAppStore-DCwd8GWN.js";
13
- import "./iteration-Dhdew1jW.js";
13
+ import "./index-jxRluZiW.js";
14
14
  /* empty css */
15
- import { R as pt } from "./app-8samJY5z.js";
16
- import "./rule-Dxt1ZSQS.js";
17
- import "./useReportPermissions-BiyAfGvZ.js";
18
- import "./dayjs.min-Ba4X_9nY.js";
19
- import "./TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-C99Jr6Ax.js";
15
+ import { R as pt } from "./app-tDHL6k4G.js";
16
+ import "./rule-7faruCdz.js";
17
+ import "./useReportPermissions-FieO4EAD.js";
18
+ import "./dayjs.min-B_XWc0Hu.js";
19
+ import "./TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-CxqxqwyD.js";
20
20
  var Nn = {};
21
21
  /*! xlsx.js (C) 2013-present SheetJS -- http://sheetjs.com */
22
22
  var qt = {};
@@ -0,0 +1,243 @@
1
+ import { defineComponent as I, createElementBlock as u, openBlock as m, normalizeStyle as P, computed as x, resolveComponent as k, createElementVNode as r, createVNode as p, toDisplayString as _, Fragment as L, renderList as S, createCommentVNode as $, withKeys as F, withModifiers as V, normalizeClass as j } from "vue";
2
+ const ee = /* @__PURE__ */ I({
3
+ __name: "Skeleton",
4
+ props: {
5
+ width: { default: "160px" }
6
+ },
7
+ setup(e) {
8
+ return (a, t) => (m(), u("div", {
9
+ class: "h-16 animate-pulse rounded bg-fm-color-neutral-gray-200",
10
+ style: P({ width: e.width })
11
+ }, null, 4));
12
+ }
13
+ });
14
+ function B(e) {
15
+ return e.map((a) => a.restaurantId).filter(Boolean);
16
+ }
17
+ function w(e, a, t) {
18
+ const o = B(a);
19
+ return e.filter((l) => l.managable || l._id === t).map((l) => ({
20
+ label: `${l.profile.code ? `${l.profile.code} - ` : ""}${l.profile.name}`,
21
+ value: l._id,
22
+ disabled: o.includes(l._id) && l._id !== t
23
+ }));
24
+ }
25
+ function C(e, a, t, o) {
26
+ return a ? e.filter((l) => l.restaurants.some((s) => s.id == a)).map((l) => ({
27
+ label: l.name,
28
+ value: l._id,
29
+ disabled: !o.isRoleUsable(l, a) && l._id !== t
30
+ })) : [];
31
+ }
32
+ function K(e, a, t, o) {
33
+ var s, c;
34
+ const l = C(e, a, t, o);
35
+ return ((s = l.find((n) => n.value === t && !n.disabled)) == null ? void 0 : s.value) ?? ((c = l.find((n) => !n.disabled)) == null ? void 0 : c.value) ?? "";
36
+ }
37
+ function N(e, a) {
38
+ const t = B(a), o = e.some(
39
+ (s) => s.managable && !t.includes(s._id)
40
+ ), l = a.every((s) => s.restaurantId && s.roleId);
41
+ return o && l;
42
+ }
43
+ function E(e, a, t, o) {
44
+ var s;
45
+ const l = ((s = e[a]) == null ? void 0 : s.restaurantId) ?? "";
46
+ return o.isRestaurantLocked(l) ? e : e.length === 1 ? [t()] : e.filter((c, n) => n !== a);
47
+ }
48
+ const M = { class: "rounded-lg border border-fm-color-neutral-gray-200 p-16 space-y-16" }, D = { class: "fm-typo-en-title-sm-600" }, G = { class: "space-y-16" }, q = { class: "grid grid-cols-[minmax(0,1fr)_minmax(0,1fr)_auto] gap-16" }, H = { class: "text-sm font-semibold text-fm-color-typo-primary" }, J = { class: "text-sm font-semibold text-fm-color-typo-primary" }, Q = { class: "flex justify-self-end" }, T = ["tabindex", "aria-disabled", "aria-label", "onClick", "onKeydown"], te = /* @__PURE__ */ I({
49
+ __name: "OutletRoleAssignment",
50
+ props: {
51
+ modelValue: {},
52
+ restaurants: {},
53
+ roles: {},
54
+ isRoleUsable: {},
55
+ isRestaurantLocked: { type: Function, default: () => !1 },
56
+ createRow: {},
57
+ title: {},
58
+ restaurantLabel: {},
59
+ roleLabel: {},
60
+ addLabel: {},
61
+ removeLabel: {}
62
+ },
63
+ emits: ["update:modelValue"],
64
+ setup(e, { emit: a }) {
65
+ const t = e, o = a, l = x(() => ({
66
+ isRoleUsable: t.isRoleUsable,
67
+ isRestaurantLocked: t.isRestaurantLocked
68
+ }));
69
+ function s(d) {
70
+ return w(t.restaurants, t.modelValue, d);
71
+ }
72
+ function c(d) {
73
+ return C(t.roles, d.restaurantId, d.roleId, l.value);
74
+ }
75
+ function n(d) {
76
+ return t.isRestaurantLocked(d);
77
+ }
78
+ function U(d, f) {
79
+ const b = t.modelValue[d], v = K(t.roles, f, b.roleId, l.value), h = [...t.modelValue];
80
+ h[d] = { ...b, restaurantId: f, roleId: v }, o("update:modelValue", h);
81
+ }
82
+ function z(d, f) {
83
+ const b = t.modelValue[d], v = [...t.modelValue];
84
+ v[d] = { ...b, roleId: f }, o("update:modelValue", v);
85
+ }
86
+ function O() {
87
+ o("update:modelValue", [...t.modelValue, t.createRow()]);
88
+ }
89
+ function R(d) {
90
+ o(
91
+ "update:modelValue",
92
+ E(t.modelValue, d, t.createRow, l.value)
93
+ );
94
+ }
95
+ const A = x(() => N(t.restaurants, t.modelValue));
96
+ return (d, f) => {
97
+ const b = k("FmSelect"), v = k("FmIcon"), h = k("FmButton");
98
+ return m(), u("div", M, [
99
+ r("div", D, _(e.title), 1),
100
+ r("div", G, [
101
+ r("div", q, [
102
+ r("div", H, _(e.restaurantLabel), 1),
103
+ r("div", J, _(e.roleLabel), 1),
104
+ f[0] || (f[0] = r("div", null, null, -1))
105
+ ]),
106
+ (m(!0), u(L, null, S(e.modelValue, (i, y) => (m(), u("div", {
107
+ key: `${i.restaurantId || "new"}-${y}`,
108
+ class: "grid grid-cols-[minmax(0,1fr)_minmax(0,1fr)_auto] items-center gap-16"
109
+ }, [
110
+ p(b, {
111
+ class: "min-w-0",
112
+ "model-value": i.restaurantId,
113
+ items: s(i.restaurantId),
114
+ multiselect: !1,
115
+ searchable: "",
116
+ "search-debounce": 300,
117
+ placeholder: e.restaurantLabel,
118
+ disabled: n(i.restaurantId),
119
+ "onUpdate:modelValue": (g) => U(y, g)
120
+ }, null, 8, ["model-value", "items", "placeholder", "disabled", "onUpdate:modelValue"]),
121
+ p(b, {
122
+ class: "min-w-0",
123
+ "model-value": i.roleId,
124
+ items: c(i),
125
+ multiselect: !1,
126
+ placeholder: e.roleLabel,
127
+ disabled: !i.restaurantId || n(i.restaurantId),
128
+ "onUpdate:modelValue": (g) => z(y, g)
129
+ }, null, 8, ["model-value", "items", "placeholder", "disabled", "onUpdate:modelValue"]),
130
+ r("div", Q, [
131
+ e.modelValue.length > 1 ? (m(), u("div", {
132
+ key: 0,
133
+ role: "button",
134
+ tabindex: n(i.restaurantId) ? -1 : 0,
135
+ "aria-disabled": n(i.restaurantId),
136
+ class: j(["inline-flex h-40 w-40 shrink-0 items-center justify-center rounded-lg text-fm-color-neutral-gray-400 transition-colors hover:bg-fm-color-neutral-gray-100 focus:outline-none focus:ring-2 focus:ring-fm-color-primary disabled:cursor-not-allowed disabled:text-fm-color-neutral-gray-200 disabled:hover:bg-transparent", {
137
+ "cursor-pointer": !n(i.restaurantId),
138
+ "pointer-events-none": n(i.restaurantId)
139
+ }]),
140
+ "aria-label": e.removeLabel,
141
+ onClick: V((g) => R(y), ["stop"]),
142
+ onKeydown: [
143
+ F(V((g) => R(y), ["prevent", "stop"]), ["enter"]),
144
+ F(V((g) => R(y), ["prevent", "stop"]), ["space"])
145
+ ]
146
+ }, [
147
+ p(v, {
148
+ name: "delete",
149
+ size: "md"
150
+ })
151
+ ], 42, T)) : $("", !0)
152
+ ])
153
+ ]))), 128))
154
+ ]),
155
+ p(h, {
156
+ type: "button",
157
+ variant: "secondary",
158
+ "text-color": "primary",
159
+ "border-color": "primary",
160
+ "prepend-icon": "add",
161
+ label: e.addLabel,
162
+ size: "md",
163
+ disabled: !A.value,
164
+ onClick: V(O, ["stop"])
165
+ }, null, 8, ["label", "disabled"])
166
+ ]);
167
+ };
168
+ }
169
+ }), W = {
170
+ key: 0,
171
+ class: "fm-typo-body-sm-400 text-fm-color-typo-secondary"
172
+ }, le = /* @__PURE__ */ I({
173
+ __name: "PasscodeGenerateButton",
174
+ props: {
175
+ label: {},
176
+ hint: {},
177
+ disabled: { type: Boolean, default: !1 },
178
+ loading: { type: Boolean, default: !1 }
179
+ },
180
+ emits: ["click"],
181
+ setup(e) {
182
+ return (a, t) => {
183
+ const o = k("FmButton");
184
+ return m(), u(L, null, [
185
+ p(o, {
186
+ variant: "secondary",
187
+ "text-color": "primary",
188
+ "border-color": "primary",
189
+ label: e.label,
190
+ size: "md",
191
+ loading: e.loading,
192
+ disabled: e.disabled,
193
+ onClick: t[0] || (t[0] = (l) => a.$emit("click"))
194
+ }, null, 8, ["label", "loading", "disabled"]),
195
+ e.disabled ? (m(), u("div", W, _(e.hint), 1)) : $("", !0)
196
+ ], 64);
197
+ };
198
+ }
199
+ }), X = { class: "flex items-center gap-8" }, Y = ["aria-label"], ae = /* @__PURE__ */ I({
200
+ __name: "PasscodePinField",
201
+ props: {
202
+ modelValue: {},
203
+ masked: { type: Boolean },
204
+ length: { default: 4 },
205
+ toggleLabel: {}
206
+ },
207
+ emits: ["update:modelValue", "update:masked", "complete"],
208
+ setup(e, { emit: a }) {
209
+ const t = a;
210
+ return (o, l) => {
211
+ const s = k("FmPinField"), c = k("FmIcon");
212
+ return m(), u("div", X, [
213
+ p(s, {
214
+ "model-value": e.modelValue,
215
+ length: e.length,
216
+ masked: e.masked,
217
+ "onUpdate:modelValue": l[0] || (l[0] = (n) => t("update:modelValue", n)),
218
+ onComplete: l[1] || (l[1] = (n) => t("complete", n)),
219
+ onFocus: l[2] || (l[2] = (n) => t("update:masked", !1))
220
+ }, null, 8, ["model-value", "length", "masked"]),
221
+ r("button", {
222
+ type: "button",
223
+ class: "flex items-center justify-center rounded-full p-4 hover:bg-fm-color-neutral-gray-100",
224
+ "aria-label": e.toggleLabel,
225
+ onClick: l[3] || (l[3] = (n) => t("update:masked", !e.masked))
226
+ }, [
227
+ p(c, {
228
+ name: e.masked ? "visibility" : "visibility_off",
229
+ size: "md",
230
+ class: "text-fm-color-neutral-gray-300"
231
+ }, null, 8, ["name"])
232
+ ], 8, Y)
233
+ ]);
234
+ };
235
+ }
236
+ });
237
+ export {
238
+ ae as _,
239
+ le as a,
240
+ te as b,
241
+ ee as c,
242
+ B as s
243
+ };
@@ -1,14 +1,15 @@
1
1
  import { defineComponent as Z, ref as v, computed as b, watch as ue, resolveComponent as h, createBlock as de, openBlock as ee, unref as r, withCtx as C, createVNode as m, createElementVNode as y, toDisplayString as G, nextTick as pe, onMounted as fe, createElementBlock as ve, Fragment as Se, h as S } from "vue";
2
2
  import { useI18n as se, useCoreStore as be } from "@feedmepos/mf-common";
3
3
  import { useSnackbar as oe, useDialog as te, useBreakpoints as ne, components as H } from "@feedmepos/ui-library";
4
- import { b as Q, _ as he } from "./app-8samJY5z.js";
4
+ import { v as Q, _ as he } from "./app-tDHL6k4G.js";
5
5
  import { _ as _e } from "./TableEmptyState.vue_vue_type_script_setup_true_lang-IfAZmWr0.js";
6
6
  import { u as ge, _ as Pe } from "./useDiscardConfirm-DPhEV6v0.js";
7
- import { u as ie, c as M, d as ae, p as Y, i as ye, b as we, m as A, o as xe, q as Fe, l as ke, n as Ce, w as Ie } from "./rule-Dxt1ZSQS.js";
8
- import { l as T } from "./lodash-CJ3mHku0.js";
9
- import { c as Ve } from "./iteration-Dhdew1jW.js";
10
- import { u as Re } from "./useLoading-CXzTpIVv.js";
11
- import { _ as Ee } from "./PortalPermissionEditor.vue_vue_type_script_setup_true_lang-Bzq2_BMn.js";
7
+ import { u as ie, c as M, d as ae, p as Y, i as ye, b as we, m as A, n as xe, o as Fe, k as ke, l as Ce, v as Ie } from "./rule-7faruCdz.js";
8
+ import { l as T } from "./lodash-D5vM3paU.js";
9
+ import "./index-jxRluZiW.js";
10
+ import { u as Ve } from "./useLoading-CXzTpIVv.js";
11
+ import { c as Re } from "./iteration-CcXrOMQe.js";
12
+ import { _ as Ee } from "./PortalPermissionEditor.vue_vue_type_script_setup_true_lang-uSdvH81B.js";
12
13
  import { A as je } from "./restaurant-BTpBmfBV.js";
13
14
  const Te = { class: "flex w-full items-center justify-between" }, $e = { class: "fm-typo-en-title-md-600" }, Be = { class: "fm-typo-en-title-sm-600 mt-24" }, Le = { class: "flex items-center justify-start gap-8" }, Ae = /* @__PURE__ */ Z({
14
15
  __name: "PermissionSetForm",
@@ -22,10 +23,10 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
22
23
  const o = K, { t: i } = se(), f = v(!1), $ = b(() => {
23
24
  var e;
24
25
  return (e = o.modelValue) != null && e.id ? i("permissionSet.form.update.title") : i("permissionSet.form.create.title");
25
- }), I = v(), q = oe(), w = te(), { breakpoints: V } = ne(), R = Re(q), l = ie(), d = v({ ...o.modelValue }), a = v([]), p = v([]), B = [(e) => !!e || i("permissionSet.form.nameRequired")], N = b(() => {
26
+ }), I = v(), N = oe(), w = te(), { breakpoints: V } = ne(), R = Ve(N), l = ie(), d = v({ ...o.modelValue }), a = v([]), p = v([]), B = [(e) => !!e || i("permissionSet.form.nameRequired")], O = b(() => {
26
27
  var e;
27
28
  return (e = o.modelValue) != null && e.id ? i("permissionSet.form.update.confirmButtonLabel") : i("permissionSet.form.create.confirmButtonLabel");
28
- }), O = b(
29
+ }), q = b(
29
30
  () => l.permissionSets.value.filter((e) => {
30
31
  var s;
31
32
  return e.id !== ((s = o.modelValue) == null ? void 0 : s.id);
@@ -60,7 +61,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
60
61
  ), P.value = {
61
62
  name: d.value.name ?? "",
62
63
  permissionSetIds: [...a.value],
63
- userPermissions: Ve(p.value)
64
+ userPermissions: Re(p.value)
64
65
  };
65
66
  }
66
67
  ue(f, async (e) => {
@@ -162,7 +163,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
162
163
  "side-sheet-footer": C(() => [
163
164
  y("div", Le, [
164
165
  m(k, {
165
- label: N.value,
166
+ label: O.value,
166
167
  size: "md",
167
168
  variant: "primary",
168
169
  type: "submit",
@@ -194,7 +195,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
194
195
  multiselect: "",
195
196
  searchable: "",
196
197
  "search-debounce": 300,
197
- items: O.value,
198
+ items: q.value,
198
199
  label: r(i)("permissionSet.form.includedSets"),
199
200
  placeholder: r(i)("permissionSet.form.includedSetsPlaceholder"),
200
201
  class: "mt-16",
@@ -215,10 +216,10 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
215
216
  }, 8, ["modelValue", "onOn:clickedAway"]);
216
217
  };
217
218
  }
218
- }), De = { class: "space-y-8" }, qe = { class: "flex justify-end xs:px-16" }, Ne = { class: "flex flex-col h-full overflow-auto" }, Ze = /* @__PURE__ */ Z({
219
+ }), De = { class: "space-y-8" }, Ne = { class: "flex justify-end xs:px-16" }, Oe = { class: "flex flex-col h-full overflow-auto" }, es = /* @__PURE__ */ Z({
219
220
  __name: "PermissionSetList",
220
221
  setup(K, { expose: D }) {
221
- const { t: o } = se(), { customReportPermissions: i, fetchCustomReportPermissions: f } = ae(), $ = oe(), I = te(), { breakpoints: q } = ne(), w = v(""), V = b(() => {
222
+ const { t: o } = se(), { customReportPermissions: i, fetchCustomReportPermissions: f } = ae(), $ = oe(), I = te(), { breakpoints: N } = ne(), w = v(""), V = b(() => {
222
223
  var n;
223
224
  return (n = d.value) == null ? void 0 : n.filter((t) => {
224
225
  const c = w.value.toLowerCase();
@@ -234,7 +235,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
234
235
  var t;
235
236
  a.value = n, (t = R.value) == null || t.trigger();
236
237
  }
237
- const N = [
238
+ const O = [
238
239
  {
239
240
  accessorKey: "name",
240
241
  header: () => o("permissionSet.table.columns.name")
@@ -304,7 +305,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
304
305
  enableSorting: !1
305
306
  }
306
307
  ];
307
- function O() {
308
+ function q() {
308
309
  var n;
309
310
  a.value = void 0, (n = R.value) == null || n.trigger();
310
311
  }
@@ -312,7 +313,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
312
313
  I.open({
313
314
  title: o("permissionSet.form.delete.title"),
314
315
  message: o("permissionSet.form.delete.confirmationMessage", { permissionSetName: n.name }),
315
- minWidth: q.value.lg ? 588 : 0,
316
+ minWidth: N.value.lg ? 588 : 0,
316
317
  primaryActions: {
317
318
  text: o("common.remove"),
318
319
  close: !1,
@@ -337,7 +338,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
337
338
  return fe(() => {
338
339
  p(), f();
339
340
  }), D({
340
- create: O
341
+ create: q
341
342
  }), (n, t) => {
342
343
  const c = h("FmSearch"), _ = h("FmTable");
343
344
  return ee(), ve(Se, null, [
@@ -347,7 +348,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
347
348
  "model-value": a.value
348
349
  }, null, 8, ["model-value"]),
349
350
  y("div", De, [
350
- y("div", qe, [
351
+ y("div", Ne, [
351
352
  m(c, {
352
353
  modelValue: w.value,
353
354
  "onUpdate:modelValue": t[0] || (t[0] = (g) => w.value = g),
@@ -358,7 +359,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
358
359
  ]),
359
360
  m(he, null, {
360
361
  default: C(() => [
361
- y("div", Ne, [
362
+ y("div", Oe, [
362
363
  m(_e, {
363
364
  "is-loading": r(l).isLoading.value,
364
365
  "is-empty": V.value.length === 0,
@@ -368,7 +369,7 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
368
369
  }, {
369
370
  default: C(() => [
370
371
  m(_, {
371
- "column-defs": N,
372
+ "column-defs": O,
372
373
  "row-data": V.value,
373
374
  "page-size": V.value.length,
374
375
  loading: r(l).isLoading.value,
@@ -390,5 +391,5 @@ const Te = { class: "flex w-full items-center justify-between" }, $e = { class:
390
391
  }
391
392
  });
392
393
  export {
393
- Ze as default
394
+ es as default
394
395
  };