@feedmepos/mf-hrm-portal 2.3.2-dev.17 → 2.3.2-dev.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ApprovalCodeList-Bo8IbNxV.js → ApprovalCodeList-Cv4-P7fX.js} +14 -15
- package/dist/{AuditLogList-C7CjPILA.js → AuditLogList-KH-H5uzM.js} +823 -833
- package/dist/ConditionBuilderForm.vue_vue_type_script_setup_true_lang-BQq5xW8d.js +459 -0
- package/dist/EmployeeList-BCjOwL1V.js +896 -0
- package/dist/FormSection.vue_vue_type_script_setup_true_lang-D4e5iSQq.js +90 -0
- package/dist/{GrantUserList-CXWGr3Wo.js → GrantUserList-CfvdU440.js} +15 -16
- package/dist/Main-CVF5eDBd.js +101 -0
- package/dist/{Main-bru10M5U.js → Main-DKKGpzdb.js} +2102 -2097
- package/dist/{Main-DeuWov9n.js → Main-YrCgPqZU.js} +5 -5
- package/dist/MyPosProfile-z84_PtAn.js +360 -0
- package/dist/PasscodePinField.vue_vue_type_script_setup_true_lang-TXPEqa46.js +126 -0
- package/dist/{PermissionSetList--xt0piQz.js → PermissionSetList-9xD_n1VF.js} +136 -137
- package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-IX3av4mS.js +4212 -0
- package/dist/PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-sPatt5hV.js +1797 -0
- package/dist/RoleForm.vue_vue_type_script_setup_true_lang-CSsgsqvl.js +547 -0
- package/dist/RoleList-oSqkcGgN.js +274 -0
- package/dist/{ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-Cqo5kHcF.js → ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-qJhZA2DN.js} +1 -1
- package/dist/{ScheduleGeneralPage-DxhgBLix.js → ScheduleGeneralPage-BxXDcGD4.js} +2 -2
- package/dist/{ScheduleModal.vue_vue_type_script_setup_true_lang-DGPwmNQb.js → ScheduleModal.vue_vue_type_script_setup_true_lang-Dcr2USSq.js} +187 -186
- package/dist/{SchedulePage-oBdEvGWN.js → SchedulePage-C_M2ABMR.js} +20 -20
- package/dist/{SchedulePositionPage-BZps-kKs.js → SchedulePositionPage-XaIHUH4A.js} +3 -3
- package/dist/{SelectFilter-Bs_LCk3L.js → SelectFilter-BzqdpDfg.js} +1 -1
- package/dist/TeamMemberList--WEaatay.js +2082 -0
- package/dist/{TimesheetList-BW6iCigo.js → TimesheetList-D6FG69-S.js} +9 -9
- package/dist/{TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-Dv66Af5C.js → TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-GIIAlhti.js} +3 -3
- package/dist/{app-B8xnhtVI.js → app-DSUfooPD.js} +7973 -4103
- package/dist/app.js +3 -3
- package/dist/{approval-code-B0jU1bvk.js → approval-code-BZYlghBT.js} +1 -1
- package/dist/{dayjs.min-CdpSCqn1.js → dayjs.min-5UvwoDGv.js} +34 -34
- package/dist/{employee-DlFGiUgI.js → employee-CT3TDtIM.js} +48 -47
- package/dist/{grant-user-C3C6glCk.js → grant-user-CgvKn27g.js} +1 -1
- package/dist/{iteration-BM0iyDBd.js → iteration-BFI7vEBg.js} +1 -1
- package/dist/{lodash-KK9U7NAy.js → lodash-DJ0F99PK.js} +1 -1
- package/dist/member-grant-BmthjLCk.js +54 -0
- package/dist/restaurant-CeR-XM1L.js +49 -0
- package/dist/{role-DYCorsOh.js → role-C2QeFrHr.js} +19 -20
- package/dist/rule-CYsTf24V.js +839 -0
- package/dist/src/api/my-pos-profile/index.d.ts +3 -0
- package/dist/src/api/sso-provider/index.d.ts +5 -0
- package/dist/src/api/staff-invite/index.d.ts +16 -0
- package/dist/src/components/CollapsibleWrapper.vue.d.ts +11 -3
- package/dist/src/components/form/SegmentedTabs.vue.d.ts +23 -0
- package/dist/src/composables/useMenuAccess.d.ts +56 -0
- package/dist/src/composables/useSsoProviders.d.ts +19 -0
- package/dist/src/composables/useStaffInviteProviders.d.ts +8 -0
- package/dist/src/composables/useTenant.d.ts +11 -0
- package/dist/src/helpers/member-grant.d.ts +36 -0
- package/dist/src/helpers/my-pos-profile.d.ts +37 -0
- package/dist/src/helpers/permission-set.d.ts +1 -102
- package/dist/src/helpers/pos-assignment-rows.d.ts +28 -0
- package/dist/src/helpers/rule.d.ts +2 -2
- package/dist/src/helpers/staff-invite.d.ts +54 -0
- package/dist/src/helpers/string.d.ts +10 -1
- package/dist/src/router/courtGuard.d.ts +4 -0
- package/dist/src/router/menu-access-guard.d.ts +17 -0
- package/dist/src/router/shared.d.ts +3 -1
- package/dist/src/stores/restaurant.d.ts +7 -7
- package/dist/src/stores/team.d.ts +31 -1
- package/dist/src/types/my-pos-profile.d.ts +24 -0
- package/dist/src/types/sso-provider.d.ts +10 -0
- package/dist/src/types/staff-invite.d.ts +100 -0
- package/dist/src/types/team.d.ts +17 -1
- package/dist/src/views/audit-log/locales/index.d.ts +12 -0
- package/dist/src/views/audit-log/useTraceIdDeepLink.d.ts +1 -1
- package/dist/src/views/hr/locales/index.d.ts +20 -0
- package/dist/src/views/hr/role/RoleForm.vue.d.ts +29 -2
- package/dist/src/views/my-pos-profile/MyPosProfile.vue.d.ts +2 -0
- package/dist/src/views/my-pos-profile/components/PasscodeChangedDialog.vue.d.ts +4 -0
- package/dist/src/views/my-pos-profile/locales/index.d.ts +236 -0
- package/dist/src/views/scheduling/composables/useScheduleOnboardingAvailability.d.ts +1 -1
- package/dist/src/views/scheduling/composables/useScheduleOnboardingWizard.d.ts +1 -1
- package/dist/src/views/scheduling/composables/useScheduleShiftDraft.d.ts +1 -1
- package/dist/src/views/scheduling/composables/useScheduleShiftPopover.d.ts +1 -1
- package/dist/src/views/team/components/BasePermission.vue.d.ts +11 -0
- package/dist/src/views/team/components/ConditionPermission.vue.d.ts +11 -0
- package/dist/src/views/team/components/MemberGrantFields.vue.d.ts +51 -0
- package/dist/src/views/team/{member/MemberInfo.vue.d.ts → components/MemberStatusBadge.vue.d.ts} +2 -2
- package/dist/src/views/team/components/PortalPermissionEditor.vue.d.ts +21 -0
- package/dist/src/views/team/components/PosAssignmentRows.vue.d.ts +44 -0
- package/dist/src/views/team/components/PosRolePermission.vue.d.ts +11 -0
- package/dist/src/views/team/locales/index.d.ts +716 -0
- package/dist/src/views/team/member/AddMemberForm.vue.d.ts +48 -3
- package/dist/src/views/team/member/ExistingMemberNotice.vue.d.ts +11 -0
- package/dist/src/views/team/member/MemberDetailsCard.vue.d.ts +35 -0
- package/dist/src/views/team/member/MemberHeaderCard.vue.d.ts +19 -0
- package/dist/src/views/team/member/TeamMemberList.vue.d.ts +1 -0
- package/dist/string-DZQ1uNjn.js +22 -0
- package/dist/style.css +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{useAppStore-C1lk2Q2j.js → useAppStore-KvMQH09O.js} +1 -1
- package/dist/{useLoading-CXdGsnHm.js → useLoading-4s1zzjal.js} +1 -1
- package/dist/useReportPermissions-BVxVU0SS.js +80 -0
- package/dist/useSsoProviders-CKRDQYcP.js +41 -0
- package/package.json +2 -2
- package/dist/ConditionBuilderForm.vue_vue_type_script_setup_true_lang-C-4BaMN-.js +0 -438
- package/dist/EmployeeList-BOP-gaTp.js +0 -776
- package/dist/FormItem.vue_vue_type_script_setup_true_lang-BEOR-8QD.js +0 -45
- package/dist/FormSection.vue_vue_type_script_setup_true_lang-DknXTYiK.js +0 -49
- package/dist/Main-BrP1frfO.js +0 -96
- package/dist/PasscodePinField.vue_vue_type_script_setup_true_lang-CqG0v0Sz.js +0 -243
- package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-D5nvRsW3.js +0 -4167
- package/dist/PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-DiNDrCy0.js +0 -35
- package/dist/RoleList-BEE-8EQK.js +0 -740
- package/dist/TeamMemberList-DCgNcs4P.js +0 -1154
- package/dist/restaurant-C7o2Yk6j.js +0 -2688
- package/dist/rule-BhGHZqKO.js +0 -783
- package/dist/string-VNuQNweN.js +0 -15
- package/dist/useReportPermissions-D_I4rFVo.js +0 -82
package/dist/app.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineStore as A } from "pinia";
|
|
2
2
|
import { ref as l } from "vue";
|
|
3
|
-
import { g as p, b as s } from "./
|
|
3
|
+
import { g as p, b as s } from "./app-DSUfooPD.js";
|
|
4
4
|
const n = {
|
|
5
5
|
async getApprovalCodes() {
|
|
6
6
|
return p(await s("approval-codes").get(""));
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { z as Q, y as K } from "./app-DSUfooPD.js";
|
|
2
2
|
var E = { exports: {} };
|
|
3
3
|
(function(V, X) {
|
|
4
4
|
(function(W, k) {
|
|
5
5
|
V.exports = k();
|
|
6
6
|
})(K, function() {
|
|
7
|
-
var W = 1e3, k = 6e4, N = 36e5, A = "millisecond", S = "second", w = "minute", O = "hour", M = "day", T = "week", m = "month", U = "quarter",
|
|
7
|
+
var W = 1e3, k = 6e4, N = 36e5, A = "millisecond", S = "second", w = "minute", O = "hour", M = "day", T = "week", m = "month", U = "quarter", y = "year", _ = "date", z = "Invalid Date", q = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, B = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, G = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(s) {
|
|
8
8
|
var n = ["th", "st", "nd", "rd"], t = s % 100;
|
|
9
9
|
return "[" + s + (n[(t - 20) % 10] || n[t] || n[0]) + "]";
|
|
10
10
|
} }, I = function(s, n, t) {
|
|
@@ -20,24 +20,24 @@ var E = { exports: {} };
|
|
|
20
20
|
}, a: function(s) {
|
|
21
21
|
return s < 0 ? Math.ceil(s) || 0 : Math.floor(s);
|
|
22
22
|
}, p: function(s) {
|
|
23
|
-
return { M: m, y
|
|
23
|
+
return { M: m, y, w: T, d: M, D: _, h: O, m: w, s: S, ms: A, Q: U }[s] || String(s || "").toLowerCase().replace(/s$/, "");
|
|
24
24
|
}, u: function(s) {
|
|
25
25
|
return s === void 0;
|
|
26
|
-
} }, x = "en",
|
|
27
|
-
|
|
28
|
-
var
|
|
29
|
-
return s instanceof C || !(!s || !s[
|
|
26
|
+
} }, x = "en", D = {};
|
|
27
|
+
D[x] = G;
|
|
28
|
+
var J = "$isDayjsObject", F = function(s) {
|
|
29
|
+
return s instanceof C || !(!s || !s[J]);
|
|
30
30
|
}, j = function s(n, t, r) {
|
|
31
31
|
var e;
|
|
32
32
|
if (!n) return x;
|
|
33
33
|
if (typeof n == "string") {
|
|
34
34
|
var i = n.toLowerCase();
|
|
35
|
-
|
|
35
|
+
D[i] && (e = i), t && (D[i] = t, e = i);
|
|
36
36
|
var u = n.split("-");
|
|
37
37
|
if (!e && u.length > 1) return s(u[0]);
|
|
38
38
|
} else {
|
|
39
39
|
var o = n.name;
|
|
40
|
-
|
|
40
|
+
D[o] = n, e = o;
|
|
41
41
|
}
|
|
42
42
|
return !r && e && (x = e), e || !r && x;
|
|
43
43
|
}, f = function(s, n) {
|
|
@@ -50,7 +50,7 @@ var E = { exports: {} };
|
|
|
50
50
|
};
|
|
51
51
|
var C = function() {
|
|
52
52
|
function s(t) {
|
|
53
|
-
this.$L = j(t.locale, null, !0), this.parse(t), this.$x = this.$x || t.x || {}, this[
|
|
53
|
+
this.$L = j(t.locale, null, !0), this.parse(t), this.$x = this.$x || t.x || {}, this[J] = !0;
|
|
54
54
|
}
|
|
55
55
|
var n = s.prototype;
|
|
56
56
|
return n.parse = function(t) {
|
|
@@ -74,7 +74,7 @@ var E = { exports: {} };
|
|
|
74
74
|
}, n.$utils = function() {
|
|
75
75
|
return a;
|
|
76
76
|
}, n.isValid = function() {
|
|
77
|
-
return this.$d.toString() !==
|
|
77
|
+
return this.$d.toString() !== z;
|
|
78
78
|
}, n.isSame = function(t, r) {
|
|
79
79
|
var e = f(t);
|
|
80
80
|
return this.startOf(r) <= e && e <= this.endOf(r);
|
|
@@ -90,18 +90,18 @@ var E = { exports: {} };
|
|
|
90
90
|
return this.$d.getTime();
|
|
91
91
|
}, n.startOf = function(t, r) {
|
|
92
92
|
var e = this, i = !!a.u(r) || r, u = a.p(t), o = function(p, $) {
|
|
93
|
-
var
|
|
94
|
-
return i ?
|
|
93
|
+
var v = a.w(e.$u ? Date.UTC(e.$y, $, p) : new Date(e.$y, $, p), e);
|
|
94
|
+
return i ? v : v.endOf(M);
|
|
95
95
|
}, c = function(p, $) {
|
|
96
96
|
return a.w(e.toDate()[p].apply(e.toDate("s"), (i ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice($)), e);
|
|
97
97
|
}, h = this.$W, d = this.$M, l = this.$D, b = "set" + (this.$u ? "UTC" : "");
|
|
98
98
|
switch (u) {
|
|
99
|
-
case
|
|
99
|
+
case y:
|
|
100
100
|
return i ? o(1, 0) : o(31, 11);
|
|
101
101
|
case m:
|
|
102
102
|
return i ? o(1, d) : o(0, d + 1);
|
|
103
103
|
case T:
|
|
104
|
-
var
|
|
104
|
+
var g = this.$locale().weekStart || 0, Y = (h < g ? h + 7 : h) - g;
|
|
105
105
|
return o(i ? l - Y : l + (6 - Y), d);
|
|
106
106
|
case M:
|
|
107
107
|
case _:
|
|
@@ -118,8 +118,8 @@ var E = { exports: {} };
|
|
|
118
118
|
}, n.endOf = function(t) {
|
|
119
119
|
return this.startOf(t, !1);
|
|
120
120
|
}, n.$set = function(t, r) {
|
|
121
|
-
var e, i = a.p(t), u = "set" + (this.$u ? "UTC" : ""), o = (e = {}, e[M] = u + "Date", e[_] = u + "Date", e[m] = u + "Month", e[
|
|
122
|
-
if (i === m || i ===
|
|
121
|
+
var e, i = a.p(t), u = "set" + (this.$u ? "UTC" : ""), o = (e = {}, e[M] = u + "Date", e[_] = u + "Date", e[m] = u + "Month", e[y] = u + "FullYear", e[O] = u + "Hours", e[w] = u + "Minutes", e[S] = u + "Seconds", e[A] = u + "Milliseconds", e)[i], c = i === M ? this.$D + (r - this.$W) : r;
|
|
122
|
+
if (i === m || i === y) {
|
|
123
123
|
var h = this.clone().set(_, 1);
|
|
124
124
|
h.$d[o](c), h.init(), this.$d = h.set(_, Math.min(this.$D, h.daysInMonth())).$d;
|
|
125
125
|
} else o && this.$d[o](c);
|
|
@@ -136,7 +136,7 @@ var E = { exports: {} };
|
|
|
136
136
|
return a.w(l.date(l.date() + Math.round(d * t)), i);
|
|
137
137
|
};
|
|
138
138
|
if (u === m) return this.set(m, this.$M + t);
|
|
139
|
-
if (u ===
|
|
139
|
+
if (u === y) return this.set(y, this.$y + t);
|
|
140
140
|
if (u === M) return o(1);
|
|
141
141
|
if (u === T) return o(7);
|
|
142
142
|
var c = (e = {}, e[w] = k, e[O] = N, e[S] = W, e)[u] || 1, h = this.$d.getTime() + t * c;
|
|
@@ -145,17 +145,17 @@ var E = { exports: {} };
|
|
|
145
145
|
return this.add(-1 * t, r);
|
|
146
146
|
}, n.format = function(t) {
|
|
147
147
|
var r = this, e = this.$locale();
|
|
148
|
-
if (!this.isValid()) return e.invalidDate ||
|
|
149
|
-
var i = t || "YYYY-MM-DDTHH:mm:ssZ", u = a.z(this), o = this.$H, c = this.$m, h = this.$M, d = e.weekdays, l = e.months, b = e.meridiem,
|
|
150
|
-
return $ && ($[
|
|
148
|
+
if (!this.isValid()) return e.invalidDate || z;
|
|
149
|
+
var i = t || "YYYY-MM-DDTHH:mm:ssZ", u = a.z(this), o = this.$H, c = this.$m, h = this.$M, d = e.weekdays, l = e.months, b = e.meridiem, g = function($, v, H, L) {
|
|
150
|
+
return $ && ($[v] || $(r, i)) || H[v].slice(0, L);
|
|
151
151
|
}, Y = function($) {
|
|
152
152
|
return a.s(o % 12 || 12, $, "0");
|
|
153
|
-
}, p = b || function($,
|
|
153
|
+
}, p = b || function($, v, H) {
|
|
154
154
|
var L = $ < 12 ? "AM" : "PM";
|
|
155
155
|
return H ? L.toLowerCase() : L;
|
|
156
156
|
};
|
|
157
|
-
return i.replace(B, function($,
|
|
158
|
-
return
|
|
157
|
+
return i.replace(B, function($, v) {
|
|
158
|
+
return v || function(H) {
|
|
159
159
|
switch (H) {
|
|
160
160
|
case "YY":
|
|
161
161
|
return String(r.$y).slice(-2);
|
|
@@ -166,9 +166,9 @@ var E = { exports: {} };
|
|
|
166
166
|
case "MM":
|
|
167
167
|
return a.s(h + 1, 2, "0");
|
|
168
168
|
case "MMM":
|
|
169
|
-
return
|
|
169
|
+
return g(e.monthsShort, h, l, 3);
|
|
170
170
|
case "MMMM":
|
|
171
|
-
return
|
|
171
|
+
return g(l, h);
|
|
172
172
|
case "D":
|
|
173
173
|
return r.$D;
|
|
174
174
|
case "DD":
|
|
@@ -176,9 +176,9 @@ var E = { exports: {} };
|
|
|
176
176
|
case "d":
|
|
177
177
|
return String(r.$W);
|
|
178
178
|
case "dd":
|
|
179
|
-
return
|
|
179
|
+
return g(e.weekdaysMin, r.$W, d, 2);
|
|
180
180
|
case "ddd":
|
|
181
|
-
return
|
|
181
|
+
return g(e.weekdaysShort, r.$W, d, 3);
|
|
182
182
|
case "dddd":
|
|
183
183
|
return d[r.$W];
|
|
184
184
|
case "H":
|
|
@@ -216,7 +216,7 @@ var E = { exports: {} };
|
|
|
216
216
|
return a.m(u, c);
|
|
217
217
|
};
|
|
218
218
|
switch (o) {
|
|
219
|
-
case
|
|
219
|
+
case y:
|
|
220
220
|
i = l() / 12;
|
|
221
221
|
break;
|
|
222
222
|
case m:
|
|
@@ -247,7 +247,7 @@ var E = { exports: {} };
|
|
|
247
247
|
}, n.daysInMonth = function() {
|
|
248
248
|
return this.endOf(m).$D;
|
|
249
249
|
}, n.$locale = function() {
|
|
250
|
-
return
|
|
250
|
+
return D[this.$L];
|
|
251
251
|
}, n.locale = function(t, r) {
|
|
252
252
|
if (!t) return this.$L;
|
|
253
253
|
var e = this.clone(), i = j(t, r, !0);
|
|
@@ -263,16 +263,16 @@ var E = { exports: {} };
|
|
|
263
263
|
}, n.toString = function() {
|
|
264
264
|
return this.$d.toUTCString();
|
|
265
265
|
}, s;
|
|
266
|
-
}(),
|
|
267
|
-
return f.prototype =
|
|
268
|
-
|
|
266
|
+
}(), Z = C.prototype;
|
|
267
|
+
return f.prototype = Z, [["$ms", A], ["$s", S], ["$m", w], ["$H", O], ["$W", M], ["$M", m], ["$y", y], ["$D", _]].forEach(function(s) {
|
|
268
|
+
Z[s[1]] = function(n) {
|
|
269
269
|
return this.$g(n, s[0], s[1]);
|
|
270
270
|
};
|
|
271
271
|
}), f.extend = function(s, n) {
|
|
272
272
|
return s.$i || (s(n, C, f), s.$i = !0), f;
|
|
273
273
|
}, f.locale = j, f.isDayjs = F, f.unix = function(s) {
|
|
274
274
|
return f(1e3 * s);
|
|
275
|
-
}, f.en =
|
|
275
|
+
}, f.en = D[x], f.Ls = D, f.p = {}, f;
|
|
276
276
|
});
|
|
277
277
|
})(E);
|
|
278
278
|
var R = E.exports;
|
|
@@ -1,23 +1,24 @@
|
|
|
1
|
-
import { d as g } from "./dayjs.min-
|
|
1
|
+
import { d as g } from "./dayjs.min-5UvwoDGv.js";
|
|
2
2
|
import { defineStore as $, storeToRefs as h } from "pinia";
|
|
3
3
|
import { ref as y } from "vue";
|
|
4
|
-
import { s as E } from "./iteration-
|
|
5
|
-
import { b as l, g as m
|
|
4
|
+
import { s as E } from "./iteration-BFI7vEBg.js";
|
|
5
|
+
import { b as l, g as m } from "./app-DSUfooPD.js";
|
|
6
6
|
import { i as v } from "./utils-BZkjJbju.js";
|
|
7
|
-
import { u as P } from "./role-
|
|
7
|
+
import { u as P } from "./role-C2QeFrHr.js";
|
|
8
|
+
import { u as I } from "./restaurant-CeR-XM1L.js";
|
|
8
9
|
const o = {
|
|
9
10
|
async readEmployees() {
|
|
10
11
|
return m(await l().get("/pos-users"));
|
|
11
12
|
},
|
|
12
13
|
async readEmployeesPage(e) {
|
|
13
|
-
var
|
|
14
|
+
var t, i;
|
|
14
15
|
return m(
|
|
15
16
|
await l().get("/pos-users/paged", {
|
|
16
17
|
params: {
|
|
17
18
|
limit: e.limit,
|
|
18
19
|
offset: e.offset,
|
|
19
20
|
search: e.search,
|
|
20
|
-
restaurantIds: (
|
|
21
|
+
restaurantIds: (t = e.restaurantIds) != null && t.length ? e.restaurantIds : void 0,
|
|
21
22
|
roleIds: (i = e.roleIds) != null && i.length ? e.roleIds : void 0,
|
|
22
23
|
includeEmptyPasscode: e.includeEmptyPasscode || void 0
|
|
23
24
|
}
|
|
@@ -34,22 +35,22 @@ const o = {
|
|
|
34
35
|
await l().post("/pos-users/master-user", e)
|
|
35
36
|
).employeeId;
|
|
36
37
|
},
|
|
37
|
-
async migrateToMasterEmployee(e,
|
|
38
|
-
await l().put(`/pos-users/migrate/${e}`,
|
|
38
|
+
async migrateToMasterEmployee(e, t) {
|
|
39
|
+
await l().put(`/pos-users/migrate/${e}`, t);
|
|
39
40
|
},
|
|
40
|
-
async updateEmployee(e,
|
|
41
|
-
await l().put(`/pos-users/${e}`,
|
|
41
|
+
async updateEmployee(e, t) {
|
|
42
|
+
await l().put(`/pos-users/${e}`, t);
|
|
42
43
|
},
|
|
43
|
-
async updateMasterEmployee(e,
|
|
44
|
-
await l().put(`/pos-users/master-user/${e}`,
|
|
44
|
+
async updateMasterEmployee(e, t) {
|
|
45
|
+
await l().put(`/pos-users/master-user/${e}`, t);
|
|
45
46
|
},
|
|
46
47
|
async deleteEmployee(e) {
|
|
47
48
|
await l().put(`/pos-users/${e._id}`, {
|
|
48
49
|
user: e,
|
|
49
50
|
roles: [],
|
|
50
|
-
previousRoles: e.restaurants.map((
|
|
51
|
-
restaurantId:
|
|
52
|
-
roleId:
|
|
51
|
+
previousRoles: e.restaurants.map((t) => ({
|
|
52
|
+
restaurantId: t.restaurantId,
|
|
53
|
+
roleId: t.roleId
|
|
53
54
|
}))
|
|
54
55
|
});
|
|
55
56
|
},
|
|
@@ -57,9 +58,9 @@ const o = {
|
|
|
57
58
|
await l().put(`/pos-users/master-user/${e._id}`, {
|
|
58
59
|
user: e,
|
|
59
60
|
roles: [],
|
|
60
|
-
previousRoles: e.restaurants.map((
|
|
61
|
-
restaurantId:
|
|
62
|
-
roleId:
|
|
61
|
+
previousRoles: e.restaurants.map((t) => ({
|
|
62
|
+
restaurantId: t.restaurantId,
|
|
63
|
+
roleId: t.roleId
|
|
63
64
|
}))
|
|
64
65
|
});
|
|
65
66
|
},
|
|
@@ -76,9 +77,9 @@ const o = {
|
|
|
76
77
|
}
|
|
77
78
|
};
|
|
78
79
|
async function x(e) {
|
|
79
|
-
const
|
|
80
|
+
const t = P().roles.value, { restaurants: i } = I(), c = new Map(
|
|
80
81
|
i.value.map((a) => [a._id, a.profile.name])
|
|
81
|
-
), u = new Map(
|
|
82
|
+
), u = new Map(t.map((a) => [a._id, a.name])), r = /* @__PURE__ */ new Map();
|
|
82
83
|
for (const a of e) {
|
|
83
84
|
const n = {
|
|
84
85
|
restaurantId: a.restaurantId,
|
|
@@ -102,8 +103,8 @@ async function x(e) {
|
|
|
102
103
|
return E([...r.values()], { selector: "name" });
|
|
103
104
|
}
|
|
104
105
|
function M(e) {
|
|
105
|
-
const { restaurants:
|
|
106
|
-
|
|
106
|
+
const { restaurants: t } = I(), i = P().roles.value, c = new Map(
|
|
107
|
+
t.value.map((a) => [a._id, a])
|
|
107
108
|
), u = new Map(i.map((a) => [a._id, a.name])), r = e.restaurantRole[0];
|
|
108
109
|
return {
|
|
109
110
|
_id: e._id,
|
|
@@ -131,56 +132,56 @@ function M(e) {
|
|
|
131
132
|
};
|
|
132
133
|
}
|
|
133
134
|
const T = $("hrm-employee", () => {
|
|
134
|
-
const e = I(),
|
|
135
|
+
const e = I(), t = y([]), i = y([]), c = y(0), u = y(!1);
|
|
135
136
|
async function r() {
|
|
136
137
|
try {
|
|
137
138
|
u.value = !0, await e.readRestaurants();
|
|
138
|
-
const
|
|
139
|
-
|
|
139
|
+
const s = await o.readEmployees();
|
|
140
|
+
t.value = await x(s);
|
|
140
141
|
} finally {
|
|
141
142
|
u.value = !1;
|
|
142
143
|
}
|
|
143
144
|
}
|
|
144
|
-
async function a(
|
|
145
|
+
async function a(s) {
|
|
145
146
|
try {
|
|
146
147
|
u.value = !0, await e.readRestaurants();
|
|
147
|
-
const p = await o.readEmployeesPage(
|
|
148
|
+
const p = await o.readEmployeesPage(s);
|
|
148
149
|
i.value = p.items.map(M), c.value = p.total;
|
|
149
150
|
} finally {
|
|
150
151
|
u.value = !1;
|
|
151
152
|
}
|
|
152
153
|
}
|
|
153
|
-
async function n(
|
|
154
|
+
async function n(s, p) {
|
|
154
155
|
await e.readRestaurants();
|
|
155
|
-
const w = p ?? (await o.readEmployeesPage({ ...
|
|
156
|
-
return w === 0 ? [] : (await o.readEmployeesPage({ ...
|
|
156
|
+
const w = p ?? (await o.readEmployeesPage({ ...s, limit: 1, offset: 0 })).total;
|
|
157
|
+
return w === 0 ? [] : (await o.readEmployeesPage({ ...s, limit: w, offset: 0 })).items.map(M);
|
|
157
158
|
}
|
|
158
|
-
async function d(
|
|
159
|
-
return o.createEmployee(
|
|
159
|
+
async function d(s) {
|
|
160
|
+
return o.createEmployee(s);
|
|
160
161
|
}
|
|
161
|
-
async function f(
|
|
162
|
-
await o.updateEmployee(
|
|
162
|
+
async function f(s, p) {
|
|
163
|
+
await o.updateEmployee(s, p);
|
|
163
164
|
}
|
|
164
|
-
async function _(
|
|
165
|
-
await o.deleteEmployee(
|
|
165
|
+
async function _(s) {
|
|
166
|
+
await o.deleteEmployee(s);
|
|
166
167
|
}
|
|
167
|
-
async function U(
|
|
168
|
-
await o.deleteMasterEmployee(
|
|
168
|
+
async function U(s) {
|
|
169
|
+
await o.deleteMasterEmployee(s);
|
|
169
170
|
}
|
|
170
|
-
async function Y(
|
|
171
|
-
return o.createMasterEmployee(
|
|
171
|
+
async function Y(s) {
|
|
172
|
+
return o.createMasterEmployee(s);
|
|
172
173
|
}
|
|
173
|
-
async function N(
|
|
174
|
-
await o.updateMasterEmployee(
|
|
174
|
+
async function N(s, p) {
|
|
175
|
+
await o.updateMasterEmployee(s, p);
|
|
175
176
|
}
|
|
176
|
-
async function S(
|
|
177
|
-
await o.migrateToMasterEmployee(
|
|
177
|
+
async function S(s, p) {
|
|
178
|
+
await o.migrateToMasterEmployee(s, p);
|
|
178
179
|
}
|
|
179
180
|
async function D() {
|
|
180
181
|
await o.syncUsersMeta();
|
|
181
182
|
}
|
|
182
183
|
return {
|
|
183
|
-
employees:
|
|
184
|
+
employees: t,
|
|
184
185
|
listEmployees: i,
|
|
185
186
|
totalEmployees: c,
|
|
186
187
|
isLoading: u,
|
|
@@ -196,7 +197,7 @@ const T = $("hrm-employee", () => {
|
|
|
196
197
|
migrateToMasterUser: S,
|
|
197
198
|
syncUsersMeta: D
|
|
198
199
|
};
|
|
199
|
-
}),
|
|
200
|
+
}), B = () => {
|
|
200
201
|
const e = T();
|
|
201
202
|
return {
|
|
202
203
|
...e,
|
|
@@ -205,5 +206,5 @@ const T = $("hrm-employee", () => {
|
|
|
205
206
|
};
|
|
206
207
|
export {
|
|
207
208
|
o as E,
|
|
208
|
-
|
|
209
|
+
B as u
|
|
209
210
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineStore as f } from "pinia";
|
|
2
2
|
import { ref as u } from "vue";
|
|
3
|
-
import { g as s,
|
|
3
|
+
import { g as s, e as v, b as o } from "./app-DSUfooPD.js";
|
|
4
4
|
const c = {
|
|
5
5
|
async getGrantUsers() {
|
|
6
6
|
return s(await o("grant").get(""));
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { y as B } from "./app-DSUfooPD.js";
|
|
2
2
|
var ma = {}, Zt = {}, l = {}, ji = {}, Ei = {}, Ii = {}, Dn = {};
|
|
3
3
|
(function(e) {
|
|
4
4
|
Object.defineProperty(e, "__esModule", { value: !0 }), e.getParsedType = e.ZodParsedType = e.util = void 0;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { k as n } from "./app-DSUfooPD.js";
|
|
2
|
+
import { z as u } from "./rule-CYsTf24V.js";
|
|
3
|
+
const a = [
|
|
4
|
+
n.Subject.Business.restaurant,
|
|
5
|
+
n.Subject.Business.role,
|
|
6
|
+
n.Subject.Restaurant.restaurant,
|
|
7
|
+
n.Subject.Business.inventory_stock
|
|
8
|
+
], c = (s) => a.includes(s.subject);
|
|
9
|
+
function l(s, t) {
|
|
10
|
+
return t.length > 0 || s.some((o) => !o.inverted && !c(o));
|
|
11
|
+
}
|
|
12
|
+
function d(s) {
|
|
13
|
+
return s.filter(c);
|
|
14
|
+
}
|
|
15
|
+
const b = {
|
|
16
|
+
customPermissions: [],
|
|
17
|
+
permissions: [],
|
|
18
|
+
permissionSetIds: [],
|
|
19
|
+
posUser: void 0
|
|
20
|
+
};
|
|
21
|
+
function S(s) {
|
|
22
|
+
const { customPermissions: t, permissions: o } = u({
|
|
23
|
+
userPermissions: s.userPermissions,
|
|
24
|
+
inheritedPermissions: s.inheritedPermissions,
|
|
25
|
+
reportSubjects: s.reportSubjects,
|
|
26
|
+
defaultReportSubjects: s.defaultReportSubjects
|
|
27
|
+
}), { posUser: e, savedPosUser: r } = s;
|
|
28
|
+
return {
|
|
29
|
+
customPermissions: t,
|
|
30
|
+
permissions: o,
|
|
31
|
+
permissionSetIds: s.permissionSetIds,
|
|
32
|
+
posUser: e ? {
|
|
33
|
+
...e,
|
|
34
|
+
name: e.name || (r == null ? void 0 : r.name) || s.fallbackName,
|
|
35
|
+
code: e.code || (r == null ? void 0 : r.code) || "",
|
|
36
|
+
passcode: e.passcode,
|
|
37
|
+
roles: e.roles.filter((i) => !!i.roleId)
|
|
38
|
+
} : e === null ? null : void 0
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
function f(s, t) {
|
|
42
|
+
const { posUser: o, ...e } = s;
|
|
43
|
+
if (!o || !t || o.passcode !== t.passcode) return { ...e, posUser: o };
|
|
44
|
+
const { passcode: r, ...i } = o;
|
|
45
|
+
return { ...e, posUser: i };
|
|
46
|
+
}
|
|
47
|
+
export {
|
|
48
|
+
b as E,
|
|
49
|
+
a as W,
|
|
50
|
+
S as b,
|
|
51
|
+
l as h,
|
|
52
|
+
f as t,
|
|
53
|
+
d as w
|
|
54
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { defineStore as d, storeToRefs as v } from "pinia";
|
|
2
|
+
import { ref as i } from "vue";
|
|
3
|
+
import { b as c, g as p, u as m } from "./app-DSUfooPD.js";
|
|
4
|
+
const R = {
|
|
5
|
+
async readRestaurants() {
|
|
6
|
+
return p(await c().get("/hr-restaurants"));
|
|
7
|
+
},
|
|
8
|
+
async saveOperationalHours(n, s) {
|
|
9
|
+
await c(`restaurants/${n}/schedules`).patch(
|
|
10
|
+
"operational-hours",
|
|
11
|
+
{ operatingHours: s }
|
|
12
|
+
);
|
|
13
|
+
}
|
|
14
|
+
}, g = d("hrm-restaurant", () => {
|
|
15
|
+
const n = m(), s = i([]), r = i(!1), u = i(null);
|
|
16
|
+
let a = null, e = null;
|
|
17
|
+
async function f(o = !1) {
|
|
18
|
+
const t = n.id.value ?? null;
|
|
19
|
+
if (!t) {
|
|
20
|
+
s.value = [], u.value = null, a = null, e = null;
|
|
21
|
+
return;
|
|
22
|
+
}
|
|
23
|
+
if (u.value && u.value !== t && (s.value = [], u.value = null), e && e !== t && (a = null, e = null), !o && u.value === t) return;
|
|
24
|
+
if (!o && a && e === t)
|
|
25
|
+
return await a;
|
|
26
|
+
let l = null;
|
|
27
|
+
try {
|
|
28
|
+
r.value = !0, l = (async () => {
|
|
29
|
+
s.value = await R.readRestaurants(), u.value = t;
|
|
30
|
+
})(), a = l, e = t, await l;
|
|
31
|
+
} finally {
|
|
32
|
+
a === l && (a = null, e = null), r.value = !1;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
return {
|
|
36
|
+
restaurants: s,
|
|
37
|
+
isLoading: r,
|
|
38
|
+
readRestaurants: f
|
|
39
|
+
};
|
|
40
|
+
}), I = () => {
|
|
41
|
+
const n = g();
|
|
42
|
+
return {
|
|
43
|
+
...n,
|
|
44
|
+
...v(n)
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
export {
|
|
48
|
+
I as u
|
|
49
|
+
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineStore as
|
|
1
|
+
import { defineStore as _, storeToRefs as x } from "pinia";
|
|
2
2
|
import { ref as w } from "vue";
|
|
3
|
-
import {
|
|
4
|
-
import { s as
|
|
5
|
-
import {
|
|
3
|
+
import { g as f, b as p, u as b } from "./app-DSUfooPD.js";
|
|
4
|
+
import { s as y } from "./iteration-BFI7vEBg.js";
|
|
5
|
+
import { u as v } from "./restaurant-CeR-XM1L.js";
|
|
6
6
|
const R = {
|
|
7
7
|
async readRoles() {
|
|
8
8
|
return f(await p().get("/pos-roles"));
|
|
@@ -23,7 +23,7 @@ const R = {
|
|
|
23
23
|
}
|
|
24
24
|
};
|
|
25
25
|
async function m(e) {
|
|
26
|
-
const { restaurants: c } =
|
|
26
|
+
const { restaurants: c } = v(), u = e.reduce((n, a) => {
|
|
27
27
|
var d;
|
|
28
28
|
const s = n.findIndex((o) => o._id === a._id), r = {
|
|
29
29
|
id: a.restaurantId,
|
|
@@ -32,16 +32,15 @@ async function m(e) {
|
|
|
32
32
|
return s < 0 ? n.push({
|
|
33
33
|
...a,
|
|
34
34
|
restaurants: [r]
|
|
35
|
-
}) : n[s].restaurants.some((o) => o.id === a.restaurantId) || (n[s].restaurants =
|
|
35
|
+
}) : n[s].restaurants.some((o) => o.id === a.restaurantId) || (n[s].restaurants = y([...n[s].restaurants, r], { selector: "name" })), n;
|
|
36
36
|
}, []);
|
|
37
|
-
return
|
|
37
|
+
return y(u, { selector: "name" });
|
|
38
38
|
}
|
|
39
|
-
const h =
|
|
40
|
-
const
|
|
39
|
+
const h = _("hrm-role", () => {
|
|
40
|
+
const e = b(), c = v(), u = w([]), n = w(!1), a = w(null);
|
|
41
41
|
let s = null, r = null;
|
|
42
42
|
async function d(l = !1) {
|
|
43
|
-
|
|
44
|
-
const t = ((y = e.value) == null ? void 0 : y._id) ?? null;
|
|
43
|
+
const t = e.id.value ?? null;
|
|
45
44
|
if (!t) {
|
|
46
45
|
u.value = [], a.value = null, s = null, r = null;
|
|
47
46
|
return;
|
|
@@ -53,8 +52,8 @@ const h = x("hrm-role", () => {
|
|
|
53
52
|
try {
|
|
54
53
|
n.value = !0, i = (async () => {
|
|
55
54
|
await c.readRestaurants();
|
|
56
|
-
const
|
|
57
|
-
u.value = await m(
|
|
55
|
+
const S = await R.readRoles();
|
|
56
|
+
u.value = await m(S), a.value = t;
|
|
58
57
|
})(), s = i, r = t, await i;
|
|
59
58
|
} finally {
|
|
60
59
|
s === i && (s = null, r = null), n.value = !1;
|
|
@@ -64,11 +63,11 @@ const h = x("hrm-role", () => {
|
|
|
64
63
|
const t = await R.createRole(l);
|
|
65
64
|
u.value = await m(t);
|
|
66
65
|
}
|
|
67
|
-
async function
|
|
66
|
+
async function I(l, t) {
|
|
68
67
|
const i = await R.updateRole(l, t);
|
|
69
68
|
u.value = await m(i);
|
|
70
69
|
}
|
|
71
|
-
async function
|
|
70
|
+
async function g(l) {
|
|
72
71
|
const t = await R.deleteRole(l);
|
|
73
72
|
u.value = await m(t);
|
|
74
73
|
}
|
|
@@ -77,16 +76,16 @@ const h = x("hrm-role", () => {
|
|
|
77
76
|
isLoading: n,
|
|
78
77
|
readRoles: d,
|
|
79
78
|
createRole: o,
|
|
80
|
-
updateRole:
|
|
81
|
-
deleteRole:
|
|
79
|
+
updateRole: I,
|
|
80
|
+
deleteRole: g
|
|
82
81
|
};
|
|
83
|
-
}),
|
|
82
|
+
}), C = () => {
|
|
84
83
|
const e = h();
|
|
85
84
|
return {
|
|
86
85
|
...e,
|
|
87
|
-
...
|
|
86
|
+
...x(e)
|
|
88
87
|
};
|
|
89
88
|
};
|
|
90
89
|
export {
|
|
91
|
-
|
|
90
|
+
C as u
|
|
92
91
|
};
|