@feedmepos/mf-hrm-portal 2.1.1-dev.3 → 2.1.1-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.
- package/dist/ApprovalCodeList-B0PLZwav.js +758 -0
- package/dist/AuditLogList-CRXwPImZ.js +1611 -0
- package/dist/ConditionFormHost.vue_vue_type_script_setup_true_lang-zJwkM_Xb.js +387 -0
- package/dist/EmployeeList-DN2pnXcS.js +884 -0
- package/dist/GrantUserList-DoyxknJZ.js +464 -0
- package/dist/{Main-cskEZ3k_.js → Main-B5BKGpLg.js} +1033 -1029
- package/dist/Main-BGONIxo8.js +122 -0
- package/dist/{Main-DLlpEU3j.js → Main-DQj4xtkB.js} +7 -7
- package/dist/PermissionSetList-4uIU9FvN.js +393 -0
- package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-D0luaKDb.js +4122 -0
- package/dist/{PortalUserSearcher.vue_vue_type_style_index_0_scoped_a439fdd8_lang-BJp9hEfv.js → PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-DVVSBIx2.js} +1 -0
- package/dist/ResponsiveFabButton.vue_vue_type_script_setup_true_lang-QrqYEy8i.js +42 -0
- package/dist/RoleList-Bj5Y5jd_.js +685 -0
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-B4PxNMwq.js +16 -0
- package/dist/TableEmptyState.vue_vue_type_script_setup_true_lang-IfAZmWr0.js +37 -0
- package/dist/TeamMemberList-Byjlca2Y.js +1216 -0
- package/dist/{TimesheetList-B1H_6zfP.js → TimesheetList-DwIcsOM-.js} +118 -112
- package/dist/{TimesheetList.vue_vue_type_style_index_0_scoped_91afda4e_lang-DeTpbaRk.js → TimesheetList.vue_vue_type_style_index_0_scoped_2c7a177a_lang-B9qlQ6KG.js} +2 -2
- package/dist/{app-DX-PG6wx.js → app-BZwE2coe.js} +5407 -2374
- package/dist/app.js +1 -1
- package/dist/{dayjs.min-BJrHE7oz.js → dayjs.min-BXBPls4m.js} +1 -1
- package/dist/{employee-BJcqtqLM.js → employee-CJTbs1f7.js} +3 -3
- package/dist/{iteration-Cfaqt-0s.js → iteration-BCbIbdHR.js} +1 -1
- package/dist/{lodash-ClKqCmlZ.js → lodash-CUIS1iIz.js} +1 -1
- package/dist/{role-CR_-nBDY.js → role-CzXchcSS.js} +1 -1
- package/dist/rule-BO6xj2Xa.js +1058 -0
- package/dist/src/api/audit-log/index.d.ts +6 -0
- package/dist/src/components/CheckboxInput.vue.d.ts +1 -1
- package/dist/src/components/button/ResponsiveFabButton.vue.d.ts +7 -1
- package/dist/src/components/table/TableEmptyState.vue.d.ts +7 -15
- package/dist/src/composables/useBasePermission.d.ts +2 -1
- package/dist/src/composables/useConditionDraft.d.ts +40 -0
- package/dist/src/composables/useCoverConditionOverride.d.ts +61 -0
- package/dist/src/helpers/business-timezone.d.ts +22 -0
- package/dist/src/helpers/filter.d.ts +15 -0
- package/dist/src/helpers/permission-reconcile.d.ts +15 -0
- package/dist/src/helpers/permission-reconcile.test.d.ts +1 -0
- package/dist/src/helpers/permission-set.d.ts +8 -4
- package/dist/src/helpers/rule.d.ts +2 -1
- package/dist/src/stores/permission-set.d.ts +12 -3
- package/dist/src/types/approval-code.d.ts +22 -7
- package/dist/src/types/audit-log.d.ts +1 -1
- package/dist/src/views/approval-code/components/ApprovalCodeCreatedDialog.vue.d.ts +9 -0
- package/dist/src/views/approval-code/components/ApprovalCodeForm.vue.d.ts +6 -1
- package/dist/src/views/approval-code/locales/index.d.ts +40 -0
- package/dist/src/views/audit-log/event-line.d.ts +13 -0
- package/dist/src/views/audit-log/locales/index.d.ts +296 -0
- package/dist/src/views/audit-log/snapshot-diff.d.ts +11 -0
- package/dist/src/views/hr/employee/EmployeeList.vue.d.ts +1 -0
- package/dist/src/views/team/components/BasePermission.vue.d.ts +13 -0
- package/dist/src/views/team/condition-builders/ConditionFormHost.vue.d.ts +22 -0
- package/dist/src/views/team/condition-builders/ConditionFormRenderer.vue.d.ts +23 -0
- package/dist/src/views/team/condition-builders/component-map.d.ts +4 -0
- package/dist/src/views/team/condition-builders/condition-form-dedupe.d.ts +23 -0
- package/dist/src/views/team/locales/index.d.ts +80 -0
- package/dist/style.css +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/useDebounce-B8ZPVS5C.js +15 -0
- package/dist/{useReportPermissions-ybHA26cJ.js → useReportPermissions-Q-xLwz5N.js} +3 -3
- package/package.json +2 -2
- package/dist/ApprovalCodeList-BH5sgVMU.js +0 -638
- package/dist/AuditLogList-Q4L5Te8O.js +0 -1145
- package/dist/CollapsibleWrapper.vue_vue_type_script_setup_true_lang-BLJlmPVa.js +0 -58
- package/dist/EmployeeList-GtKmJZbf.js +0 -899
- package/dist/GrantUserList-CnLjOi5_.js +0 -468
- package/dist/Main-Cn7Dawg4.js +0 -120
- package/dist/PermissionSetList-C2fK2pTz.js +0 -357
- package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-CMh0DL1_.js +0 -3458
- package/dist/ResponsiveFabButton.vue_vue_type_script_setup_true_lang-Cn-3MRBO.js +0 -38
- package/dist/RoleList-CcuT1ERb.js +0 -567
- package/dist/TeamMemberList-Dfs2iNdC.js +0 -1131
- package/dist/rule-BB-3S-2R.js +0 -996
- package/dist/useDebounce-CWb5QR9G.js +0 -28
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
import { ref as d, computed as g, defineComponent as pe, onMounted as fe, watch as
|
|
2
|
-
import { d as
|
|
3
|
-
import { useI18n as
|
|
4
|
-
import { useSnackbar as
|
|
1
|
+
import { ref as d, computed as g, defineComponent as pe, onMounted as fe, watch as Z, resolveComponent as u, createElementBlock as P, openBlock as E, Fragment as ee, createVNode as l, createElementVNode as i, unref as r, withCtx as b, createCommentVNode as ve, toDisplayString as O, createTextVNode as he, isRef as ge, renderList as we, createBlock as te, nextTick as ye } from "vue";
|
|
2
|
+
import { d as v } from "./dayjs.min-BXBPls4m.js";
|
|
3
|
+
import { useI18n as _e } from "@feedmepos/mf-common";
|
|
4
|
+
import { useSnackbar as be, components as xe } from "@feedmepos/ui-library";
|
|
5
5
|
import { S as De, _ as Se } from "./SelectFilter-ATOm0hdn.js";
|
|
6
|
-
import { _ as
|
|
7
|
-
import { _ as
|
|
6
|
+
import { _ as Ve } from "./app-BZwE2coe.js";
|
|
7
|
+
import { _ as ke } from "./TableEmptyState.vue_vue_type_script_setup_true_lang-IfAZmWr0.js";
|
|
8
8
|
import { u as Ce } from "./useLoading-BH02lYns.js";
|
|
9
|
-
import { g as Fe, s as Ye } from "./iteration-
|
|
9
|
+
import { g as Fe, s as Ye } from "./iteration-BCbIbdHR.js";
|
|
10
10
|
import { f as Le } from "./utils-BZkjJbju.js";
|
|
11
|
-
import { u as Me } from "./employee-
|
|
11
|
+
import { u as Me } from "./employee-CJTbs1f7.js";
|
|
12
12
|
import { u as Te } from "./restaurant-YOVMuuFY.js";
|
|
13
|
-
import { u as Re } from "./TimesheetList.
|
|
13
|
+
import { u as Re } from "./TimesheetList.vue_vue_type_style_index_0_scoped_2c7a177a_lang-B9qlQ6KG.js";
|
|
14
14
|
function Ie(x, a) {
|
|
15
15
|
return ["years", "months"].find((S) => {
|
|
16
|
-
const
|
|
17
|
-
return x.isSame(
|
|
16
|
+
const V = x.startOf(S), m = x.endOf(S);
|
|
17
|
+
return x.isSame(V, "day") && a.isSame(m, "day");
|
|
18
18
|
}) || "days";
|
|
19
19
|
}
|
|
20
20
|
function $e() {
|
|
21
21
|
const x = {
|
|
22
|
-
startDate:
|
|
23
|
-
endDate:
|
|
22
|
+
startDate: v().format("YYYY-MM-DD"),
|
|
23
|
+
endDate: v().format("YYYY-MM-DD")
|
|
24
24
|
}, a = d(x), D = g(() => {
|
|
25
25
|
if (!a.value) return "No dates selected.";
|
|
26
|
-
const
|
|
27
|
-
return `${
|
|
26
|
+
const m = a.value.startDate ?? "Start", _ = a.value.endDate ?? "End";
|
|
27
|
+
return `${m} - ${_}`;
|
|
28
28
|
}), S = g(() => ({
|
|
29
29
|
startDate: new Date(a.value.startDate),
|
|
30
30
|
endDate: new Date(a.value.endDate)
|
|
31
31
|
}));
|
|
32
|
-
function
|
|
33
|
-
const
|
|
32
|
+
function V(m) {
|
|
33
|
+
const _ = v(a.value.startDate), c = v(a.value.endDate), h = Ie(_, c), k = h === "days" ? c.diff(_, "days") + 1 : 1, C = m === "subtract" ? (F) => F.subtract(k, h) : (F) => F.add(k, h);
|
|
34
34
|
a.value = {
|
|
35
|
-
startDate: C(
|
|
35
|
+
startDate: C(_).startOf(h).format("YYYY-MM-DD"),
|
|
36
36
|
endDate: C(c).endOf(h).format("YYYY-MM-DD")
|
|
37
37
|
};
|
|
38
38
|
}
|
|
39
|
-
return { dateRange: a, parsedDateRange: S, dateRangeLabel: D, setRange:
|
|
39
|
+
return { dateRange: a, parsedDateRange: S, dateRangeLabel: D, setRange: V };
|
|
40
40
|
}
|
|
41
41
|
const Ee = {
|
|
42
42
|
class: "my-16 flex w-[350px] flex-col gap-40"
|
|
@@ -71,23 +71,25 @@ const Ee = {
|
|
|
71
71
|
class: "flex items-start gap-8 flex-wrap xs:px-16"
|
|
72
72
|
}, We = {
|
|
73
73
|
class: "flex items-center gap-8"
|
|
74
|
-
}, Xe =
|
|
74
|
+
}, Xe = {
|
|
75
|
+
class: "flex h-full flex-col overflow-auto"
|
|
76
|
+
}, Ze = /* @__PURE__ */ pe({
|
|
75
77
|
__name: "TimesheetList",
|
|
76
78
|
setup(x) {
|
|
77
79
|
const {
|
|
78
80
|
t: a
|
|
79
|
-
} =
|
|
81
|
+
} = _e(), D = be(), S = Ce(D), V = [{
|
|
80
82
|
label: a("hr.timesheet.listView"),
|
|
81
83
|
value: "listView"
|
|
82
84
|
}, {
|
|
83
85
|
label: a("hr.timesheet.userView"),
|
|
84
86
|
value: "userView"
|
|
85
|
-
}],
|
|
87
|
+
}], m = d("listView"), _ = g(() => {
|
|
86
88
|
var t;
|
|
87
|
-
return (t =
|
|
88
|
-
}), c = d(""), h = Re(),
|
|
89
|
+
return (t = V.find((e) => e.value === m.value)) == null ? void 0 : t.label;
|
|
90
|
+
}), c = d(""), h = Re(), k = Me(), C = Te(), F = g(() => k.employees.value), j = g(() => h.timesheets.value.filter((s) => !A.value || A.value.includes(s.restaurantId)).map((s) => {
|
|
89
91
|
var y;
|
|
90
|
-
const n = (y = C.restaurants.value.find((
|
|
92
|
+
const n = (y = C.restaurants.value.find((f) => f._id === s.restaurantId)) == null ? void 0 : y.profile.code, w = F.value.find((f) => f._id === s.user.id);
|
|
91
93
|
return {
|
|
92
94
|
...s,
|
|
93
95
|
restaurantCode: n,
|
|
@@ -96,32 +98,32 @@ const Ee = {
|
|
|
96
98
|
code: w ? w.code : ""
|
|
97
99
|
}
|
|
98
100
|
};
|
|
99
|
-
})),
|
|
101
|
+
})), z = g(() => j.value.filter((t) => {
|
|
100
102
|
var e, s;
|
|
101
103
|
return t.user.name.toLowerCase().includes(c.value.toLowerCase()) || t.restaurantName.toLowerCase().includes(c.value.toLowerCase()) || ((e = t.restaurantCode) == null ? void 0 : e.toLowerCase().includes(c.value.toLowerCase())) || ((s = t.user.code) == null ? void 0 : s.toLowerCase().includes(c.value.toLowerCase()));
|
|
102
104
|
})), H = g(() => {
|
|
103
|
-
const t = Fe(
|
|
105
|
+
const t = Fe(j.value, (s) => s.user.name), e = Object.entries(t).map(([s, n]) => {
|
|
104
106
|
const w = F.value.find((y) => y._id === n[0].user.id);
|
|
105
107
|
return {
|
|
106
108
|
key: s,
|
|
107
109
|
user: n[0].user.name,
|
|
108
110
|
code: w ? w.code : n[0].user.code || "",
|
|
109
111
|
timesheets: n,
|
|
110
|
-
total: Le(n.reduce((y,
|
|
112
|
+
total: Le(n.reduce((y, f) => y + f.totalMin, 0))
|
|
111
113
|
};
|
|
112
114
|
});
|
|
113
115
|
return Ye(e, {
|
|
114
116
|
selector: "user"
|
|
115
117
|
});
|
|
116
|
-
}),
|
|
118
|
+
}), N = g(() => H.value.filter((t) => {
|
|
117
119
|
var e;
|
|
118
120
|
return t.user.toLowerCase().includes(c.value.toLowerCase()) || ((e = t.code) == null ? void 0 : e.toLowerCase().includes(c.value.toLowerCase()));
|
|
119
|
-
})),
|
|
121
|
+
})), Y = d(!1), U = async () => {
|
|
120
122
|
const {
|
|
121
123
|
startDate: t,
|
|
122
124
|
endDate: e
|
|
123
|
-
} =
|
|
124
|
-
|
|
125
|
+
} = L.value;
|
|
126
|
+
Y.value = !0;
|
|
125
127
|
try {
|
|
126
128
|
await h.readTimesheet(new Date(t), new Date(e)), await ye(), B.value = Object.fromEntries(Object.entries(new Array(H.value.length).fill(!0)));
|
|
127
129
|
} catch (s) {
|
|
@@ -130,12 +132,12 @@ const Ee = {
|
|
|
130
132
|
type: "error"
|
|
131
133
|
});
|
|
132
134
|
} finally {
|
|
133
|
-
|
|
135
|
+
Y.value = !1;
|
|
134
136
|
}
|
|
135
137
|
};
|
|
136
138
|
fe(async () => {
|
|
137
139
|
try {
|
|
138
|
-
await C.readRestaurants(),
|
|
140
|
+
await C.readRestaurants(), k.employees.value.length === 0 && await k.readEmployees();
|
|
139
141
|
} catch (t) {
|
|
140
142
|
console.error("Failed to load timesheet dependencies:", t), D.open({
|
|
141
143
|
message: t instanceof Error ? t.message : String(t),
|
|
@@ -148,11 +150,11 @@ const Ee = {
|
|
|
148
150
|
label: `${t.profile.code ? `${t.profile.code} - ` : ""}${t.profile.name}`,
|
|
149
151
|
value: t._id
|
|
150
152
|
}))), {
|
|
151
|
-
dateRange:
|
|
153
|
+
dateRange: L,
|
|
152
154
|
dateRangeLabel: oe,
|
|
153
|
-
setRange:
|
|
155
|
+
setRange: G
|
|
154
156
|
} = $e();
|
|
155
|
-
|
|
157
|
+
Z(L, async () => {
|
|
156
158
|
U();
|
|
157
159
|
});
|
|
158
160
|
const se = [{
|
|
@@ -241,67 +243,67 @@ const Ee = {
|
|
|
241
243
|
return e.total ? `Total: ${e.total}` : e.duration;
|
|
242
244
|
},
|
|
243
245
|
enableSorting: !1
|
|
244
|
-
}],
|
|
245
|
-
function
|
|
246
|
-
|
|
246
|
+
}], M = d(!1);
|
|
247
|
+
function q(t) {
|
|
248
|
+
p.value = t, T.value = v(p.value.startedAt).format("YYYY-MM-DD"), I.value = v(p.value.endedAt || p.value.startedAt).format("YYYY-MM-DD"), R.value = v(p.value.startedAt).format("HH:mm"), $.value = v(p.value.endedAt || p.value.startedAt).format("HH:mm"), M.value = !0;
|
|
247
249
|
}
|
|
248
|
-
const
|
|
250
|
+
const T = d(), R = d(), I = d(), $ = d(), p = d(), K = d("");
|
|
249
251
|
async function re() {
|
|
250
|
-
const t =
|
|
251
|
-
if (
|
|
252
|
+
const t = J(T.value, R.value), e = J(I.value, $.value);
|
|
253
|
+
if (v(t).isAfter(e)) {
|
|
252
254
|
K.value = a("hr.timesheet.checkOutMustBeforeCheckIn");
|
|
253
255
|
return;
|
|
254
256
|
}
|
|
255
257
|
S.minor(async () => {
|
|
256
|
-
await h.updateTimesheet(
|
|
258
|
+
await h.updateTimesheet(p.value, t, e);
|
|
257
259
|
}, {
|
|
258
260
|
successMessage: a("hr.timesheet.update.successMessage")
|
|
259
|
-
}), U(),
|
|
261
|
+
}), U(), M.value = !1;
|
|
260
262
|
}
|
|
261
|
-
const
|
|
262
|
-
return
|
|
263
|
+
const J = (t, e) => v(t).set("h", parseInt(e.split(":")[0])).set("m", parseInt(e.split(":")[1])).toISOString();
|
|
264
|
+
return Z([T, I, R, $], ([t, e, s, n]) => {
|
|
263
265
|
(t || e || s || n) && (K.value = "");
|
|
264
266
|
}), (t, e) => {
|
|
265
|
-
const s = u("FmAvatar"), n = u("FmDatePicker"), w = u("FmTimePicker"), y = u("FmIcon"),
|
|
266
|
-
return
|
|
267
|
-
modelValue:
|
|
268
|
-
"onUpdate:modelValue": e[5] || (e[5] = (o) =>
|
|
267
|
+
const s = u("FmAvatar"), n = u("FmDatePicker"), w = u("FmTimePicker"), y = u("FmIcon"), f = u("FmButton"), ne = u("FmSideSheet"), Q = u("FmChip"), ie = u("FmDateRangePicker"), ue = u("FmMenuItem"), de = u("FmMenu"), ce = u("FmSpacer"), me = u("FmSearch"), W = u("FmTable");
|
|
268
|
+
return E(), P(ee, null, [l(ne, {
|
|
269
|
+
modelValue: M.value,
|
|
270
|
+
"onUpdate:modelValue": e[5] || (e[5] = (o) => M.value = o),
|
|
269
271
|
"dismiss-away": "",
|
|
270
272
|
header: r(a)("hr.timesheet.update.title")
|
|
271
273
|
}, {
|
|
272
|
-
"side-sheet-footer":
|
|
274
|
+
"side-sheet-footer": b(() => [i("div", qe, [l(f, {
|
|
273
275
|
label: r(a)("common.update"),
|
|
274
276
|
size: "md",
|
|
275
277
|
variant: "primary",
|
|
276
278
|
onClick: re
|
|
277
|
-
}, null, 8, ["label"]), l(
|
|
279
|
+
}, null, 8, ["label"]), l(f, {
|
|
278
280
|
label: r(a)("common.cancel"),
|
|
279
281
|
size: "md",
|
|
280
282
|
variant: "secondary",
|
|
281
|
-
onClick: e[4] || (e[4] = (o) =>
|
|
283
|
+
onClick: e[4] || (e[4] = (o) => M.value = !1)
|
|
282
284
|
}, null, 8, ["label"])])]),
|
|
283
|
-
default:
|
|
284
|
-
name:
|
|
285
|
+
default: b(() => [i("div", Ee, [i("div", Oe, [l(s, {
|
|
286
|
+
name: p.value.user.name,
|
|
285
287
|
size: "lg"
|
|
286
|
-
}, null, 8, ["name"]), i("div", Ae, [i("div", Ke, O(r(a)("hr.timesheet.employeeName")), 1), i("div", ze, O(
|
|
287
|
-
modelValue:
|
|
288
|
-
"onUpdate:modelValue": e[0] || (e[0] = (o) =>
|
|
288
|
+
}, null, 8, ["name"]), i("div", Ae, [i("div", Ke, O(r(a)("hr.timesheet.employeeName")), 1), i("div", ze, O(p.value.user.name), 1)])]), i("div", Ne, [i("div", Ue, O(r(a)("hr.timesheet.update.checkIn")), 1), i("div", Be, [l(n, {
|
|
289
|
+
modelValue: T.value,
|
|
290
|
+
"onUpdate:modelValue": e[0] || (e[0] = (o) => T.value = o),
|
|
289
291
|
disabled: !1,
|
|
290
292
|
label: r(a)("hr.timesheet.update.date")
|
|
291
293
|
}, null, 8, ["modelValue", "label"]), l(w, {
|
|
292
|
-
modelValue:
|
|
293
|
-
"onUpdate:modelValue": e[1] || (e[1] = (o) =>
|
|
294
|
+
modelValue: R.value,
|
|
295
|
+
"onUpdate:modelValue": e[1] || (e[1] = (o) => R.value = o),
|
|
294
296
|
label: r(a)("hr.timesheet.update.time")
|
|
295
297
|
}, null, 8, ["modelValue", "label"])])]), i("div", Pe, [i("div", je, O(r(a)("hr.timesheet.update.checkOut")), 1), i("div", He, [l(n, {
|
|
296
|
-
modelValue:
|
|
297
|
-
"onUpdate:modelValue": e[2] || (e[2] = (o) =>
|
|
298
|
+
modelValue: I.value,
|
|
299
|
+
"onUpdate:modelValue": e[2] || (e[2] = (o) => I.value = o),
|
|
298
300
|
disabled: !1,
|
|
299
301
|
label: r(a)("hr.timesheet.update.date")
|
|
300
302
|
}, null, 8, ["modelValue", "label"]), l(w, {
|
|
301
|
-
modelValue:
|
|
302
|
-
"onUpdate:modelValue": e[3] || (e[3] = (o) =>
|
|
303
|
+
modelValue: $.value,
|
|
304
|
+
"onUpdate:modelValue": e[3] || (e[3] = (o) => $.value = o),
|
|
303
305
|
label: r(a)("hr.timesheet.update.time")
|
|
304
|
-
}, null, 8, ["modelValue", "label"])])]), K.value ? (
|
|
306
|
+
}, null, 8, ["modelValue", "label"])])]), K.value ? (E(), P("div", Ge, [l(y, {
|
|
305
307
|
color: "#FF3B30",
|
|
306
308
|
name: "error",
|
|
307
309
|
size: "sm"
|
|
@@ -317,33 +319,33 @@ const Ee = {
|
|
|
317
319
|
placeholder: r(a)("hr.role.columns.restaurants"),
|
|
318
320
|
class: "!w-auto pt-[3px]"
|
|
319
321
|
}, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"]), i("div", We, [l(ie, {
|
|
320
|
-
modelValue: r(
|
|
321
|
-
"onUpdate:modelValue": e[7] || (e[7] = (o) => ge(
|
|
322
|
+
modelValue: r(L),
|
|
323
|
+
"onUpdate:modelValue": e[7] || (e[7] = (o) => ge(L) ? L.value = o : null),
|
|
322
324
|
"show-predefined-range": ""
|
|
323
325
|
}, {
|
|
324
|
-
"trigger-button":
|
|
326
|
+
"trigger-button": b(() => [l(Q, {
|
|
325
327
|
label: r(oe)
|
|
326
328
|
}, null, 8, ["label"])]),
|
|
327
329
|
_: 1
|
|
328
|
-
}, 8, ["modelValue"]), l(
|
|
330
|
+
}, 8, ["modelValue"]), l(f, {
|
|
329
331
|
icon: "chevron_left",
|
|
330
332
|
variant: "tertiary",
|
|
331
|
-
onClick: e[8] || (e[8] = (o) => r(
|
|
332
|
-
}), l(
|
|
333
|
+
onClick: e[8] || (e[8] = (o) => r(G)("subtract"))
|
|
334
|
+
}), l(f, {
|
|
333
335
|
icon: "chevron_right",
|
|
334
336
|
variant: "tertiary",
|
|
335
|
-
onClick: e[9] || (e[9] = (o) => r(
|
|
337
|
+
onClick: e[9] || (e[9] = (o) => r(G)("add"))
|
|
336
338
|
})]), l(de, {
|
|
337
339
|
class: "pt-[3px]"
|
|
338
340
|
}, {
|
|
339
|
-
"menu-button":
|
|
340
|
-
label:
|
|
341
|
+
"menu-button": b(() => [l(Q, {
|
|
342
|
+
label: _.value,
|
|
341
343
|
"right-icon": "keyboard_arrow_down"
|
|
342
344
|
}, null, 8, ["label"])]),
|
|
343
|
-
default:
|
|
345
|
+
default: b(() => [(E(), P(ee, null, we(V, (o) => l(ue, {
|
|
344
346
|
key: o.value,
|
|
345
347
|
label: o.label,
|
|
346
|
-
onClick: (
|
|
348
|
+
onClick: (X) => m.value = o.value
|
|
347
349
|
}, null, 8, ["label", "onClick"])), 64))]),
|
|
348
350
|
_: 1
|
|
349
351
|
}), l(ce), l(me, {
|
|
@@ -351,44 +353,48 @@ const Ee = {
|
|
|
351
353
|
"onUpdate:modelValue": e[10] || (e[10] = (o) => c.value = o),
|
|
352
354
|
class: "w-[320px]",
|
|
353
355
|
placeholder: r(a)("hr.timesheet.search.placeholder")
|
|
354
|
-
}, null, 8, ["modelValue", "placeholder"])]),
|
|
355
|
-
|
|
356
|
-
title: r(a)("hr.timesheet.noData.title"),
|
|
357
|
-
subtitle: ""
|
|
358
|
-
}, null, 8, ["title"])) : (_(), z(ke, {
|
|
359
|
-
key: 1,
|
|
360
|
-
class: "w-full xs:px-16 overflow-auto"
|
|
356
|
+
}, null, 8, ["modelValue", "placeholder"])]), l(Ve, {
|
|
357
|
+
class: "w-full xs:px-16"
|
|
361
358
|
}, {
|
|
362
|
-
default:
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
"
|
|
366
|
-
|
|
367
|
-
"
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
"
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
359
|
+
default: b(() => [i("div", Xe, [l(ke, {
|
|
360
|
+
"is-loading": Y.value,
|
|
361
|
+
"is-empty": m.value === "listView" ? z.value.length === 0 : N.value.length === 0,
|
|
362
|
+
"collapse-at": !1,
|
|
363
|
+
title: r(a)("hr.timesheet.noData.title"),
|
|
364
|
+
subtitle: ""
|
|
365
|
+
}, {
|
|
366
|
+
default: b(() => [m.value === "listView" ? (E(), te(W, {
|
|
367
|
+
key: 0,
|
|
368
|
+
class: "min-w-[640px]",
|
|
369
|
+
"column-defs": se,
|
|
370
|
+
"row-data": z.value,
|
|
371
|
+
"page-size": z.value.length,
|
|
372
|
+
loading: Y.value,
|
|
373
|
+
"pin-header-row": "",
|
|
374
|
+
"hide-footer": "",
|
|
375
|
+
"shrink-at": !1,
|
|
376
|
+
onRowClick: e[11] || (e[11] = (o) => q(o.original))
|
|
377
|
+
}, null, 8, ["row-data", "page-size", "loading"])) : (E(), te(W, {
|
|
378
|
+
key: 1,
|
|
379
|
+
class: "min-w-[640px] timesheet-user-view",
|
|
380
|
+
"column-defs": le,
|
|
381
|
+
"row-data": N.value,
|
|
382
|
+
"page-size": N.value.reduce((o, X) => o + 1 + X.timesheets.length, 0),
|
|
383
|
+
loading: Y.value,
|
|
384
|
+
"pin-header-row": "",
|
|
385
|
+
"shrink-at": !1,
|
|
386
|
+
"expanded-state": B.value,
|
|
387
|
+
"get-sub-row": (o) => o.timesheets,
|
|
388
|
+
"onUpdate:expandedState": e[12] || (e[12] = (o) => B.value = o),
|
|
389
|
+
onRowClick: e[13] || (e[13] = (o) => q(o.original))
|
|
390
|
+
}, null, 8, ["row-data", "page-size", "loading", "expanded-state", "get-sub-row"]))]),
|
|
391
|
+
_: 1
|
|
392
|
+
}, 8, ["is-loading", "is-empty", "title"])])]),
|
|
387
393
|
_: 1
|
|
388
|
-
})
|
|
394
|
+
})])], 64);
|
|
389
395
|
};
|
|
390
396
|
}
|
|
391
|
-
}),
|
|
397
|
+
}), pt = /* @__PURE__ */ Se(Ze, [["__scopeId", "data-v-2c7a177a"]]);
|
|
392
398
|
export {
|
|
393
|
-
|
|
399
|
+
pt as default
|
|
394
400
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { d as i } from "./dayjs.min-
|
|
1
|
+
import { d as i } from "./dayjs.min-BXBPls4m.js";
|
|
2
2
|
import { defineStore as p, storeToRefs as T } from "pinia";
|
|
3
3
|
import { ref as l } from "vue";
|
|
4
4
|
import { b as c, g as y } from "./restaurant-YOVMuuFY.js";
|
|
5
|
-
import { s as S } from "./iteration-
|
|
5
|
+
import { s as S } from "./iteration-BCbIbdHR.js";
|
|
6
6
|
import { i as f, f as g } from "./utils-BZkjJbju.js";
|
|
7
7
|
const u = {
|
|
8
8
|
async readTimesheets(t, e) {
|