gzhr-ui 1.0.1 → 1.0.3
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/es/{button-BSV1RhB8.mjs → button-CJ1kU7r2.mjs} +1 -1
- package/dist/es/{icon-PcypvbAz.mjs → icon-DOZyC-Pg.mjs} +2 -2
- package/dist/es/index.mjs +8 -6
- package/dist/es/{table-CCZNlgwQ.mjs → table-BSFBnDtq.mjs} +187 -191
- package/dist/es/{utils-CRsNpc-W.mjs → utils-T1zvC3Cf.mjs} +1 -1
- package/dist/es/{vendor-JYnb-2AB.mjs → vendor-WGaPw_tu.mjs} +36244 -35721
- package/dist/index.css +1 -1
- package/dist/types/components/table/index.d.ts +2552 -2545
- package/dist/types/components/table/src/index.vue.d.ts +2 -0
- package/dist/types/core/index.d.ts +1 -1
- package/dist/umd/index.css +1 -1
- package/dist/umd/index.umd.js +12 -12
- package/package.json +38 -37
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { a as ElInput, C as ClickOutside, b as ElPopover, V as VxeInput, c as ElButton, d as ElCheckboxGroup, e as ElCheckbox, f as ElTreeSelect, g as ElInputNumber, E as ElIcon, h as ElDropdown, i as ElDropdownMenu, j as ElDropdownItem, k as ElTag, l as isEmpty, m as ElColorPicker, n as dayjs, o as isoWeek, q as quarterOfYear, p as customParseFormat, r as ElImage, s as ElProgress, t as ElRadioGroup, u as ElRadio, v as ElSelect, w as ElOption, x as VxePager, y as VxeGrid, z as VxeUI } from "./vendor-
|
|
1
|
+
import { a as ElInput, C as ClickOutside, b as ElPopover, V as VxeInput, c as ElButton, d as ElCheckboxGroup, e as ElCheckbox, f as ElTreeSelect, g as ElInputNumber, E as ElIcon, h as ElDropdown, i as ElDropdownMenu, j as ElDropdownItem, k as ElTag, l as isEmpty, m as ElColorPicker, n as dayjs, o as isoWeek, q as quarterOfYear, p as customParseFormat, r as ElImage, s as ElProgress, t as ElRadioGroup, u as ElRadio, v as ElSelect, w as ElOption, x as VxePager, y as VxeGrid, z as VxeUI } from "./vendor-WGaPw_tu.mjs";
|
|
2
2
|
import { ref, computed, openBlock, createElementBlock, withDirectives, createVNode, unref, withCtx, createElementVNode, createTextVNode, withKeys, createBlock, Fragment, renderList, createCommentVNode, onMounted, defineComponent, resolveComponent, normalizeStyle, toDisplayString, watch, vShow, watchEffect, normalizeProps, mergeProps, resolveDirective, onBeforeUnmount, reactive } from "vue";
|
|
3
|
-
import { b as buildTree, d as deepClone, u as useElementClientSize, _ as _export_sfc, i as isColor, g as getFileIconUrl, p as preVideo, a as preCAD, w as withInstall } from "./utils-
|
|
3
|
+
import { b as buildTree, d as deepClone, u as useElementClientSize, _ as _export_sfc, i as isColor, g as getFileIconUrl, p as preVideo, a as preCAD, w as withInstall } from "./utils-T1zvC3Cf.mjs";
|
|
4
4
|
const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" }, _hoisted_3$3 = { class: "flex flex-col gap3" }, _hoisted_4$1 = { class: "flex justify-between" }, _sfc_main$x = {
|
|
5
5
|
__name: "filter-date",
|
|
6
6
|
props: {
|
|
@@ -12,9 +12,9 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
12
12
|
emits: ["FilterSearch"],
|
|
13
13
|
setup(r, { emit: e }) {
|
|
14
14
|
const t = r, o = ref([null, null]), n = computed(() => t.column.filters[0].data.length ? t.column.filters[0].data.join(" 至 ") : ""), c = ref(), l = ref(), a = () => {
|
|
15
|
-
var i,
|
|
16
|
-
(
|
|
17
|
-
},
|
|
15
|
+
var i, d;
|
|
16
|
+
(d = (i = unref(l).popperRef) == null ? void 0 : i.delayHide) == null || d.call(i);
|
|
17
|
+
}, s = e;
|
|
18
18
|
function m() {
|
|
19
19
|
if (!o.value[0] && !o.value[1])
|
|
20
20
|
t.column.filters[0].data = [];
|
|
@@ -23,12 +23,12 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
23
23
|
return;
|
|
24
24
|
} else
|
|
25
25
|
t.column.filters[0].data = [...o.value];
|
|
26
|
-
l.value.hide(),
|
|
26
|
+
l.value.hide(), s("FilterSearch", t.column);
|
|
27
27
|
}
|
|
28
28
|
function u() {
|
|
29
29
|
o.value = [null, null];
|
|
30
30
|
}
|
|
31
|
-
return (i,
|
|
31
|
+
return (i, d) => (openBlock(), createElementBlock("div", {
|
|
32
32
|
class: "size-full",
|
|
33
33
|
title: n.value
|
|
34
34
|
}, [
|
|
@@ -54,12 +54,12 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
54
54
|
createElementVNode("div", _hoisted_3$3, [
|
|
55
55
|
createVNode(unref(VxeInput), {
|
|
56
56
|
modelValue: o.value[0],
|
|
57
|
-
"onUpdate:modelValue":
|
|
57
|
+
"onUpdate:modelValue": d[0] || (d[0] = (f) => o.value[0] = f),
|
|
58
58
|
type: r.column.params.DateType || "date"
|
|
59
59
|
}, null, 8, ["modelValue", "type"]),
|
|
60
60
|
createVNode(unref(VxeInput), {
|
|
61
61
|
modelValue: o.value[1],
|
|
62
|
-
"onUpdate:modelValue":
|
|
62
|
+
"onUpdate:modelValue": d[1] || (d[1] = (f) => o.value[1] = f),
|
|
63
63
|
type: r.column.params.DateType || "date"
|
|
64
64
|
}, null, 8, ["modelValue", "type"])
|
|
65
65
|
]),
|
|
@@ -69,7 +69,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
69
69
|
type: "primary",
|
|
70
70
|
onClick: m
|
|
71
71
|
}, {
|
|
72
|
-
default: withCtx(() =>
|
|
72
|
+
default: withCtx(() => d[2] || (d[2] = [
|
|
73
73
|
createTextVNode("确认")
|
|
74
74
|
])),
|
|
75
75
|
_: 1
|
|
@@ -78,7 +78,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
78
78
|
size: "small",
|
|
79
79
|
onClick: u
|
|
80
80
|
}, {
|
|
81
|
-
default: withCtx(() =>
|
|
81
|
+
default: withCtx(() => d[3] || (d[3] = [
|
|
82
82
|
createTextVNode("重置")
|
|
83
83
|
])),
|
|
84
84
|
_: 1
|
|
@@ -103,7 +103,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
103
103
|
const t = r, o = ref([]), n = computed(() => t.column.filters[0].data.length ? t.column.filters[0].data.map((u) => u ? "是" : "否").join(",") : ""), c = ref(), l = ref(), a = () => {
|
|
104
104
|
var u, i;
|
|
105
105
|
(i = (u = unref(l).popperRef) == null ? void 0 : u.delayHide) == null || i.call(u);
|
|
106
|
-
},
|
|
106
|
+
}, s = e;
|
|
107
107
|
function m() {
|
|
108
108
|
o.value.length ? t.column.filters[0].data = [...o.value] : t.column.filters[0].data = [];
|
|
109
109
|
}
|
|
@@ -116,7 +116,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
116
116
|
ref: c,
|
|
117
117
|
value: n.value,
|
|
118
118
|
readonly: "",
|
|
119
|
-
onKeyup: i[0] || (i[0] = withKeys((
|
|
119
|
+
onKeyup: i[0] || (i[0] = withKeys((d) => s("FilterSearch", r.column), ["enter"]))
|
|
120
120
|
}, null, 8, ["value"]), [
|
|
121
121
|
[unref(ClickOutside), a]
|
|
122
122
|
]),
|
|
@@ -132,7 +132,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
132
132
|
createVNode(unref(ElCheckboxGroup), {
|
|
133
133
|
class: "flex flex-col",
|
|
134
134
|
modelValue: o.value,
|
|
135
|
-
"onUpdate:modelValue": i[1] || (i[1] = (
|
|
135
|
+
"onUpdate:modelValue": i[1] || (i[1] = (d) => o.value = d),
|
|
136
136
|
onChange: m
|
|
137
137
|
}, {
|
|
138
138
|
default: withCtx(() => [
|
|
@@ -166,11 +166,11 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
166
166
|
ref("");
|
|
167
167
|
const n = computed(() => t.column.filters[0].data.length ? t.column.filters[0].data.map((u) => {
|
|
168
168
|
var i;
|
|
169
|
-
return (i = t.column.params.options.find((
|
|
169
|
+
return (i = t.column.params.options.find((d) => d.value === u)) == null ? void 0 : i.label;
|
|
170
170
|
}).join(",") : ""), c = ref(), l = ref(), a = () => {
|
|
171
171
|
var u, i;
|
|
172
172
|
(i = (u = unref(l).popperRef) == null ? void 0 : u.delayHide) == null || i.call(u);
|
|
173
|
-
},
|
|
173
|
+
}, s = e;
|
|
174
174
|
function m() {
|
|
175
175
|
o.value.length ? t.column.filters[0].data = [...o.value] : t.column.filters[0].data = [];
|
|
176
176
|
}
|
|
@@ -183,7 +183,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
183
183
|
ref: c,
|
|
184
184
|
value: n.value,
|
|
185
185
|
readonly: "",
|
|
186
|
-
onKeyup: i[0] || (i[0] = withKeys((
|
|
186
|
+
onKeyup: i[0] || (i[0] = withKeys((d) => s("FilterSearch", r.column), ["enter"]))
|
|
187
187
|
}, null, 8, ["value"]), [
|
|
188
188
|
[unref(ClickOutside), a]
|
|
189
189
|
]),
|
|
@@ -200,14 +200,14 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
200
200
|
key: 0,
|
|
201
201
|
class: "flex flex-col",
|
|
202
202
|
modelValue: o.value,
|
|
203
|
-
"onUpdate:modelValue": i[1] || (i[1] = (
|
|
203
|
+
"onUpdate:modelValue": i[1] || (i[1] = (d) => o.value = d),
|
|
204
204
|
onChange: m
|
|
205
205
|
}, {
|
|
206
206
|
default: withCtx(() => [
|
|
207
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(r.column.params.options, (
|
|
208
|
-
key:
|
|
209
|
-
label:
|
|
210
|
-
value:
|
|
207
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(r.column.params.options, (d) => (openBlock(), createBlock(unref(ElCheckbox), {
|
|
208
|
+
key: d.value,
|
|
209
|
+
label: d.label,
|
|
210
|
+
value: d.value
|
|
211
211
|
}, null, 8, ["label", "value"]))), 128))
|
|
212
212
|
]),
|
|
213
213
|
_: 1
|
|
@@ -216,14 +216,14 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
216
216
|
key: 1,
|
|
217
217
|
class: "flex flex-col",
|
|
218
218
|
modelValue: o.value,
|
|
219
|
-
"onUpdate:modelValue": i[2] || (i[2] = (
|
|
219
|
+
"onUpdate:modelValue": i[2] || (i[2] = (d) => o.value = d),
|
|
220
220
|
onChange: m
|
|
221
221
|
}, {
|
|
222
222
|
default: withCtx(() => [
|
|
223
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(r.column.params.options, (
|
|
224
|
-
key:
|
|
225
|
-
label:
|
|
226
|
-
value:
|
|
223
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(r.column.params.options, (d) => (openBlock(), createBlock(unref(ElCheckbox), {
|
|
224
|
+
key: d.value,
|
|
225
|
+
label: d.label,
|
|
226
|
+
value: d.value
|
|
227
227
|
}, null, 8, ["label", "value"]))), 128))
|
|
228
228
|
]),
|
|
229
229
|
_: 1
|
|
@@ -256,7 +256,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
256
256
|
o.value = t.column.params.TreeData;
|
|
257
257
|
});
|
|
258
258
|
const a = e;
|
|
259
|
-
function
|
|
259
|
+
function s() {
|
|
260
260
|
n.value ? t.column.filters[0].data = [n.value] : t.column.filters[0].data = [];
|
|
261
261
|
}
|
|
262
262
|
return (m, u) => (openBlock(), createBlock(unref(ElTreeSelect), {
|
|
@@ -266,7 +266,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
266
266
|
data: o.value,
|
|
267
267
|
"render-after-expand": !1,
|
|
268
268
|
placeholder: "",
|
|
269
|
-
onChange:
|
|
269
|
+
onChange: s,
|
|
270
270
|
multiple: c.value,
|
|
271
271
|
"show-checkbox": c.value,
|
|
272
272
|
props: l.value,
|
|
@@ -299,7 +299,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
299
299
|
function a() {
|
|
300
300
|
n.value ? t.column.filters[0].data = n.value : t.column.filters[0].data = [];
|
|
301
301
|
}
|
|
302
|
-
function
|
|
302
|
+
function s(m) {
|
|
303
303
|
cleanUpTreeFilterRows(), l("FilterSearch", t.column);
|
|
304
304
|
}
|
|
305
305
|
return (m, u) => (openBlock(), createBlock(unref(ElTreeSelect), {
|
|
@@ -314,7 +314,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
314
314
|
"show-checkbox": "",
|
|
315
315
|
"collapse-tags": "",
|
|
316
316
|
"collapse-tags-tooltip": "",
|
|
317
|
-
onKeyup: withKeys(
|
|
317
|
+
onKeyup: withKeys(s, ["enter"]),
|
|
318
318
|
props: c.value
|
|
319
319
|
}, null, 8, ["modelValue", "data", "props"]));
|
|
320
320
|
}
|
|
@@ -329,9 +329,9 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
329
329
|
emits: ["FilterSearch"],
|
|
330
330
|
setup(r, { emit: e }) {
|
|
331
331
|
const t = r, o = ref([null, null]), n = computed(() => t.column.filters[0].data.length ? t.column.filters[0].data.join(" 至 ") : ""), c = ref(), l = ref(), a = () => {
|
|
332
|
-
var i,
|
|
333
|
-
(
|
|
334
|
-
},
|
|
332
|
+
var i, d;
|
|
333
|
+
(d = (i = unref(l).popperRef) == null ? void 0 : i.delayHide) == null || d.call(i);
|
|
334
|
+
}, s = e;
|
|
335
335
|
function m() {
|
|
336
336
|
if (!o.value[0] && !o.value[1])
|
|
337
337
|
t.column.filters[0].data = [];
|
|
@@ -340,12 +340,12 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
340
340
|
return;
|
|
341
341
|
} else
|
|
342
342
|
t.column.filters[0].data = [...o.value];
|
|
343
|
-
l.value.hide(),
|
|
343
|
+
l.value.hide(), s("FilterSearch", t.column);
|
|
344
344
|
}
|
|
345
345
|
function u() {
|
|
346
346
|
o.value = [null, null];
|
|
347
347
|
}
|
|
348
|
-
return (i,
|
|
348
|
+
return (i, d) => (openBlock(), createElementBlock("div", {
|
|
349
349
|
class: "size-full",
|
|
350
350
|
title: n.value
|
|
351
351
|
}, [
|
|
@@ -354,7 +354,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
354
354
|
ref: c,
|
|
355
355
|
value: n.value,
|
|
356
356
|
readonly: "",
|
|
357
|
-
onKeyup:
|
|
357
|
+
onKeyup: d[0] || (d[0] = withKeys((f) => s("FilterSearch", r.column), ["enter"]))
|
|
358
358
|
}, null, 8, ["value"]), [
|
|
359
359
|
[unref(ClickOutside), a]
|
|
360
360
|
]),
|
|
@@ -371,12 +371,12 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
371
371
|
createVNode(unref(ElInputNumber), {
|
|
372
372
|
class: "w-full",
|
|
373
373
|
modelValue: o.value[0],
|
|
374
|
-
"onUpdate:modelValue":
|
|
374
|
+
"onUpdate:modelValue": d[1] || (d[1] = (f) => o.value[0] = f)
|
|
375
375
|
}, null, 8, ["modelValue"]),
|
|
376
376
|
createVNode(unref(ElInputNumber), {
|
|
377
377
|
class: "w-full",
|
|
378
378
|
modelValue: o.value[1],
|
|
379
|
-
"onUpdate:modelValue":
|
|
379
|
+
"onUpdate:modelValue": d[2] || (d[2] = (f) => o.value[1] = f)
|
|
380
380
|
}, null, 8, ["modelValue"])
|
|
381
381
|
]),
|
|
382
382
|
createElementVNode("div", _hoisted_3$2, [
|
|
@@ -385,7 +385,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
385
385
|
type: "primary",
|
|
386
386
|
onClick: m
|
|
387
387
|
}, {
|
|
388
|
-
default: withCtx(() =>
|
|
388
|
+
default: withCtx(() => d[3] || (d[3] = [
|
|
389
389
|
createTextVNode("确认")
|
|
390
390
|
])),
|
|
391
391
|
_: 1
|
|
@@ -394,7 +394,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
394
394
|
size: "small",
|
|
395
395
|
onClick: u
|
|
396
396
|
}, {
|
|
397
|
-
default: withCtx(() =>
|
|
397
|
+
default: withCtx(() => d[4] || (d[4] = [
|
|
398
398
|
createTextVNode("重置")
|
|
399
399
|
])),
|
|
400
400
|
_: 1
|
|
@@ -426,8 +426,8 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
426
426
|
let n = ref(0);
|
|
427
427
|
onMounted(() => {
|
|
428
428
|
if (t.column.params.filter) {
|
|
429
|
-
const
|
|
430
|
-
useElementClientSize(
|
|
429
|
+
const s = document.querySelector(`[colid=${t.column.id}]`);
|
|
430
|
+
useElementClientSize(s, ({ clientHeight: m }) => {
|
|
431
431
|
n.value = m <= 40 ? 65 : m;
|
|
432
432
|
});
|
|
433
433
|
} else
|
|
@@ -435,24 +435,24 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
435
435
|
o.value = t.column.params.TreeData;
|
|
436
436
|
});
|
|
437
437
|
const c = e;
|
|
438
|
-
function l(
|
|
439
|
-
if (
|
|
438
|
+
function l(s) {
|
|
439
|
+
if (s === "search") {
|
|
440
440
|
const m = t.gridRef.getColumns();
|
|
441
441
|
c("FilterSearch", t.column, m);
|
|
442
|
-
} else
|
|
442
|
+
} else s === "clear" ? t.column.filters.forEach((m) => {
|
|
443
443
|
Array.isArray(m.data) ? m.data = [] : m.data = "";
|
|
444
|
-
}) :
|
|
444
|
+
}) : s === "clearAll" && t.gridRef.getColumns().forEach((u) => {
|
|
445
445
|
u.filters && u.filters.forEach((i) => {
|
|
446
446
|
Array.isArray(i.data) ? i.data = [] : i.data = "";
|
|
447
447
|
});
|
|
448
448
|
});
|
|
449
449
|
}
|
|
450
450
|
function a() {
|
|
451
|
-
var
|
|
452
|
-
(
|
|
451
|
+
var s;
|
|
452
|
+
(s = t.column).params ?? (s.params = {}), t.column.params.sortStatus === "asc" ? t.column.params.sortStatus = "desc" : t.column.params.sortStatus === "desc" ? t.column.params.sortStatus = null : t.column.params.sortStatus = "asc", c("SortChange", t.column, t.gridRef.getColumns());
|
|
453
453
|
}
|
|
454
|
-
return (
|
|
455
|
-
var i,
|
|
454
|
+
return (s, m) => {
|
|
455
|
+
var i, d;
|
|
456
456
|
const u = resolveComponent("hr-icon");
|
|
457
457
|
return openBlock(), createElementBlock("div", {
|
|
458
458
|
class: "flex flex-col filter-header",
|
|
@@ -467,7 +467,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
467
467
|
style: normalizeStyle({ color: r.column.params.Required ? "red" : "" }),
|
|
468
468
|
class: "whitespace-nowrap overflow-hidden text-ellipsis"
|
|
469
469
|
}, toDisplayString(r.column.title), 5),
|
|
470
|
-
(i = r.column.params) != null && i.sortable && ((
|
|
470
|
+
(i = r.column.params) != null && i.sortable && ((d = r.column.params) != null && d.sortStatus) ? (openBlock(), createBlock(unref(ElIcon), { key: 0 }, {
|
|
471
471
|
default: withCtx(() => {
|
|
472
472
|
var f, g;
|
|
473
473
|
return [
|
|
@@ -599,18 +599,18 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
599
599
|
n("ActionClick", { btnInfo: l, row: t.row, column: t.column, gridRef: t.gridRef });
|
|
600
600
|
}
|
|
601
601
|
return (l, a) => (openBlock(), createElementBlock("div", _hoisted_1$c, [
|
|
602
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(o), (
|
|
603
|
-
key:
|
|
602
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(o), (s) => withDirectives((openBlock(), createBlock(unref(ElButton), {
|
|
603
|
+
key: s.Name,
|
|
604
604
|
class: "!text-[12px]",
|
|
605
605
|
link: "",
|
|
606
|
-
onClick: (m) => c(
|
|
606
|
+
onClick: (m) => c(s)
|
|
607
607
|
}, {
|
|
608
608
|
default: withCtx(() => [
|
|
609
|
-
createTextVNode(toDisplayString(
|
|
609
|
+
createTextVNode(toDisplayString(s.Name), 1)
|
|
610
610
|
]),
|
|
611
611
|
_: 2
|
|
612
612
|
}, 1032, ["onClick"])), [
|
|
613
|
-
[vShow,
|
|
613
|
+
[vShow, s.hide !== !0]
|
|
614
614
|
])), 128))
|
|
615
615
|
]));
|
|
616
616
|
}
|
|
@@ -642,13 +642,13 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
642
642
|
typeof t.row[t.column.field] != "boolean" ? o.value = !!t.row[t.column.field] : o.value = t.row[t.column.field];
|
|
643
643
|
});
|
|
644
644
|
const n = e;
|
|
645
|
-
function c(l, a,
|
|
646
|
-
a[
|
|
645
|
+
function c(l, a, s) {
|
|
646
|
+
a[s.field] = l, n("change", l, a, s);
|
|
647
647
|
}
|
|
648
648
|
return (l, a) => {
|
|
649
|
-
var
|
|
649
|
+
var s;
|
|
650
650
|
return openBlock(), createBlock(unref(ElCheckbox), {
|
|
651
|
-
disabled: (
|
|
651
|
+
disabled: (s = r.column.params) == null ? void 0 : s.disabled,
|
|
652
652
|
modelValue: o.value,
|
|
653
653
|
"onUpdate:modelValue": a[0] || (a[0] = (m) => o.value = m),
|
|
654
654
|
onChange: a[1] || (a[1] = (m) => c(m, r.row, r.column))
|
|
@@ -696,29 +696,29 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
696
696
|
});
|
|
697
697
|
function c(u) {
|
|
698
698
|
if (!u) return;
|
|
699
|
-
let i,
|
|
699
|
+
let i, d, f, g = 1;
|
|
700
700
|
if (u.startsWith("#"))
|
|
701
|
-
u = u.slice(1), u.length === 3 ? (i = parseInt(u[0] + u[0], 16),
|
|
701
|
+
u = u.slice(1), u.length === 3 ? (i = parseInt(u[0] + u[0], 16), d = parseInt(u[1] + u[1], 16), f = parseInt(u[2] + u[2], 16)) : u.length === 6 && (i = parseInt(u.slice(0, 2), 16), d = parseInt(u.slice(2, 4), 16), f = parseInt(u.slice(4, 6), 16));
|
|
702
702
|
else if (u.startsWith("rgb")) {
|
|
703
703
|
const v = u.match(/rgba?\((\d+),\s*(\d+),\s*(\d+)(?:,\s*(\d*\.?\d+))?\)/);
|
|
704
|
-
v && (i = parseInt(v[1]),
|
|
704
|
+
v && (i = parseInt(v[1]), d = parseInt(v[2]), f = parseInt(v[3]), v[4] && (g = parseFloat(v[4])));
|
|
705
705
|
} else if (u.startsWith("hsl")) {
|
|
706
706
|
const v = u.match(/hsla?\((\d+),\s*(\d+)%,\s*(\d+)%(?:,\s*(\d*\.?\d+))?\)/);
|
|
707
707
|
if (v) {
|
|
708
708
|
const w = parseInt(v[1]) / 360, y = parseInt(v[2]) / 100, k = parseInt(v[3]) / 100;
|
|
709
709
|
if (v[4] && (g = parseFloat(v[4])), y === 0)
|
|
710
|
-
i =
|
|
710
|
+
i = d = f = k * 255;
|
|
711
711
|
else {
|
|
712
712
|
const V = (B, E, j) => (j < 0 && (j += 1), j > 1 && (j -= 1), j < 0.16666666666666666 ? B + (E - B) * 6 * j : j < 0.5 ? E : j < 0.6666666666666666 ? B + (E - B) * (0.6666666666666666 - j) * 6 : B), x = k < 0.5 ? k * (1 + y) : k + y - k * y, C = 2 * k - x;
|
|
713
|
-
i = V(C, x, w + 1 / 3) * 255,
|
|
713
|
+
i = V(C, x, w + 1 / 3) * 255, d = V(C, x, w) * 255, f = V(C, x, w - 1 / 3) * 255;
|
|
714
714
|
}
|
|
715
715
|
}
|
|
716
716
|
}
|
|
717
|
-
return { r: i, g:
|
|
717
|
+
return { r: i, g: d, b: f, a: g };
|
|
718
718
|
}
|
|
719
|
-
function l(u, i,
|
|
720
|
-
u /= 255, i /= 255,
|
|
721
|
-
const f = Math.max(u, i,
|
|
719
|
+
function l(u, i, d) {
|
|
720
|
+
u /= 255, i /= 255, d /= 255;
|
|
721
|
+
const f = Math.max(u, i, d), g = Math.min(u, i, d);
|
|
722
722
|
let v, w, y = (f + g) / 2;
|
|
723
723
|
if (f === g)
|
|
724
724
|
v = w = 0;
|
|
@@ -726,12 +726,12 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
726
726
|
const k = f - g;
|
|
727
727
|
switch (w = y > 0.5 ? k / (2 - f - g) : k / (f + g), f) {
|
|
728
728
|
case u:
|
|
729
|
-
v = (i -
|
|
729
|
+
v = (i - d) / k + (i < d ? 6 : 0);
|
|
730
730
|
break;
|
|
731
731
|
case i:
|
|
732
|
-
v = (
|
|
732
|
+
v = (d - u) / k + 2;
|
|
733
733
|
break;
|
|
734
|
-
case
|
|
734
|
+
case d:
|
|
735
735
|
v = (u - i) / k + 4;
|
|
736
736
|
break;
|
|
737
737
|
}
|
|
@@ -739,19 +739,19 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
739
739
|
}
|
|
740
740
|
return { h: v, s: w, l: y };
|
|
741
741
|
}
|
|
742
|
-
function a(u, i,
|
|
742
|
+
function a(u, i, d) {
|
|
743
743
|
let f, g, v;
|
|
744
744
|
if (i === 0)
|
|
745
|
-
f = g = v =
|
|
745
|
+
f = g = v = d;
|
|
746
746
|
else {
|
|
747
|
-
const w = (V, x, C) => (C < 0 && (C += 1), C > 1 && (C -= 1), C < 0.16666666666666666 ? V + (x - V) * 6 * C : C < 0.5 ? x : C < 0.6666666666666666 ? V + (x - V) * (0.6666666666666666 - C) * 6 : V), y =
|
|
747
|
+
const w = (V, x, C) => (C < 0 && (C += 1), C > 1 && (C -= 1), C < 0.16666666666666666 ? V + (x - V) * 6 * C : C < 0.5 ? x : C < 0.6666666666666666 ? V + (x - V) * (0.6666666666666666 - C) * 6 : V), y = d < 0.5 ? d * (1 + i) : d + i - d * i, k = 2 * d - y;
|
|
748
748
|
f = w(k, y, u + 1 / 3), g = w(k, y, u), v = w(k, y, u - 1 / 3);
|
|
749
749
|
}
|
|
750
750
|
return { r: Math.round(f * 255), g: Math.round(g * 255), b: Math.round(v * 255) };
|
|
751
751
|
}
|
|
752
|
-
function
|
|
752
|
+
function s(u, i) {
|
|
753
753
|
if (!u) return;
|
|
754
|
-
let { r:
|
|
754
|
+
let { r: d, g: f, b: g } = c(u), { h: v, s: w, l: y } = l(d, f, g);
|
|
755
755
|
y = Math.max(0, y - i);
|
|
756
756
|
const { r: k, g: V, b: x } = a(v, w, y);
|
|
757
757
|
return `rgb(${k}, ${V}, ${x})`;
|
|
@@ -760,35 +760,35 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
760
760
|
function u(v, w) {
|
|
761
761
|
return Math.floor(Math.random() * (w - v + 1)) + v;
|
|
762
762
|
}
|
|
763
|
-
const i = u(200, 255),
|
|
764
|
-
return `#${i.toString(16).padStart(2, "0")}${
|
|
763
|
+
const i = u(200, 255), d = u(200, 255), f = u(200, 255);
|
|
764
|
+
return `#${i.toString(16).padStart(2, "0")}${d.toString(16).padStart(2, "0")}${f.toString(16).padStart(2, "0")}`;
|
|
765
765
|
}
|
|
766
766
|
return (u, i) => {
|
|
767
|
-
const
|
|
767
|
+
const d = resolveComponent("hr-icon");
|
|
768
768
|
return o.value ? (openBlock(), createElementBlock("div", _hoisted_1$b, [
|
|
769
769
|
n.value ? (openBlock(), createBlock(unref(ElTag), {
|
|
770
770
|
key: 0,
|
|
771
771
|
color: n.value.Color,
|
|
772
772
|
size: "small",
|
|
773
|
-
style: normalizeStyle({ borderColor:
|
|
773
|
+
style: normalizeStyle({ borderColor: s(n.value.Color, "0.03") })
|
|
774
774
|
}, {
|
|
775
775
|
default: withCtx(() => [
|
|
776
|
-
n.value.LeftIcon ? (openBlock(), createBlock(
|
|
776
|
+
n.value.LeftIcon ? (openBlock(), createBlock(d, {
|
|
777
777
|
key: 0,
|
|
778
778
|
class: "mr0.25 v-middle mt0.15",
|
|
779
779
|
size: "13",
|
|
780
|
-
color:
|
|
780
|
+
color: s(n.value.Color, "0.3"),
|
|
781
781
|
icon: n.value.LeftIcon
|
|
782
782
|
}, null, 8, ["color", "icon"])) : createCommentVNode("", !0),
|
|
783
783
|
createElementVNode("span", {
|
|
784
784
|
class: "v-middle",
|
|
785
|
-
style: normalizeStyle({ color:
|
|
785
|
+
style: normalizeStyle({ color: s(n.value.Color, "0.3") })
|
|
786
786
|
}, toDisplayString(r.displayValue === void 0 ? o.value : r.displayValue), 5),
|
|
787
|
-
n.value.RightIcon ? (openBlock(), createBlock(
|
|
787
|
+
n.value.RightIcon ? (openBlock(), createBlock(d, {
|
|
788
788
|
key: 1,
|
|
789
789
|
class: "ml0.25 v-middle mt0.15",
|
|
790
790
|
size: "13",
|
|
791
|
-
color:
|
|
791
|
+
color: s(n.value.Color, "0.3"),
|
|
792
792
|
icon: n.value.RightIcon
|
|
793
793
|
}, null, 8, ["color", "icon"])) : createCommentVNode("", !0)
|
|
794
794
|
]),
|
|
@@ -922,19 +922,19 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
922
922
|
n.value = isColor(t.row[t.column.field]) ? t.row[t.column.field] : null;
|
|
923
923
|
});
|
|
924
924
|
const c = e;
|
|
925
|
-
function l(a,
|
|
926
|
-
|
|
925
|
+
function l(a, s, m) {
|
|
926
|
+
s[m.field] = a, c("change", a, s, m);
|
|
927
927
|
}
|
|
928
|
-
return (a,
|
|
928
|
+
return (a, s) => {
|
|
929
929
|
var m;
|
|
930
930
|
return openBlock(), createElementBlock("div", _hoisted_1$9, [
|
|
931
931
|
createVNode(unref(ElColorPicker), {
|
|
932
932
|
disabled: (m = r.column.params) == null ? void 0 : m.disabled,
|
|
933
933
|
class: "size-full",
|
|
934
934
|
modelValue: n.value,
|
|
935
|
-
"onUpdate:modelValue":
|
|
935
|
+
"onUpdate:modelValue": s[0] || (s[0] = (u) => n.value = u),
|
|
936
936
|
predefine: o.value,
|
|
937
|
-
onChange:
|
|
937
|
+
onChange: s[1] || (s[1] = (u) => l(u, r.row, r.column))
|
|
938
938
|
}, null, 8, ["disabled", "modelValue", "predefine"])
|
|
939
939
|
]);
|
|
940
940
|
};
|
|
@@ -1007,26 +1007,26 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1007
1007
|
if (l.includes("周") || !u.isValid() && a === "week") {
|
|
1008
1008
|
const i = l.match(/^(\d{4})年第(\d{1,2})周$/);
|
|
1009
1009
|
if (i) {
|
|
1010
|
-
const [,
|
|
1011
|
-
u = dayjs(`${
|
|
1010
|
+
const [, d, f] = i;
|
|
1011
|
+
u = dayjs(`${d}-01-01`).isoWeek(Number(f));
|
|
1012
1012
|
}
|
|
1013
1013
|
} else if (l.includes("季度") || !u.isValid() && a === "quarter") {
|
|
1014
1014
|
const i = l.match(/^(\d{4})年第(\d)季度$/);
|
|
1015
1015
|
if (i) {
|
|
1016
|
-
const [,
|
|
1017
|
-
u = dayjs(`${
|
|
1016
|
+
const [, d, f] = i;
|
|
1017
|
+
u = dayjs(`${d}-01-01`).quarter(Number(f));
|
|
1018
1018
|
}
|
|
1019
1019
|
} else if (l.includes("月") || !u.isValid() && a === "month") {
|
|
1020
1020
|
const i = l.match(/^(\d{4})年(\d{1,2})月$/);
|
|
1021
1021
|
if (i) {
|
|
1022
|
-
const [,
|
|
1023
|
-
u = dayjs(`${
|
|
1022
|
+
const [, d, f] = i;
|
|
1023
|
+
u = dayjs(`${d}-${f}-01`);
|
|
1024
1024
|
}
|
|
1025
1025
|
} else if (l.includes("年") || !u.isValid() && a === "year") {
|
|
1026
1026
|
const i = l.match(/^(\d{4})年$/);
|
|
1027
1027
|
if (i) {
|
|
1028
|
-
const [,
|
|
1029
|
-
u = dayjs(`${
|
|
1028
|
+
const [, d] = i;
|
|
1029
|
+
u = dayjs(`${d}-01-01`);
|
|
1030
1030
|
}
|
|
1031
1031
|
}
|
|
1032
1032
|
return u.isValid() ? n(u, a) : null;
|
|
@@ -1063,12 +1063,12 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1063
1063
|
case "year":
|
|
1064
1064
|
return `${dayjs(l).year()}年`;
|
|
1065
1065
|
default:
|
|
1066
|
-
const
|
|
1066
|
+
const s = {
|
|
1067
1067
|
time: "HH:mm:ss",
|
|
1068
1068
|
date: "YYYY-MM-DD",
|
|
1069
1069
|
datetime: "YYYY-MM-DD HH:mm:ss"
|
|
1070
1070
|
};
|
|
1071
|
-
return dayjs(l).format(
|
|
1071
|
+
return dayjs(l).format(s[a]);
|
|
1072
1072
|
}
|
|
1073
1073
|
}
|
|
1074
1074
|
return (l, a) => e.column.params.IsLabel ? (openBlock(), createBlock(_sfc_main$o, normalizeProps(mergeProps({ key: 0 }, { ...e, displayValue: t.value })), null, 16)) : (openBlock(), createElementBlock("span", {
|
|
@@ -1128,7 +1128,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1128
1128
|
return (n, c) => {
|
|
1129
1129
|
const l = resolveDirective("viewer");
|
|
1130
1130
|
return withDirectives((openBlock(), createElementBlock("div", _hoisted_1$6, [
|
|
1131
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(r.row[r.column.field], (a,
|
|
1131
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(r.row[r.column.field], (a, s) => (openBlock(), createElementBlock("div", {
|
|
1132
1132
|
class: "Link flex",
|
|
1133
1133
|
title: a.FileName
|
|
1134
1134
|
}, [
|
|
@@ -1149,7 +1149,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1149
1149
|
createElementVNode("a", {
|
|
1150
1150
|
href: a.FilePath,
|
|
1151
1151
|
download: a.FileName
|
|
1152
|
-
}, toDisplayString(
|
|
1152
|
+
}, toDisplayString(s + 1) + "." + toDisplayString(a.FileType), 9, _hoisted_4)
|
|
1153
1153
|
], 8, _hoisted_2))), 256))
|
|
1154
1154
|
])), [
|
|
1155
1155
|
[
|
|
@@ -1189,8 +1189,8 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1189
1189
|
t("change", c, l, a);
|
|
1190
1190
|
}
|
|
1191
1191
|
function n(c, l) {
|
|
1192
|
-
var
|
|
1193
|
-
if ((
|
|
1192
|
+
var s;
|
|
1193
|
+
if ((s = l.params) != null && s.disable) return;
|
|
1194
1194
|
let a = layer.open({
|
|
1195
1195
|
type: 2,
|
|
1196
1196
|
title: "图标选择",
|
|
@@ -1208,7 +1208,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1208
1208
|
const a = resolveComponent("hr-icon");
|
|
1209
1209
|
return openBlock(), createElementBlock("div", {
|
|
1210
1210
|
class: "w-full h-full flex justify-center items-center",
|
|
1211
|
-
onClick: l[0] || (l[0] = (
|
|
1211
|
+
onClick: l[0] || (l[0] = (s) => n(r.row, r.column))
|
|
1212
1212
|
}, [
|
|
1213
1213
|
createVNode(a, {
|
|
1214
1214
|
icon: r.row[r.column.field]
|
|
@@ -1245,20 +1245,20 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1245
1245
|
if ((g = l.params) != null && g.disabled) return;
|
|
1246
1246
|
let {
|
|
1247
1247
|
PickPeopleType: a,
|
|
1248
|
-
PickPeopleCheckType:
|
|
1248
|
+
PickPeopleCheckType: s,
|
|
1249
1249
|
PickPeopleIsAll: m,
|
|
1250
1250
|
PickPeopleStatus: u,
|
|
1251
1251
|
StoredValueField: i,
|
|
1252
|
-
ReturnValueField:
|
|
1252
|
+
ReturnValueField: d,
|
|
1253
1253
|
BackfillField: f
|
|
1254
1254
|
} = t.column.params;
|
|
1255
1255
|
openChoosePeople({
|
|
1256
1256
|
Type: a,
|
|
1257
|
-
Choose:
|
|
1257
|
+
Choose: s,
|
|
1258
1258
|
IsAll: m,
|
|
1259
1259
|
Status: u
|
|
1260
1260
|
}, (v) => {
|
|
1261
|
-
isEmpty(i) ? c[l.field] = v.Name || null : (Array.isArray(i) || (i = [i]), Array.isArray(
|
|
1261
|
+
isEmpty(i) ? c[l.field] = v.Name || null : (Array.isArray(i) || (i = [i]), Array.isArray(d) || (d = [d]), i.forEach((w, y) => c[w] = v[d[y]] || null)), o("change", v, c, l);
|
|
1262
1262
|
}, f ? c[f] : null);
|
|
1263
1263
|
}
|
|
1264
1264
|
return (c, l) => (openBlock(), createElementBlock("div", _hoisted_1$5, [
|
|
@@ -1337,8 +1337,8 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1337
1337
|
setup(r, { emit: e }) {
|
|
1338
1338
|
const t = r, o = e;
|
|
1339
1339
|
function n(c, l, a) {
|
|
1340
|
-
t.gridRef.getTableData().tableData.filter((
|
|
1341
|
-
|
|
1340
|
+
t.gridRef.getTableData().tableData.filter((s) => s !== l).forEach((s) => {
|
|
1341
|
+
s[a.field] && (s[a.field] = !1);
|
|
1342
1342
|
}), o("change", c, l, a);
|
|
1343
1343
|
}
|
|
1344
1344
|
return (c, l) => {
|
|
@@ -1346,8 +1346,8 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1346
1346
|
return openBlock(), createBlock(unref(ElRadioGroup), {
|
|
1347
1347
|
disabled: (a = r.column.params) == null ? void 0 : a.disabled,
|
|
1348
1348
|
modelValue: r.row[r.column.field],
|
|
1349
|
-
"onUpdate:modelValue": l[0] || (l[0] = (
|
|
1350
|
-
onChange: l[1] || (l[1] = (
|
|
1349
|
+
"onUpdate:modelValue": l[0] || (l[0] = (s) => r.row[r.column.field] = s),
|
|
1350
|
+
onChange: l[1] || (l[1] = (s) => n(s, r.row, r.column))
|
|
1351
1351
|
}, {
|
|
1352
1352
|
default: withCtx(() => [
|
|
1353
1353
|
createVNode(unref(ElRadio), { value: !0 })
|
|
@@ -1388,17 +1388,17 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1388
1388
|
var l;
|
|
1389
1389
|
return ((l = e.column.params[e.gridRef.getRowid(e.row)]) == null ? void 0 : l.options) || e.column.params.options;
|
|
1390
1390
|
}), o = computed(() => {
|
|
1391
|
-
var a,
|
|
1391
|
+
var a, s;
|
|
1392
1392
|
const l = e.row[e.column.field];
|
|
1393
1393
|
if (l && l.length > 1) {
|
|
1394
1394
|
let m = [];
|
|
1395
1395
|
return l.split(",").map((u) => {
|
|
1396
|
-
var
|
|
1397
|
-
const i = (f = (
|
|
1396
|
+
var d, f;
|
|
1397
|
+
const i = (f = (d = t.value) == null ? void 0 : d.find((g) => g.value == u)) == null ? void 0 : f.label;
|
|
1398
1398
|
i !== void 0 && m.push(i);
|
|
1399
1399
|
}), m.join(",");
|
|
1400
1400
|
} else
|
|
1401
|
-
return ((
|
|
1401
|
+
return ((s = (a = t.value) == null ? void 0 : a.find((m) => m.value == l)) == null ? void 0 : s.label) || "";
|
|
1402
1402
|
});
|
|
1403
1403
|
return (l, a) => e.column.params.IsLabel ? (openBlock(), createBlock(_sfc_main$o, normalizeProps(mergeProps({ key: 0 }, { ...e, displayValue: o.value })), null, 16)) : (openBlock(), createElementBlock("span", {
|
|
1404
1404
|
key: 1,
|
|
@@ -1438,7 +1438,7 @@ const _hoisted_1$h = ["title"], _hoisted_2$4 = { class: "flex flex-col gap3" },
|
|
|
1438
1438
|
return ((l = e.column.params[e.gridRef.getRowid(e.row)]) == null ? void 0 : l.options) || e.column.params.options;
|
|
1439
1439
|
}), o = computed(() => {
|
|
1440
1440
|
var l, a;
|
|
1441
|
-
return ((a = (l = t.value) == null ? void 0 : l.find((
|
|
1441
|
+
return ((a = (l = t.value) == null ? void 0 : l.find((s) => s.value == e.row[e.column.field])) == null ? void 0 : a.label) || "";
|
|
1442
1442
|
});
|
|
1443
1443
|
return (l, a) => e.column.params.IsLabel ? (openBlock(), createBlock(_sfc_main$o, normalizeProps(mergeProps({ key: 0 }, { ...e, displayValue: o.value })), null, 16)) : (openBlock(), createElementBlock("span", {
|
|
1444
1444
|
key: 1,
|
|
@@ -1555,11 +1555,11 @@ const _sfc_main$a = /* @__PURE__ */ Object.assign({
|
|
|
1555
1555
|
dayjs.extend(isoWeek), dayjs.extend(quarterOfYear), dayjs.extend(customParseFormat);
|
|
1556
1556
|
const t = r, o = ref(n(t.row[t.column.field], ((l = t.column.params) == null ? void 0 : l.DateType) || "date"));
|
|
1557
1557
|
onBeforeUnmount(() => {
|
|
1558
|
-
var
|
|
1559
|
-
const a = ((
|
|
1558
|
+
var s;
|
|
1559
|
+
const a = ((s = t.column.params) == null ? void 0 : s.DateType) || "date";
|
|
1560
1560
|
o.value && (a === "year" ? t.row[t.column.field] = dayjs(o.value).format("YYYY年") : a === "month" ? t.row[t.column.field] = dayjs(o.value).format("YYYY年MM月") : a === "quarter" ? t.row[t.column.field] = dayjs(o.value).format("YYYY年第Q季度") : a === "week" ? t.row[t.column.field] = dayjs(o.value).format("YYYY年第WW周") : a === "datetime" ? t.row[t.column.field] = dayjs(o.value).format("YYYY-MM-DD HH:mm:ss") : t.row[t.column.field] = dayjs(o.value).format("YYYY-MM-DD"));
|
|
1561
1561
|
});
|
|
1562
|
-
function n(a,
|
|
1562
|
+
function n(a, s) {
|
|
1563
1563
|
if (!a) return null;
|
|
1564
1564
|
const u = {
|
|
1565
1565
|
time: "HH:mm:ss",
|
|
@@ -1569,38 +1569,38 @@ const _sfc_main$a = /* @__PURE__ */ Object.assign({
|
|
|
1569
1569
|
month: "YYYY-MM",
|
|
1570
1570
|
quarter: "YYYY-Q",
|
|
1571
1571
|
year: "YYYY"
|
|
1572
|
-
}[
|
|
1572
|
+
}[s];
|
|
1573
1573
|
if (!u) throw new Error("Unsupported date type");
|
|
1574
1574
|
let i = dayjs(a, u);
|
|
1575
|
-
if (!i.isValid() &&
|
|
1576
|
-
const
|
|
1577
|
-
if (
|
|
1578
|
-
const [, f, g] =
|
|
1575
|
+
if (!i.isValid() && s === "week") {
|
|
1576
|
+
const d = a.match(/^(\d{4})年第(\d{2})周$/);
|
|
1577
|
+
if (d) {
|
|
1578
|
+
const [, f, g] = d;
|
|
1579
1579
|
i = dayjs(`${f}-01-01`).isoWeek(Number(g));
|
|
1580
1580
|
}
|
|
1581
|
-
} else if (!i.isValid() &&
|
|
1582
|
-
const
|
|
1583
|
-
if (
|
|
1584
|
-
const [, f, g] =
|
|
1581
|
+
} else if (!i.isValid() && s === "quarter") {
|
|
1582
|
+
const d = a.match(/^(\d{4})年第(\d)季度$/);
|
|
1583
|
+
if (d) {
|
|
1584
|
+
const [, f, g] = d;
|
|
1585
1585
|
i = dayjs(`${f}-01-01`).quarter(Number(g));
|
|
1586
1586
|
}
|
|
1587
|
-
} else if (!i.isValid() &&
|
|
1588
|
-
const
|
|
1589
|
-
if (
|
|
1590
|
-
const [, f, g] =
|
|
1587
|
+
} else if (!i.isValid() && s === "month") {
|
|
1588
|
+
const d = a.match(/^(\d{4})年(\d{2})月$/);
|
|
1589
|
+
if (d) {
|
|
1590
|
+
const [, f, g] = d;
|
|
1591
1591
|
i = dayjs(`${f}-${g}-01`);
|
|
1592
1592
|
}
|
|
1593
|
-
} else if (!i.isValid() &&
|
|
1594
|
-
const
|
|
1595
|
-
if (
|
|
1596
|
-
const [, f] =
|
|
1593
|
+
} else if (!i.isValid() && s === "year") {
|
|
1594
|
+
const d = a.match(/^(\d{4})年$/);
|
|
1595
|
+
if (d) {
|
|
1596
|
+
const [, f] = d;
|
|
1597
1597
|
i = dayjs(`${f}-01-01`);
|
|
1598
1598
|
}
|
|
1599
1599
|
}
|
|
1600
|
-
return i.isValid() ? c(i,
|
|
1600
|
+
return i.isValid() ? c(i, s) : null;
|
|
1601
1601
|
}
|
|
1602
|
-
function c(a,
|
|
1603
|
-
switch (
|
|
1602
|
+
function c(a, s) {
|
|
1603
|
+
switch (s) {
|
|
1604
1604
|
case "time":
|
|
1605
1605
|
return a.format("HH:mm:ss");
|
|
1606
1606
|
case "date":
|
|
@@ -1619,11 +1619,11 @@ const _sfc_main$a = /* @__PURE__ */ Object.assign({
|
|
|
1619
1619
|
return null;
|
|
1620
1620
|
}
|
|
1621
1621
|
}
|
|
1622
|
-
return (a,
|
|
1622
|
+
return (a, s) => {
|
|
1623
1623
|
var m;
|
|
1624
1624
|
return openBlock(), createBlock(unref(VxeInput), {
|
|
1625
1625
|
modelValue: o.value,
|
|
1626
|
-
"onUpdate:modelValue":
|
|
1626
|
+
"onUpdate:modelValue": s[0] || (s[0] = (u) => o.value = u),
|
|
1627
1627
|
type: ((m = r.column.params) == null ? void 0 : m.DateType) || "date",
|
|
1628
1628
|
clearable: "",
|
|
1629
1629
|
transfer: ""
|
|
@@ -1730,7 +1730,7 @@ const _sfc_main$a = /* @__PURE__ */ Object.assign({
|
|
|
1730
1730
|
e.row[e.column.field] = t.value;
|
|
1731
1731
|
const c = e.column.params.LabelStoreField;
|
|
1732
1732
|
if (c) {
|
|
1733
|
-
const a = (l = n.value.find((
|
|
1733
|
+
const a = (l = n.value.find((s) => s.value === t.value)) == null ? void 0 : l.label;
|
|
1734
1734
|
a !== void 0 ? e.row[c] = a : t.value === void 0 ? e.row[c] = null : t.value !== void 0 && a === void 0 && (e.row[c] = t.value);
|
|
1735
1735
|
}
|
|
1736
1736
|
}), (c, l) => (openBlock(), createBlock(unref(ElSelect), {
|
|
@@ -1789,7 +1789,7 @@ const _sfc_main$a = /* @__PURE__ */ Object.assign({
|
|
|
1789
1789
|
e.row[e.column.field] = c;
|
|
1790
1790
|
const l = e.column.params.LabelStoreField;
|
|
1791
1791
|
if (l) {
|
|
1792
|
-
const a = o.value.filter((
|
|
1792
|
+
const a = o.value.filter((s) => n.value.includes(s.value)).map((s) => s.label).join(",");
|
|
1793
1793
|
e.row[l] = a;
|
|
1794
1794
|
}
|
|
1795
1795
|
});
|
|
@@ -1838,8 +1838,9 @@ const _sfc_main$a = /* @__PURE__ */ Object.assign({
|
|
|
1838
1838
|
default: () => ({})
|
|
1839
1839
|
}
|
|
1840
1840
|
},
|
|
1841
|
-
|
|
1842
|
-
|
|
1841
|
+
emits: ["remoteMethod"],
|
|
1842
|
+
setup(r, { emit: e }) {
|
|
1843
|
+
const t = e, o = r, n = ref(o.row[o.column.field] === void 0 ? "" : o.row[o.column.field]), c = reactive(o.column.params || {
|
|
1843
1844
|
options: [],
|
|
1844
1845
|
placeholder: "请选择",
|
|
1845
1846
|
disabled: !1,
|
|
@@ -1850,41 +1851,41 @@ const _sfc_main$a = /* @__PURE__ */ Object.assign({
|
|
|
1850
1851
|
loading: !1
|
|
1851
1852
|
});
|
|
1852
1853
|
onBeforeUnmount(() => {
|
|
1853
|
-
const { StoredValueField:
|
|
1854
|
-
|
|
1855
|
-
const
|
|
1856
|
-
|
|
1857
|
-
}) :
|
|
1854
|
+
const { StoredValueField: a, ReturnValueField: s } = c;
|
|
1855
|
+
a && a.length ? a.forEach((m, u) => {
|
|
1856
|
+
const i = c.options.find((d) => d._value === n.value);
|
|
1857
|
+
i && (o.row[m] = i[s[u]]);
|
|
1858
|
+
}) : o.row[o.column.field] = n.value;
|
|
1858
1859
|
});
|
|
1859
|
-
function
|
|
1860
|
-
const { DataAPIOID:
|
|
1861
|
-
|
|
1860
|
+
function l(a) {
|
|
1861
|
+
const { DataAPIOID: s, SearchField: m } = c;
|
|
1862
|
+
a ? (c.loading = !0, t("remoteMethod", { DataAPIOID: s, SearchField: m, query: a, params: c })) : o.column.params.options = [];
|
|
1862
1863
|
}
|
|
1863
|
-
return (
|
|
1864
|
+
return (a, s) => (openBlock(), createBlock(unref(ElSelect), {
|
|
1864
1865
|
class: "z-1 vxe-table--ignore-clear",
|
|
1865
|
-
modelValue:
|
|
1866
|
-
"onUpdate:modelValue":
|
|
1866
|
+
modelValue: n.value,
|
|
1867
|
+
"onUpdate:modelValue": s[0] || (s[0] = (m) => n.value = m),
|
|
1867
1868
|
"automatic-dropdown": "",
|
|
1868
|
-
placeholder:
|
|
1869
|
+
placeholder: c.placeholder,
|
|
1869
1870
|
"popper-class": "select-dropdown",
|
|
1870
|
-
loading:
|
|
1871
|
+
loading: c.loading,
|
|
1871
1872
|
filterable: "",
|
|
1872
1873
|
remote: "",
|
|
1873
|
-
"remote-method":
|
|
1874
|
+
"remote-method": l,
|
|
1874
1875
|
clearable: ""
|
|
1875
1876
|
}, {
|
|
1876
1877
|
default: withCtx(() => [
|
|
1877
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(
|
|
1878
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(c.options, (m) => (openBlock(), createBlock(unref(ElOption), {
|
|
1878
1879
|
class: "vxe-table--ignore-clear",
|
|
1879
|
-
key:
|
|
1880
|
-
label:
|
|
1881
|
-
value:
|
|
1880
|
+
key: m._value,
|
|
1881
|
+
label: m._label,
|
|
1882
|
+
value: m._value
|
|
1882
1883
|
}, null, 8, ["label", "value"]))), 128))
|
|
1883
1884
|
]),
|
|
1884
1885
|
_: 1
|
|
1885
1886
|
}, 8, ["modelValue", "placeholder", "loading"]));
|
|
1886
1887
|
}
|
|
1887
|
-
}), selectRemoteEditor = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-
|
|
1888
|
+
}), selectRemoteEditor = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-84ff76dd"]]), __vite_glob_0_5 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1888
1889
|
__proto__: null,
|
|
1889
1890
|
default: selectRemoteEditor
|
|
1890
1891
|
}, Symbol.toStringTag, { value: "Module" })), _sfc_main$4 = /* @__PURE__ */ Object.assign({
|
|
@@ -2011,7 +2012,7 @@ const _sfc_main$a = /* @__PURE__ */ Object.assign({
|
|
|
2011
2012
|
indent: 12
|
|
2012
2013
|
}, {
|
|
2013
2014
|
label: withCtx(({ label: l, value: a }) => [
|
|
2014
|
-
createElementVNode("span", null, toDisplayString(r.column.params.options.find((
|
|
2015
|
+
createElementVNode("span", null, toDisplayString(r.column.params.options.find((s) => s[o.value.value] === a) ? l : ""), 1)
|
|
2015
2016
|
]),
|
|
2016
2017
|
_: 1
|
|
2017
2018
|
}, 8, ["modelValue", "data", "props"]));
|
|
@@ -2059,7 +2060,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2059
2060
|
function l() {
|
|
2060
2061
|
c("pageChange", t.pagination);
|
|
2061
2062
|
}
|
|
2062
|
-
return (a,
|
|
2063
|
+
return (a, s) => (openBlock(), createElementBlock("div", {
|
|
2063
2064
|
ref_key: "pagingDom",
|
|
2064
2065
|
ref: o,
|
|
2065
2066
|
class: "flex items-center w-full h-12 border border-solid border-[#e8eaec] box-border"
|
|
@@ -2069,9 +2070,9 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2069
2070
|
class: "w-full !h-full",
|
|
2070
2071
|
background: "",
|
|
2071
2072
|
"current-page": r.pagination.Page,
|
|
2072
|
-
"onUpdate:currentPage":
|
|
2073
|
+
"onUpdate:currentPage": s[0] || (s[0] = (m) => r.pagination.Page = m),
|
|
2073
2074
|
"page-size": r.pagination.PageSize,
|
|
2074
|
-
"onUpdate:pageSize":
|
|
2075
|
+
"onUpdate:pageSize": s[1] || (s[1] = (m) => r.pagination.PageSize = m),
|
|
2075
2076
|
total: r.pagination.Total,
|
|
2076
2077
|
layouts: n.value,
|
|
2077
2078
|
onPageChange: l,
|
|
@@ -2104,7 +2105,8 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2104
2105
|
"SortChange",
|
|
2105
2106
|
"ActionRenderBefore",
|
|
2106
2107
|
"PickPeople",
|
|
2107
|
-
"FileClick"
|
|
2108
|
+
"FileClick",
|
|
2109
|
+
"RemoteMethod"
|
|
2108
2110
|
],
|
|
2109
2111
|
setup(r, { expose: e, emit: t }) {
|
|
2110
2112
|
var R;
|
|
@@ -2113,11 +2115,11 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2113
2115
|
ColorPickerRender: c,
|
|
2114
2116
|
IconPickerRender: l,
|
|
2115
2117
|
RadioRender: a,
|
|
2116
|
-
ProgressRender:
|
|
2118
|
+
ProgressRender: s,
|
|
2117
2119
|
ActionRender: m,
|
|
2118
2120
|
SelectRender: u,
|
|
2119
2121
|
TreeSelectRender: i,
|
|
2120
|
-
SelectMultipleRender:
|
|
2122
|
+
SelectMultipleRender: d,
|
|
2121
2123
|
TreeMultipleSelectRender: f,
|
|
2122
2124
|
ChooseFrameRender: g,
|
|
2123
2125
|
PickPeopleRender: v,
|
|
@@ -2156,17 +2158,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2156
2158
|
// 因为对过滤行进行了修改 该属性必须为false
|
|
2157
2159
|
...(R = o.config) == null ? void 0 : R.editConfig
|
|
2158
2160
|
}
|
|
2159
|
-
});
|
|
2160
|
-
onMounted(() => {
|
|
2161
|
-
setTimeout(() => {
|
|
2162
|
-
var h;
|
|
2163
|
-
(h = b.value) == null || h.loadData([
|
|
2164
|
-
{ Code: 1, PageName: "测试1" },
|
|
2165
|
-
{ Code: 2, PageName: "测试2" }
|
|
2166
|
-
]);
|
|
2167
|
-
});
|
|
2168
|
-
});
|
|
2169
|
-
const O = t;
|
|
2161
|
+
}), O = t;
|
|
2170
2162
|
e({
|
|
2171
2163
|
gridRef: b,
|
|
2172
2164
|
gridOptions: $
|
|
@@ -2195,7 +2187,10 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2195
2187
|
function L(...h) {
|
|
2196
2188
|
O("FileClick", ...h);
|
|
2197
2189
|
}
|
|
2198
|
-
|
|
2190
|
+
function H(...h) {
|
|
2191
|
+
O("RemoteMethod", ...h);
|
|
2192
|
+
}
|
|
2193
|
+
return (h, q) => (openBlock(), createElementBlock("div", _hoisted_1, [
|
|
2199
2194
|
createVNode(unref(VxeGrid), mergeProps({
|
|
2200
2195
|
class: "grid-table",
|
|
2201
2196
|
ref_key: "gridRef",
|
|
@@ -2247,7 +2242,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2247
2242
|
}, null, 8, ["row", "column", "grid-ref"])
|
|
2248
2243
|
]),
|
|
2249
2244
|
ProgressRender: withCtx(({ row: p, column: _ }) => [
|
|
2250
|
-
createVNode(unref(
|
|
2245
|
+
createVNode(unref(s), {
|
|
2251
2246
|
row: p,
|
|
2252
2247
|
column: _,
|
|
2253
2248
|
"grid-ref": b.value
|
|
@@ -2261,7 +2256,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2261
2256
|
}, null, 8, ["row", "column", "grid-ref"])
|
|
2262
2257
|
]),
|
|
2263
2258
|
SelectMultipleRender: withCtx(({ row: p, column: _ }) => [
|
|
2264
|
-
createVNode(unref(
|
|
2259
|
+
createVNode(unref(d), {
|
|
2265
2260
|
row: p,
|
|
2266
2261
|
column: _,
|
|
2267
2262
|
"grid-ref": b.value
|
|
@@ -2385,7 +2380,8 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2385
2380
|
createVNode(unref(N), {
|
|
2386
2381
|
row: p,
|
|
2387
2382
|
column: _,
|
|
2388
|
-
"grid-ref": b.value
|
|
2383
|
+
"grid-ref": b.value,
|
|
2384
|
+
onRemoteMethod: H
|
|
2389
2385
|
}, null, 8, ["row", "column", "grid-ref"])
|
|
2390
2386
|
]),
|
|
2391
2387
|
pager: withCtx(() => [
|
|
@@ -2400,7 +2396,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
2400
2396
|
}, 16)
|
|
2401
2397
|
]));
|
|
2402
2398
|
}
|
|
2403
|
-
}), Table = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
2399
|
+
}), Table = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-bdff8a1c"]]);
|
|
2404
2400
|
VxeUI.setConfig({
|
|
2405
2401
|
size: "small",
|
|
2406
2402
|
table: {
|