@opengis/admin 0.1.30 → 0.1.32
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/README.md +29 -29
- package/config.js +4 -4
- package/dist/{IconSearch-D9I5Aq9M.js → IconSearch-CxDTYG1J.js} +1 -1
- package/dist/{add-page-DlCRMnx_.js → add-page-D_Fg9HXW.js} +1 -1
- package/dist/{admin-interface-96V27WHl.js → admin-interface-BRAtve0X.js} +173 -169
- package/dist/{admin-view-D-4XxCw7.js → admin-view-DEPFLjx8.js} +3 -3
- package/dist/admin.js +1 -1
- package/dist/admin.umd.cjs +202 -90
- package/dist/{card-page-DQlo1_B4.js → card-page-DBDmzwDl.js} +2 -2
- package/dist/{card-view-oRDd-qea.js → card-view-BqFARR8P.js} +1 -1
- package/dist/{edit-page-q-vG6Aun.js → edit-page-DxYGPaLO.js} +1 -1
- package/dist/import-file-BtyRoYT7.js +46488 -0
- package/dist/style.css +1 -1
- package/module/settings/card/admin.roles.table/access.hbs +27 -27
- package/module/settings/card/admin.roles.table/general_info.hbs +16 -16
- package/module/settings/card/admin.roles.table/index.yml +14 -14
- package/module/settings/card/admin.roles.table/users.hbs +27 -27
- package/module/settings/card/admin.routes.table/general_info.hbs +40 -40
- package/module/settings/card/admin.routes.table/index.yml +8 -8
- package/module/settings/card/admin.routes.table/users.hbs +33 -33
- package/module/settings/card/admin.users.table/general_info.hbs +25 -25
- package/module/settings/card/admin.users.table/index.yml +12 -12
- package/module/settings/card/admin.users.table/logs.hbs +30 -30
- package/module/settings/card/admin.users.table/user_roles.hbs +24 -24
- package/module/settings/cls/core.actions.json +13 -13
- package/module/settings/cls/core.scope.json +13 -13
- package/module/settings/cls/properties.site_status.json +13 -13
- package/module/settings/cls/properties.widget_status.json +13 -13
- package/module/settings/cls/users.user_type.json +13 -13
- package/module/settings/form/admin.access.form.json +36 -36
- package/module/settings/form/admin.properties.form.json +15 -15
- package/module/settings/form/admin.roles.form.json +19 -19
- package/module/settings/form/admin.routes.form.json +25 -25
- package/module/settings/form/admin.user_properties.form.json +15 -15
- package/module/settings/form/admin.user_roles.form.json +21 -21
- package/module/settings/form/admin.users.form.json +150 -150
- package/module/settings/form/user.user_roles.form.json +13 -13
- package/module/settings/interface/admin.properties.json +4 -4
- package/module/settings/interface/admin.roles.json +4 -4
- package/module/settings/interface/admin.routes.json +4 -4
- package/module/settings/interface/admin.users.json +4 -4
- package/module/settings/menu.json +39 -45
- package/module/settings/select/core.roles.json +2 -2
- package/module/settings/select/core.user_uid.sql +1 -1
- package/module/settings/table/admin.access.table.json +77 -77
- package/module/settings/table/admin.properties.table.json +33 -33
- package/module/settings/table/admin.roles.table.json +58 -58
- package/module/settings/table/admin.routes.table.json +55 -55
- package/module/settings/table/admin.user_properties.table.json +28 -29
- package/module/settings/table/admin.user_roles.table.json +66 -66
- package/module/settings/table/admin.users.table.json +119 -119
- package/package.json +74 -67
- package/plugin.js +102 -102
- package/server/helpers/controllers/badge.js +11 -11
- package/server/helpers/controllers/hb.js +2 -2
- package/server/helpers/controllers/map.js +2 -2
- package/server/helpers/controllers/mls.js +2 -2
- package/server/helpers/controllers/vue.js +2 -2
- package/server/helpers/index.mjs +13 -13
- package/server/plugins/docs.js +28 -28
- package/server/plugins/hook.js +166 -166
- package/server/plugins/vite.js +69 -69
- package/server/routes/data/controllers/cardData.js +56 -56
- package/server/routes/data/controllers/cardTabData.js +39 -39
- package/server/routes/data/controllers/funcs/getFilterSQL/index.js +85 -85
- package/server/routes/data/controllers/funcs/getFilterSQL/util/formatValue.js +142 -142
- package/server/routes/data/controllers/funcs/getFilterSQL/util/getCustomQuery.js +13 -13
- package/server/routes/data/controllers/funcs/getFilterSQL/util/getFilterQuery.js +67 -67
- package/server/routes/data/controllers/funcs/getFilterSQL/util/getOptimizedQuery.js +12 -12
- package/server/routes/data/controllers/funcs/getFilterSQL/util/getTableSql.js +34 -34
- package/server/routes/data/controllers/tableData.js +121 -121
- package/server/routes/data/controllers/tableDataId.js +27 -27
- package/server/routes/data/controllers/tableFilter.js +54 -54
- package/server/routes/data/controllers/utils/assignTokens.js +30 -30
- package/server/routes/data/controllers/utils/getColumns.js +21 -21
- package/server/routes/data/index.mjs +12 -12
- package/server/routes/menu/controllers/getMenu.js +33 -33
- package/server/routes/menu/index.mjs +5 -5
- package/server/routes/properties/controllers/admin.properties.get.js +29 -29
- package/server/routes/properties/controllers/user.properties.get.js +34 -34
- package/server/routes/properties/controllers/user.properties.post.js +30 -30
- package/server/routes/properties/funcs/getSettings.js +56 -56
- package/server/routes/properties/funcs/setSettings.js +44 -44
- package/server/routes/properties/funcs/utils/dataInsert.js +26 -26
- package/server/routes/properties/index.mjs +26 -26
- package/server/routes/root.mjs +3 -3
- package/server/routes/templates/controllers/getTemplate.js +14 -14
- package/server/routes/templates/index.mjs +14 -14
- package/server/templates/cls/itree.recrzone_category.json +73 -73
- package/server/templates/cls/test.json +9 -9
- package/server/templates/form/admin.user_cls.data.form.json +49 -49
- package/server/templates/form/admin.user_group_rel.form.json +21 -21
- package/server/templates/form/cp_building.form.json +32 -32
- package/server/templates/form/form-user-pass.json +10 -10
- package/server/templates/form/form-user_group.json +39 -39
- package/server/templates/form/form-users.json +156 -156
- package/server/templates/form/user_group_access.form.json +22 -22
- package/server/templates/select/account_id.json +2 -2
- package/server/templates/table/gis.dataset.table.json +43 -43
- package/server/templates/table/management.user_group.table.json +112 -112
- package/server/templates/table/management.users.table.json +126 -126
- package/utils.js +8 -8
- package/dist/import-file-BsZhLoDU.js +0 -30438
- package/module/settings/form/admin.user_properties.entity.form.json +0 -71
- package/module/settings/table/admin.user_properties.entity.table.json +0 -76
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { _ as m, a as C } from "./import-file-
|
|
1
|
+
import { _ as m, a as C } from "./import-file-BtyRoYT7.js";
|
|
2
2
|
import { u as B } from "./userMenu-CT1xO2Pt.js";
|
|
3
|
-
import { openBlock as
|
|
4
|
-
import { I as oe } from "./IconSearch-
|
|
5
|
-
const
|
|
3
|
+
import { openBlock as a, createElementBlock as i, createStaticVNode as A, createTextVNode as T, toDisplayString as V, createCommentVNode as v, createElementVNode as l, Fragment as x, resolveComponent as d, createVNode as h, withCtx as y, createBlock as g, withModifiers as re, renderList as S, withDirectives as Y, vModelCheckbox as le, normalizeStyle as j, normalizeClass as ne, resolveDynamicComponent as X, Transition as se, vShow as ae } from "vue";
|
|
4
|
+
import { I as oe } from "./IconSearch-CxDTYG1J.js";
|
|
5
|
+
const ie = {}, de = {
|
|
6
6
|
class: "h21yx vs0hq",
|
|
7
7
|
xmlns: "http://www.w3.org/2000/svg",
|
|
8
8
|
width: "24",
|
|
@@ -14,12 +14,12 @@ const ae = {}, ie = {
|
|
|
14
14
|
"stroke-linecap": "round",
|
|
15
15
|
"stroke-linejoin": "round"
|
|
16
16
|
};
|
|
17
|
-
function
|
|
18
|
-
return
|
|
17
|
+
function ce(t, e, r, o, n, s) {
|
|
18
|
+
return a(), i("svg", de, e[0] || (e[0] = [
|
|
19
19
|
A('<line x1="21" x2="14" y1="4" y2="4"></line><line x1="10" x2="3" y1="4" y2="4"></line><line x1="21" x2="12" y1="12" y2="12"></line><line x1="8" x2="3" y1="12" y2="12"></line><line x1="21" x2="16" y1="20" y2="20"></line><line x1="12" x2="3" y1="20" y2="20"></line><line x1="14" x2="14" y1="2" y2="6"></line><line x1="8" x2="8" y1="10" y2="14"></line><line x1="16" x2="16" y1="18" y2="22"></line>', 9)
|
|
20
20
|
]));
|
|
21
21
|
}
|
|
22
|
-
const
|
|
22
|
+
const ue = /* @__PURE__ */ m(ie, [["render", ce]]), he = {
|
|
23
23
|
data() {
|
|
24
24
|
return {
|
|
25
25
|
currentSort: ""
|
|
@@ -65,10 +65,10 @@ const ce = /* @__PURE__ */ m(ae, [["render", de]]), ue = {
|
|
|
65
65
|
},
|
|
66
66
|
handleClickSortBtn(t) {
|
|
67
67
|
this.$emit("change-active", this.data.name), this.currentSort = this.changeCurrentSort(t);
|
|
68
|
-
const e = this.$route.query, { sort: r, ...
|
|
68
|
+
const e = this.$route.query, { sort: r, ...o } = e, n = this.currentSort ? `${this.data.name}-${this.currentSort}` : "";
|
|
69
69
|
this.$router.replace({
|
|
70
70
|
query: {
|
|
71
|
-
...
|
|
71
|
+
...o,
|
|
72
72
|
...n && { sort: n }
|
|
73
73
|
}
|
|
74
74
|
});
|
|
@@ -77,10 +77,10 @@ const ce = /* @__PURE__ */ m(ae, [["render", de]]), ue = {
|
|
|
77
77
|
return `${this.data.name}-${t}` === this.selectedSortParam;
|
|
78
78
|
}
|
|
79
79
|
}
|
|
80
|
-
},
|
|
80
|
+
}, pe = {
|
|
81
81
|
scope: "col",
|
|
82
82
|
class: "text-start"
|
|
83
|
-
},
|
|
83
|
+
}, me = {
|
|
84
84
|
class: "flex-shrink-0 size-3.5",
|
|
85
85
|
xmlns: "http://www.w3.org/2000/svg",
|
|
86
86
|
width: "24",
|
|
@@ -91,33 +91,33 @@ const ce = /* @__PURE__ */ m(ae, [["render", de]]), ue = {
|
|
|
91
91
|
"stroke-width": "2",
|
|
92
92
|
"stroke-linecap": "round",
|
|
93
93
|
"stroke-linejoin": "round"
|
|
94
|
-
},
|
|
94
|
+
}, be = {
|
|
95
95
|
key: 0,
|
|
96
96
|
d: "m7 15 5 5 5-5"
|
|
97
|
-
},
|
|
97
|
+
}, fe = {
|
|
98
98
|
key: 1,
|
|
99
99
|
d: "m7 9 5-5 5 5"
|
|
100
|
-
},
|
|
100
|
+
}, ge = {
|
|
101
101
|
key: 1,
|
|
102
102
|
class: "text-sm text-gray-800 px-[4px] py-2.5 text-start font-normal text-gray-500"
|
|
103
103
|
};
|
|
104
|
-
function
|
|
105
|
-
return
|
|
106
|
-
s.getVisibleIcon ? (
|
|
104
|
+
function xe(t, e, r, o, n, s) {
|
|
105
|
+
return a(), i("th", pe, [
|
|
106
|
+
s.getVisibleIcon ? (a(), i("button", {
|
|
107
107
|
key: 0,
|
|
108
108
|
type: "button",
|
|
109
109
|
class: "text-sm text-gray-800 px-[4px] py-2.5 text-start font-normal text-gray-500 flex items-center gap-[6px]",
|
|
110
110
|
onClick: e[0] || (e[0] = (b) => s.handleClickSortBtn(n.currentSort))
|
|
111
111
|
}, [
|
|
112
112
|
T(V(s.label) + " ", 1),
|
|
113
|
-
(
|
|
114
|
-
n.currentSort === "asc" || n.currentSort === "" ? (
|
|
115
|
-
n.currentSort === "desc" || n.currentSort === "" ? (
|
|
113
|
+
(a(), i("svg", me, [
|
|
114
|
+
n.currentSort === "asc" || n.currentSort === "" ? (a(), i("path", be)) : v("", !0),
|
|
115
|
+
n.currentSort === "desc" || n.currentSort === "" ? (a(), i("path", fe)) : v("", !0)
|
|
116
116
|
]))
|
|
117
|
-
])) : (
|
|
117
|
+
])) : (a(), i("p", ge, V(s.label), 1))
|
|
118
118
|
]);
|
|
119
119
|
}
|
|
120
|
-
const
|
|
120
|
+
const ye = /* @__PURE__ */ m(he, [["render", xe]]), ke = {}, we = {
|
|
121
121
|
xmlns: "http://www.w3.org/2000/svg",
|
|
122
122
|
viewBox: "0 0 24 24",
|
|
123
123
|
fill: "none",
|
|
@@ -127,8 +127,8 @@ const xe = /* @__PURE__ */ m(ue, [["render", ge]]), ye = {}, ke = {
|
|
|
127
127
|
"stroke-linejoin": "round",
|
|
128
128
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-dots-vertical"
|
|
129
129
|
};
|
|
130
|
-
function
|
|
131
|
-
return
|
|
130
|
+
function _e(t, e, r, o, n, s) {
|
|
131
|
+
return a(), i("svg", we, e[0] || (e[0] = [
|
|
132
132
|
l("path", {
|
|
133
133
|
stroke: "none",
|
|
134
134
|
d: "M0 0h24v24H0z",
|
|
@@ -139,7 +139,7 @@ function we(t, e, r, a, n, s) {
|
|
|
139
139
|
l("path", { d: "M12 5m-1 0a1 1 0 1 0 2 0a1 1 0 1 0 -2 0" }, null, -1)
|
|
140
140
|
]));
|
|
141
141
|
}
|
|
142
|
-
const
|
|
142
|
+
const ve = /* @__PURE__ */ m(ke, [["render", _e]]), Ce = {}, $e = {
|
|
143
143
|
class: "flex-shrink-0 size-3.5",
|
|
144
144
|
xmlns: "http://www.w3.org/2000/svg",
|
|
145
145
|
viewBox: "0 0 24 24",
|
|
@@ -149,21 +149,21 @@ const _e = /* @__PURE__ */ m(ye, [["render", we]]), ve = {}, Ce = {
|
|
|
149
149
|
"stroke-linecap": "round",
|
|
150
150
|
"stroke-linejoin": "round"
|
|
151
151
|
};
|
|
152
|
-
function
|
|
153
|
-
return
|
|
152
|
+
function Se(t, e, r, o, n, s) {
|
|
153
|
+
return a(), i("svg", $e, e[0] || (e[0] = [
|
|
154
154
|
A('<path d="M3 6h18"></path><path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"></path><path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"></path><line x1="10" x2="10" y1="11" y2="17"></line><line x1="14" x2="14" y1="11" y2="17"></line>', 5)
|
|
155
155
|
]));
|
|
156
156
|
}
|
|
157
|
-
const
|
|
157
|
+
const Te = /* @__PURE__ */ m(Ce, [["render", Se]]), Ve = {
|
|
158
158
|
props: {
|
|
159
159
|
height: { type: String, default: "16" },
|
|
160
160
|
width: { type: String, default: "12" },
|
|
161
161
|
color: { type: String, default: "black" }
|
|
162
162
|
}
|
|
163
|
-
},
|
|
164
|
-
function
|
|
165
|
-
return
|
|
166
|
-
(
|
|
163
|
+
}, De = { style: { display: "none" } }, Fe = ["height", "width", "fill"];
|
|
164
|
+
function Me(t, e, r, o, n, s) {
|
|
165
|
+
return a(), i(x, null, [
|
|
166
|
+
(a(), i("svg", De, e[0] || (e[0] = [
|
|
167
167
|
l("symbol", {
|
|
168
168
|
id: "icon-pencil",
|
|
169
169
|
viewBox: "0 0 32 32"
|
|
@@ -171,7 +171,7 @@ function De(t, e, r, a, n, s) {
|
|
|
171
171
|
l("path", { d: "M27 0c2.761 0 5 2.239 5 5 0 1.126-0.372 2.164-1 3l-2 2-7-7 2-2c0.836-0.628 1.874-1 3-1zM2 23l-2 9 9-2 18.5-18.5-7-7-18.5 18.5zM22.362 11.362l-14 14-1.724-1.724 14-14 1.724 1.724z" })
|
|
172
172
|
], -1)
|
|
173
173
|
]))),
|
|
174
|
-
(
|
|
174
|
+
(a(), i("svg", {
|
|
175
175
|
height: r.height,
|
|
176
176
|
width: r.width,
|
|
177
177
|
fill: r.color
|
|
@@ -180,11 +180,11 @@ function De(t, e, r, a, n, s) {
|
|
|
180
180
|
]), 8, Fe))
|
|
181
181
|
], 64);
|
|
182
182
|
}
|
|
183
|
-
const
|
|
183
|
+
const Ae = /* @__PURE__ */ m(Ve, [["render", Me]]), Ie = {
|
|
184
184
|
components: {
|
|
185
|
-
IconMore:
|
|
186
|
-
IconDelete:
|
|
187
|
-
IconEdit:
|
|
185
|
+
IconMore: ve,
|
|
186
|
+
IconDelete: Te,
|
|
187
|
+
IconEdit: Ae
|
|
188
188
|
},
|
|
189
189
|
emits: ["updateTable"],
|
|
190
190
|
props: { item: Object, table: String, isForm: null },
|
|
@@ -232,20 +232,20 @@ const Me = /* @__PURE__ */ m(Te, [["render", De]]), Ae = {
|
|
|
232
232
|
}
|
|
233
233
|
}
|
|
234
234
|
}
|
|
235
|
-
},
|
|
235
|
+
}, Be = { class: "hs-dropdown [--placement:bottom-right] inline-flex" }, je = { class: "gap-x-2 p-[4px] rounded-lg shadow-sm hover:border-transparent border focus:outline-none text-black hover:bg-gray-50" }, ze = { class: "flex flex-col items-start" }, Pe = {
|
|
236
236
|
key: 1,
|
|
237
237
|
class: "h-[1px] w-[80%] bg-gray-200 ml-auto mr-auto"
|
|
238
|
-
},
|
|
239
|
-
function Le(t, e, r,
|
|
238
|
+
}, Ee = { class: "p-4" }, Ue = { class: "mt-4 flex justify-end gap-x-3" };
|
|
239
|
+
function Le(t, e, r, o, n, s) {
|
|
240
240
|
const b = d("IconMore"), f = d("IconEdit"), k = d("router-link"), u = d("IconDelete"), w = d("VsPopover"), $ = d("VsDialog");
|
|
241
|
-
return
|
|
242
|
-
l("div",
|
|
241
|
+
return a(), i(x, null, [
|
|
242
|
+
l("div", Be, [
|
|
243
243
|
h(w, {
|
|
244
244
|
trigger: "click",
|
|
245
245
|
placement: "bottom-left"
|
|
246
246
|
}, {
|
|
247
247
|
reference: y(() => [
|
|
248
|
-
l("button",
|
|
248
|
+
l("button", je, [
|
|
249
249
|
h(b, {
|
|
250
250
|
height: "16",
|
|
251
251
|
width: "16"
|
|
@@ -253,12 +253,12 @@ function Le(t, e, r, a, n, s) {
|
|
|
253
253
|
])
|
|
254
254
|
]),
|
|
255
255
|
default: y(() => {
|
|
256
|
-
var _,
|
|
256
|
+
var _, D, F;
|
|
257
257
|
return [
|
|
258
|
-
l("div",
|
|
259
|
-
r.isForm ? (
|
|
258
|
+
l("div", ze, [
|
|
259
|
+
r.isForm ? (a(), g(k, {
|
|
260
260
|
key: 0,
|
|
261
|
-
to: `/edit?table=${(
|
|
261
|
+
to: `/edit?table=${(D = (_ = t.$route) == null ? void 0 : _.params) == null ? void 0 : D.catchAll}&id=${(F = r.item) == null ? void 0 : F.id}`,
|
|
262
262
|
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"
|
|
263
263
|
}, {
|
|
264
264
|
default: y(() => [
|
|
@@ -267,9 +267,9 @@ function Le(t, e, r, a, n, s) {
|
|
|
267
267
|
]),
|
|
268
268
|
_: 1
|
|
269
269
|
}, 8, ["to"])) : v("", !0),
|
|
270
|
-
r.isForm ? (
|
|
270
|
+
r.isForm ? (a(), i("div", Pe)) : v("", !0),
|
|
271
271
|
l("button", {
|
|
272
|
-
onClick: e[0] || (e[0] =
|
|
272
|
+
onClick: e[0] || (e[0] = re((...I) => s.openConfirm && s.openConfirm(...I), ["stop"])),
|
|
273
273
|
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"
|
|
274
274
|
}, [
|
|
275
275
|
h(u),
|
|
@@ -287,9 +287,9 @@ function Le(t, e, r, a, n, s) {
|
|
|
287
287
|
title: "Ви впевнені?"
|
|
288
288
|
}, {
|
|
289
289
|
default: y(() => [
|
|
290
|
-
l("div",
|
|
290
|
+
l("div", Ee, [
|
|
291
291
|
e[6] || (e[6] = l("p", { class: "mt-1 text-gray-500 dark:text-neutral-500" }, " Ви впевнені, що хочете видалити цей об'єкт? ", -1)),
|
|
292
|
-
l("div",
|
|
292
|
+
l("div", Ue, [
|
|
293
293
|
l("button", {
|
|
294
294
|
type: "button",
|
|
295
295
|
class: "py-2 px-3 inline-flex items-center gap-x-2 text-sm 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",
|
|
@@ -307,7 +307,7 @@ function Le(t, e, r, a, n, s) {
|
|
|
307
307
|
}, 8, ["visible"])
|
|
308
308
|
], 64);
|
|
309
309
|
}
|
|
310
|
-
const
|
|
310
|
+
const qe = /* @__PURE__ */ m(Ie, [["render", Le]]), Oe = {}, We = {
|
|
311
311
|
class: "flex-shrink-0 mt-0.5 size-3.5",
|
|
312
312
|
xmlns: "http://www.w3.org/2000/svg",
|
|
313
313
|
viewBox: "0 0 24 24",
|
|
@@ -317,16 +317,16 @@ const Ue = /* @__PURE__ */ m(Ae, [["render", Le]]), qe = {}, Oe = {
|
|
|
317
317
|
"stroke-linecap": "round",
|
|
318
318
|
"stroke-linejoin": "round"
|
|
319
319
|
};
|
|
320
|
-
function
|
|
321
|
-
return
|
|
320
|
+
function He(t, e, r, o, n, s) {
|
|
321
|
+
return a(), i("svg", We, e[0] || (e[0] = [
|
|
322
322
|
l("path", { d: "m3 16 4 4 4-4" }, null, -1),
|
|
323
323
|
l("path", { d: "M7 20V4" }, null, -1),
|
|
324
324
|
l("path", { d: "m21 8-4-4-4 4" }, null, -1),
|
|
325
325
|
l("path", { d: "M17 4v16" }, null, -1)
|
|
326
326
|
]));
|
|
327
327
|
}
|
|
328
|
-
const
|
|
329
|
-
components: { IconExport:
|
|
328
|
+
const Ne = /* @__PURE__ */ m(Oe, [["render", He]]), Re = {
|
|
329
|
+
components: { IconExport: Ne },
|
|
330
330
|
props: { table: String, columns: Array },
|
|
331
331
|
data() {
|
|
332
332
|
return {
|
|
@@ -348,11 +348,11 @@ const He = /* @__PURE__ */ m(qe, [["render", We]]), Ne = {
|
|
|
348
348
|
responseType: "blob"
|
|
349
349
|
}), e = new Blob([t.data], {
|
|
350
350
|
type: "application/octet-stream"
|
|
351
|
-
}), r = window.URL.createObjectURL(e),
|
|
352
|
-
|
|
351
|
+
}), r = window.URL.createObjectURL(e), o = document.createElement("a");
|
|
352
|
+
o.href = r, o.setAttribute(
|
|
353
353
|
"download",
|
|
354
354
|
`${this.table.split(".")[0]}.${this.format}`
|
|
355
|
-
), document.body.appendChild(
|
|
355
|
+
), document.body.appendChild(o), o.click(), document.body.removeChild(o), window.URL.revokeObjectURL(r), this.$notify({
|
|
356
356
|
type: "success",
|
|
357
357
|
title: "Експорт",
|
|
358
358
|
message: "Файл успішно експортовано!"
|
|
@@ -369,10 +369,10 @@ const He = /* @__PURE__ */ m(qe, [["render", We]]), Ne = {
|
|
|
369
369
|
this.format = t;
|
|
370
370
|
}
|
|
371
371
|
}
|
|
372
|
-
},
|
|
373
|
-
function
|
|
372
|
+
}, Ge = { class: "p-4" }, Ze = { class: "pb-5 mb-5 last:pb-0 last:mb-0 border-b last:border-b-0 border-gray-200 dark:border-neutral-700" }, Je = { class: "mt-2 flex row flex-wrap gap-y-[5px] gap-x-[10px]" }, Ke = { class: "pb-5 mb-5 last:pb-0 last:mb-0 border-b last:border-b-0 border-gray-200 dark:border-neutral-700" }, Qe = { class: "mt-2 space-y-2" }, Xe = ["id", "onChange"], Ye = ["for"], et = { class: "flex w-full justify-end p-[20px] gap-[6px] border-t" };
|
|
373
|
+
function tt(t, e, r, o, n, s) {
|
|
374
374
|
const b = d("IconExport"), f = d("VsCheckbox"), k = d("VsDialog");
|
|
375
|
-
return
|
|
375
|
+
return a(), i(x, null, [
|
|
376
376
|
l("button", {
|
|
377
377
|
onClick: e[0] || (e[0] = (u) => n.isOpen = !0),
|
|
378
378
|
class: "py-2 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"
|
|
@@ -404,7 +404,7 @@ function et(t, e, r, a, n, s) {
|
|
|
404
404
|
size: "small"
|
|
405
405
|
}, {
|
|
406
406
|
footer: y(() => [
|
|
407
|
-
l("div",
|
|
407
|
+
l("div", et, [
|
|
408
408
|
e[8] || (e[8] = l("button", {
|
|
409
409
|
type: "button",
|
|
410
410
|
class: "py-2 px-3 text-nowrap inline-flex justify-center items-center text-start bg-white border border-gray-200 text-gray-800 text-sm font-medium rounded-lg shadow-sm align-middle 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",
|
|
@@ -419,11 +419,11 @@ function et(t, e, r, a, n, s) {
|
|
|
419
419
|
]),
|
|
420
420
|
default: y(() => [
|
|
421
421
|
e[9] || (e[9] = l("div", { class: "dark:border-neutral-700" }, null, -1)),
|
|
422
|
-
l("div",
|
|
423
|
-
l("div",
|
|
422
|
+
l("div", Ge, [
|
|
423
|
+
l("div", Ze, [
|
|
424
424
|
e[6] || (e[6] = l("h2", { class: "text-sm text-gray-500" }, " Виберіть стовпці таблиці для експорту: ", -1)),
|
|
425
|
-
l("div",
|
|
426
|
-
(
|
|
425
|
+
l("div", Je, [
|
|
426
|
+
(a(!0), i(x, null, S(r.columns, (u, w) => (a(), i("div", {
|
|
427
427
|
class: "flex items-center",
|
|
428
428
|
key: w,
|
|
429
429
|
style: { width: "calc((100% - 10px) / 2)" }
|
|
@@ -438,10 +438,10 @@ function et(t, e, r, a, n, s) {
|
|
|
438
438
|
]))), 128))
|
|
439
439
|
])
|
|
440
440
|
]),
|
|
441
|
-
l("div",
|
|
441
|
+
l("div", Ke, [
|
|
442
442
|
e[7] || (e[7] = l("h2", { class: "text-sm text-gray-500" }, "Виберіть формат таблиці:", -1)),
|
|
443
|
-
l("div",
|
|
444
|
-
(
|
|
443
|
+
l("div", Qe, [
|
|
444
|
+
(a(!0), i(x, null, S(n.tableFormats, (u, w) => (a(), i("div", {
|
|
445
445
|
class: "flex items-center",
|
|
446
446
|
key: w
|
|
447
447
|
}, [
|
|
@@ -451,11 +451,11 @@ function et(t, e, r, a, n, s) {
|
|
|
451
451
|
class: "shrink-0 border-gray-300 rounded-full text-blue-600 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",
|
|
452
452
|
id: u,
|
|
453
453
|
onChange: ($) => s.selectFormat(u)
|
|
454
|
-
}, null, 40,
|
|
454
|
+
}, null, 40, Xe),
|
|
455
455
|
l("label", {
|
|
456
456
|
for: u,
|
|
457
457
|
class: "text-sm text-gray-800 ms-3 dark:text-neutral-400"
|
|
458
|
-
}, " Формат " + V(u), 9,
|
|
458
|
+
}, " Формат " + V(u), 9, Ye)
|
|
459
459
|
]))), 128))
|
|
460
460
|
])
|
|
461
461
|
])
|
|
@@ -465,7 +465,7 @@ function et(t, e, r, a, n, s) {
|
|
|
465
465
|
}, 8, ["visible"])
|
|
466
466
|
], 64);
|
|
467
467
|
}
|
|
468
|
-
const
|
|
468
|
+
const rt = /* @__PURE__ */ m(Re, [["render", tt]]), lt = {}, nt = {
|
|
469
469
|
xmlns: "http://www.w3.org/2000/svg",
|
|
470
470
|
viewBox: "0 0 24 24",
|
|
471
471
|
fill: "none",
|
|
@@ -475,12 +475,12 @@ const tt = /* @__PURE__ */ m(Ne, [["render", et]]), rt = {}, lt = {
|
|
|
475
475
|
"stroke-linejoin": "round",
|
|
476
476
|
class: "icon icon-tabler icons-tabler-outline icon-tabler-columns"
|
|
477
477
|
};
|
|
478
|
-
function
|
|
479
|
-
return
|
|
478
|
+
function st(t, e, r, o, n, s) {
|
|
479
|
+
return a(), i("svg", nt, e[0] || (e[0] = [
|
|
480
480
|
A('<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)
|
|
481
481
|
]));
|
|
482
482
|
}
|
|
483
|
-
const
|
|
483
|
+
const at = /* @__PURE__ */ m(lt, [["render", st]]), ot = {
|
|
484
484
|
props: { column: Object },
|
|
485
485
|
emits: ["update-column"],
|
|
486
486
|
data() {
|
|
@@ -497,38 +497,38 @@ const st = /* @__PURE__ */ m(rt, [["render", nt]]), ot = {
|
|
|
497
497
|
var t;
|
|
498
498
|
((t = this.column) == null ? void 0 : t.hidden) !== !0 && (this.value = !0);
|
|
499
499
|
}
|
|
500
|
-
},
|
|
501
|
-
function
|
|
500
|
+
}, it = { class: "flex w-full gap-[8px] items-centr" };
|
|
501
|
+
function dt(t, e, r, o, n, s) {
|
|
502
502
|
var b, f;
|
|
503
|
-
return
|
|
504
|
-
|
|
503
|
+
return a(), i("label", it, [
|
|
504
|
+
Y(l("input", {
|
|
505
505
|
"onUpdate:modelValue": e[0] || (e[0] = (k) => n.value = k),
|
|
506
506
|
type: "checkbox"
|
|
507
507
|
}, null, 512), [
|
|
508
|
-
[
|
|
508
|
+
[le, n.value]
|
|
509
509
|
]),
|
|
510
510
|
T(" " + V(((b = r.column) == null ? void 0 : b.ua) || ((f = r.column) == null ? void 0 : f.title)), 1)
|
|
511
511
|
]);
|
|
512
512
|
}
|
|
513
|
-
const
|
|
514
|
-
components: { IconColumns:
|
|
513
|
+
const ct = /* @__PURE__ */ m(ot, [["render", dt]]), ut = {
|
|
514
|
+
components: { IconColumns: at, AdminTableColumnsHiddenItem: ct },
|
|
515
515
|
emits: ["update-columns"],
|
|
516
516
|
props: { columns: Array },
|
|
517
517
|
methods: {
|
|
518
518
|
updateColumn(t) {
|
|
519
|
-
const e = this.columns.findIndex((
|
|
519
|
+
const e = this.columns.findIndex((o) => (o == null ? void 0 : o.name) === (t == null ? void 0 : t.name)), r = this.columns;
|
|
520
520
|
r[e] = t, this.$emit("update-columns", [...r]);
|
|
521
521
|
}
|
|
522
522
|
}
|
|
523
|
-
},
|
|
524
|
-
function
|
|
523
|
+
}, ht = { class: "py-2 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" }, pt = { class: "py-[10px] px-[10px] w-[260px]" }, mt = { class: "flex flex-col gap-[3px] max-h-[400px] w-full 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" };
|
|
524
|
+
function bt(t, e, r, o, n, s) {
|
|
525
525
|
const b = d("IconColumns"), f = d("AdminTableColumnsHiddenItem"), k = d("VsPopover");
|
|
526
|
-
return
|
|
526
|
+
return a(), g(k, {
|
|
527
527
|
trigger: "click",
|
|
528
528
|
placement: "bottom"
|
|
529
529
|
}, {
|
|
530
530
|
reference: y(() => [
|
|
531
|
-
l("button",
|
|
531
|
+
l("button", ht, [
|
|
532
532
|
h(b, {
|
|
533
533
|
height: "20",
|
|
534
534
|
width: "16"
|
|
@@ -536,10 +536,10 @@ function mt(t, e, r, a, n, s) {
|
|
|
536
536
|
])
|
|
537
537
|
]),
|
|
538
538
|
default: y(() => [
|
|
539
|
-
l("div",
|
|
539
|
+
l("div", pt, [
|
|
540
540
|
e[0] || (e[0] = l("h2", { class: "text-sm mb-[8px]" }, "Оберіть колонки, щоб приховати", -1)),
|
|
541
|
-
l("ul",
|
|
542
|
-
(
|
|
541
|
+
l("ul", mt, [
|
|
542
|
+
(a(!0), i(x, null, S(r.columns, (u, w) => (a(), i("li", { key: w }, [
|
|
543
543
|
h(f, {
|
|
544
544
|
column: u,
|
|
545
545
|
onUpdateColumn: s.updateColumn
|
|
@@ -551,14 +551,14 @@ function mt(t, e, r, a, n, s) {
|
|
|
551
551
|
_: 1
|
|
552
552
|
});
|
|
553
553
|
}
|
|
554
|
-
const
|
|
554
|
+
const ft = /* @__PURE__ */ m(ut, [["render", bt]]), gt = {}, xt = {
|
|
555
555
|
class: "hidden sm:block shrink-0 size-3",
|
|
556
556
|
xmlns: "http://www.w3.org/2000/svg",
|
|
557
557
|
fill: "currentColor",
|
|
558
558
|
viewBox: "0 0 16 16"
|
|
559
559
|
};
|
|
560
|
-
function
|
|
561
|
-
return
|
|
560
|
+
function yt(t, e, r, o, n, s) {
|
|
561
|
+
return a(), i("svg", xt, e[0] || (e[0] = [
|
|
562
562
|
l("path", {
|
|
563
563
|
"fill-rule": "evenodd",
|
|
564
564
|
"clip-rule": "evenodd",
|
|
@@ -566,22 +566,22 @@ function xt(t, e, r, a, n, s) {
|
|
|
566
566
|
}, null, -1)
|
|
567
567
|
]));
|
|
568
568
|
}
|
|
569
|
-
const
|
|
570
|
-
function
|
|
571
|
-
return
|
|
569
|
+
const kt = /* @__PURE__ */ m(gt, [["render", yt]]), wt = {}, _t = { class: "vs-table-interface__table-wrp w-full rounded h-fit overflow-hidden" };
|
|
570
|
+
function vt(t, e, r, o, n, s) {
|
|
571
|
+
return a(), i("div", _t, e[0] || (e[0] = [
|
|
572
572
|
A('<div><div class="p-5 min-h-[500px] flex flex-col justify-center items-center text-center"><svg class="w-48 mx-auto" viewBox="0 0 178 90" fill="none" xmlns="http://www.w3.org/2000/svg"><rect x="27" y="50.5" width="124" height="39" rx="7.5" fill="currentColor" class="fill-white dark:fill-neutral-800"></rect><rect x="27" y="50.5" width="124" height="39" rx="7.5" stroke="currentColor" class="stroke-gray-50 dark:stroke-neutral-700/10"></rect><rect x="34.5" y="58" width="24" height="24" rx="4" fill="currentColor" class="fill-gray-50 dark:fill-neutral-700/30"></rect><rect x="66.5" y="61" width="60" height="6" rx="3" fill="currentColor" class="fill-gray-50 dark:fill-neutral-700/30"></rect><rect x="66.5" y="73" width="77" height="6" rx="3" fill="currentColor" class="fill-gray-50 dark:fill-neutral-700/30"></rect><rect x="19.5" y="28.5" width="139" height="39" rx="7.5" fill="currentColor" class="fill-white dark:fill-neutral-800"></rect><rect x="19.5" y="28.5" width="139" height="39" rx="7.5" stroke="currentColor" class="stroke-gray-100 dark:stroke-neutral-700/30"></rect><rect x="27" y="36" width="24" height="24" rx="4" fill="currentColor" class="fill-gray-100 dark:fill-neutral-700/70"></rect><rect x="59" y="39" width="60" height="6" rx="3" fill="currentColor" class="fill-gray-100 dark:fill-neutral-700/70"></rect><rect x="59" y="51" width="92" height="6" rx="3" fill="currentColor" class="fill-gray-100 dark:fill-neutral-700/70"></rect><g filter="url(#filter1)"><rect x="12" y="6" width="154" height="40" rx="8" fill="currentColor" class="fill-white dark:fill-neutral-800" shape-rendering="crispEdges"></rect><rect x="12.5" y="6.5" width="153" height="39" rx="7.5" stroke="currentColor" class="stroke-gray-100 dark:stroke-neutral-700/60" shape-rendering="crispEdges"></rect><rect x="20" y="14" width="24" height="24" rx="4" fill="currentColor" class="fill-gray-200 dark:fill-neutral-700"></rect><rect x="52" y="17" width="60" height="6" rx="3" fill="currentColor" class="fill-gray-200 dark:fill-neutral-700"></rect><rect x="52" y="29" width="106" height="6" rx="3" fill="currentColor" class="fill-gray-200 dark:fill-neutral-700"></rect></g><defs><filter id="filter1" x="0" y="0" width="178" height="64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB"><feFlood flood-opacity="0" result="BackgroundImageFix"></feFlood><feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"></feColorMatrix><feOffset dy="6"></feOffset><feGaussianBlur stdDeviation="6"></feGaussianBlur><feComposite in2="hardAlpha" operator="out"></feComposite><feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.03 0"></feColorMatrix><feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_1187_14810"></feBlend><feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_1187_14810" result="shape"></feBlend></filter></defs></svg><div class="max-w-sm mx-auto mt-6"><p class="font-medium text-gray-800 dark:text-neutral-200"> Дані для відображення відсутні </p><p class="mt-2 text-sm text-gray-500 dark:text-neutral-500"> Змініть параметри пошуку або спробуйте пізніше </p></div></div></div>', 1)
|
|
573
573
|
]));
|
|
574
574
|
}
|
|
575
|
-
const
|
|
575
|
+
const Ct = /* @__PURE__ */ m(wt, [["render", vt]]), $t = {
|
|
576
576
|
props: { table: String, title: String },
|
|
577
577
|
components: {
|
|
578
|
-
IconFilter:
|
|
579
|
-
AdminTableControl:
|
|
580
|
-
AdminTableExport:
|
|
581
|
-
AdminTableColumnsHidden:
|
|
582
|
-
AdminTableColumn:
|
|
583
|
-
AdminNodata:
|
|
584
|
-
IconPlus:
|
|
578
|
+
IconFilter: ue,
|
|
579
|
+
AdminTableControl: qe,
|
|
580
|
+
AdminTableExport: rt,
|
|
581
|
+
AdminTableColumnsHidden: ft,
|
|
582
|
+
AdminTableColumn: ye,
|
|
583
|
+
AdminNodata: Ct,
|
|
584
|
+
IconPlus: kt,
|
|
585
585
|
IconSearch: oe
|
|
586
586
|
},
|
|
587
587
|
data() {
|
|
@@ -598,8 +598,8 @@ const vt = /* @__PURE__ */ m(kt, [["render", _t]]), Ct = {
|
|
|
598
598
|
};
|
|
599
599
|
},
|
|
600
600
|
mounted() {
|
|
601
|
-
var t, e, r,
|
|
602
|
-
this.page = ((e = (t = this.$route) == null ? void 0 : t.query) == null ? void 0 : e.page) || 1, this.limit = ((
|
|
601
|
+
var t, e, r, o;
|
|
602
|
+
this.page = ((e = (t = this.$route) == null ? void 0 : t.query) == null ? void 0 : e.page) || 1, this.limit = ((o = (r = this.$route) == null ? void 0 : r.query) == null ? void 0 : o.limit) || 20, this.getTableData(), this.getFilters();
|
|
603
603
|
},
|
|
604
604
|
computed: {
|
|
605
605
|
defaultPage() {
|
|
@@ -636,8 +636,8 @@ const vt = /* @__PURE__ */ m(kt, [["render", _t]]), Ct = {
|
|
|
636
636
|
},
|
|
637
637
|
$route: {
|
|
638
638
|
handler(t, e) {
|
|
639
|
-
var r,
|
|
640
|
-
((r = t == null ? void 0 : t.params) == null ? void 0 : r.catchAll) !== ((
|
|
639
|
+
var r, o;
|
|
640
|
+
((r = t == null ? void 0 : t.params) == null ? void 0 : r.catchAll) !== ((o = e == null ? void 0 : e.params) == null ? void 0 : o.catchAll) && (this.filterScheme = null, this.filters = null, this.onFilters = 0, this.getFilters());
|
|
641
641
|
},
|
|
642
642
|
deep: !0
|
|
643
643
|
},
|
|
@@ -650,7 +650,7 @@ const vt = /* @__PURE__ */ m(kt, [["render", _t]]), Ct = {
|
|
|
650
650
|
async getTableData() {
|
|
651
651
|
var t, e;
|
|
652
652
|
try {
|
|
653
|
-
const { data: r } = await C.get(`/api/template/table/${this.table}`),
|
|
653
|
+
const { data: r } = await C.get(`/api/template/table/${this.table}`), o = await C.get(`/api/table-data/${this.table}`, {
|
|
654
654
|
params: {
|
|
655
655
|
page: this.page,
|
|
656
656
|
search: this.searchValue || null,
|
|
@@ -661,7 +661,7 @@ const vt = /* @__PURE__ */ m(kt, [["render", _t]]), Ct = {
|
|
|
661
661
|
});
|
|
662
662
|
this.tableData = {
|
|
663
663
|
...r,
|
|
664
|
-
...(
|
|
664
|
+
...(o == null ? void 0 : o.data) || {}
|
|
665
665
|
};
|
|
666
666
|
} catch {
|
|
667
667
|
}
|
|
@@ -699,27 +699,27 @@ const vt = /* @__PURE__ */ m(kt, [["render", _t]]), Ct = {
|
|
|
699
699
|
((e = this.tableData) == null ? void 0 : e.card) === !1 || this.$router.push(`/card/${this.table}/${t}`);
|
|
700
700
|
}
|
|
701
701
|
}
|
|
702
|
-
},
|
|
702
|
+
}, St = { class: "w-[calc(100vw - 320px)]" }, Tt = { class: "h-[76px] bg-gray-50 flex items-center justify-between px-[30px]" }, Vt = { class: "text-xl font-medium h-[20px]" }, Dt = {
|
|
703
703
|
style: { height: "calc(100vh - 140px)", width: "calc(100vw - 260px)" },
|
|
704
704
|
class: "bg-gray-50 p-[20px] flex pt-[10px]"
|
|
705
|
-
}, Ft = { class: "bg-white w-full rounded-xl border p-[20px]" },
|
|
705
|
+
}, Ft = { class: "bg-white w-full rounded-xl border p-[20px]" }, Mt = { class: "flex sm:grid sm:grid-cols-2 gap-x-2 sm:gap-x-5 mb-[10px] relative" }, At = { class: "flex gap-[6px] ml-auto" }, It = {
|
|
706
706
|
key: 0,
|
|
707
707
|
class: "font-medium text-[10px] py-0.5 px-[5px] bg-gray-800 text-white leading-3 rounded-full dark:bg-neutral-500"
|
|
708
|
-
},
|
|
708
|
+
}, Bt = { class: "space-y-5 flex items-start w-full justify-start" }, jt = {
|
|
709
709
|
style: { height: "calc(100vh - 310px)" },
|
|
710
710
|
class: "overflow-x-auto w-full border-t [&::-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"
|
|
711
|
-
},
|
|
711
|
+
}, zt = { class: "inline-block w-full align-middle" }, Pt = {
|
|
712
712
|
key: 0,
|
|
713
713
|
class: "divide-y divide-gray-200 min-w-full dark:divide-neutral-700 relative table-fixed"
|
|
714
|
-
},
|
|
715
|
-
function
|
|
716
|
-
var z, P, E,
|
|
717
|
-
const b = d("IconPlus"), f = d("router-link"), k = d("IconSearch"), u = d("VsText"), w = d("AdminTableColumnsHidden"), $ = d("AdminTableExport"), _ = d("IconFilter"),
|
|
718
|
-
return
|
|
719
|
-
l("div",
|
|
720
|
-
l("div",
|
|
721
|
-
l("h2",
|
|
722
|
-
s.isForm ? (
|
|
714
|
+
}, Et = { class: "sticky top-0 bg-white w-full relative after:absolute after:content-[''] after:block after:w-full after:h-px after:bg-stone-200" }, Ut = { class: "border-stone-200 right-0 z-[1]" }, Lt = { class: "divide-y divide-gray-200" }, qt = ["onClick"], Ot = { class: "text-center sticky right-0 bg-white w-[80px] px-[10px]" }, Wt = { class: "p-[20px] flex justify-end w-full" }, Ht = { class: "filter-content h-screen bg-white w-[400px] p-[20px] pt-[10px] overflow-x-auto bg-white [&::-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" };
|
|
715
|
+
function Nt(t, e, r, o, n, s) {
|
|
716
|
+
var z, P, E, U, L, q;
|
|
717
|
+
const b = d("IconPlus"), f = d("router-link"), k = d("IconSearch"), u = d("VsText"), w = d("AdminTableColumnsHidden"), $ = d("AdminTableExport"), _ = d("IconFilter"), D = d("AdminTableColumn"), F = d("AdminTableControl"), I = d("AdminNodata"), ee = d("VsPagination"), te = d("VsFilter");
|
|
718
|
+
return a(), i(x, null, [
|
|
719
|
+
l("div", St, [
|
|
720
|
+
l("div", Tt, [
|
|
721
|
+
l("h2", Vt, V(r.title), 1),
|
|
722
|
+
s.isForm ? (a(), g(f, {
|
|
723
723
|
key: 0,
|
|
724
724
|
to: `/add?table=${(P = (z = t.$route) == null ? void 0 : z.params) == null ? void 0 : P.catchAll}`,
|
|
725
725
|
class: "py-2 px-3 inline-flex items-center gap-x-2 text-sm font-medium rounded-lg border border-transparent bg-blue-600 text-white hover:bg-blue-700 hover:text-white duration-300"
|
|
@@ -734,9 +734,9 @@ function Ht(t, e, r, a, n, s) {
|
|
|
734
734
|
_: 1
|
|
735
735
|
}, 8, ["to"])) : v("", !0)
|
|
736
736
|
]),
|
|
737
|
-
l("div",
|
|
737
|
+
l("div", Dt, [
|
|
738
738
|
l("div", Ft, [
|
|
739
|
-
l("div",
|
|
739
|
+
l("div", Mt, [
|
|
740
740
|
h(k, {
|
|
741
741
|
height: "14",
|
|
742
742
|
width: "14",
|
|
@@ -749,14 +749,14 @@ function Ht(t, e, r, a, n, s) {
|
|
|
749
749
|
clearable: !0,
|
|
750
750
|
class: "[&>input]:py-[7px] [&>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"
|
|
751
751
|
}, null, 8, ["modelValue"]),
|
|
752
|
-
l("div",
|
|
752
|
+
l("div", At, [
|
|
753
753
|
h(w, {
|
|
754
754
|
columns: (E = n.tableData) == null ? void 0 : E.columns,
|
|
755
755
|
onUpdateColumns: e[1] || (e[1] = (c) => n.tableData.columns = c)
|
|
756
756
|
}, null, 8, ["columns"]),
|
|
757
757
|
h($, {
|
|
758
758
|
table: r.table,
|
|
759
|
-
columns: (
|
|
759
|
+
columns: (U = n.tableData) == null ? void 0 : U.columns
|
|
760
760
|
}, null, 8, ["table", "columns"]),
|
|
761
761
|
l("button", {
|
|
762
762
|
onClick: e[2] || (e[2] = (c) => n.isFilters = !n.isFilters),
|
|
@@ -767,17 +767,17 @@ function Ht(t, e, r, a, n, s) {
|
|
|
767
767
|
width: "16"
|
|
768
768
|
}),
|
|
769
769
|
e[6] || (e[6] = T(" Фільтри ")),
|
|
770
|
-
n.onFilters ? (
|
|
770
|
+
n.onFilters ? (a(), i("span", It, V(n.onFilters), 1)) : v("", !0)
|
|
771
771
|
])
|
|
772
772
|
])
|
|
773
773
|
]),
|
|
774
|
-
l("div",
|
|
775
|
-
l("div",
|
|
776
|
-
l("div",
|
|
777
|
-
s.isNoData ? (
|
|
778
|
-
l("thead",
|
|
779
|
-
l("tr",
|
|
780
|
-
(
|
|
774
|
+
l("div", Bt, [
|
|
775
|
+
l("div", jt, [
|
|
776
|
+
l("div", zt, [
|
|
777
|
+
s.isNoData ? (a(), g(I, { key: 1 })) : (a(), i("table", Pt, [
|
|
778
|
+
l("thead", Et, [
|
|
779
|
+
l("tr", Ut, [
|
|
780
|
+
(a(!0), i(x, null, S(s.columns, (c) => (a(), g(D, {
|
|
781
781
|
key: c.name,
|
|
782
782
|
style: j({ minWidth: s.rowWidth, maxWidth: s.rowWidth }),
|
|
783
783
|
data: c,
|
|
@@ -788,46 +788,50 @@ function Ht(t, e, r, a, n, s) {
|
|
|
788
788
|
])
|
|
789
789
|
]),
|
|
790
790
|
l("tbody", Lt, [
|
|
791
|
-
(
|
|
791
|
+
(a(!0), i(x, null, S((L = n.tableData) == null ? void 0 : L.rows, (c, M) => {
|
|
792
792
|
var O, W, H, N, R, G, Z, J;
|
|
793
|
-
return
|
|
793
|
+
return a(), i("tr", { key: M }, [
|
|
794
794
|
l("td", {
|
|
795
795
|
class: "text-sm text-gray-600",
|
|
796
796
|
style: j({ minWidth: s.rowWidth, maxWidth: s.rowWidth })
|
|
797
797
|
}, [
|
|
798
798
|
l("button", {
|
|
799
799
|
onClick: () => s.pushToCard(c == null ? void 0 : c.id),
|
|
800
|
-
class:
|
|
800
|
+
class: ne(["text-sm font-medium", [
|
|
801
801
|
((O = n.tableData) == null ? void 0 : O.card) === !1 ? "" : "text-blue-600 decoration-2 focus:outline-none focus:underline hover:text-blue-600 hover:underline"
|
|
802
802
|
]])
|
|
803
803
|
}, [
|
|
804
|
-
(
|
|
804
|
+
(a(), g(X(
|
|
805
805
|
((W = s.columns[0]) == null ? void 0 : W.format) === "custom" ? (H = s.columns[0]) == null ? void 0 : H.component : t.$componentsConfig[`table-format-${((R = (N = s.columns[0]) == null ? void 0 : N.format) == null ? void 0 : R.toLowerCase()) || "text"}`]
|
|
806
806
|
), {
|
|
807
807
|
name: (G = s.columns[0]) == null ? void 0 : G.name,
|
|
808
808
|
data: c,
|
|
809
|
-
value: c == null ? void 0 : c[(Z = s.columns[0]) == null ? void 0 : Z.name]
|
|
810
|
-
|
|
811
|
-
|
|
809
|
+
value: c == null ? void 0 : c[(Z = s.columns[0]) == null ? void 0 : Z.name],
|
|
810
|
+
table: r.table
|
|
811
|
+
}, null, 8, ["name", "data", "value", "table"]))
|
|
812
|
+
], 10, qt)
|
|
812
813
|
], 4),
|
|
813
|
-
(
|
|
814
|
-
var K;
|
|
815
|
-
return
|
|
814
|
+
(a(!0), i(x, null, S((J = s.columns) == null ? void 0 : J.slice(1), (p) => {
|
|
815
|
+
var K, Q;
|
|
816
|
+
return a(), i("td", {
|
|
816
817
|
class: "text-start px-[4px] py-3 text-sm text-gray-600",
|
|
817
818
|
style: j({ minWidth: s.rowWidth, maxWidth: s.rowWidth }),
|
|
818
819
|
key: p.name
|
|
819
820
|
}, [
|
|
820
|
-
(
|
|
821
|
+
(a(), g(X(
|
|
821
822
|
(p == null ? void 0 : p.format) === "custom" ? p == null ? void 0 : p.component : t.$componentsConfig[`table-format-${((K = p == null ? void 0 : p.format) == null ? void 0 : K.toLowerCase()) || "text"}`]
|
|
822
823
|
), {
|
|
824
|
+
onUpdateTable: s.getTableData,
|
|
823
825
|
name: p == null ? void 0 : p.name,
|
|
824
826
|
data: c,
|
|
825
|
-
value: c == null ? void 0 : c[p == null ? void 0 : p.name]
|
|
826
|
-
|
|
827
|
+
value: c == null ? void 0 : c[p == null ? void 0 : p.name],
|
|
828
|
+
table: r.table,
|
|
829
|
+
inline: ((Q = n.tableData) == null ? void 0 : Q.inline) || !1
|
|
830
|
+
}, null, 40, ["onUpdateTable", "name", "data", "value", "table", "inline"]))
|
|
827
831
|
], 4);
|
|
828
832
|
}), 128)),
|
|
829
|
-
l("td",
|
|
830
|
-
h(
|
|
833
|
+
l("td", Ot, [
|
|
834
|
+
h(F, {
|
|
831
835
|
isForm: s.isForm,
|
|
832
836
|
item: c,
|
|
833
837
|
table: r.table,
|
|
@@ -841,8 +845,8 @@ function Ht(t, e, r, a, n, s) {
|
|
|
841
845
|
])
|
|
842
846
|
])
|
|
843
847
|
]),
|
|
844
|
-
l("div",
|
|
845
|
-
n.limit ? (
|
|
848
|
+
l("div", Wt, [
|
|
849
|
+
n.limit ? (a(), g(ee, {
|
|
846
850
|
key: 0,
|
|
847
851
|
goTo: !1,
|
|
848
852
|
class: "justify-end",
|
|
@@ -857,17 +861,17 @@ function Ht(t, e, r, a, n, s) {
|
|
|
857
861
|
])
|
|
858
862
|
])
|
|
859
863
|
]),
|
|
860
|
-
h(
|
|
864
|
+
h(se, { name: "fade" }, {
|
|
861
865
|
default: y(() => {
|
|
862
866
|
var c;
|
|
863
867
|
return [
|
|
864
|
-
|
|
868
|
+
Y(l("div", {
|
|
865
869
|
onClick: e[4] || (e[4] = (...M) => s.closeFilter && s.closeFilter(...M)),
|
|
866
870
|
style: { height: "100vh" },
|
|
867
871
|
class: "fixed filter-container top-0 flex justify-end items-center z-[2] right-0 left-0 bottom-0 bg-[rgba(0,0,0,0.5)]"
|
|
868
872
|
}, [
|
|
869
|
-
l("div",
|
|
870
|
-
(c = n.filterScheme) != null && c.length ? (
|
|
873
|
+
l("div", Ht, [
|
|
874
|
+
(c = n.filterScheme) != null && c.length ? (a(), g(te, {
|
|
871
875
|
key: 0,
|
|
872
876
|
ref: "filter",
|
|
873
877
|
scheme: n.filterScheme,
|
|
@@ -881,7 +885,7 @@ function Ht(t, e, r, a, n, s) {
|
|
|
881
885
|
}, null, 8, ["scheme", "onFilterChange"])) : v("", !0)
|
|
882
886
|
])
|
|
883
887
|
], 512), [
|
|
884
|
-
[
|
|
888
|
+
[ae, n.isFilters]
|
|
885
889
|
])
|
|
886
890
|
];
|
|
887
891
|
}),
|
|
@@ -889,8 +893,8 @@ function Ht(t, e, r, a, n, s) {
|
|
|
889
893
|
})
|
|
890
894
|
], 64);
|
|
891
895
|
}
|
|
892
|
-
const
|
|
893
|
-
components: { AdminTable:
|
|
896
|
+
const Rt = /* @__PURE__ */ m($t, [["render", Nt]]), Gt = {
|
|
897
|
+
components: { AdminTable: Rt },
|
|
894
898
|
data() {
|
|
895
899
|
return {
|
|
896
900
|
table: !1,
|
|
@@ -930,9 +934,9 @@ const Nt = /* @__PURE__ */ m(Ct, [["render", Ht]]), Rt = {
|
|
|
930
934
|
async checkPageType() {
|
|
931
935
|
const t = this.flattenMenu(B.value);
|
|
932
936
|
t != null && t.length || this.$router.replace("/404");
|
|
933
|
-
const e = t == null ? void 0 : t.find((
|
|
937
|
+
const e = t == null ? void 0 : t.find((o) => {
|
|
934
938
|
var n, s;
|
|
935
|
-
return (
|
|
939
|
+
return (o == null ? void 0 : o.path) == ((s = (n = this.$route) == null ? void 0 : n.params) == null ? void 0 : s.catchAll);
|
|
936
940
|
});
|
|
937
941
|
this.title = e == null ? void 0 : e.ua, e || this.$router.replace("/404");
|
|
938
942
|
const r = e == null ? void 0 : e.table;
|
|
@@ -950,21 +954,21 @@ const Nt = /* @__PURE__ */ m(Ct, [["render", Ht]]), Rt = {
|
|
|
950
954
|
}
|
|
951
955
|
}
|
|
952
956
|
}
|
|
953
|
-
},
|
|
954
|
-
function
|
|
957
|
+
}, Zt = ["innerHTML"];
|
|
958
|
+
function Jt(t, e, r, o, n, s) {
|
|
955
959
|
const b = d("AdminTable");
|
|
956
|
-
return n.table ? (
|
|
960
|
+
return n.table ? (a(), g(b, {
|
|
957
961
|
key: 0,
|
|
958
962
|
table: n.table,
|
|
959
963
|
title: n.title
|
|
960
|
-
}, null, 8, ["table", "title"])) : (
|
|
964
|
+
}, null, 8, ["table", "title"])) : (a(), i("div", {
|
|
961
965
|
key: 1,
|
|
962
966
|
class: "w-full bg-gray-50",
|
|
963
967
|
style: { height: "calc(100vh - 120px)" },
|
|
964
968
|
innerHTML: n.interface
|
|
965
|
-
}, null, 8,
|
|
969
|
+
}, null, 8, Zt));
|
|
966
970
|
}
|
|
967
|
-
const
|
|
971
|
+
const er = /* @__PURE__ */ m(Gt, [["render", Jt]]);
|
|
968
972
|
export {
|
|
969
|
-
|
|
973
|
+
er as default
|
|
970
974
|
};
|