@opengis/admin 0.2.61 → 0.2.63
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/{add-page-7lwkpclk.js → add-page-B-HdoM-b.js} +1 -1
- package/dist/{admin-interface-CI6dXY6S.js → admin-interface-CB_IDKZ4.js} +354 -350
- package/dist/admin-view-Dho_oQDM.js +650 -0
- package/dist/admin.js +2 -2
- package/dist/admin.umd.cjs +113 -29268
- package/dist/{card-view-Dpi1KUgZ.js → card-view-nRpGn7Eh.js} +1 -1
- package/dist/{edit-page-3A9esUlY.js → edit-page-CL1s0lQK.js} +1 -1
- package/dist/{import-file-BNV8_q-Q.js → import-file-D3jqKElS.js} +3754 -3698
- package/dist/style.css +1 -1
- package/package.json +3 -2
- package/plugin.js +2 -2
- package/server/routes/menu/controllers/getMenu.js +2 -1
- package/server/routes/print/controllers/cardPrint.js +108 -0
- package/server/routes/print/index.mjs +5 -0
- package/server/routes/widget/controllers/widget.del.js +12 -6
- package/server/routes/widget/controllers/widget.get.js +32 -30
- package/server/templates/pt/card-print.pt.hbs +15 -0
- package/dist/admin-view-DLchstfQ.js +0 -58998
@@ -1,6 +1,6 @@
|
|
1
|
-
import { _ as
|
2
|
-
import { openBlock as
|
3
|
-
const
|
1
|
+
import { _ as C, f as qe, g as Be, h as Oe, e as F, I as Ne, i as Ve, j as N, A as U, V as Ue, k as Ee, l as He, m as Re, n as We, o as Je, a as Ge, u as Se, s as Ke } from "./import-file-D3jqKElS.js";
|
2
|
+
import { openBlock as r, createElementBlock as i, createTextVNode as j, toDisplayString as A, createElementVNode as l, normalizeClass as I, createCommentVNode as v, resolveComponent as p, Fragment as T, createVNode as x, withCtx as S, createBlock as k, renderList as V, withModifiers as Qe, createStaticVNode as Xe, withDirectives as M, vModelCheckbox as Ye, Transition as L, vModelText as Ze, renderSlot as et, vShow as E, Teleport as tt, getCurrentInstance as De, ref as B, resolveDynamicComponent as O, defineComponent as st, normalizeStyle as Ie } from "vue";
|
3
|
+
const nt = {
|
4
4
|
data() {
|
5
5
|
return {
|
6
6
|
currentSort: ""
|
@@ -58,24 +58,24 @@ const st = {
|
|
58
58
|
return `${this.data.name}-${t}` === this.selectedSortParam;
|
59
59
|
}
|
60
60
|
}
|
61
|
-
},
|
61
|
+
}, lt = {
|
62
62
|
scope: "col",
|
63
63
|
class: "pe-2 py-1 text-start"
|
64
|
-
},
|
64
|
+
}, rt = { class: "w-[24px]" }, ot = {
|
65
65
|
key: 1,
|
66
66
|
class: "flex items-center px-1 py-3 font-medium text-gray-800 text-start gap-x-1 dark:text-neutral-200"
|
67
67
|
};
|
68
|
-
function
|
69
|
-
return
|
70
|
-
|
68
|
+
function at(t, e, s, a, n, o) {
|
69
|
+
return r(), i("th", lt, [
|
70
|
+
o.getVisibleIcon ? (r(), i("button", {
|
71
71
|
key: 0,
|
72
72
|
type: "button",
|
73
73
|
class: "flex items-center px-1 py-3 font-medium text-gray-800 text-start gap-x-1 dark:text-neutral-200",
|
74
|
-
onClick: e[0] || (e[0] = (d) =>
|
74
|
+
onClick: e[0] || (e[0] = (d) => o.handleClickSortBtn(n.currentSort))
|
75
75
|
}, [
|
76
|
-
j(A(
|
77
|
-
l("span",
|
78
|
-
n.currentSort ? (
|
76
|
+
j(A(o.label) + " ", 1),
|
77
|
+
l("span", rt, [
|
78
|
+
n.currentSort ? (r(), i("svg", {
|
79
79
|
key: 0,
|
80
80
|
class: I(["shrink-0 size-3.5", { "rotate-180": n.currentSort === "asc" }]),
|
81
81
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -92,10 +92,10 @@ function rt(t, e, s, a, n, r) {
|
|
92
92
|
l("path", { d: "M12 19V5" }, null, -1)
|
93
93
|
]), 2)) : v("", !0)
|
94
94
|
])
|
95
|
-
])) : (
|
95
|
+
])) : (r(), i("p", ot, A(o.label), 1))
|
96
96
|
]);
|
97
97
|
}
|
98
|
-
const
|
98
|
+
const it = /* @__PURE__ */ C(nt, [["render", at]]), ut = {
|
99
99
|
components: {
|
100
100
|
IconMore: qe,
|
101
101
|
IconDelete: Be,
|
@@ -178,20 +178,20 @@ const at = /* @__PURE__ */ w(st, [["render", rt]]), it = {
|
|
178
178
|
});
|
179
179
|
}
|
180
180
|
}
|
181
|
-
},
|
181
|
+
}, dt = { class: "inline-flex" }, ct = { class: "inline-flex items-center justify-center bg-white border rounded-lg shadow-sm size-7 gap-x-2 border-stone-200 text-stone-800 hover:bg-stone-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-stone-50" }, pt = { class: "flex flex-col items-start" }, ht = ["onClick"], bt = { class: "text-gray-800" }, ft = {
|
182
182
|
key: 1,
|
183
183
|
class: "h-[1px] w-[80%] bg-gray-200 ml-auto mr-auto"
|
184
|
-
},
|
185
|
-
function mt(t, e, s, a, n,
|
184
|
+
}, gt = { class: "flex justify-end p-[16px] pr-0 gap-x-3" };
|
185
|
+
function mt(t, e, s, a, n, o) {
|
186
186
|
const d = p("IconMore"), f = p("IconEdit"), h = p("router-link"), b = p("IconDelete"), u = p("VsPopover"), _ = p("VsConfirm");
|
187
|
-
return
|
188
|
-
l("div",
|
187
|
+
return r(), i(T, null, [
|
188
|
+
l("div", dt, [
|
189
189
|
x(u, {
|
190
190
|
trigger: "click",
|
191
191
|
placement: "bottom-left"
|
192
192
|
}, {
|
193
193
|
reference: S(() => [
|
194
|
-
l("button",
|
194
|
+
l("button", ct, [
|
195
195
|
x(d, {
|
196
196
|
height: "16",
|
197
197
|
width: "16"
|
@@ -199,12 +199,12 @@ function mt(t, e, s, a, n, r) {
|
|
199
199
|
])
|
200
200
|
]),
|
201
201
|
default: S(() => {
|
202
|
-
var
|
202
|
+
var m, g, w, y, $;
|
203
203
|
return [
|
204
|
-
l("div",
|
205
|
-
(
|
204
|
+
l("div", pt, [
|
205
|
+
(m = s.actions) != null && m.includes("edit") && s.isForm ? (r(), k(h, {
|
206
206
|
key: 0,
|
207
|
-
to: `/edit?table=${(
|
207
|
+
to: `/edit?table=${(w = (g = t.$route) == null ? void 0 : g.params) == null ? void 0 : w.catchAll}&id=${(y = s.item) == null ? void 0 : y.id}`,
|
208
208
|
class: "w-full flex items-center gap-x-3 py-1.5 px-2 rounded-lg text-[13px] text-stone-800 hover:bg-stone-100 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-stone-100"
|
209
209
|
}, {
|
210
210
|
default: S(() => [
|
@@ -213,18 +213,18 @@ function mt(t, e, s, a, n, r) {
|
|
213
213
|
]),
|
214
214
|
_: 1
|
215
215
|
}, 8, ["to"])) : v("", !0),
|
216
|
-
(
|
216
|
+
(r(!0), i(T, null, V(o.getCustomActions, (D, z) => (r(), i("button", {
|
217
217
|
key: z,
|
218
|
-
onClick: (q) =>
|
218
|
+
onClick: (q) => o.customButtonAction(D),
|
219
219
|
class: "w-full flex items-center gap-x-3 py-1.5 px-2 rounded-lg text-[13px] text-stone-800 hover:bg-stone-100 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-stone-100"
|
220
220
|
}, [
|
221
221
|
x(b, { class: "opacity-0" }),
|
222
|
-
l("span",
|
223
|
-
], 8,
|
224
|
-
s.isForm ? (
|
225
|
-
($ = s.actions) != null && $.includes("del") ? (
|
222
|
+
l("span", bt, A(D == null ? void 0 : D.label), 1)
|
223
|
+
], 8, ht))), 128)),
|
224
|
+
s.isForm ? (r(), i("div", ft)) : v("", !0),
|
225
|
+
($ = s.actions) != null && $.includes("del") ? (r(), i("button", {
|
226
226
|
key: 2,
|
227
|
-
onClick: e[0] || (e[0] = Qe((...D) =>
|
227
|
+
onClick: e[0] || (e[0] = Qe((...D) => o.openConfirm && o.openConfirm(...D), ["stop"])),
|
228
228
|
class: "w-full flex items-center gap-x-3 py-1.5 px-2 rounded-lg text-[13px] text-stone-800 hover:bg-stone-100 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-stone-100"
|
229
229
|
}, [
|
230
230
|
x(b),
|
@@ -238,22 +238,22 @@ function mt(t, e, s, a, n, r) {
|
|
238
238
|
]),
|
239
239
|
x(_, {
|
240
240
|
visible: n.isDeleteConfirm,
|
241
|
-
"onUpdate:visible": e[3] || (e[3] = (
|
241
|
+
"onUpdate:visible": e[3] || (e[3] = (m) => n.isDeleteConfirm = m),
|
242
242
|
size: "small",
|
243
243
|
title: "Ви впевнені?"
|
244
244
|
}, {
|
245
245
|
default: S(() => [
|
246
246
|
e[6] || (e[6] = l("p", { class: "mt-1 text-sm text-gray-600 dark:text-neutral-400" }, " Ви впевнені, що хочете видалити цей об'єкт? ", -1)),
|
247
|
-
l("div",
|
247
|
+
l("div", gt, [
|
248
248
|
l("button", {
|
249
249
|
type: "button",
|
250
250
|
class: "inline-flex items-center px-3 py-2 text-xs font-medium duration-300 border rounded-lg shadow-sm hover:bg-gray-100 gap-x-2 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-50",
|
251
|
-
onClick: e[1] || (e[1] = (
|
251
|
+
onClick: e[1] || (e[1] = (m) => n.isDeleteConfirm = !1)
|
252
252
|
}, " Скасувати "),
|
253
253
|
l("button", {
|
254
254
|
type: "button",
|
255
255
|
class: "inline-flex items-center px-3 py-2 text-xs font-medium text-white duration-300 bg-red-500 rounded-lg gap-x-2 hover:bg-red-700 disabled:opacity-50 disabled:pointer-events-none",
|
256
|
-
onClick: e[2] || (e[2] = (...
|
256
|
+
onClick: e[2] || (e[2] = (...m) => o.deleteElement && o.deleteElement(...m))
|
257
257
|
}, " Так, я впевнена(ий) ")
|
258
258
|
])
|
259
259
|
]),
|
@@ -261,7 +261,7 @@ function mt(t, e, s, a, n, r) {
|
|
261
261
|
}, 8, ["visible"])
|
262
262
|
], 64);
|
263
263
|
}
|
264
|
-
const
|
264
|
+
const xt = /* @__PURE__ */ C(ut, [["render", mt]]), yt = {}, kt = {
|
265
265
|
class: "flex-shrink-0 mt-0.5 size-3.5",
|
266
266
|
xmlns: "http://www.w3.org/2000/svg",
|
267
267
|
viewBox: "0 0 24 24",
|
@@ -271,15 +271,15 @@ const gt = /* @__PURE__ */ w(it, [["render", mt]]), xt = {}, yt = {
|
|
271
271
|
"stroke-linecap": "round",
|
272
272
|
"stroke-linejoin": "round"
|
273
273
|
};
|
274
|
-
function
|
275
|
-
return
|
274
|
+
function vt(t, e, s, a, n, o) {
|
275
|
+
return r(), i("svg", kt, e[0] || (e[0] = [
|
276
276
|
l("path", { d: "m3 16 4 4 4-4" }, null, -1),
|
277
277
|
l("path", { d: "M7 20V4" }, null, -1),
|
278
278
|
l("path", { d: "m21 8-4-4-4 4" }, null, -1),
|
279
279
|
l("path", { d: "M17 4v16" }, null, -1)
|
280
280
|
]));
|
281
281
|
}
|
282
|
-
const
|
282
|
+
const _t = /* @__PURE__ */ C(yt, [["render", vt]]), wt = {}, Ct = {
|
283
283
|
xmlns: "http://www.w3.org/2000/svg",
|
284
284
|
width: "24",
|
285
285
|
height: "24",
|
@@ -291,8 +291,8 @@ const vt = /* @__PURE__ */ w(xt, [["render", kt]]), _t = {}, Ct = {
|
|
291
291
|
"stroke-linejoin": "round",
|
292
292
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-rosette-discount-check"
|
293
293
|
};
|
294
|
-
function
|
295
|
-
return
|
294
|
+
function $t(t, e, s, a, n, o) {
|
295
|
+
return r(), i("svg", Ct, e[0] || (e[0] = [
|
296
296
|
l("path", {
|
297
297
|
stroke: "none",
|
298
298
|
d: "M0 0h24v24H0z",
|
@@ -302,8 +302,8 @@ function wt(t, e, s, a, n, r) {
|
|
302
302
|
l("path", { d: "M9 12l2 2l4 -4" }, null, -1)
|
303
303
|
]));
|
304
304
|
}
|
305
|
-
const
|
306
|
-
components: { IconExport:
|
305
|
+
const At = /* @__PURE__ */ C(wt, [["render", $t]]), Tt = {
|
306
|
+
components: { IconExport: _t, IconChevronDown: Ne, IconSuccess: At },
|
307
307
|
props: {
|
308
308
|
table: String,
|
309
309
|
columns: Array,
|
@@ -369,15 +369,15 @@ const $t = /* @__PURE__ */ w(_t, [["render", wt]]), At = {
|
|
369
369
|
responseType: "blob"
|
370
370
|
}), s = await e.data.text(), a = s != null && s.includes(";") ? null : JSON == null ? void 0 : JSON.parse(s), n = new Blob([e.data], {
|
371
371
|
type: "application/octet-stream"
|
372
|
-
}),
|
373
|
-
if (d.href =
|
372
|
+
}), o = window.URL.createObjectURL(n), d = document.createElement("a");
|
373
|
+
if (d.href = o, d.setAttribute(
|
374
374
|
"download",
|
375
375
|
`${this.table.split(".")[0]}.${this.format}`
|
376
376
|
), document.body.appendChild(d), typeof a == "string") {
|
377
377
|
this.exportTable();
|
378
378
|
return;
|
379
379
|
}
|
380
|
-
d.click(), document.body.removeChild(d), window.URL.revokeObjectURL(
|
380
|
+
d.click(), document.body.removeChild(d), window.URL.revokeObjectURL(o), this.$notify({
|
381
381
|
type: "success",
|
382
382
|
title: "Експорт",
|
383
383
|
message: "Файл успішно експортовано!"
|
@@ -405,25 +405,25 @@ const $t = /* @__PURE__ */ w(_t, [["render", wt]]), At = {
|
|
405
405
|
this.cols = (e = (t = this.columns) == null ? void 0 : t.filter((s) => (s == null ? void 0 : s.hidden) !== !0)) == null ? void 0 : e.map((s) => s == null ? void 0 : s.name), this.activeAction = "choceVisible";
|
406
406
|
}
|
407
407
|
}
|
408
|
-
},
|
408
|
+
}, St = {
|
409
409
|
key: 0,
|
410
410
|
class: "flex flex-col items-center"
|
411
|
-
},
|
411
|
+
}, It = {
|
412
412
|
key: 1,
|
413
413
|
class: "p-4"
|
414
|
-
},
|
414
|
+
}, Vt = { class: "pb-5 mb-5 border-b border-gray-200 last:pb-0 last:mb-0 last:border-b-0 dark:border-neutral-700" }, Dt = { class: "flex items-center gap-[10px] -ml-[10px] my-[10px]" }, Pt = ["onClick"], jt = {
|
415
415
|
key: 0,
|
416
416
|
class: "block h-[8px] w-[8px] rounded-full bg-blue-500"
|
417
|
-
},
|
417
|
+
}, Ft = { class: "mt-2 flex row flex-wrap gap-y-[5px] gap-x-[10px]" }, Mt = { class: "pb-5 mb-5 border-b border-gray-200 last:pb-0 last:mb-0 last:border-b-0 dark:border-neutral-700" }, Lt = { class: "mt-2 space-y-2" }, zt = ["id", "onChange"], qt = ["for"], Bt = {
|
418
418
|
key: 0,
|
419
419
|
class: "flex w-full justify-end p-[20px] gap-[6px] border-t"
|
420
|
-
},
|
420
|
+
}, Ot = {
|
421
421
|
key: 1,
|
422
422
|
class: "flex w-full justify-end p-[20px] gap-[6px] border-t"
|
423
423
|
};
|
424
|
-
function
|
424
|
+
function Nt(t, e, s, a, n, o) {
|
425
425
|
const d = p("IconExport"), f = p("IconSuccess"), h = p("VsCheckbox"), b = p("VsDialog");
|
426
|
-
return
|
426
|
+
return r(), i(T, null, [
|
427
427
|
l("button", {
|
428
428
|
onClick: e[0] || (e[0] = (u) => n.isOpen = !0),
|
429
429
|
class: "py-2 max-h-[34px] px-2.5 md:inline-flex hidden items-center gap-x-1.5 text-xs font-medium rounded-lg border border-gray-200 bg-white text-gray-800 shadow-sm hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-50 dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-700 dark:focus:bg-neutral-700"
|
@@ -442,7 +442,7 @@ function Ot(t, e, s, a, n, r) {
|
|
442
442
|
closeClickBack: !0
|
443
443
|
}, {
|
444
444
|
footer: S(() => [
|
445
|
-
n.isSuccessTemplate ? (
|
445
|
+
n.isSuccessTemplate ? (r(), i("div", Bt, [
|
446
446
|
l("button", {
|
447
447
|
type: "button",
|
448
448
|
class: "inline-flex items-center justify-center px-3 py-2 text-sm font-medium text-gray-800 align-middle bg-white border border-gray-200 rounded-lg shadow-sm text-nowrap text-start hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-700 dark:focus:bg-neutral-700",
|
@@ -453,7 +453,7 @@ function Ot(t, e, s, a, n, r) {
|
|
453
453
|
class: "inline-flex items-center justify-center px-3 py-2 text-sm font-medium text-white align-middle bg-blue-600 border border-blue-600 rounded-lg shadow-sm text-nowrap gap-x-2 text-start hover:bg-blue-700 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:ring-1 focus:ring-blue-300 dark:focus:ring-blue-500",
|
454
454
|
onClick: e[3] || (e[3] = (u) => n.isSuccessTemplate = !1)
|
455
455
|
}, " Вигрузити ще ")
|
456
|
-
])) : (
|
456
|
+
])) : (r(), i("div", Ot, [
|
457
457
|
l("button", {
|
458
458
|
type: "button",
|
459
459
|
class: "inline-flex items-center justify-center px-3 py-2 text-sm font-medium text-gray-800 align-middle bg-white border border-gray-200 rounded-lg shadow-sm text-nowrap text-start hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-700 dark:focus:bg-neutral-700",
|
@@ -462,23 +462,23 @@ function Ot(t, e, s, a, n, r) {
|
|
462
462
|
l("button", {
|
463
463
|
type: "button",
|
464
464
|
class: "inline-flex items-center justify-center px-3 py-2 text-sm font-medium text-white align-middle bg-blue-600 border border-blue-600 rounded-lg shadow-sm text-nowrap gap-x-2 text-start hover:bg-blue-700 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:ring-1 focus:ring-blue-300 dark:focus:ring-blue-500",
|
465
|
-
onClick: e[5] || (e[5] = (...u) =>
|
465
|
+
onClick: e[5] || (e[5] = (...u) => o.exportTable && o.exportTable(...u))
|
466
466
|
}, " Завантажити таблицю ")
|
467
467
|
]))
|
468
468
|
]),
|
469
469
|
default: S(() => [
|
470
|
-
n.isSuccessTemplate ? (
|
470
|
+
n.isSuccessTemplate ? (r(), i("div", St, [
|
471
471
|
x(f, {
|
472
472
|
height: "100",
|
473
473
|
width: "100",
|
474
474
|
class: "text-green-200 mb-[20px]"
|
475
475
|
}),
|
476
476
|
e[8] || (e[8] = l("h2", null, "Звіт сформовано і збережено", -1))
|
477
|
-
])) : (
|
478
|
-
l("div",
|
477
|
+
])) : (r(), i("div", It, [
|
478
|
+
l("div", Vt, [
|
479
479
|
e[9] || (e[9] = l("h2", { class: "text-sm font-[600] text-gray-500" }, " Виберіть стовпці таблиці для експорту: ", -1)),
|
480
|
-
l("div",
|
481
|
-
(
|
480
|
+
l("div", Dt, [
|
481
|
+
(r(!0), i(T, null, V(n.actions, (u) => (r(), i("button", {
|
482
482
|
key: u == null ? void 0 : u.name,
|
483
483
|
onClick: u == null ? void 0 : u.function,
|
484
484
|
class: "inline-flex items-center gap-[8px] justify-center px-3 py-2 text-sm font-medium text-gray-800 align-middle bg-white border-gray-200 text-nowrap text-start"
|
@@ -486,13 +486,13 @@ function Ot(t, e, s, a, n, r) {
|
|
486
486
|
l("span", {
|
487
487
|
class: I(["h-[14px] w-[14px] border rounded-full flex items-center justify-center", { "border-blue-500": (u == null ? void 0 : u.name) === n.activeAction }])
|
488
488
|
}, [
|
489
|
-
(u == null ? void 0 : u.name) === n.activeAction ? (
|
489
|
+
(u == null ? void 0 : u.name) === n.activeAction ? (r(), i("span", jt)) : v("", !0)
|
490
490
|
], 2),
|
491
491
|
j(" " + A(u == null ? void 0 : u.label), 1)
|
492
|
-
], 8,
|
492
|
+
], 8, Pt))), 128))
|
493
493
|
]),
|
494
|
-
l("div",
|
495
|
-
(
|
494
|
+
l("div", Ft, [
|
495
|
+
(r(!0), i(T, null, V(s.columns, (u, _) => (r(), i("div", {
|
496
496
|
class: "flex items-center",
|
497
497
|
key: _,
|
498
498
|
style: { width: "calc((100% - 10px) / 2)" }
|
@@ -500,17 +500,17 @@ function Ot(t, e, s, a, n, r) {
|
|
500
500
|
x(h, {
|
501
501
|
class: "[&>label]:text-sm [&>label]:text-gray-800 [&>label]:ms-3 !gap-x-[1px] !p-0",
|
502
502
|
modelValue: n.cols,
|
503
|
-
"onUpdate:modelValue": e[1] || (e[1] = (
|
503
|
+
"onUpdate:modelValue": e[1] || (e[1] = (m) => n.cols = m),
|
504
504
|
value: u == null ? void 0 : u.name,
|
505
505
|
label: u == null ? void 0 : u.ua
|
506
506
|
}, null, 8, ["modelValue", "value", "label"])
|
507
507
|
]))), 128))
|
508
508
|
])
|
509
509
|
]),
|
510
|
-
l("div",
|
510
|
+
l("div", Mt, [
|
511
511
|
e[10] || (e[10] = l("h2", { class: "text-sm font-[600] text-gray-500" }, "Виберіть формат таблиці:", -1)),
|
512
|
-
l("div",
|
513
|
-
(
|
512
|
+
l("div", Lt, [
|
513
|
+
(r(!0), i(T, null, V(n.tableFormats, (u, _) => (r(), i("div", {
|
514
514
|
class: "flex items-center",
|
515
515
|
key: _
|
516
516
|
}, [
|
@@ -519,12 +519,12 @@ function Ot(t, e, s, a, n, r) {
|
|
519
519
|
name: "hs-pro-duecmfm",
|
520
520
|
class: "text-blue-600 border-gray-300 rounded-full shrink-0 focus:ring-blue-500 disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-800 dark:border-neutral-500 dark:checked:bg-blue-500 dark:checked:border-blue-500 dark:focus:ring-offset-gray-800",
|
521
521
|
id: u,
|
522
|
-
onChange: (
|
523
|
-
}, null, 40,
|
522
|
+
onChange: (m) => o.selectFormat(u)
|
523
|
+
}, null, 40, zt),
|
524
524
|
l("label", {
|
525
525
|
for: u,
|
526
526
|
class: "text-sm text-gray-800 ms-3 dark:text-neutral-400"
|
527
|
-
}, " Формат " + A(u), 9,
|
527
|
+
}, " Формат " + A(u), 9, qt)
|
528
528
|
]))), 128))
|
529
529
|
])
|
530
530
|
])
|
@@ -534,7 +534,7 @@ function Ot(t, e, s, a, n, r) {
|
|
534
534
|
}, 8, ["visible"])
|
535
535
|
], 64);
|
536
536
|
}
|
537
|
-
const
|
537
|
+
const Ut = /* @__PURE__ */ C(Tt, [["render", Nt]]), Et = {}, Ht = {
|
538
538
|
xmlns: "http://www.w3.org/2000/svg",
|
539
539
|
viewBox: "0 0 24 24",
|
540
540
|
fill: "none",
|
@@ -544,12 +544,12 @@ const Nt = /* @__PURE__ */ w(At, [["render", Ot]]), Ut = {}, Et = {
|
|
544
544
|
"stroke-linejoin": "round",
|
545
545
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-columns"
|
546
546
|
};
|
547
|
-
function
|
548
|
-
return
|
547
|
+
function Rt(t, e, s, a, n, o) {
|
548
|
+
return r(), i("svg", Ht, e[0] || (e[0] = [
|
549
549
|
Xe('<path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M4 6l5.5 0"></path><path d="M4 10l5.5 0"></path><path d="M4 14l5.5 0"></path><path d="M4 18l5.5 0"></path><path d="M14.5 6l5.5 0"></path><path d="M14.5 10l5.5 0"></path><path d="M14.5 14l5.5 0"></path><path d="M14.5 18l5.5 0"></path>', 9)
|
550
550
|
]));
|
551
551
|
}
|
552
|
-
const
|
552
|
+
const Wt = /* @__PURE__ */ C(Et, [["render", Rt]]), Jt = {
|
553
553
|
props: { column: Object },
|
554
554
|
emits: ["update-column"],
|
555
555
|
components: {
|
@@ -569,12 +569,12 @@ const Rt = /* @__PURE__ */ w(Ut, [["render", Ht]]), Wt = {
|
|
569
569
|
var t;
|
570
570
|
((t = this.column) == null ? void 0 : t.hidden) !== !0 && (this.value = !0);
|
571
571
|
}
|
572
|
-
},
|
573
|
-
function
|
572
|
+
}, Gt = { class: "flex justify-between items-center py-1.5 px-3 cursor-pointer rounded-lg hover:bg-gray-100 has-[:disabled]:opacity-50 has-[:disabled]:pointer-events-none dark:hover:bg-neutral-800" }, Kt = { class: "flex justify-between flex-1 items-center gap-x-2.5 cursor-pointer text-[13px] text-gray-800 dark:text-neutral-300" };
|
573
|
+
function Qt(t, e, s, a, n, o) {
|
574
574
|
var f, h;
|
575
575
|
const d = p("IconCheck2");
|
576
|
-
return
|
577
|
-
l("label",
|
576
|
+
return r(), i("div", Gt, [
|
577
|
+
l("label", Kt, [
|
578
578
|
j(A(((f = s.column) == null ? void 0 : f.ua) || ((h = s.column) == null ? void 0 : h.title)) + " ", 1),
|
579
579
|
M(l("input", {
|
580
580
|
type: "checkbox",
|
@@ -584,7 +584,7 @@ function Kt(t, e, s, a, n, r) {
|
|
584
584
|
[Ye, n.value]
|
585
585
|
]),
|
586
586
|
l("span", {
|
587
|
-
class: I(["flex items-center justify-center text-white
|
587
|
+
class: I(["flex items-center justify-center text-white border border-gray-300 rounded shrink-0 size-4 focus:ring-blue-500", [n.value ? "bg-blue-600 border-0" : "bg-white"]])
|
588
588
|
}, [
|
589
589
|
x(d, {
|
590
590
|
height: "12",
|
@@ -594,8 +594,8 @@ function Kt(t, e, s, a, n, r) {
|
|
594
594
|
])
|
595
595
|
]);
|
596
596
|
}
|
597
|
-
const
|
598
|
-
components: { IconColumns:
|
597
|
+
const Xt = /* @__PURE__ */ C(Jt, [["render", Qt]]), Yt = {
|
598
|
+
components: { IconColumns: Wt, AdminTableColumnsHiddenItem: Xt },
|
599
599
|
emits: ["update-columns"],
|
600
600
|
props: { columns: Array },
|
601
601
|
data() {
|
@@ -609,8 +609,8 @@ const Qt = /* @__PURE__ */ w(Wt, [["render", Kt]]), Xt = {
|
|
609
609
|
var t;
|
610
610
|
return (t = this.columns) == null ? void 0 : t.filter(
|
611
611
|
(e) => {
|
612
|
-
var s, a, n,
|
613
|
-
return ((n = (s = e == null ? void 0 : e.ua) == null ? void 0 : s.toLowerCase()) == null ? void 0 : n.includes((a = this.searchValue) == null ? void 0 : a.toLowerCase())) || ((f = (
|
612
|
+
var s, a, n, o, d, f;
|
613
|
+
return ((n = (s = e == null ? void 0 : e.ua) == null ? void 0 : s.toLowerCase()) == null ? void 0 : n.includes((a = this.searchValue) == null ? void 0 : a.toLowerCase())) || ((f = (o = e == null ? void 0 : e.title) == null ? void 0 : o.toLowerCase()) == null ? void 0 : f.includes((d = this.searchValue) == null ? void 0 : d.toLowerCase()));
|
614
614
|
}
|
615
615
|
);
|
616
616
|
}
|
@@ -631,24 +631,24 @@ const Qt = /* @__PURE__ */ w(Wt, [["render", Kt]]), Xt = {
|
|
631
631
|
beforeUnmount() {
|
632
632
|
document.removeEventListener("click", this.handleClickOutside);
|
633
633
|
}
|
634
|
-
},
|
634
|
+
}, Zt = {
|
635
635
|
class: "relative",
|
636
636
|
ref: "wrapper"
|
637
|
-
},
|
637
|
+
}, es = {
|
638
638
|
key: 0,
|
639
639
|
class: "absolute left-[50%] top-[110%] translate-x-[-50%] z-10 w-64 transition-[opacity,margin] duration bg-white rounded-xl shadow-lg dark:bg-neutral-900"
|
640
|
-
},
|
640
|
+
}, ts = { class: "relative p-1 border-gray-200 border-y dark:border-neutral-800" }, ss = { class: "p-1 pt-3 max-h-80 overflow-y-auto [&::-webkit-scrollbar]:w-2 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-track]:bg-gray-100 [&::-webkit-scrollbar-thumb]:bg-gray-300 dark:[&::-webkit-scrollbar-track]:bg-neutral-700 dark:[&::-webkit-scrollbar-thumb]:bg-neutral-500" }, ns = {
|
641
641
|
key: 0,
|
642
642
|
class: "block px-3 mb-2 text-xs text-gray-500 dark:text-neutral-500"
|
643
|
-
},
|
643
|
+
}, ls = { class: "space-y-1" }, rs = {
|
644
644
|
key: 1,
|
645
645
|
class: "flex items-center px-3 text-[13px] py-1.5 px-3 rounded-md cursor-pointer group"
|
646
646
|
};
|
647
|
-
function os(t, e, s, a, n,
|
647
|
+
function os(t, e, s, a, n, o) {
|
648
648
|
const d = p("IconColumns"), f = p("AdminTableColumnsHiddenItem");
|
649
|
-
return
|
649
|
+
return r(), i("div", Zt, [
|
650
650
|
l("button", {
|
651
|
-
onClick: e[0] || (e[0] = (...h) =>
|
651
|
+
onClick: e[0] || (e[0] = (...h) => o.toggleVisible && o.toggleVisible(...h)),
|
652
652
|
class: "py-2 max-h-[34px] px-2.5 md:inline-flex hidden items-center gap-x-1.5 text-xs font-medium rounded-lg border border-gray-200 bg-white text-gray-800 shadow-sm hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-50 dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-700 dark:focus:bg-neutral-700"
|
653
653
|
}, [
|
654
654
|
x(d, {
|
@@ -660,9 +660,9 @@ function os(t, e, s, a, n, r) {
|
|
660
660
|
default: S(() => {
|
661
661
|
var h, b;
|
662
662
|
return [
|
663
|
-
n.visible ? (
|
663
|
+
n.visible ? (r(), i("div", es, [
|
664
664
|
e[2] || (e[2] = l("div", { class: "flex items-center justify-between h-[48px] px-4 py-2 gap-x-2 text-sm font-medium text-gray-800" }, " Колонки ", -1)),
|
665
|
-
l("div",
|
665
|
+
l("div", ts, [
|
666
666
|
M(l("input", {
|
667
667
|
"onUpdate:modelValue": e[1] || (e[1] = (u) => n.searchValue = u),
|
668
668
|
type: "text",
|
@@ -673,14 +673,14 @@ function os(t, e, s, a, n, r) {
|
|
673
673
|
[Ze, n.searchValue]
|
674
674
|
])
|
675
675
|
]),
|
676
|
-
l("div",
|
677
|
-
(h =
|
678
|
-
l("div",
|
679
|
-
(b =
|
676
|
+
l("div", ss, [
|
677
|
+
(h = o.filteredColumn) != null && h.length ? (r(), i("span", ns, " Оберіть колонки для відображення ")) : v("", !0),
|
678
|
+
l("div", ls, [
|
679
|
+
(b = o.filteredColumn) != null && b.length ? (r(!0), i(T, { key: 0 }, V(o.filteredColumn, (u, _) => (r(), k(f, {
|
680
680
|
key: _,
|
681
681
|
column: u,
|
682
|
-
onUpdateColumn:
|
683
|
-
}, null, 8, ["column", "onUpdateColumn"]))), 128)) : (
|
682
|
+
onUpdateColumn: o.updateColumn
|
683
|
+
}, null, 8, ["column", "onUpdateColumn"]))), 128)) : (r(), i("div", rs, " Нічого не знайдено "))
|
684
684
|
])
|
685
685
|
])
|
686
686
|
])) : v("", !0)
|
@@ -690,7 +690,7 @@ function os(t, e, s, a, n, r) {
|
|
690
690
|
})
|
691
691
|
], 512);
|
692
692
|
}
|
693
|
-
const
|
693
|
+
const as = /* @__PURE__ */ C(Yt, [["render", os]]), is = {}, us = {
|
694
694
|
xmlns: "http://www.w3.org/2000/svg",
|
695
695
|
viewBox: "0 0 24 24",
|
696
696
|
fill: "none",
|
@@ -700,8 +700,8 @@ const rs = /* @__PURE__ */ w(Xt, [["render", os]]), as = {}, is = {
|
|
700
700
|
"stroke-linejoin": "round",
|
701
701
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-minus"
|
702
702
|
};
|
703
|
-
function
|
704
|
-
return
|
703
|
+
function ds(t, e, s, a, n, o) {
|
704
|
+
return r(), i("svg", us, e[0] || (e[0] = [
|
705
705
|
l("path", {
|
706
706
|
stroke: "none",
|
707
707
|
d: "M0 0h24v24H0z",
|
@@ -710,8 +710,8 @@ function us(t, e, s, a, n, r) {
|
|
710
710
|
l("path", { d: "M5 12l14 0" }, null, -1)
|
711
711
|
]));
|
712
712
|
}
|
713
|
-
const
|
714
|
-
components: { IconPlus: N, IconMinus:
|
713
|
+
const cs = /* @__PURE__ */ C(is, [["render", ds]]), ps = {
|
714
|
+
components: { IconPlus: N, IconMinus: cs },
|
715
715
|
props: {
|
716
716
|
title: String,
|
717
717
|
defaultValue: { type: Boolean, default: () => !1 }
|
@@ -719,32 +719,32 @@ const ds = /* @__PURE__ */ w(as, [["render", us]]), cs = {
|
|
719
719
|
data() {
|
720
720
|
return { expanded: this.defaultValue };
|
721
721
|
}
|
722
|
-
},
|
723
|
-
function ms(t, e, s, a, n,
|
722
|
+
}, hs = { class: "hs-accordion" }, bs = { class: "py-0.5 flex items-center gap-x-0.5 w-full" }, fs = { class: "text-sm font-medium" }, gs = { class: "relative inline-block w-full duration-150 cursor-pointer before:block before:absolute b" };
|
723
|
+
function ms(t, e, s, a, n, o) {
|
724
724
|
const d = p("IconPlus"), f = p("IconMinus");
|
725
|
-
return
|
725
|
+
return r(), i("div", null, [
|
726
726
|
l("div", null, [
|
727
|
-
l("div",
|
728
|
-
l("div",
|
727
|
+
l("div", hs, [
|
728
|
+
l("div", bs, [
|
729
729
|
l("div", {
|
730
730
|
onClick: e[0] || (e[0] = (h) => n.expanded = !n.expanded),
|
731
731
|
class: "rounded-md cursor-pointer grow"
|
732
732
|
}, [
|
733
|
-
l("span",
|
733
|
+
l("span", fs, A(s.title), 1)
|
734
734
|
]),
|
735
735
|
l("button", {
|
736
736
|
class: "flex items-center justify-center rounded-md size-6 hover:bg-gray-100",
|
737
737
|
onClick: e[1] || (e[1] = (h) => n.expanded = !n.expanded)
|
738
738
|
}, [
|
739
|
-
n.expanded ? (
|
739
|
+
n.expanded ? (r(), k(f, {
|
740
740
|
key: 1,
|
741
741
|
width: "14"
|
742
|
-
})) : (
|
742
|
+
})) : (r(), k(d, { key: 0 }))
|
743
743
|
])
|
744
744
|
]),
|
745
745
|
x(L, { name: "fade" }, {
|
746
746
|
default: S(() => [
|
747
|
-
M(l("div",
|
747
|
+
M(l("div", gs, [
|
748
748
|
et(t.$slots, "default", {}, void 0, !0)
|
749
749
|
], 512), [
|
750
750
|
[E, n.expanded]
|
@@ -756,44 +756,44 @@ function ms(t, e, s, a, n, r) {
|
|
756
756
|
])
|
757
757
|
]);
|
758
758
|
}
|
759
|
-
const
|
759
|
+
const xs = /* @__PURE__ */ C(ps, [["render", ms], ["__scopeId", "data-v-e1f274c9"]]), ys = {
|
760
760
|
components: {
|
761
761
|
AdminComponentIs: U,
|
762
|
-
AdminTree:
|
762
|
+
AdminTree: xs,
|
763
763
|
VsNoData: Ue,
|
764
764
|
VsWidgetComments: Ee,
|
765
765
|
VsWidgetMap: He,
|
766
766
|
VsWidgetFileList: Re
|
767
767
|
},
|
768
768
|
props: { table: String, columns: Array, row: Object }
|
769
|
-
},
|
769
|
+
}, ks = {
|
770
770
|
class: "hs-accordion border-gray-100 w-[360px] shrink-0 overflow-auto [&::-webkit-scrollbar]:w-2 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar:horizontal]:h-[8px] [&::-webkit-scrollbar-track]:bg-gray-100 [&::-webkit-scrollbar-thumb]:bg-gray-300 dark:[&::-webkit-scrollbar-track]:bg-neutral-700 dark:[&::-webkit-scrollbar-thumb]:bg-neutral-500",
|
771
771
|
style: { height: "calc(100vh - 310px)" }
|
772
|
-
},
|
772
|
+
}, vs = {
|
773
773
|
class: "border-l",
|
774
774
|
style: { height: "calc(100vh - 360px)" }
|
775
|
-
},
|
776
|
-
function
|
777
|
-
var
|
775
|
+
}, _s = { class: "flow-root mt-[10px]" }, ws = { class: "-my-3 text-sm divide-y divide-gray-100" }, Cs = { class: "flex py-3 sm:grid-cols-3 sm:gap-4" }, $s = { class: "font-medium text-black w-[50%]" }, As = { class: "text-gray-700 sm:col-span-2 w-[50%]" }, Ts = { class: "table-info-card" }, Ss = { class: "table-info-card" };
|
776
|
+
function Is(t, e, s, a, n, o) {
|
777
|
+
var m, g, w;
|
778
778
|
const d = p("AdminComponentIs"), f = p("AdminTree"), h = p("VsWidgetMap"), b = p("VsNoData"), u = p("VsWidgetComments"), _ = p("VsWidgetFileList");
|
779
|
-
return
|
779
|
+
return r(), i("div", ks, [
|
780
780
|
e[0] || (e[0] = l("div", { class: "p-[10px] pl-[18px] pb-[18px] border-b" }, [
|
781
781
|
l("h2", { class: "text-sm font-medium" }, "Інформація про об'єкт")
|
782
782
|
], -1)),
|
783
|
-
l("div",
|
784
|
-
(
|
785
|
-
s.row ? (
|
783
|
+
l("div", vs, [
|
784
|
+
(g = (m = t.$route) == null ? void 0 : m.query) != null && g.card ? (r(), i(T, { key: 0 }, [
|
785
|
+
s.row ? (r(), k(f, {
|
786
786
|
key: 0,
|
787
787
|
defaultValue: !0,
|
788
788
|
title: "Основна інформація",
|
789
789
|
class: "border-b p-[10px] py-[16px]"
|
790
790
|
}, {
|
791
791
|
default: S(() => [
|
792
|
-
l("div",
|
793
|
-
l("dl",
|
794
|
-
(
|
795
|
-
l("dt",
|
796
|
-
l("dd",
|
792
|
+
l("div", _s, [
|
793
|
+
l("dl", ws, [
|
794
|
+
(r(!0), i(T, null, V(s.columns, (y) => (r(), i("div", Cs, [
|
795
|
+
l("dt", $s, A((y == null ? void 0 : y.ua) || (y == null ? void 0 : y.title)), 1),
|
796
|
+
l("dd", As, [
|
797
797
|
x(d, {
|
798
798
|
row: s.row,
|
799
799
|
column: y,
|
@@ -806,7 +806,7 @@ function Ss(t, e, s, a, n, r) {
|
|
806
806
|
]),
|
807
807
|
_: 1
|
808
808
|
})) : v("", !0),
|
809
|
-
(
|
809
|
+
(w = s.row) != null && w.geom ? (r(), k(f, {
|
810
810
|
key: 1,
|
811
811
|
title: "Карта",
|
812
812
|
class: "border-b p-[10px] py-[16px]"
|
@@ -814,11 +814,11 @@ function Ss(t, e, s, a, n, r) {
|
|
814
814
|
default: S(() => {
|
815
815
|
var y, $;
|
816
816
|
return [
|
817
|
-
(y = s.row) != null && y.geom ? (
|
817
|
+
(y = s.row) != null && y.geom ? (r(), k(h, {
|
818
818
|
key: 0,
|
819
819
|
geometry: ($ = s.row) == null ? void 0 : $.geom,
|
820
820
|
zoom: 14
|
821
|
-
}, null, 8, ["geometry"])) : (
|
821
|
+
}, null, 8, ["geometry"])) : (r(), k(b, {
|
822
822
|
key: 1,
|
823
823
|
title: "У об'єкта відсутня геометрія",
|
824
824
|
text: "",
|
@@ -835,7 +835,7 @@ function Ss(t, e, s, a, n, r) {
|
|
835
835
|
default: S(() => {
|
836
836
|
var y;
|
837
837
|
return [
|
838
|
-
l("div",
|
838
|
+
l("div", Ts, [
|
839
839
|
x(u, {
|
840
840
|
id: (y = s.row) == null ? void 0 : y.id
|
841
841
|
}, null, 8, ["id"])
|
@@ -851,8 +851,8 @@ function Ss(t, e, s, a, n, r) {
|
|
851
851
|
default: S(() => {
|
852
852
|
var y, $;
|
853
853
|
return [
|
854
|
-
l("div",
|
855
|
-
(
|
854
|
+
l("div", Ss, [
|
855
|
+
(r(), k(_, {
|
856
856
|
key: (y = s.row) == null ? void 0 : y.id,
|
857
857
|
id: ($ = s.row) == null ? void 0 : $.id
|
858
858
|
}, null, 8, ["id"]))
|
@@ -861,14 +861,14 @@ function Ss(t, e, s, a, n, r) {
|
|
861
861
|
}),
|
862
862
|
_: 1
|
863
863
|
})
|
864
|
-
], 64)) : (
|
864
|
+
], 64)) : (r(), k(b, {
|
865
865
|
key: 1,
|
866
866
|
text: "Оберіть один з об'єктів в таблиці для відображення інформаціі про нього"
|
867
867
|
}))
|
868
868
|
])
|
869
869
|
]);
|
870
870
|
}
|
871
|
-
const
|
871
|
+
const Vs = /* @__PURE__ */ C(ys, [["render", Is]]), Ds = {}, Ps = {
|
872
872
|
class: "size-4",
|
873
873
|
xmlns: "http://www.w3.org/2000/svg",
|
874
874
|
viewBox: "0 0 24 24",
|
@@ -878,8 +878,8 @@ const Is = /* @__PURE__ */ w(xs, [["render", Ss]]), Vs = {}, Ds = {
|
|
878
878
|
"stroke-linecap": "round",
|
879
879
|
"stroke-linejoin": "round"
|
880
880
|
};
|
881
|
-
function
|
882
|
-
return
|
881
|
+
function js(t, e, s, a, n, o) {
|
882
|
+
return r(), i("svg", Ps, e[0] || (e[0] = [
|
883
883
|
l("rect", {
|
884
884
|
width: "18",
|
885
885
|
height: "18",
|
@@ -891,7 +891,7 @@ function Ps(t, e, s, a, n, r) {
|
|
891
891
|
l("path", { d: "m8 9 3 3-3 3" }, null, -1)
|
892
892
|
]));
|
893
893
|
}
|
894
|
-
const
|
894
|
+
const Fs = /* @__PURE__ */ C(Ds, [["render", js]]), Ms = {
|
895
895
|
emits: ["filterChange"],
|
896
896
|
props: {
|
897
897
|
scheme: { type: Object },
|
@@ -909,10 +909,10 @@ const js = /* @__PURE__ */ w(Vs, [["render", Ps]]), Fs = {
|
|
909
909
|
this.isFilters && t.classList.contains("filter-container") && (this.isFilters = !1);
|
910
910
|
}
|
911
911
|
}
|
912
|
-
},
|
913
|
-
function
|
912
|
+
}, Ls = { key: 0 }, zs = { class: "filter-content h-screen bg-white w-[400px] overflow-x-auto [&::-webkit-scrollbar]:w-2 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar:horizontal]:h-[8px] [&::-webkit-scrollbar-track]:bg-gray-100 [&::-webkit-scrollbar-thumb]:bg-gray-300 dark:[&::-webkit-scrollbar-track]:bg-neutral-700 dark:[&::-webkit-scrollbar-thumb]:bg-neutral-500" };
|
913
|
+
function qs(t, e, s, a, n, o) {
|
914
914
|
const d = p("IconFilter"), f = p("VsFilter");
|
915
|
-
return
|
915
|
+
return r(), i(T, null, [
|
916
916
|
l("button", {
|
917
917
|
onClick: e[0] || (e[0] = (h) => n.isFilters = !n.isFilters),
|
918
918
|
class: "py-2 px-2.5 max-h-[34px] inline-flex items-center gap-x-1.5 text-xs font-medium rounded-lg border border-gray-200 bg-white text-gray-800 shadow-sm hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none"
|
@@ -922,62 +922,64 @@ function zs(t, e, s, a, n, r) {
|
|
922
922
|
width: "16"
|
923
923
|
}),
|
924
924
|
e[4] || (e[4] = j(" Фільтри ")),
|
925
|
-
s.onFilters ? (
|
925
|
+
s.onFilters ? (r(), i("span", Ls, A(s.onFilters), 1)) : v("", !0)
|
926
926
|
]),
|
927
927
|
x(L, { name: "fade" }, {
|
928
928
|
default: S(() => {
|
929
929
|
var h;
|
930
930
|
return [
|
931
|
-
|
932
|
-
|
933
|
-
|
934
|
-
|
935
|
-
|
936
|
-
|
937
|
-
(
|
938
|
-
|
939
|
-
|
940
|
-
|
941
|
-
|
942
|
-
|
943
|
-
|
944
|
-
|
945
|
-
|
946
|
-
|
947
|
-
|
948
|
-
|
949
|
-
|
950
|
-
|
951
|
-
|
931
|
+
(r(), k(tt, { to: "#modal" }, [
|
932
|
+
M(l("div", {
|
933
|
+
onClick: e[3] || (e[3] = (...b) => o.closeFilter && o.closeFilter(...b)),
|
934
|
+
style: { height: "100vh" },
|
935
|
+
class: "fixed filter-container top-0 flex justify-end items-center z-[12] right-0 left-0 bottom-0 bg-[rgba(0,0,0,0.2)]"
|
936
|
+
}, [
|
937
|
+
l("div", zs, [
|
938
|
+
(h = s.scheme) != null && h.length ? (r(), k(f, {
|
939
|
+
key: 0,
|
940
|
+
ref: "filter",
|
941
|
+
scheme: s.scheme,
|
942
|
+
layout: "default",
|
943
|
+
"apply-vue-router": "",
|
944
|
+
history: "",
|
945
|
+
token: s.table,
|
946
|
+
name: "filter",
|
947
|
+
footer: !0,
|
948
|
+
background: !0,
|
949
|
+
onFilterChange: e[1] || (e[1] = (b) => t.$emit("filterChange", b)),
|
950
|
+
closeFilterBtn: !0,
|
951
|
+
onFilterClose: e[2] || (e[2] = (b) => n.isFilters = !1)
|
952
|
+
}, null, 8, ["scheme", "token"])) : v("", !0)
|
953
|
+
])
|
954
|
+
], 512), [
|
955
|
+
[E, n.isFilters]
|
952
956
|
])
|
953
|
-
]
|
954
|
-
[E, n.isFilters]
|
955
|
-
])
|
957
|
+
]))
|
956
958
|
];
|
957
959
|
}),
|
958
960
|
_: 1
|
959
961
|
})
|
960
962
|
], 64);
|
961
963
|
}
|
962
|
-
const
|
964
|
+
const Bs = /* @__PURE__ */ C(Ms, [["render", qs]]), Os = {
|
963
965
|
props: { tabsList: { type: Array, default: () => [] }, filterState: String }
|
964
|
-
},
|
966
|
+
}, Ns = {
|
965
967
|
class: "relative flex space-x-1 mb-[20px] after:absolute after:w-[99%] after:bottom-0 after:inset-x-0 after:border-b-2 after:border-gray-200 dark:after:border-neutral-700",
|
966
968
|
"aria-label": "Tabs",
|
967
969
|
role: "tablist",
|
968
970
|
"aria-orientation": "horizontal"
|
969
|
-
},
|
970
|
-
function
|
971
|
-
return
|
972
|
-
(
|
971
|
+
}, Us = ["onClick"];
|
972
|
+
function Es(t, e, s, a, n, o) {
|
973
|
+
return r(), i("nav", Ns, [
|
974
|
+
(r(!0), i(T, null, V(s.tabsList, (d) => (r(), i("button", {
|
973
975
|
onClick: (f) => t.$emit("update:filterState", d == null ? void 0 : d.name),
|
974
976
|
class: I(["hs-tab-active:after:bg-gray-800 hs-tab-active:text-gray-800 px-2.5 py-1.5 mb-2 relative inline-flex justify-center items-center gap-x-2 hover:bg-gray-100 text-gray-500 hover:text-gray-800 text-sm rounded-lg disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-100 after:absolute after:-bottom-2 after:inset-x-0 after:z-10 after:h-0.5 after:pointer-events-none dark:hs-tab-active:text-neutral-200 dark:hs-tab-active:after:bg-neutral-400 dark:text-neutral-500 dark:hover:text-neutral-300 dark:hover:bg-neutral-700 dark:focus:bg-neutral-700 active", {
|
975
977
|
" font-semibold after:absolute after:bottom-[-8px] after:left-2.5 after:right-2.5 after:z-10 after:h-0.5 after:bg-gray-800": (d == null ? void 0 : d.name) === s.filterState
|
976
978
|
}])
|
977
|
-
}, A(d == null ? void 0 : d.label), 11,
|
979
|
+
}, A(d == null ? void 0 : d.label), 11, Us))), 256))
|
978
980
|
]);
|
979
981
|
}
|
980
|
-
const
|
982
|
+
const Hs = /* @__PURE__ */ C(Os, [["render", Es]]), Rs = {}, Ws = {
|
981
983
|
xmlns: "http://www.w3.org/2000/svg",
|
982
984
|
viewBox: "0 0 24 24",
|
983
985
|
fill: "none",
|
@@ -987,8 +989,8 @@ const Es = /* @__PURE__ */ w(Bs, [["render", Us]]), Hs = {}, Rs = {
|
|
987
989
|
"stroke-linejoin": "round",
|
988
990
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-filter"
|
989
991
|
};
|
990
|
-
function
|
991
|
-
return
|
992
|
+
function Js(t, e, s, a, n, o) {
|
993
|
+
return r(), i("svg", Ws, e[0] || (e[0] = [
|
992
994
|
l("path", {
|
993
995
|
stroke: "none",
|
994
996
|
d: "M0 0h24v24H0z",
|
@@ -997,18 +999,18 @@ function Ws(t, e, s, a, n, r) {
|
|
997
999
|
l("path", { d: "M4 4h16v2.172a2 2 0 0 1 -.586 1.414l-4.414 4.414v7l-6 2v-8.5l-4.48 -4.928a2 2 0 0 1 -.52 -1.345v-2.227z" }, null, -1)
|
998
1000
|
]));
|
999
1001
|
}
|
1000
|
-
const
|
1001
|
-
components: { IconFilter2:
|
1002
|
+
const Gs = /* @__PURE__ */ C(Rs, [["render", Js]]), Ks = {
|
1003
|
+
components: { IconFilter2: Gs, IconCheck2: Ve },
|
1002
1004
|
props: { filterCustom: String, customList: Array }
|
1003
|
-
},
|
1004
|
-
function
|
1005
|
+
}, Qs = { class: "py-2 max-h-[34px] px-2.5 inline-flex items-center gap-x-1.5 text-xs font-medium rounded-lg border border-gray-200 bg-white text-gray-800 shadow-sm hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-50 dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-700 dark:focus:bg-neutral-700" }, Xs = { class: "flex flex-col p-[2px] gap-[2px] w-[170px]" }, Ys = ["onClick"], Zs = { class: "text-sm text-gray-800" };
|
1006
|
+
function en(t, e, s, a, n, o) {
|
1005
1007
|
const d = p("IconFilter2"), f = p("IconCheck2"), h = p("VsPopover");
|
1006
|
-
return
|
1008
|
+
return r(), k(h, {
|
1007
1009
|
ref: "popover",
|
1008
1010
|
placement: "bottom"
|
1009
1011
|
}, {
|
1010
1012
|
reference: S(() => [
|
1011
|
-
l("button",
|
1013
|
+
l("button", Qs, [
|
1012
1014
|
x(d, {
|
1013
1015
|
height: "20",
|
1014
1016
|
width: "20"
|
@@ -1016,21 +1018,21 @@ function Zs(t, e, s, a, n, r) {
|
|
1016
1018
|
])
|
1017
1019
|
]),
|
1018
1020
|
default: S(() => [
|
1019
|
-
l("div",
|
1020
|
-
(
|
1021
|
+
l("div", Xs, [
|
1022
|
+
(r(!0), i(T, null, V(s.customList, (b, u) => (r(), i("button", {
|
1021
1023
|
onClick: (_) => {
|
1022
|
-
var
|
1023
|
-
t.$emit("update:filterCustom", b == null ? void 0 : b.name), (
|
1024
|
+
var m;
|
1025
|
+
t.$emit("update:filterCustom", b == null ? void 0 : b.name), (m = t.$refs) == null || m.popover.togglePopover();
|
1024
1026
|
},
|
1025
1027
|
key: u,
|
1026
1028
|
class: I(["flex items-center px-3 py-1 rounded-md cursor-pointer group hover:bg-gray-100", { "bg-gray-100": s.filterCustom === (b == null ? void 0 : b.name) }])
|
1027
1029
|
}, [
|
1028
|
-
l("span",
|
1029
|
-
s.filterCustom === (b == null ? void 0 : b.name) ? (
|
1030
|
+
l("span", Zs, A(b == null ? void 0 : b.label), 1),
|
1031
|
+
s.filterCustom === (b == null ? void 0 : b.name) ? (r(), k(f, {
|
1030
1032
|
key: 0,
|
1031
1033
|
class: "ml-auto size-3 shrink-0"
|
1032
1034
|
})) : v("", !0)
|
1033
|
-
], 10,
|
1035
|
+
], 10, Ys))), 128)),
|
1034
1036
|
l("button", {
|
1035
1037
|
class: "flex items-center px-3 py-1 rounded-md cursor-pointer group hover:bg-gray-100",
|
1036
1038
|
onClick: e[0] || (e[0] = (b) => {
|
@@ -1043,16 +1045,16 @@ function Zs(t, e, s, a, n, r) {
|
|
1043
1045
|
_: 1
|
1044
1046
|
}, 512);
|
1045
1047
|
}
|
1046
|
-
const
|
1048
|
+
const tn = /* @__PURE__ */ C(Ks, [["render", en]]), sn = { class: "flex items-center gap-x-2" }, nn = {
|
1047
1049
|
__name: "admin-table-custom-buttons",
|
1048
1050
|
props: {
|
1049
1051
|
slots: Object
|
1050
1052
|
},
|
1051
1053
|
setup(t) {
|
1052
1054
|
var f, h, b, u, _;
|
1053
|
-
const { asyncTemplateSlot: e } = (_ = (u = (b = (h = (f = De()) == null ? void 0 : f.appContext) == null ? void 0 : h.app) == null ? void 0 : b.config) == null ? void 0 : u.globalProperties) == null ? void 0 : _.utils, s = B(""), a = B(""), n = t,
|
1054
|
-
var
|
1055
|
-
if ((
|
1055
|
+
const { asyncTemplateSlot: e } = (_ = (u = (b = (h = (f = De()) == null ? void 0 : f.appContext) == null ? void 0 : h.app) == null ? void 0 : b.config) == null ? void 0 : u.globalProperties) == null ? void 0 : _.utils, s = B(""), a = B(""), n = t, o = () => {
|
1056
|
+
var m, g, w, y, $;
|
1057
|
+
if ((m = n.slots) != null && m.panelLeft || (a.value = "div"), (w = (g = n.slots) == null ? void 0 : g.panelLeft) != null && w.includes("<")) {
|
1056
1058
|
const D = e("PanelLeft", (y = n.slots) == null ? void 0 : y.panelLeft, [
|
1057
1059
|
"name"
|
1058
1060
|
]);
|
@@ -1060,8 +1062,8 @@ const en = /* @__PURE__ */ w(Gs, [["render", Zs]]), tn = { class: "flex items-ce
|
|
1060
1062
|
} else
|
1061
1063
|
a.value = ($ = n.slots) == null ? void 0 : $.panelLeft;
|
1062
1064
|
}, d = () => {
|
1063
|
-
var
|
1064
|
-
if ((
|
1065
|
+
var m, g, w, y, $;
|
1066
|
+
if ((m = n.slots) != null && m.panelRight || (s.value = "div"), (w = (g = n.slots) == null ? void 0 : g.panelRight) != null && w.includes("<")) {
|
1065
1067
|
const D = e("PanelRight", (y = n.slots) == null ? void 0 : y.panelRight, [
|
1066
1068
|
"name"
|
1067
1069
|
]);
|
@@ -1069,47 +1071,47 @@ const en = /* @__PURE__ */ w(Gs, [["render", Zs]]), tn = { class: "flex items-ce
|
|
1069
1071
|
} else
|
1070
1072
|
s.value = ($ = n.slots) == null ? void 0 : $.panelRight;
|
1071
1073
|
};
|
1072
|
-
return
|
1073
|
-
(
|
1074
|
-
(
|
1074
|
+
return o(), d(), (m, g) => (r(), i("div", sn, [
|
1075
|
+
(r(), k(O(a.value))),
|
1076
|
+
(r(), k(O(s.value)))
|
1075
1077
|
]));
|
1076
1078
|
}
|
1077
|
-
},
|
1079
|
+
}, ln = (t, e = 300) => {
|
1078
1080
|
let s;
|
1079
1081
|
return function(...a) {
|
1080
1082
|
clearTimeout(s), s = setTimeout(() => {
|
1081
1083
|
t.apply(this, a);
|
1082
1084
|
}, e);
|
1083
1085
|
};
|
1084
|
-
},
|
1086
|
+
}, rn = {
|
1085
1087
|
__name: "admin-custom-button-add",
|
1086
1088
|
props: {
|
1087
1089
|
slots: Object
|
1088
1090
|
},
|
1089
1091
|
setup(t) {
|
1090
|
-
var
|
1091
|
-
const { asyncTemplateSlot: e } = (b = (h = (f = (d = (
|
1092
|
+
var o, d, f, h, b;
|
1093
|
+
const { asyncTemplateSlot: e } = (b = (h = (f = (d = (o = De()) == null ? void 0 : o.appContext) == null ? void 0 : d.app) == null ? void 0 : f.config) == null ? void 0 : h.globalProperties) == null ? void 0 : b.utils, s = B(""), a = t;
|
1092
1094
|
return (() => {
|
1093
|
-
var u, _,
|
1094
|
-
if ((u = a.slots) != null && u.addButton || (s.value = "div"), (
|
1095
|
-
const y = e("addButton", (
|
1095
|
+
var u, _, m, g, w;
|
1096
|
+
if ((u = a.slots) != null && u.addButton || (s.value = "div"), (m = (_ = a.slots) == null ? void 0 : _.addButton) != null && m.includes("<")) {
|
1097
|
+
const y = e("addButton", (g = a.slots) == null ? void 0 : g.addButton, [
|
1096
1098
|
"IconPlus"
|
1097
1099
|
]);
|
1098
1100
|
s.value = y;
|
1099
1101
|
} else
|
1100
|
-
s.value = (
|
1101
|
-
})(), (u, _) => s.value ? (
|
1102
|
+
s.value = (w = a.slots) == null ? void 0 : w.addButton;
|
1103
|
+
})(), (u, _) => s.value ? (r(), k(O(s.value), {
|
1102
1104
|
key: 0,
|
1103
1105
|
IconPlus: N
|
1104
1106
|
})) : v("", !0);
|
1105
1107
|
}
|
1106
1108
|
}, on = {
|
1107
1109
|
key: 0,
|
1108
|
-
class: "px-
|
1109
|
-
}, rn = {
|
1110
|
-
key: 1,
|
1111
|
-
class: "px-3 py-3 text-gray-800 font-[700]"
|
1110
|
+
class: "px-1 py-3 text-gray-800 font-[500]"
|
1112
1111
|
}, an = {
|
1112
|
+
key: 1,
|
1113
|
+
class: "px-1 py-3 text-gray-800 font-[700]"
|
1114
|
+
}, un = {
|
1113
1115
|
__name: "admin-table-totals-list",
|
1114
1116
|
props: {
|
1115
1117
|
columns: { type: Array, default: () => [] },
|
@@ -1117,23 +1119,23 @@ const en = /* @__PURE__ */ w(Gs, [["render", Zs]]), tn = { class: "flex items-ce
|
|
1117
1119
|
} }
|
1118
1120
|
},
|
1119
1121
|
setup(t) {
|
1120
|
-
return (e, s) => (
|
1121
|
-
(
|
1122
|
+
return (e, s) => (r(), i("tr", null, [
|
1123
|
+
(r(!0), i(T, null, V(t.columns, (a) => {
|
1122
1124
|
var n;
|
1123
|
-
return
|
1125
|
+
return r(), i(T, {
|
1124
1126
|
key: a == null ? void 0 : a.name
|
1125
1127
|
}, [
|
1126
|
-
(n = t.agg) != null && n[a == null ? void 0 : a.name] ? (
|
1128
|
+
(n = t.agg) != null && n[a == null ? void 0 : a.name] ? (r(), i("td", on, [
|
1127
1129
|
x(U, {
|
1128
1130
|
column: a,
|
1129
1131
|
row: t.agg
|
1130
1132
|
}, null, 8, ["column", "row"])
|
1131
|
-
])) : (
|
1133
|
+
])) : (r(), i("td", an))
|
1132
1134
|
], 64);
|
1133
1135
|
}), 128))
|
1134
1136
|
]));
|
1135
1137
|
}
|
1136
|
-
},
|
1138
|
+
}, dn = {}, cn = {
|
1137
1139
|
xmlns: "http://www.w3.org/2000/svg",
|
1138
1140
|
viewBox: "0 0 24 24",
|
1139
1141
|
fill: "none",
|
@@ -1143,8 +1145,8 @@ const en = /* @__PURE__ */ w(Gs, [["render", Zs]]), tn = { class: "flex items-ce
|
|
1143
1145
|
"stroke-linejoin": "round",
|
1144
1146
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-chevron-down"
|
1145
1147
|
};
|
1146
|
-
function
|
1147
|
-
return
|
1148
|
+
function pn(t, e, s, a, n, o) {
|
1149
|
+
return r(), i("svg", cn, e[0] || (e[0] = [
|
1148
1150
|
l("path", {
|
1149
1151
|
stroke: "none",
|
1150
1152
|
d: "M0 0h24v24H0z",
|
@@ -1153,7 +1155,7 @@ function cn(t, e, s, a, n, r) {
|
|
1153
1155
|
l("path", { d: "M6 9l6 6l6 -6" }, null, -1)
|
1154
1156
|
]));
|
1155
1157
|
}
|
1156
|
-
const
|
1158
|
+
const hn = /* @__PURE__ */ C(dn, [["render", pn]]), bn = {}, fn = {
|
1157
1159
|
xmlns: "http://www.w3.org/2000/svg",
|
1158
1160
|
viewBox: "0 0 24 24",
|
1159
1161
|
fill: "none",
|
@@ -1163,8 +1165,8 @@ const pn = /* @__PURE__ */ w(un, [["render", cn]]), hn = {}, bn = {
|
|
1163
1165
|
"stroke-linejoin": "round",
|
1164
1166
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-check"
|
1165
1167
|
};
|
1166
|
-
function
|
1167
|
-
return
|
1168
|
+
function gn(t, e, s, a, n, o) {
|
1169
|
+
return r(), i("svg", fn, e[0] || (e[0] = [
|
1168
1170
|
l("path", {
|
1169
1171
|
stroke: "none",
|
1170
1172
|
d: "M0 0h24v24H0z",
|
@@ -1173,8 +1175,8 @@ function fn(t, e, s, a, n, r) {
|
|
1173
1175
|
l("path", { d: "M5 12l5 5l10 -10" }, null, -1)
|
1174
1176
|
]));
|
1175
1177
|
}
|
1176
|
-
const mn = /* @__PURE__ */
|
1177
|
-
components: { IconChevronDown:
|
1178
|
+
const mn = /* @__PURE__ */ C(bn, [["render", gn]]), xn = st({
|
1179
|
+
components: { IconChevronDown: hn, IconCheck: mn },
|
1178
1180
|
props: {
|
1179
1181
|
total: { type: Number, default: () => 0 },
|
1180
1182
|
pageSize: { type: Number, default: () => 20 },
|
@@ -1230,18 +1232,20 @@ const mn = /* @__PURE__ */ w(hn, [["render", fn]]), gn = tt({
|
|
1230
1232
|
this.updatePages(this.page);
|
1231
1233
|
},
|
1232
1234
|
handleSetPage(t) {
|
1233
|
-
|
1235
|
+
const e = t.replace(/\D/g, "");
|
1236
|
+
if (e > this.pagesCount) {
|
1234
1237
|
this.$refs.currentPage.innerText = this.page;
|
1235
1238
|
return;
|
1236
|
-
}
|
1237
|
-
|
1239
|
+
} else
|
1240
|
+
this.$refs.currentPage.innerText = e;
|
1241
|
+
this.setCurrentPage(e);
|
1238
1242
|
},
|
1239
1243
|
updatePages(t) {
|
1240
1244
|
const e = Math.floor(this.maxPages / 2);
|
1241
1245
|
let s = Math.max(t - e, 1), a = s + this.maxPages - 1;
|
1242
1246
|
a > this.pagesCount && (a = this.pagesCount, s = Math.max(a - this.maxPages + 1, 1)), this.pages = Array.from(
|
1243
1247
|
{ length: a - s + 1 },
|
1244
|
-
(n,
|
1248
|
+
(n, o) => s + o
|
1245
1249
|
);
|
1246
1250
|
},
|
1247
1251
|
handleClickPrev() {
|
@@ -1254,13 +1258,13 @@ const mn = /* @__PURE__ */ w(hn, [["render", fn]]), gn = tt({
|
|
1254
1258
|
t < 1 || t > this.pagesCount || this.page === t || (this.page = t, this.$emit("pageChange", this.page, this.pageSizeLocal), this.updatePages(t));
|
1255
1259
|
}
|
1256
1260
|
}
|
1257
|
-
}),
|
1261
|
+
}), yn = { class: "flex items-center w-full" }, kn = { class: "flex items-center mx-[8px]" }, vn = { class: "min-h-[38px] flex justify-center items-center text-stone-500 py-2 px-1.5 text-sm" }, _n = {
|
1258
1262
|
key: 0,
|
1259
1263
|
class: "flex justify-center items-center gap-x-5 ml-3"
|
1260
|
-
},
|
1261
|
-
function
|
1264
|
+
}, wn = { class: "relative" }, Cn = { class: "z-50 bg-white shadow-md rounded-lg p-1 space-y-0.5 dark:bg-neutral-800 dark:border dark:border-neutral-700 dark:divide-neutral-700 absolute bottom-[100%]" }, $n = ["onClick"];
|
1265
|
+
function An(t, e, s, a, n, o) {
|
1262
1266
|
const d = p("IconChevronDown"), f = p("IconCheck");
|
1263
|
-
return
|
1267
|
+
return r(), i("nav", yn, [
|
1264
1268
|
l("button", {
|
1265
1269
|
type: "button",
|
1266
1270
|
onClick: e[0] || (e[0] = (...h) => t.handleClickPrev && t.handleClickPrev(...h)),
|
@@ -1272,15 +1276,15 @@ function $n(t, e, s, a, n, r) {
|
|
1272
1276
|
class: "rotate-90"
|
1273
1277
|
})
|
1274
1278
|
], 2),
|
1275
|
-
l("div",
|
1279
|
+
l("div", kn, [
|
1276
1280
|
l("span", {
|
1277
1281
|
ref: "currentPage",
|
1278
1282
|
contenteditable: "true",
|
1279
1283
|
onBlur: e[1] || (e[1] = (h) => t.handleSetPage(h.target.innerText)),
|
1280
|
-
class: "min-h-[38px] min-w-[38px] flex justify-center items-center bg-stone-100 text-stone-800 py-2 px-3 text-sm rounded-lg disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-700 dark:text-white"
|
1284
|
+
class: "min-h-[38px] max-h-[38px] overflow-hidden min-w-[38px] flex justify-center items-center bg-stone-100 text-stone-800 py-2 px-3 text-sm rounded-lg disabled:opacity-50 disabled:pointer-events-none dark:bg-neutral-700 dark:text-white"
|
1281
1285
|
}, A(t.page), 545),
|
1282
1286
|
e[4] || (e[4] = l("span", { class: "min-h-[38px] flex justify-center items-center text-stone-500 py-2 px-1.5 text-sm" }, "з", -1)),
|
1283
|
-
l("span",
|
1287
|
+
l("span", vn, A(t.pagesCount), 1)
|
1284
1288
|
]),
|
1285
1289
|
l("button", {
|
1286
1290
|
type: "button",
|
@@ -1293,26 +1297,26 @@ function $n(t, e, s, a, n, r) {
|
|
1293
1297
|
class: "-rotate-90"
|
1294
1298
|
})
|
1295
1299
|
], 2),
|
1296
|
-
t.pageSizes.length ? (
|
1297
|
-
l("div",
|
1300
|
+
t.pageSizes.length ? (r(), i("div", _n, [
|
1301
|
+
l("div", wn, [
|
1298
1302
|
M(l("div", Cn, [
|
1299
|
-
(
|
1303
|
+
(r(!0), i(T, null, V(t.pageSizes, (h) => (r(), i("button", {
|
1300
1304
|
type: "button",
|
1301
1305
|
class: "w-full flex items-center gap-x-3.5 py-2 px-3 rounded-lg text-sm",
|
1302
1306
|
onClick: (b) => t.pageSizeLocal = h
|
1303
1307
|
}, [
|
1304
1308
|
j(A(h) + " ", 1),
|
1305
|
-
h === t.pageSizeLocal ? (
|
1309
|
+
h === t.pageSizeLocal ? (r(), k(f, {
|
1306
1310
|
key: 0,
|
1307
1311
|
width: "14",
|
1308
1312
|
height: "14",
|
1309
1313
|
class: "text-blue-600"
|
1310
1314
|
})) : v("", !0)
|
1311
|
-
], 8,
|
1315
|
+
], 8, $n))), 256))
|
1312
1316
|
], 512), [
|
1313
1317
|
[E, t.isDropdownOpen]
|
1314
1318
|
]),
|
1315
|
-
t.pageSizes.length ? (
|
1319
|
+
t.pageSizes.length ? (r(), i("button", {
|
1316
1320
|
key: 0,
|
1317
1321
|
type: "button",
|
1318
1322
|
class: "text-sm h-[32px] min-w-8 py-3 px-3.5 inline-flex items-center gap-x-1 rounded-lg border border-gray-200 text-gray-800 shadow-sm hover:bg-gray-50 focus:outline-none focus:bg-gray-100 disabled:opacity-50 disabled:pointer-events-none dark:border-neutral-700 dark:text-white dark:hover:bg-neutral-700 dark:focus:bg-neutral-700",
|
@@ -1328,26 +1332,26 @@ function $n(t, e, s, a, n, r) {
|
|
1328
1332
|
])) : v("", !0)
|
1329
1333
|
]);
|
1330
1334
|
}
|
1331
|
-
const
|
1335
|
+
const Tn = /* @__PURE__ */ C(xn, [["render", An]]), Sn = {
|
1332
1336
|
props: { table: String, title: String },
|
1333
1337
|
components: {
|
1334
|
-
AdminTableControl:
|
1335
|
-
AdminTableExport:
|
1336
|
-
AdminTableColumnsHidden:
|
1337
|
-
AdminTableColumn:
|
1338
|
+
AdminTableControl: xt,
|
1339
|
+
AdminTableExport: Ut,
|
1340
|
+
AdminTableColumnsHidden: as,
|
1341
|
+
AdminTableColumn: it,
|
1338
1342
|
AdminNodata: Je,
|
1339
1343
|
IconPlus: N,
|
1340
1344
|
IconSearch: Ge,
|
1341
|
-
AdminTableCardInfo:
|
1342
|
-
IconOpenCard:
|
1345
|
+
AdminTableCardInfo: Vs,
|
1346
|
+
IconOpenCard: Fs,
|
1343
1347
|
AdminComponentIs: U,
|
1344
|
-
AdminTableFilters:
|
1345
|
-
AdminTableTabs:
|
1346
|
-
AdminTableCustomFilters:
|
1347
|
-
AdminTableCustomButtons:
|
1348
|
-
AdminCustomButtonAdd:
|
1349
|
-
AdminTableTotalsList:
|
1350
|
-
AdminTablePagination:
|
1348
|
+
AdminTableFilters: Bs,
|
1349
|
+
AdminTableTabs: Hs,
|
1350
|
+
AdminTableCustomFilters: tn,
|
1351
|
+
AdminTableCustomButtons: nn,
|
1352
|
+
AdminCustomButtonAdd: rn,
|
1353
|
+
AdminTableTotalsList: un,
|
1354
|
+
AdminTablePagination: Tn
|
1351
1355
|
},
|
1352
1356
|
data() {
|
1353
1357
|
return {
|
@@ -1403,7 +1407,7 @@ const An = /* @__PURE__ */ w(gn, [["render", $n]]), Tn = {
|
|
1403
1407
|
this.tableData = null, await this.getTableData();
|
1404
1408
|
},
|
1405
1409
|
searchValue: {
|
1406
|
-
handler:
|
1410
|
+
handler: ln(async function(t) {
|
1407
1411
|
var e;
|
1408
1412
|
await this.getTableData(), this.$router.push({
|
1409
1413
|
...this.$route,
|
@@ -1438,7 +1442,7 @@ const An = /* @__PURE__ */ w(gn, [["render", $n]]), Tn = {
|
|
1438
1442
|
},
|
1439
1443
|
columns(t) {
|
1440
1444
|
var e, s, a, n;
|
1441
|
-
this.visibleColumns = t == null ? void 0 : t.map((
|
1445
|
+
this.visibleColumns = t == null ? void 0 : t.map((o) => o == null ? void 0 : o.name), this.initialHiddenColumns === ((e = this.visibleColumns) == null ? void 0 : e.join(",")) && (this.visibleColumns = []), this.$router.replace({
|
1442
1446
|
...this.$route,
|
1443
1447
|
query: {
|
1444
1448
|
...(s = this.$route) == null ? void 0 : s.query,
|
@@ -1449,8 +1453,8 @@ const An = /* @__PURE__ */ w(gn, [["render", $n]]), Tn = {
|
|
1449
1453
|
},
|
1450
1454
|
methods: {
|
1451
1455
|
async checkUrlMounted() {
|
1452
|
-
var t, e, s, a, n,
|
1453
|
-
this.page = ((e = (t = this.$route) == null ? void 0 : t.query) == null ? void 0 : e.page) || 1, this.limit = ((a = (s = this.$route) == null ? void 0 : s.query) == null ? void 0 : a.limit) || 20, this.filters = ((d = decodeURI((
|
1456
|
+
var t, e, s, a, n, o, d, f, h, b, u, _, m, g, w, y, $;
|
1457
|
+
this.page = ((e = (t = this.$route) == null ? void 0 : t.query) == null ? void 0 : e.page) || 1, this.limit = ((a = (s = this.$route) == null ? void 0 : s.query) == null ? void 0 : a.limit) || 20, this.filters = ((d = decodeURI((o = (n = this.$route) == null ? void 0 : n.query) == null ? void 0 : o.filter)) == null ? void 0 : d.replaceAll("+", " ")) || null, this.filterState = ((h = (f = this.$route) == null ? void 0 : f.query) == null ? void 0 : h.filterState) || null, this.filterCustom = ((u = (b = this.$route) == null ? void 0 : b.query) == null ? void 0 : u.custom) || null, this.searchValue = ((m = (_ = this.$route) == null ? void 0 : _.query) == null ? void 0 : m.search) || "", this.visibleColumns = ((y = (w = (g = this.$route) == null ? void 0 : g.query) == null ? void 0 : w.columns) == null ? void 0 : y.split(",")) || [], ($ = this.$route) != null && $.query.card && (this.isVisibleCardInfo = !0);
|
1454
1458
|
},
|
1455
1459
|
rowWidth(t) {
|
1456
1460
|
var s, a;
|
@@ -1464,9 +1468,9 @@ const An = /* @__PURE__ */ w(gn, [["render", $n]]), Tn = {
|
|
1464
1468
|
this.page = 1, this.visibleColumns = [], this.filterCustom = null, this.filterState = null, this.isVisibleCardInfo = !1, this.filterScheme = null, this.filters = null, this.onFilters = 0, this.searchValue = "";
|
1465
1469
|
},
|
1466
1470
|
async getTableData() {
|
1467
|
-
var t, e, s, a, n,
|
1471
|
+
var t, e, s, a, n, o, d, f, h, b, u;
|
1468
1472
|
try {
|
1469
|
-
const { data: _ } = await F.get(`/api/template/table/${this.table}`),
|
1473
|
+
const { data: _ } = await F.get(`/api/template/table/${this.table}`), m = await F.get(`/api/table-data/${this.table}`, {
|
1470
1474
|
params: {
|
1471
1475
|
page: this.page,
|
1472
1476
|
search: this.searchValue || null,
|
@@ -1479,11 +1483,11 @@ const An = /* @__PURE__ */ w(gn, [["render", $n]]), Tn = {
|
|
1479
1483
|
});
|
1480
1484
|
this.tableData = {
|
1481
1485
|
..._,
|
1482
|
-
...(
|
1483
|
-
}, this.initialHiddenColumns = (
|
1484
|
-
var
|
1485
|
-
(
|
1486
|
-
}) : this.visibleColumns = (u = (b = (h = this.tableData) == null ? void 0 : h.columns) == null ? void 0 : b.filter((
|
1486
|
+
...(m == null ? void 0 : m.data) || {}
|
1487
|
+
}, this.initialHiddenColumns = (o = (n = (a = (s = this.tableData) == null ? void 0 : s.columns) == null ? void 0 : a.filter((g) => (g == null ? void 0 : g.hidden) !== !0)) == null ? void 0 : n.map((g) => g == null ? void 0 : g.name)) == null ? void 0 : o.join(","), (d = this.visibleColumns) != null && d.length ? (f = this.tableData) == null || f.columns.forEach((g) => {
|
1488
|
+
var w;
|
1489
|
+
(w = this.visibleColumns) != null && w.includes(g == null ? void 0 : g.name) ? g.hidden = !1 : g.hidden = !0;
|
1490
|
+
}) : this.visibleColumns = (u = (b = (h = this.tableData) == null ? void 0 : h.columns) == null ? void 0 : b.filter((g) => (g == null ? void 0 : g.hidden) !== !0)) == null ? void 0 : u.map((g) => g == null ? void 0 : g.name);
|
1487
1491
|
} catch {
|
1488
1492
|
}
|
1489
1493
|
},
|
@@ -1531,30 +1535,30 @@ const An = /* @__PURE__ */ w(gn, [["render", $n]]), Tn = {
|
|
1531
1535
|
});
|
1532
1536
|
}
|
1533
1537
|
}
|
1534
|
-
},
|
1538
|
+
}, In = { class: "w-[calc(100vw - 320px)] bg-gray-50" }, Vn = { class: "h-[76px] mt-[15px] flex items-center justify-between mx-[20px] px-[20px] bg-white border rounded-xl" }, Dn = { class: "text-lg font-semibold text-gray-800 dark:text-neutral-200" }, Pn = {
|
1535
1539
|
style: { height: "calc(100vh - 155px)" },
|
1536
1540
|
class: "bg-gray-50 p-[20px] flex pt-[10px] lg:w-[calc(100vw-260px)] w-[100vw]"
|
1537
|
-
},
|
1541
|
+
}, jn = { class: "bg-white w-full rounded-xl border p-[20px] pr-0" }, Fn = { class: "flex" }, Mn = { class: "flex gap-[6px] ml-auto" }, Ln = { class: "inline-block w-full align-middle" }, zn = {
|
1538
1542
|
key: 0,
|
1539
1543
|
class: "relative min-w-full text-[13px] divide-y divide-gray-200 table-fixed w-max dark:divide-neutral-700"
|
1540
|
-
},
|
1544
|
+
}, qn = { class: "sticky top-[-1px] z-[2] bg-white w-full after:absolute after:content-[''] after:block after:w-full after:h-px after:bg-stone-200" }, Bn = { class: "right-0" }, On = {
|
1541
1545
|
key: 0,
|
1542
1546
|
class: "w-[70px] sticky right-0 top-0"
|
1543
|
-
},
|
1547
|
+
}, Nn = { class: "divide-y divide-gray-200 z-[1] relative" }, Un = { class: "px-1 py-3 text-gray-600 pe-4" }, En = ["onClick"], Hn = ["onClick"], Rn = { class: "p-[10px] flex justify-start items-center w-full" }, Wn = { class: "w-[200px] md:inline-flex hidden" }, Jn = { class: "text-sm text-gray-600 dark:text-neutral-400" }, Gn = { class: "font-semibold text-gray-800 dark:text-neutral-200" }, Kn = { key: 0 }, Qn = {
|
1544
1548
|
key: 0,
|
1545
1549
|
class: "font-semibold text-gray-800 dark:text-neutral-200"
|
1546
1550
|
};
|
1547
|
-
function
|
1548
|
-
var H, R, W, J, G, K, Q, X, Y, Z, ee, te, se, ne, le,
|
1549
|
-
const d = p("AdminCustomButtonAdd"), f = p("IconPlus"), h = p("router-link"), b = p("AdminTableTabs"), u = p("IconSearch"), _ = p("VsText"),
|
1550
|
-
return
|
1551
|
-
l("div",
|
1552
|
-
l("h2",
|
1553
|
-
|
1554
|
-
(R = (H = n.tableData) == null ? void 0 : H.slots) != null && R.addButton ? (
|
1551
|
+
function Xn(t, e, s, a, n, o) {
|
1552
|
+
var H, R, W, J, G, K, Q, X, Y, Z, ee, te, se, ne, le, re, oe, ae, ie, ue, de, ce, pe, he, be, fe, ge;
|
1553
|
+
const d = p("AdminCustomButtonAdd"), f = p("IconPlus"), h = p("router-link"), b = p("AdminTableTabs"), u = p("IconSearch"), _ = p("VsText"), m = p("AdminTableCustomButtons"), g = p("AdminTableCustomFilters"), w = p("AdminTableColumnsHidden"), y = p("AdminTableExport"), $ = p("AdminTableFilters"), D = p("IconOpenCard"), z = p("AdminTableColumn"), q = p("AdminComponentIs"), Pe = p("AdminTableControl"), je = p("AdminTableTotalsList"), Fe = p("AdminNodata"), Me = p("AdminTablePagination"), Le = p("AdminTableCardInfo");
|
1554
|
+
return r(), i("div", In, [
|
1555
|
+
l("div", Vn, [
|
1556
|
+
l("h2", Dn, A(s.title), 1),
|
1557
|
+
o.isForm ? (r(), i(T, { key: 0 }, [
|
1558
|
+
(R = (H = n.tableData) == null ? void 0 : H.slots) != null && R.addButton ? (r(), k(d, {
|
1555
1559
|
key: 0,
|
1556
1560
|
slots: (W = n.tableData) == null ? void 0 : W.slots
|
1557
|
-
}, null, 8, ["slots"])) : (
|
1561
|
+
}, null, 8, ["slots"])) : (r(), k(h, {
|
1558
1562
|
key: 1,
|
1559
1563
|
to: `/add?table=${(G = (J = t.$route) == null ? void 0 : J.params) == null ? void 0 : G.catchAll}`,
|
1560
1564
|
class: "inline-flex items-center px-3 py-2 text-sm font-medium text-white duration-300 bg-blue-600 border border-transparent rounded-lg gap-x-2 hover:bg-blue-700 hover:text-white"
|
@@ -1570,15 +1574,15 @@ function Qn(t, e, s, a, n, r) {
|
|
1570
1574
|
}, 8, ["to"]))
|
1571
1575
|
], 64)) : v("", !0)
|
1572
1576
|
]),
|
1573
|
-
l("div",
|
1574
|
-
l("div",
|
1575
|
-
(Q = (K = n.tableData) == null ? void 0 : K.filterState) != null && Q.length ? (
|
1577
|
+
l("div", Pn, [
|
1578
|
+
l("div", jn, [
|
1579
|
+
(Q = (K = n.tableData) == null ? void 0 : K.filterState) != null && Q.length ? (r(), k(b, {
|
1576
1580
|
key: 0,
|
1577
1581
|
tabsList: (X = n.tableData) == null ? void 0 : X.filterState,
|
1578
1582
|
filterState: n.filterState,
|
1579
1583
|
"onUpdate:filterState": e[0] || (e[0] = (c) => n.filterState = c)
|
1580
1584
|
}, null, 8, ["tabsList", "filterState"])) : v("", !0),
|
1581
|
-
l("div",
|
1585
|
+
l("div", Fn, [
|
1582
1586
|
l("div", {
|
1583
1587
|
class: I([n.isVisibleCardInfo ? "w-[calc(100%-360px)]" : "w-full"])
|
1584
1588
|
}, [
|
@@ -1597,39 +1601,39 @@ function Qn(t, e, s, a, n, r) {
|
|
1597
1601
|
clearable: !0,
|
1598
1602
|
class: "[&>input]:py-[7px] [&>input]:max-h-[36px] [&>input]:ps-10 [&>input]:pe-8 [&>input]:block [&>input]:w-full [&>input]:bg-gray-100 [&>input]:border-transparent [&>input]:rounded-lg [&>input]:text-sm [&>input]:focus:bg-white [&>input]:focus:border-blue-500 [&>input]:focus:ring-blue-500 [&>input]:disabled:opacity-50 [&>input]:disabled:pointer-events-none [&>input]:dark:bg-neutral-700 [&>input]:dark:border-transparent [&>input]:dark:text-neutral-400 [&>input]:dark:placeholder:text-neutral-400 dark:focus:bg-neutral-800 dark:focus:ring-neutral-600"
|
1599
1603
|
}, null, 8, ["modelValue"]),
|
1600
|
-
l("div",
|
1601
|
-
(Y = n.tableData) != null && Y.slots ? (
|
1604
|
+
l("div", Mn, [
|
1605
|
+
(Y = n.tableData) != null && Y.slots ? (r(), k(m, {
|
1602
1606
|
key: 0,
|
1603
1607
|
slots: (Z = n.tableData) == null ? void 0 : Z.slots
|
1604
1608
|
}, null, 8, ["slots"])) : v("", !0),
|
1605
|
-
(te = (ee = n.tableData) == null ? void 0 : ee.filterCustom) != null && te.length ? (
|
1609
|
+
(te = (ee = n.tableData) == null ? void 0 : ee.filterCustom) != null && te.length ? (r(), k(g, {
|
1606
1610
|
key: 1,
|
1607
1611
|
customList: (se = n.tableData) == null ? void 0 : se.filterCustom,
|
1608
1612
|
filterCustom: n.filterCustom,
|
1609
1613
|
"onUpdate:filterCustom": e[2] || (e[2] = (c) => n.filterCustom = c)
|
1610
1614
|
}, null, 8, ["customList", "filterCustom"])) : v("", !0),
|
1611
|
-
x(
|
1615
|
+
x(w, {
|
1612
1616
|
columns: (ne = n.tableData) == null ? void 0 : ne.columns,
|
1613
1617
|
onUpdateColumns: e[3] || (e[3] = (c) => n.tableData.columns = c)
|
1614
1618
|
}, null, 8, ["columns"]),
|
1615
|
-
((le = n.tableData) == null ? void 0 : le.export) !== !1 ? (
|
1619
|
+
((le = n.tableData) == null ? void 0 : le.export) !== !1 ? (r(), k(y, {
|
1616
1620
|
key: 2,
|
1617
1621
|
table: s.table,
|
1618
|
-
columns: (
|
1622
|
+
columns: (re = n.tableData) == null ? void 0 : re.columns,
|
1619
1623
|
page: n.page,
|
1620
1624
|
"filter-state": n.filterState,
|
1621
1625
|
"filter-custom": n.filterCustom,
|
1622
1626
|
filters: n.filters
|
1623
1627
|
}, null, 8, ["table", "columns", "page", "filter-state", "filter-custom", "filters"])) : v("", !0),
|
1624
|
-
(
|
1628
|
+
(oe = n.filterScheme) != null && oe.length ? (r(), k($, {
|
1625
1629
|
key: 3,
|
1626
1630
|
scheme: n.filterScheme,
|
1627
1631
|
onFilters: n.onFilters,
|
1628
1632
|
table: s.table,
|
1629
|
-
onFilterChange:
|
1633
|
+
onFilterChange: o.filterChange
|
1630
1634
|
}, null, 8, ["scheme", "onFilters", "table", "onFilterChange"])) : v("", !0),
|
1631
1635
|
l("button", {
|
1632
|
-
onClick: e[4] || (e[4] = (...c) =>
|
1636
|
+
onClick: e[4] || (e[4] = (...c) => o.toggleCardInfo && o.toggleCardInfo(...c)),
|
1633
1637
|
class: "py-2 px-2.5 max-h-[34px] md:inline-flex hidden items-center gap-x-1.5 text-xs font-medium rounded-lg border border-gray-200 bg-white text-gray-800 shadow-sm hover:bg-gray-50 disabled:opacity-50 disabled:pointer-events-none focus:outline-none focus:bg-gray-50 dark:bg-neutral-800 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-700 dark:focus:bg-neutral-700"
|
1634
1638
|
}, [
|
1635
1639
|
x(D, {
|
@@ -1647,56 +1651,56 @@ function Qn(t, e, s, a, n, r) {
|
|
1647
1651
|
}),
|
1648
1652
|
class: "overflow-x-auto w-full [&::-webkit-scrollbar]:h-2 [&::-webkit-scrollbar]:w-2 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-track]:bg-stone-100 [&::-webkit-scrollbar-thumb]:bg-stone-300 dark:[&::-webkit-scrollbar-track]:bg-neutral-700 dark:[&::-webkit-scrollbar-thumb]:bg-neutral-500"
|
1649
1653
|
}, [
|
1650
|
-
l("div",
|
1651
|
-
|
1652
|
-
l("thead",
|
1653
|
-
l("tr",
|
1654
|
-
(
|
1654
|
+
l("div", Ln, [
|
1655
|
+
o.isNoData ? (r(), k(Fe, { key: 1 })) : (r(), i("table", zn, [
|
1656
|
+
l("thead", qn, [
|
1657
|
+
l("tr", Bn, [
|
1658
|
+
(r(!0), i(T, null, V(o.columns, (c) => (r(), k(z, {
|
1655
1659
|
key: c.name,
|
1656
1660
|
style: Ie({
|
1657
|
-
width:
|
1661
|
+
width: o.rowWidth(c == null ? void 0 : c.name),
|
1658
1662
|
textAlign: c == null ? void 0 : c.align,
|
1659
1663
|
wordBreak: c == null ? void 0 : c.wrap
|
1660
1664
|
}),
|
1661
1665
|
data: c,
|
1662
1666
|
activeColumn: n.activeColumn,
|
1663
|
-
onChangeActive:
|
1667
|
+
onChangeActive: o.changeActiveColumn
|
1664
1668
|
}, null, 8, ["style", "data", "activeColumn", "onChangeActive"]))), 128)),
|
1665
|
-
(de = (ue =
|
1669
|
+
(de = (ue = o.getActions) == null ? void 0 : ue.filter(
|
1666
1670
|
(c) => c !== "add" && c !== "view"
|
1667
|
-
)) != null && de.length ? (
|
1671
|
+
)) != null && de.length ? (r(), i("th", On)) : v("", !0)
|
1668
1672
|
])
|
1669
1673
|
]),
|
1670
|
-
l("tbody",
|
1671
|
-
(
|
1672
|
-
var
|
1673
|
-
return
|
1674
|
+
l("tbody", Nn, [
|
1675
|
+
(r(!0), i(T, null, V((ce = n.tableData) == null ? void 0 : ce.rows, (c, ze) => {
|
1676
|
+
var me, xe, ye, ke, ve, _e, we, Ce, $e, Ae, Te;
|
1677
|
+
return r(), i("tr", {
|
1674
1678
|
key: (c == null ? void 0 : c.id) || ze,
|
1675
1679
|
class: I({
|
1676
|
-
"bg-gray-50": ((xe = (
|
1680
|
+
"bg-gray-50": ((xe = (me = t.$route) == null ? void 0 : me.query) == null ? void 0 : xe.card) === (c == null ? void 0 : c.id)
|
1677
1681
|
})
|
1678
1682
|
}, [
|
1679
|
-
l("td",
|
1683
|
+
l("td", Un, [
|
1680
1684
|
l("button", {
|
1681
1685
|
onClick: (P) => {
|
1682
|
-
|
1686
|
+
o.pushToCard(c == null ? void 0 : c.id), o.pushToLinkCard(o.columns[0], c);
|
1683
1687
|
},
|
1684
1688
|
class: I(["font-medium", [
|
1685
1689
|
((ye = n.tableData) == null ? void 0 : ye.card) === !1 ? "" : "text-blue-600 decoration-2 focus:outline-none focus:underline hover:text-blue-600 hover:underline",
|
1686
|
-
(ke =
|
1690
|
+
(ke = o.columns[0]) != null && ke.link ? "text-blue-600 hover:underline decoration-2" : ""
|
1687
1691
|
]])
|
1688
1692
|
}, [
|
1689
1693
|
x(q, {
|
1690
1694
|
row: c,
|
1691
|
-
column:
|
1695
|
+
column: o.columns[0],
|
1692
1696
|
table: s.table,
|
1693
|
-
onUpdateTable:
|
1697
|
+
onUpdateTable: o.getTableData
|
1694
1698
|
}, null, 8, ["row", "column", "table", "onUpdateTable"])
|
1695
|
-
], 10,
|
1699
|
+
], 10, En)
|
1696
1700
|
]),
|
1697
|
-
(
|
1698
|
-
onClick: (
|
1699
|
-
|
1701
|
+
(r(!0), i(T, null, V((ve = o.columns) == null ? void 0 : ve.slice(1), (P) => (r(), i("td", {
|
1702
|
+
onClick: (sl) => {
|
1703
|
+
o.changeActiveCardInfo(c == null ? void 0 : c.id), o.pushToLinkCard(P, c);
|
1700
1704
|
},
|
1701
1705
|
class: I(["px-1 py-3 text-gray-600 pe-3 text-start", {
|
1702
1706
|
"cursor-pointer": n.isVisibleCardInfo,
|
@@ -1708,53 +1712,53 @@ function Qn(t, e, s, a, n, r) {
|
|
1708
1712
|
row: c,
|
1709
1713
|
column: P,
|
1710
1714
|
table: s.table,
|
1711
|
-
onUpdateTable:
|
1715
|
+
onUpdateTable: o.getTableData
|
1712
1716
|
}, null, 8, ["row", "column", "table", "onUpdateTable"])
|
1713
|
-
], 10,
|
1714
|
-
(
|
1717
|
+
], 10, Hn))), 128)),
|
1718
|
+
(we = (_e = o.getActions) == null ? void 0 : _e.filter(
|
1715
1719
|
(P) => P !== "add" && P !== "view"
|
1716
|
-
)) != null &&
|
1720
|
+
)) != null && we.length ? (r(), i("td", {
|
1717
1721
|
key: 0,
|
1718
1722
|
class: I(["text-center sticky right-0 w-[80px] px-[10px]", {
|
1719
|
-
"bg-gray-50": (($e = (
|
1723
|
+
"bg-gray-50": (($e = (Ce = t.$route) == null ? void 0 : Ce.query) == null ? void 0 : $e.card) === (c == null ? void 0 : c.id),
|
1720
1724
|
"bg-white": ((Te = (Ae = t.$route) == null ? void 0 : Ae.query) == null ? void 0 : Te.card) !== (c == null ? void 0 : c.id)
|
1721
1725
|
}])
|
1722
1726
|
}, [
|
1723
1727
|
x(Pe, {
|
1724
|
-
actions:
|
1725
|
-
isForm:
|
1728
|
+
actions: o.getActions,
|
1729
|
+
isForm: o.isForm,
|
1726
1730
|
item: c,
|
1727
1731
|
table: s.table,
|
1728
|
-
onUpdateTable:
|
1732
|
+
onUpdateTable: o.getTableData
|
1729
1733
|
}, null, 8, ["actions", "isForm", "item", "table", "onUpdateTable"])
|
1730
1734
|
], 2)) : v("", !0)
|
1731
1735
|
], 2);
|
1732
1736
|
}), 128))
|
1733
1737
|
]),
|
1734
1738
|
x(je, {
|
1735
|
-
columns:
|
1739
|
+
columns: o.columns,
|
1736
1740
|
agg: (pe = n.tableData) == null ? void 0 : pe.agg
|
1737
1741
|
}, null, 8, ["columns", "agg"])
|
1738
1742
|
]))
|
1739
1743
|
])
|
1740
1744
|
], 4)
|
1741
1745
|
], 2),
|
1742
|
-
l("div",
|
1743
|
-
l("div",
|
1744
|
-
l("p",
|
1745
|
-
l("span",
|
1746
|
+
l("div", Rn, [
|
1747
|
+
l("div", Wn, [
|
1748
|
+
l("p", Jn, [
|
1749
|
+
l("span", Gn, [
|
1746
1750
|
j(A(n.filters || n.searchValue ? "Знайдено" : "Об'єктів") + " " + A(((he = n.tableData) == null ? void 0 : he.count) || "0 ") + " ", 1),
|
1747
|
-
n.filters || n.searchValue ? (
|
1751
|
+
n.filters || n.searchValue ? (r(), i("span", Kn, " з")) : v("", !0)
|
1748
1752
|
]),
|
1749
|
-
n.filters || n.searchValue ? (
|
1753
|
+
n.filters || n.searchValue ? (r(), i("span", Qn, A(" " + ((be = n.tableData) == null ? void 0 : be.filtered) || 0), 1)) : v("", !0)
|
1750
1754
|
])
|
1751
1755
|
]),
|
1752
|
-
Math.ceil(((fe = n.tableData) == null ? void 0 : fe.filtered) / n.limit) > 1 ? (
|
1756
|
+
Math.ceil(((fe = n.tableData) == null ? void 0 : fe.filtered) / n.limit) > 1 ? (r(), k(Me, {
|
1753
1757
|
key: 0,
|
1754
1758
|
class: "justify-end",
|
1755
|
-
"default-page": parseInt(
|
1756
|
-
total: ((
|
1757
|
-
onPageChange:
|
1759
|
+
"default-page": parseInt(o.defaultPage),
|
1760
|
+
total: ((ge = n.tableData) == null ? void 0 : ge.filtered) || 0,
|
1761
|
+
onPageChange: o.handlePageChange,
|
1758
1762
|
pageSize: parseInt(n.limit),
|
1759
1763
|
pageSizes: [10, 16, 20]
|
1760
1764
|
}, null, 8, ["default-page", "total", "onPageChange", "pageSize"])) : v("", !0)
|
@@ -1764,11 +1768,11 @@ function Qn(t, e, s, a, n, r) {
|
|
1764
1768
|
default: S(() => {
|
1765
1769
|
var c;
|
1766
1770
|
return [
|
1767
|
-
n.isVisibleCardInfo ? (
|
1771
|
+
n.isVisibleCardInfo ? (r(), k(Le, {
|
1768
1772
|
key: 0,
|
1769
1773
|
table: s.table,
|
1770
1774
|
columns: (c = n.tableData) == null ? void 0 : c.columns,
|
1771
|
-
row:
|
1775
|
+
row: o.activeCardRow
|
1772
1776
|
}, null, 8, ["table", "columns", "row"])) : v("", !0)
|
1773
1777
|
];
|
1774
1778
|
}),
|
@@ -1779,8 +1783,8 @@ function Qn(t, e, s, a, n, r) {
|
|
1779
1783
|
])
|
1780
1784
|
]);
|
1781
1785
|
}
|
1782
|
-
const
|
1783
|
-
components: { AdminTable:
|
1786
|
+
const Yn = /* @__PURE__ */ C(Sn, [["render", Xn], ["__scopeId", "data-v-df0b453f"]]), Zn = {
|
1787
|
+
components: { AdminTable: Yn },
|
1784
1788
|
data() {
|
1785
1789
|
return {
|
1786
1790
|
table: !1,
|
@@ -1815,9 +1819,9 @@ const Xn = /* @__PURE__ */ w(Tn, [["render", Qn], ["__scopeId", "data-v-e9573b35
|
|
1815
1819
|
var a, n;
|
1816
1820
|
const t = this.flattenMenu(Se.value);
|
1817
1821
|
t != null && t.length || this.$router.replace("/404");
|
1818
|
-
const e = t == null ? void 0 : t.find((
|
1822
|
+
const e = t == null ? void 0 : t.find((o) => {
|
1819
1823
|
var d, f;
|
1820
|
-
return (
|
1824
|
+
return (o == null ? void 0 : o.path) == ((f = (d = this.$route) == null ? void 0 : d.params) == null ? void 0 : f.catchAll);
|
1821
1825
|
});
|
1822
1826
|
this.title = e == null ? void 0 : e.ua, e || this.$router.replace("/404"), e != null && e.component && this.$router.replace((n = (a = this.$route) == null ? void 0 : a.params) == null ? void 0 : n.catchAll);
|
1823
1827
|
const s = e == null ? void 0 : e.table;
|
@@ -1835,21 +1839,21 @@ const Xn = /* @__PURE__ */ w(Tn, [["render", Qn], ["__scopeId", "data-v-e9573b35
|
|
1835
1839
|
}
|
1836
1840
|
}
|
1837
1841
|
}
|
1838
|
-
},
|
1839
|
-
function
|
1842
|
+
}, el = ["innerHTML"];
|
1843
|
+
function tl(t, e, s, a, n, o) {
|
1840
1844
|
const d = p("AdminTable");
|
1841
|
-
return n.table ? (
|
1845
|
+
return n.table ? (r(), k(d, {
|
1842
1846
|
key: 0,
|
1843
1847
|
table: n.table,
|
1844
1848
|
title: n.title
|
1845
|
-
}, null, 8, ["table", "title"])) : (
|
1849
|
+
}, null, 8, ["table", "title"])) : (r(), i("div", {
|
1846
1850
|
key: 1,
|
1847
1851
|
class: "w-full bg-gray-50",
|
1848
1852
|
style: { height: "calc(100vh - 120px)" },
|
1849
1853
|
innerHTML: n.interface
|
1850
|
-
}, null, 8,
|
1854
|
+
}, null, 8, el));
|
1851
1855
|
}
|
1852
|
-
const
|
1856
|
+
const rl = /* @__PURE__ */ C(Zn, [["render", tl]]);
|
1853
1857
|
export {
|
1854
|
-
|
1858
|
+
rl as default
|
1855
1859
|
};
|