@feedmepos/mf-hrm-portal 2.0.20 → 2.0.21
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/{AuditLogList-TOZRNTSo.js → AuditLogList-COhT1PFG.js} +4 -4
- package/dist/{EmployeeList-CqAhLDpa.js → EmployeeList-CBfr6g9t.js} +6 -6
- package/dist/{Main-ZnQXWxWY.js → Main-BEfbP-bs.js} +6 -6
- package/dist/{Main-DwipzHNI.js → Main-D1dN1FTE.js} +9 -9
- package/dist/{Main-CNsbo8k2.js → Main-gByKBqZC.js} +4 -4
- package/dist/{PermissionSetList-DH2Cwyis.js → PermissionSetList-CHLm6ueB.js} +6 -6
- package/dist/{PortalPermissionEditor.vue_vue_type_script_setup_true_lang-CWS0T07y.js → PortalPermissionEditor.vue_vue_type_script_setup_true_lang-BRb3aRsV.js} +748 -748
- package/dist/{PortalUserSearcher.vue_vue_type_style_index_0_scoped_a439fdd8_lang-oqww39U7.js → PortalUserSearcher.vue_vue_type_style_index_0_scoped_a439fdd8_lang-BW8o67ka.js} +1 -1
- package/dist/{RoleList-DcrMX2Mi.js → RoleList-mgMUDQa_.js} +7 -7
- package/dist/{TeamMemberList-MBwOsPwC.js → TeamMemberList-Bdtm1lLi.js} +8 -8
- package/dist/{TimesheetList-KChmIX6Q.js → TimesheetList-BdO8bRzv.js} +113 -113
- package/dist/{app-DGh3k8-U.js → app-DdGJIhvX.js} +180 -179
- package/dist/app.js +1 -1
- package/dist/{dayjs.min-BxM3dCKV.js → dayjs.min-Dn0iKqwG.js} +1 -1
- package/dist/{employee-C4FMY6tR.js → employee-rjbsWBRt.js} +3 -3
- package/dist/{iteration-BsPfVFYw.js → iteration-iN8h5bwW.js} +1 -1
- package/dist/{lodash-COviVyx5.js → lodash-BX4i2dq_.js} +1 -1
- package/dist/{rule-BR8uiSU2.js → rule-CBauoBQ2.js} +2 -2
- package/dist/{timesheet-DtssF2P4.js → timesheet-q4UbovJv.js} +2 -2
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{useAppStore-DhnL8kOw.js → useAppStore-DPDMpfh5.js} +1 -1
- package/dist/{useLoading-BdA-bKJE.js → useLoading-DLMKZcST.js} +1 -1
- package/dist/{useReportPermissions-Dqo3v4ao.js → useReportPermissions-DjUtbNV6.js} +3 -3
- package/package.json +1 -1
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import { ref as d, computed as g, defineComponent as
|
|
2
|
-
import { d as
|
|
3
|
-
import { useI18n as
|
|
4
|
-
import { useSnackbar as
|
|
5
|
-
import { S as
|
|
6
|
-
import { _ as
|
|
7
|
-
import { _ as
|
|
8
|
-
import { u as
|
|
9
|
-
import { u as
|
|
10
|
-
import { f as
|
|
11
|
-
import { u as
|
|
12
|
-
import { u as
|
|
13
|
-
function
|
|
1
|
+
import { ref as d, computed as g, defineComponent as pe, onMounted as fe, watch as ee, resolveComponent as u, createElementBlock as P, openBlock as _, Fragment as te, createVNode as l, createElementVNode as i, unref as r, withCtx as Y, createCommentVNode as ve, toDisplayString as O, createTextVNode as he, createBlock as z, isRef as ge, renderList as ye, nextTick as we } from "vue";
|
|
2
|
+
import { d as f } from "./dayjs.min-Dn0iKqwG.js";
|
|
3
|
+
import { useI18n as be } from "@feedmepos/mf-common";
|
|
4
|
+
import { useSnackbar as _e, components as xe } from "@feedmepos/ui-library";
|
|
5
|
+
import { S as De } from "./SelectFilter-DUj7GBtT.js";
|
|
6
|
+
import { _ as Se } from "./app-DdGJIhvX.js";
|
|
7
|
+
import { _ as ke } from "./index.vue_vue_type_script_setup_true_lang-Vc5ARO29.js";
|
|
8
|
+
import { u as Ve } from "./useLoading-DLMKZcST.js";
|
|
9
|
+
import { u as Ce, c as Fe, s as Ye } from "./iteration-iN8h5bwW.js";
|
|
10
|
+
import { f as Le } from "./utils-BZkjJbju.js";
|
|
11
|
+
import { u as Me } from "./employee-rjbsWBRt.js";
|
|
12
|
+
import { u as Te } from "./timesheet-q4UbovJv.js";
|
|
13
|
+
function Re(x, a) {
|
|
14
14
|
return ["years", "months"].find((S) => {
|
|
15
|
-
const k = x.startOf(S),
|
|
16
|
-
return x.isSame(k, "day") && a.isSame(
|
|
15
|
+
const k = x.startOf(S), v = x.endOf(S);
|
|
16
|
+
return x.isSame(k, "day") && a.isSame(v, "day");
|
|
17
17
|
}) || "days";
|
|
18
18
|
}
|
|
19
|
-
function
|
|
19
|
+
function $e() {
|
|
20
20
|
const x = {
|
|
21
|
-
startDate:
|
|
22
|
-
endDate:
|
|
21
|
+
startDate: f().format("YYYY-MM-DD"),
|
|
22
|
+
endDate: f().format("YYYY-MM-DD")
|
|
23
23
|
}, a = d(x), D = g(() => {
|
|
24
24
|
if (!a.value) return "No dates selected.";
|
|
25
|
-
const
|
|
26
|
-
return `${
|
|
25
|
+
const v = a.value.startDate ?? "Start", b = a.value.endDate ?? "End";
|
|
26
|
+
return `${v} - ${b}`;
|
|
27
27
|
}), S = g(() => ({
|
|
28
28
|
startDate: new Date(a.value.startDate),
|
|
29
29
|
endDate: new Date(a.value.endDate)
|
|
30
30
|
}));
|
|
31
|
-
function k(
|
|
32
|
-
const b =
|
|
31
|
+
function k(v) {
|
|
32
|
+
const b = f(a.value.startDate), c = f(a.value.endDate), h = Re(b, c), V = h === "days" ? c.diff(b, "days") + 1 : 1, C = v === "subtract" ? (F) => F.subtract(V, h) : (F) => F.add(V, h);
|
|
33
33
|
a.value = {
|
|
34
34
|
startDate: C(b).startOf(h).format("YYYY-MM-DD"),
|
|
35
35
|
endDate: C(c).endOf(h).format("YYYY-MM-DD")
|
|
@@ -37,79 +37,79 @@ function Re() {
|
|
|
37
37
|
}
|
|
38
38
|
return { dateRange: a, parsedDateRange: S, dateRangeLabel: D, setRange: k };
|
|
39
39
|
}
|
|
40
|
-
const
|
|
40
|
+
const Ie = {
|
|
41
41
|
class: "my-16 flex w-[350px] flex-col gap-40"
|
|
42
|
-
}, Ie = {
|
|
43
|
-
class: "flex gap-16"
|
|
44
42
|
}, Ee = {
|
|
45
|
-
class: "flex
|
|
43
|
+
class: "flex gap-16"
|
|
46
44
|
}, Oe = {
|
|
47
|
-
class: "
|
|
45
|
+
class: "flex flex-col gap-4"
|
|
48
46
|
}, Ae = {
|
|
49
|
-
class: "fm-typo-body-md-
|
|
47
|
+
class: "fm-typo-body-md-400 text-fm-color-typo-secondary"
|
|
50
48
|
}, Ke = {
|
|
51
|
-
class: "
|
|
49
|
+
class: "fm-typo-body-md-700 text-fm-color-typo-primary"
|
|
52
50
|
}, ze = {
|
|
53
|
-
class: "
|
|
51
|
+
class: "flex flex-col gap-8"
|
|
54
52
|
}, Ne = {
|
|
55
|
-
class: "
|
|
53
|
+
class: "fm-typo-body-xl-700"
|
|
56
54
|
}, Ue = {
|
|
57
|
-
class: "flex flex-col gap-
|
|
55
|
+
class: "flex flex-col gap-24"
|
|
58
56
|
}, Be = {
|
|
59
|
-
class: "
|
|
57
|
+
class: "flex flex-col gap-8"
|
|
60
58
|
}, Pe = {
|
|
61
|
-
class: "
|
|
59
|
+
class: "fm-typo-body-xl-700"
|
|
62
60
|
}, je = {
|
|
61
|
+
class: "flex flex-col gap-24"
|
|
62
|
+
}, He = {
|
|
63
63
|
key: 0,
|
|
64
64
|
class: "fm-typo-body-sm-400 text-fm-color-typo-error mt-1 flex items-center gap-4"
|
|
65
|
-
}, He = {
|
|
66
|
-
class: "flex items-center justify-start gap-8"
|
|
67
65
|
}, Ge = {
|
|
68
|
-
class: "
|
|
66
|
+
class: "flex items-center justify-start gap-8"
|
|
69
67
|
}, qe = {
|
|
70
|
-
class: "
|
|
68
|
+
class: "space-y-8"
|
|
71
69
|
}, Je = {
|
|
70
|
+
class: "flex items-start gap-8 flex-wrap xs:px-16"
|
|
71
|
+
}, Qe = {
|
|
72
72
|
class: "flex items-center gap-8"
|
|
73
|
-
}, ut = /* @__PURE__ */
|
|
73
|
+
}, ut = /* @__PURE__ */ pe({
|
|
74
74
|
__name: "TimesheetList",
|
|
75
75
|
setup(x) {
|
|
76
76
|
const {
|
|
77
77
|
t: a
|
|
78
|
-
} =
|
|
78
|
+
} = be(), D = _e(), S = Ve(D), k = [{
|
|
79
79
|
label: a("hr.timesheet.listView"),
|
|
80
80
|
value: "listView"
|
|
81
81
|
}, {
|
|
82
82
|
label: a("hr.timesheet.userView"),
|
|
83
83
|
value: "userView"
|
|
84
|
-
}],
|
|
84
|
+
}], v = d("listView"), b = g(() => {
|
|
85
85
|
var t;
|
|
86
|
-
return (t = k.find((e) => e.value ===
|
|
87
|
-
}), c = d(""), h =
|
|
86
|
+
return (t = k.find((e) => e.value === v.value)) == null ? void 0 : t.label;
|
|
87
|
+
}), c = d(""), h = Te(), V = Me(), C = Ce(), F = g(() => V.employees.value), N = g(() => h.timesheets.value.filter((s) => !A.value || A.value.includes(s.restaurantId)).map((s) => {
|
|
88
88
|
var w;
|
|
89
|
-
const
|
|
89
|
+
const n = (w = C.restaurants.value.find((p) => p._id === s.restaurantId)) == null ? void 0 : w.profile.code, y = F.value.find((p) => p._id === s.user.id);
|
|
90
90
|
return {
|
|
91
91
|
...s,
|
|
92
|
-
restaurantCode:
|
|
92
|
+
restaurantCode: n,
|
|
93
93
|
user: {
|
|
94
94
|
...s.user,
|
|
95
95
|
code: y ? y.code : ""
|
|
96
96
|
}
|
|
97
97
|
};
|
|
98
|
-
})), j = g(() =>
|
|
98
|
+
})), j = g(() => N.value.filter((t) => {
|
|
99
99
|
var e, s;
|
|
100
100
|
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()));
|
|
101
101
|
})), H = g(() => {
|
|
102
|
-
const t =
|
|
103
|
-
const y = F.value.find((w) => w._id ===
|
|
102
|
+
const t = Fe(N.value, (s) => s.user.name), e = Object.entries(t).map(([s, n]) => {
|
|
103
|
+
const y = F.value.find((w) => w._id === n[0].user.id);
|
|
104
104
|
return {
|
|
105
105
|
key: s,
|
|
106
|
-
user:
|
|
107
|
-
code: y ? y.code : "",
|
|
108
|
-
timesheets:
|
|
109
|
-
total:
|
|
106
|
+
user: n[0].user.name,
|
|
107
|
+
code: y ? y.code : n[0].user.code || "",
|
|
108
|
+
timesheets: n,
|
|
109
|
+
total: Le(n.reduce((w, p) => w + p.totalMin, 0))
|
|
110
110
|
};
|
|
111
111
|
});
|
|
112
|
-
return
|
|
112
|
+
return Ye(e, {
|
|
113
113
|
selector: "user"
|
|
114
114
|
});
|
|
115
115
|
}), G = g(() => H.value.filter((t) => {
|
|
@@ -122,7 +122,7 @@ const $e = {
|
|
|
122
122
|
} = M.value;
|
|
123
123
|
L.value = !0;
|
|
124
124
|
try {
|
|
125
|
-
await h.readTimesheet(new Date(t), new Date(e)), await
|
|
125
|
+
await h.readTimesheet(new Date(t), new Date(e)), await we(), B.value = Object.fromEntries(Object.entries(new Array(H.value.length).fill(!0)));
|
|
126
126
|
} catch (s) {
|
|
127
127
|
D.open({
|
|
128
128
|
title: s instanceof Error ? s.message : `${s}`,
|
|
@@ -132,7 +132,7 @@ const $e = {
|
|
|
132
132
|
L.value = !1;
|
|
133
133
|
}
|
|
134
134
|
};
|
|
135
|
-
|
|
135
|
+
fe(async () => {
|
|
136
136
|
try {
|
|
137
137
|
await C.readRestaurants(), V.employees.value.length === 0 && await V.readEmployees();
|
|
138
138
|
} catch (t) {
|
|
@@ -143,18 +143,18 @@ const $e = {
|
|
|
143
143
|
}
|
|
144
144
|
U();
|
|
145
145
|
});
|
|
146
|
-
const
|
|
146
|
+
const A = d(), ae = g(() => C.restaurants.value.filter((t) => t.managable).map((t) => ({
|
|
147
147
|
label: `${t.profile.code ? `${t.profile.code} - ` : ""}${t.profile.name}`,
|
|
148
148
|
value: t._id
|
|
149
149
|
}))), {
|
|
150
150
|
dateRange: M,
|
|
151
|
-
dateRangeLabel:
|
|
151
|
+
dateRangeLabel: oe,
|
|
152
152
|
setRange: q
|
|
153
|
-
} =
|
|
154
|
-
|
|
153
|
+
} = $e();
|
|
154
|
+
ee(M, async () => {
|
|
155
155
|
U();
|
|
156
156
|
});
|
|
157
|
-
const
|
|
157
|
+
const se = [{
|
|
158
158
|
accessorKey: "user.code",
|
|
159
159
|
size: 100,
|
|
160
160
|
header: () => a("hr.employee.columns.code"),
|
|
@@ -189,7 +189,7 @@ const $e = {
|
|
|
189
189
|
header: () => a("hr.timesheet.columns.duration"),
|
|
190
190
|
cell: (t) => t.row.original.duration || "--",
|
|
191
191
|
enableSorting: !0
|
|
192
|
-
}], B = d({}),
|
|
192
|
+
}], B = d({}), le = [{
|
|
193
193
|
accessorKey: "code",
|
|
194
194
|
size: 100,
|
|
195
195
|
header: () => a("hr.employee.columns.code"),
|
|
@@ -205,10 +205,10 @@ const $e = {
|
|
|
205
205
|
return l("div", {
|
|
206
206
|
class: "flex items-center gap-8"
|
|
207
207
|
}, [l("div", {
|
|
208
|
-
onClick: (
|
|
209
|
-
|
|
208
|
+
onClick: (n) => {
|
|
209
|
+
n.stopPropagation(), t.row.getToggleExpandedHandler()(n);
|
|
210
210
|
}
|
|
211
|
-
}, [l(
|
|
211
|
+
}, [l(xe.FmButton, {
|
|
212
212
|
variant: "tertiary",
|
|
213
213
|
icon: s ? "keyboard_arrow_up" : "keyboard_arrow_down"
|
|
214
214
|
}, null)]), e.user]);
|
|
@@ -242,13 +242,13 @@ const $e = {
|
|
|
242
242
|
enableSorting: !1
|
|
243
243
|
}], T = d(!1);
|
|
244
244
|
function J(t) {
|
|
245
|
-
m.value = t, R.value =
|
|
245
|
+
m.value = t, R.value = f(m.value.startedAt).format("YYYY-MM-DD"), I.value = f(m.value.endedAt || m.value.startedAt).format("YYYY-MM-DD"), $.value = f(m.value.startedAt).format("HH:mm"), E.value = f(m.value.endedAt || m.value.startedAt).format("HH:mm"), T.value = !0;
|
|
246
246
|
}
|
|
247
|
-
const R = d(), $ = d(), I = d(), E = d(), m = d(),
|
|
248
|
-
async function
|
|
247
|
+
const R = d(), $ = d(), I = d(), E = d(), m = d(), K = d("");
|
|
248
|
+
async function re() {
|
|
249
249
|
const t = Q(R.value, $.value), e = Q(I.value, E.value);
|
|
250
|
-
if (
|
|
251
|
-
|
|
250
|
+
if (f(t).isAfter(e)) {
|
|
251
|
+
K.value = a("hr.timesheet.checkOutMustBeforeCheckIn");
|
|
252
252
|
return;
|
|
253
253
|
}
|
|
254
254
|
S.minor(async () => {
|
|
@@ -257,111 +257,111 @@ const $e = {
|
|
|
257
257
|
successMessage: a("hr.timesheet.update.successMessage")
|
|
258
258
|
}), U(), T.value = !1;
|
|
259
259
|
}
|
|
260
|
-
const Q = (t, e) =>
|
|
261
|
-
return
|
|
262
|
-
(t || e || s ||
|
|
260
|
+
const Q = (t, e) => f(t).set("h", parseInt(e.split(":")[0])).set("m", parseInt(e.split(":")[1])).toISOString();
|
|
261
|
+
return ee([R, I, $, E], ([t, e, s, n]) => {
|
|
262
|
+
(t || e || s || n) && (K.value = "");
|
|
263
263
|
}), (t, e) => {
|
|
264
|
-
const s = u("FmAvatar"),
|
|
265
|
-
return _(), P(
|
|
264
|
+
const s = u("FmAvatar"), n = u("FmDatePicker"), y = u("FmTimePicker"), w = u("FmIcon"), p = u("FmButton"), ne = u("FmSideSheet"), W = u("FmChip"), ie = u("FmDateRangePicker"), ue = u("FmMenuItem"), de = u("FmMenu"), ce = u("FmSpacer"), me = u("FmSearch"), X = u("FmTable");
|
|
265
|
+
return _(), P(te, null, [l(ne, {
|
|
266
266
|
modelValue: T.value,
|
|
267
267
|
"onUpdate:modelValue": e[5] || (e[5] = (o) => T.value = o),
|
|
268
268
|
"dismiss-away": "",
|
|
269
|
-
header:
|
|
269
|
+
header: r(a)("hr.timesheet.update.title")
|
|
270
270
|
}, {
|
|
271
|
-
"side-sheet-footer": Y(() => [i("div",
|
|
272
|
-
label:
|
|
271
|
+
"side-sheet-footer": Y(() => [i("div", Ge, [l(p, {
|
|
272
|
+
label: r(a)("common.update"),
|
|
273
273
|
size: "md",
|
|
274
274
|
variant: "primary",
|
|
275
|
-
onClick:
|
|
275
|
+
onClick: re
|
|
276
276
|
}, null, 8, ["label"]), l(p, {
|
|
277
|
-
label:
|
|
277
|
+
label: r(a)("common.cancel"),
|
|
278
278
|
size: "md",
|
|
279
279
|
variant: "secondary",
|
|
280
280
|
onClick: e[4] || (e[4] = (o) => T.value = !1)
|
|
281
281
|
}, null, 8, ["label"])])]),
|
|
282
|
-
default: Y(() => [i("div",
|
|
282
|
+
default: Y(() => [i("div", Ie, [i("div", Ee, [l(s, {
|
|
283
283
|
initials: m.value.user.name,
|
|
284
284
|
size: "lg"
|
|
285
|
-
}, null, 8, ["initials"]), i("div",
|
|
285
|
+
}, null, 8, ["initials"]), i("div", Oe, [i("div", Ae, O(r(a)("hr.timesheet.employeeName")), 1), i("div", Ke, O(m.value.user.name), 1)])]), i("div", ze, [i("div", Ne, O(r(a)("hr.timesheet.update.checkIn")), 1), i("div", Ue, [l(n, {
|
|
286
286
|
modelValue: R.value,
|
|
287
287
|
"onUpdate:modelValue": e[0] || (e[0] = (o) => R.value = o),
|
|
288
288
|
disabled: !1,
|
|
289
|
-
label:
|
|
289
|
+
label: r(a)("hr.timesheet.update.date")
|
|
290
290
|
}, null, 8, ["modelValue", "label"]), l(y, {
|
|
291
291
|
modelValue: $.value,
|
|
292
292
|
"onUpdate:modelValue": e[1] || (e[1] = (o) => $.value = o),
|
|
293
|
-
label:
|
|
294
|
-
}, null, 8, ["modelValue", "label"])])]), i("div",
|
|
293
|
+
label: r(a)("hr.timesheet.update.time")
|
|
294
|
+
}, null, 8, ["modelValue", "label"])])]), i("div", Be, [i("div", Pe, O(r(a)("hr.timesheet.update.checkOut")), 1), i("div", je, [l(n, {
|
|
295
295
|
modelValue: I.value,
|
|
296
296
|
"onUpdate:modelValue": e[2] || (e[2] = (o) => I.value = o),
|
|
297
297
|
disabled: !1,
|
|
298
|
-
label:
|
|
298
|
+
label: r(a)("hr.timesheet.update.date")
|
|
299
299
|
}, null, 8, ["modelValue", "label"]), l(y, {
|
|
300
300
|
modelValue: E.value,
|
|
301
301
|
"onUpdate:modelValue": e[3] || (e[3] = (o) => E.value = o),
|
|
302
|
-
label:
|
|
303
|
-
}, null, 8, ["modelValue", "label"])])]),
|
|
302
|
+
label: r(a)("hr.timesheet.update.time")
|
|
303
|
+
}, null, 8, ["modelValue", "label"])])]), K.value ? (_(), P("div", He, [l(w, {
|
|
304
304
|
color: "#FF3B30",
|
|
305
305
|
name: "error",
|
|
306
306
|
size: "sm"
|
|
307
|
-
}),
|
|
307
|
+
}), he(" " + O(K.value), 1)])) : ve("", !0)])]),
|
|
308
308
|
_: 1
|
|
309
|
-
}, 8, ["modelValue", "header"]), i("div",
|
|
310
|
-
modelValue:
|
|
311
|
-
"onUpdate:modelValue": e[6] || (e[6] = (o) =>
|
|
309
|
+
}, 8, ["modelValue", "header"]), i("div", qe, [i("div", Je, [l(De, {
|
|
310
|
+
modelValue: A.value,
|
|
311
|
+
"onUpdate:modelValue": e[6] || (e[6] = (o) => A.value = o),
|
|
312
312
|
multiple: "",
|
|
313
|
-
items:
|
|
313
|
+
items: ae.value,
|
|
314
314
|
variant: "dark",
|
|
315
|
-
"selected-prefix":
|
|
316
|
-
placeholder:
|
|
315
|
+
"selected-prefix": r(a)("hr.role.columns.restaurants"),
|
|
316
|
+
placeholder: r(a)("hr.role.columns.restaurants"),
|
|
317
317
|
class: "!w-auto pt-[3px]"
|
|
318
|
-
}, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"]), i("div",
|
|
319
|
-
modelValue:
|
|
320
|
-
"onUpdate:modelValue": e[7] || (e[7] = (o) =>
|
|
318
|
+
}, null, 8, ["modelValue", "items", "selected-prefix", "placeholder"]), i("div", Qe, [l(ie, {
|
|
319
|
+
modelValue: r(M),
|
|
320
|
+
"onUpdate:modelValue": e[7] || (e[7] = (o) => ge(M) ? M.value = o : null),
|
|
321
321
|
"show-predefined-range": ""
|
|
322
322
|
}, {
|
|
323
323
|
"trigger-button": Y(() => [l(W, {
|
|
324
|
-
label:
|
|
324
|
+
label: r(oe)
|
|
325
325
|
}, null, 8, ["label"])]),
|
|
326
326
|
_: 1
|
|
327
327
|
}, 8, ["modelValue"]), l(p, {
|
|
328
328
|
icon: "chevron_left",
|
|
329
329
|
variant: "tertiary",
|
|
330
|
-
onClick: e[8] || (e[8] = (o) =>
|
|
330
|
+
onClick: e[8] || (e[8] = (o) => r(q)("subtract"))
|
|
331
331
|
}), l(p, {
|
|
332
332
|
icon: "chevron_right",
|
|
333
333
|
variant: "tertiary",
|
|
334
|
-
onClick: e[9] || (e[9] = (o) =>
|
|
335
|
-
})]), l(
|
|
334
|
+
onClick: e[9] || (e[9] = (o) => r(q)("add"))
|
|
335
|
+
})]), l(de, {
|
|
336
336
|
class: "pt-[3px]"
|
|
337
337
|
}, {
|
|
338
338
|
"menu-button": Y(() => [l(W, {
|
|
339
339
|
label: b.value,
|
|
340
340
|
"right-icon": "keyboard_arrow_down"
|
|
341
341
|
}, null, 8, ["label"])]),
|
|
342
|
-
default: Y(() => [(_(), P(
|
|
342
|
+
default: Y(() => [(_(), P(te, null, ye(k, (o) => l(ue, {
|
|
343
343
|
key: o.value,
|
|
344
344
|
label: o.label,
|
|
345
|
-
onClick: (
|
|
345
|
+
onClick: (Z) => v.value = o.value
|
|
346
346
|
}, null, 8, ["label", "onClick"])), 64))]),
|
|
347
347
|
_: 1
|
|
348
|
-
}), l(
|
|
348
|
+
}), l(ce), l(me, {
|
|
349
349
|
modelValue: c.value,
|
|
350
350
|
"onUpdate:modelValue": e[10] || (e[10] = (o) => c.value = o),
|
|
351
351
|
class: "w-[320px]",
|
|
352
|
-
placeholder:
|
|
353
|
-
}, null, 8, ["modelValue", "placeholder"])]),
|
|
352
|
+
placeholder: r(a)("hr.timesheet.search.placeholder")
|
|
353
|
+
}, null, 8, ["modelValue", "placeholder"])]), N.value.length === 0 && !L.value ? (_(), z(r(ke), {
|
|
354
354
|
key: 0,
|
|
355
|
-
title:
|
|
355
|
+
title: r(a)("hr.timesheet.noData.title"),
|
|
356
356
|
subtitle: ""
|
|
357
|
-
}, null, 8, ["title"])) : (_(),
|
|
357
|
+
}, null, 8, ["title"])) : (_(), z(Se, {
|
|
358
358
|
key: 1,
|
|
359
359
|
class: "w-full xs:px-16 overflow-auto"
|
|
360
360
|
}, {
|
|
361
|
-
default: Y(() => [
|
|
361
|
+
default: Y(() => [v.value === "listView" ? (_(), z(X, {
|
|
362
362
|
key: 0,
|
|
363
363
|
class: "min-w-[640px]",
|
|
364
|
-
"column-defs":
|
|
364
|
+
"column-defs": se,
|
|
365
365
|
"row-data": j.value,
|
|
366
366
|
"page-size": j.value.length,
|
|
367
367
|
loading: L.value,
|
|
@@ -369,12 +369,12 @@ const $e = {
|
|
|
369
369
|
"hide-footer": "",
|
|
370
370
|
"shrink-at": !1,
|
|
371
371
|
onRowClick: e[11] || (e[11] = (o) => J(o.original))
|
|
372
|
-
}, null, 8, ["row-data", "page-size", "loading"])) : (_(),
|
|
372
|
+
}, null, 8, ["row-data", "page-size", "loading"])) : (_(), z(X, {
|
|
373
373
|
key: 1,
|
|
374
374
|
class: "min-w-[640px]",
|
|
375
|
-
"column-defs":
|
|
375
|
+
"column-defs": le,
|
|
376
376
|
"row-data": G.value,
|
|
377
|
-
"page-size":
|
|
377
|
+
"page-size": G.value.reduce((o, Z) => o + 1 + Z.timesheets.length, 0),
|
|
378
378
|
loading: L.value,
|
|
379
379
|
"pin-header-row": "",
|
|
380
380
|
"hide-footer": "",
|