@hb-hellotech/hb-ui 1.0.1 → 1.0.9
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/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_form_item_filter_modal/index.d.ts +2 -1
- package/dist/components/business_comp/list_page_comp/hb_form_item_filter_modal/index.d.ts.map +1 -0
- package/dist/components/{types/hb_form_item_filter_modal_type.d.ts → business_comp/list_page_comp/hb_form_item_filter_modal/src/type.d.ts} +9 -4
- package/dist/components/business_comp/list_page_comp/hb_form_item_filter_modal/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_form_select_filter/index.d.ts +2 -1
- package/dist/components/business_comp/list_page_comp/hb_form_select_filter/index.d.ts.map +1 -0
- package/dist/components/{types/hb_form_select_filter_type.d.ts → business_comp/list_page_comp/hb_form_select_filter/src/type.d.ts} +1 -0
- package/dist/components/business_comp/list_page_comp/hb_form_select_filter/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_form_select_modal/index.d.ts +2 -1
- package/dist/components/business_comp/list_page_comp/hb_form_select_modal/index.d.ts.map +1 -0
- package/dist/components/business_comp/list_page_comp/hb_form_select_modal/src/HbMutilpleSelectModal.vue.d.ts +112 -0
- package/dist/components/business_comp/list_page_comp/hb_form_select_modal/src/HbMutilpleSelectModal.vue.d.ts.map +1 -0
- package/dist/components/{types/hb_form_select_modal_type.d.ts → business_comp/list_page_comp/hb_form_select_modal/src/type.d.ts} +10 -0
- package/dist/components/business_comp/list_page_comp/hb_form_select_modal/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_list_btns_act/index.d.ts +2 -0
- package/dist/components/business_comp/list_page_comp/hb_list_btns_act/index.d.ts.map +1 -0
- package/dist/components/business_comp/list_page_comp/hb_list_btns_act/src/HbListBtns.vue.d.ts +61 -0
- package/dist/components/business_comp/list_page_comp/hb_list_btns_act/src/HbListBtns.vue.d.ts.map +1 -0
- package/dist/components/{types/hb_list_btns_act_type.d.ts → business_comp/list_page_comp/hb_list_btns_act/src/type.d.ts} +9 -1
- package/dist/components/business_comp/list_page_comp/hb_list_btns_act/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_list_form/index.d.ts +2 -1
- package/dist/components/business_comp/list_page_comp/hb_list_form/index.d.ts.map +1 -0
- package/dist/components/{types/hb_list_form_type.d.ts → business_comp/list_page_comp/hb_list_form/src/type.d.ts} +13 -0
- package/dist/components/business_comp/list_page_comp/hb_list_form/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_list_page_act/index.d.ts +2 -0
- package/dist/components/business_comp/list_page_comp/hb_list_page_act/index.d.ts.map +1 -0
- package/dist/components/business_comp/list_page_comp/hb_list_page_act/src/HbListPageAct.vue.d.ts +60 -0
- package/dist/components/business_comp/list_page_comp/hb_list_page_act/src/HbListPageAct.vue.d.ts.map +1 -0
- package/dist/components/{types/hb_list_page_act_type.d.ts → business_comp/list_page_comp/hb_list_page_act/src/type.d.ts} +8 -1
- package/dist/components/business_comp/list_page_comp/hb_list_page_act/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_list_page_container/index.d.ts +2 -0
- package/dist/components/business_comp/list_page_comp/hb_list_page_container/index.d.ts.map +1 -0
- package/dist/components/business_comp/list_page_comp/hb_list_page_container/src/HbListPageContainer.vue.d.ts +50 -0
- package/dist/components/business_comp/list_page_comp/hb_list_page_container/src/HbListPageContainer.vue.d.ts.map +1 -0
- package/dist/components/{types/hb_list_page_container_type.d.ts → business_comp/list_page_comp/hb_list_page_container/src/type.d.ts} +7 -0
- package/dist/components/business_comp/list_page_comp/hb_list_page_container/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_list_table/index.d.ts +2 -1
- package/dist/components/business_comp/list_page_comp/hb_list_table/index.d.ts.map +1 -0
- package/dist/components/{types/hb_list_table_type.d.ts → business_comp/list_page_comp/hb_list_table/src/type.d.ts} +8 -0
- package/dist/components/business_comp/list_page_comp/hb_list_table/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_list_table_act/index.d.ts +2 -0
- package/dist/components/business_comp/list_page_comp/hb_list_table_act/index.d.ts.map +1 -0
- package/dist/components/{types/hb_list_table_act_type.d.ts → business_comp/list_page_comp/hb_list_table_act/src/type.d.ts} +1 -0
- package/dist/components/business_comp/list_page_comp/hb_list_table_act/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/hb_list_table_colums_set/index.d.ts +2 -0
- package/dist/components/business_comp/list_page_comp/hb_list_table_colums_set/index.d.ts.map +1 -0
- package/dist/components/{types/hb_list_table_colums_set_type.d.ts → business_comp/list_page_comp/hb_list_table_colums_set/src/type.d.ts} +1 -0
- package/dist/components/business_comp/list_page_comp/hb_list_table_colums_set/src/type.d.ts.map +1 -0
- package/dist/components/{business-comp/list-page-comp → business_comp/list_page_comp}/index.d.ts +2 -1
- package/dist/components/business_comp/list_page_comp/index.d.ts.map +1 -0
- package/dist/components/{func-comp → func_comp}/hb_func_comp_copy/index.d.ts +1 -0
- package/dist/components/func_comp/hb_func_comp_copy/index.d.ts.map +1 -0
- package/dist/components/{func-comp → func_comp}/hb_func_comp_copy/src/copy.vue.d.ts +1 -0
- package/dist/components/func_comp/hb_func_comp_copy/src/copy.vue.d.ts.map +1 -0
- package/dist/components/{func-comp → func_comp}/hb_func_comp_copy/src/type.d.ts +12 -0
- package/dist/components/func_comp/hb_func_comp_copy/src/type.d.ts.map +1 -0
- package/dist/components/func_comp/hb_func_comp_drag/index.d.ts +443 -0
- package/dist/components/func_comp/hb_func_comp_drag/index.d.ts.map +1 -0
- package/dist/components/func_comp/hb_func_comp_drag/src/index.vue.d.ts +182 -0
- package/dist/components/func_comp/hb_func_comp_drag/src/index.vue.d.ts.map +1 -0
- package/dist/components/func_comp/hb_func_comp_drag/src/type.d.ts +57 -0
- package/dist/components/func_comp/hb_func_comp_drag/src/type.d.ts.map +1 -0
- package/dist/components/{func-comp → func_comp}/hb_func_comp_tree/index.d.ts +1 -0
- package/dist/components/func_comp/hb_func_comp_tree/index.d.ts.map +1 -0
- package/dist/components/{func-comp → func_comp}/hb_func_comp_tree/src/tree.d.ts +1 -0
- package/dist/components/func_comp/hb_func_comp_tree/src/tree.d.ts.map +1 -0
- package/dist/components/{func-comp → func_comp}/hb_func_comp_tree/src/tree.vue.d.ts +1 -0
- package/dist/components/func_comp/hb_func_comp_tree/src/tree.vue.d.ts.map +1 -0
- package/dist/components/{func-comp → func_comp}/hb_func_comp_tree/src/treeNode.vue.d.ts +1 -0
- package/dist/components/func_comp/hb_func_comp_tree/src/treeNode.vue.d.ts.map +1 -0
- package/dist/components/func_comp/index.d.ts +5 -0
- package/dist/components/func_comp/index.d.ts.map +1 -0
- package/dist/components/hooks/useCalTableHeight.d.ts +1 -0
- package/dist/components/hooks/useCalTableHeight.d.ts.map +1 -0
- package/dist/components/hooks/useCalTableWidth.d.ts +1 -0
- package/dist/components/hooks/useCalTableWidth.d.ts.map +1 -0
- package/dist/components/hooks/useListFormItem.d.ts +8 -0
- package/dist/components/hooks/useListFormItem.d.ts.map +1 -0
- package/dist/components/utils/createBem.d.ts +1 -0
- package/dist/components/utils/createBem.d.ts.map +1 -0
- package/dist/components/utils/withInstall.d.ts +1 -0
- package/dist/components/utils/withInstall.d.ts.map +1 -0
- package/dist/components.d.ts +18 -0
- package/dist/hb_component_lib.css +1 -1
- package/dist/hb_component_lib.js +1345 -1169
- package/dist/hb_component_lib.umd.cjs +1 -1
- package/dist/index.d.ts +4 -3
- package/dist/index.d.ts.map +1 -0
- package/dist/shims-vue.d.ts +5 -0
- package/package.json +6 -5
- package/dist/components/business-comp/list-page-comp/hb_form_select_modal/src/HbMutilpleSelectModal.vue.d.ts +0 -99
- package/dist/components/business-comp/list-page-comp/hb_list_btns_act/src/HbListBtns.vue.d.ts +0 -53
- package/dist/components/business-comp/list-page-comp/hb_list_page_act/src/HbListPageAct.vue.d.ts +0 -55
- package/dist/components/business-comp/list-page-comp/hb_list_page_container/src/HbListPageContainer.vue.d.ts +0 -41
- package/dist/components/func-comp/index.d.ts +0 -2
- package/dist/types/components.d.ts +0 -32
package/dist/hb_component_lib.js
CHANGED
|
@@ -1,140 +1,126 @@
|
|
|
1
1
|
import './hb_component_lib.css';
|
|
2
|
-
import { defineComponent as X, reactive as
|
|
3
|
-
import
|
|
4
|
-
import { CloseOutlined as
|
|
5
|
-
import { Modal as
|
|
2
|
+
import { defineComponent as X, reactive as Ge, ref as O, computed as W, watch as se, createElementBlock as k, openBlock as o, normalizeClass as z, unref as i, createVNode as T, withCtx as b, createElementVNode as v, toDisplayString as L, createTextVNode as I, createBlock as B, createCommentVNode as R, Fragment as J, renderList as ae, inject as xe, resolveComponent as j, Transition as at, withDirectives as re, mergeProps as ee, createSlots as Qe, renderSlot as Z, vShow as ot, nextTick as he, onMounted as Te, onUnmounted as nt, useTemplateRef as st, provide as it, normalizeStyle as be, mergeModels as He, useModel as rt, withModifiers as _e, resolveDirective as ct, watchEffect as dt, shallowRef as ut, resolveDynamicComponent as ht } from "vue";
|
|
3
|
+
import me from "vuedraggable";
|
|
4
|
+
import { CloseOutlined as bt, QuestionCircleOutlined as ft, SearchOutlined as $e, UpCircleOutlined as pt, DownCircleOutlined as mt, UnorderedListOutlined as vt, DownOutlined as Ie } from "@ant-design/icons-vue";
|
|
5
|
+
import { Modal as Se, Button as de, Tooltip as Ae, Switch as De, Radio as Oe, RadioGroup as Be, InputNumber as Ne, DatePicker as Re, Checkbox as ve, CheckboxGroup as Pe, Select as ze, Input as Ee, Col as gt, Row as yt, FormItem as Ve, Form as Ue, SelectOption as Ke, Popconfirm as Le, MenuItem as Ye, Menu as je, Dropdown as qe, Popover as Ct, message as we } from "ant-design-vue";
|
|
6
6
|
import { useRoute as Ze } from "vue-router";
|
|
7
|
-
import { useI18n as
|
|
8
|
-
import
|
|
9
|
-
import { useFullscreen as
|
|
10
|
-
import
|
|
11
|
-
const
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
default: () => [],
|
|
16
|
-
required: !0
|
|
17
|
-
},
|
|
18
|
-
afterChange: {
|
|
19
|
-
type: Function,
|
|
20
|
-
default: () => {
|
|
21
|
-
}
|
|
22
|
-
},
|
|
23
|
-
title: {
|
|
24
|
-
type: String,
|
|
25
|
-
default: "自定义查询条件"
|
|
26
|
-
},
|
|
27
|
-
showNumber: {
|
|
28
|
-
type: Number,
|
|
29
|
-
default: 40
|
|
30
|
-
}
|
|
31
|
-
}, Ct = "hb-", me = (p = "") => {
|
|
32
|
-
const c = `${Ct}${p}`;
|
|
33
|
-
return Lt(c);
|
|
34
|
-
}, se = (p, c, d, s) => (c && (p += `-${c}`), d && (p += `__${d}`), s && (p += `--${s}`), p), Lt = (p) => ({
|
|
7
|
+
import { useI18n as ce } from "vue-i18n";
|
|
8
|
+
import ke from "lodash";
|
|
9
|
+
import { useFullscreen as Lt, useDebounceFn as kt } from "@vueuse/core";
|
|
10
|
+
import Me from "dayjs";
|
|
11
|
+
const _t = "hb-", fe = (e = "") => {
|
|
12
|
+
const d = `${_t}${e}`;
|
|
13
|
+
return St(d);
|
|
14
|
+
}, ie = (e, d, u, n) => (d && (e += `-${d}`), u && (e += `__${u}`), n && (e += `--${n}`), e), St = (e) => ({
|
|
35
15
|
// hb-button
|
|
36
|
-
b: (
|
|
16
|
+
b: (d) => d ? ie(e, d, "", "") : ie(e, "", "", ""),
|
|
37
17
|
// hb-button__header
|
|
38
|
-
e: (
|
|
18
|
+
e: (d) => d ? ie(e, "", d, "") : "",
|
|
39
19
|
// hb-button--primary
|
|
40
|
-
m: (
|
|
20
|
+
m: (d) => ie(e, "", "", d),
|
|
41
21
|
// hb-button__header
|
|
42
|
-
be: (
|
|
22
|
+
be: (d, u) => ie(e, d, u, ""),
|
|
43
23
|
// hb-button__header--primary
|
|
44
|
-
em: (
|
|
24
|
+
em: (d, u) => ie(e, "", d, u),
|
|
45
25
|
// hb-button__header--primary
|
|
46
|
-
bem: (
|
|
26
|
+
bem: (d, u, n) => ie(e, d, u, n),
|
|
47
27
|
// is-disabled
|
|
48
|
-
is: (
|
|
49
|
-
}),
|
|
28
|
+
is: (d, u) => u ? `is-${d}` : ""
|
|
29
|
+
}), wt = ["onMouseenter", "onMouseleave"], Ft = ["onClick"], xt = /* @__PURE__ */ X({
|
|
50
30
|
name: "HbLibFormItemFilterModal",
|
|
51
31
|
__name: "HbFormItemFilterModal",
|
|
52
|
-
props:
|
|
32
|
+
props: {
|
|
33
|
+
list: { default: () => [] },
|
|
34
|
+
afterChange: { type: Function, default: () => () => {
|
|
35
|
+
} },
|
|
36
|
+
title: { default: "自定义查询条件" },
|
|
37
|
+
showNumber: { default: 40 }
|
|
38
|
+
},
|
|
53
39
|
emits: ["confirm"],
|
|
54
|
-
setup(
|
|
55
|
-
const
|
|
40
|
+
setup(e, { expose: d, emit: u }) {
|
|
41
|
+
const n = ce().t, _ = ce().messages.value.en_US, m = ce().messages.value.ja_JP, p = ce().messages.value.zh_CN, h = e, l = u, s = fe("sfcm"), r = Ze(), M = Ge({
|
|
56
42
|
lan: window.localStorage.getItem("lan")
|
|
57
|
-
}),
|
|
43
|
+
}), w = O(!1), N = O(600);
|
|
58
44
|
let S = [];
|
|
59
|
-
const
|
|
60
|
-
const D =
|
|
45
|
+
const x = O([]), U = O([]), E = W(() => x.value.every((C) => C.isLinked || C.isFixed)), V = (C) => {
|
|
46
|
+
const D = C.draggedContext.element, g = C.relatedContext.index;
|
|
61
47
|
if (D.isLinked || D.isFixed)
|
|
62
48
|
return !1;
|
|
63
|
-
const Y =
|
|
49
|
+
const Y = x.value.map((Q, ne) => ({ item: Q, index: ne })).filter(({ item: Q }) => Q.isLinked).map(({ index: Q }) => Q);
|
|
64
50
|
if (Y.length === 0)
|
|
65
51
|
return !0;
|
|
66
52
|
for (let Q = 0; Q < Y.length - 1; Q++) {
|
|
67
|
-
const
|
|
68
|
-
if (g >
|
|
53
|
+
const ne = Y[Q], ue = Y[Q + 1];
|
|
54
|
+
if (g > ne && g < ue)
|
|
69
55
|
return !1;
|
|
70
56
|
}
|
|
71
57
|
return !0;
|
|
72
|
-
},
|
|
73
|
-
const
|
|
58
|
+
}, H = () => {
|
|
59
|
+
const C = localStorage.getItem("pro__Login_Userinfo");
|
|
74
60
|
let D = "anonymous";
|
|
75
|
-
if (
|
|
61
|
+
if (C)
|
|
76
62
|
try {
|
|
77
|
-
D = JSON.parse(
|
|
63
|
+
D = JSON.parse(C).value.jobNumber || "anonymous";
|
|
78
64
|
} catch (Y) {
|
|
79
65
|
console.warn("解析用户信息失败:", Y);
|
|
80
66
|
}
|
|
81
|
-
let g =
|
|
67
|
+
let g = r?.path;
|
|
82
68
|
return `searchFormConfig_${D}_${g}`;
|
|
83
|
-
},
|
|
84
|
-
ja_JP: () =>
|
|
85
|
-
en_US: () =>
|
|
86
|
-
zh_CN: () =>
|
|
87
|
-
})[
|
|
69
|
+
}, F = (C) => ({
|
|
70
|
+
ja_JP: () => ke.get(m, C.labelLanguage || ""),
|
|
71
|
+
en_US: () => ke.get(_, C.labelLanguage || ""),
|
|
72
|
+
zh_CN: () => ke.get(p, C.labelLanguage || "")
|
|
73
|
+
})[M.lan]?.() || C.label, t = () => {
|
|
88
74
|
try {
|
|
89
|
-
const
|
|
75
|
+
const C = H(), D = localStorage.getItem(C);
|
|
90
76
|
if (D) {
|
|
91
77
|
const g = JSON.parse(D);
|
|
92
78
|
if (g.originalList && Array.isArray(g.originalList)) {
|
|
93
79
|
S = JSON.parse(JSON.stringify(g.originalList));
|
|
94
|
-
const Y = S.filter((
|
|
95
|
-
|
|
96
|
-
label:
|
|
97
|
-
key:
|
|
98
|
-
isFixed:
|
|
99
|
-
isLinked:
|
|
100
|
-
labelLanguage:
|
|
101
|
-
})),
|
|
102
|
-
|
|
103
|
-
label:
|
|
104
|
-
key:
|
|
105
|
-
isFixed:
|
|
80
|
+
const Y = S.filter(($) => $?.isFixed), Q = S.filter(($) => $?.isLinked), ne = g.showList.filter(($) => !$.isFixed && !$.isLinked), ue = h.showNumber && h.showNumber > 0 ? Math.max(0, h.showNumber - Y.length - Q.length) : ne.length, ge = Y.map(($) => ({
|
|
81
|
+
...$,
|
|
82
|
+
label: F($) || `${$.subLabel || ""}${n("hbLibComp.hbFormItemFilterModal.moreConditionSearch")}`,
|
|
83
|
+
key: $.key,
|
|
84
|
+
isFixed: $?.isFixed || !1,
|
|
85
|
+
isLinked: $?.isLinked || !1,
|
|
86
|
+
labelLanguage: $?.labelLanguage || void 0
|
|
87
|
+
})), ye = Q.map(($) => ({
|
|
88
|
+
...$,
|
|
89
|
+
label: F($) || `${$.subLabel || ""}${n("hbLibComp.hbFormItemFilterModal.moreConditionSearch")}`,
|
|
90
|
+
key: $.key,
|
|
91
|
+
isFixed: $?.isFixed || !1,
|
|
106
92
|
isLinked: !0,
|
|
107
|
-
labelLanguage:
|
|
108
|
-
})),
|
|
109
|
-
|
|
110
|
-
label:
|
|
111
|
-
key:
|
|
112
|
-
isFixed:
|
|
113
|
-
isLinked:
|
|
114
|
-
labelLanguage:
|
|
93
|
+
labelLanguage: $?.labelLanguage || void 0
|
|
94
|
+
})), Ce = ne.slice(0, ue).map(($) => ({
|
|
95
|
+
...$,
|
|
96
|
+
label: F($) || `${$.subLabel || ""}${n("hbLibComp.hbFormItemFilterModal.moreConditionSearch")}`,
|
|
97
|
+
key: $.key,
|
|
98
|
+
isFixed: $?.isFixed || !1,
|
|
99
|
+
isLinked: $?.isLinked || !1,
|
|
100
|
+
labelLanguage: $?.labelLanguage || void 0
|
|
115
101
|
}));
|
|
116
|
-
|
|
117
|
-
const
|
|
118
|
-
return U.value = S.filter((
|
|
119
|
-
|
|
120
|
-
label:
|
|
121
|
-
key:
|
|
122
|
-
isFixed:
|
|
123
|
-
isLinked:
|
|
102
|
+
x.value = [...ge, ...ye, ...Ce];
|
|
103
|
+
const A = x.value.map(($) => $.key), lt = S.map(($) => $.key).filter(($) => !A.includes($));
|
|
104
|
+
return U.value = S.filter(($) => lt.includes($.key)).map(($) => ({
|
|
105
|
+
...$,
|
|
106
|
+
label: F($) || `${$.subLabel || ""}${n("hbLibComp.hbFormItemFilterModal.moreConditionSearch")}`,
|
|
107
|
+
key: $.key,
|
|
108
|
+
isFixed: $?.isFixed || !1,
|
|
109
|
+
isLinked: $?.isLinked || !1,
|
|
124
110
|
active: !1,
|
|
125
|
-
labelLanguage:
|
|
111
|
+
labelLanguage: $?.labelLanguage || void 0
|
|
126
112
|
})), !0;
|
|
127
113
|
}
|
|
128
114
|
}
|
|
129
|
-
} catch (
|
|
130
|
-
console.warn("加载保存的搜索配置失败:",
|
|
115
|
+
} catch (C) {
|
|
116
|
+
console.warn("加载保存的搜索配置失败:", C);
|
|
131
117
|
}
|
|
132
118
|
return !1;
|
|
133
|
-
},
|
|
119
|
+
}, a = () => {
|
|
134
120
|
try {
|
|
135
|
-
const
|
|
121
|
+
const C = {
|
|
136
122
|
originalList: S,
|
|
137
|
-
showList:
|
|
123
|
+
showList: x.value.map((g) => ({
|
|
138
124
|
...g,
|
|
139
125
|
key: g.key,
|
|
140
126
|
label: g.label,
|
|
@@ -142,148 +128,148 @@ const yt = {
|
|
|
142
128
|
isLinked: g.isLinked,
|
|
143
129
|
labelLanguage: g?.labelLanguage || void 0
|
|
144
130
|
}))
|
|
145
|
-
}, D =
|
|
146
|
-
localStorage.setItem(D, JSON.stringify(
|
|
147
|
-
} catch (
|
|
148
|
-
console.warn("保存搜索配置失败:",
|
|
131
|
+
}, D = H();
|
|
132
|
+
localStorage.setItem(D, JSON.stringify(C));
|
|
133
|
+
} catch (C) {
|
|
134
|
+
console.warn("保存搜索配置失败:", C);
|
|
149
135
|
}
|
|
150
|
-
},
|
|
151
|
-
const
|
|
152
|
-
return
|
|
136
|
+
}, f = W(() => {
|
|
137
|
+
const C = x.value.filter((g) => !g.isFixed && !g.isLinked).length, D = x.value.filter((g) => g.isFixed || g.isLinked).length;
|
|
138
|
+
return C >= h.showNumber - D;
|
|
153
139
|
});
|
|
154
|
-
|
|
155
|
-
() =>
|
|
156
|
-
(
|
|
157
|
-
if (!
|
|
158
|
-
S = JSON.parse(JSON.stringify(
|
|
159
|
-
const g =
|
|
160
|
-
...
|
|
161
|
-
label:
|
|
162
|
-
key:
|
|
163
|
-
isFixed:
|
|
164
|
-
isLinked:
|
|
165
|
-
labelLanguage:
|
|
166
|
-
})),
|
|
167
|
-
...
|
|
168
|
-
label:
|
|
169
|
-
key:
|
|
170
|
-
isFixed:
|
|
140
|
+
se(
|
|
141
|
+
() => h.list,
|
|
142
|
+
(C) => {
|
|
143
|
+
if (!t() && S.length === 0) {
|
|
144
|
+
S = JSON.parse(JSON.stringify(C));
|
|
145
|
+
const g = C.filter((A) => A?.isFixed), Y = C.filter((A) => A?.isLinked), Q = C.filter((A) => !A?.isFixed && !A?.isLinked), ne = h.showNumber && h.showNumber > 0 ? Math.max(0, h.showNumber - g.length - Y.length) : Q.length, ue = g.map((A) => ({
|
|
146
|
+
...A,
|
|
147
|
+
label: F(A) || `${A.subLabel || ""}${n("hbLibComp.hbFormItemFilterModal.moreConditionSearch")}`,
|
|
148
|
+
key: A.key,
|
|
149
|
+
isFixed: A?.isFixed || !1,
|
|
150
|
+
isLinked: A?.isLinked || !1,
|
|
151
|
+
labelLanguage: A?.labelLanguage || void 0
|
|
152
|
+
})), ge = Y.map((A) => ({
|
|
153
|
+
...A,
|
|
154
|
+
label: F(A) || `${A.subLabel || ""}${n("hbLibComp.hbFormItemFilterModal.moreConditionSearch")}`,
|
|
155
|
+
key: A.key,
|
|
156
|
+
isFixed: A?.isFixed || !1,
|
|
171
157
|
isLinked: !0,
|
|
172
|
-
labelLanguage:
|
|
173
|
-
})),
|
|
174
|
-
...
|
|
175
|
-
label:
|
|
176
|
-
key:
|
|
177
|
-
isFixed:
|
|
178
|
-
isLinked:
|
|
179
|
-
labelLanguage:
|
|
158
|
+
labelLanguage: A?.labelLanguage || void 0
|
|
159
|
+
})), ye = Q.slice(0, ne).map((A) => ({
|
|
160
|
+
...A,
|
|
161
|
+
label: F(A) || `${A.subLabel || ""}${n("hbLibComp.hbFormItemFilterModal.moreConditionSearch")}`,
|
|
162
|
+
key: A.key,
|
|
163
|
+
isFixed: A?.isFixed || !1,
|
|
164
|
+
isLinked: A?.isLinked || !1,
|
|
165
|
+
labelLanguage: A?.labelLanguage || void 0
|
|
180
166
|
}));
|
|
181
|
-
|
|
182
|
-
const
|
|
183
|
-
...
|
|
184
|
-
label:
|
|
185
|
-
key:
|
|
186
|
-
isFixed:
|
|
187
|
-
isLinked:
|
|
167
|
+
x.value = [...ue, ...ge, ...ye];
|
|
168
|
+
const Ce = Q.slice(ne).map((A) => ({
|
|
169
|
+
...A,
|
|
170
|
+
label: F(A) || `${A.subLabel || ""}${n("hbLibComp.hbFormItemFilterModal.moreConditionSearch")}`,
|
|
171
|
+
key: A.key,
|
|
172
|
+
isFixed: A?.isFixed || !1,
|
|
173
|
+
isLinked: A?.isLinked || !1,
|
|
188
174
|
active: !1,
|
|
189
|
-
labelLanguage:
|
|
175
|
+
labelLanguage: A?.labelLanguage || void 0
|
|
190
176
|
}));
|
|
191
|
-
U.value =
|
|
177
|
+
U.value = Ce;
|
|
192
178
|
}
|
|
193
179
|
},
|
|
194
180
|
{ immediate: !0 }
|
|
195
181
|
);
|
|
196
|
-
const
|
|
197
|
-
const D =
|
|
198
|
-
D !== -1 && (
|
|
199
|
-
},
|
|
200
|
-
if (
|
|
182
|
+
const y = (C) => {
|
|
183
|
+
const D = x.value.findIndex((g) => g.key === C.key);
|
|
184
|
+
D !== -1 && (x.value.splice(D, 1), U.value.push({ ...C, active: !1 }));
|
|
185
|
+
}, c = (C) => {
|
|
186
|
+
if (f.value)
|
|
201
187
|
return;
|
|
202
|
-
const D = U.value.findIndex((g) => g.key ===
|
|
188
|
+
const D = U.value.findIndex((g) => g.key === C.key);
|
|
203
189
|
if (D !== -1) {
|
|
204
190
|
const [g] = U.value.splice(D, 1);
|
|
205
|
-
|
|
191
|
+
x.value.push({ ...g, active: !1 });
|
|
206
192
|
}
|
|
207
193
|
}, K = () => {
|
|
208
|
-
|
|
194
|
+
w.value = !1;
|
|
209
195
|
}, P = () => {
|
|
210
|
-
|
|
211
|
-
},
|
|
212
|
-
|
|
213
|
-
}, G = (
|
|
214
|
-
const D = U.value.findIndex((g) => g.key ===
|
|
196
|
+
w.value = !0;
|
|
197
|
+
}, te = () => {
|
|
198
|
+
a(), l("confirm", x.value), K();
|
|
199
|
+
}, G = (C) => {
|
|
200
|
+
const D = U.value.findIndex((g) => g.key === C.key);
|
|
215
201
|
D !== -1 && (U.value[D].active = !0);
|
|
216
|
-
},
|
|
217
|
-
const D = U.value.findIndex((g) => g.key ===
|
|
202
|
+
}, q = (C) => {
|
|
203
|
+
const D = U.value.findIndex((g) => g.key === C.key);
|
|
218
204
|
D !== -1 && (U.value[D].active = !1);
|
|
219
205
|
};
|
|
220
|
-
return
|
|
206
|
+
return d({
|
|
221
207
|
toOpenModal: P
|
|
222
|
-
}), (
|
|
223
|
-
class: z(
|
|
208
|
+
}), (C, D) => (o(), k("div", {
|
|
209
|
+
class: z(i(s).b())
|
|
224
210
|
}, [
|
|
225
|
-
|
|
226
|
-
visible:
|
|
227
|
-
"onUpdate:visible": D[1] || (D[1] = (g) =>
|
|
228
|
-
width:
|
|
211
|
+
T(i(Se), {
|
|
212
|
+
visible: w.value,
|
|
213
|
+
"onUpdate:visible": D[1] || (D[1] = (g) => w.value = g),
|
|
214
|
+
width: N.value,
|
|
229
215
|
onCancel: K,
|
|
230
|
-
onOk:
|
|
216
|
+
onOk: te
|
|
231
217
|
}, {
|
|
232
|
-
title:
|
|
218
|
+
title: b(() => [
|
|
233
219
|
v("div", {
|
|
234
|
-
class: z(
|
|
235
|
-
}, L(
|
|
220
|
+
class: z(i(s).e("title"))
|
|
221
|
+
}, L(e.title), 3)
|
|
236
222
|
]),
|
|
237
|
-
footer:
|
|
238
|
-
|
|
239
|
-
default:
|
|
240
|
-
I(L(
|
|
223
|
+
footer: b(() => [
|
|
224
|
+
T(i(de), { onClick: K }, {
|
|
225
|
+
default: b(() => [
|
|
226
|
+
I(L(C.$t("hbLibComp.hbFormItemFilterModal.cancel")), 1)
|
|
241
227
|
]),
|
|
242
228
|
_: 1
|
|
243
229
|
}),
|
|
244
|
-
|
|
230
|
+
T(i(de), {
|
|
245
231
|
type: "primary",
|
|
246
|
-
onClick:
|
|
232
|
+
onClick: te
|
|
247
233
|
}, {
|
|
248
|
-
default:
|
|
249
|
-
I(L(
|
|
234
|
+
default: b(() => [
|
|
235
|
+
I(L(C.$t("hbLibComp.hbFormItemFilterModal.confirm")), 1)
|
|
250
236
|
]),
|
|
251
237
|
_: 1
|
|
252
238
|
})
|
|
253
239
|
]),
|
|
254
|
-
default:
|
|
240
|
+
default: b(() => [
|
|
255
241
|
v("section", {
|
|
256
|
-
class: z(
|
|
242
|
+
class: z(i(s).e("show"))
|
|
257
243
|
}, [
|
|
258
244
|
v("div", {
|
|
259
|
-
class: z(
|
|
245
|
+
class: z(i(s).e("show__title"))
|
|
260
246
|
}, [
|
|
261
247
|
v("span", {
|
|
262
|
-
class: z(
|
|
263
|
-
}, L(
|
|
264
|
-
v("span", null, L(
|
|
248
|
+
class: z(i(s).e("title__tip"))
|
|
249
|
+
}, L(C.$t("hbLibComp.hbFormItemFilterModal.titleTip")), 3),
|
|
250
|
+
v("span", null, L(C.$t("hbLibComp.hbFormItemFilterModal.mostMore")) + L(e.showNumber) + L(C.$t("hbLibComp.hbFormItemFilterModal.mostMoreTip")), 1)
|
|
265
251
|
], 2),
|
|
266
252
|
v("div", {
|
|
267
|
-
class: z(
|
|
253
|
+
class: z(i(s).e("show__tag"))
|
|
268
254
|
}, [
|
|
269
|
-
|
|
270
|
-
modelValue:
|
|
271
|
-
"onUpdate:modelValue": D[0] || (D[0] = (g) =>
|
|
255
|
+
T(i(me), {
|
|
256
|
+
modelValue: x.value,
|
|
257
|
+
"onUpdate:modelValue": D[0] || (D[0] = (g) => x.value = g),
|
|
272
258
|
"item-key": "key",
|
|
273
259
|
tag: "div",
|
|
274
260
|
disabled: E.value,
|
|
275
261
|
move: V
|
|
276
262
|
}, {
|
|
277
|
-
item:
|
|
263
|
+
item: b(({ element: g }) => [
|
|
278
264
|
v("div", {
|
|
279
|
-
class: z([
|
|
265
|
+
class: z([i(s).e("show__tag__item"), i(s).is("fixed", g.isFixed), i(s).is("linked", g.isLinked)])
|
|
280
266
|
}, [
|
|
281
267
|
I(L(g.label) + " ", 1),
|
|
282
|
-
!g.isFixed && !g.isLinked &&
|
|
268
|
+
!g.isFixed && !g.isLinked && e.list.length > 1 ? (o(), B(i(bt), {
|
|
283
269
|
key: 0,
|
|
284
|
-
class: z(
|
|
285
|
-
onClick: (Y) =>
|
|
286
|
-
}, null, 8, ["class", "onClick"])) :
|
|
270
|
+
class: z(i(s).e("show__tag__item-close")),
|
|
271
|
+
onClick: (Y) => y(g)
|
|
272
|
+
}, null, 8, ["class", "onClick"])) : R("", !0)
|
|
287
273
|
], 2)
|
|
288
274
|
]),
|
|
289
275
|
_: 1
|
|
@@ -291,34 +277,34 @@ const yt = {
|
|
|
291
277
|
], 2)
|
|
292
278
|
], 2),
|
|
293
279
|
v("section", {
|
|
294
|
-
class: z(
|
|
280
|
+
class: z(i(s).e("unshow"))
|
|
295
281
|
}, [
|
|
296
282
|
v("div", {
|
|
297
|
-
class: z(
|
|
283
|
+
class: z(i(s).e("show__title"))
|
|
298
284
|
}, [
|
|
299
285
|
v("span", {
|
|
300
|
-
class: z(
|
|
301
|
-
}, L(
|
|
286
|
+
class: z(i(s).e("title__tip"))
|
|
287
|
+
}, L(C.$t("hbLibComp.hbFormItemFilterModal.notShowTip")), 3)
|
|
302
288
|
], 2),
|
|
303
289
|
v("div", {
|
|
304
|
-
class: z(
|
|
290
|
+
class: z(i(s).e("unshow__tag"))
|
|
305
291
|
}, [
|
|
306
|
-
U.value.length > 0 ? (o(!0), k(J, { key: 0 },
|
|
307
|
-
class: z([
|
|
292
|
+
U.value.length > 0 ? (o(!0), k(J, { key: 0 }, ae(U.value, (g) => (o(), k("div", {
|
|
293
|
+
class: z([i(s).e("unshow__tag__item"), i(s).is("fixed", g.isFixed || ""), i(s).is("linked", g.isLinked || "")]),
|
|
308
294
|
key: g.key,
|
|
309
295
|
onMouseenter: (Y) => G(g),
|
|
310
|
-
onMouseleave: (Y) =>
|
|
296
|
+
onMouseleave: (Y) => q(g)
|
|
311
297
|
}, [
|
|
312
298
|
I(L(g.label) + " ", 1),
|
|
313
299
|
g.active ? (o(), k("aside", {
|
|
314
300
|
key: 0,
|
|
315
|
-
class: z(
|
|
316
|
-
onClick: (Y) =>
|
|
317
|
-
}, L(
|
|
318
|
-
], 42,
|
|
301
|
+
class: z(i(s).e("unshow__tag__item-add")),
|
|
302
|
+
onClick: (Y) => c(g)
|
|
303
|
+
}, L(C.$t("hbLibComp.hbFormItemFilterModal.add")), 11, Ft)) : R("", !0)
|
|
304
|
+
], 42, wt))), 128)) : (o(), k("div", {
|
|
319
305
|
key: 1,
|
|
320
|
-
class: z(
|
|
321
|
-
}, L(
|
|
306
|
+
class: z(i(s).e("unshow__tag__empty"))
|
|
307
|
+
}, L(C.$t("hbLibComp.hbFormItemFilterModal.noData")), 3))
|
|
322
308
|
], 2)
|
|
323
309
|
], 2)
|
|
324
310
|
]),
|
|
@@ -326,27 +312,41 @@ const yt = {
|
|
|
326
312
|
}, 8, ["visible", "width"])
|
|
327
313
|
], 2));
|
|
328
314
|
}
|
|
329
|
-
}),
|
|
330
|
-
const
|
|
331
|
-
for (const [
|
|
332
|
-
|
|
333
|
-
return
|
|
334
|
-
},
|
|
335
|
-
for (const
|
|
336
|
-
|
|
337
|
-
},
|
|
338
|
-
//
|
|
339
|
-
|
|
315
|
+
}), oe = (e, d) => {
|
|
316
|
+
const u = e.__vccOpts || e;
|
|
317
|
+
for (const [n, _] of d)
|
|
318
|
+
u[n] = _;
|
|
319
|
+
return u;
|
|
320
|
+
}, Tt = /* @__PURE__ */ oe(xt, [["__scopeId", "data-v-6ceb65e8"]]), le = (e, d) => (e.install = (u) => {
|
|
321
|
+
for (const n of [e, ...Object.values({})])
|
|
322
|
+
u.component(n.name, n);
|
|
323
|
+
}, e), $t = {
|
|
324
|
+
// 数据源 一般等于搜索框的options
|
|
325
|
+
list: {
|
|
340
326
|
type: Array,
|
|
327
|
+
default: () => [],
|
|
341
328
|
required: !0
|
|
342
329
|
},
|
|
343
|
-
|
|
344
|
-
type:
|
|
345
|
-
|
|
330
|
+
afterChange: {
|
|
331
|
+
type: Function,
|
|
332
|
+
default: () => {
|
|
333
|
+
}
|
|
346
334
|
},
|
|
347
|
-
|
|
348
|
-
type:
|
|
349
|
-
default:
|
|
335
|
+
title: {
|
|
336
|
+
type: String,
|
|
337
|
+
default: "自定义查询条件"
|
|
338
|
+
},
|
|
339
|
+
showNumber: {
|
|
340
|
+
type: Number,
|
|
341
|
+
default: 40
|
|
342
|
+
}
|
|
343
|
+
}, Mt = le(Tt), Ht = { class: "form-footer" }, It = /* @__PURE__ */ X({
|
|
344
|
+
name: "HbLibListForm",
|
|
345
|
+
__name: "HbListForm",
|
|
346
|
+
props: {
|
|
347
|
+
items: { default: () => [] },
|
|
348
|
+
formData: {},
|
|
349
|
+
layoutConfig: { default: () => ({
|
|
350
350
|
// 对row的属性设置
|
|
351
351
|
row: {
|
|
352
352
|
gutter: 20
|
|
@@ -360,219 +360,202 @@ const yt = {
|
|
|
360
360
|
lg: 6,
|
|
361
361
|
xl: 6
|
|
362
362
|
}
|
|
363
|
-
}
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
type:
|
|
368
|
-
|
|
369
|
-
},
|
|
370
|
-
isFormExpanded: {
|
|
371
|
-
type: Boolean,
|
|
372
|
-
default: !0
|
|
363
|
+
}) },
|
|
364
|
+
needFooter: { type: Boolean, default: !1 },
|
|
365
|
+
isFormExpanded: { type: Boolean, default: !0 },
|
|
366
|
+
needFilter: { type: Boolean, default: !0 },
|
|
367
|
+
calTableHeight: { type: Function, default: () => () => {
|
|
368
|
+
} }
|
|
373
369
|
},
|
|
374
|
-
needFilter: {
|
|
375
|
-
type: Boolean,
|
|
376
|
-
default: !0
|
|
377
|
-
},
|
|
378
|
-
calTableHeight: {
|
|
379
|
-
type: Function,
|
|
380
|
-
default: () => {
|
|
381
|
-
}
|
|
382
|
-
}
|
|
383
|
-
}, Tt = { class: "form-footer" }, $t = /* @__PURE__ */ X({
|
|
384
|
-
name: "HbLibListForm",
|
|
385
|
-
__name: "HbListForm",
|
|
386
|
-
props: xt,
|
|
387
370
|
emits: ["handleSearch", "handleReset", "handleSfcmConfirm", "handleOpenOrClose"],
|
|
388
|
-
setup(
|
|
389
|
-
const
|
|
390
|
-
|
|
391
|
-
},
|
|
392
|
-
|
|
393
|
-
},
|
|
394
|
-
|
|
395
|
-
}, S = (
|
|
396
|
-
|
|
397
|
-
},
|
|
398
|
-
|
|
371
|
+
setup(e, { expose: d, emit: u }) {
|
|
372
|
+
const n = u, _ = xe("HB_LIST_PAGE_CONTAINER"), m = fe("form"), p = e, h = O("show"), l = W(() => (console.log(p.items), [...p.items])), s = O(), r = () => {
|
|
373
|
+
n("handleSearch");
|
|
374
|
+
}, M = () => {
|
|
375
|
+
n("handleReset");
|
|
376
|
+
}, w = O(), N = () => {
|
|
377
|
+
w.value && w.value.toOpenModal();
|
|
378
|
+
}, S = (F) => {
|
|
379
|
+
n("handleSfcmConfirm", F);
|
|
380
|
+
}, x = () => {
|
|
381
|
+
h.value = h.value === "show" ? "hide" : "show";
|
|
399
382
|
};
|
|
400
|
-
|
|
401
|
-
() =>
|
|
402
|
-
(
|
|
403
|
-
if (
|
|
404
|
-
console.log(
|
|
405
|
-
const
|
|
406
|
-
|
|
407
|
-
|
|
383
|
+
se(
|
|
384
|
+
() => p.isFormExpanded,
|
|
385
|
+
(F) => {
|
|
386
|
+
if (F) {
|
|
387
|
+
console.log(F);
|
|
388
|
+
const t = document.querySelector("#subpackage_container");
|
|
389
|
+
t instanceof HTMLElement && (t.style.overflow = "hidden", setTimeout(() => {
|
|
390
|
+
t.style.overflow = "auto";
|
|
408
391
|
}, 500));
|
|
409
392
|
}
|
|
410
393
|
}
|
|
411
394
|
);
|
|
412
|
-
const U = (
|
|
413
|
-
const
|
|
414
|
-
|
|
415
|
-
}, E = (
|
|
416
|
-
const
|
|
417
|
-
|
|
418
|
-
|
|
395
|
+
const U = (F) => {
|
|
396
|
+
const t = F;
|
|
397
|
+
t.style.height = "", t.offsetHeight;
|
|
398
|
+
}, E = (F) => {
|
|
399
|
+
const t = F;
|
|
400
|
+
t.style.height = "", t.style.overflow = "", he(() => {
|
|
401
|
+
_.calTableHeight && _.calTableHeight();
|
|
419
402
|
});
|
|
420
|
-
}, V = (
|
|
421
|
-
const
|
|
422
|
-
if (
|
|
423
|
-
const
|
|
424
|
-
|
|
425
|
-
|
|
403
|
+
}, V = (F) => {
|
|
404
|
+
const t = F, a = t.querySelector(".hb-lib-form--container");
|
|
405
|
+
if (a) {
|
|
406
|
+
const f = a.offsetHeight;
|
|
407
|
+
t.style.height = f + "px", t.style.overflow = "hidden", t.offsetHeight, requestAnimationFrame(() => {
|
|
408
|
+
t.style.height = "0";
|
|
426
409
|
});
|
|
427
410
|
}
|
|
428
|
-
},
|
|
429
|
-
|
|
430
|
-
|
|
411
|
+
}, H = () => {
|
|
412
|
+
he(() => {
|
|
413
|
+
_.calTableHeight && _.calTableHeight();
|
|
431
414
|
});
|
|
432
415
|
};
|
|
433
|
-
return
|
|
434
|
-
formRef:
|
|
435
|
-
SelectOption:
|
|
436
|
-
Form:
|
|
437
|
-
FormItem:
|
|
438
|
-
Row:
|
|
439
|
-
Col:
|
|
440
|
-
Input:
|
|
441
|
-
Select:
|
|
416
|
+
return d({
|
|
417
|
+
formRef: s,
|
|
418
|
+
SelectOption: Ke,
|
|
419
|
+
Form: Ue,
|
|
420
|
+
FormItem: Ve,
|
|
421
|
+
Row: yt,
|
|
422
|
+
Col: gt,
|
|
423
|
+
Input: Ee,
|
|
424
|
+
Select: ze,
|
|
442
425
|
CheckboxGroup: Pe,
|
|
443
|
-
Checkbox:
|
|
444
|
-
DatePicker:
|
|
445
|
-
InputNumber:
|
|
446
|
-
RadioGroup:
|
|
447
|
-
Radio:
|
|
448
|
-
Switch:
|
|
426
|
+
Checkbox: ve,
|
|
427
|
+
DatePicker: Re,
|
|
428
|
+
InputNumber: Ne,
|
|
429
|
+
RadioGroup: Be,
|
|
430
|
+
Radio: Oe,
|
|
431
|
+
Switch: De,
|
|
449
432
|
Button: de,
|
|
450
|
-
Tooltip:
|
|
451
|
-
}), (
|
|
452
|
-
const
|
|
433
|
+
Tooltip: Ae
|
|
434
|
+
}), (F, t) => {
|
|
435
|
+
const a = j("a-button"), f = j("a-tooltip"), y = j("HbLibFormItemFilterModal");
|
|
453
436
|
return o(), k(J, null, [
|
|
454
|
-
|
|
437
|
+
T(at, {
|
|
455
438
|
name: "form-collapse",
|
|
456
439
|
onEnter: U,
|
|
457
440
|
onAfterEnter: E,
|
|
458
441
|
onLeave: V,
|
|
459
|
-
onAfterLeave:
|
|
442
|
+
onAfterLeave: H
|
|
460
443
|
}, {
|
|
461
|
-
default:
|
|
462
|
-
|
|
463
|
-
class: z([
|
|
444
|
+
default: b(() => [
|
|
445
|
+
re(v("div", {
|
|
446
|
+
class: z([i(m).b(), "hb-lib-list-page-form-box hb-form-item-ui"])
|
|
464
447
|
}, [
|
|
465
|
-
|
|
466
|
-
model:
|
|
448
|
+
T(i(Ue), ee(F.$attrs, {
|
|
449
|
+
model: e.formData,
|
|
467
450
|
ref_key: "formRef",
|
|
468
|
-
ref:
|
|
469
|
-
class: ["hb-lib-form--container",
|
|
451
|
+
ref: s,
|
|
452
|
+
class: ["hb-lib-form--container", h.value == "show" ? "" : "hide"]
|
|
470
453
|
}), {
|
|
471
|
-
default:
|
|
472
|
-
(o(!0), k(J, null,
|
|
454
|
+
default: b(() => [
|
|
455
|
+
(o(!0), k(J, null, ae(l.value, (c, K) => (o(), B(i(Ve), ee({
|
|
473
456
|
key: K,
|
|
474
457
|
ref_for: !0
|
|
475
|
-
},
|
|
476
|
-
name:
|
|
477
|
-
class:
|
|
478
|
-
}),
|
|
479
|
-
default:
|
|
480
|
-
|
|
458
|
+
}, c, {
|
|
459
|
+
name: c.key,
|
|
460
|
+
class: c.isUnNeedBorder ? "hb-lib-form-item-border--unneed" : ""
|
|
461
|
+
}), Qe({
|
|
462
|
+
default: b(() => [
|
|
463
|
+
c.type === "slot" ? Z(F.$slots, c.key, {
|
|
481
464
|
key: 0,
|
|
482
|
-
formData:
|
|
483
|
-
item:
|
|
484
|
-
}, void 0, !0) :
|
|
485
|
-
|
|
465
|
+
formData: e.formData,
|
|
466
|
+
item: c
|
|
467
|
+
}, void 0, !0) : R("", !0),
|
|
468
|
+
c.type === "mixin" ? Z(F.$slots, c.key, {
|
|
486
469
|
key: 1,
|
|
487
|
-
formData:
|
|
488
|
-
item:
|
|
489
|
-
}, void 0, !0) :
|
|
490
|
-
|
|
470
|
+
formData: e.formData,
|
|
471
|
+
item: c
|
|
472
|
+
}, void 0, !0) : R("", !0),
|
|
473
|
+
c.type === "input" ? (o(), B(i(Ee), ee({
|
|
491
474
|
key: 2,
|
|
492
|
-
value:
|
|
493
|
-
"onUpdate:value": (P) =>
|
|
494
|
-
}, { ref_for: !0 },
|
|
495
|
-
|
|
475
|
+
value: e.formData[c.key],
|
|
476
|
+
"onUpdate:value": (P) => e.formData[c.key] = P
|
|
477
|
+
}, { ref_for: !0 }, c.attrs), null, 16, ["value", "onUpdate:value"])) : R("", !0),
|
|
478
|
+
c.type === "select" ? (o(), B(i(ze), ee({
|
|
496
479
|
key: 3,
|
|
497
|
-
value:
|
|
498
|
-
"onUpdate:value": (P) =>
|
|
499
|
-
}, { ref_for: !0 },
|
|
500
|
-
default:
|
|
501
|
-
(o(!0), k(J, null,
|
|
502
|
-
key:
|
|
480
|
+
value: e.formData[c.key],
|
|
481
|
+
"onUpdate:value": (P) => e.formData[c.key] = P
|
|
482
|
+
}, { ref_for: !0 }, c.attrs), {
|
|
483
|
+
default: b(() => [
|
|
484
|
+
(o(!0), k(J, null, ae(c.options, (P, te) => (o(), B(i(Ke), {
|
|
485
|
+
key: te,
|
|
503
486
|
value: P.value
|
|
504
487
|
}, {
|
|
505
|
-
default:
|
|
488
|
+
default: b(() => [
|
|
506
489
|
I(L(P.label), 1)
|
|
507
490
|
]),
|
|
508
491
|
_: 2
|
|
509
492
|
}, 1032, ["value"]))), 128))
|
|
510
493
|
]),
|
|
511
494
|
_: 2
|
|
512
|
-
}, 1040, ["value", "onUpdate:value"])) :
|
|
513
|
-
|
|
495
|
+
}, 1040, ["value", "onUpdate:value"])) : R("", !0),
|
|
496
|
+
c.type === "checkbox" ? (o(), B(i(Pe), ee({
|
|
514
497
|
key: 4,
|
|
515
|
-
value:
|
|
516
|
-
"onUpdate:value": (P) =>
|
|
517
|
-
}, { ref_for: !0 },
|
|
518
|
-
default:
|
|
519
|
-
(o(!0), k(J, null,
|
|
520
|
-
key:
|
|
498
|
+
value: e.formData[c.key],
|
|
499
|
+
"onUpdate:value": (P) => e.formData[c.key] = P
|
|
500
|
+
}, { ref_for: !0 }, c.attrs), {
|
|
501
|
+
default: b(() => [
|
|
502
|
+
(o(!0), k(J, null, ae(c.options, (P, te) => (o(), B(i(ve), {
|
|
503
|
+
key: te,
|
|
521
504
|
value: P.value
|
|
522
505
|
}, {
|
|
523
|
-
default:
|
|
506
|
+
default: b(() => [
|
|
524
507
|
I(L(P.label), 1)
|
|
525
508
|
]),
|
|
526
509
|
_: 2
|
|
527
510
|
}, 1032, ["value"]))), 128))
|
|
528
511
|
]),
|
|
529
512
|
_: 2
|
|
530
|
-
}, 1040, ["value", "onUpdate:value"])) :
|
|
531
|
-
|
|
513
|
+
}, 1040, ["value", "onUpdate:value"])) : R("", !0),
|
|
514
|
+
c.type === "date-picker" ? (o(), B(i(Re), ee({
|
|
532
515
|
key: 5,
|
|
533
|
-
value:
|
|
534
|
-
"onUpdate:value": (P) =>
|
|
535
|
-
}, { ref_for: !0 },
|
|
536
|
-
|
|
516
|
+
value: e.formData[c.key],
|
|
517
|
+
"onUpdate:value": (P) => e.formData[c.key] = P
|
|
518
|
+
}, { ref_for: !0 }, c.attrs), null, 16, ["value", "onUpdate:value"])) : R("", !0),
|
|
519
|
+
c.type === "input-number" ? (o(), B(i(Ne), ee({
|
|
537
520
|
key: 6,
|
|
538
|
-
value:
|
|
539
|
-
"onUpdate:value": (P) =>
|
|
540
|
-
}, { ref_for: !0 },
|
|
541
|
-
|
|
521
|
+
value: e.formData[c.key],
|
|
522
|
+
"onUpdate:value": (P) => e.formData[c.key] = P
|
|
523
|
+
}, { ref_for: !0 }, c.attrs), null, 16, ["value", "onUpdate:value"])) : R("", !0),
|
|
524
|
+
c.type === "radio" ? (o(), B(i(Be), ee({
|
|
542
525
|
key: 7,
|
|
543
|
-
value:
|
|
544
|
-
"onUpdate:value": (P) =>
|
|
545
|
-
}, { ref_for: !0 },
|
|
546
|
-
default:
|
|
547
|
-
(o(!0), k(J, null,
|
|
548
|
-
key:
|
|
526
|
+
value: e.formData[c.key],
|
|
527
|
+
"onUpdate:value": (P) => e.formData[c.key] = P
|
|
528
|
+
}, { ref_for: !0 }, c.attrs), {
|
|
529
|
+
default: b(() => [
|
|
530
|
+
(o(!0), k(J, null, ae(c.options, (P, te) => (o(), B(i(Oe), {
|
|
531
|
+
key: te,
|
|
549
532
|
value: P.value
|
|
550
533
|
}, {
|
|
551
|
-
default:
|
|
534
|
+
default: b(() => [
|
|
552
535
|
I(L(P.label), 1)
|
|
553
536
|
]),
|
|
554
537
|
_: 2
|
|
555
538
|
}, 1032, ["value"]))), 128))
|
|
556
539
|
]),
|
|
557
540
|
_: 2
|
|
558
|
-
}, 1040, ["value", "onUpdate:value"])) :
|
|
559
|
-
|
|
541
|
+
}, 1040, ["value", "onUpdate:value"])) : R("", !0),
|
|
542
|
+
c.type === "switch" ? (o(), B(i(De), ee({
|
|
560
543
|
key: 8,
|
|
561
|
-
checked:
|
|
562
|
-
"onUpdate:checked": (P) =>
|
|
563
|
-
}, { ref_for: !0 },
|
|
544
|
+
checked: e.formData[c.key],
|
|
545
|
+
"onUpdate:checked": (P) => e.formData[c.key] = P
|
|
546
|
+
}, { ref_for: !0 }, c.attrs), null, 16, ["checked", "onUpdate:checked"])) : R("", !0)
|
|
564
547
|
]),
|
|
565
548
|
_: 2
|
|
566
549
|
}, [
|
|
567
|
-
|
|
550
|
+
c.tooltip ? {
|
|
568
551
|
name: "label",
|
|
569
|
-
fn:
|
|
570
|
-
I(L(
|
|
571
|
-
|
|
572
|
-
title:
|
|
552
|
+
fn: b(() => [
|
|
553
|
+
I(L(c.label) + " ", 1),
|
|
554
|
+
T(i(Ae), {
|
|
555
|
+
title: c.tooltip
|
|
573
556
|
}, {
|
|
574
|
-
default:
|
|
575
|
-
|
|
557
|
+
default: b(() => [
|
|
558
|
+
T(i(ft), { style: { "margin-left": "4px", color: "#1890ff" } })
|
|
576
559
|
]),
|
|
577
560
|
_: 1
|
|
578
561
|
}, 8, ["title"])
|
|
@@ -580,38 +563,38 @@ const yt = {
|
|
|
580
563
|
key: "0"
|
|
581
564
|
} : void 0
|
|
582
565
|
]), 1040, ["name", "class"]))), 128)),
|
|
583
|
-
v("section",
|
|
584
|
-
|
|
566
|
+
v("section", Ht, [
|
|
567
|
+
T(a, {
|
|
585
568
|
type: "primary",
|
|
586
|
-
onClick:
|
|
569
|
+
onClick: r,
|
|
587
570
|
class: "hb_list_page_button"
|
|
588
571
|
}, {
|
|
589
|
-
icon:
|
|
590
|
-
|
|
572
|
+
icon: b(() => [
|
|
573
|
+
T(i($e))
|
|
591
574
|
]),
|
|
592
|
-
default:
|
|
593
|
-
I(" " + L(
|
|
575
|
+
default: b(() => [
|
|
576
|
+
I(" " + L(F.$t("hbLibComp.hbListPageAct.query")), 1)
|
|
594
577
|
]),
|
|
595
578
|
_: 1
|
|
596
579
|
}),
|
|
597
|
-
|
|
580
|
+
T(a, {
|
|
598
581
|
type: "link",
|
|
599
|
-
onClick:
|
|
582
|
+
onClick: M
|
|
600
583
|
}, {
|
|
601
|
-
default:
|
|
602
|
-
I(L(
|
|
584
|
+
default: b(() => [
|
|
585
|
+
I(L(F.$t("hbLibComp.hbListPageAct.reset")), 1)
|
|
603
586
|
]),
|
|
604
587
|
_: 1
|
|
605
588
|
}),
|
|
606
|
-
|
|
589
|
+
e.needFilter ? (o(), B(f, {
|
|
607
590
|
key: 0,
|
|
608
|
-
title:
|
|
591
|
+
title: F.$t("hbLibComp.hbListPageAct.selfDefine")
|
|
609
592
|
}, {
|
|
610
|
-
default:
|
|
593
|
+
default: b(() => [
|
|
611
594
|
v("span", {
|
|
612
595
|
class: "hb-lib-form-svg",
|
|
613
|
-
onClick:
|
|
614
|
-
}, [...
|
|
596
|
+
onClick: N
|
|
597
|
+
}, [...t[0] || (t[0] = [
|
|
615
598
|
v("svg", {
|
|
616
599
|
t: "1757915025410",
|
|
617
600
|
class: "icon",
|
|
@@ -631,94 +614,120 @@ const yt = {
|
|
|
631
614
|
])])
|
|
632
615
|
]),
|
|
633
616
|
_: 1
|
|
634
|
-
}, 8, ["title"])) :
|
|
635
|
-
Z(
|
|
617
|
+
}, 8, ["title"])) : R("", !0),
|
|
618
|
+
Z(F.$slots, "formBtns", {}, void 0, !0)
|
|
636
619
|
])
|
|
637
620
|
]),
|
|
638
621
|
_: 3
|
|
639
622
|
}, 16, ["model", "class"]),
|
|
640
|
-
|
|
623
|
+
e.needFooter ? (o(), k("div", {
|
|
641
624
|
key: 0,
|
|
642
|
-
class: z(
|
|
625
|
+
class: z(i(m).e("footer"))
|
|
643
626
|
}, [
|
|
644
627
|
v("div", {
|
|
645
|
-
class: z(
|
|
628
|
+
class: z(i(m).e("footer__left"))
|
|
646
629
|
}, [
|
|
647
|
-
Z(
|
|
630
|
+
Z(F.$slots, "form-footer-left", {}, void 0, !0)
|
|
648
631
|
], 2),
|
|
649
632
|
v("div", {
|
|
650
|
-
class: z(
|
|
633
|
+
class: z(i(m).e("footer__right"))
|
|
651
634
|
}, [
|
|
652
|
-
|
|
635
|
+
h.value == "show" ? Z(F.$slots, "form-footer-right", {
|
|
653
636
|
key: 0,
|
|
654
|
-
formRef:
|
|
637
|
+
formRef: s.value
|
|
655
638
|
}, () => [
|
|
656
|
-
|
|
639
|
+
T(i(de), {
|
|
657
640
|
type: "primary",
|
|
658
|
-
onClick:
|
|
641
|
+
onClick: M
|
|
659
642
|
}, {
|
|
660
|
-
default:
|
|
661
|
-
I(L(
|
|
643
|
+
default: b(() => [
|
|
644
|
+
I(L(F.$t("hbLibComp.hbListPageAct.reset")), 1)
|
|
662
645
|
]),
|
|
663
646
|
_: 1
|
|
664
647
|
}),
|
|
665
|
-
|
|
648
|
+
T(i(de), {
|
|
666
649
|
type: "primary",
|
|
667
|
-
onClick:
|
|
650
|
+
onClick: r
|
|
668
651
|
}, {
|
|
669
|
-
default:
|
|
670
|
-
I(L(
|
|
652
|
+
default: b(() => [
|
|
653
|
+
I(L(F.$t("hbLibComp.hbListPageAct.query")), 1)
|
|
671
654
|
]),
|
|
672
655
|
_: 1
|
|
673
656
|
})
|
|
674
|
-
], !0) :
|
|
675
|
-
|
|
657
|
+
], !0) : R("", !0),
|
|
658
|
+
T(i(de), {
|
|
676
659
|
type: "primary",
|
|
677
|
-
onClick:
|
|
660
|
+
onClick: x
|
|
678
661
|
}, {
|
|
679
|
-
default:
|
|
680
|
-
I(L(
|
|
662
|
+
default: b(() => [
|
|
663
|
+
I(L(h.value == "show" ? `${F.$t("hbLibComp.hbListPageAct.close")}` : `${F.$t("hbLibComp.hbListPageAct.open")}`), 1)
|
|
681
664
|
]),
|
|
682
665
|
_: 1
|
|
683
666
|
})
|
|
684
667
|
], 2)
|
|
685
|
-
], 2)) :
|
|
668
|
+
], 2)) : R("", !0)
|
|
686
669
|
], 2), [
|
|
687
|
-
[
|
|
670
|
+
[ot, e.isFormExpanded]
|
|
688
671
|
])
|
|
689
672
|
]),
|
|
690
673
|
_: 3
|
|
691
674
|
}),
|
|
692
|
-
|
|
693
|
-
list:
|
|
675
|
+
T(y, {
|
|
676
|
+
list: e.items,
|
|
694
677
|
ref_key: "HbSfCmRef",
|
|
695
|
-
ref:
|
|
678
|
+
ref: w,
|
|
696
679
|
onConfirm: S
|
|
697
680
|
}, null, 8, ["list"])
|
|
698
681
|
], 64);
|
|
699
682
|
};
|
|
700
683
|
}
|
|
701
|
-
}),
|
|
702
|
-
|
|
684
|
+
}), At = /* @__PURE__ */ oe(It, [["__scopeId", "data-v-a1fedfa4"]]), Dt = {
|
|
685
|
+
// 每一个表单配置对象
|
|
686
|
+
items: {
|
|
703
687
|
type: Array,
|
|
704
|
-
|
|
688
|
+
required: !0
|
|
705
689
|
},
|
|
706
|
-
|
|
707
|
-
|
|
690
|
+
formData: {
|
|
691
|
+
type: Object,
|
|
692
|
+
required: !0
|
|
693
|
+
},
|
|
694
|
+
layoutConfig: {
|
|
695
|
+
type: Object,
|
|
696
|
+
default: {
|
|
697
|
+
// 对row的属性设置
|
|
698
|
+
row: {
|
|
699
|
+
gutter: 20
|
|
700
|
+
},
|
|
701
|
+
// 对col的属性设置
|
|
702
|
+
col: {
|
|
703
|
+
// 栅格设置
|
|
704
|
+
xs: 24,
|
|
705
|
+
sm: 12,
|
|
706
|
+
md: 8,
|
|
707
|
+
lg: 6,
|
|
708
|
+
xl: 6
|
|
709
|
+
}
|
|
710
|
+
}
|
|
711
|
+
},
|
|
712
|
+
// 是否需要底部按钮
|
|
713
|
+
needFooter: {
|
|
708
714
|
type: Boolean,
|
|
709
|
-
default: !
|
|
715
|
+
default: !1
|
|
710
716
|
},
|
|
711
|
-
|
|
712
|
-
isShowOpenClose: {
|
|
717
|
+
isFormExpanded: {
|
|
713
718
|
type: Boolean,
|
|
714
719
|
default: !0
|
|
715
720
|
},
|
|
716
|
-
|
|
717
|
-
isShowFullScreen: {
|
|
721
|
+
needFilter: {
|
|
718
722
|
type: Boolean,
|
|
719
723
|
default: !0
|
|
724
|
+
},
|
|
725
|
+
calTableHeight: {
|
|
726
|
+
type: Function,
|
|
727
|
+
default: () => {
|
|
728
|
+
}
|
|
720
729
|
}
|
|
721
|
-
}, At = { class: "hb-lib-list-page-act-box" },
|
|
730
|
+
}, Ot = le(At), Bt = { class: "hb-lib-list-page-act-box" }, Nt = { class: "hb-lib-list-page-breadcrumb" }, Rt = { class: "hb-lib-list-page-act" }, Pt = {
|
|
722
731
|
key: 0,
|
|
723
732
|
t: "1757915338760",
|
|
724
733
|
class: "icon",
|
|
@@ -728,7 +737,7 @@ const yt = {
|
|
|
728
737
|
"p-id": "22885",
|
|
729
738
|
width: "200",
|
|
730
739
|
height: "200"
|
|
731
|
-
},
|
|
740
|
+
}, zt = {
|
|
732
741
|
key: 1,
|
|
733
742
|
t: "1757915360496",
|
|
734
743
|
class: "icon",
|
|
@@ -738,38 +747,43 @@ const yt = {
|
|
|
738
747
|
"p-id": "23904",
|
|
739
748
|
width: "200",
|
|
740
749
|
height: "200"
|
|
741
|
-
},
|
|
750
|
+
}, Et = /* @__PURE__ */ X({
|
|
742
751
|
name: "HbLibListPageAct",
|
|
743
752
|
__name: "HbListPageAct",
|
|
744
|
-
props:
|
|
753
|
+
props: {
|
|
754
|
+
formItems: {},
|
|
755
|
+
isShowSelfFilter: { type: Boolean, default: !0 },
|
|
756
|
+
isShowOpenClose: { type: Boolean, default: !0 },
|
|
757
|
+
isShowFullScreen: { type: Boolean, default: !0 }
|
|
758
|
+
},
|
|
745
759
|
emits: ["handleSearch", "handleReset", "handleSfcmConfirm", "handleOpenOrClose"],
|
|
746
|
-
setup(
|
|
747
|
-
const
|
|
748
|
-
const
|
|
749
|
-
let
|
|
750
|
-
if (
|
|
751
|
-
let
|
|
752
|
-
|
|
760
|
+
setup(e, { emit: d }) {
|
|
761
|
+
const u = xe("HB_LIST_PAGE_CONTAINER"), { isFullscreen: n, toggle: _ } = Lt(u.PageContainerRef), m = O(""), p = () => {
|
|
762
|
+
const h = Ze();
|
|
763
|
+
let l = localStorage.getItem("BreadCrumb") || "[]", s = h?.path;
|
|
764
|
+
if (l !== "[]") {
|
|
765
|
+
let r = JSON.parse(l).find((M) => M.value === s);
|
|
766
|
+
r && (m.value = r.label.replace(/-/g, " / "));
|
|
753
767
|
}
|
|
754
768
|
};
|
|
755
|
-
return
|
|
756
|
-
|
|
757
|
-
}), (
|
|
758
|
-
const
|
|
759
|
-
return o(), k("section",
|
|
760
|
-
v("aside",
|
|
761
|
-
v("aside",
|
|
762
|
-
|
|
763
|
-
title: n
|
|
769
|
+
return Te(() => {
|
|
770
|
+
p();
|
|
771
|
+
}), (h, l) => {
|
|
772
|
+
const s = j("a-tooltip");
|
|
773
|
+
return o(), k("section", Bt, [
|
|
774
|
+
v("aside", Nt, L(m.value), 1),
|
|
775
|
+
v("aside", Rt, [
|
|
776
|
+
T(s, {
|
|
777
|
+
title: i(n) ? `${h.$t("hbLibComp.hbListPageAct.exitFullScreen")}` : `${h.$t("hbLibComp.hbListPageAct.fullScreen")}`,
|
|
764
778
|
placement: "leftTop"
|
|
765
779
|
}, {
|
|
766
|
-
default:
|
|
780
|
+
default: b(() => [
|
|
767
781
|
v("span", {
|
|
768
782
|
class: "hb-lib-list-page-act-svg",
|
|
769
|
-
onClick:
|
|
770
|
-
(...
|
|
783
|
+
onClick: l[0] || (l[0] = //@ts-ignore
|
|
784
|
+
(...r) => i(_) && i(_)(...r))
|
|
771
785
|
}, [
|
|
772
|
-
n
|
|
786
|
+
i(n) ? (o(), k("svg", zt, [...l[2] || (l[2] = [
|
|
773
787
|
v("path", {
|
|
774
788
|
d: "M257.706667 376.32H128c-11.946667 0-21.333333-9.386667-21.333333-21.333333s9.386667-21.333333 21.333333-21.333334h129.706667c35.413333 0 64-28.586667 64-64V128c0-11.946667 9.386667-21.333333 21.333333-21.333333s21.333333 9.386667 21.333333 21.333333v141.653333a106.666667 106.666667 0 0 1-106.666666 106.666667zM896 376.32h-129.706667a106.666667 106.666667 0 0 1-106.666666-106.666667V128c0-11.946667 9.386667-21.333333 21.333333-21.333333s21.333333 9.386667 21.333333 21.333333v141.653333c0 35.413333 28.586667 64 64 64H896c11.946667 0 21.333333 9.386667 21.333333 21.333334s-9.386667 21.333333-21.333333 21.333333z",
|
|
775
789
|
fill: "#ff5000",
|
|
@@ -785,7 +799,7 @@ const yt = {
|
|
|
785
799
|
fill: "#ff5000",
|
|
786
800
|
"p-id": "23907"
|
|
787
801
|
}, null, -1)
|
|
788
|
-
])])) : (o(), k("svg",
|
|
802
|
+
])])) : (o(), k("svg", Pt, [...l[1] || (l[1] = [
|
|
789
803
|
v("path", {
|
|
790
804
|
d: "M85.333333 682.666667v128a128 128 0 0 0 128 128h128a42.666667 42.666667 0 0 0 0-85.333334H213.333333a42.666667 42.666667 0 0 1-42.666666-42.666666v-128a42.666667 42.666667 0 0 0-85.333334 0z m597.333334 256h128a128 128 0 0 0 128-128v-128a42.666667 42.666667 0 0 0-85.333334 0v128a42.666667 42.666667 0 0 1-42.666666 42.666666h-128a42.666667 42.666667 0 0 0 0 85.333334z m256-597.333334V213.333333a128 128 0 0 0-128-128h-128a42.666667 42.666667 0 0 0 0 85.333334h128a42.666667 42.666667 0 0 1 42.666666 42.666666v128a42.666667 42.666667 0 0 0 85.333334 0zM341.333333 85.333333H213.333333a128 128 0 0 0-128 128v128a42.666667 42.666667 0 0 0 85.333334 0V213.333333a42.666667 42.666667 0 0 1 42.666666-42.666666h128a42.666667 42.666667 0 0 0 0-85.333334z",
|
|
791
805
|
fill: "#ff5000",
|
|
@@ -796,12 +810,12 @@ const yt = {
|
|
|
796
810
|
]),
|
|
797
811
|
_: 1
|
|
798
812
|
}, 8, ["title"]),
|
|
799
|
-
Z(
|
|
813
|
+
Z(h.$slots, "listAct", {}, void 0, !0)
|
|
800
814
|
])
|
|
801
815
|
]);
|
|
802
816
|
};
|
|
803
817
|
}
|
|
804
|
-
}),
|
|
818
|
+
}), Vt = /* @__PURE__ */ oe(Et, [["__scopeId", "data-v-cb524b69"]]), Ut = {
|
|
805
819
|
formItems: {
|
|
806
820
|
type: Array,
|
|
807
821
|
default: () => []
|
|
@@ -811,42 +825,49 @@ const yt = {
|
|
|
811
825
|
type: Boolean,
|
|
812
826
|
default: !0
|
|
813
827
|
},
|
|
814
|
-
|
|
828
|
+
// 是否展示展开收起
|
|
829
|
+
isShowOpenClose: {
|
|
815
830
|
type: Boolean,
|
|
816
831
|
default: !0
|
|
817
832
|
},
|
|
818
|
-
|
|
833
|
+
// 是否展示全屏
|
|
834
|
+
isShowFullScreen: {
|
|
819
835
|
type: Boolean,
|
|
820
836
|
default: !0
|
|
821
837
|
}
|
|
822
|
-
}, Vt = { class: "hb-lib-list-btns-box" },
|
|
838
|
+
}, Kt = le(Vt), Yt = { class: "hb-lib-list-btns-box" }, jt = { class: "hb-lib-list-btns-left" }, qt = { class: "hb-lib-list-btns-right" }, Wt = /* @__PURE__ */ X({
|
|
823
839
|
name: "HbLibListBtnsAct",
|
|
824
840
|
__name: "HbListBtns",
|
|
825
|
-
props:
|
|
841
|
+
props: {
|
|
842
|
+
formItems: { default: () => [] },
|
|
843
|
+
isShowSelfFilter: { type: Boolean, default: !0 },
|
|
844
|
+
needReload: { type: Boolean, default: !0 },
|
|
845
|
+
needOpenOrClose: { type: Boolean, default: !0 }
|
|
846
|
+
},
|
|
826
847
|
emits: ["handleOpenOrClose", "handleReload"],
|
|
827
|
-
setup(
|
|
828
|
-
const
|
|
829
|
-
|
|
848
|
+
setup(e, { emit: d }) {
|
|
849
|
+
const u = d, n = O(!0), _ = () => {
|
|
850
|
+
n.value = !n.value, u("handleOpenOrClose", n.value);
|
|
830
851
|
}, m = () => {
|
|
831
|
-
|
|
852
|
+
u("handleReload");
|
|
832
853
|
};
|
|
833
|
-
return
|
|
834
|
-
}), (
|
|
835
|
-
const
|
|
836
|
-
return o(), k("section",
|
|
837
|
-
v("aside",
|
|
838
|
-
Z(
|
|
854
|
+
return Te(() => {
|
|
855
|
+
}), (p, h) => {
|
|
856
|
+
const l = j("a-tooltip");
|
|
857
|
+
return o(), k("section", Yt, [
|
|
858
|
+
v("aside", jt, [
|
|
859
|
+
Z(p.$slots, "btnsLeft", {}, void 0, !0)
|
|
839
860
|
]),
|
|
840
|
-
v("aside",
|
|
841
|
-
|
|
861
|
+
v("aside", qt, [
|
|
862
|
+
e.needReload ? (o(), B(l, {
|
|
842
863
|
key: 0,
|
|
843
|
-
title:
|
|
864
|
+
title: p.$t("hbLibComp.hbListBtnsAct.reload")
|
|
844
865
|
}, {
|
|
845
|
-
default:
|
|
866
|
+
default: b(() => [
|
|
846
867
|
v("span", {
|
|
847
868
|
class: "hb-lib-list-btns-act-svg hb-lib-list-btns-item",
|
|
848
869
|
onClick: m
|
|
849
|
-
}, [...
|
|
870
|
+
}, [...h[0] || (h[0] = [
|
|
850
871
|
v("svg", {
|
|
851
872
|
t: "1759041224819",
|
|
852
873
|
class: "icon",
|
|
@@ -866,68 +887,71 @@ const yt = {
|
|
|
866
887
|
])])
|
|
867
888
|
]),
|
|
868
889
|
_: 1
|
|
869
|
-
}, 8, ["title"])) :
|
|
870
|
-
|
|
890
|
+
}, 8, ["title"])) : R("", !0),
|
|
891
|
+
e.needOpenOrClose ? (o(), B(l, {
|
|
871
892
|
key: 1,
|
|
872
|
-
title:
|
|
893
|
+
title: n.value ? `${p.$t("hbLibComp.hbListBtnsAct.close")}` : `${p.$t("hbLibComp.hbListBtnsAct.open")}`
|
|
873
894
|
}, {
|
|
874
|
-
default:
|
|
895
|
+
default: b(() => [
|
|
875
896
|
v("span", {
|
|
876
897
|
class: "hb-lib-list-btns-act-open hb-lib-list-btns-item",
|
|
877
|
-
onClick:
|
|
898
|
+
onClick: _
|
|
878
899
|
}, [
|
|
879
|
-
|
|
900
|
+
n.value ? (o(), B(i(pt), {
|
|
880
901
|
key: 0,
|
|
881
902
|
style: { "font-size": "21px", color: "#ff5000" }
|
|
882
|
-
})) : (o(),
|
|
903
|
+
})) : (o(), B(i(mt), {
|
|
883
904
|
key: 1,
|
|
884
905
|
style: { "font-size": "21px", color: "#ff5000" }
|
|
885
906
|
}))
|
|
886
907
|
])
|
|
887
908
|
]),
|
|
888
909
|
_: 1
|
|
889
|
-
}, 8, ["title"])) :
|
|
890
|
-
Z(
|
|
910
|
+
}, 8, ["title"])) : R("", !0),
|
|
911
|
+
Z(p.$slots, "btnsRight", {}, void 0, !0)
|
|
891
912
|
])
|
|
892
913
|
]);
|
|
893
914
|
};
|
|
894
915
|
}
|
|
895
|
-
}),
|
|
896
|
-
|
|
897
|
-
type: Number,
|
|
898
|
-
default: 400
|
|
899
|
-
},
|
|
900
|
-
tabelData: {
|
|
916
|
+
}), Jt = /* @__PURE__ */ oe(Wt, [["__scopeId", "data-v-0ab77a2c"]]), Gt = {
|
|
917
|
+
formItems: {
|
|
901
918
|
type: Array,
|
|
902
919
|
default: () => []
|
|
903
920
|
},
|
|
904
|
-
|
|
905
|
-
|
|
921
|
+
// 是否展示自定义筛选
|
|
922
|
+
isShowSelfFilter: {
|
|
923
|
+
type: Boolean,
|
|
924
|
+
default: !0
|
|
906
925
|
},
|
|
907
|
-
|
|
908
|
-
type:
|
|
926
|
+
needReload: {
|
|
927
|
+
type: Boolean,
|
|
928
|
+
default: !0
|
|
929
|
+
},
|
|
930
|
+
needOpenOrClose: {
|
|
931
|
+
type: Boolean,
|
|
932
|
+
default: !0
|
|
909
933
|
}
|
|
910
|
-
}, Jt = (
|
|
911
|
-
const { formRef:
|
|
912
|
-
let m = null,
|
|
913
|
-
const
|
|
914
|
-
|
|
934
|
+
}, Qt = le(Jt), Zt = (e = {}) => {
|
|
935
|
+
const { formRef: d, offsetBottom: u = 50, minHeight: n = 300 } = e, _ = O(0);
|
|
936
|
+
let m = null, p = null, h = null, l = null, s = null;
|
|
937
|
+
const r = () => {
|
|
938
|
+
s && clearTimeout(s), s = setTimeout(() => {
|
|
915
939
|
requestAnimationFrame(() => {
|
|
916
|
-
|
|
940
|
+
he(() => {
|
|
917
941
|
const E = document.querySelector(".ant-table"), V = document.querySelector(".ant-pagination");
|
|
918
942
|
if (E) {
|
|
919
|
-
const
|
|
920
|
-
let
|
|
921
|
-
|
|
943
|
+
const H = E.getBoundingClientRect().top, F = window.innerHeight, a = (V ? V.offsetHeight + 20 : 40) + u;
|
|
944
|
+
let f = F - H - a;
|
|
945
|
+
f < n && (f = n), _.value = f;
|
|
922
946
|
}
|
|
923
947
|
});
|
|
924
948
|
});
|
|
925
949
|
}, 100);
|
|
926
|
-
},
|
|
950
|
+
}, M = () => {
|
|
927
951
|
const E = document.querySelector(".ant-pagination");
|
|
928
952
|
if (E) {
|
|
929
953
|
const V = new MutationObserver(() => {
|
|
930
|
-
|
|
954
|
+
r();
|
|
931
955
|
});
|
|
932
956
|
return V.observe(E, {
|
|
933
957
|
childList: !0,
|
|
@@ -937,101 +961,121 @@ const yt = {
|
|
|
937
961
|
}), V;
|
|
938
962
|
}
|
|
939
963
|
return null;
|
|
940
|
-
},
|
|
964
|
+
}, w = () => {
|
|
941
965
|
const E = document.querySelector(".hb-lib-list-page-form-box");
|
|
942
966
|
E && (m = new ResizeObserver(() => {
|
|
943
|
-
document.querySelectorAll(".ant-tooltip").forEach((
|
|
944
|
-
|
|
945
|
-
}),
|
|
967
|
+
document.querySelectorAll(".ant-tooltip").forEach((H) => {
|
|
968
|
+
H.style.display = "none";
|
|
969
|
+
}), r();
|
|
946
970
|
}), m.observe(E));
|
|
947
|
-
},
|
|
971
|
+
}, N = () => {
|
|
948
972
|
const E = document.querySelector(".hb-lib-list-page-form-box");
|
|
949
|
-
E && (
|
|
973
|
+
E && (h = new MutationObserver(() => {
|
|
950
974
|
setTimeout(() => {
|
|
951
|
-
|
|
975
|
+
r();
|
|
952
976
|
}, 100);
|
|
953
|
-
}),
|
|
977
|
+
}), h.observe(E, {
|
|
954
978
|
childList: !0,
|
|
955
979
|
subtree: !0,
|
|
956
980
|
attributes: !0,
|
|
957
981
|
attributeFilter: ["style", "class"]
|
|
958
982
|
}));
|
|
959
983
|
}, S = () => {
|
|
960
|
-
|
|
961
|
-
|
|
984
|
+
l && clearTimeout(l), l = setTimeout(() => {
|
|
985
|
+
r();
|
|
962
986
|
}, 100);
|
|
963
|
-
},
|
|
964
|
-
window.addEventListener("resize", S),
|
|
965
|
-
|
|
987
|
+
}, x = () => {
|
|
988
|
+
window.addEventListener("resize", S), he(() => {
|
|
989
|
+
w(), N(), p = M();
|
|
966
990
|
});
|
|
967
991
|
}, U = () => {
|
|
968
|
-
window.removeEventListener("resize", S), m && m.disconnect(),
|
|
992
|
+
window.removeEventListener("resize", S), m && m.disconnect(), h && h.disconnect(), p && p.disconnect(), l && clearTimeout(l), s && clearTimeout(s);
|
|
969
993
|
};
|
|
970
|
-
return
|
|
971
|
-
() =>
|
|
994
|
+
return d && se(
|
|
995
|
+
() => d,
|
|
972
996
|
() => {
|
|
973
997
|
setTimeout(() => {
|
|
974
|
-
|
|
998
|
+
r();
|
|
975
999
|
}, 200);
|
|
976
1000
|
},
|
|
977
1001
|
{ deep: !0 }
|
|
978
|
-
),
|
|
979
|
-
|
|
980
|
-
}),
|
|
1002
|
+
), Te(() => {
|
|
1003
|
+
r(), x();
|
|
1004
|
+
}), nt(() => {
|
|
981
1005
|
U();
|
|
982
1006
|
}), {
|
|
983
|
-
tableHeight:
|
|
984
|
-
calTableHeight:
|
|
1007
|
+
tableHeight: _,
|
|
1008
|
+
calTableHeight: r
|
|
985
1009
|
};
|
|
986
|
-
},
|
|
1010
|
+
}, Xt = /* @__PURE__ */ X({
|
|
987
1011
|
name: "HbLibListPageContainer",
|
|
988
1012
|
__name: "HbListPageContainer",
|
|
989
|
-
props:
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
1013
|
+
props: {
|
|
1014
|
+
tableHeight: { default: 400 },
|
|
1015
|
+
tabelData: { default: () => [] },
|
|
1016
|
+
offsetBottom: {},
|
|
1017
|
+
minHeight: {}
|
|
1018
|
+
},
|
|
1019
|
+
setup(e) {
|
|
1020
|
+
const d = e, u = st("PageContainerRef"), { calTableHeight: n, tableHeight: _ } = Zt({
|
|
1021
|
+
offsetBottom: d.offsetBottom || 20,
|
|
993
1022
|
// 底部预留空间
|
|
994
|
-
minHeight:
|
|
1023
|
+
minHeight: d.minHeight || 300
|
|
995
1024
|
// table最小高度 请勿随便修改!!
|
|
996
|
-
}), m = W(() =>
|
|
997
|
-
return
|
|
998
|
-
PageContainerRef:
|
|
1025
|
+
}), m = W(() => _.value);
|
|
1026
|
+
return it("HB_LIST_PAGE_CONTAINER", {
|
|
1027
|
+
PageContainerRef: u,
|
|
999
1028
|
// 通过函数访问,
|
|
1000
|
-
tableHeight:
|
|
1001
|
-
calTableHeight:
|
|
1002
|
-
}), (
|
|
1029
|
+
tableHeight: _,
|
|
1030
|
+
calTableHeight: n
|
|
1031
|
+
}), (p, h) => (o(), k("section", {
|
|
1003
1032
|
class: "hb-lib-list-page-container",
|
|
1004
1033
|
ref_key: "PageContainerRef",
|
|
1005
|
-
ref:
|
|
1034
|
+
ref: u
|
|
1006
1035
|
}, [
|
|
1007
|
-
Z(
|
|
1036
|
+
Z(p.$slots, "header"),
|
|
1008
1037
|
v("section", {
|
|
1009
1038
|
class: "list-page-box",
|
|
1010
|
-
style:
|
|
1039
|
+
style: be({
|
|
1011
1040
|
"--hb-list-table-height": m.value - 20 + "px",
|
|
1012
|
-
"--hb-list-ttable-height":
|
|
1041
|
+
"--hb-list-ttable-height": e.tabelData.length ? "" : m.value - 20 + "px"
|
|
1013
1042
|
})
|
|
1014
1043
|
}, [
|
|
1015
|
-
Z(
|
|
1044
|
+
Z(p.$slots, "default")
|
|
1016
1045
|
], 4)
|
|
1017
1046
|
], 512));
|
|
1018
1047
|
}
|
|
1019
|
-
}),
|
|
1048
|
+
}), el = {
|
|
1049
|
+
tableHeight: {
|
|
1050
|
+
type: Number,
|
|
1051
|
+
default: 400
|
|
1052
|
+
},
|
|
1053
|
+
tabelData: {
|
|
1054
|
+
type: Array,
|
|
1055
|
+
default: () => []
|
|
1056
|
+
},
|
|
1057
|
+
offsetBottom: {
|
|
1058
|
+
type: Number
|
|
1059
|
+
},
|
|
1060
|
+
minHeight: {
|
|
1061
|
+
type: Number
|
|
1062
|
+
}
|
|
1063
|
+
}, tl = le(Xt), ll = { style: { "font-weight": "500" } }, al = {
|
|
1020
1064
|
key: 0,
|
|
1021
1065
|
class: "hb-lib-search-tag__description"
|
|
1022
|
-
},
|
|
1066
|
+
}, ol = { class: "hb-lib-selector-dropdown" }, nl = { class: "hb-lib-selector-search" }, sl = { class: "hb-lib-selector-list" }, il = ["onClick"], rl = { class: "hb-lib-option-content" }, cl = { class: "hb-lib-option-label" }, dl = {
|
|
1023
1067
|
key: 0,
|
|
1024
1068
|
class: "hb-lib-selector-empty"
|
|
1025
|
-
},
|
|
1069
|
+
}, ul = {
|
|
1026
1070
|
key: 1,
|
|
1027
1071
|
class: "hb-lib-selector-footer"
|
|
1028
|
-
},
|
|
1072
|
+
}, hl = { class: "hb-lib-footer-buttons" }, bl = {
|
|
1029
1073
|
key: 2,
|
|
1030
1074
|
class: "hb-lib-selector-footer"
|
|
1031
|
-
},
|
|
1075
|
+
}, fl = { class: "hb-lib-footer-buttons" }, pl = /* @__PURE__ */ X({
|
|
1032
1076
|
name: "HbLibListMultiSelect",
|
|
1033
1077
|
__name: "HbListMultiSelect",
|
|
1034
|
-
props: /* @__PURE__ */
|
|
1078
|
+
props: /* @__PURE__ */ He({
|
|
1035
1079
|
title: { default: "请选择" },
|
|
1036
1080
|
placeholder: { default: "点击选择" },
|
|
1037
1081
|
searchPlaceholder: { default: "搜索选项" },
|
|
@@ -1048,183 +1092,183 @@ const yt = {
|
|
|
1048
1092
|
value: {},
|
|
1049
1093
|
valueModifiers: {}
|
|
1050
1094
|
}),
|
|
1051
|
-
emits: /* @__PURE__ */
|
|
1052
|
-
setup(
|
|
1053
|
-
const
|
|
1054
|
-
if (
|
|
1055
|
-
const
|
|
1056
|
-
return
|
|
1057
|
-
}),
|
|
1058
|
-
if (
|
|
1059
|
-
const
|
|
1060
|
-
return
|
|
1095
|
+
emits: /* @__PURE__ */ He(["update:value", "update:searchValue", "change", "confirm", "cancel", "search"], ["update:value"]),
|
|
1096
|
+
setup(e, { emit: d }) {
|
|
1097
|
+
const u = e, n = d, _ = rt(e, "value"), m = O(!1), p = O(""), h = O([]), l = O(), s = W(() => {
|
|
1098
|
+
if (u.remoteSearch || !p.value) return u.options;
|
|
1099
|
+
const t = p.value.toLowerCase();
|
|
1100
|
+
return u.options.filter((a) => a.label.toLowerCase().includes(t) || a.description?.toLowerCase().includes(t));
|
|
1101
|
+
}), r = W(() => u.prefix ? `${u.prefix.length * 14 + 8}px` : "0px"), M = W(() => s.value.length === 0 ? !1 : s.value.every((t) => h.value.includes(t.value))), w = W(() => {
|
|
1102
|
+
if (s.value.length === 0) return !1;
|
|
1103
|
+
const t = s.value.filter((a) => h.value.includes(a.value)).length;
|
|
1104
|
+
return t > 0 && t < s.value.length;
|
|
1061
1105
|
});
|
|
1062
|
-
|
|
1063
|
-
() =>
|
|
1064
|
-
(
|
|
1065
|
-
|
|
1106
|
+
se(
|
|
1107
|
+
() => _.value,
|
|
1108
|
+
(t) => {
|
|
1109
|
+
t ? h.value = Array.isArray(t) ? [...t] : [t] : h.value = [];
|
|
1066
1110
|
},
|
|
1067
1111
|
{ immediate: !0 }
|
|
1068
|
-
),
|
|
1069
|
-
() =>
|
|
1070
|
-
(
|
|
1071
|
-
|
|
1112
|
+
), se(
|
|
1113
|
+
() => u.searchValue,
|
|
1114
|
+
(t) => {
|
|
1115
|
+
u.remoteSearch && t !== void 0 && (p.value = t);
|
|
1072
1116
|
},
|
|
1073
1117
|
{ immediate: !0 }
|
|
1074
1118
|
);
|
|
1075
|
-
const
|
|
1076
|
-
|
|
1077
|
-
if (
|
|
1078
|
-
const
|
|
1079
|
-
|
|
1119
|
+
const N = (t) => {
|
|
1120
|
+
t && (m.value = t, S.value = [...h.value], p.value = "", setTimeout(() => {
|
|
1121
|
+
if (l.value) {
|
|
1122
|
+
const a = l.value.input || l.value.$el?.querySelector("input");
|
|
1123
|
+
a && a.focus();
|
|
1080
1124
|
}
|
|
1081
1125
|
}, 100));
|
|
1082
|
-
}, S = O([]),
|
|
1083
|
-
|
|
1126
|
+
}, S = O([]), x = () => {
|
|
1127
|
+
h.value = [...S.value], m.value = !1, n("cancel");
|
|
1084
1128
|
}, U = O([]), E = () => {
|
|
1085
|
-
const
|
|
1086
|
-
U.value =
|
|
1087
|
-
}, V =
|
|
1088
|
-
const
|
|
1089
|
-
|
|
1090
|
-
}, 300),
|
|
1091
|
-
if (
|
|
1092
|
-
const
|
|
1093
|
-
|
|
1129
|
+
const t = u.multiple ? h.value : h.value[0] || "", a = u.options.filter((f) => h.value.includes(f.value));
|
|
1130
|
+
U.value = a, console.log(t, a), S.value = [...h.value], _.value = t, n("update:value", t), n("change", t, a), n("confirm", t, a), m.value = !1;
|
|
1131
|
+
}, V = kt((t) => {
|
|
1132
|
+
const a = t !== void 0 ? t : p.value;
|
|
1133
|
+
u.remoteSearch && (n("search", a), n("update:searchValue", a));
|
|
1134
|
+
}, 300), H = (t) => {
|
|
1135
|
+
if (u.multiple) {
|
|
1136
|
+
const a = new Set(h.value);
|
|
1137
|
+
a.has(t.value) ? a.delete(t.value) : a.add(t.value), h.value = Array.from(a);
|
|
1094
1138
|
} else
|
|
1095
|
-
|
|
1096
|
-
},
|
|
1097
|
-
if (
|
|
1098
|
-
const
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
}),
|
|
1139
|
+
h.value = [t.value], E();
|
|
1140
|
+
}, F = (t) => {
|
|
1141
|
+
if (t.target.checked) {
|
|
1142
|
+
const f = new Set(h.value);
|
|
1143
|
+
s.value.forEach((y) => {
|
|
1144
|
+
f.add(y.value);
|
|
1145
|
+
}), h.value = Array.from(f);
|
|
1102
1146
|
} else {
|
|
1103
|
-
const
|
|
1104
|
-
|
|
1147
|
+
const f = new Set(s.value.map((y) => y.value));
|
|
1148
|
+
h.value = h.value.filter((y) => !f.has(y));
|
|
1105
1149
|
}
|
|
1106
1150
|
};
|
|
1107
|
-
return (
|
|
1108
|
-
const
|
|
1109
|
-
return o(), k("div",
|
|
1151
|
+
return (t, a) => {
|
|
1152
|
+
const f = j("a-tag"), y = j("a-input"), c = j("a-checkbox"), K = j("a-radio"), P = j("a-button"), te = j("a-select");
|
|
1153
|
+
return o(), k("div", ee({
|
|
1110
1154
|
class: "hb-lib-selector-wrapper",
|
|
1111
|
-
style: { "--prefix-width":
|
|
1112
|
-
},
|
|
1113
|
-
|
|
1114
|
-
value:
|
|
1115
|
-
"onUpdate:value":
|
|
1116
|
-
mode:
|
|
1117
|
-
placeholder:
|
|
1155
|
+
style: { "--prefix-width": r.value }
|
|
1156
|
+
}, t.$attrs), [
|
|
1157
|
+
T(te, {
|
|
1158
|
+
value: _.value,
|
|
1159
|
+
"onUpdate:value": a[5] || (a[5] = (G) => _.value = G),
|
|
1160
|
+
mode: e.multiple ? "multiple" : void 0,
|
|
1161
|
+
placeholder: e.placeholder,
|
|
1118
1162
|
"show-search": !0,
|
|
1119
1163
|
"filter-option": !1,
|
|
1120
1164
|
open: m.value,
|
|
1121
1165
|
allowClear: "",
|
|
1122
|
-
maxTagCount:
|
|
1123
|
-
options:
|
|
1124
|
-
onDropdownVisibleChange:
|
|
1125
|
-
onSearch:
|
|
1126
|
-
"max-tag-text-length":
|
|
1127
|
-
class: z({ "has-prefix":
|
|
1128
|
-
"data-prefix":
|
|
1166
|
+
maxTagCount: e.maxTagCount,
|
|
1167
|
+
options: s.value,
|
|
1168
|
+
onDropdownVisibleChange: N,
|
|
1169
|
+
onSearch: i(V),
|
|
1170
|
+
"max-tag-text-length": e.tagTextLength,
|
|
1171
|
+
class: z({ "has-prefix": e.prefix }),
|
|
1172
|
+
"data-prefix": e.prefix,
|
|
1129
1173
|
style: { width: "100%" }
|
|
1130
1174
|
}, {
|
|
1131
|
-
tagRender:
|
|
1132
|
-
|
|
1175
|
+
tagRender: b(({ value: G, label: q, closable: C, option: D }) => [
|
|
1176
|
+
T(f, {
|
|
1133
1177
|
class: "hb-lib-search-tag",
|
|
1134
|
-
onClick:
|
|
1178
|
+
onClick: a[0] || (a[0] = () => N(!0))
|
|
1135
1179
|
}, {
|
|
1136
|
-
default:
|
|
1137
|
-
v("span",
|
|
1138
|
-
D?.description ? (o(), k("span",
|
|
1180
|
+
default: b(() => [
|
|
1181
|
+
v("span", ll, L(q), 1),
|
|
1182
|
+
D?.description ? (o(), k("span", al, " (" + L(D.description) + ") ", 1)) : R("", !0)
|
|
1139
1183
|
]),
|
|
1140
1184
|
_: 2
|
|
1141
1185
|
}, 1024)
|
|
1142
1186
|
]),
|
|
1143
|
-
dropdownRender:
|
|
1144
|
-
v("div",
|
|
1145
|
-
v("div",
|
|
1146
|
-
|
|
1187
|
+
dropdownRender: b(({ menuNode: G }) => [
|
|
1188
|
+
v("div", ol, [
|
|
1189
|
+
v("div", nl, [
|
|
1190
|
+
T(y, {
|
|
1147
1191
|
ref_key: "searchInputRef",
|
|
1148
|
-
ref:
|
|
1192
|
+
ref: l,
|
|
1149
1193
|
class: "hb-lib-selector-search-input",
|
|
1150
|
-
value:
|
|
1151
|
-
"onUpdate:value":
|
|
1194
|
+
value: p.value,
|
|
1195
|
+
"onUpdate:value": a[1] || (a[1] = (q) => p.value = q),
|
|
1152
1196
|
placeholder: "请输入关键词搜索",
|
|
1153
1197
|
"allow-clear": "",
|
|
1154
|
-
onInput:
|
|
1198
|
+
onInput: a[2] || (a[2] = (q) => i(V)(q.target.value))
|
|
1155
1199
|
}, {
|
|
1156
|
-
prefix:
|
|
1157
|
-
|
|
1200
|
+
prefix: b(() => [
|
|
1201
|
+
T(i($e))
|
|
1158
1202
|
]),
|
|
1159
1203
|
_: 1
|
|
1160
1204
|
}, 8, ["value"])
|
|
1161
1205
|
]),
|
|
1162
|
-
v("div",
|
|
1163
|
-
(o(!0), k(J, null,
|
|
1164
|
-
key:
|
|
1165
|
-
class: z(["hb-lib-selector-option", { selected:
|
|
1166
|
-
onClick: () =>
|
|
1206
|
+
v("div", sl, [
|
|
1207
|
+
(o(!0), k(J, null, ae(s.value, (q) => (o(), k("div", {
|
|
1208
|
+
key: q.value,
|
|
1209
|
+
class: z(["hb-lib-selector-option", { selected: h.value.includes(q.value) }]),
|
|
1210
|
+
onClick: () => H(q)
|
|
1167
1211
|
}, [
|
|
1168
|
-
|
|
1212
|
+
e.multiple ? (o(), B(c, {
|
|
1169
1213
|
key: 0,
|
|
1170
|
-
checked:
|
|
1171
|
-
onChange: () =>
|
|
1172
|
-
onClick:
|
|
1214
|
+
checked: h.value.includes(q.value),
|
|
1215
|
+
onChange: () => H(q),
|
|
1216
|
+
onClick: a[3] || (a[3] = _e(() => {
|
|
1173
1217
|
}, ["stop"]))
|
|
1174
|
-
}, null, 8, ["checked", "onChange"])) : (o(),
|
|
1218
|
+
}, null, 8, ["checked", "onChange"])) : (o(), B(K, {
|
|
1175
1219
|
key: 1,
|
|
1176
|
-
checked:
|
|
1177
|
-
onChange: () =>
|
|
1178
|
-
onClick:
|
|
1220
|
+
checked: h.value.includes(q.value),
|
|
1221
|
+
onChange: () => H(q),
|
|
1222
|
+
onClick: a[4] || (a[4] = _e(() => {
|
|
1179
1223
|
}, ["stop"]))
|
|
1180
1224
|
}, null, 8, ["checked", "onChange"])),
|
|
1181
|
-
v("div",
|
|
1182
|
-
v("div",
|
|
1225
|
+
v("div", rl, [
|
|
1226
|
+
v("div", cl, L(q.label), 1)
|
|
1183
1227
|
])
|
|
1184
|
-
], 10,
|
|
1228
|
+
], 10, il))), 128))
|
|
1185
1229
|
]),
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
checked:
|
|
1190
|
-
indeterminate:
|
|
1191
|
-
onChange:
|
|
1230
|
+
s.value.length === 0 ? (o(), k("div", dl, L(t.$t("hbLibComp.hbFormItemFilterModal.noData")), 1)) : R("", !0),
|
|
1231
|
+
e.multiple ? (o(), k("div", ul, [
|
|
1232
|
+
T(c, {
|
|
1233
|
+
checked: M.value,
|
|
1234
|
+
indeterminate: w.value,
|
|
1235
|
+
onChange: F
|
|
1192
1236
|
}, {
|
|
1193
|
-
default:
|
|
1194
|
-
I(L(
|
|
1237
|
+
default: b(() => [
|
|
1238
|
+
I(L(t.$t("hbLibComp.hbFormSelectFilter.allSelect")), 1)
|
|
1195
1239
|
]),
|
|
1196
1240
|
_: 1
|
|
1197
1241
|
}, 8, ["checked", "indeterminate"]),
|
|
1198
|
-
v("div",
|
|
1199
|
-
|
|
1242
|
+
v("div", hl, [
|
|
1243
|
+
T(P, {
|
|
1200
1244
|
size: "small",
|
|
1201
|
-
onClick:
|
|
1245
|
+
onClick: x
|
|
1202
1246
|
}, {
|
|
1203
|
-
default:
|
|
1204
|
-
I(L(
|
|
1247
|
+
default: b(() => [
|
|
1248
|
+
I(L(t.$t("hbLibComp.hbFormItemFilterModal.cancel")), 1)
|
|
1205
1249
|
]),
|
|
1206
1250
|
_: 1
|
|
1207
1251
|
}),
|
|
1208
|
-
|
|
1252
|
+
T(P, {
|
|
1209
1253
|
type: "primary",
|
|
1210
1254
|
size: "small",
|
|
1211
1255
|
onClick: E
|
|
1212
1256
|
}, {
|
|
1213
|
-
default:
|
|
1214
|
-
I(L(
|
|
1257
|
+
default: b(() => [
|
|
1258
|
+
I(L(t.$t("hbLibComp.hbFormItemFilterModal.confirm")), 1)
|
|
1215
1259
|
]),
|
|
1216
1260
|
_: 1
|
|
1217
1261
|
})
|
|
1218
1262
|
])
|
|
1219
|
-
])) : (o(), k("div",
|
|
1220
|
-
|
|
1221
|
-
v("div",
|
|
1222
|
-
|
|
1263
|
+
])) : (o(), k("div", bl, [
|
|
1264
|
+
a[6] || (a[6] = v("div", null, null, -1)),
|
|
1265
|
+
v("div", fl, [
|
|
1266
|
+
T(P, {
|
|
1223
1267
|
size: "small",
|
|
1224
|
-
onClick:
|
|
1268
|
+
onClick: x
|
|
1225
1269
|
}, {
|
|
1226
|
-
default:
|
|
1227
|
-
I(L(
|
|
1270
|
+
default: b(() => [
|
|
1271
|
+
I(L(t.$t("hbLibComp.hbFormSelectFilter.close")), 1)
|
|
1228
1272
|
]),
|
|
1229
1273
|
_: 1
|
|
1230
1274
|
})
|
|
@@ -1237,188 +1281,166 @@ const yt = {
|
|
|
1237
1281
|
], 16);
|
|
1238
1282
|
};
|
|
1239
1283
|
}
|
|
1240
|
-
}),
|
|
1241
|
-
|
|
1242
|
-
return
|
|
1284
|
+
}), Fe = /* @__PURE__ */ oe(pl, [["__scopeId", "data-v-11422adb"]]);
|
|
1285
|
+
Fe.install = function(e) {
|
|
1286
|
+
return e.component("HbFormSelectFilter", Fe), e;
|
|
1243
1287
|
};
|
|
1244
|
-
const
|
|
1245
|
-
modelTitle: {
|
|
1246
|
-
type: String,
|
|
1247
|
-
default: "搜索弹窗"
|
|
1248
|
-
},
|
|
1249
|
-
modalWidth: {
|
|
1250
|
-
type: Number,
|
|
1251
|
-
default: 800
|
|
1252
|
-
},
|
|
1253
|
-
tableHeight: {
|
|
1254
|
-
type: Number,
|
|
1255
|
-
default: 500
|
|
1256
|
-
},
|
|
1257
|
-
tableColumn: {
|
|
1258
|
-
type: Array,
|
|
1259
|
-
default: () => [],
|
|
1260
|
-
required: !0
|
|
1261
|
-
},
|
|
1262
|
-
tableData: {
|
|
1263
|
-
type: Array,
|
|
1264
|
-
default: () => []
|
|
1265
|
-
},
|
|
1266
|
-
tableKey: {
|
|
1267
|
-
type: String,
|
|
1268
|
-
default: "id"
|
|
1269
|
-
},
|
|
1270
|
-
labelKey: {
|
|
1271
|
-
type: String,
|
|
1272
|
-
default: "label"
|
|
1273
|
-
}
|
|
1274
|
-
}, hl = { class: "hb-lib-form-item-filter-modal-search" }, pl = { class: "hb-lib-form-item-filter-modal-buttons" }, fl = { key: 0 }, ml = /* @__PURE__ */ X({
|
|
1288
|
+
const ml = { class: "hb-lib-form-item-filter-modal-search" }, vl = { class: "hb-lib-form-item-filter-modal-buttons" }, gl = { key: 0 }, yl = /* @__PURE__ */ X({
|
|
1275
1289
|
name: "HbLibMutilpleSelectModal",
|
|
1276
1290
|
__name: "HbMutilpleSelectModal",
|
|
1277
|
-
props:
|
|
1291
|
+
props: {
|
|
1292
|
+
modelTitle: { default: "搜索弹窗" },
|
|
1293
|
+
modalWidth: { default: 800 },
|
|
1294
|
+
tableHeight: { default: 500 },
|
|
1295
|
+
tableColumn: { default: () => [] },
|
|
1296
|
+
tableData: { default: () => [] },
|
|
1297
|
+
tableKey: { default: "id" },
|
|
1298
|
+
labelKey: { default: "label" }
|
|
1299
|
+
},
|
|
1278
1300
|
emits: ["handleConfirm", "handleCancel"],
|
|
1279
|
-
setup(
|
|
1280
|
-
const
|
|
1301
|
+
setup(e, { expose: d, emit: u }) {
|
|
1302
|
+
const n = e, _ = u, m = O(!1), p = O(""), h = O(), l = O(), s = O([]), r = O([]), M = O(), w = Ge({
|
|
1281
1303
|
searchText: "",
|
|
1282
1304
|
searchedColumn: ""
|
|
1283
|
-
}),
|
|
1284
|
-
|
|
1285
|
-
|
|
1305
|
+
}), N = W(() => n.tableData.map((f) => (f.id = f.id || Math.random(), f))), S = W(() => n.tableColumn.map((f) => (f.customFilterDropdown && (f.onFilter = (y, c) => c[f.dataIndex].toString().toLowerCase().includes(y.toLowerCase()), f.onFilterDropdownVisibleChange = (y) => {
|
|
1306
|
+
y && setTimeout(() => {
|
|
1307
|
+
h.value?.focus();
|
|
1286
1308
|
}, 100);
|
|
1287
|
-
}), { ...
|
|
1288
|
-
let
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
}),
|
|
1309
|
+
}), { ...f }))), x = () => {
|
|
1310
|
+
let f = "";
|
|
1311
|
+
r.value.forEach((y) => {
|
|
1312
|
+
f = f + y[n.labelKey] + ",";
|
|
1313
|
+
}), p.value = f.substring(0, f.length - 1), m.value = !1, _("handleConfirm", r.value);
|
|
1292
1314
|
}, U = () => {
|
|
1293
1315
|
m.value = !1;
|
|
1294
1316
|
}, E = () => {
|
|
1295
|
-
m.value = !0,
|
|
1296
|
-
const
|
|
1297
|
-
|
|
1317
|
+
m.value = !0, he(() => {
|
|
1318
|
+
const f = M.value?.$el?.querySelector(".ant-table-body");
|
|
1319
|
+
f && (f.scrollTop = 0);
|
|
1298
1320
|
});
|
|
1299
1321
|
}, V = () => {
|
|
1300
|
-
|
|
1301
|
-
},
|
|
1302
|
-
|
|
1303
|
-
},
|
|
1304
|
-
|
|
1305
|
-
},
|
|
1306
|
-
|
|
1307
|
-
},
|
|
1308
|
-
|
|
1322
|
+
s.value = [], r.value = [];
|
|
1323
|
+
}, H = () => {
|
|
1324
|
+
p.value = "", V();
|
|
1325
|
+
}, F = (f, y, c) => {
|
|
1326
|
+
y(), w.searchText = f[0], w.searchedColumn = c;
|
|
1327
|
+
}, t = (f, y) => {
|
|
1328
|
+
f({ confirm: !0 }), w.searchText = "", y();
|
|
1329
|
+
}, a = (f, y) => {
|
|
1330
|
+
s.value = f, r.value = y;
|
|
1309
1331
|
};
|
|
1310
|
-
return
|
|
1311
|
-
resetInputVal:
|
|
1312
|
-
}), (
|
|
1313
|
-
const
|
|
1332
|
+
return d({
|
|
1333
|
+
resetInputVal: H
|
|
1334
|
+
}), (f, y) => {
|
|
1335
|
+
const c = j("a-input"), K = j("a-button"), P = j("a-table"), te = j("a-modal");
|
|
1314
1336
|
return o(), k("div", {
|
|
1315
1337
|
class: "hb-lib-multipleSelectModal-box",
|
|
1316
1338
|
ref_key: "hbMultipSelectModalRef",
|
|
1317
|
-
ref:
|
|
1339
|
+
ref: l
|
|
1318
1340
|
}, [
|
|
1319
|
-
|
|
1341
|
+
T(c, {
|
|
1320
1342
|
readonly: "",
|
|
1321
1343
|
onClick: E,
|
|
1322
|
-
value:
|
|
1323
|
-
"onUpdate:value":
|
|
1324
|
-
placeholder:
|
|
1344
|
+
value: p.value,
|
|
1345
|
+
"onUpdate:value": y[0] || (y[0] = (G) => p.value = G),
|
|
1346
|
+
placeholder: f.$t("hbLibComp.hbMultiSelectModal.pleaseSelect")
|
|
1325
1347
|
}, {
|
|
1326
|
-
addonAfter:
|
|
1327
|
-
|
|
1348
|
+
addonAfter: b(() => [
|
|
1349
|
+
T(i(vt), { onClick: E })
|
|
1328
1350
|
]),
|
|
1329
1351
|
_: 1
|
|
1330
1352
|
}, 8, ["value", "placeholder"]),
|
|
1331
|
-
|
|
1353
|
+
T(te, {
|
|
1332
1354
|
visible: m.value,
|
|
1333
|
-
"onUpdate:visible":
|
|
1334
|
-
title:
|
|
1335
|
-
width:
|
|
1355
|
+
"onUpdate:visible": y[1] || (y[1] = (G) => m.value = G),
|
|
1356
|
+
title: e.modelTitle,
|
|
1357
|
+
width: e.modalWidth,
|
|
1336
1358
|
class: "hb-lib-multipleSelectModal-modal"
|
|
1337
1359
|
}, {
|
|
1338
|
-
footer:
|
|
1339
|
-
|
|
1340
|
-
default:
|
|
1341
|
-
I(L(
|
|
1360
|
+
footer: b(() => [
|
|
1361
|
+
T(K, { onClick: V }, {
|
|
1362
|
+
default: b(() => [
|
|
1363
|
+
I(L(f.$t("hbLibComp.hbListPageAct.reset")), 1)
|
|
1342
1364
|
]),
|
|
1343
1365
|
_: 1
|
|
1344
1366
|
}),
|
|
1345
|
-
|
|
1346
|
-
default:
|
|
1347
|
-
I(L(
|
|
1367
|
+
T(K, { onClick: U }, {
|
|
1368
|
+
default: b(() => [
|
|
1369
|
+
I(L(f.$t("hbLibComp.hbFormItemFilterModal.cancel")), 1)
|
|
1348
1370
|
]),
|
|
1349
1371
|
_: 1
|
|
1350
1372
|
}),
|
|
1351
|
-
|
|
1373
|
+
T(K, {
|
|
1352
1374
|
type: "primary",
|
|
1353
|
-
onClick:
|
|
1375
|
+
onClick: x
|
|
1354
1376
|
}, {
|
|
1355
|
-
default:
|
|
1356
|
-
I(L(
|
|
1377
|
+
default: b(() => [
|
|
1378
|
+
I(L(f.$t("hbLibComp.hbFormItemFilterModal.confirm")), 1)
|
|
1357
1379
|
]),
|
|
1358
1380
|
_: 1
|
|
1359
1381
|
})
|
|
1360
1382
|
]),
|
|
1361
|
-
default:
|
|
1362
|
-
|
|
1383
|
+
default: b(() => [
|
|
1384
|
+
T(P, {
|
|
1363
1385
|
ref_key: "tableRef",
|
|
1364
|
-
ref:
|
|
1386
|
+
ref: M,
|
|
1365
1387
|
columns: S.value,
|
|
1366
|
-
dataSource:
|
|
1367
|
-
rowSelection: { selectedRowKeys:
|
|
1368
|
-
rowKey: (G) => G[
|
|
1369
|
-
scroll: { y:
|
|
1388
|
+
dataSource: N.value,
|
|
1389
|
+
rowSelection: { selectedRowKeys: s.value, onChange: a },
|
|
1390
|
+
rowKey: (G) => G[e.tableKey],
|
|
1391
|
+
scroll: { y: e.tableHeight }
|
|
1370
1392
|
}, {
|
|
1371
|
-
customFilterDropdown:
|
|
1372
|
-
v("div",
|
|
1373
|
-
|
|
1393
|
+
customFilterDropdown: b(({ setSelectedKeys: G, selectedKeys: q, confirm: C, clearFilters: D, column: g }) => [
|
|
1394
|
+
v("div", ml, [
|
|
1395
|
+
T(c, {
|
|
1374
1396
|
ref_key: "searchInput",
|
|
1375
|
-
ref:
|
|
1397
|
+
ref: h,
|
|
1376
1398
|
placeholder: `请输入${g.title}`,
|
|
1377
|
-
value:
|
|
1399
|
+
value: q[0],
|
|
1378
1400
|
class: "hb-lib-form-item-filter-modal-search-input",
|
|
1379
1401
|
onChange: (Y) => G(Y.target.value ? [Y.target.value] : []),
|
|
1380
|
-
onPressEnter: (Y) =>
|
|
1402
|
+
onPressEnter: (Y) => F(q, C, g.dataIndex)
|
|
1381
1403
|
}, null, 8, ["placeholder", "value", "onChange", "onPressEnter"]),
|
|
1382
|
-
v("section",
|
|
1383
|
-
|
|
1404
|
+
v("section", vl, [
|
|
1405
|
+
T(K, {
|
|
1384
1406
|
class: "hb-lib-form-item-filter-modal-button",
|
|
1385
1407
|
type: "ghost",
|
|
1386
|
-
onClick: (Y) =>
|
|
1408
|
+
onClick: (Y) => t(D, C)
|
|
1387
1409
|
}, {
|
|
1388
|
-
default:
|
|
1389
|
-
I(L(
|
|
1410
|
+
default: b(() => [
|
|
1411
|
+
I(L(f.$t("hbLibComp.hbListPageAct.reset")), 1)
|
|
1390
1412
|
]),
|
|
1391
1413
|
_: 1
|
|
1392
1414
|
}, 8, ["onClick"]),
|
|
1393
|
-
|
|
1415
|
+
T(K, {
|
|
1394
1416
|
type: "primary",
|
|
1395
1417
|
class: "hb-lib-form-item-filter-modal-button-confirm",
|
|
1396
|
-
onClick: (Y) =>
|
|
1418
|
+
onClick: (Y) => F(q, C, g.dataIndex)
|
|
1397
1419
|
}, {
|
|
1398
|
-
default:
|
|
1399
|
-
I(L(
|
|
1420
|
+
default: b(() => [
|
|
1421
|
+
I(L(f.$t("hbLibComp.hbFormItemFilterModal.confirm")), 1)
|
|
1400
1422
|
]),
|
|
1401
1423
|
_: 1
|
|
1402
1424
|
}, 8, ["onClick"])
|
|
1403
1425
|
])
|
|
1404
1426
|
])
|
|
1405
1427
|
]),
|
|
1406
|
-
customFilterIcon:
|
|
1407
|
-
|
|
1408
|
-
style:
|
|
1428
|
+
customFilterIcon: b(({ filtered: G }) => [
|
|
1429
|
+
T(i($e), {
|
|
1430
|
+
style: be({ color: G ? "#108ee9" : void 0 })
|
|
1409
1431
|
}, null, 8, ["style"])
|
|
1410
1432
|
]),
|
|
1411
|
-
bodyCell:
|
|
1412
|
-
|
|
1413
|
-
(o(!0), k(J, null,
|
|
1414
|
-
|
|
1433
|
+
bodyCell: b(({ text: G, column: q }) => [
|
|
1434
|
+
w.searchText && w.searchedColumn === q.dataIndex ? (o(), k("span", gl, [
|
|
1435
|
+
(o(!0), k(J, null, ae(G.toString().split(new RegExp(`(?<=${w.searchText})|(?=${w.searchText})`, "i")), (C, D) => (o(), k(J, null, [
|
|
1436
|
+
C.toLowerCase() === w.searchText.toLowerCase() ? (o(), k("mark", {
|
|
1415
1437
|
key: D,
|
|
1416
1438
|
class: "highlight"
|
|
1417
|
-
}, L(
|
|
1418
|
-
I(L(
|
|
1439
|
+
}, L(C), 1)) : (o(), k(J, { key: 1 }, [
|
|
1440
|
+
I(L(C), 1)
|
|
1419
1441
|
], 64))
|
|
1420
1442
|
], 64))), 256))
|
|
1421
|
-
])) :
|
|
1443
|
+
])) : R("", !0)
|
|
1422
1444
|
]),
|
|
1423
1445
|
_: 1
|
|
1424
1446
|
}, 8, ["columns", "dataSource", "rowSelection", "rowKey", "scroll"])
|
|
@@ -1428,13 +1450,43 @@ const bl = {
|
|
|
1428
1450
|
], 512);
|
|
1429
1451
|
};
|
|
1430
1452
|
}
|
|
1431
|
-
}),
|
|
1453
|
+
}), Cl = {
|
|
1454
|
+
modelTitle: {
|
|
1455
|
+
type: String,
|
|
1456
|
+
default: "搜索弹窗"
|
|
1457
|
+
},
|
|
1458
|
+
modalWidth: {
|
|
1459
|
+
type: Number,
|
|
1460
|
+
default: 800
|
|
1461
|
+
},
|
|
1462
|
+
tableHeight: {
|
|
1463
|
+
type: Number,
|
|
1464
|
+
default: 500
|
|
1465
|
+
},
|
|
1466
|
+
tableColumn: {
|
|
1467
|
+
type: Array,
|
|
1468
|
+
default: () => [],
|
|
1469
|
+
required: !0
|
|
1470
|
+
},
|
|
1471
|
+
tableData: {
|
|
1472
|
+
type: Array,
|
|
1473
|
+
default: () => []
|
|
1474
|
+
},
|
|
1475
|
+
tableKey: {
|
|
1476
|
+
type: String,
|
|
1477
|
+
default: "id"
|
|
1478
|
+
},
|
|
1479
|
+
labelKey: {
|
|
1480
|
+
type: String,
|
|
1481
|
+
default: "label"
|
|
1482
|
+
}
|
|
1483
|
+
}, Ll = le(yl), kl = { class: "hb-lib-table-act-box" }, _l = ["onClick"], Sl = {
|
|
1432
1484
|
href: "javascript:;",
|
|
1433
1485
|
class: "hb-lib-table-main-action"
|
|
1434
|
-
},
|
|
1486
|
+
}, wl = ["onClick"], Fl = {
|
|
1435
1487
|
href: "javascript:;",
|
|
1436
1488
|
class: "hb-lib-table-more-action"
|
|
1437
|
-
},
|
|
1489
|
+
}, xl = ["onClick"], Tl = { href: "javascript:;" }, $l = ["onClick"], Ml = { class: "hb-lib-table-confirm-modal-content" }, Hl = /* @__PURE__ */ X({
|
|
1438
1490
|
name: "HbLibTableAct",
|
|
1439
1491
|
__name: "HbTableAct",
|
|
1440
1492
|
props: {
|
|
@@ -1442,119 +1494,119 @@ const bl = {
|
|
|
1442
1494
|
record: {},
|
|
1443
1495
|
buttonDisplaysQuantity: {}
|
|
1444
1496
|
},
|
|
1445
|
-
setup(
|
|
1446
|
-
const
|
|
1447
|
-
|
|
1448
|
-
},
|
|
1449
|
-
|
|
1450
|
-
},
|
|
1451
|
-
if (
|
|
1497
|
+
setup(e, { expose: d }) {
|
|
1498
|
+
const u = e, { t: n } = ce(), _ = O(!1), m = O(!1), p = O(null), h = W(() => u.actions.filter((x) => x.condition !== void 0 ? x.condition : !0)), l = W(() => h.value.slice(0, u.buttonDisplaysQuantity)), s = W(() => h.value.slice(u.buttonDisplaysQuantity)), r = (x) => {
|
|
1499
|
+
x.handler && x.handler(u.record);
|
|
1500
|
+
}, M = (x) => {
|
|
1501
|
+
p.value = x, _.value = !0;
|
|
1502
|
+
}, w = () => {
|
|
1503
|
+
if (p.value) {
|
|
1452
1504
|
m.value = !0;
|
|
1453
1505
|
try {
|
|
1454
|
-
|
|
1506
|
+
r(p.value), m.value = !1, _.value = !1;
|
|
1455
1507
|
} catch {
|
|
1456
1508
|
m.value = !1;
|
|
1457
1509
|
}
|
|
1458
1510
|
}
|
|
1459
|
-
},
|
|
1460
|
-
|
|
1461
|
-
}, S = W(() =>
|
|
1462
|
-
title:
|
|
1463
|
-
content:
|
|
1511
|
+
}, N = () => {
|
|
1512
|
+
_.value = !1, p.value = null;
|
|
1513
|
+
}, S = W(() => p.value ? {
|
|
1514
|
+
title: p.value.confirmTitle,
|
|
1515
|
+
content: p.value.confirmContent || p.value.confirmTitle
|
|
1464
1516
|
} : {
|
|
1465
|
-
title:
|
|
1466
|
-
content:
|
|
1517
|
+
title: n("hbLibComp.hbTableAct.secendConfirm"),
|
|
1518
|
+
content: n("hbLibComp.hbTableAct.confirmContent")
|
|
1467
1519
|
});
|
|
1468
|
-
return
|
|
1520
|
+
return d({
|
|
1469
1521
|
ADropdown: qe,
|
|
1470
|
-
AMenu:
|
|
1471
|
-
AMenuItem:
|
|
1472
|
-
APopconfirm:
|
|
1473
|
-
AModal:
|
|
1522
|
+
AMenu: je,
|
|
1523
|
+
AMenuItem: Ye,
|
|
1524
|
+
APopconfirm: Le,
|
|
1525
|
+
AModal: Se,
|
|
1474
1526
|
DownOutlined: Ie
|
|
1475
|
-
}), (
|
|
1476
|
-
const E =
|
|
1477
|
-
return o(), k("div",
|
|
1478
|
-
(o(!0), k(J, null,
|
|
1479
|
-
|
|
1480
|
-
|
|
1527
|
+
}), (x, U) => {
|
|
1528
|
+
const E = j("a-divider"), V = ct("has");
|
|
1529
|
+
return o(), k("div", kl, [
|
|
1530
|
+
(o(!0), k(J, null, ae(l.value, (H, F) => (o(), k(J, { key: F }, [
|
|
1531
|
+
H.needConfirm ? (o(), k(J, { key: 0 }, [
|
|
1532
|
+
H.confirmType === "modal" ? re((o(), k("a", {
|
|
1481
1533
|
key: 0,
|
|
1482
1534
|
href: "javascript:;",
|
|
1483
|
-
onClick: (
|
|
1535
|
+
onClick: (t) => M(H),
|
|
1484
1536
|
class: "hb-lib-table-main-action"
|
|
1485
1537
|
}, [
|
|
1486
|
-
I(L(
|
|
1487
|
-
], 8,
|
|
1488
|
-
[V,
|
|
1489
|
-
]) : (o(),
|
|
1538
|
+
I(L(H.label), 1)
|
|
1539
|
+
], 8, _l)), [
|
|
1540
|
+
[V, H.permissionsTag || null]
|
|
1541
|
+
]) : (o(), B(i(Le), {
|
|
1490
1542
|
key: 1,
|
|
1491
|
-
title:
|
|
1492
|
-
onConfirm: (
|
|
1543
|
+
title: H.confirmTitle,
|
|
1544
|
+
onConfirm: (t) => r(H)
|
|
1493
1545
|
}, {
|
|
1494
|
-
default:
|
|
1495
|
-
|
|
1496
|
-
I(L(
|
|
1546
|
+
default: b(() => [
|
|
1547
|
+
re((o(), k("a", Sl, [
|
|
1548
|
+
I(L(H.label), 1)
|
|
1497
1549
|
])), [
|
|
1498
|
-
[V,
|
|
1550
|
+
[V, H.permissionsTag || null]
|
|
1499
1551
|
])
|
|
1500
1552
|
]),
|
|
1501
1553
|
_: 2
|
|
1502
1554
|
}, 1032, ["title", "onConfirm"]))
|
|
1503
1555
|
], 64)) : (o(), k(J, { key: 1 }, [
|
|
1504
|
-
|
|
1556
|
+
re((o(), k("a", {
|
|
1505
1557
|
href: "javascript:;",
|
|
1506
|
-
onClick: (
|
|
1558
|
+
onClick: (t) => r(H),
|
|
1507
1559
|
class: "hb-lib-table-main-action"
|
|
1508
1560
|
}, [
|
|
1509
|
-
I(L(
|
|
1510
|
-
], 8,
|
|
1511
|
-
[V,
|
|
1561
|
+
I(L(H.label), 1)
|
|
1562
|
+
], 8, wl)), [
|
|
1563
|
+
[V, H.permissionsTag || null]
|
|
1512
1564
|
]),
|
|
1513
|
-
|
|
1565
|
+
s.value && s.value.length > 0 || F !== l.value.length - 1 ? (o(), B(E, {
|
|
1514
1566
|
key: 0,
|
|
1515
1567
|
type: "vertical"
|
|
1516
|
-
})) :
|
|
1568
|
+
})) : R("", !0)
|
|
1517
1569
|
], 64))
|
|
1518
1570
|
], 64))), 128)),
|
|
1519
|
-
|
|
1520
|
-
overlay:
|
|
1521
|
-
|
|
1522
|
-
default:
|
|
1523
|
-
(o(!0), k(J, null,
|
|
1524
|
-
key:
|
|
1571
|
+
s.value && s.value.length > 0 ? (o(), B(i(qe), { key: 0 }, {
|
|
1572
|
+
overlay: b(() => [
|
|
1573
|
+
T(i(je), null, {
|
|
1574
|
+
default: b(() => [
|
|
1575
|
+
(o(!0), k(J, null, ae(s.value, (H) => (o(), B(i(Ye), {
|
|
1576
|
+
key: H.key
|
|
1525
1577
|
}, {
|
|
1526
|
-
default:
|
|
1527
|
-
|
|
1528
|
-
|
|
1578
|
+
default: b(() => [
|
|
1579
|
+
H.needConfirm ? (o(), k(J, { key: 0 }, [
|
|
1580
|
+
H.confirmType === "modal" ? re((o(), k("a", {
|
|
1529
1581
|
key: 0,
|
|
1530
1582
|
href: "javascript:;",
|
|
1531
|
-
onClick: (
|
|
1583
|
+
onClick: (F) => M(H)
|
|
1532
1584
|
}, [
|
|
1533
|
-
I(L(
|
|
1534
|
-
], 8,
|
|
1535
|
-
[V,
|
|
1536
|
-
]) : (o(),
|
|
1585
|
+
I(L(H.label), 1)
|
|
1586
|
+
], 8, xl)), [
|
|
1587
|
+
[V, H.permissionsTag || null]
|
|
1588
|
+
]) : (o(), B(i(Le), {
|
|
1537
1589
|
key: 1,
|
|
1538
|
-
title:
|
|
1539
|
-
onConfirm: (
|
|
1590
|
+
title: H.confirmTitle,
|
|
1591
|
+
onConfirm: (F) => r(H)
|
|
1540
1592
|
}, {
|
|
1541
|
-
default:
|
|
1542
|
-
|
|
1543
|
-
I(L(
|
|
1593
|
+
default: b(() => [
|
|
1594
|
+
re((o(), k("a", Tl, [
|
|
1595
|
+
I(L(H.label), 1)
|
|
1544
1596
|
])), [
|
|
1545
|
-
[V,
|
|
1597
|
+
[V, H.permissionsTag || null]
|
|
1546
1598
|
])
|
|
1547
1599
|
]),
|
|
1548
1600
|
_: 2
|
|
1549
1601
|
}, 1032, ["title", "onConfirm"]))
|
|
1550
|
-
], 64)) :
|
|
1602
|
+
], 64)) : re((o(), k("a", {
|
|
1551
1603
|
key: 1,
|
|
1552
1604
|
href: "javascript:;",
|
|
1553
|
-
onClick: (
|
|
1605
|
+
onClick: (F) => r(H)
|
|
1554
1606
|
}, [
|
|
1555
|
-
I(L(
|
|
1556
|
-
], 8,
|
|
1557
|
-
[V,
|
|
1607
|
+
I(L(H.label), 1)
|
|
1608
|
+
], 8, $l)), [
|
|
1609
|
+
[V, H.permissionsTag || null]
|
|
1558
1610
|
])
|
|
1559
1611
|
]),
|
|
1560
1612
|
_: 2
|
|
@@ -1563,73 +1615,59 @@ const bl = {
|
|
|
1563
1615
|
_: 1
|
|
1564
1616
|
})
|
|
1565
1617
|
]),
|
|
1566
|
-
default:
|
|
1567
|
-
v("a",
|
|
1568
|
-
I(L(
|
|
1569
|
-
|
|
1618
|
+
default: b(() => [
|
|
1619
|
+
v("a", Fl, [
|
|
1620
|
+
I(L(x.$t("hbLibComp.hbTableAct.more")) + " ", 1),
|
|
1621
|
+
T(i(Ie), { style: { "font-size": "12px", "margin-left": "4px" } })
|
|
1570
1622
|
])
|
|
1571
1623
|
]),
|
|
1572
1624
|
_: 1
|
|
1573
|
-
})) :
|
|
1574
|
-
|
|
1575
|
-
visible:
|
|
1625
|
+
})) : R("", !0),
|
|
1626
|
+
T(i(Se), {
|
|
1627
|
+
visible: _.value,
|
|
1576
1628
|
title: S.value.title,
|
|
1577
1629
|
"confirm-loading": m.value,
|
|
1578
|
-
onOk:
|
|
1579
|
-
onCancel:
|
|
1630
|
+
onOk: w,
|
|
1631
|
+
onCancel: N
|
|
1580
1632
|
}, {
|
|
1581
|
-
default:
|
|
1582
|
-
v("p",
|
|
1633
|
+
default: b(() => [
|
|
1634
|
+
v("p", Ml, L(S.value.content), 1)
|
|
1583
1635
|
]),
|
|
1584
1636
|
_: 1
|
|
1585
1637
|
}, 8, ["visible", "title", "confirm-loading"])
|
|
1586
1638
|
]);
|
|
1587
1639
|
};
|
|
1588
1640
|
}
|
|
1589
|
-
}),
|
|
1590
|
-
const
|
|
1591
|
-
return !
|
|
1592
|
-
}) }),
|
|
1593
|
-
columns: {
|
|
1594
|
-
type: Array,
|
|
1595
|
-
default: () => [],
|
|
1596
|
-
required: !0
|
|
1597
|
-
},
|
|
1598
|
-
childColumns: {
|
|
1599
|
-
type: Array,
|
|
1600
|
-
default: () => []
|
|
1601
|
-
},
|
|
1602
|
-
// 自定义每行行高
|
|
1603
|
-
rowHeight: {
|
|
1604
|
-
type: Number
|
|
1605
|
-
},
|
|
1606
|
-
// 默认每列宽度
|
|
1607
|
-
defaultWidth: {
|
|
1608
|
-
type: [String, Number],
|
|
1609
|
-
default: 150
|
|
1610
|
-
}
|
|
1611
|
-
}, Hl = {
|
|
1641
|
+
}), Il = /* @__PURE__ */ oe(Hl, [["__scopeId", "data-v-ecac600b"]]), Al = le(Il), Dl = (e) => ({ tableWidth: W(() => {
|
|
1642
|
+
const u = Array.isArray(e) ? e : e.value;
|
|
1643
|
+
return !u || u.length === 0 ? 0 : u.map((n) => n.width && Number(n.width.toString().replace("px", "")) || 0).reduce((n, _) => n + _, 0);
|
|
1644
|
+
}) }), Ol = {
|
|
1612
1645
|
key: 0,
|
|
1613
1646
|
class: "hb-lib-list-table-act"
|
|
1614
|
-
},
|
|
1647
|
+
}, Bl = { class: "empty-container" }, Nl = /* @__PURE__ */ X({
|
|
1615
1648
|
name: "HbLibListTable",
|
|
1616
1649
|
__name: "HbListTable",
|
|
1617
|
-
props:
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1650
|
+
props: {
|
|
1651
|
+
columns: {},
|
|
1652
|
+
childColumns: {},
|
|
1653
|
+
rowHeight: {},
|
|
1654
|
+
defaultWidth: { default: () => 150 }
|
|
1655
|
+
},
|
|
1656
|
+
setup(e) {
|
|
1657
|
+
const { t: d } = ce(), u = e, n = O([]), _ = xe("HB_LIST_PAGE_CONTAINER"), { tableWidth: m } = Dl(W(() => u.columns));
|
|
1658
|
+
se(
|
|
1659
|
+
() => u.columns,
|
|
1660
|
+
(l) => {
|
|
1661
|
+
const s = l.filter((r) => r != null && r.checked);
|
|
1662
|
+
n.value = s.map((r) => {
|
|
1663
|
+
let M = { ...r, title: r.title || r.label };
|
|
1664
|
+
if (!M.width)
|
|
1665
|
+
M.width = u.defaultWidth;
|
|
1666
|
+
else if (typeof M.width == "string") {
|
|
1667
|
+
const w = parseInt(M.width, 10);
|
|
1668
|
+
M.width = isNaN(w) ? u.defaultWidth : w;
|
|
1631
1669
|
}
|
|
1632
|
-
return
|
|
1670
|
+
return M.resizable === void 0 && (M.resizable = !0), M;
|
|
1633
1671
|
});
|
|
1634
1672
|
},
|
|
1635
1673
|
{
|
|
@@ -1637,83 +1675,83 @@ const bl = {
|
|
|
1637
1675
|
deep: !0
|
|
1638
1676
|
}
|
|
1639
1677
|
);
|
|
1640
|
-
const
|
|
1641
|
-
if (
|
|
1642
|
-
const
|
|
1643
|
-
|
|
1678
|
+
const p = (l, s) => {
|
|
1679
|
+
if (s) {
|
|
1680
|
+
const r = typeof l == "string" ? parseInt(l, 10) : l;
|
|
1681
|
+
s.width = isNaN(r) ? 150 : r;
|
|
1644
1682
|
}
|
|
1645
|
-
},
|
|
1646
|
-
return (
|
|
1647
|
-
const
|
|
1683
|
+
}, h = (l, s = "YYYY-MM-DD HH:mm:ss") => l ? Me(l).format(s) : "";
|
|
1684
|
+
return (l, s) => {
|
|
1685
|
+
const r = j("a-empty"), M = j("a-tooltip"), w = j("HbLibCopy"), N = j("a-table");
|
|
1648
1686
|
return o(), k("div", {
|
|
1649
|
-
class: z(["hb-lib-list-table", { "nowrap-table":
|
|
1650
|
-
style:
|
|
1687
|
+
class: z(["hb-lib-list-table", { "nowrap-table": u.rowHeight }]),
|
|
1688
|
+
style: be({ "--hb-lib-table-td-height": e.rowHeight && e.rowHeight + "px" || "" })
|
|
1651
1689
|
}, [
|
|
1652
|
-
|
|
1653
|
-
Z(
|
|
1654
|
-
Z(
|
|
1655
|
-
])) :
|
|
1656
|
-
|
|
1657
|
-
columns:
|
|
1658
|
-
onResizeColumn:
|
|
1690
|
+
l.$slots.tableActLeft ? (o(), k("section", Ol, [
|
|
1691
|
+
Z(l.$slots, "tableActLeft", {}, void 0, !0),
|
|
1692
|
+
Z(l.$slots, "tableActRight", {}, void 0, !0)
|
|
1693
|
+
])) : R("", !0),
|
|
1694
|
+
T(N, ee(l.$attrs, {
|
|
1695
|
+
columns: n.value,
|
|
1696
|
+
onResizeColumn: p,
|
|
1659
1697
|
scroll: {
|
|
1660
|
-
x:
|
|
1661
|
-
y:
|
|
1698
|
+
x: i(m),
|
|
1699
|
+
y: i(_).tableHeight
|
|
1662
1700
|
}
|
|
1663
|
-
}),
|
|
1664
|
-
emptyText:
|
|
1665
|
-
v("div",
|
|
1666
|
-
|
|
1667
|
-
description:
|
|
1701
|
+
}), Qe({
|
|
1702
|
+
emptyText: b(() => [
|
|
1703
|
+
v("div", Bl, [
|
|
1704
|
+
T(r, {
|
|
1705
|
+
description: i(d)("hbLibComp.hbListTable.noData")
|
|
1668
1706
|
}, null, 8, ["description"])
|
|
1669
1707
|
])
|
|
1670
1708
|
]),
|
|
1671
1709
|
_: 2
|
|
1672
1710
|
}, [
|
|
1673
|
-
|
|
1711
|
+
l.$slots.headerCell ? {
|
|
1674
1712
|
name: "headerCell",
|
|
1675
|
-
fn:
|
|
1676
|
-
Z(
|
|
1713
|
+
fn: b(({ column: S }) => [
|
|
1714
|
+
Z(l.$slots, "headerCell", { column: S }, () => [
|
|
1677
1715
|
I(L(S.title), 1)
|
|
1678
1716
|
], !0)
|
|
1679
1717
|
]),
|
|
1680
1718
|
key: "0"
|
|
1681
1719
|
} : void 0,
|
|
1682
|
-
|
|
1720
|
+
l.$slots.bodyCell ? {
|
|
1683
1721
|
name: "bodyCell",
|
|
1684
|
-
fn:
|
|
1685
|
-
Z(
|
|
1722
|
+
fn: b(({ column: S, record: x, index: U }) => [
|
|
1723
|
+
Z(l.$slots, "bodyCell", {
|
|
1686
1724
|
column: S,
|
|
1687
|
-
record:
|
|
1725
|
+
record: x,
|
|
1688
1726
|
index: U
|
|
1689
1727
|
}, void 0, !0),
|
|
1690
1728
|
S && S.needTooltip ? (o(), k(J, { key: 0 }, [
|
|
1691
|
-
S.needTooltip ? (o(),
|
|
1692
|
-
title:
|
|
1693
|
-
I(L(
|
|
1729
|
+
S.needTooltip ? (o(), B(M, { key: 0 }, {
|
|
1730
|
+
title: b(() => [
|
|
1731
|
+
I(L(x[S.dataIndex]), 1)
|
|
1694
1732
|
]),
|
|
1695
|
-
default:
|
|
1696
|
-
I(" " + L(
|
|
1733
|
+
default: b(() => [
|
|
1734
|
+
I(" " + L(x[S.dataIndex]), 1)
|
|
1697
1735
|
]),
|
|
1698
1736
|
_: 2
|
|
1699
|
-
}, 1024)) :
|
|
1700
|
-
], 64)) :
|
|
1701
|
-
S && S.needCopy ? (o(),
|
|
1737
|
+
}, 1024)) : R("", !0)
|
|
1738
|
+
], 64)) : R("", !0),
|
|
1739
|
+
S && S.needCopy ? (o(), B(w, {
|
|
1702
1740
|
key: 1,
|
|
1703
|
-
"cp-text":
|
|
1741
|
+
"cp-text": x[S.dataIndex],
|
|
1704
1742
|
style: { position: "relative" }
|
|
1705
|
-
}, null, 8, ["cp-text"])) :
|
|
1743
|
+
}, null, 8, ["cp-text"])) : R("", !0),
|
|
1706
1744
|
S && S.needFormat ? (o(), k(J, { key: 2 }, [
|
|
1707
|
-
I(L(
|
|
1708
|
-
], 64)) :
|
|
1745
|
+
I(L(h(x[S.dataIndex], S.format)), 1)
|
|
1746
|
+
], 64)) : R("", !0)
|
|
1709
1747
|
]),
|
|
1710
1748
|
key: "1"
|
|
1711
1749
|
} : void 0,
|
|
1712
|
-
|
|
1750
|
+
l.$slots.expandedRowRender ? {
|
|
1713
1751
|
name: "expandedRowRender",
|
|
1714
|
-
fn:
|
|
1715
|
-
Z(
|
|
1716
|
-
column:
|
|
1752
|
+
fn: b(({ record: S }) => [
|
|
1753
|
+
Z(l.$slots, "expandedRowRender", {
|
|
1754
|
+
column: e.childColumns,
|
|
1717
1755
|
record: S
|
|
1718
1756
|
}, void 0, !0)
|
|
1719
1757
|
]),
|
|
@@ -1723,16 +1761,35 @@ const bl = {
|
|
|
1723
1761
|
], 6);
|
|
1724
1762
|
};
|
|
1725
1763
|
}
|
|
1726
|
-
}),
|
|
1764
|
+
}), Rl = /* @__PURE__ */ oe(Nl, [["__scopeId", "data-v-f5b59c06"]]), Pl = {
|
|
1765
|
+
columns: {
|
|
1766
|
+
type: Array,
|
|
1767
|
+
default: () => [],
|
|
1768
|
+
required: !0
|
|
1769
|
+
},
|
|
1770
|
+
childColumns: {
|
|
1771
|
+
type: Array,
|
|
1772
|
+
default: () => []
|
|
1773
|
+
},
|
|
1774
|
+
// 自定义每行行高
|
|
1775
|
+
rowHeight: {
|
|
1776
|
+
type: Number
|
|
1777
|
+
},
|
|
1778
|
+
// 默认每列宽度
|
|
1779
|
+
defaultWidth: {
|
|
1780
|
+
type: [String, Number],
|
|
1781
|
+
default: 150
|
|
1782
|
+
}
|
|
1783
|
+
}, zl = le(Rl), El = { class: "hb-lib-table-setting-box" }, Vl = {
|
|
1727
1784
|
key: 0,
|
|
1728
1785
|
class: "hb-lib-table-drag-item"
|
|
1729
|
-
},
|
|
1786
|
+
}, Ul = {
|
|
1730
1787
|
key: 0,
|
|
1731
1788
|
class: "hb-lib-table-drag-item-act"
|
|
1732
|
-
},
|
|
1789
|
+
}, Kl = ["onClick"], Yl = ["onClick"], jl = { class: "hb-lib-table-set-btn-group" }, ql = {
|
|
1733
1790
|
class: "select-all-container",
|
|
1734
1791
|
style: { "margin-right": "10px" }
|
|
1735
|
-
},
|
|
1792
|
+
}, Wl = /* @__PURE__ */ X({
|
|
1736
1793
|
name: "HbLibTableColumnSet",
|
|
1737
1794
|
__name: "HbTableColumnSet",
|
|
1738
1795
|
props: {
|
|
@@ -1764,109 +1821,109 @@ const bl = {
|
|
|
1764
1821
|
}
|
|
1765
1822
|
},
|
|
1766
1823
|
emits: ["on-get-columns", "refresh", "clearSelected"],
|
|
1767
|
-
setup(
|
|
1768
|
-
const
|
|
1824
|
+
setup(e, { emit: d }) {
|
|
1825
|
+
const u = d, { t: n } = ce(), _ = e, m = O([]), p = W(() => l.value.filter((t) => t.checked));
|
|
1769
1826
|
O([]);
|
|
1770
|
-
const
|
|
1771
|
-
|
|
1772
|
-
},
|
|
1773
|
-
const
|
|
1774
|
-
if (m.value.some((
|
|
1775
|
-
const
|
|
1776
|
-
if ((
|
|
1777
|
-
const K =
|
|
1778
|
-
|
|
1827
|
+
const h = O(!1), l = O([]), s = O(null), r = W(() => p.value.length > 0 && p.value.length === m.value.length), M = W(() => p.value.length > 0 && p.value.length < m.value.length), w = (t) => {
|
|
1828
|
+
s.value = t.oldIndex;
|
|
1829
|
+
}, N = (t) => {
|
|
1830
|
+
const a = t.newIndex;
|
|
1831
|
+
if (m.value.some((y) => y.fixed === "left" || y.fixed === "right" || y.fixed === !0)) {
|
|
1832
|
+
const y = m.value.filter((K) => K.fixed === "left").length, c = m.value.length - m.value.filter((K) => K.fixed === "right").length;
|
|
1833
|
+
if ((y > 0 && a < y || c < m.value.length && a >= c) && (we.warning(n("hbLibComp.hbLibListTableColumsSet.errorTip")), s.value !== null)) {
|
|
1834
|
+
const K = l.value.splice(a, 1)[0];
|
|
1835
|
+
l.value.splice(s.value, 0, K);
|
|
1779
1836
|
}
|
|
1780
1837
|
}
|
|
1781
|
-
|
|
1782
|
-
}, S = (
|
|
1783
|
-
|
|
1784
|
-
},
|
|
1785
|
-
|
|
1838
|
+
s.value = null;
|
|
1839
|
+
}, S = (t) => {
|
|
1840
|
+
t.target.checked ? l.value.forEach((f) => f.checked = !0) : l.value.forEach((f) => f.checked = !1);
|
|
1841
|
+
}, x = (t, a) => {
|
|
1842
|
+
a ? t.checked = !0 : t.checked = !1;
|
|
1786
1843
|
}, U = () => {
|
|
1787
|
-
m.value = [...
|
|
1844
|
+
m.value = [...l.value], u("on-get-columns", m.value), h.value = !1;
|
|
1788
1845
|
}, E = () => {
|
|
1789
|
-
m.value =
|
|
1790
|
-
...
|
|
1791
|
-
label:
|
|
1792
|
-
value:
|
|
1793
|
-
checked:
|
|
1794
|
-
})),
|
|
1795
|
-
let
|
|
1796
|
-
|
|
1797
|
-
|
|
1846
|
+
m.value = _.tableColumns.map((a) => ({
|
|
1847
|
+
...a,
|
|
1848
|
+
label: a.title && a.title.tag ? V(a.title) : a.title || a.title2,
|
|
1849
|
+
value: a.dataIndex,
|
|
1850
|
+
checked: a.checked || a.checked === void 0
|
|
1851
|
+
})), l.value = [...m.value];
|
|
1852
|
+
let t = [];
|
|
1853
|
+
_.tableColumns.forEach(function(a) {
|
|
1854
|
+
t.push(a.dataIndex);
|
|
1798
1855
|
});
|
|
1799
|
-
}, V = (
|
|
1800
|
-
delete
|
|
1801
|
-
const
|
|
1802
|
-
if (
|
|
1803
|
-
let
|
|
1804
|
-
for (let
|
|
1805
|
-
|
|
1806
|
-
if (
|
|
1807
|
-
const
|
|
1808
|
-
|
|
1856
|
+
}, V = (t) => t.children[0].text, H = (t) => {
|
|
1857
|
+
delete t.fixed;
|
|
1858
|
+
const a = l.value.findIndex((f) => f.value === t.value);
|
|
1859
|
+
if (a !== -1) {
|
|
1860
|
+
let f = -1;
|
|
1861
|
+
for (let y = 0; y < l.value.length; y++)
|
|
1862
|
+
l.value[y].fixed === "left" && (f = y);
|
|
1863
|
+
if (f !== -1 && a !== f + 1) {
|
|
1864
|
+
const y = [...l.value], [c] = y.splice(a, 1);
|
|
1865
|
+
y.splice(f + 1, 0, c), l.value = y;
|
|
1809
1866
|
}
|
|
1810
1867
|
}
|
|
1811
|
-
},
|
|
1812
|
-
const
|
|
1813
|
-
if (
|
|
1814
|
-
let
|
|
1815
|
-
for (let
|
|
1816
|
-
|
|
1817
|
-
if (
|
|
1818
|
-
const
|
|
1819
|
-
|
|
1868
|
+
}, F = (t) => {
|
|
1869
|
+
const a = l.value.findIndex((f) => f.value === t.value);
|
|
1870
|
+
if (a !== -1) {
|
|
1871
|
+
let f = -1;
|
|
1872
|
+
for (let y = 0; y < l.value.length; y++)
|
|
1873
|
+
l.value[y].fixed === "left" && (f = y);
|
|
1874
|
+
if (f !== -1 && a !== f + 1) {
|
|
1875
|
+
const y = [...l.value], c = y.splice(a, 1);
|
|
1876
|
+
c[0].fixed = "left", y.splice(f + 1, 0, c[0]), l.value = y;
|
|
1820
1877
|
}
|
|
1821
1878
|
}
|
|
1822
1879
|
};
|
|
1823
|
-
return E(), (
|
|
1824
|
-
const
|
|
1825
|
-
return o(), k("div",
|
|
1826
|
-
|
|
1827
|
-
title: n
|
|
1880
|
+
return E(), (t, a) => {
|
|
1881
|
+
const f = j("a-tooltip"), y = j("a-button");
|
|
1882
|
+
return o(), k("div", El, [
|
|
1883
|
+
T(i(Ct), {
|
|
1884
|
+
title: i(n)("hbLibComp.hbLibListTableColumsSet.popoverTitle"),
|
|
1828
1885
|
trigger: "click",
|
|
1829
1886
|
placement: "leftTop",
|
|
1830
1887
|
overlayClassName: "alertInfoContent",
|
|
1831
|
-
visible:
|
|
1832
|
-
"onUpdate:visible":
|
|
1888
|
+
visible: h.value,
|
|
1889
|
+
"onUpdate:visible": a[1] || (a[1] = (c) => h.value = c)
|
|
1833
1890
|
}, {
|
|
1834
|
-
content:
|
|
1835
|
-
|
|
1836
|
-
modelValue:
|
|
1837
|
-
"onUpdate:modelValue":
|
|
1891
|
+
content: b(() => [
|
|
1892
|
+
T(i(me), {
|
|
1893
|
+
modelValue: l.value,
|
|
1894
|
+
"onUpdate:modelValue": a[0] || (a[0] = (c) => l.value = c),
|
|
1838
1895
|
"item-key": "value",
|
|
1839
1896
|
class: "hb-lib-table-set-drag",
|
|
1840
1897
|
"ghost-class": "ghost",
|
|
1841
1898
|
animation: "200",
|
|
1842
1899
|
handle: ".drag-handle",
|
|
1843
|
-
onStart:
|
|
1844
|
-
onEnd:
|
|
1900
|
+
onStart: w,
|
|
1901
|
+
onEnd: N
|
|
1845
1902
|
}, {
|
|
1846
|
-
item:
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
checked:
|
|
1850
|
-
onChange: (K) =>
|
|
1903
|
+
item: b(({ element: c }) => [
|
|
1904
|
+
c.fixed !== "right" ? (o(), k("div", Vl, [
|
|
1905
|
+
T(i(ve), {
|
|
1906
|
+
checked: c.checked,
|
|
1907
|
+
onChange: (K) => x(c, K.target.checked)
|
|
1851
1908
|
}, {
|
|
1852
|
-
default:
|
|
1853
|
-
I(L(
|
|
1909
|
+
default: b(() => [
|
|
1910
|
+
I(L(c.label), 1)
|
|
1854
1911
|
]),
|
|
1855
1912
|
_: 2
|
|
1856
1913
|
}, 1032, ["checked", "onChange"]),
|
|
1857
|
-
|
|
1914
|
+
c.checked ? (o(), k("section", Ul, [
|
|
1858
1915
|
v("span", {
|
|
1859
|
-
class: z(
|
|
1916
|
+
class: z(c.fixed ? "drag-hide" : "drag-handle")
|
|
1860
1917
|
}, "⋮⋮", 2),
|
|
1861
|
-
|
|
1862
|
-
title:
|
|
1863
|
-
I(L(n
|
|
1918
|
+
c.fixed ? (o(), B(f, { key: 0 }, {
|
|
1919
|
+
title: b(() => [
|
|
1920
|
+
I(L(i(n)("hbLibComp.hbLibListTableColumsSet.cancelFix")), 1)
|
|
1864
1921
|
]),
|
|
1865
|
-
default:
|
|
1922
|
+
default: b(() => [
|
|
1866
1923
|
v("span", {
|
|
1867
1924
|
class: "hb-lib-table-drag-item-act-btn",
|
|
1868
|
-
onClick: (K) =>
|
|
1869
|
-
}, [...
|
|
1925
|
+
onClick: (K) => H(c)
|
|
1926
|
+
}, [...a[2] || (a[2] = [
|
|
1870
1927
|
v("svg", {
|
|
1871
1928
|
t: "1759048615600",
|
|
1872
1929
|
class: "icon",
|
|
@@ -1883,19 +1940,19 @@ const bl = {
|
|
|
1883
1940
|
fill: "#ff5000"
|
|
1884
1941
|
})
|
|
1885
1942
|
], -1)
|
|
1886
|
-
])], 8,
|
|
1943
|
+
])], 8, Kl)
|
|
1887
1944
|
]),
|
|
1888
1945
|
_: 2
|
|
1889
|
-
}, 1024)) :
|
|
1890
|
-
|
|
1891
|
-
title:
|
|
1892
|
-
I(L(n
|
|
1946
|
+
}, 1024)) : R("", !0),
|
|
1947
|
+
c.fixed ? R("", !0) : (o(), B(f, { key: 1 }, {
|
|
1948
|
+
title: b(() => [
|
|
1949
|
+
I(L(i(n)("hbLibComp.hbLibListTableColumsSet.fix")), 1)
|
|
1893
1950
|
]),
|
|
1894
|
-
default:
|
|
1951
|
+
default: b(() => [
|
|
1895
1952
|
v("span", {
|
|
1896
1953
|
class: "hb-lib-table-drag-item-act-btn",
|
|
1897
|
-
onClick: (K) =>
|
|
1898
|
-
}, [...
|
|
1954
|
+
onClick: (K) => F(c)
|
|
1955
|
+
}, [...a[3] || (a[3] = [
|
|
1899
1956
|
v("svg", {
|
|
1900
1957
|
t: "1759048735643",
|
|
1901
1958
|
class: "icon",
|
|
@@ -1912,45 +1969,45 @@ const bl = {
|
|
|
1912
1969
|
fill: "#ff5000"
|
|
1913
1970
|
})
|
|
1914
1971
|
], -1)
|
|
1915
|
-
])], 8,
|
|
1972
|
+
])], 8, Yl)
|
|
1916
1973
|
]),
|
|
1917
1974
|
_: 2
|
|
1918
1975
|
}, 1024))
|
|
1919
|
-
])) :
|
|
1920
|
-
])) :
|
|
1976
|
+
])) : R("", !0)
|
|
1977
|
+
])) : R("", !0)
|
|
1921
1978
|
]),
|
|
1922
1979
|
_: 1
|
|
1923
1980
|
}, 8, ["modelValue"]),
|
|
1924
|
-
v("div",
|
|
1925
|
-
v("div",
|
|
1926
|
-
|
|
1927
|
-
checked:
|
|
1928
|
-
indeterminate:
|
|
1981
|
+
v("div", jl, [
|
|
1982
|
+
v("div", ql, [
|
|
1983
|
+
T(i(ve), {
|
|
1984
|
+
checked: r.value,
|
|
1985
|
+
indeterminate: M.value,
|
|
1929
1986
|
onChange: S
|
|
1930
1987
|
}, {
|
|
1931
|
-
default:
|
|
1932
|
-
I(L(n
|
|
1988
|
+
default: b(() => [
|
|
1989
|
+
I(L(i(n)("hbLibComp.hbLibListTableColumsSet.allSelect")), 1)
|
|
1933
1990
|
]),
|
|
1934
1991
|
_: 1
|
|
1935
1992
|
}, 8, ["checked", "indeterminate"])
|
|
1936
1993
|
]),
|
|
1937
|
-
|
|
1994
|
+
T(y, {
|
|
1938
1995
|
onClick: U,
|
|
1939
1996
|
type: "primary"
|
|
1940
1997
|
}, {
|
|
1941
|
-
default:
|
|
1942
|
-
I(L(n
|
|
1998
|
+
default: b(() => [
|
|
1999
|
+
I(L(i(n)("hbLibComp.hbLibListTableColumsSet.confirm")), 1)
|
|
1943
2000
|
]),
|
|
1944
2001
|
_: 1
|
|
1945
2002
|
})
|
|
1946
2003
|
])
|
|
1947
2004
|
]),
|
|
1948
|
-
default:
|
|
1949
|
-
|
|
1950
|
-
title: n
|
|
2005
|
+
default: b(() => [
|
|
2006
|
+
T(f, {
|
|
2007
|
+
title: i(n)("hbLibComp.hbLibListTableColumsSet.title"),
|
|
1951
2008
|
placement: "leftTop"
|
|
1952
2009
|
}, {
|
|
1953
|
-
default:
|
|
2010
|
+
default: b(() => [...a[4] || (a[4] = [
|
|
1954
2011
|
v("span", { class: "hb-lib-table-col-set" }, [
|
|
1955
2012
|
v("svg", {
|
|
1956
2013
|
t: "1759041858618",
|
|
@@ -1983,7 +2040,7 @@ const bl = {
|
|
|
1983
2040
|
]);
|
|
1984
2041
|
};
|
|
1985
2042
|
}
|
|
1986
|
-
}),
|
|
2043
|
+
}), Jl = /* @__PURE__ */ oe(Wl, [["__scopeId", "data-v-c9fc6c04"]]), Gl = le(Jl), Xe = {
|
|
1987
2044
|
// 如果存在cpText时,K和V无效
|
|
1988
2045
|
cpText: {
|
|
1989
2046
|
type: String,
|
|
@@ -2024,65 +2081,65 @@ const bl = {
|
|
|
2024
2081
|
type: String,
|
|
2025
2082
|
default: "ab"
|
|
2026
2083
|
}
|
|
2027
|
-
},
|
|
2084
|
+
}, Ql = /* @__PURE__ */ X({
|
|
2028
2085
|
name: "HbLibCopy",
|
|
2029
2086
|
__name: "copy",
|
|
2030
|
-
props:
|
|
2031
|
-
setup(
|
|
2032
|
-
const
|
|
2033
|
-
|
|
2034
|
-
|
|
2087
|
+
props: Xe,
|
|
2088
|
+
setup(e) {
|
|
2089
|
+
const d = e, u = O();
|
|
2090
|
+
dt(() => {
|
|
2091
|
+
u.value = d.data;
|
|
2035
2092
|
});
|
|
2036
|
-
const
|
|
2037
|
-
if (
|
|
2093
|
+
const n = W(() => {
|
|
2094
|
+
if (d.cpText) return d.cpText;
|
|
2038
2095
|
let m = "";
|
|
2039
|
-
if (
|
|
2040
|
-
if (Array.isArray(
|
|
2041
|
-
if (
|
|
2042
|
-
const
|
|
2043
|
-
m =
|
|
2096
|
+
if (d.data)
|
|
2097
|
+
if (Array.isArray(d.data)) {
|
|
2098
|
+
if (d.K && d.V && d.L) {
|
|
2099
|
+
const p = d.data.find((h) => h?.[d.K] === d.V);
|
|
2100
|
+
m = p ? p[d.L] : "";
|
|
2044
2101
|
}
|
|
2045
2102
|
} else
|
|
2046
|
-
|
|
2103
|
+
d.K && (m = d.data[d.K]);
|
|
2047
2104
|
return m;
|
|
2048
|
-
}),
|
|
2049
|
-
navigator.clipboard.writeText(
|
|
2050
|
-
|
|
2105
|
+
}), _ = () => {
|
|
2106
|
+
navigator.clipboard.writeText(n.value).then(() => {
|
|
2107
|
+
we.success(d.copySuccessTip);
|
|
2051
2108
|
}).catch(() => {
|
|
2052
|
-
|
|
2109
|
+
we.error("复制失败");
|
|
2053
2110
|
});
|
|
2054
2111
|
};
|
|
2055
|
-
return (m,
|
|
2056
|
-
const
|
|
2057
|
-
return
|
|
2112
|
+
return (m, p) => {
|
|
2113
|
+
const h = j("a-tooltip");
|
|
2114
|
+
return n.value ? (o(), B(h, {
|
|
2058
2115
|
key: 0,
|
|
2059
2116
|
title: m.tooltipTitle
|
|
2060
2117
|
}, {
|
|
2061
|
-
default:
|
|
2118
|
+
default: b(() => [
|
|
2062
2119
|
v("i", {
|
|
2063
2120
|
class: z(["hb-lib-copy-text-eyevue icon strongQ strong-copy", m.classType == "ab" ? "ab" : "normal"]),
|
|
2064
|
-
style:
|
|
2065
|
-
onClick: _e(
|
|
2121
|
+
style: be({ ...m.cpStyle }),
|
|
2122
|
+
onClick: _e(_, ["stop", "prevent"])
|
|
2066
2123
|
}, null, 6)
|
|
2067
2124
|
]),
|
|
2068
2125
|
_: 1
|
|
2069
|
-
}, 8, ["title"])) :
|
|
2126
|
+
}, 8, ["title"])) : R("", !0);
|
|
2070
2127
|
};
|
|
2071
2128
|
}
|
|
2072
|
-
}),
|
|
2129
|
+
}), Zl = /* @__PURE__ */ oe(Ql, [["__scopeId", "data-v-d5ca4420"]]), et = le(Zl), Xl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2073
2130
|
__proto__: null,
|
|
2074
|
-
HbLibCopy:
|
|
2075
|
-
HbLibFormItemFilterModal:
|
|
2076
|
-
HbLibListBtnsAct:
|
|
2077
|
-
HbLibListForm:
|
|
2078
|
-
HbLibListMultiSelect:
|
|
2079
|
-
HbLibListPageAct:
|
|
2080
|
-
HbLibListPageContainer:
|
|
2081
|
-
HbLibListTable:
|
|
2082
|
-
HbLibMutilpleSelectModal:
|
|
2083
|
-
HbLibTableAct:
|
|
2084
|
-
HbLibTableColumnSet:
|
|
2085
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2131
|
+
HbLibCopy: et,
|
|
2132
|
+
HbLibFormItemFilterModal: Mt,
|
|
2133
|
+
HbLibListBtnsAct: Qt,
|
|
2134
|
+
HbLibListForm: Ot,
|
|
2135
|
+
HbLibListMultiSelect: Fe,
|
|
2136
|
+
HbLibListPageAct: Kt,
|
|
2137
|
+
HbLibListPageContainer: tl,
|
|
2138
|
+
HbLibListTable: zl,
|
|
2139
|
+
HbLibMutilpleSelectModal: Ll,
|
|
2140
|
+
HbLibTableAct: Al,
|
|
2141
|
+
HbLibTableColumnSet: Gl
|
|
2142
|
+
}, Symbol.toStringTag, { value: "Module" })), ea = {
|
|
2086
2143
|
// 传进来的数据
|
|
2087
2144
|
data: {
|
|
2088
2145
|
type: Array,
|
|
@@ -2131,7 +2188,7 @@ const bl = {
|
|
|
2131
2188
|
// 是否支持单击选中item
|
|
2132
2189
|
// 是否支持多项选中 checkbox
|
|
2133
2190
|
// 是否支持虚拟滚动
|
|
2134
|
-
},
|
|
2191
|
+
}, ta = /* @__PURE__ */ X({
|
|
2135
2192
|
__name: "treeNode",
|
|
2136
2193
|
props: {
|
|
2137
2194
|
item: {
|
|
@@ -2145,131 +2202,250 @@ const bl = {
|
|
|
2145
2202
|
}
|
|
2146
2203
|
},
|
|
2147
2204
|
emits: ["toggleExpand"],
|
|
2148
|
-
setup(
|
|
2149
|
-
const
|
|
2150
|
-
|
|
2205
|
+
setup(e, { emit: d }) {
|
|
2206
|
+
const u = e, n = d, _ = fe("treeNode"), m = W(() => u.expandedKeys.has(u.item.key)), p = () => {
|
|
2207
|
+
n("toggleExpand", u.item.key);
|
|
2151
2208
|
};
|
|
2152
|
-
return (
|
|
2209
|
+
return (h, l) => (o(), k("div", {
|
|
2153
2210
|
class: "tree-node-container",
|
|
2154
|
-
style:
|
|
2155
|
-
onClick:
|
|
2211
|
+
style: be({ paddingLeft: `${e.item.level * 20}px` }),
|
|
2212
|
+
onClick: l[0] || (l[0] = (s) => p())
|
|
2156
2213
|
}, [
|
|
2157
2214
|
v("span", {
|
|
2158
2215
|
class: z(["tree-node-icon", [
|
|
2159
2216
|
m.value && "tree-node-icon-open",
|
|
2160
|
-
|
|
2217
|
+
i(_).is("leaf", e.item.isLeaf)
|
|
2161
2218
|
]])
|
|
2162
2219
|
}, "➡", 2),
|
|
2163
|
-
I(L(
|
|
2220
|
+
I(L(e.item.label), 1)
|
|
2164
2221
|
], 4));
|
|
2165
2222
|
}
|
|
2166
|
-
}),
|
|
2223
|
+
}), la = /* @__PURE__ */ X({
|
|
2167
2224
|
name: "HbTree",
|
|
2168
2225
|
__name: "tree",
|
|
2169
|
-
props:
|
|
2170
|
-
setup(
|
|
2171
|
-
const
|
|
2172
|
-
const
|
|
2173
|
-
const S =
|
|
2174
|
-
...
|
|
2175
|
-
originData:
|
|
2176
|
-
label:
|
|
2177
|
-
key:
|
|
2226
|
+
props: ea,
|
|
2227
|
+
setup(e) {
|
|
2228
|
+
const d = e, u = fe("tree"), n = O([]), _ = O(new Set(d.defaultExpandKeys)), m = (s) => {
|
|
2229
|
+
const r = (M, w = null) => M.map((N) => {
|
|
2230
|
+
const S = N[d.childrenKey], x = {
|
|
2231
|
+
...N,
|
|
2232
|
+
originData: N,
|
|
2233
|
+
label: N[d.labelKey] || "",
|
|
2234
|
+
key: N[d.keyKey] || "",
|
|
2178
2235
|
children: [],
|
|
2179
|
-
isLeaf:
|
|
2180
|
-
level:
|
|
2181
|
-
parentKey:
|
|
2236
|
+
isLeaf: N.isLeaf ?? S.length === 0,
|
|
2237
|
+
level: w ? w.level + 1 : 0,
|
|
2238
|
+
parentKey: w ? w.key : null
|
|
2182
2239
|
};
|
|
2183
|
-
return S.length > 0 && (
|
|
2240
|
+
return S.length > 0 && (x.children = r(S, x)), x;
|
|
2184
2241
|
});
|
|
2185
|
-
return
|
|
2242
|
+
return r(s);
|
|
2186
2243
|
};
|
|
2187
|
-
|
|
2188
|
-
() =>
|
|
2189
|
-
(
|
|
2190
|
-
|
|
2244
|
+
se(
|
|
2245
|
+
() => d.data,
|
|
2246
|
+
(s) => {
|
|
2247
|
+
n.value = m(s);
|
|
2191
2248
|
},
|
|
2192
2249
|
{
|
|
2193
2250
|
deep: !0,
|
|
2194
2251
|
immediate: !0
|
|
2195
2252
|
}
|
|
2196
2253
|
);
|
|
2197
|
-
const
|
|
2198
|
-
const
|
|
2199
|
-
for (let
|
|
2200
|
-
|
|
2201
|
-
for (;
|
|
2202
|
-
const
|
|
2203
|
-
if (
|
|
2204
|
-
for (let S =
|
|
2205
|
-
|
|
2254
|
+
const p = W(() => {
|
|
2255
|
+
const s = n.value, r = _.value, M = [], w = [];
|
|
2256
|
+
for (let N = s.length - 1; N >= 0; N--)
|
|
2257
|
+
w.push(s[N]);
|
|
2258
|
+
for (; w.length > 0; ) {
|
|
2259
|
+
const N = w.pop();
|
|
2260
|
+
if (M.push(N), r.has(N.key))
|
|
2261
|
+
for (let S = N.children.length - 1; S >= 0; S--)
|
|
2262
|
+
w.push(N.children[S]);
|
|
2206
2263
|
}
|
|
2207
|
-
return
|
|
2208
|
-
}),
|
|
2209
|
-
|
|
2210
|
-
},
|
|
2264
|
+
return M;
|
|
2265
|
+
}), h = (s) => {
|
|
2266
|
+
_.value.has(s) ? _.value.delete(s) : _.value.add(s);
|
|
2267
|
+
}, l = () => {
|
|
2211
2268
|
};
|
|
2212
|
-
return (
|
|
2213
|
-
class: z([
|
|
2214
|
-
onClick:
|
|
2269
|
+
return (s, r) => (o(), k("div", {
|
|
2270
|
+
class: z([i(u).b()]),
|
|
2271
|
+
onClick: r[0] || (r[0] = (M) => l())
|
|
2215
2272
|
}, [
|
|
2216
|
-
(o(!0), k(J, null,
|
|
2217
|
-
key:
|
|
2218
|
-
item:
|
|
2219
|
-
expandedKeys:
|
|
2220
|
-
onToggleExpand:
|
|
2273
|
+
(o(!0), k(J, null, ae(p.value, (M) => (o(), B(ta, {
|
|
2274
|
+
key: M.key,
|
|
2275
|
+
item: M,
|
|
2276
|
+
expandedKeys: _.value,
|
|
2277
|
+
onToggleExpand: h
|
|
2221
2278
|
}, null, 8, ["item", "expandedKeys"]))), 128))
|
|
2222
2279
|
], 2));
|
|
2223
2280
|
}
|
|
2224
|
-
}),
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2281
|
+
}), aa = le(la), tt = {
|
|
2282
|
+
dragList: {
|
|
2283
|
+
type: Array,
|
|
2284
|
+
required: !0
|
|
2285
|
+
},
|
|
2286
|
+
// 拖拽的元素类型 可以是html元素 或者 vue组件
|
|
2287
|
+
childrenType: {
|
|
2288
|
+
type: String,
|
|
2289
|
+
default: "html"
|
|
2290
|
+
},
|
|
2291
|
+
// 拖拽的元素自定义样式
|
|
2292
|
+
dragClass: {
|
|
2293
|
+
type: String,
|
|
2294
|
+
default: "drag-item"
|
|
2295
|
+
},
|
|
2296
|
+
// 设置拖动元素的占位符类名 拖动起来后原来位置的元素会变成这个类名 就可以设置一些样式
|
|
2297
|
+
ghostClass: { type: String, default: null },
|
|
2298
|
+
// 拖拽元素被选中时添加的类名
|
|
2299
|
+
chosenClass: { type: String, default: null },
|
|
2300
|
+
// 是否可排序
|
|
2301
|
+
sort: {
|
|
2302
|
+
type: Boolean,
|
|
2303
|
+
default: !0
|
|
2304
|
+
},
|
|
2305
|
+
// 拖拽的元素自定义拖拽按钮 class 设置了它 盒子里只有有这个类名的元素才能启动盒子拖拽
|
|
2306
|
+
handle: {
|
|
2307
|
+
type: String,
|
|
2308
|
+
default: ""
|
|
2309
|
+
},
|
|
2310
|
+
// 过滤掉具有特定 class 的元素 不能拖拽
|
|
2311
|
+
filter: {
|
|
2312
|
+
type: String,
|
|
2313
|
+
default: ""
|
|
2314
|
+
},
|
|
2315
|
+
// 允许拖拽的元素 class
|
|
2316
|
+
draggable: {
|
|
2317
|
+
type: String,
|
|
2318
|
+
default: ""
|
|
2319
|
+
}
|
|
2320
|
+
}, oa = /* @__PURE__ */ X({
|
|
2321
|
+
name: "HbDrag",
|
|
2322
|
+
__name: "index",
|
|
2323
|
+
props: tt,
|
|
2324
|
+
emits: ["update:dragList", "handleDragStart", "handleDragEnd", "handleDragAdd", "handleDragRemove"],
|
|
2325
|
+
setup(e, { emit: d }) {
|
|
2326
|
+
const u = e, n = ut([]);
|
|
2327
|
+
se(
|
|
2328
|
+
() => u.dragList,
|
|
2329
|
+
(r) => {
|
|
2330
|
+
n.value = r;
|
|
2331
|
+
},
|
|
2332
|
+
{
|
|
2333
|
+
deep: !0,
|
|
2334
|
+
immediate: !0
|
|
2335
|
+
}
|
|
2336
|
+
);
|
|
2337
|
+
const _ = fe("drag"), m = d, p = (r) => {
|
|
2338
|
+
console.log("drag start", r), m("handleDragStart", r);
|
|
2339
|
+
}, h = (r) => {
|
|
2340
|
+
console.log("drag end", r), m("handleDragEnd", r);
|
|
2341
|
+
}, l = (r) => {
|
|
2342
|
+
console.log("drag add", r), m("handleDragAdd", r);
|
|
2343
|
+
}, s = (r) => {
|
|
2344
|
+
console.log("drag remove", r), m("handleDragRemove", r);
|
|
2345
|
+
};
|
|
2346
|
+
return (r, M) => (o(), k("div", {
|
|
2347
|
+
class: z(i(_).b())
|
|
2348
|
+
}, [
|
|
2349
|
+
r.childrenType == "component" ? (o(), B(i(me), ee({
|
|
2350
|
+
key: 0,
|
|
2351
|
+
modelValue: n.value,
|
|
2352
|
+
"onUpdate:modelValue": M[0] || (M[0] = (w) => n.value = w),
|
|
2353
|
+
"item-key": "key",
|
|
2354
|
+
class: { [r.dragClass]: r.dragClass }
|
|
2355
|
+
}, r.$attrs, {
|
|
2356
|
+
"ghost-class": r.ghostClass,
|
|
2357
|
+
onStart: p,
|
|
2358
|
+
onEnd: h,
|
|
2359
|
+
onAdd: l,
|
|
2360
|
+
onRemove: s
|
|
2361
|
+
}), {
|
|
2362
|
+
item: b(({ element: w }) => [
|
|
2363
|
+
(o(), B(ht(w.component)))
|
|
2364
|
+
]),
|
|
2365
|
+
_: 1
|
|
2366
|
+
}, 16, ["modelValue", "class", "ghost-class"])) : (o(), B(i(me), ee({
|
|
2367
|
+
key: 1,
|
|
2368
|
+
modelValue: n.value,
|
|
2369
|
+
"onUpdate:modelValue": M[1] || (M[1] = (w) => n.value = w),
|
|
2370
|
+
"item-key": "id",
|
|
2371
|
+
class: { [r.dragClass]: r.dragClass }
|
|
2372
|
+
}, r.$attrs, {
|
|
2373
|
+
"ghost-class": r.ghostClass,
|
|
2374
|
+
onStart: p,
|
|
2375
|
+
onEnd: h,
|
|
2376
|
+
onAdd: l,
|
|
2377
|
+
onRemove: s
|
|
2378
|
+
}), {
|
|
2379
|
+
item: b(({ element: w }) => [
|
|
2380
|
+
v("div", null, [
|
|
2381
|
+
Z(r.$slots, "default", { item: w }, void 0, !0)
|
|
2382
|
+
])
|
|
2383
|
+
]),
|
|
2384
|
+
_: 3
|
|
2385
|
+
}, 16, ["modelValue", "class", "ghost-class"]))
|
|
2386
|
+
], 2));
|
|
2387
|
+
}
|
|
2388
|
+
}), na = /* @__PURE__ */ oe(oa, [["__scopeId", "data-v-15b227f5"]]), sa = le(na), ia = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2389
|
+
__proto__: null,
|
|
2390
|
+
HbLibFuncCompCopy: et,
|
|
2391
|
+
HbLibFuncCompDrag: sa,
|
|
2392
|
+
HbLibFuncCompTree: aa
|
|
2393
|
+
}, Symbol.toStringTag, { value: "Module" }));
|
|
2394
|
+
let ra = { ...Xl, ...ia };
|
|
2395
|
+
const ca = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2228
2396
|
__proto__: null,
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2397
|
+
HbCopyProps: Xe,
|
|
2398
|
+
HbDragProps: tt,
|
|
2399
|
+
HbFormProps: Dt,
|
|
2400
|
+
HbFormSelectModalprops: Cl,
|
|
2401
|
+
HbListBtnsProps: Gt,
|
|
2402
|
+
HbListPageActProps: Ut,
|
|
2403
|
+
HbSfCmProps: $t,
|
|
2404
|
+
HbTableProps: Pl,
|
|
2405
|
+
ListPageContainerProps: el,
|
|
2406
|
+
default: ra
|
|
2407
|
+
}, Symbol.toStringTag, { value: "Module" })), da = { HbFileUploadModal: { cancel: "Cancel", clickUpload: "Click to upload", confirmImport: "Confirm import", dataImport: "Import data", downloadTemplate: "Import template download", dragFile: "Drag files here or", file: "document", fileUpload: "File import", maxSupport: "Most supported", onlySupport: "Only supports", placeSelect: "Please select", selectFile: "Please select the file to upload" }, HbLogModal: { close: "closure", operateContent: "Operation content", operateLogs: "Operation log", operateTime: "Operating time", operator: "operator" }, hbFormItemFilterModal: { add: "Add to", cancel: "Cancel", confirm: "Sure", moreConditionSearch: "Multiple searches", mostMore: "Optional at most", mostMoreTip: "conditions, drag and drop to adjust the sorting", noData: "No data yet", notShowTip: "No conditions shown", titleTip: "Conditions shown" }, hbFormSelectFilter: { allSelect: "Select all", close: "closure" }, hbLibListForm: { queryCase: "query plan" }, hbLibListTableColumsSet: { allSelect: "Select all", cancelFix: "Unpin", confirm: "Sure", errorTip: "Cannot move column to fixed column position", fix: "fixed", popoverTitle: "Custom columns", title: "Table field settings" }, hbListBtnsAct: { close: "Close query conditions", open: "Expand query conditions", reload: "Refresh data" }, hbListPageAct: { close: "close", exitFullScreen: "Exit full screen", fullScreen: "full screen", open: "Expand", query: "Query", reset: "reset", selfDefine: "Filter query conditions" }, hbListTable: { noData: "No data yet" }, hbMultiSelectModal: { pleaseSelect: "Please select" }, hbTableAct: { confirmContent: "Confirm content", more: "More", secendConfirm: "Second confirmation" } }, ua = {
|
|
2408
|
+
hbLibComp: da
|
|
2409
|
+
}, ha = { HbFileUploadModal: { cancel: "キャンセル", clickUpload: "クリックしてアップロード", confirmImport: "インポートの確認", dataImport: "データのインポート", downloadTemplate: "インポートテンプレートのダウンロード", dragFile: "ここにファイルをドラッグするか、", file: "書類", fileUpload: "ファイルのインポート", maxSupport: "最も支持されている", onlySupport: "サポートのみ", placeSelect: "選択してください", selectFile: "アップロードするファイルを選択してください" }, HbLogModal: { close: "閉鎖", operateContent: "操作内容", operateLogs: "操作ログ", operateTime: "稼働時間", operator: "オペレーター" }, hbFormItemFilterModal: { add: "に追加", cancel: "キャンセル", confirm: "もちろん", moreConditionSearch: "複数の検索", mostMore: "せいぜいオプション", mostMoreTip: "条件をドラッグアンドドロップして並べ替えを調整します", noData: "まだデータがありません", notShowTip: "条件が表示されていません", titleTip: "表示される条件" }, hbFormSelectFilter: { allSelect: "すべて選択", close: "閉鎖" }, hbLibListForm: { queryCase: "クエリプラン" }, hbLibListTableColumsSet: { allSelect: "すべて選択", cancelFix: "固定を解除する", confirm: "もちろん", errorTip: "列を固定列位置に移動できません", fix: "修理済み", popoverTitle: "カスタム列", title: "テーブルフィールドの設定" }, hbListBtnsAct: { close: "クエリ条件を閉じる", open: "クエリ条件を拡張する", reload: "データを更新する" }, hbListPageAct: { close: "近い", exitFullScreen: "全画面表示を終了する", fullScreen: "全画面表示", open: "拡大する", query: "クエリ", reset: "リセット", selfDefine: "フィルタークエリ条件" }, hbListTable: { noData: "まだデータがありません" }, hbMultiSelectModal: { pleaseSelect: "選択してください" }, hbTableAct: { confirmContent: "内容を確認する", more: "もっと", secendConfirm: "2回目の確認" } }, ba = {
|
|
2410
|
+
hbLibComp: ha
|
|
2411
|
+
}, fa = { hbFormItemFilterModal: { titleTip: "已显示条件", mostMore: "最多可选", mostMoreTip: "个条件,拖拽可以调整排序", notShowTip: "未显示条件", add: "添加", noData: "暂无数据", cancel: "取消", confirm: "确定", moreConditionSearch: "多项搜索" }, hbFormSelectFilter: { allSelect: "全选", close: "关闭" }, hbListPageAct: { query: "查询", reset: "重置", selfDefine: "筛选查询条件", open: "展开", close: "收起", fullScreen: "全屏", exitFullScreen: "退出全屏" }, hbListBtnsAct: { reload: "刷新数据", open: "展开查询条件", close: "收起查询条件" }, hbTableAct: { more: "更多", secendConfirm: "二次确认", confirmContent: "确认内容" }, hbMultiSelectModal: { pleaseSelect: "请选择" }, hbListTable: { noData: "暂时没有数据" }, hbLibListTableColumsSet: { popoverTitle: "自定义列", title: "表格字段设置", fix: "固定", cancelFix: "取消固定", allSelect: "全选", confirm: "确定", errorTip: "不能将列移动到固定列位置" }, hbLibListForm: { queryCase: "查询方案" }, HbFileUploadModal: { fileUpload: "文件导入", confirmImport: "确认导入", cancel: "取消", maxSupport: "最多支持", dataImport: "条数据导入", placeSelect: "请选择", file: "文件", selectFile: "请选择上传的文件", dragFile: "将文件拖到此处或", clickUpload: "点击上传", onlySupport: "仅支持", downloadTemplate: "导入模板下载" }, HbLogModal: { close: "关 闭", operateLogs: "操作日志", operator: "操作人", operateTime: "操作时间", operateContent: "操作内容" } }, pa = {
|
|
2412
|
+
hbLibComp: fa
|
|
2413
|
+
}, ma = { HbFileUploadModal: { cancel: "Stornieren", clickUpload: "Klicken Sie zum Hochladen", confirmImport: "Bestätigen Sie den Import", dataImport: "Daten importieren", downloadTemplate: "Importvorlage herunterladen", dragFile: "Ziehen Sie Dateien hierher oder", file: "dokumentieren", fileUpload: "Dateiimport", maxSupport: "Am meisten unterstützt", onlySupport: "Unterstützt nur", placeSelect: "Bitte auswählen", selectFile: "Bitte wählen Sie die hochzuladende Datei aus" }, HbLogModal: { close: "Schließung", operateContent: "Inhalt der Operation", operateLogs: "Betriebsprotokoll", operateTime: "Betriebszeit", operator: "Operator" }, hbFormItemFilterModal: { add: "Hinzufügen zu", cancel: "Stornieren", confirm: "Sicher", moreConditionSearch: "Mehrere Suchanfragen", mostMore: "Höchstens optional", mostMoreTip: "Bedingungen anpassen, per Drag-and-Drop die Sortierung anpassen", noData: "Noch keine Daten", notShowTip: "Keine Bedingungen angezeigt", titleTip: "Bedingungen angezeigt" }, hbFormSelectFilter: { allSelect: "Alles auswählen", close: "Schließung" }, hbLibListForm: { queryCase: "Abfrageplan" }, hbLibListTableColumsSet: { allSelect: "Alles auswählen", cancelFix: "Lösen", confirm: "Sicher", errorTip: "Die Spalte kann nicht in eine feste Spaltenposition verschoben werden", fix: "behoben", popoverTitle: "Benutzerdefinierte Spalten", title: "Tabellenfeldeinstellungen" }, hbListBtnsAct: { close: "Abfragebedingungen schließen", open: "Abfragebedingungen erweitern", reload: "Daten aktualisieren" }, hbListPageAct: { close: "schließen", exitFullScreen: "Verlassen Sie den Vollbildmodus", fullScreen: "Vollbild", open: "Expandieren", query: "Abfrage", reset: "zurücksetzen", selfDefine: "Abfragebedingungen filtern" }, hbListTable: { noData: "Noch keine Daten" }, hbMultiSelectModal: { pleaseSelect: "Bitte auswählen" }, hbTableAct: { confirmContent: "Inhalt bestätigen", more: "Mehr", secendConfirm: "Zweite Bestätigung" } }, va = {
|
|
2414
|
+
hbLibComp: ma
|
|
2238
2415
|
};
|
|
2239
|
-
var pe = { exports: {} },
|
|
2240
|
-
function
|
|
2241
|
-
return
|
|
2242
|
-
(function(
|
|
2243
|
-
|
|
2244
|
-
})(
|
|
2245
|
-
function
|
|
2246
|
-
return
|
|
2416
|
+
var pe = { exports: {} }, ga = pe.exports, We;
|
|
2417
|
+
function ya() {
|
|
2418
|
+
return We || (We = 1, (function(e, d) {
|
|
2419
|
+
(function(u, n) {
|
|
2420
|
+
e.exports = n(Me);
|
|
2421
|
+
})(ga, (function(u) {
|
|
2422
|
+
function n(p) {
|
|
2423
|
+
return p && typeof p == "object" && "default" in p ? p : { default: p };
|
|
2247
2424
|
}
|
|
2248
|
-
var
|
|
2249
|
-
return
|
|
2250
|
-
}, weekStart: 1, yearStart: 4, formats: { LT: "HH:mm", LTS: "HH:mm:ss", L: "YYYY/MM/DD", LL: "YYYY年M月D日", LLL: "YYYY年M月D日Ah点mm分", LLLL: "YYYY年M月D日ddddAh点mm分", l: "YYYY/M/D", ll: "YYYY年M月D日", lll: "YYYY年M月D日 HH:mm", llll: "YYYY年M月D日dddd HH:mm" }, relativeTime: { future: "%s内", past: "%s前", s: "几秒", m: "1 分钟", mm: "%d 分钟", h: "1 小时", hh: "%d 小时", d: "1 天", dd: "%d 天", M: "1 个月", MM: "%d 个月", y: "1 年", yy: "%d 年" }, meridiem: function(
|
|
2251
|
-
var
|
|
2252
|
-
return
|
|
2425
|
+
var _ = n(u), m = { name: "zh-cn", weekdays: "星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"), weekdaysShort: "周日_周一_周二_周三_周四_周五_周六".split("_"), weekdaysMin: "日_一_二_三_四_五_六".split("_"), months: "一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"), monthsShort: "1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"), ordinal: function(p, h) {
|
|
2426
|
+
return h === "W" ? p + "周" : p + "日";
|
|
2427
|
+
}, weekStart: 1, yearStart: 4, formats: { LT: "HH:mm", LTS: "HH:mm:ss", L: "YYYY/MM/DD", LL: "YYYY年M月D日", LLL: "YYYY年M月D日Ah点mm分", LLLL: "YYYY年M月D日ddddAh点mm分", l: "YYYY/M/D", ll: "YYYY年M月D日", lll: "YYYY年M月D日 HH:mm", llll: "YYYY年M月D日dddd HH:mm" }, relativeTime: { future: "%s内", past: "%s前", s: "几秒", m: "1 分钟", mm: "%d 分钟", h: "1 小时", hh: "%d 小时", d: "1 天", dd: "%d 天", M: "1 个月", MM: "%d 个月", y: "1 年", yy: "%d 年" }, meridiem: function(p, h) {
|
|
2428
|
+
var l = 100 * p + h;
|
|
2429
|
+
return l < 600 ? "凌晨" : l < 900 ? "早上" : l < 1100 ? "上午" : l < 1300 ? "中午" : l < 1800 ? "下午" : "晚上";
|
|
2253
2430
|
} };
|
|
2254
|
-
return
|
|
2431
|
+
return _.default.locale(m, null, !0), m;
|
|
2255
2432
|
}));
|
|
2256
2433
|
})(pe)), pe.exports;
|
|
2257
2434
|
}
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
const
|
|
2262
|
-
en_US:
|
|
2263
|
-
ja_JP:
|
|
2264
|
-
zh_CN:
|
|
2265
|
-
de_DE:
|
|
2266
|
-
},
|
|
2267
|
-
Object.keys(
|
|
2268
|
-
|
|
2435
|
+
ya();
|
|
2436
|
+
const Je = ca;
|
|
2437
|
+
Me.locale("zh-cn");
|
|
2438
|
+
const Ma = {
|
|
2439
|
+
en_US: ua,
|
|
2440
|
+
ja_JP: ba,
|
|
2441
|
+
zh_CN: pa,
|
|
2442
|
+
de_DE: va
|
|
2443
|
+
}, Ha = function(e) {
|
|
2444
|
+
Object.keys(Je).forEach((u) => {
|
|
2445
|
+
e.use(Je[u]);
|
|
2269
2446
|
});
|
|
2270
2447
|
};
|
|
2271
2448
|
export {
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
So as locales
|
|
2449
|
+
Ha as install,
|
|
2450
|
+
Ma as locales
|
|
2275
2451
|
};
|