@studio-west/employees 0.6.26 → 0.6.28
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/SheetTable.cjs +3 -3
- package/dist/SheetTable.js +263 -263
- package/dist/WorkTable.cjs +3 -4
- package/dist/WorkTable.js +627 -462
- package/dist/employees.css +1 -1
- package/package.json +1 -1
package/dist/SheetTable.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ref as p, computed as
|
|
1
|
+
import { ref as p, computed as fe, watch as q, resolveComponent as xe, resolveDirective as Ie, createElementBlock as R, openBlock as $, Fragment as Z, createElementVNode as V, createVNode as m, withDirectives as Se, createBlock as A, createCommentVNode as B, unref as s, withCtx as g, renderList as ie, createTextVNode as x, toDisplayString as b } from "vue";
|
|
2
2
|
import { useI18n as Ne } from "vue-i18n";
|
|
3
|
-
import { p as
|
|
3
|
+
import { p as F, b as Me, a as pe, h as _e, c as Ee, d as y } from "./index-2Mx6IUGl.js";
|
|
4
4
|
import { ElSelect as Te, ElOption as Ae, ElSwitch as Ye, ElTable as Ve, ElTableColumn as C, ElButton as te } from "element-plus";
|
|
5
5
|
import { ContextMenu as Be, ContextMenuItem as J, ContextMenuSeparator as Fe, ContextMenuGroup as We } from "@imengyu/vue3-context-menu";
|
|
6
6
|
import { saveAs as Ue } from "file-saver";
|
|
@@ -22,25 +22,25 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
22
22
|
date: String
|
|
23
23
|
},
|
|
24
24
|
setup(ne) {
|
|
25
|
-
const S = ne, { t:
|
|
26
|
-
{ value: "Я", label:
|
|
27
|
-
{ value: "К", label:
|
|
28
|
-
{ value: "ОТ", label:
|
|
29
|
-
{ value: "ДО", label:
|
|
30
|
-
{ value: "Р", label:
|
|
31
|
-
{ value: "ОЖ", label:
|
|
32
|
-
{ value: "Б", label:
|
|
33
|
-
{ value: "НН", label:
|
|
34
|
-
{ value: "ПР", label:
|
|
35
|
-
{ value: "У", label:
|
|
36
|
-
{ value: "УД", label:
|
|
37
|
-
{ value: "Г", label:
|
|
38
|
-
]),
|
|
25
|
+
const S = ne, { t: i, d: Q } = Ne(), ee = p(!1), k = p([]), K = p("0"), w = p(new Date((/* @__PURE__ */ new Date()).getFullYear(), (/* @__PURE__ */ new Date()).getMonth(), 1).setMonth((/* @__PURE__ */ new Date()).getMonth() + Number(K.value))), d = p([]), E = p(""), ue = p([{ value: "all", label: "Все", key: "all" }]), be = p([
|
|
26
|
+
{ value: "Я", label: i("sheet.valid.1") },
|
|
27
|
+
{ value: "К", label: i("sheet.valid.2") },
|
|
28
|
+
{ value: "ОТ", label: i("sheet.valid.3") },
|
|
29
|
+
{ value: "ДО", label: i("sheet.valid.4") },
|
|
30
|
+
{ value: "Р", label: i("sheet.valid.5") },
|
|
31
|
+
{ value: "ОЖ", label: i("sheet.valid.6") },
|
|
32
|
+
{ value: "Б", label: i("sheet.valid.7") },
|
|
33
|
+
{ value: "НН", label: i("sheet.valid.8") },
|
|
34
|
+
{ value: "ПР", label: i("sheet.valid.9") },
|
|
35
|
+
{ value: "У", label: i("sheet.valid.10") },
|
|
36
|
+
{ value: "УД", label: i("sheet.valid.11") },
|
|
37
|
+
{ value: "Г", label: i("sheet.valid.12") }
|
|
38
|
+
]), re = p([]), Ce = p(0), N = p(9), I = p(8), Y = p(0), L = p(0), z = p([]), P = p(!1), oe = p([]), G = p([]), W = p(!1), X = p(1), se = p({
|
|
39
39
|
zIndex: 3,
|
|
40
40
|
minWidth: 230,
|
|
41
41
|
x: 500,
|
|
42
42
|
y: 200
|
|
43
|
-
}), v = p({ name: "", length: 0, code: "" }),
|
|
43
|
+
}), v = p({ name: "", length: 0, code: "" }), _ = p([
|
|
44
44
|
// {code: '00ЗК-00336',
|
|
45
45
|
// days:[
|
|
46
46
|
// {
|
|
@@ -50,196 +50,196 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
50
50
|
// }
|
|
51
51
|
// ]
|
|
52
52
|
// }
|
|
53
|
-
]), f =
|
|
54
|
-
const
|
|
55
|
-
|
|
56
|
-
const t = Array.from(
|
|
57
|
-
return [{ ...
|
|
53
|
+
]), f = fe(() => k.value.flatMap((l, e) => {
|
|
54
|
+
const r = _.value.find((a) => a.code === l.code), u = /* @__PURE__ */ new Map();
|
|
55
|
+
l.days.forEach((a) => u.set(a.day, { ...a })), r && r.days.forEach((a) => u.set(a.day, { ...a }));
|
|
56
|
+
const t = Array.from(u.values());
|
|
57
|
+
return [{ ...l, days: t, key: 0, ids: e, numberNonAppearing: [0, 0] }, { ...l, days: t, key: 1, ids: e, numberNonAppearing: [0, 0] }];
|
|
58
58
|
}));
|
|
59
|
-
q(E, async (
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
}),
|
|
63
|
-
}), q(K, (
|
|
64
|
-
w.value = new Date((/* @__PURE__ */ new Date()).getFullYear(), (/* @__PURE__ */ new Date()).getMonth(), 1).setMonth((/* @__PURE__ */ new Date()).getMonth() + Number(
|
|
59
|
+
q(E, async (l, e) => {
|
|
60
|
+
l !== e && (z.value = [], confirm.value = !1, S.odata.personal.forEach((r) => {
|
|
61
|
+
r.divisionName === l && (z.value.some((u) => (u == null ? void 0 : u.activeText) === r.roleName) || z.value.push({ val: !0, activeText: r.roleName }));
|
|
62
|
+
}), ge());
|
|
63
|
+
}), q(K, (l) => {
|
|
64
|
+
w.value = new Date((/* @__PURE__ */ new Date()).getFullYear(), (/* @__PURE__ */ new Date()).getMonth(), 1).setMonth((/* @__PURE__ */ new Date()).getMonth() + Number(l)), he(), ge();
|
|
65
65
|
}), q(I, () => {
|
|
66
|
-
P.value =
|
|
66
|
+
P.value = W.value;
|
|
67
67
|
}), q(N, () => {
|
|
68
|
-
P.value =
|
|
68
|
+
P.value = W.value;
|
|
69
69
|
}), q(X, () => {
|
|
70
|
-
P.value =
|
|
70
|
+
P.value = W.value;
|
|
71
71
|
});
|
|
72
|
-
const
|
|
73
|
-
if (e.level !== 3 || e.labelClassName === "turn" || e.no === 15 || e.no >
|
|
74
|
-
v.value.ids =
|
|
75
|
-
const t = new Date(w.value),
|
|
76
|
-
v.value.id =
|
|
77
|
-
const h =
|
|
78
|
-
v.value.failure =
|
|
79
|
-
}, le = (
|
|
80
|
-
const e = new Date(w.value),
|
|
81
|
-
let
|
|
82
|
-
switch (
|
|
72
|
+
const we = (l, e, r, u) => {
|
|
73
|
+
if (e.level !== 3 || e.labelClassName === "turn" || e.no === 15 || e.no > d.value.length || !S.checkEdit) return "";
|
|
74
|
+
v.value.ids = l.ids, v.value.key = l.key, v.value.day = e.no < 15 ? e.no : e.no - 1;
|
|
75
|
+
const t = new Date(w.value), a = `${t.getFullYear()}-${(t.getMonth() + 1).toString().padStart(2, "0")}-${(v.value.day + 1).toString().padStart(2, "0")}`, o = _.value.findIndex((c) => c.code === l.code);
|
|
76
|
+
v.value.id = o !== -1 ? _.value[o].days.findIndex((c) => (c == null ? void 0 : c.day) === a) : o, v.value.rest = o !== -1 && v.value.id !== -1, N.value = typeof l.days[v.value.day].tips > "u" ? 9 : parseInt(l.days[v.value.day].tips.match(/(\d{1,2})/)), Y.value = typeof l.days[v.value.day].night > "u" ? 0 : parseInt(l.days[v.value.day].night), L.value = typeof l.days[v.value.day].overtime > "u" ? 0 : parseInt(l.days[v.value.day].overtime), I.value = l.days[v.value.day].time !== "-" ? parseInt(l.days[v.value.day].time + Y.value + L.value) : 8;
|
|
77
|
+
const h = l.days.findIndex((c) => c.day === a);
|
|
78
|
+
v.value.failure = l.days[h].state, se.value.y = u.clientY, se.value.x = u.clientX, v.value.name = i("sheet.choiceOfMode"), W.value = !0, P.value = !1;
|
|
79
|
+
}, le = (l) => {
|
|
80
|
+
const e = new Date(w.value), r = `${e.getFullYear()}-${(e.getMonth() + 1).toString().padStart(2, "0")}-${(v.value.day + 1).toString().padStart(2, "0")}`;
|
|
81
|
+
let u = _.value.findIndex((D) => D.code === k.value[v.value.ids].code), t = k.value[v.value.ids].days[v.value.day].state, a = l, o = "-", h, c, M;
|
|
82
|
+
switch (l) {
|
|
83
83
|
case "Я":
|
|
84
|
-
t === "В" && (
|
|
84
|
+
t === "В" && (a = "РВ"), o = 8;
|
|
85
85
|
break;
|
|
86
86
|
case "КВ":
|
|
87
87
|
case "К":
|
|
88
|
-
t === "В" || t === "КВ" ?
|
|
88
|
+
t === "В" || t === "КВ" ? a = "КВ" : a = "К";
|
|
89
89
|
break;
|
|
90
90
|
case "save":
|
|
91
|
-
let
|
|
92
|
-
if (
|
|
93
|
-
|
|
91
|
+
let D = ve.value.split('"');
|
|
92
|
+
if (a = D[1], P.value = !1, /^(|К|КВ|ОТ|Б|Р|ОЖ|НН|У|ДО|УД|Г)$/.test(D[1])) break;
|
|
93
|
+
o = I.value - Y.value - L.value, M = "(" + D[2].split("(")[1], h = Y.value, c = L.value;
|
|
94
94
|
}
|
|
95
|
-
|
|
95
|
+
l === "reset" ? (a = t, _.value[u].days.splice(v.value.id, 1)) : u === -1 ? _.value.push({ code: k.value[v.value.ids].code, days: [{ day: r, state: a, time: o, night: h, overtime: c, tips: M }] }) : v.value.id === -1 ? _.value[u].days.push({ day: r, state: a, time: o, night: h, overtime: c, tips: M }) : _.value[u].days[v.value.id] = { day: r, state: a, time: o, night: h, overtime: c, tips: M }, S.workSchedule.addWorkSheet({
|
|
96
96
|
group: E.value,
|
|
97
|
-
date:
|
|
97
|
+
date: F(new Date(w.value), "{Y}-{m}-{dd}"),
|
|
98
98
|
data: [{
|
|
99
|
-
name:
|
|
100
|
-
days:
|
|
101
|
-
code:
|
|
99
|
+
name: k.value[v.value.ids].fio,
|
|
100
|
+
days: _.value[u].days,
|
|
101
|
+
code: k.value[v.value.ids].code
|
|
102
102
|
}]
|
|
103
|
-
}), v.value.failure =
|
|
104
|
-
},
|
|
105
|
-
let
|
|
106
|
-
|
|
107
|
-
let t = typeof (
|
|
108
|
-
return '"' +
|
|
109
|
-
}),
|
|
110
|
-
if (
|
|
111
|
-
return f.value[
|
|
103
|
+
}), v.value.failure = a, X.value > 1 && (X.value--, v.value.day++, v.value.id = u !== -1 ? _.value[u].days.findIndex((D) => (D == null ? void 0 : D.day) === `${e.getFullYear()}-${(e.getMonth() + 1).toString().padStart(2, "0")}-${(v.value.day + 1).toString().padStart(2, "0")}`) : u, le(v.value.failure)), ce();
|
|
104
|
+
}, ve = fe(() => {
|
|
105
|
+
let l = k.value[v.value.ids].days[v.value.day], e = "", r = I.value >= 22 ? N.value + I.value + 2 : N.value + I.value + 1, u = v.value.failure.split("/")[0];
|
|
106
|
+
u = /^Н(?!Н$)С?$/.test(u) ? l.state !== "В" ? "Я" : "РВ" : u, (N.value < 6 || r > 22) && (e = "Н", Y.value = N.value < 6 ? Math.min(6, r) - N.value : 0, r <= 6 && (Y.value = I.value, u = ""), r === 7 && Y.value > 3 && Y.value--, Y.value += Math.max(22, r) - 22), I.value > l.time && u !== "РВ" && (e += "С", L.value = I.value - l.time), e.length > 0 && u.length > 0 && (e = "/" + e);
|
|
107
|
+
let t = typeof (l == null ? void 0 : l.tips) < "u" ? l.tips : `(${N.value}:00 - ${I.value >= 22 ? N.value + I.value + 2 : N.value + I.value + 1}:00)`, a = f.value[v.value.ids * 2].days[v.value.day].time !== "-" ? " " + I.value + " " + t : "";
|
|
108
|
+
return '"' + u + e + '"' + a;
|
|
109
|
+
}), De = (l) => {
|
|
110
|
+
if (l.columnIndex < 2 || l.columnIndex > d.value.length + 3 && l.columnIndex < d.value.length + 9 || l.columnIndex > d.value.length + 11)
|
|
111
|
+
return f.value[l.rowIndex].key === 0 ? {
|
|
112
112
|
rowspan: 2,
|
|
113
113
|
colspan: 1
|
|
114
114
|
} : {
|
|
115
115
|
rowspan: 0,
|
|
116
116
|
colspan: 0
|
|
117
117
|
};
|
|
118
|
-
},
|
|
119
|
-
const
|
|
120
|
-
let
|
|
121
|
-
for (let
|
|
122
|
-
const
|
|
123
|
-
t +=
|
|
124
|
-
let h =
|
|
125
|
-
|
|
118
|
+
}, he = () => {
|
|
119
|
+
const l = re.value, e = new Date(w.value), r = new Date(e.getFullYear(), e.getMonth() + 1, 0).getDate();
|
|
120
|
+
let u = [], t = 0;
|
|
121
|
+
for (let a = 1; a <= r; a++) {
|
|
122
|
+
const o = F(e.setDate(a), "{Y}-{m}-{dd}");
|
|
123
|
+
t += l.nowork.includes(o) || l.holidays.includes(o) ? 0 : l.preholidays.includes(o) ? 7 : 8;
|
|
124
|
+
let h = l.nowork.includes(o) ? "nowork" : l.holidays.includes(o) ? "holiday" : l.preholidays.includes(o) ? "preholiday" : "";
|
|
125
|
+
u.push({ day: a, holidays: h, weekday: Q(new Date(e.getFullYear(), e.getMonth(), a), "day") });
|
|
126
126
|
}
|
|
127
|
-
|
|
128
|
-
var
|
|
129
|
-
E.value = (
|
|
127
|
+
Ce.value = t, d.value = u, S.odata.getPersonal({}).then((a) => {
|
|
128
|
+
var o;
|
|
129
|
+
E.value.length === 0 && (E.value = (o = a.find((h) => h.employeeName === S.fullName)) == null ? void 0 : o.divisionName), a.forEach((h) => {
|
|
130
130
|
ue.value.some((c) => (c == null ? void 0 : c.value) === h.divisionName) || ue.value.push({ value: h.divisionName, label: h.divisionName, key: h.divisionName }), h.divisionName === E.value && !z.value.some((c) => (c == null ? void 0 : c.activeText) === h.roleName) && z.value.push({ val: !0, activeText: h.roleName });
|
|
131
131
|
});
|
|
132
132
|
});
|
|
133
|
-
},
|
|
134
|
-
|
|
135
|
-
if (
|
|
136
|
-
let e = Me(
|
|
137
|
-
G.value.push(
|
|
133
|
+
}, ge = () => {
|
|
134
|
+
k.value = [], G.value = [], oe.value = [], S.odata.personal.forEach((l) => {
|
|
135
|
+
if (l.divisionName === E.value && z.value.some((e) => e.val && e.activeText === l.roleName)) {
|
|
136
|
+
let e = Me(l.employeeName);
|
|
137
|
+
G.value.push(l.employeeKey), k.value.push({ fio: l.employeeName, name: e + " (" + l.roleName + ")", code: l.employeeKey, days: [], contHour: 0, id: !1, ids: k.value.length });
|
|
138
138
|
}
|
|
139
|
-
}), S.workSchedule.getUsersYear({ code: G.value, year: new Date(w.value).getFullYear() }).then((
|
|
140
|
-
|
|
139
|
+
}), S.workSchedule.getUsersYear({ code: G.value, year: new Date(w.value).getFullYear() }).then((l) => {
|
|
140
|
+
l.forEach((e) => {
|
|
141
141
|
e.dateStart && oe.value.push({ code: e.code, dateStart: e.dateStart, dateEnd: e.dateEnd });
|
|
142
|
-
}),
|
|
142
|
+
}), ke();
|
|
143
143
|
});
|
|
144
|
-
},
|
|
145
|
-
S.workSchedule.getWorkSheet({ code: G.value, date:
|
|
146
|
-
(
|
|
147
|
-
|
|
148
|
-
e !== null &&
|
|
149
|
-
})
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
144
|
+
}, ke = () => {
|
|
145
|
+
S.workSchedule.getWorkSheet({ code: G.value, date: F(new Date(w.value), "{Y}-{m}-{dd}") }).then(
|
|
146
|
+
(l) => {
|
|
147
|
+
_.value = [], l.forEach((e) => {
|
|
148
|
+
e !== null && _.value.push({ code: e.code, days: e.data.days });
|
|
149
|
+
}), S.workSchedule.getWorkSchedule({ code: G.value, date: F(new Date(w.value), "{Y}-{m}-{dd}") }).then(
|
|
150
|
+
(e) => {
|
|
151
|
+
e.forEach((r, u) => {
|
|
152
|
+
var t, a;
|
|
153
|
+
if (r !== null) {
|
|
154
|
+
k.value[u].days = [], r.data.days.forEach((o) => o.state = "Я");
|
|
155
|
+
for (let o = 1; o <= d.value.length; o++) {
|
|
156
|
+
let h = F(new Date(w.value).setDate(o), "{Y}-{m}-{dd}");
|
|
157
|
+
const c = (t = r.data) == null ? void 0 : t.days.findIndex((M) => M.day === h);
|
|
158
|
+
c === -1 ? ae(o, u, "-", "В") : k.value[u].days.push((a = r.data) == null ? void 0 : a.days[c]);
|
|
159
|
+
}
|
|
160
|
+
} else
|
|
161
|
+
for (let o = 1; o <= d.value.length; o++)
|
|
162
|
+
d.value[o - 1].holidays === "" ? ae(o, u, 8) : d.value[o - 1].holidays === "preholiday" ? ae(o, u, 7) : ae(o, u, "-", "В");
|
|
163
|
+
for (let o = 1; o <= d.value.length; o++) {
|
|
164
|
+
let h = new Date(new Date(w.value).getFullYear(), new Date(w.value).getMonth(), o).getTime() + 1e3;
|
|
165
|
+
for (let c of oe.value) {
|
|
166
|
+
const { dateStart: M, dateEnd: D, code: U } = c;
|
|
167
|
+
if (M && D && U === k.value[u].code) {
|
|
168
|
+
const H = new Date(pe(M)).getTime(), j = new Date(pe(D)).getTime();
|
|
169
|
+
if (h >= H && h <= j) {
|
|
170
|
+
const n = F(new Date(w.value).setDate(o), "{Y}-{m}-{dd}"), O = k.value[u].days.findIndex((de) => de.day === n);
|
|
171
|
+
O !== -1 ? k.value[u].days[O] = { day: n, time: "-", state: "ОТ" } : k.value[u].days.push({ day: n, time: "-", state: "ОТ" });
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
174
|
}
|
|
175
175
|
}
|
|
176
|
-
}
|
|
176
|
+
}), ce();
|
|
177
177
|
}
|
|
178
|
-
|
|
178
|
+
);
|
|
179
179
|
}
|
|
180
180
|
);
|
|
181
|
-
}, ae = (
|
|
182
|
-
const t =
|
|
183
|
-
|
|
181
|
+
}, ae = (l, e, r, u = "Я") => {
|
|
182
|
+
const t = F(new Date(w.value).setDate(l), "{Y}-{m}-{dd}");
|
|
183
|
+
k.value[e].days.push({
|
|
184
184
|
day: t,
|
|
185
|
-
time:
|
|
186
|
-
state:
|
|
185
|
+
time: r,
|
|
186
|
+
state: u
|
|
187
187
|
});
|
|
188
|
-
},
|
|
189
|
-
f.value.forEach((
|
|
190
|
-
|
|
188
|
+
}, ce = () => {
|
|
189
|
+
f.value.forEach((l) => {
|
|
190
|
+
l.hourI = 0, l.hourII = 0, l.halfII = 0, l.halfI = 0, l.weekend = 0, l.weekendDays = 0, l.overtime = 0, l.night = 0, l.appearing = {
|
|
191
191
|
code: "-",
|
|
192
192
|
count: "-"
|
|
193
193
|
};
|
|
194
194
|
const e = Object.entries(
|
|
195
|
-
|
|
196
|
-
if (
|
|
197
|
-
const h =
|
|
198
|
-
|
|
195
|
+
l.days.reduce((a, o) => {
|
|
196
|
+
if (o.hasOwnProperty("state") && /^(|К|КВ|ОТ|Б|Р|ПР|ОЖ|НН|У|ДО|УД|Г)$/.test(o.state)) {
|
|
197
|
+
const h = o.state;
|
|
198
|
+
a[h] = (a[h] || 0) + 1;
|
|
199
199
|
}
|
|
200
|
-
return
|
|
200
|
+
return a;
|
|
201
201
|
}, {})
|
|
202
|
-
).map(([
|
|
203
|
-
|
|
204
|
-
const
|
|
205
|
-
|
|
206
|
-
code:
|
|
207
|
-
count:
|
|
208
|
-
}),
|
|
209
|
-
code: t.map((
|
|
210
|
-
count: t.map((
|
|
202
|
+
).map(([a, o]) => ({ code: a, count: o }));
|
|
203
|
+
l.numberNonAppearing = [e.reduce((a, o) => a + o.count, 0), 0];
|
|
204
|
+
const r = Math.ceil(e.length / 2), u = e.slice(0, r), t = e.slice(r);
|
|
205
|
+
l.key === 0 && u.length > 0 && (l.appearing = {
|
|
206
|
+
code: u.map((a) => a.code).join("/"),
|
|
207
|
+
count: u.map((a) => a.count).join("/")
|
|
208
|
+
}), l.key === 1 && t.length > 0 && (l.appearing = {
|
|
209
|
+
code: t.map((a) => a.code).join("/"),
|
|
210
|
+
count: t.map((a) => a.count).join("/")
|
|
211
211
|
});
|
|
212
|
-
for (let
|
|
213
|
-
|
|
214
|
-
|
|
212
|
+
for (let a = 0; a < l.days.length; a++)
|
|
213
|
+
a < 15 && l.days[a].time !== "-" && (l.hourI += Number(l.days[a].time), l.days[a].night && (l.hourI += Number(l.days[a].night)), l.days[a].overtime && (l.hourI += Number(l.days[a].overtime)), l.halfI++), a >= 15 && l.days[a].time !== "-" && (l.days[a].night && (l.hourII += Number(l.days[a].night)), l.days[a].overtime && (l.hourII += Number(l.days[a].overtime)), l.hourII += Number(l.days[a].time), l.halfII++), l.days[a].night && (l.night += Number(l.days[a].night)), l.days[a].overtime && (l.overtime += Number(l.days[a].overtime)), /{|РВ|}/.test(l.days[a].state) && (l.weekend += Number(l.days[a].time)), l.days[a].state === "В" && l.weekendDays++;
|
|
214
|
+
l.contDays = l.halfI + l.halfII, l.contHour = l.hourI + l.hourII;
|
|
215
215
|
});
|
|
216
|
-
},
|
|
217
|
-
var h, c,
|
|
216
|
+
}, me = (l, e) => {
|
|
217
|
+
var h, c, M, D, U, H;
|
|
218
218
|
if (e === -1) return "";
|
|
219
|
-
const
|
|
220
|
-
let
|
|
221
|
-
return (h =
|
|
219
|
+
const r = f.value[e], u = new Date(w.value), t = `${u.getFullYear()}-${(u.getMonth() + 1).toString().padStart(2, "0")}-${l.toString().padStart(2, "0")}`, a = r.days.findIndex((j) => j.day === t);
|
|
220
|
+
let o = 0;
|
|
221
|
+
return (h = r.days[a]) != null && h.night && (o += r.days[a].night), (c = r.days[a]) != null && c.overtime && (o += r.days[a].overtime), a === -1 ? "" : r.key === 0 ? (M = r.days[a]) == null ? void 0 : M.state : ((D = r.days[a]) == null ? void 0 : D.time) === 0 ? o === 0 ? "-" : o : o === 0 ? (U = r.days[a]) == null ? void 0 : U.time : `${(H = r.days[a]) == null ? void 0 : H.time}/${o}`;
|
|
222
222
|
};
|
|
223
|
-
S.group && (E.value = S.group), S.date && (K.value = (/* @__PURE__ */ new Date(S.date + "T00:00:01")).getMonth()), _e().then((
|
|
224
|
-
|
|
223
|
+
S.group && (E.value = S.group), S.date && (K.value = (/* @__PURE__ */ new Date(S.date + "T00:00:01")).getMonth()), _e().then((l) => {
|
|
224
|
+
re.value = l, he();
|
|
225
225
|
});
|
|
226
|
-
const
|
|
227
|
-
var
|
|
226
|
+
const ye = (l) => new Date(w.value).getMonth() === (/* @__PURE__ */ new Date()).getMonth() && l === (/* @__PURE__ */ new Date()).getDate() ? " today" : "", $e = async () => {
|
|
227
|
+
var D, U, H, j;
|
|
228
228
|
ee.value = !0;
|
|
229
|
-
const
|
|
230
|
-
e.mergeCells(`A1:${y("A1",
|
|
231
|
-
for (let n = 1; n <=
|
|
232
|
-
e.mergeCells(`${y("D3", n)}3:${y("D4", n)}4`), e.getColumn(n + 3).width = 5, e.getColumn(n + 3).alignment = t, e.getCell(3, n + 3).border =
|
|
233
|
-
e.getCell("A1").value =
|
|
229
|
+
const l = new He.Workbook(), e = l.addWorksheet(Q(w.value, "month"), { pageSetup: { paperSize: 9, orientation: "landscape", fitToPage: !0 } }), r = { vertical: "middle", horizontal: "center" }, u = { top: { style: "thin" }, left: { style: "thin" }, bottom: { style: "thin" }, right: { style: "thin" } }, t = { vertical: "middle", horizontal: "center", wrapText: !0 };
|
|
230
|
+
e.mergeCells(`A1:${y("A1", d.value.length + 15)}1`), e.mergeCells("A2:A4"), e.mergeCells("B2:B4"), e.mergeCells("C2:C4"), e.mergeCells("D5:R5"), e.mergeCells(`D2:${y("D2", d.value.length + 2)}2`), e.mergeCells(`${y("D2", d.value.length + 3)}2:${y("D2", d.value.length + 8)}2`), e.mergeCells(`${y("D2", d.value.length + 9)}2:${y("D2", d.value.length + 9)}4`), e.mergeCells(`${y("D2", d.value.length + 10)}2:${y("D2", d.value.length + 11)}2`), e.mergeCells(`${y("D2", d.value.length + 12)}2:${y("D2", d.value.length + 12)}4`), e.mergeCells(`${y("D3", d.value.length + 3)}3:${y("D3", d.value.length + 3)}4`), e.mergeCells(`${y("D3", d.value.length + 4)}3:${y("D3", d.value.length + 8)}3`), e.mergeCells(`${y("D3", d.value.length + 10)}3:${y("D3", d.value.length + 10)}4`), e.mergeCells(`${y("D3", d.value.length + 11)}3:${y("D3", d.value.length + 11)}4`), e.mergeCells(`T5:${y("D5", d.value.length + 1)}5`);
|
|
231
|
+
for (let n = 1; n <= d.value.length + 2; n++)
|
|
232
|
+
e.mergeCells(`${y("D3", n)}3:${y("D4", n)}4`), e.getColumn(n + 3).width = 5, e.getColumn(n + 3).alignment = t, e.getCell(3, n + 3).border = u, n < 16 && (e.getCell(3, n + 3).value = n), n > 16 && (e.getCell(3, n + 3).value = n - 1);
|
|
233
|
+
e.getCell("A1").value = i("sheet.title", { name: E.value }) + Q(w.value, "month"), e.getCell("A2").value = i("sheet.listNumber"), e.getCell("B2").value = i("sheet.employee"), e.getCell("C2").value = i("sheet.personnelNumber"), e.getCell("D2").value = i("sheet.marks"), e.getCell("S3").value = i("sheet.halfMonth", { half: "I" }), e.getCell("A5").value = "1", e.getCell("B5").value = "2", e.getCell("C5").value = "3", e.getCell("D5").value = "4", e.getCell("S5").value = "5", e.getCell("T5").value = "6", e.getCell(5, d.value.length + 5).value = "7", e.getCell(2, d.value.length + 6).value = i("sheet.workedMonth"), e.getCell(2, d.value.length + 12).value = i("sheet.numberNonAppearing"), e.getCell(2, d.value.length + 13).value = i("sheet.them"), e.getCell(2, d.value.length + 15).value = i("sheet.countWeekend"), e.getCell(3, d.value.length + 5).value = i("sheet.halfMonth", { half: "II" }), e.getCell(3, d.value.length + 6).value = i("sheet.days"), e.getCell(3, d.value.length + 7).value = i("sheet.hours"), e.getCell(4, d.value.length + 7).value = i("sheet.all"), e.getCell(4, d.value.length + 8).value = i("sheet.overtime"), e.getCell(4, d.value.length + 9).value = i("sheet.night"), e.getCell(4, d.value.length + 10).value = i("sheet.weekend"), e.getCell(4, d.value.length + 13).value = i("sheet.code"), e.getCell(4, d.value.length + 14).value = i("sheet.count"), e.getRow(1).height = 40, e.getRow(2).height = 32, e.getRow(3).height = 20, e.getRow(4).height = 60, e.getColumn(1).width = 6, e.getColumn(2).width = 30, e.getColumn(3).width = 17, e.getColumn(19).width = 12, e.getColumn(d.value.length + 5).width = 12, e.getColumn(d.value.length + 12).width = 11, e.getColumn(d.value.length + 15).width = 11, e.getCell("A1").alignment = r, e.getColumn(1).alignment = t, e.getColumn(2).alignment = t, e.getColumn(3).alignment = t;
|
|
234
234
|
for (let n = 6; n <= 15; n++)
|
|
235
|
-
e.getCell(5,
|
|
236
|
-
e.getCell("A2").border =
|
|
237
|
-
let
|
|
235
|
+
e.getCell(5, d.value.length + n).value = n + 2, e.getColumn(d.value.length + n).alignment = t, e.getCell(4, d.value.length + n).border = u, e.getCell(5, d.value.length + n).border = u;
|
|
236
|
+
e.getCell("A2").border = u, e.getCell("B2").border = u, e.getCell("C2").border = u, e.getCell("D2").border = u, e.getCell("D2").border = u, e.getCell("A5").border = u, e.getCell("B5").border = u, e.getCell("C5").border = u, e.getCell("D5").border = u, e.getCell("S5").border = u, e.getCell("T5").border = u, e.getCell(2, d.value.length + 6).border = u, e.getCell(2, d.value.length + 12).border = u, e.getCell(2, d.value.length + 13).border = u, e.getCell(2, d.value.length + 15).border = u, e.getCell(3, d.value.length + 7).border = u;
|
|
237
|
+
let a = 1, o = 5, h = !0;
|
|
238
238
|
for (const n of f.value) {
|
|
239
|
-
let
|
|
240
|
-
for (let T = 0; T <
|
|
241
|
-
T === 15 &&
|
|
242
|
-
|
|
239
|
+
let O = [a, n.name, n.code];
|
|
240
|
+
for (let T = 0; T < d.value.length; T++)
|
|
241
|
+
T === 15 && O.push(h ? (n == null ? void 0 : n.halfI) || "" : (n == null ? void 0 : n.hourI) || ""), O.push(h ? ((D = n.days[T]) == null ? void 0 : D.state) || "" : ((U = n.days[T]) == null ? void 0 : U.time) || "");
|
|
242
|
+
O.push(
|
|
243
243
|
h ? (n == null ? void 0 : n.halfII) || 0 : (n == null ? void 0 : n.hourII) || 0,
|
|
244
244
|
(n == null ? void 0 : n.contDays) || 0,
|
|
245
245
|
(n == null ? void 0 : n.contHour) || 0,
|
|
@@ -248,30 +248,30 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
248
248
|
(n == null ? void 0 : n.weekend) || 0,
|
|
249
249
|
"",
|
|
250
250
|
h ? (n == null ? void 0 : n.numberNonAppearing[0]) || "" : (n == null ? void 0 : n.numberNonAppearing[1]) || 0,
|
|
251
|
-
((
|
|
252
|
-
((
|
|
251
|
+
((H = n == null ? void 0 : n.appearing) == null ? void 0 : H.code) || "-",
|
|
252
|
+
((j = n == null ? void 0 : n.appearing) == null ? void 0 : j.count) || "-",
|
|
253
253
|
(n == null ? void 0 : n.weekendDays) || 0
|
|
254
254
|
);
|
|
255
|
-
const
|
|
256
|
-
if (
|
|
257
|
-
e.mergeCells(`A${
|
|
258
|
-
for (let T =
|
|
259
|
-
e.mergeCells(`${y("D", T)}${
|
|
260
|
-
e.mergeCells(`${y("D",
|
|
255
|
+
const de = e.addRow(O);
|
|
256
|
+
if (de.border = u, !h) {
|
|
257
|
+
e.mergeCells(`A${o + a * 2 - 1}:A${o + a * 2}`), e.mergeCells(`B${o + a * 2 - 1}:B${o + a * 2}`), e.mergeCells(`C${o + a * 2 - 1}:C${o + a * 2}`);
|
|
258
|
+
for (let T = d.value.length + 3; T <= d.value.length + 8; T++)
|
|
259
|
+
e.mergeCells(`${y("D", T)}${o + a * 2 - 1}:${y("D", T)}${o + a * 2}`);
|
|
260
|
+
e.mergeCells(`${y("D", d.value.length + 12)}${o + a * 2 - 1}:${y("D", d.value.length + 12)}${o + a * 2}`), a++;
|
|
261
261
|
}
|
|
262
262
|
h = !h;
|
|
263
263
|
}
|
|
264
264
|
S.odata.personal.forEach((n) => {
|
|
265
265
|
n.roleName === "Начальник отдела правовой и кадровой работы" && n.employeeName;
|
|
266
266
|
});
|
|
267
|
-
const c = "export_" +
|
|
268
|
-
Ue(new Blob([
|
|
267
|
+
const c = "export_" + F(Date.now(), "{dd}.{m}.{Y}") + ".xlsx", M = await l.xlsx.writeBuffer();
|
|
268
|
+
Ue(new Blob([M]), c), ee.value = !1;
|
|
269
269
|
};
|
|
270
|
-
return (
|
|
271
|
-
const
|
|
270
|
+
return (l, e) => {
|
|
271
|
+
const r = xe("el-slider"), u = Ie("loading");
|
|
272
272
|
return $(), R(Z, null, [
|
|
273
273
|
V("div", Oe, [
|
|
274
|
-
ne.checkEdit ? ($(), A(
|
|
274
|
+
ne.checkEdit ? ($(), A(s(Te), {
|
|
275
275
|
key: 0,
|
|
276
276
|
modelValue: E.value,
|
|
277
277
|
"onUpdate:modelValue": e[0] || (e[0] = (t) => E.value = t),
|
|
@@ -279,7 +279,7 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
279
279
|
style: { width: "240px", "margin-bottom": ".5rem", "margin-right": ".5rem" }
|
|
280
280
|
}, {
|
|
281
281
|
default: g(() => [
|
|
282
|
-
($(!0), R(Z, null,
|
|
282
|
+
($(!0), R(Z, null, ie(ue.value, (t) => ($(), A(s(Ae), {
|
|
283
283
|
key: t.value,
|
|
284
284
|
label: t.label,
|
|
285
285
|
value: t.value
|
|
@@ -288,36 +288,36 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
288
288
|
_: 1
|
|
289
289
|
}, 8, ["modelValue"])) : B("", !0),
|
|
290
290
|
e[9] || (e[9] = V("div", { class: "expander" }, null, -1)),
|
|
291
|
-
ne.checkEdit ? ($(), A(
|
|
291
|
+
ne.checkEdit ? ($(), A(s(Ye), {
|
|
292
292
|
key: 1,
|
|
293
293
|
modelValue: K.value,
|
|
294
294
|
"onUpdate:modelValue": e[1] || (e[1] = (t) => K.value = t),
|
|
295
|
-
"active-text":
|
|
295
|
+
"active-text": s(i)("workSchedule.currentMonth"),
|
|
296
296
|
"active-value": "0",
|
|
297
297
|
"inactive-value": "-1",
|
|
298
298
|
style: { "margin-bottom": ".5rem", "margin-left": ".5rem" }
|
|
299
299
|
}, null, 8, ["modelValue", "active-text"])) : B("", !0)
|
|
300
300
|
]),
|
|
301
|
-
m(
|
|
301
|
+
m(s(Ve), {
|
|
302
302
|
id: "printTable",
|
|
303
303
|
data: f.value,
|
|
304
|
-
"span-method":
|
|
304
|
+
"span-method": De,
|
|
305
305
|
border: "",
|
|
306
306
|
style: { width: "100%" },
|
|
307
307
|
size: "small",
|
|
308
|
-
"empty-text":
|
|
308
|
+
"empty-text": s(i)("sheet.emptyText"),
|
|
309
309
|
align: "center",
|
|
310
|
-
onCellClick:
|
|
310
|
+
onCellClick: we
|
|
311
311
|
}, {
|
|
312
312
|
default: g(() => [
|
|
313
|
-
m(
|
|
314
|
-
label:
|
|
313
|
+
m(s(C), {
|
|
314
|
+
label: s(i)("sheet.title", { name: E.value }) + s(Q)(w.value, "month"),
|
|
315
315
|
align: "center",
|
|
316
316
|
height: "10"
|
|
317
317
|
}, {
|
|
318
318
|
default: g(() => [
|
|
319
|
-
m(
|
|
320
|
-
label:
|
|
319
|
+
m(s(C), {
|
|
320
|
+
label: s(i)("sheet.employee"),
|
|
321
321
|
width: "180",
|
|
322
322
|
align: "center"
|
|
323
323
|
}, {
|
|
@@ -326,8 +326,8 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
326
326
|
]),
|
|
327
327
|
_: 1
|
|
328
328
|
}, 8, ["label"]),
|
|
329
|
-
m(
|
|
330
|
-
label:
|
|
329
|
+
m(s(C), {
|
|
330
|
+
label: s(i)("sheet.personnelNumber"),
|
|
331
331
|
align: "center"
|
|
332
332
|
}, {
|
|
333
333
|
default: g((t) => [
|
|
@@ -335,53 +335,53 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
335
335
|
]),
|
|
336
336
|
_: 1
|
|
337
337
|
}, 8, ["label"]),
|
|
338
|
-
m(
|
|
339
|
-
label:
|
|
338
|
+
m(s(C), {
|
|
339
|
+
label: s(i)("sheet.marks"),
|
|
340
340
|
align: "center"
|
|
341
341
|
}, {
|
|
342
342
|
default: g(() => [
|
|
343
|
-
($(!0), R(Z, null,
|
|
343
|
+
($(!0), R(Z, null, ie(d.value, (t) => ($(), R(Z, {
|
|
344
344
|
key: t.day
|
|
345
345
|
}, [
|
|
346
|
-
t.day <= 15 ? ($(), A(
|
|
346
|
+
t.day <= 15 ? ($(), A(s(C), {
|
|
347
347
|
key: 0,
|
|
348
348
|
width: "30",
|
|
349
|
-
"class-name": t.holidays +
|
|
349
|
+
"class-name": t.holidays + ye(t.day),
|
|
350
350
|
align: "center",
|
|
351
351
|
label: t.day.toString() + `
|
|
352
352
|
` + t.weekday
|
|
353
353
|
}, {
|
|
354
|
-
default: g((
|
|
355
|
-
V("div", Re, b(
|
|
354
|
+
default: g((a) => [
|
|
355
|
+
V("div", Re, b(me(t.day, a.$index) || " "), 1)
|
|
356
356
|
]),
|
|
357
357
|
_: 2
|
|
358
358
|
}, 1032, ["class-name", "label"])) : B("", !0),
|
|
359
|
-
t.day === 15 ? ($(), A(
|
|
359
|
+
t.day === 15 ? ($(), A(s(C), {
|
|
360
360
|
key: 1,
|
|
361
|
-
label:
|
|
361
|
+
label: s(i)("sheet.halfMonth", { half: "I" }),
|
|
362
362
|
align: "center"
|
|
363
363
|
}, {
|
|
364
|
-
default: g((
|
|
365
|
-
x(b(f.value[
|
|
364
|
+
default: g((a) => [
|
|
365
|
+
x(b(f.value[a.$index].key === 0 ? f.value[a.$index].halfI : f.value[a.$index].hourI), 1)
|
|
366
366
|
]),
|
|
367
367
|
_: 1
|
|
368
368
|
}, 8, ["label"])) : B("", !0),
|
|
369
|
-
t.day > 15 ? ($(), A(
|
|
369
|
+
t.day > 15 ? ($(), A(s(C), {
|
|
370
370
|
key: 2,
|
|
371
371
|
width: "30",
|
|
372
|
-
"class-name": t.holidays +
|
|
372
|
+
"class-name": t.holidays + ye(t.day),
|
|
373
373
|
align: "center",
|
|
374
374
|
label: t.day.toString() + `
|
|
375
375
|
` + t.weekday
|
|
376
376
|
}, {
|
|
377
|
-
default: g((
|
|
378
|
-
V("div", ze, b(
|
|
377
|
+
default: g((a) => [
|
|
378
|
+
V("div", ze, b(me(t.day, a.$index) || " "), 1)
|
|
379
379
|
]),
|
|
380
380
|
_: 2
|
|
381
381
|
}, 1032, ["class-name", "label"])) : B("", !0)
|
|
382
382
|
], 64))), 128)),
|
|
383
|
-
m(
|
|
384
|
-
label:
|
|
383
|
+
m(s(C), {
|
|
384
|
+
label: s(i)("sheet.halfMonth", { half: "II" }),
|
|
385
385
|
align: "center"
|
|
386
386
|
}, {
|
|
387
387
|
default: g((t) => [
|
|
@@ -392,13 +392,13 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
392
392
|
]),
|
|
393
393
|
_: 1
|
|
394
394
|
}, 8, ["label"]),
|
|
395
|
-
m(
|
|
396
|
-
label:
|
|
395
|
+
m(s(C), {
|
|
396
|
+
label: s(i)("sheet.workedMonth"),
|
|
397
397
|
align: "center"
|
|
398
398
|
}, {
|
|
399
399
|
default: g(() => [
|
|
400
|
-
m(
|
|
401
|
-
label:
|
|
400
|
+
m(s(C), {
|
|
401
|
+
label: s(i)("sheet.days"),
|
|
402
402
|
align: "center",
|
|
403
403
|
"label-class-name": "turn",
|
|
404
404
|
width: "34"
|
|
@@ -408,13 +408,13 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
408
408
|
]),
|
|
409
409
|
_: 1
|
|
410
410
|
}, 8, ["label"]),
|
|
411
|
-
m(
|
|
412
|
-
label:
|
|
411
|
+
m(s(C), {
|
|
412
|
+
label: s(i)("sheet.hours"),
|
|
413
413
|
align: "center"
|
|
414
414
|
}, {
|
|
415
415
|
default: g(() => [
|
|
416
|
-
m(
|
|
417
|
-
label:
|
|
416
|
+
m(s(C), {
|
|
417
|
+
label: s(i)("sheet.all"),
|
|
418
418
|
align: "center",
|
|
419
419
|
"label-class-name": "turn",
|
|
420
420
|
width: "40"
|
|
@@ -424,8 +424,8 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
424
424
|
]),
|
|
425
425
|
_: 1
|
|
426
426
|
}, 8, ["label"]),
|
|
427
|
-
m(
|
|
428
|
-
label:
|
|
427
|
+
m(s(C), {
|
|
428
|
+
label: s(i)("sheet.overtime"),
|
|
429
429
|
align: "center",
|
|
430
430
|
"label-class-name": "turn",
|
|
431
431
|
width: "34"
|
|
@@ -435,8 +435,8 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
435
435
|
]),
|
|
436
436
|
_: 1
|
|
437
437
|
}, 8, ["label"]),
|
|
438
|
-
m(
|
|
439
|
-
label:
|
|
438
|
+
m(s(C), {
|
|
439
|
+
label: s(i)("sheet.night"),
|
|
440
440
|
align: "center",
|
|
441
441
|
"label-class-name": "turn",
|
|
442
442
|
width: "34"
|
|
@@ -446,8 +446,8 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
446
446
|
]),
|
|
447
447
|
_: 1
|
|
448
448
|
}, 8, ["label"]),
|
|
449
|
-
m(
|
|
450
|
-
label:
|
|
449
|
+
m(s(C), {
|
|
450
|
+
label: s(i)("sheet.weekend"),
|
|
451
451
|
align: "center",
|
|
452
452
|
"label-class-name": "turn",
|
|
453
453
|
width: "34"
|
|
@@ -463,47 +463,47 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
463
463
|
]),
|
|
464
464
|
_: 1
|
|
465
465
|
}, 8, ["label"]),
|
|
466
|
-
m(
|
|
467
|
-
label:
|
|
466
|
+
m(s(C), {
|
|
467
|
+
label: s(i)("sheet.numberNonAppearing"),
|
|
468
468
|
align: "center"
|
|
469
469
|
}, {
|
|
470
470
|
default: g((t) => {
|
|
471
|
-
var
|
|
471
|
+
var a;
|
|
472
472
|
return [
|
|
473
|
-
x(b((
|
|
473
|
+
x(b((a = f.value[t.$index]) == null ? void 0 : a.numberNonAppearing[f.value[t.$index].key]), 1)
|
|
474
474
|
];
|
|
475
475
|
}),
|
|
476
476
|
_: 1
|
|
477
477
|
}, 8, ["label"]),
|
|
478
|
-
m(
|
|
479
|
-
label:
|
|
478
|
+
m(s(C), {
|
|
479
|
+
label: s(i)("sheet.them"),
|
|
480
480
|
align: "center"
|
|
481
481
|
}, {
|
|
482
482
|
default: g(() => [
|
|
483
|
-
m(
|
|
484
|
-
label:
|
|
483
|
+
m(s(C), {
|
|
484
|
+
label: s(i)("sheet.code"),
|
|
485
485
|
align: "center",
|
|
486
486
|
"label-class-name": "turn",
|
|
487
487
|
width: "30"
|
|
488
488
|
}, {
|
|
489
489
|
default: g((t) => {
|
|
490
|
-
var
|
|
490
|
+
var a;
|
|
491
491
|
return [
|
|
492
|
-
x(b((
|
|
492
|
+
x(b((a = f.value[t.$index].appearing) == null ? void 0 : a.code), 1)
|
|
493
493
|
];
|
|
494
494
|
}),
|
|
495
495
|
_: 1
|
|
496
496
|
}, 8, ["label"]),
|
|
497
|
-
m(
|
|
498
|
-
label:
|
|
497
|
+
m(s(C), {
|
|
498
|
+
label: s(i)("sheet.count"),
|
|
499
499
|
align: "center",
|
|
500
500
|
"label-class-name": "turn",
|
|
501
501
|
width: "30"
|
|
502
502
|
}, {
|
|
503
503
|
default: g((t) => {
|
|
504
|
-
var
|
|
504
|
+
var a;
|
|
505
505
|
return [
|
|
506
|
-
x(b((
|
|
506
|
+
x(b((a = f.value[t.$index].appearing) == null ? void 0 : a.count), 1)
|
|
507
507
|
];
|
|
508
508
|
}),
|
|
509
509
|
_: 1
|
|
@@ -511,8 +511,8 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
511
511
|
]),
|
|
512
512
|
_: 1
|
|
513
513
|
}, 8, ["label"]),
|
|
514
|
-
m(
|
|
515
|
-
label:
|
|
514
|
+
m(s(C), {
|
|
515
|
+
label: s(i)("sheet.countWeekend"),
|
|
516
516
|
align: "center"
|
|
517
517
|
}, {
|
|
518
518
|
default: g((t) => [
|
|
@@ -526,41 +526,41 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
526
526
|
]),
|
|
527
527
|
_: 1
|
|
528
528
|
}, 8, ["data", "empty-text"]),
|
|
529
|
-
Se(($(), A(
|
|
529
|
+
Se(($(), A(s(te), {
|
|
530
530
|
disabled: ee.value,
|
|
531
531
|
plain: "",
|
|
532
|
-
onClick:
|
|
532
|
+
onClick: $e,
|
|
533
533
|
style: { "margin-top": ".5rem" }
|
|
534
534
|
}, {
|
|
535
535
|
default: g(() => [
|
|
536
|
-
x(b(
|
|
536
|
+
x(b(s(i)("workSchedule.exportExcel")), 1)
|
|
537
537
|
]),
|
|
538
538
|
_: 1
|
|
539
539
|
}, 8, ["disabled"])), [
|
|
540
|
-
[
|
|
540
|
+
[u, ee.value]
|
|
541
541
|
]),
|
|
542
|
-
m(
|
|
543
|
-
show:
|
|
544
|
-
"onUpdate:show": e[8] || (e[8] = (t) =>
|
|
542
|
+
m(s(Be), {
|
|
543
|
+
show: W.value,
|
|
544
|
+
"onUpdate:show": e[8] || (e[8] = (t) => W.value = t),
|
|
545
545
|
options: se.value
|
|
546
546
|
}, {
|
|
547
547
|
default: g(() => [
|
|
548
|
-
m(
|
|
548
|
+
m(s(J), {
|
|
549
549
|
label: v.value.name,
|
|
550
550
|
disabled: ""
|
|
551
551
|
}, null, 8, ["label"]),
|
|
552
|
-
m(
|
|
552
|
+
m(s(Fe)),
|
|
553
553
|
V("div", null, [
|
|
554
554
|
V("div", null, [
|
|
555
|
-
m(
|
|
556
|
-
label:
|
|
555
|
+
m(s(We), {
|
|
556
|
+
label: ve.value,
|
|
557
557
|
style: { padding: "0 0 .5rem" }
|
|
558
558
|
}, {
|
|
559
559
|
default: g(() => [
|
|
560
|
-
($(!0), R(Z, null,
|
|
560
|
+
($(!0), R(Z, null, ie(be.value, (t) => ($(), A(s(J), {
|
|
561
561
|
key: t.value,
|
|
562
562
|
label: t.label,
|
|
563
|
-
onClick: (
|
|
563
|
+
onClick: (a) => le(t.value),
|
|
564
564
|
clickClose: !1
|
|
565
565
|
}, null, 8, ["label", "onClick"]))), 128))
|
|
566
566
|
]),
|
|
@@ -568,13 +568,13 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
568
568
|
}, 8, ["label"])
|
|
569
569
|
]),
|
|
570
570
|
/^(РВ|Я|Н(?![Н])).*$/.test(v.value.failure) ? ($(), R("div", Pe, [
|
|
571
|
-
m(
|
|
571
|
+
m(s(J), { clickClose: !1 }, {
|
|
572
572
|
default: g(() => [
|
|
573
|
-
V("span", null, b(
|
|
573
|
+
V("span", null, b(s(i)("workSchedule.with")) + ":", 1)
|
|
574
574
|
]),
|
|
575
575
|
_: 1
|
|
576
576
|
}),
|
|
577
|
-
m(
|
|
577
|
+
m(r, {
|
|
578
578
|
modelValue: N.value,
|
|
579
579
|
"onUpdate:modelValue": e[2] || (e[2] = (t) => N.value = t),
|
|
580
580
|
step: 1,
|
|
@@ -582,61 +582,61 @@ const Oe = { class: "nav" }, Re = { style: { height: "20px", width: "100%", disp
|
|
|
582
582
|
max: 19,
|
|
583
583
|
style: { width: "100%" }
|
|
584
584
|
}, null, 8, ["modelValue"]),
|
|
585
|
-
m(
|
|
585
|
+
m(s(J), { clickClose: !1 }, {
|
|
586
586
|
default: g(() => [
|
|
587
|
-
V("span", null, b(
|
|
587
|
+
V("span", null, b(s(i)("workSchedule.duration")) + ":", 1)
|
|
588
588
|
]),
|
|
589
589
|
_: 1
|
|
590
590
|
}),
|
|
591
|
-
m(
|
|
591
|
+
m(r, {
|
|
592
592
|
modelValue: I.value,
|
|
593
593
|
"onUpdate:modelValue": e[3] || (e[3] = (t) => I.value = t),
|
|
594
594
|
step: 1,
|
|
595
595
|
min: 4,
|
|
596
|
-
max:
|
|
596
|
+
max: s(Ee)(N.value !== 1 ? 23 - N.value : 21, 4, 22)
|
|
597
597
|
}, null, 8, ["modelValue", "max"])
|
|
598
598
|
])) : B("", !0),
|
|
599
599
|
/^(|К|КВ|ОТ|Б|Р|ОЖ|У|ДО|УД|Г)$/.test(v.value.failure) ? ($(), R("div", je, [
|
|
600
|
-
m(
|
|
600
|
+
m(s(J), { clickClose: !1 }, {
|
|
601
601
|
default: g(() => [
|
|
602
|
-
V("span", null, b(
|
|
602
|
+
V("span", null, b(s(i)("sheet.count")) + ":", 1)
|
|
603
603
|
]),
|
|
604
604
|
_: 1
|
|
605
605
|
}),
|
|
606
|
-
m(
|
|
606
|
+
m(r, {
|
|
607
607
|
modelValue: X.value,
|
|
608
608
|
"onUpdate:modelValue": e[4] || (e[4] = (t) => X.value = t),
|
|
609
609
|
step: 1,
|
|
610
610
|
min: 1,
|
|
611
|
-
max:
|
|
611
|
+
max: d.value.length - v.value.day,
|
|
612
612
|
style: { width: "100%" }
|
|
613
613
|
}, null, 8, ["modelValue", "max"])
|
|
614
614
|
])) : B("", !0),
|
|
615
|
-
m(
|
|
615
|
+
m(s(J), null, {
|
|
616
616
|
default: g(() => [
|
|
617
|
-
v.value.rest ? ($(), A(
|
|
617
|
+
v.value.rest ? ($(), A(s(te), {
|
|
618
618
|
key: 0,
|
|
619
619
|
onClick: e[5] || (e[5] = (t) => le("reset"))
|
|
620
620
|
}, {
|
|
621
621
|
default: g(() => [
|
|
622
|
-
x(b(
|
|
622
|
+
x(b(s(i)("sheet.reset")), 1)
|
|
623
623
|
]),
|
|
624
624
|
_: 1
|
|
625
625
|
})) : B("", !0),
|
|
626
|
-
P.value ? ($(), A(
|
|
626
|
+
P.value ? ($(), A(s(te), {
|
|
627
627
|
key: 1,
|
|
628
628
|
onClick: e[6] || (e[6] = (t) => le("save"))
|
|
629
629
|
}, {
|
|
630
630
|
default: g(() => [
|
|
631
|
-
x(b(
|
|
631
|
+
x(b(s(i)("sheet.save")), 1)
|
|
632
632
|
]),
|
|
633
633
|
_: 1
|
|
634
634
|
})) : B("", !0),
|
|
635
|
-
m(
|
|
636
|
-
onClick: e[7] || (e[7] = (t) =>
|
|
635
|
+
m(s(te), {
|
|
636
|
+
onClick: e[7] || (e[7] = (t) => W.value = !1)
|
|
637
637
|
}, {
|
|
638
638
|
default: g(() => [
|
|
639
|
-
x(b(
|
|
639
|
+
x(b(s(i)("sheet.cancel")), 1)
|
|
640
640
|
]),
|
|
641
641
|
_: 1
|
|
642
642
|
})
|