@feedmepos/mf-hrm-portal 0.0.1-alpha.1 → 0.0.1
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/package.json +1 -1
- package/dist/App.vue.d.ts +0 -2
- package/dist/EmployeeList-BU6n0y6w.js +0 -604
- package/dist/Entry.vue.d.ts +0 -2
- package/dist/PageLayout.vue_vue_type_script_setup_true_lang-HKK4cbW8.js +0 -37
- package/dist/RoleList-kE8O8wyy.js +0 -492
- package/dist/TeamMemberList-BBl8auxB.js +0 -1447
- package/dist/TimesheetList-QmuwWz31.js +0 -395
- package/dist/api/employee/index.d.ts +0 -15
- package/dist/api/index.d.ts +0 -3
- package/dist/api/inventory/index.d.ts +0 -5
- package/dist/api/role/index.d.ts +0 -9
- package/dist/api/team/index.d.ts +0 -10
- package/dist/api/timesheet/index.d.ts +0 -6
- package/dist/api/user/index.d.ts +0 -6
- package/dist/app-DWSjl6MP.js +0 -1170
- package/dist/app-DXlbstZu.js +0 -2282
- package/dist/app.d.ts +0 -3
- package/dist/app.js +0 -6
- package/dist/components/AppForm.vue.d.ts +0 -45
- package/dist/components/CheckboxInput.vue.d.ts +0 -155
- package/dist/components/Navigator.vue.d.ts +0 -6
- package/dist/components/Splash.vue.d.ts +0 -2
- package/dist/composables/message.d.ts +0 -4
- package/dist/composables/restaurant.d.ts +0 -329
- package/dist/employee-C-ICOGva.js +0 -449
- package/dist/favicon.ico +0 -0
- package/dist/helpers/component.d.ts +0 -12
- package/dist/helpers/iteration.d.ts +0 -10
- package/dist/helpers/rule.d.ts +0 -28
- package/dist/helpers/utils.d.ts +0 -3
- package/dist/index-COaCoGwy.js +0 -57
- package/dist/loading-31nfQqf0.js +0 -140
- package/dist/lodash-P5mhhlxp.js +0 -3676
- package/dist/main-DlJuqlgg.js +0 -15636
- package/dist/main.d.ts +0 -1
- package/dist/restaurant-D5BNPLKh.js +0 -107
- package/dist/router/index.d.ts +0 -2
- package/dist/router/shared.d.ts +0 -10
- package/dist/rule-DjIknogy.js +0 -8229
- package/dist/search-Dh3HG-_h.js +0 -258
- package/dist/shared/api/index.d.ts +0 -3
- package/dist/shared/api/public.d.ts +0 -5
- package/dist/shared/components/button/ResponsiveFabButton.vue.d.ts +0 -3
- package/dist/shared/components/form/SelectFilter.vue.d.ts +0 -86
- package/dist/shared/components/layout/FormColumn.vue.d.ts +0 -12
- package/dist/shared/components/layout/FormItem.vue.d.ts +0 -17
- package/dist/shared/components/layout/FormSection.vue.d.ts +0 -18
- package/dist/shared/components/layout/FullWrapper.vue.d.ts +0 -9
- package/dist/shared/components/layout/HorizontalSplitter.vue.d.ts +0 -2
- package/dist/shared/components/layout/LottieAnimation.vue.d.ts +0 -39
- package/dist/shared/components/layout/PageLayout.vue.d.ts +0 -20
- package/dist/shared/components/loading/AppLoading.vue.d.ts +0 -20
- package/dist/shared/components/loading/PageLoading.vue.d.ts +0 -2
- package/dist/shared/components/loading/index.d.ts +0 -1
- package/dist/shared/components/menu/BottomSheetMenu.vue.d.ts +0 -13
- package/dist/shared/components/menu/BottomSheetMenuItem.vue.d.ts +0 -15
- package/dist/shared/components/menu/ResponsiveContextMenu.vue.d.ts +0 -13
- package/dist/shared/components/table/EmptyDataTemplate/Icon.vue.d.ts +0 -2
- package/dist/shared/components/table/EmptyDataTemplate/index.d.ts +0 -1
- package/dist/shared/components/table/EmptyDataTemplate/index.vue.d.ts +0 -18
- package/dist/shared/composable/dateRange.d.ts +0 -18
- package/dist/shared/composable/discardConfirm.d.ts +0 -1
- package/dist/shared/composable/elementPosition.d.ts +0 -17
- package/dist/shared/composable/filterSelector.d.ts +0 -12
- package/dist/shared/composable/loading.d.ts +0 -29
- package/dist/shared/composable/search.d.ts +0 -5
- package/dist/shared/composable/sheet.d.ts +0 -17
- package/dist/shared/helpers/createComponent.d.ts +0 -7
- package/dist/shared/helpers/iteration.d.ts +0 -11
- package/dist/shared/helpers/object.d.ts +0 -6
- package/dist/shared/helpers/string.d.ts +0 -12
- package/dist/shared/permission/posPermission.d.ts +0 -6
- package/dist/shared/stores/app.d.ts +0 -217
- package/dist/stores/employee.d.ts +0 -590
- package/dist/stores/role.d.ts +0 -214
- package/dist/stores/timesheet.d.ts +0 -253
- package/dist/style.css +0 -1
- package/dist/timesheet-Jwqi_LdM.js +0 -56
- package/dist/tsconfig.app.tsbuildinfo +0 -1
- package/dist/types/employee.d.ts +0 -30
- package/dist/types/permission.d.ts +0 -2
- package/dist/types/restaurant.d.ts +0 -18
- package/dist/types/role.d.ts +0 -37
- package/dist/types/team.d.ts +0 -49
- package/dist/types/timesheet.d.ts +0 -16
- package/dist/views/hr/locales/index.d.ts +0 -602
- package/dist/views/hr/views/employee/Employee.vue.d.ts +0 -2
- package/dist/views/hr/views/employee/EmployeeList.vue.d.ts +0 -38
- package/dist/views/hr/views/employee/components/EmployeeForm.vue.d.ts +0 -27
- package/dist/views/hr/views/main.vue.d.ts +0 -2
- package/dist/views/hr/views/role/RoleForm.vue.d.ts +0 -17
- package/dist/views/hr/views/role/RoleList.vue.d.ts +0 -5
- package/dist/views/hr/views/timesheet/TimesheetList.vue.d.ts +0 -2
- package/dist/views/team/locales/index.d.ts +0 -348
- package/dist/views/team/views/team/TeamMemberList.vue.d.ts +0 -2
- package/dist/views/team/views/team/components/AddMemberForm.vue.d.ts +0 -37
- package/dist/views/team/views/team/components/MemberInfo.vue.d.ts +0 -6
- package/dist/views/team/views/team/components/PortalPermissionEditor.vue.d.ts +0 -46
- package/dist/views/team/views/team/components/PortalUserSearcher.vue.d.ts +0 -40
- package/dist/views/team/views/team/components/TeamMemberBasePermission.vue.d.ts +0 -36
- package/dist/views/team/views/team/components/TeamMemberConditionPermission.vue.d.ts +0 -50
- package/dist/views/team/views/team/components/TeamMemberMasterUser.vue.d.ts +0 -710
- package/dist/views/team/views/team/components/TeamMemberRolePermission.vue.d.ts +0 -46
|
@@ -1,395 +0,0 @@
|
|
|
1
|
-
import { ref as v, computed as k, defineComponent as me, onMounted as ve, watch as Z, resolveComponent as m, createElementBlock as B, openBlock as C, Fragment as ee, createVNode as l, createElementVNode as u, unref as n, withCtx as V, createCommentVNode as fe, toDisplayString as A, createTextVNode as pe, createBlock as z, isRef as he, renderList as ge, nextTick as ye } from "vue";
|
|
2
|
-
import { D as _, u as we } from "./employee-C-ICOGva.js";
|
|
3
|
-
import { useI18n as be, useCoreStore as _e, RestaurantSelector as De } from "@feedmepos/mf-common";
|
|
4
|
-
import { useSnackbar as xe, components as Se } from "@feedmepos/ui-library";
|
|
5
|
-
import { _ as ke } from "./app-DWSjl6MP.js";
|
|
6
|
-
import { u as Ce, _ as Ve } from "./loading-31nfQqf0.js";
|
|
7
|
-
import { n as Fe } from "./rule-DjIknogy.js";
|
|
8
|
-
import { u as Ye } from "./timesheet-Jwqi_LdM.js";
|
|
9
|
-
function Le(i, t) {
|
|
10
|
-
return ["years", "months"].find((f) => {
|
|
11
|
-
const p = i.startOf(f), c = i.endOf(f);
|
|
12
|
-
return i.isSame(p, "day") && t.isSame(c, "day");
|
|
13
|
-
}) || "days";
|
|
14
|
-
}
|
|
15
|
-
function Me() {
|
|
16
|
-
const i = {
|
|
17
|
-
startDate: _().format("YYYY-MM-DD"),
|
|
18
|
-
endDate: _().format("YYYY-MM-DD")
|
|
19
|
-
}, t = v(i), y = k(() => {
|
|
20
|
-
if (!t.value) return "No dates selected.";
|
|
21
|
-
const c = t.value.startDate ?? "Start", h = t.value.endDate ?? "End";
|
|
22
|
-
return `${c} - ${h}`;
|
|
23
|
-
}), f = k(() => ({
|
|
24
|
-
startDate: new Date(t.value.startDate),
|
|
25
|
-
endDate: new Date(t.value.endDate)
|
|
26
|
-
}));
|
|
27
|
-
function p(c) {
|
|
28
|
-
const h = _(t.value.startDate), d = _(t.value.endDate), g = Le(h, d), O = g === "days" ? d.diff(h, "days") + 1 : 1, F = c === "subtract" ? (D) => D.subtract(O, g) : (D) => D.add(O, g);
|
|
29
|
-
t.value = {
|
|
30
|
-
startDate: F(h).startOf(g).format("YYYY-MM-DD"),
|
|
31
|
-
endDate: F(d).endOf(g).format("YYYY-MM-DD")
|
|
32
|
-
};
|
|
33
|
-
}
|
|
34
|
-
return { dateRange: t, parsedDateRange: f, dateRangeLabel: y, setRange: p };
|
|
35
|
-
}
|
|
36
|
-
function P(i, t) {
|
|
37
|
-
return t === void 0 ? i : typeof t == "function" ? t(i) : `${i[t]}`;
|
|
38
|
-
}
|
|
39
|
-
function Te(i, t) {
|
|
40
|
-
return [...i].sort((f, p) => {
|
|
41
|
-
let c = P(f, t == null ? void 0 : t.selector), h = P(p, t == null ? void 0 : t.selector);
|
|
42
|
-
if (t != null && t.descending) {
|
|
43
|
-
const [d, g] = [c, h];
|
|
44
|
-
c = g, h = d;
|
|
45
|
-
}
|
|
46
|
-
return c.localeCompare(h, "en", { numeric: !0, sensitivity: "base" });
|
|
47
|
-
});
|
|
48
|
-
}
|
|
49
|
-
function Re(i, t) {
|
|
50
|
-
return i.reduce((y, f) => {
|
|
51
|
-
const p = P(f, t);
|
|
52
|
-
return y[p] = [...y[p] || [], f], y;
|
|
53
|
-
}, {});
|
|
54
|
-
}
|
|
55
|
-
const Ie = {
|
|
56
|
-
class: "my-16 flex w-[350px] flex-col gap-40"
|
|
57
|
-
}, $e = {
|
|
58
|
-
class: "flex gap-16"
|
|
59
|
-
}, Ae = {
|
|
60
|
-
class: "flex flex-col gap-4"
|
|
61
|
-
}, Oe = {
|
|
62
|
-
class: "fm-typo-body-md-400 text-fm-color-typo-secondary"
|
|
63
|
-
}, Ee = {
|
|
64
|
-
class: "fm-typo-body-md-700 text-fm-color-typo-primary"
|
|
65
|
-
}, Ke = {
|
|
66
|
-
class: "flex flex-col gap-8"
|
|
67
|
-
}, ze = {
|
|
68
|
-
class: "fm-typo-body-xl-700"
|
|
69
|
-
}, Ne = {
|
|
70
|
-
class: "flex flex-col gap-24"
|
|
71
|
-
}, Ue = {
|
|
72
|
-
class: "flex flex-col gap-8"
|
|
73
|
-
}, Be = {
|
|
74
|
-
class: "fm-typo-body-xl-700"
|
|
75
|
-
}, Pe = {
|
|
76
|
-
class: "flex flex-col gap-24"
|
|
77
|
-
}, He = {
|
|
78
|
-
key: 0,
|
|
79
|
-
class: "fm-typo-body-sm-400 text-fm-color-typo-error mt-1 flex items-center gap-4"
|
|
80
|
-
}, je = {
|
|
81
|
-
class: "flex items-center justify-start gap-8"
|
|
82
|
-
}, Ge = {
|
|
83
|
-
class: "space-y-8"
|
|
84
|
-
}, qe = {
|
|
85
|
-
class: "flex items-start gap-8 flex-wrap xs:px-16"
|
|
86
|
-
}, Je = {
|
|
87
|
-
class: "flex items-center gap-8"
|
|
88
|
-
}, lt = /* @__PURE__ */ me({
|
|
89
|
-
__name: "TimesheetList",
|
|
90
|
-
setup(i) {
|
|
91
|
-
const {
|
|
92
|
-
t
|
|
93
|
-
} = be(), y = xe(), f = Ce(y), p = [{
|
|
94
|
-
label: t("hr.timesheet.listView"),
|
|
95
|
-
value: "listView"
|
|
96
|
-
}, {
|
|
97
|
-
label: t("hr.timesheet.userView"),
|
|
98
|
-
value: "userView"
|
|
99
|
-
}], c = v("listView"), h = k(() => {
|
|
100
|
-
var a;
|
|
101
|
-
return (a = p.find((e) => e.value === c.value)) == null ? void 0 : a.label;
|
|
102
|
-
}), d = v(""), g = Ye(), O = we(), F = k(() => O.employees.value), D = k(() => g.timesheets.value.filter((o) => !E.value || E.value.includes(o.restaurantId)).map((o) => {
|
|
103
|
-
var S;
|
|
104
|
-
const r = (S = te.restaurants.value.find((b) => b._id === o.restaurantId)) == null ? void 0 : S.profile.code, x = F.value.find((b) => b._id === o.user.id);
|
|
105
|
-
return {
|
|
106
|
-
...o,
|
|
107
|
-
restaurantCode: r,
|
|
108
|
-
user: {
|
|
109
|
-
...o.user,
|
|
110
|
-
code: x ? x.code : ""
|
|
111
|
-
}
|
|
112
|
-
};
|
|
113
|
-
})), H = k(() => D.value.filter((a) => {
|
|
114
|
-
var e, o;
|
|
115
|
-
return a.user.name.toLowerCase().includes(d.value.toLowerCase()) || a.restaurantName.toLowerCase().includes(d.value.toLowerCase()) || ((e = a.restaurantCode) == null ? void 0 : e.toLowerCase().includes(d.value.toLowerCase())) || ((o = a.user.code) == null ? void 0 : o.toLowerCase().includes(d.value.toLowerCase()));
|
|
116
|
-
})), j = k(() => {
|
|
117
|
-
const a = Re(D.value, (o) => o.user.name), e = Object.entries(a).map(([o, r]) => {
|
|
118
|
-
const x = F.value.find((S) => S._id === r[0].user.id);
|
|
119
|
-
return {
|
|
120
|
-
key: o,
|
|
121
|
-
user: r[0].user.name,
|
|
122
|
-
code: x ? x.code : "",
|
|
123
|
-
timesheets: r,
|
|
124
|
-
total: Fe(r.reduce((S, b) => S + b.totalMin, 0))
|
|
125
|
-
};
|
|
126
|
-
});
|
|
127
|
-
return Te(e, {
|
|
128
|
-
selector: "user"
|
|
129
|
-
});
|
|
130
|
-
}), G = k(() => j.value.filter((a) => {
|
|
131
|
-
var e;
|
|
132
|
-
return a.user.toLowerCase().includes(d.value.toLowerCase()) || ((e = a.code) == null ? void 0 : e.toLowerCase().includes(d.value.toLowerCase()));
|
|
133
|
-
})), Y = v(!1), N = async () => {
|
|
134
|
-
const {
|
|
135
|
-
startDate: a,
|
|
136
|
-
endDate: e
|
|
137
|
-
} = L.value;
|
|
138
|
-
Y.value = !0;
|
|
139
|
-
try {
|
|
140
|
-
await g.readTimesheet(new Date(a), new Date(e)), await ye(), U.value = Object.fromEntries(Object.entries(new Array(j.value.length).fill(!0)));
|
|
141
|
-
} catch (o) {
|
|
142
|
-
y.open({
|
|
143
|
-
title: o instanceof Error ? o.message : `${o}`,
|
|
144
|
-
type: "error"
|
|
145
|
-
});
|
|
146
|
-
} finally {
|
|
147
|
-
Y.value = !1;
|
|
148
|
-
}
|
|
149
|
-
};
|
|
150
|
-
ve(() => {
|
|
151
|
-
N();
|
|
152
|
-
});
|
|
153
|
-
const te = _e(), E = v(), {
|
|
154
|
-
dateRange: L,
|
|
155
|
-
dateRangeLabel: ae,
|
|
156
|
-
setRange: q
|
|
157
|
-
} = Me();
|
|
158
|
-
Z(L, async () => {
|
|
159
|
-
N();
|
|
160
|
-
});
|
|
161
|
-
const se = [{
|
|
162
|
-
accessorKey: "user.code",
|
|
163
|
-
size: 100,
|
|
164
|
-
header: () => t("hr.employee.columns.code"),
|
|
165
|
-
cell: (a) => a.row.original.user.code || "--",
|
|
166
|
-
enableSorting: !0
|
|
167
|
-
}, {
|
|
168
|
-
accessorKey: "user",
|
|
169
|
-
header: () => t("hr.timesheet.columns.name"),
|
|
170
|
-
cell: (a) => a.row.original.user.name,
|
|
171
|
-
enableSorting: !1
|
|
172
|
-
}, {
|
|
173
|
-
accessorKey: "restaurantName",
|
|
174
|
-
header: () => t("hr.timesheet.columns.restaurant"),
|
|
175
|
-
cell: (a) => {
|
|
176
|
-
const e = a.row.original.restaurantCode, o = a.row.original.restaurantName;
|
|
177
|
-
return `${e ? e + " - " : ""}${o}`;
|
|
178
|
-
},
|
|
179
|
-
enableSorting: !0
|
|
180
|
-
}, {
|
|
181
|
-
accessorKey: "start",
|
|
182
|
-
header: () => t("hr.timesheet.columns.start"),
|
|
183
|
-
cell: (a) => a.row.original.start || "--",
|
|
184
|
-
enableSorting: !0
|
|
185
|
-
}, {
|
|
186
|
-
accessorKey: "end",
|
|
187
|
-
header: () => t("hr.timesheet.columns.end"),
|
|
188
|
-
cell: (a) => a.row.original.end || "--",
|
|
189
|
-
enableSorting: !0
|
|
190
|
-
}, {
|
|
191
|
-
name: "duration",
|
|
192
|
-
accessorKey: "duration",
|
|
193
|
-
header: () => t("hr.timesheet.columns.duration"),
|
|
194
|
-
cell: (a) => a.row.original.duration || "--",
|
|
195
|
-
enableSorting: !0
|
|
196
|
-
}], U = v({}), oe = [{
|
|
197
|
-
accessorKey: "code",
|
|
198
|
-
size: 100,
|
|
199
|
-
header: () => t("hr.employee.columns.code"),
|
|
200
|
-
cell: (a) => a.row.original.code,
|
|
201
|
-
enableSorting: !1
|
|
202
|
-
}, {
|
|
203
|
-
accessorKey: "user",
|
|
204
|
-
header: () => t("hr.timesheet.columns.name"),
|
|
205
|
-
cell: (a) => {
|
|
206
|
-
const e = a.row.original;
|
|
207
|
-
if (typeof e.user == "string") {
|
|
208
|
-
const o = a.row.getIsExpanded();
|
|
209
|
-
return l("div", {
|
|
210
|
-
class: "flex items-center gap-8"
|
|
211
|
-
}, [l(Se.FmButton, {
|
|
212
|
-
variant: "tertiary",
|
|
213
|
-
icon: o ? "keyboard_arrow_up" : "keyboard_arrow_down",
|
|
214
|
-
onClick: (r) => {
|
|
215
|
-
r.stopPropagation(), a.row.getToggleExpandedHandler()(r);
|
|
216
|
-
}
|
|
217
|
-
}, null), e.user]);
|
|
218
|
-
}
|
|
219
|
-
},
|
|
220
|
-
enableSorting: !1
|
|
221
|
-
}, {
|
|
222
|
-
accessorKey: "start",
|
|
223
|
-
header: () => t("hr.timesheet.columns.start"),
|
|
224
|
-
cell: (a) => {
|
|
225
|
-
const e = a.row.original;
|
|
226
|
-
return (e == null ? void 0 : e.start) || "--";
|
|
227
|
-
},
|
|
228
|
-
enableSorting: !1
|
|
229
|
-
}, {
|
|
230
|
-
accessorKey: "end",
|
|
231
|
-
header: () => t("hr.timesheet.columns.end"),
|
|
232
|
-
cell: (a) => {
|
|
233
|
-
const e = a.row.original;
|
|
234
|
-
return (e == null ? void 0 : e.end) || "--";
|
|
235
|
-
},
|
|
236
|
-
enableSorting: !1
|
|
237
|
-
}, {
|
|
238
|
-
name: "duration",
|
|
239
|
-
accessorKey: "duration",
|
|
240
|
-
header: () => t("hr.timesheet.columns.hourMinute"),
|
|
241
|
-
cell: (a) => {
|
|
242
|
-
const e = a.row.original;
|
|
243
|
-
return e.total ? `Total: ${e.total}` : e.duration;
|
|
244
|
-
},
|
|
245
|
-
enableSorting: !1
|
|
246
|
-
}], M = v(!1);
|
|
247
|
-
function J(a) {
|
|
248
|
-
w.value = a, T.value = _(w.value.startedAt).format("YYYY-MM-DD"), I.value = _(w.value.endedAt || w.value.startedAt).format("YYYY-MM-DD"), R.value = _(w.value.startedAt).format("HH:mm"), $.value = _(w.value.endedAt || w.value.startedAt).format("HH:mm"), M.value = !0;
|
|
249
|
-
}
|
|
250
|
-
const T = v(), R = v(), I = v(), $ = v(), w = v(), K = v("");
|
|
251
|
-
async function le() {
|
|
252
|
-
const a = Q(T.value, R.value), e = Q(I.value, $.value);
|
|
253
|
-
if (_(a).isAfter(e)) {
|
|
254
|
-
K.value = t("hr.timesheet.checkOutMustBeforeCheckIn");
|
|
255
|
-
return;
|
|
256
|
-
}
|
|
257
|
-
f.minor(async () => {
|
|
258
|
-
await g.updateTimesheet(w.value, a, e);
|
|
259
|
-
}, {
|
|
260
|
-
successMessage: t("hr.timesheet.update.successMessage")
|
|
261
|
-
}), N(), M.value = !1;
|
|
262
|
-
}
|
|
263
|
-
const Q = (a, e) => _(a).set("h", parseInt(e.split(":")[0])).set("m", parseInt(e.split(":")[1])).toISOString();
|
|
264
|
-
return Z([T, I, R, $], ([a, e, o, r]) => {
|
|
265
|
-
(a || e || o || r) && (K.value = "");
|
|
266
|
-
}), (a, e) => {
|
|
267
|
-
const o = m("FmAvatar"), r = m("FmDatePicker"), x = m("FmTimePicker"), S = m("FmIcon"), b = m("FmButton"), ne = m("FmSideSheet"), W = m("FmChip"), re = m("FmDateRangePicker"), ue = m("FmMenuItem"), ie = m("FmMenu"), de = m("FmSpacer"), ce = m("FmSearch"), X = m("FmTable");
|
|
268
|
-
return C(), B(ee, null, [l(ne, {
|
|
269
|
-
modelValue: M.value,
|
|
270
|
-
"onUpdate:modelValue": e[5] || (e[5] = (s) => M.value = s),
|
|
271
|
-
"dismiss-away": "",
|
|
272
|
-
header: n(t)("hr.timesheet.update.title")
|
|
273
|
-
}, {
|
|
274
|
-
"side-sheet-footer": V(() => [u("div", je, [l(b, {
|
|
275
|
-
label: n(t)("common.update"),
|
|
276
|
-
size: "md",
|
|
277
|
-
variant: "primary",
|
|
278
|
-
onClick: le
|
|
279
|
-
}, null, 8, ["label"]), l(b, {
|
|
280
|
-
label: n(t)("common.cancel"),
|
|
281
|
-
size: "md",
|
|
282
|
-
variant: "secondary",
|
|
283
|
-
onClick: e[4] || (e[4] = (s) => M.value = !1)
|
|
284
|
-
}, null, 8, ["label"])])]),
|
|
285
|
-
default: V(() => [u("div", Ie, [u("div", $e, [l(o, {
|
|
286
|
-
initials: w.value.user.name,
|
|
287
|
-
size: "lg"
|
|
288
|
-
}, null, 8, ["initials"]), u("div", Ae, [u("div", Oe, A(n(t)("hr.timesheet.employeeName")), 1), u("div", Ee, A(w.value.user.name), 1)])]), u("div", Ke, [u("div", ze, A(n(t)("hr.timesheet.update.checkIn")), 1), u("div", Ne, [l(r, {
|
|
289
|
-
modelValue: T.value,
|
|
290
|
-
"onUpdate:modelValue": e[0] || (e[0] = (s) => T.value = s),
|
|
291
|
-
disabled: !1,
|
|
292
|
-
label: n(t)("hr.timesheet.update.date")
|
|
293
|
-
}, null, 8, ["modelValue", "label"]), l(x, {
|
|
294
|
-
modelValue: R.value,
|
|
295
|
-
"onUpdate:modelValue": e[1] || (e[1] = (s) => R.value = s),
|
|
296
|
-
label: n(t)("hr.timesheet.update.time")
|
|
297
|
-
}, null, 8, ["modelValue", "label"])])]), u("div", Ue, [u("div", Be, A(n(t)("hr.timesheet.update.checkOut")), 1), u("div", Pe, [l(r, {
|
|
298
|
-
modelValue: I.value,
|
|
299
|
-
"onUpdate:modelValue": e[2] || (e[2] = (s) => I.value = s),
|
|
300
|
-
disabled: !1,
|
|
301
|
-
label: n(t)("hr.timesheet.update.date")
|
|
302
|
-
}, null, 8, ["modelValue", "label"]), l(x, {
|
|
303
|
-
modelValue: $.value,
|
|
304
|
-
"onUpdate:modelValue": e[3] || (e[3] = (s) => $.value = s),
|
|
305
|
-
label: n(t)("hr.timesheet.update.time")
|
|
306
|
-
}, null, 8, ["modelValue", "label"])])]), K.value ? (C(), B("div", He, [l(S, {
|
|
307
|
-
color: "#FF3B30",
|
|
308
|
-
name: "error",
|
|
309
|
-
size: "sm"
|
|
310
|
-
}), pe(" " + A(K.value), 1)])) : fe("", !0)])]),
|
|
311
|
-
_: 1
|
|
312
|
-
}, 8, ["modelValue", "header"]), u("div", Ge, [u("div", qe, [l(n(De), {
|
|
313
|
-
"managable-only": "",
|
|
314
|
-
modelValue: E.value,
|
|
315
|
-
"onUpdate:modelValue": e[6] || (e[6] = (s) => E.value = s),
|
|
316
|
-
multiple: "",
|
|
317
|
-
variant: "dark",
|
|
318
|
-
class: "!w-auto pt-[3px]"
|
|
319
|
-
}, null, 8, ["modelValue"]), u("div", Je, [l(re, {
|
|
320
|
-
modelValue: n(L),
|
|
321
|
-
"onUpdate:modelValue": e[7] || (e[7] = (s) => he(L) ? L.value = s : null),
|
|
322
|
-
"show-predefined-range": ""
|
|
323
|
-
}, {
|
|
324
|
-
"trigger-button": V(() => [l(W, {
|
|
325
|
-
label: n(ae)
|
|
326
|
-
}, null, 8, ["label"])]),
|
|
327
|
-
_: 1
|
|
328
|
-
}, 8, ["modelValue"]), l(b, {
|
|
329
|
-
icon: "chevron_left",
|
|
330
|
-
variant: "tertiary",
|
|
331
|
-
onClick: e[8] || (e[8] = (s) => n(q)("subtract"))
|
|
332
|
-
}), l(b, {
|
|
333
|
-
icon: "chevron_right",
|
|
334
|
-
variant: "tertiary",
|
|
335
|
-
onClick: e[9] || (e[9] = (s) => n(q)("add"))
|
|
336
|
-
})]), l(ie, {
|
|
337
|
-
class: "pt-[3px]"
|
|
338
|
-
}, {
|
|
339
|
-
"menu-button": V(() => [l(W, {
|
|
340
|
-
label: h.value,
|
|
341
|
-
"right-icon": "keyboard_arrow_down"
|
|
342
|
-
}, null, 8, ["label"])]),
|
|
343
|
-
default: V(() => [(C(), B(ee, null, ge(p, (s) => l(ue, {
|
|
344
|
-
key: s.value,
|
|
345
|
-
label: s.label,
|
|
346
|
-
onClick: (Qe) => c.value = s.value
|
|
347
|
-
}, null, 8, ["label", "onClick"])), 64))]),
|
|
348
|
-
_: 1
|
|
349
|
-
}), l(de), l(ce, {
|
|
350
|
-
class: "w-[320px]",
|
|
351
|
-
modelValue: d.value,
|
|
352
|
-
"onUpdate:modelValue": e[10] || (e[10] = (s) => d.value = s),
|
|
353
|
-
placeholder: n(t)("hr.timesheet.search.placeholder")
|
|
354
|
-
}, null, 8, ["modelValue", "placeholder"])]), D.value.length === 0 && !Y.value ? (C(), z(n(Ve), {
|
|
355
|
-
key: 0,
|
|
356
|
-
title: n(t)("hr.timesheet.noData.title"),
|
|
357
|
-
subtitle: ""
|
|
358
|
-
}, null, 8, ["title"])) : (C(), z(ke, {
|
|
359
|
-
key: 1,
|
|
360
|
-
class: "w-full xs:px-16 overflow-auto"
|
|
361
|
-
}, {
|
|
362
|
-
default: V(() => [c.value === "listView" ? (C(), z(X, {
|
|
363
|
-
key: 0,
|
|
364
|
-
class: "min-w-[640px]",
|
|
365
|
-
"column-defs": se,
|
|
366
|
-
"row-data": H.value,
|
|
367
|
-
"page-size": H.value.length,
|
|
368
|
-
loading: Y.value,
|
|
369
|
-
"pin-header-row": "",
|
|
370
|
-
"hide-footer": "",
|
|
371
|
-
"shrink-at": !1,
|
|
372
|
-
onRowClick: e[11] || (e[11] = (s) => J(s.original))
|
|
373
|
-
}, null, 8, ["row-data", "page-size", "loading"])) : (C(), z(X, {
|
|
374
|
-
key: 1,
|
|
375
|
-
class: "min-w-[640px]",
|
|
376
|
-
"column-defs": oe,
|
|
377
|
-
"row-data": G.value,
|
|
378
|
-
"page-size": D.value.length + G.value.length,
|
|
379
|
-
loading: Y.value,
|
|
380
|
-
"pin-header-row": "",
|
|
381
|
-
"hide-footer": "",
|
|
382
|
-
"shrink-at": !1,
|
|
383
|
-
"expanded-state": U.value,
|
|
384
|
-
"get-sub-row": (s) => s.timesheets,
|
|
385
|
-
"onUpdate:expandedState": e[12] || (e[12] = (s) => U.value = s),
|
|
386
|
-
onRowClick: e[13] || (e[13] = (s) => J(s.original))
|
|
387
|
-
}, null, 8, ["row-data", "page-size", "loading", "expanded-state", "get-sub-row"]))]),
|
|
388
|
-
_: 1
|
|
389
|
-
}))])], 64);
|
|
390
|
-
};
|
|
391
|
-
}
|
|
392
|
-
});
|
|
393
|
-
export {
|
|
394
|
-
lt as default
|
|
395
|
-
};
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { FdtoUpdatePosUserReq, FdtoUpdatePosMasterUserReq } from '@feedmepos/core/entity';
|
|
2
|
-
import type { IFdtoPosUser } from '@/types/employee';
|
|
3
|
-
declare const EmployeeAPI: {
|
|
4
|
-
readEmployees(): Promise<IFdtoPosUser[]>;
|
|
5
|
-
createEmployee(dto: FdtoUpdatePosUserReq): Promise<IFdtoPosUser[]>;
|
|
6
|
-
createMasterEmployee(dto: FdtoUpdatePosMasterUserReq): Promise<IFdtoPosUser[]>;
|
|
7
|
-
migrateToMasterEmployee(employeeId: string, dto: FdtoUpdatePosMasterUserReq): Promise<IFdtoPosUser[]>;
|
|
8
|
-
updateEmployee(employeeId: string, dto: FdtoUpdatePosUserReq): Promise<IFdtoPosUser[]>;
|
|
9
|
-
updateMasterEmployee(employeeId: string, dto: FdtoUpdatePosMasterUserReq): Promise<IFdtoPosUser[]>;
|
|
10
|
-
deleteEmployee(employee: IFdtoPosUser): Promise<IFdtoPosUser[]>;
|
|
11
|
-
deleteMasterEmployee(employee: IFdtoPosUser): Promise<IFdtoPosUser[]>;
|
|
12
|
-
generateEmployeePasscode(): Promise<string>;
|
|
13
|
-
syncUsersMeta(): Promise<void>;
|
|
14
|
-
};
|
|
15
|
-
export default EmployeeAPI;
|
package/dist/api/index.d.ts
DELETED
package/dist/api/role/index.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { FdoPosRole } from '@feedmepos/core/entity';
|
|
2
|
-
import type { IFdtoPosRole, IFdtoUpdateRoleReq } from '@/types/role';
|
|
3
|
-
declare const RoleAPI: {
|
|
4
|
-
readRoles(): Promise<IFdtoPosRole[]>;
|
|
5
|
-
createRole(dto: IFdtoUpdateRoleReq): Promise<IFdtoPosRole[]>;
|
|
6
|
-
updateRole(roleId: string, dto: IFdtoUpdateRoleReq): Promise<IFdtoPosRole[]>;
|
|
7
|
-
deleteRole(role: FdoPosRole): Promise<IFdtoPosRole[]>;
|
|
8
|
-
};
|
|
9
|
-
export default RoleAPI;
|
package/dist/api/team/index.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { FTeamMember, IFdtoCreatePortalUserReq, IFdtoUpdatePortalUserReq } from '@/types/team';
|
|
2
|
-
export declare const portalTeamPermissions: readonly import("@feedmepos/mf-common").IFdtoPortalPermission[];
|
|
3
|
-
export declare const teamApi: {
|
|
4
|
-
readTeamMembers(): Promise<FTeamMember[]>;
|
|
5
|
-
createTeamMember(req: IFdtoCreatePortalUserReq): Promise<FTeamMember>;
|
|
6
|
-
updateTeamMember(permissionUserId: string, req: IFdtoUpdatePortalUserReq): Promise<FTeamMember>;
|
|
7
|
-
deleteTeamMember(permissionUserId: string): Promise<boolean>;
|
|
8
|
-
readTeamMemberPosUserIds(): Promise<string[]>;
|
|
9
|
-
};
|
|
10
|
-
export default teamApi;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { IFdtoTimesheet, UpdateTimesheetDTO } from '@/types/timesheet';
|
|
2
|
-
declare const TimesheetAPI: {
|
|
3
|
-
readTimesheets(startIso: string, endIso: string): Promise<IFdtoTimesheet[]>;
|
|
4
|
-
updateTimesheet(restaurantId: string, dto: UpdateTimesheetDTO): Promise<void>;
|
|
5
|
-
};
|
|
6
|
-
export default TimesheetAPI;
|
package/dist/api/user/index.d.ts
DELETED