golden-logic-ui 1.3.33 → 1.3.34
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/components/GeneralComponents/ConfirmationModal.vue.js +32 -32
- package/dist/components/GeneralComponents/DataTable/DatatableDate.vue.js +8 -8
- package/dist/components/GeneralComponents/DataTable/DatatableDeleteAction.vue.js +42 -37
- package/dist/components/GeneralComponents/DataTable/DatatableStatus.vue.js +22 -16
- package/dist/components/GeneralComponents/DataTable/GLDataTable.vue.js +31 -30
- package/dist/components/GeneralComponents/DataTable/GLDataTableServerSide.vue.js +8 -5
- package/dist/components/GeneralComponents/DataTable/GlDataTableComponent.vue.js +4 -3
- package/dist/components/GeneralComponents/DataTable/GlDataTableServerSideGroupBy.vue.js +16 -15
- package/dist/components/GeneralComponents/FilesUpload.vue.js +114 -109
- package/dist/components/GeneralComponents/GlDropdown.vue.js +85 -77
- package/dist/components/GeneralComponents/GlMultiSelectDropdown.vue.js +9 -8
- package/dist/golden-logic-ui.css +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { resolveComponent as b, createElementBlock as f, createCommentVNode as u, openBlock as _, createElementVNode as t, toDisplayString as
|
|
1
|
+
import { resolveComponent as b, createElementBlock as f, createCommentVNode as u, openBlock as _, createElementVNode as t, toDisplayString as l, renderSlot as y, withDirectives as h, createTextVNode as c, withKeys as v, withModifiers as k, vModelText as w, createVNode as x, withCtx as g, ref as r, watch as C } from "vue";
|
|
2
2
|
import I from "./GLButton.vue.js";
|
|
3
|
-
import { useGlFocusTrap as T, nextGlId as
|
|
3
|
+
import { useGlFocusTrap as T, nextGlId as p } from "./useGlFocusTrap.js";
|
|
4
4
|
import A from "../../_virtual/_plugin-vue_export-helper.js";
|
|
5
5
|
const B = {
|
|
6
6
|
components: {
|
|
@@ -26,21 +26,21 @@ const B = {
|
|
|
26
26
|
}
|
|
27
27
|
},
|
|
28
28
|
emits: ["confirm-action", "cancel-action"],
|
|
29
|
-
setup(
|
|
30
|
-
const
|
|
31
|
-
return C(() =>
|
|
32
|
-
|
|
33
|
-
}), T(
|
|
34
|
-
closeOnEscape: () =>
|
|
35
|
-
onEscape: () =>
|
|
29
|
+
setup(a, { emit: n }) {
|
|
30
|
+
const e = r(null), o = r(null), d = r(null), i = r("");
|
|
31
|
+
return C(() => a.isOpen, (s) => {
|
|
32
|
+
s && (i.value = "");
|
|
33
|
+
}), T(e, () => !!a.isOpen, {
|
|
34
|
+
closeOnEscape: () => a.close_on_escape,
|
|
35
|
+
onEscape: () => n("cancel-action"),
|
|
36
36
|
initialFocus: () => o.value || d.value?.$el || null
|
|
37
37
|
}), {
|
|
38
|
-
panel:
|
|
38
|
+
panel: e,
|
|
39
39
|
confirmInput: o,
|
|
40
40
|
cancelButton: d,
|
|
41
41
|
typedText: i,
|
|
42
|
-
titleId:
|
|
43
|
-
inputId:
|
|
42
|
+
titleId: p("gl-confirmation-title"),
|
|
43
|
+
inputId: p("gl-confirmation-input")
|
|
44
44
|
};
|
|
45
45
|
},
|
|
46
46
|
computed: {
|
|
@@ -64,9 +64,9 @@ const B = {
|
|
|
64
64
|
key: 0,
|
|
65
65
|
class: "mt-4 text-left"
|
|
66
66
|
}, F = ["for"], K = { class: "px-1 py-0.5 font-mono text-red-600 bg-gray-100 rounded-sm dark:bg-gray-900 dark:text-red-300" }, z = ["id"], U = { class: "border-t border-gray-200 rounded-b dark:border-gray-600 px-4 py-3 sm:px-6 flex gap-2" };
|
|
67
|
-
function q(
|
|
68
|
-
const
|
|
69
|
-
return
|
|
67
|
+
function q(a, n, e, o, d, i) {
|
|
68
|
+
const s = b("gl-button");
|
|
69
|
+
return e.isOpen ? (_(), f("div", {
|
|
70
70
|
key: 0,
|
|
71
71
|
class: "fixed inset-0 z-99999 overflow-y-auto",
|
|
72
72
|
role: "dialog",
|
|
@@ -74,11 +74,11 @@ function q(l, e, n, o, d, i) {
|
|
|
74
74
|
"aria-labelledby": o.titleId
|
|
75
75
|
}, [
|
|
76
76
|
t("div", V, [
|
|
77
|
-
|
|
77
|
+
n[2] || (n[2] = t("div", {
|
|
78
78
|
class: "fixed inset-0 transition-opacity bg-gray-500/75",
|
|
79
79
|
"aria-hidden": "true"
|
|
80
80
|
}, null, -1)),
|
|
81
|
-
|
|
81
|
+
n[3] || (n[3] = t("span", {
|
|
82
82
|
class: "hidden sm:inline-block sm:align-middle sm:h-screen",
|
|
83
83
|
"aria-hidden": "true"
|
|
84
84
|
}, "", -1)),
|
|
@@ -89,28 +89,28 @@ function q(l, e, n, o, d, i) {
|
|
|
89
89
|
t("h3", {
|
|
90
90
|
id: o.titleId,
|
|
91
91
|
class: "text-lg font-medium leading-6"
|
|
92
|
-
},
|
|
92
|
+
}, l(e.title), 9, S),
|
|
93
93
|
t("div", j, [
|
|
94
|
-
y(
|
|
94
|
+
y(a.$slots, "default")
|
|
95
95
|
]),
|
|
96
|
-
|
|
96
|
+
e.confirm_text ? (_(), f("div", D, [
|
|
97
97
|
t("label", {
|
|
98
98
|
for: o.inputId,
|
|
99
99
|
class: "block mb-1 text-xs font-medium text-gray-600 dark:text-gray-300"
|
|
100
100
|
}, [
|
|
101
|
-
|
|
102
|
-
t("code", K,
|
|
103
|
-
|
|
101
|
+
c(l(e.language?.type_to_confirm ?? "Type") + " ", 1),
|
|
102
|
+
t("code", K, l(e.confirm_text), 1),
|
|
103
|
+
c(" " + l(e.language?.to_confirm ?? "to confirm"), 1)
|
|
104
104
|
], 8, F),
|
|
105
105
|
h(t("input", {
|
|
106
106
|
id: o.inputId,
|
|
107
107
|
ref: "confirmInput",
|
|
108
|
-
"onUpdate:modelValue":
|
|
108
|
+
"onUpdate:modelValue": n[0] || (n[0] = (m) => o.typedText = m),
|
|
109
109
|
type: "text",
|
|
110
110
|
autocomplete: "off",
|
|
111
111
|
spellcheck: "false",
|
|
112
112
|
class: "gl-input-form",
|
|
113
|
-
onKeydown:
|
|
113
|
+
onKeydown: n[1] || (n[1] = v(k((...m) => i.confirmAction && i.confirmAction(...m), ["prevent"]), ["enter"]))
|
|
114
114
|
}, null, 40, z), [
|
|
115
115
|
[w, o.typedText]
|
|
116
116
|
])
|
|
@@ -119,26 +119,26 @@ function q(l, e, n, o, d, i) {
|
|
|
119
119
|
])
|
|
120
120
|
]),
|
|
121
121
|
t("div", U, [
|
|
122
|
-
x(
|
|
122
|
+
x(s, {
|
|
123
123
|
onClick: i.confirmAction,
|
|
124
124
|
tag: "button",
|
|
125
125
|
button_type: "red",
|
|
126
126
|
is_disabled: !i.canConfirm
|
|
127
127
|
}, {
|
|
128
|
-
default:
|
|
129
|
-
|
|
128
|
+
default: g(() => [
|
|
129
|
+
c(l(e.button_text), 1)
|
|
130
130
|
]),
|
|
131
131
|
_: 1
|
|
132
132
|
}, 8, ["onClick", "is_disabled"]),
|
|
133
|
-
x(
|
|
133
|
+
x(s, {
|
|
134
134
|
ref: "cancelButton",
|
|
135
135
|
onClick: i.cancelAction,
|
|
136
136
|
tag: "button",
|
|
137
137
|
button_type: "light"
|
|
138
138
|
}, {
|
|
139
|
-
default:
|
|
140
|
-
|
|
141
|
-
])
|
|
139
|
+
default: g(() => [
|
|
140
|
+
c(l(e.language?.cancel ?? "Cancel"), 1)
|
|
141
|
+
]),
|
|
142
142
|
_: 1
|
|
143
143
|
}, 8, ["onClick"])
|
|
144
144
|
])
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { createElementBlock as s, openBlock as c, toDisplayString as
|
|
2
|
-
import
|
|
3
|
-
const
|
|
1
|
+
import { createElementBlock as s, openBlock as c, toDisplayString as d } from "vue";
|
|
2
|
+
import i from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
+
const l = {
|
|
4
4
|
props: ["field", "row", "tdProps"],
|
|
5
5
|
computed: {
|
|
6
6
|
formattedDate() {
|
|
7
7
|
if (!this.row[this.field])
|
|
8
8
|
return "";
|
|
9
|
-
const t = new Date(this.row[this.field]), e = t.getFullYear(), o = t.toLocaleString("default", { month: "long" }), r = t.getDate();
|
|
9
|
+
const t = new Date(this.row[this.field]), e = t.getFullYear(), o = t.toLocaleString(document.documentElement.lang || "default", { month: "long" }), r = t.getDate();
|
|
10
10
|
return `${o} ${r}, ${e}`;
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
|
-
},
|
|
14
|
-
function
|
|
15
|
-
return c(), s("div",
|
|
13
|
+
}, m = { class: "w-full" };
|
|
14
|
+
function f(t, e, o, r, a, n) {
|
|
15
|
+
return c(), s("div", m, d(n.formattedDate), 1);
|
|
16
16
|
}
|
|
17
|
-
const _ = /* @__PURE__ */
|
|
17
|
+
const _ = /* @__PURE__ */ i(l, [["render", f]]);
|
|
18
18
|
export {
|
|
19
19
|
_ as default
|
|
20
20
|
};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { ref as
|
|
2
|
-
import { useGlFloatingMenu as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
const
|
|
1
|
+
import { ref as C, resolveDirective as M, createElementBlock as i, openBlock as d, Fragment as O, createVNode as _, withDirectives as g, createCommentVNode as m, createElementVNode as e, unref as r, normalizeStyle as j, withModifiers as A, createTextVNode as S, toDisplayString as B, vShow as N } from "vue";
|
|
2
|
+
import { useGlFloatingMenu as V } from "./useGlFloatingMenu.js";
|
|
3
|
+
import $ from "../DeleteConfirmationModal.vue.js";
|
|
4
|
+
import f from "../../../Stores/toast.js";
|
|
5
|
+
const T = {
|
|
6
6
|
key: 0,
|
|
7
7
|
class: "flex lg:justify-center"
|
|
8
|
-
},
|
|
8
|
+
}, Z = {
|
|
9
9
|
class: "py-2 text-sm text-gray-700 dark:text-gray-200",
|
|
10
10
|
"aria-labelledby": "dropdownDividerButton"
|
|
11
|
-
},
|
|
11
|
+
}, z = { key: 0 }, P = {
|
|
12
12
|
__name: "DatatableDeleteAction",
|
|
13
13
|
props: {
|
|
14
14
|
field: {
|
|
@@ -30,43 +30,48 @@ const $ = {
|
|
|
30
30
|
tdProps: {
|
|
31
31
|
type: Object,
|
|
32
32
|
default: {}
|
|
33
|
+
},
|
|
34
|
+
language: {
|
|
35
|
+
type: Object,
|
|
36
|
+
default: () => ({})
|
|
33
37
|
}
|
|
34
38
|
},
|
|
35
39
|
emits: ["deleteAction"],
|
|
36
|
-
setup(
|
|
37
|
-
const a =
|
|
40
|
+
setup(t, { emit: p }) {
|
|
41
|
+
const a = t, { open: y, menu: v, style: h, toggle: c, close: u } = V(), s = C(!1), n = () => {
|
|
38
42
|
s.value = !1;
|
|
39
43
|
}, w = () => {
|
|
40
44
|
u(), s.value = !0;
|
|
41
|
-
}, x =
|
|
45
|
+
}, x = p, b = () => {
|
|
42
46
|
axios.delete(`${a.xprops.route}/${a.row.id}`).then(() => {
|
|
43
|
-
|
|
44
|
-
message: "Item deleted successfully.",
|
|
47
|
+
n(), x("deleteAction"), f.methods.add({
|
|
48
|
+
message: a.language?.item_deleted_successfully ?? "Item deleted successfully.",
|
|
45
49
|
type: "success",
|
|
46
50
|
duration: 5e3
|
|
47
51
|
});
|
|
48
52
|
}).catch((l) => {
|
|
49
|
-
|
|
53
|
+
n(), f.methods.add({
|
|
50
54
|
message: l.response?.data?.message ?? a.language?.delete_failed ?? "That item could not be deleted.",
|
|
51
55
|
type: "error",
|
|
52
56
|
duration: 5e3
|
|
53
57
|
});
|
|
54
58
|
});
|
|
55
59
|
};
|
|
56
|
-
return (l,
|
|
57
|
-
const
|
|
58
|
-
return
|
|
59
|
-
|
|
60
|
+
return (l, o) => {
|
|
61
|
+
const k = M("click-outside");
|
|
62
|
+
return d(), i(O, null, [
|
|
63
|
+
_($, {
|
|
64
|
+
language: t.language,
|
|
60
65
|
isOpen: s.value,
|
|
61
|
-
onConfirmDelete:
|
|
62
|
-
onCancelDelete:
|
|
63
|
-
}, null, 8, ["isOpen"]),
|
|
64
|
-
|
|
66
|
+
onConfirmDelete: b,
|
|
67
|
+
onCancelDelete: n
|
|
68
|
+
}, null, 8, ["language", "isOpen"]),
|
|
69
|
+
t.row && l.can(`delete_${t.xprops.permission}`) ? g((d(), i("div", T, [
|
|
65
70
|
e("button", {
|
|
66
|
-
onClick:
|
|
71
|
+
onClick: o[0] || (o[0] = (...D) => r(c) && r(c)(...D)),
|
|
67
72
|
class: "inline-flex items-center p-2 text-sm font-medium text-center text-gray-900 bg-white rounded-lg hover:bg-gray-100 focus:ring-4 focus:outline-hidden dark:text-white focus:ring-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700 dark:focus:ring-gray-600",
|
|
68
73
|
type: "button"
|
|
69
|
-
},
|
|
74
|
+
}, o[1] || (o[1] = [
|
|
70
75
|
e("svg", {
|
|
71
76
|
class: "w-5 h-5",
|
|
72
77
|
"aria-hidden": "true",
|
|
@@ -77,34 +82,34 @@ const $ = {
|
|
|
77
82
|
e("path", { d: "M3.5 1.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 6.041a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 5.959a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Z" })
|
|
78
83
|
], -1)
|
|
79
84
|
])),
|
|
80
|
-
|
|
85
|
+
g(e("div", {
|
|
81
86
|
ref_key: "menu",
|
|
82
87
|
ref: v,
|
|
83
|
-
style:
|
|
88
|
+
style: j(r(h)),
|
|
84
89
|
class: "fixed z-50 bg-white divide-y divide-gray-100 rounded-lg shadow-sm w-44 dark:bg-gray-700 dark:divide-gray-600"
|
|
85
90
|
}, [
|
|
86
|
-
e("ul",
|
|
87
|
-
l.can(`delete_${
|
|
91
|
+
e("ul", Z, [
|
|
92
|
+
l.can(`delete_${t.xprops.permission}`) ? (d(), i("li", z, [
|
|
88
93
|
e("a", {
|
|
89
94
|
href: "#",
|
|
90
|
-
onClick:
|
|
95
|
+
onClick: A(w, ["prevent"]),
|
|
91
96
|
class: "block px-4 py-2 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white"
|
|
92
|
-
},
|
|
93
|
-
e("i", { class: "mr-2 fa-solid fa-trash-can opacity-80" }, null, -1),
|
|
94
|
-
B("
|
|
95
|
-
])
|
|
96
|
-
])) :
|
|
97
|
+
}, [
|
|
98
|
+
o[2] || (o[2] = e("i", { class: "mr-2 fa-solid fa-trash-can opacity-80" }, null, -1)),
|
|
99
|
+
S(" " + B(t.language?.remove ?? "Remove"), 1)
|
|
100
|
+
])
|
|
101
|
+
])) : m("", !0)
|
|
97
102
|
])
|
|
98
103
|
], 4), [
|
|
99
|
-
[N,
|
|
104
|
+
[N, r(y)]
|
|
100
105
|
])
|
|
101
106
|
])), [
|
|
102
|
-
[
|
|
103
|
-
]) :
|
|
107
|
+
[k, r(u)]
|
|
108
|
+
]) : m("", !0)
|
|
104
109
|
], 64);
|
|
105
110
|
};
|
|
106
111
|
}
|
|
107
112
|
};
|
|
108
113
|
export {
|
|
109
|
-
|
|
114
|
+
P as default
|
|
110
115
|
};
|
|
@@ -1,31 +1,37 @@
|
|
|
1
|
-
import { createElementBlock as t, openBlock as
|
|
2
|
-
import
|
|
3
|
-
const
|
|
4
|
-
props:
|
|
1
|
+
import { createElementBlock as t, openBlock as n, createCommentVNode as i, createElementVNode as s, createTextVNode as a, toDisplayString as d } from "vue";
|
|
2
|
+
import o from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
+
const u = {
|
|
4
|
+
props: {
|
|
5
|
+
field: null,
|
|
6
|
+
row: null,
|
|
7
|
+
tdProps: null,
|
|
8
|
+
// Texts in the table's language; without it the badges read Active / Inactive.
|
|
9
|
+
language: { type: Object, default: () => ({}) }
|
|
10
|
+
},
|
|
5
11
|
computed: {
|
|
6
12
|
isActive() {
|
|
7
13
|
return this.row[this.field] === 1;
|
|
8
14
|
}
|
|
9
15
|
}
|
|
10
|
-
},
|
|
16
|
+
}, c = { class: "flex flex-wrap gap-2 text-nowrap" }, f = {
|
|
11
17
|
key: 0,
|
|
12
18
|
class: "inline-flex items-center px-2 py-1 text-xs font-medium text-green-800 bg-green-100 rounded-full dark:bg-green-900 dark:text-green-300"
|
|
13
19
|
}, p = {
|
|
14
20
|
key: 1,
|
|
15
21
|
class: "inline-flex items-center px-2 py-1 bg-red-100 text-red-800 text-xs font-medium rounded-full dark:bg-red-900 dark:text-red-300"
|
|
16
22
|
};
|
|
17
|
-
function
|
|
18
|
-
return
|
|
19
|
-
|
|
20
|
-
s("span", { class: "w-2 h-2 bg-green-500 rounded-full me-1" }, null, -1),
|
|
21
|
-
|
|
22
|
-
]))
|
|
23
|
-
s("span", { class: "w-2 h-2 bg-red-500 rounded-full me-1" }, null, -1),
|
|
24
|
-
|
|
25
|
-
]))
|
|
23
|
+
function g(x, e, r, m, _, l) {
|
|
24
|
+
return n(), t("div", c, [
|
|
25
|
+
l.isActive ? (n(), t("span", f, [
|
|
26
|
+
e[0] || (e[0] = s("span", { class: "w-2 h-2 bg-green-500 rounded-full me-1" }, null, -1)),
|
|
27
|
+
a(" " + d(r.language?.active ?? "Active"), 1)
|
|
28
|
+
])) : l.isActive ? i("", !0) : (n(), t("span", p, [
|
|
29
|
+
e[1] || (e[1] = s("span", { class: "w-2 h-2 bg-red-500 rounded-full me-1" }, null, -1)),
|
|
30
|
+
a(" " + d(r.language?.inactive ?? "Inactive"), 1)
|
|
31
|
+
]))
|
|
26
32
|
]);
|
|
27
33
|
}
|
|
28
|
-
const
|
|
34
|
+
const v = /* @__PURE__ */ o(u, [["render", g]]);
|
|
29
35
|
export {
|
|
30
|
-
|
|
36
|
+
v as default
|
|
31
37
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import L from "../../../node_modules/vue3-print-nb/dist/vue3-print-nb.es.js";
|
|
2
|
-
import { resolveComponent as D, resolveDirective as E, createElementBlock as i, openBlock as d, withDirectives as T, createElementVNode as r, createCommentVNode as j, toDisplayString as
|
|
2
|
+
import { resolveComponent as D, resolveDirective as E, createElementBlock as i, openBlock as d, withDirectives as T, createElementVNode as r, createCommentVNode as j, toDisplayString as o, createVNode as k, vModelText as O, withCtx as M, createTextVNode as f, Fragment as m, renderList as _, withModifiers as w, normalizeClass as v } from "vue";
|
|
3
3
|
/* empty css */
|
|
4
4
|
import A from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
5
5
|
const H = {
|
|
@@ -83,7 +83,7 @@ const H = {
|
|
|
83
83
|
},
|
|
84
84
|
methods: {
|
|
85
85
|
async exportToExcel() {
|
|
86
|
-
const t = await import("xlsx"), e = t.default || t, a = document.querySelector("#table" + this.Random_string), g = Array.from(a.querySelectorAll("thead th")).map((c) => c.innerText),
|
|
86
|
+
const t = await import("xlsx"), e = t.default || t, a = document.querySelector("#table" + this.Random_string), g = Array.from(a.querySelectorAll("thead th")).map((c) => c.innerText), l = ["", ...["action"]], y = g.map((c, b) => l.includes(c) ? b : -1).filter((c) => c !== -1), p = Array.from(a.querySelectorAll("tbody tr")).map((c) => Array.from(c.querySelectorAll("td")).map((C) => C.innerText).filter((C, S) => !y.includes(S))), s = [g.filter((c, b) => !y.includes(b)), ...p], h = e.utils.aoa_to_sheet(s), x = e.utils.book_new();
|
|
87
87
|
e.utils.book_append_sheet(x, h, "Sheet1"), e.writeFile(x, "exported-file.xlsx");
|
|
88
88
|
},
|
|
89
89
|
generateRandomString(t) {
|
|
@@ -143,8 +143,8 @@ const H = {
|
|
|
143
143
|
}, te = ["innerHTML"], re = {
|
|
144
144
|
key: 0,
|
|
145
145
|
class: "flex items-center justify-between px-4 py-3 bg-white border-gray-200 sm:px-6 dark:text-gray-400 dark:bg-gray-800"
|
|
146
|
-
}, ae = { class: "flex flex-col items-center w-full gap-2" }, se = { class: "text-sm text-gray-700 dark:text-gray-400" }, ne = { class: "font-semibold text-gray-900 dark:text-white" },
|
|
147
|
-
function ce(t, e, a, g, n,
|
|
146
|
+
}, ae = { class: "flex flex-col items-center w-full gap-2" }, se = { class: "text-sm text-gray-700 dark:text-gray-400" }, ne = { class: "font-semibold text-gray-900 dark:text-white" }, le = { class: "font-semibold text-gray-900 dark:text-white" }, oe = { class: "font-semibold text-gray-900 dark:text-white" }, ie = { "aria-label": "Page navigation" }, de = { class: "flex items-center h-8 -space-x-px text-sm" }, ge = ["onClick", "aria-current"];
|
|
147
|
+
function ce(t, e, a, g, n, l) {
|
|
148
148
|
const y = D("dropdown"), p = D("gl-button"), P = E("print");
|
|
149
149
|
return d(), i("div", V, [
|
|
150
150
|
T(r("button", B, null, 512), [
|
|
@@ -152,9 +152,10 @@ function ce(t, e, a, g, n, o) {
|
|
|
152
152
|
]),
|
|
153
153
|
r("div", I, [
|
|
154
154
|
r("div", K, [
|
|
155
|
-
r("span", q,
|
|
155
|
+
r("span", q, o(a.language?.show ?? "Show"), 1),
|
|
156
156
|
r("div", R, [
|
|
157
157
|
k(y, {
|
|
158
|
+
language: a.language,
|
|
158
159
|
has_cancel: !1,
|
|
159
160
|
options: n.showNoOfEntries,
|
|
160
161
|
modelValue: n.itemsPerPage,
|
|
@@ -164,10 +165,10 @@ function ce(t, e, a, g, n, o) {
|
|
|
164
165
|
label_name: "",
|
|
165
166
|
default_value: 10,
|
|
166
167
|
show: !1,
|
|
167
|
-
placeholder: "Please select an option"
|
|
168
|
-
}, null, 8, ["options", "modelValue"])
|
|
168
|
+
placeholder: a.language?.please_select_an_option ?? "Please select an option"
|
|
169
|
+
}, null, 8, ["language", "options", "modelValue", "placeholder"])
|
|
169
170
|
]),
|
|
170
|
-
r("span", N,
|
|
171
|
+
r("span", N, o(a.language?.entries ?? "Entries"), 1)
|
|
171
172
|
]),
|
|
172
173
|
e[5] || (e[5] = r("label", {
|
|
173
174
|
for: "table-search",
|
|
@@ -187,7 +188,7 @@ function ce(t, e, a, g, n, o) {
|
|
|
187
188
|
]),
|
|
188
189
|
r("div", z, [
|
|
189
190
|
k(p, {
|
|
190
|
-
onClick:
|
|
191
|
+
onClick: l.delayedPrint,
|
|
191
192
|
tag: "button",
|
|
192
193
|
is_loading: t.isLoadingPrint,
|
|
193
194
|
button_type: "light",
|
|
@@ -198,12 +199,12 @@ function ce(t, e, a, g, n, o) {
|
|
|
198
199
|
</svg>`
|
|
199
200
|
}, {
|
|
200
201
|
default: M(() => [
|
|
201
|
-
f(
|
|
202
|
+
f(o(a.language?.print ?? "Print"), 1)
|
|
202
203
|
]),
|
|
203
204
|
_: 1
|
|
204
205
|
}, 8, ["onClick", "is_loading"]),
|
|
205
206
|
k(p, {
|
|
206
|
-
onClick:
|
|
207
|
+
onClick: l.exportToExcel,
|
|
207
208
|
tag: "button",
|
|
208
209
|
button_type: "light",
|
|
209
210
|
has_border_reduced: !1,
|
|
@@ -214,7 +215,7 @@ function ce(t, e, a, g, n, o) {
|
|
|
214
215
|
`
|
|
215
216
|
}, {
|
|
216
217
|
default: M(() => [
|
|
217
|
-
f(
|
|
218
|
+
f(o(a.language?.excel ?? "Excel"), 1)
|
|
218
219
|
]),
|
|
219
220
|
_: 1
|
|
220
221
|
}, 8, ["onClick"])
|
|
@@ -231,11 +232,11 @@ function ce(t, e, a, g, n, o) {
|
|
|
231
232
|
r("tr", null, [
|
|
232
233
|
(d(!0), i(m, null, _(a.columns, (s, h) => (d(), i("th", {
|
|
233
234
|
key: h,
|
|
234
|
-
onClick: w((x) =>
|
|
235
|
+
onClick: w((x) => l.sort(s), ["prevent"]),
|
|
235
236
|
class: "w-full px-4 py-2 lg:w-2/12 print:w-2/12! print:border!"
|
|
236
237
|
}, [
|
|
237
238
|
r("div", J, [
|
|
238
|
-
r("span", null,
|
|
239
|
+
r("span", null, o(s), 1),
|
|
239
240
|
n.sortKey === s ? (d(), i("span", Q, e[6] || (e[6] = [
|
|
240
241
|
r("svg", {
|
|
241
242
|
class: "w-4 h-4",
|
|
@@ -258,7 +259,7 @@ function ce(t, e, a, g, n, o) {
|
|
|
258
259
|
])
|
|
259
260
|
]),
|
|
260
261
|
r("tbody", Y, [
|
|
261
|
-
(d(!0), i(m, null, _(
|
|
262
|
+
(d(!0), i(m, null, _(l.paginatedData, (s, h) => (d(), i("tr", {
|
|
262
263
|
key: h,
|
|
263
264
|
class: "text-gray-500 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
|
264
265
|
}, [
|
|
@@ -270,7 +271,7 @@ function ce(t, e, a, g, n, o) {
|
|
|
270
271
|
"rounded-b-lg lg:rounded-b-none!": u === a.columns.length - 1
|
|
271
272
|
}])
|
|
272
273
|
}, [
|
|
273
|
-
a.escape_html ? (d(), i("p", ee,
|
|
274
|
+
a.escape_html ? (d(), i("p", ee, o(s[u]), 1)) : (d(), i("p", {
|
|
274
275
|
key: 1,
|
|
275
276
|
class: "text-pretty",
|
|
276
277
|
innerHTML: s[u]
|
|
@@ -280,23 +281,23 @@ function ce(t, e, a, g, n, o) {
|
|
|
280
281
|
])
|
|
281
282
|
], 8, X)
|
|
282
283
|
], 8, U),
|
|
283
|
-
|
|
284
|
+
l.paginatedData.length > 0 ? (d(), i("div", re, [
|
|
284
285
|
r("div", ae, [
|
|
285
286
|
r("p", se, [
|
|
286
|
-
f(
|
|
287
|
-
r("span", ne, l
|
|
288
|
-
f(" " +
|
|
289
|
-
r("span",
|
|
290
|
-
f(" " +
|
|
291
|
-
r("span",
|
|
292
|
-
f(" " +
|
|
287
|
+
f(o(a.language?.showing ?? "Showing") + " ", 1),
|
|
288
|
+
r("span", ne, o(l.firstItemIndex), 1),
|
|
289
|
+
f(" " + o(a.language?.to ?? "to") + " ", 1),
|
|
290
|
+
r("span", le, o(l.lastItemIndex), 1),
|
|
291
|
+
f(" " + o(a.language?.of ?? "of") + " ", 1),
|
|
292
|
+
r("span", oe, o(l.filteredData.length), 1),
|
|
293
|
+
f(" " + o(a.language?.entries ?? "entries"), 1)
|
|
293
294
|
]),
|
|
294
295
|
r("nav", ie, [
|
|
295
296
|
r("ul", de, [
|
|
296
297
|
r("li", null, [
|
|
297
298
|
r("a", {
|
|
298
299
|
href: "#",
|
|
299
|
-
onClick: e[2] || (e[2] = w((...s) =>
|
|
300
|
+
onClick: e[2] || (e[2] = w((...s) => l.previousPage && l.previousPage(...s), ["prevent"])),
|
|
300
301
|
class: "flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 ms-0 border-e-0 rounded-s-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"
|
|
301
302
|
}, e[7] || (e[7] = [
|
|
302
303
|
r("span", { class: "sr-only" }, "Previous", -1),
|
|
@@ -317,21 +318,21 @@ function ce(t, e, a, g, n, o) {
|
|
|
317
318
|
], -1)
|
|
318
319
|
]))
|
|
319
320
|
]),
|
|
320
|
-
(d(!0), i(m, null, _(
|
|
321
|
+
(d(!0), i(m, null, _(l.displayedPageNumbers, (s) => (d(), i("li", {
|
|
321
322
|
key: s,
|
|
322
323
|
class: v(Math.abs(s - n.currentPage) > 2 ? "hidden sm:block" : "")
|
|
323
324
|
}, [
|
|
324
325
|
r("a", {
|
|
325
326
|
href: "#",
|
|
326
|
-
onClick: w((h) =>
|
|
327
|
+
onClick: w((h) => l.goToPage(s), ["prevent"]),
|
|
327
328
|
class: v(n.currentPage === s ? "z-10 flex items-center justify-center h-8 px-3 leading-tight text-blue-600 border border-blue-300 bg-blue-50 hover:bg-blue-100 hover:text-blue-700 dark:border-gray-700 dark:bg-gray-700 dark:text-white" : "flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"),
|
|
328
329
|
"aria-current": n.currentPage === s ? "page" : void 0
|
|
329
|
-
},
|
|
330
|
+
}, o(s), 11, ge)
|
|
330
331
|
], 2))), 128)),
|
|
331
332
|
r("li", null, [
|
|
332
333
|
r("a", {
|
|
333
334
|
href: "#",
|
|
334
|
-
onClick: e[3] || (e[3] = w((...s) =>
|
|
335
|
+
onClick: e[3] || (e[3] = w((...s) => l.nextPage && l.nextPage(...s), ["prevent"])),
|
|
335
336
|
class: "flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 rounded-e-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"
|
|
336
337
|
}, e[8] || (e[8] = [
|
|
337
338
|
r("span", { class: "sr-only" }, "Next", -1),
|
|
@@ -358,7 +359,7 @@ function ce(t, e, a, g, n, o) {
|
|
|
358
359
|
])) : j("", !0)
|
|
359
360
|
]);
|
|
360
361
|
}
|
|
361
|
-
const ye = /* @__PURE__ */ A(H, [["render", ce], ["__scopeId", "data-v-
|
|
362
|
+
const ye = /* @__PURE__ */ A(H, [["render", ce], ["__scopeId", "data-v-5ce108ff"]]);
|
|
362
363
|
export {
|
|
363
364
|
ye as default
|
|
364
365
|
};
|
|
@@ -336,6 +336,7 @@ function Ie(t, s, i, d, a, r) {
|
|
|
336
336
|
l("span", ee, u(i.language?.show ?? "Show"), 1),
|
|
337
337
|
l("div", te, [
|
|
338
338
|
x(F, {
|
|
339
|
+
language: i.language,
|
|
339
340
|
options_top_size: 0,
|
|
340
341
|
has_cancel: !1,
|
|
341
342
|
options: a.pageOptions,
|
|
@@ -346,8 +347,8 @@ function Ie(t, s, i, d, a, r) {
|
|
|
346
347
|
label_name: "",
|
|
347
348
|
default_value: 5,
|
|
348
349
|
show: !1,
|
|
349
|
-
placeholder: "Please select an option"
|
|
350
|
-
}, null, 8, ["options", "modelValue"])
|
|
350
|
+
placeholder: i.language?.please_select_an_option ?? "Please select an option"
|
|
351
|
+
}, null, 8, ["language", "options", "modelValue", "placeholder"])
|
|
351
352
|
]),
|
|
352
353
|
l("span", le, u(i.language?.entries ?? "Entries"), 1)
|
|
353
354
|
]),
|
|
@@ -374,6 +375,7 @@ function Ie(t, s, i, d, a, r) {
|
|
|
374
375
|
(o(!0), c(f, null, v(r.customFilters, (e, h) => (o(), c(f, { key: h }, [
|
|
375
376
|
e.type == "dropdown" ? (o(), _(D, {
|
|
376
377
|
key: 0,
|
|
378
|
+
language: i.language,
|
|
377
379
|
has_cancel: !0,
|
|
378
380
|
options: e.options,
|
|
379
381
|
modelValue: a.dynamicFilters[e.field_name],
|
|
@@ -383,7 +385,7 @@ function Ie(t, s, i, d, a, r) {
|
|
|
383
385
|
label_name: e.field_label,
|
|
384
386
|
show: !1,
|
|
385
387
|
placeholder: i.language?.please_select_an_option ?? "Please select an option"
|
|
386
|
-
}, null, 8, ["options", "modelValue", "onUpdate:modelValue", "field_name", "label_name", "placeholder"])) : g("", !0),
|
|
388
|
+
}, null, 8, ["language", "options", "modelValue", "onUpdate:modelValue", "field_name", "label_name", "placeholder"])) : g("", !0),
|
|
387
389
|
e.type == "text" ? (o(), _(k, {
|
|
388
390
|
key: 1,
|
|
389
391
|
type: "text",
|
|
@@ -419,6 +421,7 @@ function Ie(t, s, i, d, a, r) {
|
|
|
419
421
|
e.hasOwnFilter && Object.keys(e.hasOwnFilter).length > 0 ? (o(), c(f, { key: 0 }, [
|
|
420
422
|
e.hasOwnFilter.type == "dropdown" ? (o(), _(D, {
|
|
421
423
|
key: 0,
|
|
424
|
+
language: i.language,
|
|
422
425
|
has_cancel: !0,
|
|
423
426
|
options: e.hasOwnFilter.options,
|
|
424
427
|
modelValue: a.dynamicFilters[e.field_name],
|
|
@@ -428,7 +431,7 @@ function Ie(t, s, i, d, a, r) {
|
|
|
428
431
|
label_name: e.field_label,
|
|
429
432
|
show: !1,
|
|
430
433
|
placeholder: i.language?.please_select_an_option ?? "Please select an option"
|
|
431
|
-
}, null, 8, ["options", "modelValue", "onUpdate:modelValue", "field_name", "label_name", "placeholder"])) : g("", !0),
|
|
434
|
+
}, null, 8, ["language", "options", "modelValue", "onUpdate:modelValue", "field_name", "label_name", "placeholder"])) : g("", !0),
|
|
432
435
|
e.hasOwnFilter.type == "text" ? (o(), _(k, {
|
|
433
436
|
key: 1,
|
|
434
437
|
type: "text",
|
|
@@ -781,7 +784,7 @@ function Ie(t, s, i, d, a, r) {
|
|
|
781
784
|
])
|
|
782
785
|
], 64);
|
|
783
786
|
}
|
|
784
|
-
const Ee = /* @__PURE__ */ J(X, [["render", Ie], ["__scopeId", "data-v-
|
|
787
|
+
const Ee = /* @__PURE__ */ J(X, [["render", Ie], ["__scopeId", "data-v-95fa873e"]]);
|
|
785
788
|
export {
|
|
786
789
|
Ee as default
|
|
787
790
|
};
|
|
@@ -194,6 +194,7 @@ function ye(t, r, s, h, n, l) {
|
|
|
194
194
|
e("span", G, c(s.language?.show ?? "Show"), 1),
|
|
195
195
|
e("div", N, [
|
|
196
196
|
k(x, {
|
|
197
|
+
language: s.language,
|
|
197
198
|
has_cancel: !1,
|
|
198
199
|
options: n.showNoOfEntries,
|
|
199
200
|
modelValue: n.itemsPerPage,
|
|
@@ -203,8 +204,8 @@ function ye(t, r, s, h, n, l) {
|
|
|
203
204
|
label_name: "",
|
|
204
205
|
default_value: 10,
|
|
205
206
|
show: !1,
|
|
206
|
-
placeholder: "Please select an option"
|
|
207
|
-
}, null, 8, ["options", "modelValue"])
|
|
207
|
+
placeholder: s.language?.please_select_an_option ?? "Please select an option"
|
|
208
|
+
}, null, 8, ["language", "options", "modelValue", "placeholder"])
|
|
208
209
|
]),
|
|
209
210
|
e("span", F, c(s.language?.entries ?? "Entries"), 1)
|
|
210
211
|
]),
|
|
@@ -464,7 +465,7 @@ function ye(t, r, s, h, n, l) {
|
|
|
464
465
|
])) : v("", !0)
|
|
465
466
|
]);
|
|
466
467
|
}
|
|
467
|
-
const ve = /* @__PURE__ */ B(H, [["render", ye], ["__scopeId", "data-v-
|
|
468
|
+
const ve = /* @__PURE__ */ B(H, [["render", ye], ["__scopeId", "data-v-6d6a6ad9"]]);
|
|
468
469
|
export {
|
|
469
470
|
ve as default
|
|
470
471
|
};
|