@feedmepos/mf-hrm-portal 2.3.2-dev.7 → 2.3.2-dev.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ApprovalCodeList-Bw0E-hZl.js → ApprovalCodeList-gb0bre9J.js} +7 -7
- package/dist/{AuditLogList-CA-_t77n.js → AuditLogList-9cwS6bL7.js} +795 -719
- package/dist/{ConditionBuilderForm.vue_vue_type_script_setup_true_lang-LtjNCAFN.js → ConditionBuilderForm.vue_vue_type_script_setup_true_lang-DR-c15gr.js} +2 -2
- package/dist/{EmployeeList-D_bX0EhQ.js → EmployeeList-DjyoW1we.js} +8 -8
- package/dist/{FormSection.vue_vue_type_script_setup_true_lang-CyZxQa-b.js → FormSection.vue_vue_type_script_setup_true_lang-BBWlADve.js} +1 -1
- package/dist/{GrantUserList-Cg7ITk_M.js → GrantUserList-yU2NqFVO.js} +8 -8
- package/dist/{Main-Bl-Ocx1G.js → Main-4KwMqF3h.js} +5 -5
- package/dist/{Main-BaB4vgI5.js → Main-BS_Lk_eB.js} +1005 -999
- package/dist/{Main-D5wi42fp.js → Main-BuG7SPnC.js} +10 -10
- package/dist/MyPosProfile-CuDzRaRS.js +360 -0
- package/dist/{PermissionSetList-kgG9H3DX.js → PermissionSetList-D7SS1iAr.js} +30 -29
- package/dist/{PortalPermissionEditor.vue_vue_type_script_setup_true_lang-y1YcZpGA.js → PortalPermissionEditor.vue_vue_type_script_setup_true_lang-u1UlV2Aw.js} +902 -901
- package/dist/{PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-fQyCtDXM.js → PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-CYkv2x_y.js} +1 -1
- package/dist/{RoleForm.vue_vue_type_script_setup_true_lang-3Q8udk43.js → RoleForm.vue_vue_type_script_setup_true_lang-hiMgwiya.js} +9 -9
- package/dist/{RoleList-Cmz97HHP.js → RoleList-B3P-LQYV.js} +7 -7
- package/dist/{ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-CggEy3OI.js → ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang--dsZOhnv.js} +1 -1
- package/dist/{ScheduleGeneralPage-B39k3SQH.js → ScheduleGeneralPage-Pq6ufiDu.js} +2 -2
- package/dist/{ScheduleModal.vue_vue_type_script_setup_true_lang-C5j3D4eF.js → ScheduleModal.vue_vue_type_script_setup_true_lang-DKFJLsTW.js} +4 -4
- package/dist/{SchedulePage-AVmRkFi1.js → SchedulePage-8EAOfiJx.js} +189 -201
- package/dist/{SchedulePositionPage-3rE-O8CG.js → SchedulePositionPage-CGXeUnju.js} +3 -3
- package/dist/{SelectFilter-R7ry_GEg.js → SelectFilter-C-UEVLla.js} +1 -1
- package/dist/{TeamMemberList-CvDnIILn.js → TeamMemberList-Bd1O44Ur.js} +102 -101
- package/dist/TimesheetList-CSCmigCM.js +437 -0
- package/dist/{app-DKUCzcrc.js → app-BohKQtlz.js} +82 -14
- package/dist/app.js +1 -1
- package/dist/{approval-code-nsETgIry.js → approval-code-Bfvxsg8h.js} +4 -4
- package/dist/{dayjs.min-CtULWW1N.js → dayjs.min-C0MqTPg1.js} +1 -1
- package/dist/employee-DWxT78W2.js +172 -0
- package/dist/{grant-user-Dpa_Rl6j.js → grant-user-LZ3b6siI.js} +2 -2
- package/dist/{iteration-DpHBtiyr.js → index-DDDG-LHm.js} +698 -726
- package/dist/iteration-CcXrOMQe.js +30 -0
- package/dist/{lodash-YaHCUo_F.js → lodash-BRqMda7F.js} +1 -1
- package/dist/{member-grant-CEokFI3_.js → member-grant-a3AGCWfT.js} +2 -2
- package/dist/{restaurant-CDFKqEFm.js → restaurant-pL7vHt-H.js} +2 -2
- package/dist/{role-DyBVVlEA.js → role--EKCVqho.js} +8 -7
- package/dist/{rule-xErZqYmH.js → rule-Db3gFVHx.js} +83 -82
- package/dist/src/api/audit-log/index.d.ts +2 -0
- package/dist/src/api/employee/index.d.ts +1 -2
- package/dist/src/stores/approval-code.d.ts +1 -1
- package/dist/src/stores/employee.d.ts +3 -9
- package/dist/src/stores/grant-user.d.ts +1 -1
- package/dist/src/stores/permission-assignment.d.ts +2 -2
- package/dist/src/stores/permission-set.d.ts +2 -2
- package/dist/src/stores/restaurant.d.ts +2 -2
- package/dist/src/stores/role.d.ts +2 -2
- package/dist/src/stores/team.d.ts +1 -1
- package/dist/src/stores/timesheet.d.ts +62 -47
- package/dist/src/types/timesheet.d.ts +3 -0
- package/dist/src/views/audit-log/locales/index.d.ts +28 -0
- package/dist/src/views/audit-log/useTraceIdDeepLink.d.ts +19 -0
- package/dist/src/views/my-pos-profile/components/PasscodeChangedDialog.vue.d.ts +1 -1
- package/dist/src/views/my-pos-profile/locales/index.d.ts +40 -0
- package/dist/style.css +1 -1
- package/dist/timesheet-NYW1P4rf.js +76 -0
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{useAppStore-BqsvPsPB.js → useAppStore-DV13z6oc.js} +1 -1
- package/dist/{useLoading-BS1bnZg1.js → useLoading-Fcnnfywt.js} +1 -1
- package/dist/useMessage-_ywT_N9X.js +17 -0
- package/dist/{useReportPermissions-DJEhkyGc.js → useReportPermissions-BcyVoKVq.js} +13 -13
- package/package.json +3 -3
- package/dist/MyPosProfile-CUG_201f.js +0 -290
- package/dist/TimesheetList-DYoglTi8.js +0 -401
- package/dist/TimesheetList.vue_vue_type_style_index_0_scoped_d0c6fd51_lang-DBpzyQ17.js +0 -63
- package/dist/employee-DlsSqR3i.js +0 -210
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineStore as
|
|
1
|
+
import { defineStore as A } from "pinia";
|
|
2
2
|
import { ref as l } from "vue";
|
|
3
|
-
import { g as p, b as s } from "./app-
|
|
3
|
+
import { g as p, b as s } from "./app-BohKQtlz.js";
|
|
4
4
|
const n = {
|
|
5
5
|
async getApprovalCodes() {
|
|
6
6
|
return p(await s("approval-codes").get(""));
|
|
@@ -15,7 +15,7 @@ const n = {
|
|
|
15
15
|
})
|
|
16
16
|
);
|
|
17
17
|
}
|
|
18
|
-
},
|
|
18
|
+
}, C = A("hrm-approval-code", () => {
|
|
19
19
|
const r = l([]), a = l(!1);
|
|
20
20
|
async function d() {
|
|
21
21
|
a.value = !0;
|
|
@@ -52,7 +52,7 @@ const n = {
|
|
|
52
52
|
createApprovalCodes: v,
|
|
53
53
|
revokeApprovalCode: i
|
|
54
54
|
};
|
|
55
|
-
}), g =
|
|
55
|
+
}), g = C;
|
|
56
56
|
export {
|
|
57
57
|
g as u
|
|
58
58
|
};
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
import { d as S } from "./dayjs.min-C0MqTPg1.js";
|
|
2
|
+
import { defineStore as _, storeToRefs as $ } from "pinia";
|
|
3
|
+
import { ref as u } from "vue";
|
|
4
|
+
import "./index-DDDG-LHm.js";
|
|
5
|
+
import { b as n, g as m } from "./app-BohKQtlz.js";
|
|
6
|
+
import { s as h } from "./iteration-CcXrOMQe.js";
|
|
7
|
+
import { i as T } from "./utils-BZkjJbju.js";
|
|
8
|
+
import { u as x } from "./role--EKCVqho.js";
|
|
9
|
+
import { u as f } from "./restaurant-pL7vHt-H.js";
|
|
10
|
+
const r = {
|
|
11
|
+
async readEmployeesPage(e) {
|
|
12
|
+
var s, l;
|
|
13
|
+
return m(
|
|
14
|
+
await n().get("/pos-users/paged", {
|
|
15
|
+
params: {
|
|
16
|
+
limit: e.limit,
|
|
17
|
+
offset: e.offset,
|
|
18
|
+
search: e.search,
|
|
19
|
+
restaurantIds: (s = e.restaurantIds) != null && s.length ? e.restaurantIds : void 0,
|
|
20
|
+
roleIds: (l = e.roleIds) != null && l.length ? e.roleIds : void 0,
|
|
21
|
+
includeEmptyPasscode: e.includeEmptyPasscode || void 0
|
|
22
|
+
}
|
|
23
|
+
})
|
|
24
|
+
);
|
|
25
|
+
},
|
|
26
|
+
async createEmployee(e) {
|
|
27
|
+
return m(
|
|
28
|
+
await n().post("/pos-users", e)
|
|
29
|
+
).employeeId;
|
|
30
|
+
},
|
|
31
|
+
async createMasterEmployee(e) {
|
|
32
|
+
return m(
|
|
33
|
+
await n().post("/pos-users/master-user", e)
|
|
34
|
+
).employeeId;
|
|
35
|
+
},
|
|
36
|
+
async migrateToMasterEmployee(e, s) {
|
|
37
|
+
await n().put(`/pos-users/migrate/${e}`, s);
|
|
38
|
+
},
|
|
39
|
+
async updateEmployee(e, s) {
|
|
40
|
+
await n().put(`/pos-users/${e}`, s);
|
|
41
|
+
},
|
|
42
|
+
async updateMasterEmployee(e, s) {
|
|
43
|
+
await n().put(`/pos-users/master-user/${e}`, s);
|
|
44
|
+
},
|
|
45
|
+
async deleteEmployee(e) {
|
|
46
|
+
await n().put(`/pos-users/${e._id}`, {
|
|
47
|
+
user: e,
|
|
48
|
+
roles: [],
|
|
49
|
+
previousRoles: e.restaurants.map((s) => ({
|
|
50
|
+
restaurantId: s.restaurantId,
|
|
51
|
+
roleId: s.roleId
|
|
52
|
+
}))
|
|
53
|
+
});
|
|
54
|
+
},
|
|
55
|
+
async deleteMasterEmployee(e) {
|
|
56
|
+
await n().put(`/pos-users/master-user/${e._id}`, {
|
|
57
|
+
user: e,
|
|
58
|
+
roles: [],
|
|
59
|
+
previousRoles: e.restaurants.map((s) => ({
|
|
60
|
+
restaurantId: s.restaurantId,
|
|
61
|
+
roleId: s.roleId
|
|
62
|
+
}))
|
|
63
|
+
});
|
|
64
|
+
},
|
|
65
|
+
async generateEmployeePasscode(e) {
|
|
66
|
+
return `${m(
|
|
67
|
+
await n().post("/pos-users/generate-passcode", {
|
|
68
|
+
restaurantIds: e.restaurantIds,
|
|
69
|
+
excludePosUserId: e.excludePosUserId
|
|
70
|
+
})
|
|
71
|
+
)}`;
|
|
72
|
+
},
|
|
73
|
+
async syncUsersMeta() {
|
|
74
|
+
await n().post("/pos-users/create-users-meta");
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
function E(e) {
|
|
78
|
+
const { restaurants: s } = f(), l = x().roles.value, c = new Map(
|
|
79
|
+
s.value.map((a) => [a._id, a])
|
|
80
|
+
), d = new Map(l.map((a) => [a._id, a.name])), p = e.restaurantRole[0];
|
|
81
|
+
return {
|
|
82
|
+
_id: e._id,
|
|
83
|
+
name: e.name,
|
|
84
|
+
code: e.code,
|
|
85
|
+
passcode: e.passcode,
|
|
86
|
+
isMasterUser: e.isMasterUser,
|
|
87
|
+
isRestricted: e.isRestricted,
|
|
88
|
+
restaurantId: (p == null ? void 0 : p.restaurantId) || "",
|
|
89
|
+
role: (p == null ? void 0 : p.roleId) || "",
|
|
90
|
+
since: S(T(e._id)).format("DD/MM/YYYY"),
|
|
91
|
+
restaurants: h(
|
|
92
|
+
e.restaurantRole.map((a) => {
|
|
93
|
+
const i = c.get(a.restaurantId);
|
|
94
|
+
return {
|
|
95
|
+
restaurantId: a.restaurantId,
|
|
96
|
+
restaurantName: (i == null ? void 0 : i.profile.name) || "",
|
|
97
|
+
restaurantCode: (i == null ? void 0 : i.profile.code) ?? void 0,
|
|
98
|
+
roleId: a.roleId,
|
|
99
|
+
roleName: d.get(a.roleId) || ""
|
|
100
|
+
};
|
|
101
|
+
}),
|
|
102
|
+
{ selector: "restaurantName" }
|
|
103
|
+
)
|
|
104
|
+
};
|
|
105
|
+
}
|
|
106
|
+
const D = _("hrm-employee", () => {
|
|
107
|
+
const e = f(), s = u([]), l = u([]), c = u(0), d = u(!1);
|
|
108
|
+
async function p(t) {
|
|
109
|
+
try {
|
|
110
|
+
d.value = !0, await e.readRestaurants();
|
|
111
|
+
const o = await r.readEmployeesPage(t);
|
|
112
|
+
l.value = o.items.map(E), c.value = o.total;
|
|
113
|
+
} finally {
|
|
114
|
+
d.value = !1;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
async function a(t, o) {
|
|
118
|
+
await e.readRestaurants();
|
|
119
|
+
const y = o ?? (await r.readEmployeesPage({ ...t, limit: 1, offset: 0 })).total;
|
|
120
|
+
return y === 0 ? [] : (await r.readEmployeesPage({ ...t, limit: y, offset: 0 })).items.map(E);
|
|
121
|
+
}
|
|
122
|
+
async function i(t) {
|
|
123
|
+
return r.createEmployee(t);
|
|
124
|
+
}
|
|
125
|
+
async function I(t, o) {
|
|
126
|
+
await r.updateEmployee(t, o);
|
|
127
|
+
}
|
|
128
|
+
async function w(t) {
|
|
129
|
+
await r.deleteEmployee(t);
|
|
130
|
+
}
|
|
131
|
+
async function M(t) {
|
|
132
|
+
await r.deleteMasterEmployee(t);
|
|
133
|
+
}
|
|
134
|
+
async function g(t) {
|
|
135
|
+
return r.createMasterEmployee(t);
|
|
136
|
+
}
|
|
137
|
+
async function v(t, o) {
|
|
138
|
+
await r.updateMasterEmployee(t, o);
|
|
139
|
+
}
|
|
140
|
+
async function P(t, o) {
|
|
141
|
+
await r.migrateToMasterEmployee(t, o);
|
|
142
|
+
}
|
|
143
|
+
async function U() {
|
|
144
|
+
await r.syncUsersMeta();
|
|
145
|
+
}
|
|
146
|
+
return {
|
|
147
|
+
employees: s,
|
|
148
|
+
listEmployees: l,
|
|
149
|
+
totalEmployees: c,
|
|
150
|
+
isLoading: d,
|
|
151
|
+
readEmployeesPage: p,
|
|
152
|
+
readAllEmployeesPage: a,
|
|
153
|
+
createEmployee: i,
|
|
154
|
+
updateEmployee: I,
|
|
155
|
+
deleteEmployee: w,
|
|
156
|
+
createMasterEmployee: g,
|
|
157
|
+
updateMasterEmployee: v,
|
|
158
|
+
deleteMasterEmployee: M,
|
|
159
|
+
migrateToMasterUser: P,
|
|
160
|
+
syncUsersMeta: U
|
|
161
|
+
};
|
|
162
|
+
}), z = () => {
|
|
163
|
+
const e = D();
|
|
164
|
+
return {
|
|
165
|
+
...e,
|
|
166
|
+
...$(e)
|
|
167
|
+
};
|
|
168
|
+
};
|
|
169
|
+
export {
|
|
170
|
+
r as E,
|
|
171
|
+
z as u
|
|
172
|
+
};
|
|
@@ -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, e as v, b as o } from "./app-
|
|
3
|
+
import { g as s, e as v, b as o } from "./app-BohKQtlz.js";
|
|
4
4
|
const c = {
|
|
5
5
|
async getGrantUsers() {
|
|
6
6
|
return s(await o("grant").get(""));
|
|
@@ -24,7 +24,7 @@ const c = {
|
|
|
24
24
|
})
|
|
25
25
|
);
|
|
26
26
|
}
|
|
27
|
-
}, w = f("
|
|
27
|
+
}, w = f("hrm-grant-user", () => {
|
|
28
28
|
const r = u([]), a = u(!1);
|
|
29
29
|
async function l() {
|
|
30
30
|
a.value = !0;
|