@jeecg/online 3.7.0-beta → 3.7.4-beta

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.
Files changed (150) hide show
  1. package/AccountLoginForm-84cbd344.mjs +254 -0
  2. package/AiModal-26903538.mjs +84 -0
  3. package/AppForgetPassword-52443f23.mjs +310 -0
  4. package/AppLogin-ecf798fa.mjs +287 -0
  5. package/AppLoginHeader-4432c584.mjs +27 -0
  6. package/AppNameEmail-3303a037.mjs +180 -0
  7. package/AppRegister-79a62c59.mjs +303 -0
  8. package/AppTenant-f0bef7ca.mjs +373 -0
  9. package/AppThirdForm-fd8b4604.mjs +189 -0
  10. package/AuthButtonConfig-d5bffca0.mjs +156 -0
  11. package/AuthButtonTree-b0bd6c40.mjs +165 -0
  12. package/{AuthDataConfig-7bb0cd85.mjs → AuthDataConfig-d3b7afa4.mjs} +30 -29
  13. package/{AuthDataTree-6e3bb86f.mjs → AuthDataTree-f14a98d9.mjs} +47 -47
  14. package/AuthFieldConfig-f1e224cc.mjs +245 -0
  15. package/AuthFieldTree-5cc0da05.mjs +232 -0
  16. package/{AuthManagerDrawer-5e2ed5ce.mjs → AuthManagerDrawer-32556109.mjs} +9 -8
  17. package/{AuthSetterModal-6f74449c.mjs → AuthSetterModal-364f1f67.mjs} +12 -11
  18. package/BuiltInButtonList-bb6cf95c.mjs +10 -0
  19. package/BuiltInButtonList.vue_vue_type_script_setup_true_lang-07d0b7d0.mjs +338 -0
  20. package/CgformAddressModal-1131274c.mjs +260 -0
  21. package/CgformCopyList-5fba0810.mjs +252 -0
  22. package/CgformModal-c4a4e0c2.mjs +667 -0
  23. package/{CgreportModal-5a23d089.mjs → CgreportModal-8a84aae5.mjs} +186 -172
  24. package/{CheckDictTable-b5cb0e2b.mjs → CheckDictTable-8a938e3a.mjs} +37 -34
  25. package/CodeFileListModal-a924902a.mjs +159 -0
  26. package/CodeFileViewModal-405e2b58.mjs +253 -0
  27. package/CodeGeneratorModal-2e1dc13d.mjs +281 -0
  28. package/CustomButtonList-c453b654.mjs +274 -0
  29. package/{DBAttributeTable-95dc66c1.mjs → DBAttributeTable-1a45c7b7.mjs} +80 -72
  30. package/DbToOnlineModal-f28ff0a3.mjs +168 -0
  31. package/{DetailForm-4aa2570b.mjs → DetailForm-c592b8d8.mjs} +50 -49
  32. package/DropMenuItem-1e49abea.mjs +44 -0
  33. package/{EnhanceJavaModal-98934198.mjs → EnhanceJavaModal-d5a93f2a.mjs} +62 -62
  34. package/{EnhanceJsHistory-9c4acdaf.mjs → EnhanceJsHistory-8ddb0657.mjs} +35 -35
  35. package/{EnhanceJsModal-247f640d.mjs → EnhanceJsModal-dc4f9ade.mjs} +154 -138
  36. package/{EnhanceSqlModal-65b74b0f.mjs → EnhanceSqlModal-984f045d.mjs} +67 -67
  37. package/ErrorTip-bb616e32.mjs +7 -0
  38. package/ErrorTip.vue_vue_type_script_setup_true_lang-49d35987.mjs +60 -0
  39. package/{ExtendConfigModal-00f2fb55.mjs → ExtendConfigModal-7d70f362.mjs} +2 -2
  40. package/{FieldExtendJsonModal-cc7fce26.mjs → FieldExtendJsonModal-bf04d70e.mjs} +2 -2
  41. package/{FileSelectModal-38660e3c.mjs → FileSelectModal-ffc69d4a.mjs} +23 -23
  42. package/{ForeignKeyTable-a78cb5ad.mjs → ForeignKeyTable-92decaea.mjs} +3 -3
  43. package/{IndexTable-1b496559.mjs → IndexTable-2ded2014.mjs} +28 -20
  44. package/JModalTip-a927f85d.mjs +49 -0
  45. package/JOnlineSearchSelect-04ec87d0.mjs +128 -0
  46. package/{LeftDepart-8ade4bf7.mjs → LeftDepart-52cb6743.mjs} +1 -1
  47. package/LeftRole-b0e0b496.mjs +86 -0
  48. package/{LeftUser-b4d1372a.mjs → LeftUser-dd4b10e2.mjs} +30 -30
  49. package/{LinkTableConfigModal-a138c85e.mjs → LinkTableConfigModal-7eeb3e58.mjs} +43 -31
  50. package/{LinkTableFieldConfigModal-17b413b0.mjs → LinkTableFieldConfigModal-b078fcef.mjs} +1 -1
  51. package/{LinkTableListPiece-2660d709.mjs → LinkTableListPiece-e016b8e6.mjs} +1 -1
  52. package/{ModalFormDemo-0544737d.mjs → ModalFormDemo-aaa719a7.mjs} +1 -1
  53. package/OnlCgformErpList-5c5acdaa.mjs +488 -0
  54. package/OnlCgformErpSubTable-e1b88312.mjs +441 -0
  55. package/{OnlCgformInnerSubTable-290ace5d.mjs → OnlCgformInnerSubTable-6b6fa15a.mjs} +106 -107
  56. package/OnlCgformInnerTableList-b283a525.mjs +474 -0
  57. package/OnlCgformTabList-91e3dd78.mjs +424 -0
  58. package/OnlineAutoList-84475f1b.mjs +513 -0
  59. package/OnlineAutoModal-95f46901.mjs +260 -0
  60. package/OnlineAutoTreeList-20b9ce04.mjs +523 -0
  61. package/OnlineCustomModal-c8b1e780.mjs +232 -0
  62. package/{OnlineDetailModal-2a271e0b.mjs → OnlineDetailModal-5b412bb9.mjs} +74 -65
  63. package/OnlineForm-58282699.mjs +1012 -0
  64. package/{OnlineFormDetail-e036cd11.mjs → OnlineFormDetail-fc087725.mjs} +7 -7
  65. package/{OnlineFormUrlAdd-7fb3dcca.mjs → OnlineFormUrlAdd-bc9105bb.mjs} +10 -10
  66. package/{OnlineFormUrlDetail-b2292137.mjs → OnlineFormUrlDetail-ad912560.mjs} +12 -12
  67. package/{OnlineFormUrlEdit-44080fb3.mjs → OnlineFormUrlEdit-f2fa79ff.mjs} +10 -10
  68. package/OnlineFormUrlSuccess-76813d45.mjs +59 -0
  69. package/OnlineQueryForm-9248341f.mjs +484 -0
  70. package/{OnlineSearchFormItem-6feacae6.mjs → OnlineSearchFormItem-1e437bd3.mjs} +82 -82
  71. package/{OnlineSelectCascade-471fcc76.mjs → OnlineSelectCascade-d631ed72.mjs} +1 -1
  72. package/{OnlineSubFormDetail-03f8ee5c.mjs → OnlineSubFormDetail-8be879b9.mjs} +53 -54
  73. package/{OnlineTabAutoModal-7b9bcd0b.mjs → OnlineTabAutoModal-c9ca3c24.mjs} +108 -95
  74. package/{OnlineTabDetailModal-88143301.mjs → OnlineTabDetailModal-fd4c9a72.mjs} +36 -36
  75. package/OnlineTabForm-1940e88b.mjs +814 -0
  76. package/{OnlineTabFormDetail-bbf23caa.mjs → OnlineTabFormDetail-2aa67564.mjs} +17 -17
  77. package/{PageAttributeTable-6c23547b.mjs → PageAttributeTable-66e7b485.mjs} +169 -149
  78. package/PhoneLoginForm-86437a9d.mjs +214 -0
  79. package/{ProcessOnlineForm-b42198f5.mjs → ProcessOnlineForm-98ede18d.mjs} +64 -58
  80. package/{QueryTable-96b3dbd0.mjs → QueryTable-65d3f54f.mjs} +40 -37
  81. package/SetSwitchOptions-f914bc17.mjs +62 -0
  82. package/ShareAddView-657f0f8b.mjs +86 -0
  83. package/ShareEditView-1b945fd3.mjs +92 -0
  84. package/ShareView-222ed3d8.mjs +80 -0
  85. package/ShareView.vue_vue_type_script_setup_true_lang-44fbeaff.mjs +162 -0
  86. package/SingleView-23b0cb4e.mjs +68 -0
  87. package/SingleView.vue_vue_type_style_index_0_lang-e0f2f6c0.mjs +131 -0
  88. package/SuperQuery-46032e66.mjs +974 -0
  89. package/{SuperQueryValComponent-7ad86d4b.mjs → SuperQueryValComponent-5a9ccfd4.mjs} +1 -1
  90. package/{SuperQueryValComponent.vue_vue_type_script_lang-e9196096.mjs → SuperQueryValComponent.vue_vue_type_script_lang-8fe34917.mjs} +11 -11
  91. package/auth.api-53df4c33.mjs +41 -0
  92. package/{auth.data-22948e87.mjs → auth.data-626c5083.mjs} +68 -30
  93. package/button.data-fe45d43b.mjs +12 -0
  94. package/{cgform.data-475d4984.mjs → cgform.data-0ca62d09.mjs} +4 -1
  95. package/{enhance.data-3304d553.mjs → enhance.data-6601ff44.mjs} +9 -8
  96. package/index-19eaef11.mjs +11 -0
  97. package/index-1a2e8832.mjs +135 -0
  98. package/{index-581bef24.mjs → index-2fb8e07f.mjs} +59 -59
  99. package/index-5e89258d.mjs +8 -0
  100. package/index-9e1e1e53.mjs +57 -0
  101. package/{index-d2abb8a0.mjs → index-a039036e.mjs} +273 -262
  102. package/index-c5a79b0b.mjs +219 -0
  103. package/index-cce225be.mjs +110 -0
  104. package/index-f2c2d1cf.mjs +74 -0
  105. package/main.index.js +1 -1
  106. package/package.json +1 -1
  107. package/shareStore-7de6c7a6.mjs +67 -0
  108. package/style.css +1 -1
  109. package/useCgformList-f3cb9156.mjs +378 -0
  110. package/useExtendComponent-bb98e568.mjs +4460 -0
  111. package/useListButton-98908683.mjs +719 -0
  112. package/{useSchemas-47e45edc.mjs → useSchemas-b074f3a1.mjs} +88 -46
  113. package/useTableSync-075826a1.mjs +89 -0
  114. package/utils-9fce7606.mjs +16 -0
  115. package/AiModal-fe3988fb.mjs +0 -84
  116. package/AuthButtonConfig-d50a0a65.mjs +0 -134
  117. package/AuthButtonTree-589395ed.mjs +0 -156
  118. package/AuthFieldConfig-490fc0ab.mjs +0 -139
  119. package/AuthFieldTree-b7cd091e.mjs +0 -232
  120. package/CgformCopyList-8077ccc6.mjs +0 -250
  121. package/CgformModal-36faf29a.mjs +0 -621
  122. package/CodeFileListModal-0e26b7e0.mjs +0 -158
  123. package/CodeFileViewModal-9d4a5b5f.mjs +0 -248
  124. package/CodeGeneratorModal-b722d976.mjs +0 -238
  125. package/CustomButtonList-37639061.mjs +0 -381
  126. package/DbToOnlineModal-f49b9530.mjs +0 -166
  127. package/JModalTip-4a83aaed.mjs +0 -49
  128. package/JOnlineSearchSelect-34a37ec9.mjs +0 -95
  129. package/LeftRole-7d8c5acc.mjs +0 -86
  130. package/OnlCgformErpList-30e416c8.mjs +0 -470
  131. package/OnlCgformErpSubTable-9a876058.mjs +0 -427
  132. package/OnlCgformInnerTableList-f89b6687.mjs +0 -458
  133. package/OnlCgformTabList-7a2f2c03.mjs +0 -408
  134. package/OnlineAutoList-46c6c8b9.mjs +0 -493
  135. package/OnlineAutoModal-971bef13.mjs +0 -236
  136. package/OnlineAutoTreeList-3b92454c.mjs +0 -502
  137. package/OnlineCustomModal-594244f3.mjs +0 -232
  138. package/OnlineForm-018981b2.mjs +0 -924
  139. package/OnlineFormUrlSuccess-af285b02.mjs +0 -59
  140. package/OnlineQueryForm-998c12a4.mjs +0 -444
  141. package/OnlineTabForm-9ad7d29a.mjs +0 -805
  142. package/SetSwitchOptions-a452fa0f.mjs +0 -62
  143. package/SuperQuery-cbfba908.mjs +0 -975
  144. package/auth.api-d3a6c4b3.mjs +0 -39
  145. package/index-173949bb.mjs +0 -57
  146. package/useCgformList-8755a94e.mjs +0 -426
  147. package/useExtendComponent-bb7cca20.mjs +0 -4295
  148. package/useListButton-7ddb9a46.mjs +0 -697
  149. package/useTableSync-f6089e8a.mjs +0 -87
  150. /package/{OnlineForm.vue_vue_type_style_index_0_scoped_0f9f2964_lang-4ed993c7.mjs → OnlineForm.vue_vue_type_style_index_0_scoped_3f26e7bd_lang-4ed993c7.mjs} +0 -0
@@ -1,975 +0,0 @@
1
- var ke = Object.defineProperty, we = Object.defineProperties;
2
- var De = Object.getOwnPropertyDescriptors;
3
- var me = Object.getOwnPropertySymbols;
4
- var be = Object.prototype.hasOwnProperty, Te = Object.prototype.propertyIsEnumerable;
5
- var ve = (p, d, E) => d in p ? ke(p, d, { enumerable: !0, configurable: !0, writable: !0, value: E }) : p[d] = E, $ = (p, d) => {
6
- for (var E in d || (d = {}))
7
- be.call(d, E) && ve(p, E, d[E]);
8
- if (me)
9
- for (var E of me(d))
10
- Te.call(d, E) && ve(p, E, d[E]);
11
- return p;
12
- }, ee = (p, d) => we(p, De(d));
13
- import { ref as O, reactive as _e, watch as ae, toRaw as ye, computed as Oe, resolveComponent as m, openBlock as x, createElementBlock as he, Fragment as ge, createElementVNode as w, createBlock as V, withCtx as i, createVNode as a, createTextVNode as S, Teleport as xe, createCommentVNode as Be, normalizeClass as fe, withDirectives as Ce, vShow as Se, normalizeStyle as Me, renderList as Pe, toDisplayString as Ie, pushScopeId as Ae, popScopeId as Ve } from "vue";
14
- import { useModalInner as Re, BasicModal as Ne, useModal as Qe } from "/@/components/Modal";
15
- import { randomString as re } from "/@/utils/common/compUtils";
16
- import { useMessage as Ee } from "/@/hooks/web/useMessage";
17
- import { Modal as je, Divider as qe, Empty as Le } from "ant-design-vue";
18
- import { createLocalStorage as Ye } from "/@/utils/cache";
19
- import { useRoute as Je } from "vue-router";
20
- import { i as He, F as Ue, j as pe } from "./useExtendComponent-bb7cca20.mjs";
21
- import { cloneDeep as ue } from "lodash-es";
22
- import { _ as Ke } from "./SuperQueryValComponent.vue_vue_type_script_lang-e9196096.mjs";
23
- import { MinusCircleOutlined as ze, PlusOutlined as We, FileTextOutlined as Ge, CloseCircleOutlined as Xe, AppstoreTwoTone as Ze } from "@ant-design/icons-vue";
24
- import { useDesign as $e } from "/@/hooks/web/useDesign";
25
- import { _ as et } from "./index-173949bb.mjs";
26
- import "/@/components/Form/src/componentMap";
27
- import "/@/utils/propTypes";
28
- import "/@/components/Form/index";
29
- import "/@/utils/http/axios";
30
- import "./constant-fa63bd66.mjs";
31
- import "/@/components/Form/src/jeecg/components/JUpload";
32
- import "/@/utils/is";
33
- import "/@/views/system/user/user.api";
34
- import "/@/store/modules/user";
35
- import "/@/utils";
36
- import "/@/utils/desform/customExpression";
37
- import "/@/store/modules/permission";
38
- import "/@/utils/dict/JDictSelectUtil";
39
- import "/@/components/Table";
40
- import "/@/hooks/system/useListPage";
41
- import "/@/components/Form/src/utils/Area";
42
- import "/@/components/Preview/index";
43
- import "./LinkTableListPiece-2660d709.mjs";
44
- import "/@/utils/auth";
45
- import "/@/api/common/api";
46
- import "/@/hooks/web/useAppInject";
47
- import "/@/assets/images/placeholderImage.png";
48
- import "./OnlineSelectCascade-471fcc76.mjs";
49
- import "/@/components/Loading";
50
- import "./JModalTip-4a83aaed.mjs";
51
- import "@vueuse/core";
52
- import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
53
- const tt = {
54
- password: "text",
55
- file: "text",
56
- image: "text",
57
- textarea: "text",
58
- umeditor: "text",
59
- markdown: "text",
60
- checkbox: "list_multi",
61
- radio: "list"
62
- }, lt = "JSuperQuerySaved_";
63
- function ot(p) {
64
- const { linkTableCard2Select: d } = He(), { createMessage: E } = Ee(), o = O(), k = _e({
65
- values: []
66
- }), I = O("and"), B = O(!1), [te, { setModalProps: D }] = Re(() => {
67
- D({ confirmLoading: !1 });
68
- }), J = Object.assign({}, { link_down: "text" }, tt);
69
- function R() {
70
- }
71
- function H() {
72
- }
73
- function U(t, l, r) {
74
- r.val = l;
75
- }
76
- const g = O({}), A = O([]), M = (t) => {
77
- const { properties: l = {} } = t;
78
- Object.entries(l).forEach(([r, n]) => {
79
- n.view === "table" && M(n), ["image", "password", "file"].includes(n.originView || n.view) && delete l[r];
80
- });
81
- };
82
- function K(t) {
83
- M(t);
84
- let { allFields: l, treeData: r } = ce(t);
85
- g.value = l, A.value = r;
86
- }
87
- function z(t) {
88
- let l = {
89
- field: void 0,
90
- rule: "eq",
91
- val: "",
92
- key: re(16)
93
- };
94
- t === !1 ? (k.values = [], k.values.push(l)) : t === !0 ? k.values.length == 0 && k.values.push(l) : k.values.splice(++t, 0, l);
95
- }
96
- function le(t) {
97
- let l = ye(k.values), r = -1;
98
- for (let n = 0; n < l.length; n++)
99
- if (t.key == l[n].key) {
100
- r = n;
101
- break;
102
- }
103
- r != -1 && k.values.splice(r, 1);
104
- }
105
- const W = {
106
- field: "val",
107
- label: "测试",
108
- component: "Input"
109
- };
110
- function j(t, l) {
111
- var s, v, y;
112
- let n = g.value[t.field];
113
- if (!n)
114
- return W;
115
- J[n.view] && (n.view = J[n.view]);
116
- let _ = Ue.createFormSchema(t.field, n);
117
- _.noChange(), _.asSearchForm(), _.updateField(t.field + l);
118
- const f = (c) => {
119
- t.val = c[t.field];
120
- };
121
- _.setFunctionForFieldValue(f);
122
- let e = _.getFormItemSchema();
123
- if (["empty", "not_empty"].includes(t.rule) && (e.componentProps = ee($({}, e.componentProps), { disabled: !0 })), d(e), e.component === "LinkTableSelect") {
124
- let c = (s = e.componentProps) != null ? s : {};
125
- e.componentProps = ee($({}, c), { editBtnShow: !1 });
126
- }
127
- if (e && e.component === "InputNumber" && (t.curLineAlign = "start"), (e == null ? void 0 : e.component) === "JTreeSelect") {
128
- let c = e.componentProps;
129
- c ? c.getPopupContainer = () => document.body : e.componentProps = { getPopupContainer: () => document.body };
130
- }
131
- if ((e == null ? void 0 : e.component) === "JSwitch") {
132
- const c = (v = e.componentProps) != null ? v : {};
133
- e.componentProps = ee($({}, c), { query: !0 });
134
- }
135
- if ((e == null ? void 0 : e.component) === "JSelectUser") {
136
- const c = (y = e.componentProps) != null ? y : {};
137
- e.componentProps = ee($({}, c), { showButton: !1 });
138
- }
139
- return e;
140
- }
141
- const N = O(""), q = Ye(), b = _e({
142
- visible: !1,
143
- title: "",
144
- content: "",
145
- saveCode: ""
146
- }), oe = O(!1), G = Je();
147
- p.isCustomSave ? ae(p.saveSearchData, () => {
148
- F.value = p.saveSearchData;
149
- }) : ae(() => G.fullPath, (t) => {
150
- L();
151
- });
152
- const F = O([]);
153
- ae(() => F.value, (t) => {
154
- let l = [];
155
- t && t.length > 0 && t.map((r) => {
156
- let n = re(16);
157
- l.push({
158
- title: r.title,
159
- slots: { icon: "custom" },
160
- value: n
161
- });
162
- }), N.value = l;
163
- }, { immediate: !0, deep: !0 });
164
- function L() {
165
- if (p.isCustomSave)
166
- F.value = ue(p.saveSearchData);
167
- else {
168
- let t = lt + G.fullPath;
169
- b.saveCode = t;
170
- let l = q.get(t);
171
- l && l instanceof Array && (F.value = l);
172
- }
173
- }
174
- L();
175
- function ne() {
176
- let t = u();
177
- if (!t) {
178
- E.warning("空条件不能保存");
179
- return;
180
- }
181
- let l = JSON.stringify(t);
182
- Q(l);
183
- }
184
- function Q(t) {
185
- b.visible = !0, b.title = "", b.content = t;
186
- }
187
- function Y() {
188
- let { title: t, content: l, saveCode: r } = b, n = X(t);
189
- const _ = (f) => {
190
- const e = ue(F.value);
191
- B.value = !0, f ? e.splice(n, 1, {
192
- content: l,
193
- title: t,
194
- type: I.value
195
- }) : e.push({
196
- content: l,
197
- title: t,
198
- type: I.value
199
- });
200
- const s = () => {
201
- b.visible = !1, E.success("保存成功"), F.value = e, B.value = !1;
202
- };
203
- p.isCustomSave ? p.save(e, 0).then(() => {
204
- s();
205
- }).catch((v) => {
206
- B.value = !1;
207
- }) : (q.set(r, e, 2592e3), s());
208
- };
209
- n >= 0 ? je.confirm({
210
- title: "提示",
211
- content: `${t} 已存在,是否覆盖?`,
212
- okText: "确认",
213
- cancelText: "取消",
214
- onOk: () => {
215
- _(1);
216
- }
217
- }) : _(0);
218
- }
219
- function X(t) {
220
- let l = F.value, r = -1;
221
- for (let n = 0; n < l.length; n++)
222
- if (l[n].title == t) {
223
- r = n;
224
- break;
225
- }
226
- return r;
227
- }
228
- function u(t = !1) {
229
- var _;
230
- let l = k.values;
231
- if (!l || l.length == 0)
232
- return !1;
233
- let r = [], n = g.value;
234
- for (let f of l) {
235
- let e = ["empty", "not_empty"].includes(f.rule);
236
- if (f.field && (e || f.val || f.val === 0) && f.rule) {
237
- let s = n[f.field], v = (_ = s == null ? void 0 : s.formatValue) != null ? _ : (C) => C, y = ye(f.val);
238
- y instanceof Array ? y = y.map((C) => v(C)).join(",") : y = v(y);
239
- let h = {
240
- field: P(f),
241
- rule: f.rule,
242
- val: y,
243
- fileType: f.fileType
244
- };
245
- if (t === !0) {
246
- let C = n[f.field];
247
- C && (h.type = C.view, h.dbType = C.type);
248
- }
249
- r.push(h);
250
- }
251
- }
252
- return r.length == 0 ? !1 : r;
253
- }
254
- function P(t) {
255
- let l = t.field;
256
- return l.indexOf("@") > 0 && (l = l.replace("@", ",")), l;
257
- }
258
- function T(t, { node: l }) {
259
- let r = l.dataRef.title, n = F.value.filter((_) => _.title == r);
260
- if (n && n.length > 0) {
261
- let { content: _, type: f } = n[0], e = JSON.parse(_), s = [];
262
- for (let v of e)
263
- v.field = v.field.replace(",", "@"), s.push(Object.assign({}, { key: re(16) }, v));
264
- k.values = s, I.value = f;
265
- }
266
- }
267
- function Z(t) {
268
- let l = X(t);
269
- if (l >= 0)
270
- if (p.isCustomSave) {
271
- const r = ue(F.value);
272
- r.splice(l, 1), p.save(r, 1).then(() => {
273
- F.value = r;
274
- }).catch((n) => {
275
- });
276
- } else
277
- F.value.splice(l, 1), q.set(b.saveCode, F.value);
278
- }
279
- function ce(t) {
280
- let l = {}, r = 1, n = [];
281
- return t.properties && (t = t.properties), Object.keys(t).map((_) => {
282
- let f = t[_];
283
- if (f.view == "table") {
284
- let e = f.properties || f.fields, s = r * 100, v = {
285
- title: f.title,
286
- value: _,
287
- disabled: !0,
288
- children: [],
289
- order: s,
290
- // update-begin--author:liaozhiyang---date:20240306---for:【TV360X-461】字段类型是string,则默认模糊查询
291
- fieldType: f.type
292
- // update-end--author:liaozhiyang---date:20240306---for:【TV360X-461】字段类型是string,则默认模糊查询
293
- };
294
- Object.keys(e).map((y) => {
295
- let c = e[y];
296
- c.order = s + c.order;
297
- let h = _ + "@" + y;
298
- l[h] = c, v.children.push({
299
- title: c.title,
300
- value: h,
301
- isLeaf: !0,
302
- order: c.order,
303
- // update-begin--author:liaozhiyang---date:20240306---for:【TV360X-461】字段类型是string,则默认模糊查询
304
- fieldType: c.type,
305
- view: c.view,
306
- originView: c.view
307
- // update-end--author:liaozhiyang---date:20240306---for:【TV360X-461】字段类型是string,则默认模糊查询
308
- });
309
- }), ie(v), n.push(v), r++;
310
- } else {
311
- let e = _;
312
- l[e] = f, n.push({
313
- title: f.title,
314
- value: e,
315
- isLeaf: !0,
316
- order: f.order,
317
- // update-begin--author:liaozhiyang---date:20240306---for:【TV360X-461】字段类型是string,则默认模糊查询
318
- fieldType: f.type,
319
- view: f.view,
320
- originView: f.view
321
- // update-end--author:liaozhiyang---date:20240306---for:【TV360X-461】字段类型是string,则默认模糊查询
322
- });
323
- }
324
- }), ie(n), { allFields: l, treeData: n };
325
- }
326
- function ie(t) {
327
- (t.children || t).sort(function(r, n) {
328
- return r.order - n.order;
329
- });
330
- }
331
- function de(t) {
332
- const { params: l, matchType: r } = t;
333
- if (l) {
334
- let n = [];
335
- for (let _ of l)
336
- n.push(Object.assign({}, { key: re(16) }, _));
337
- k.values = n, r.value = r;
338
- }
339
- }
340
- return {
341
- formRef: o,
342
- init: K,
343
- dynamicRowValues: k,
344
- matchType: I,
345
- registerModal: te,
346
- handleSubmit: R,
347
- handleCancel: H,
348
- handleSave: ne,
349
- doSaveQueryInfo: Y,
350
- saveInfo: b,
351
- saveTreeData: N,
352
- handleRemoveSaveInfo: Z,
353
- handleTreeSelect: T,
354
- fieldTreeData: A,
355
- addOne: z,
356
- removeOne: le,
357
- setFormModel: U,
358
- getSchema: j,
359
- loading: oe,
360
- getQueryInfo: u,
361
- initDefaultValues: de,
362
- saveModalLoading: B,
363
- fieldProperties: g
364
- };
365
- }
366
- const nt = {
367
- name: "OnlineSuperQuery",
368
- props: {
369
- config: {
370
- type: Object,
371
- default: []
372
- },
373
- status: {
374
- type: Boolean,
375
- default: !1
376
- },
377
- online: {
378
- type: Boolean,
379
- default: !1
380
- },
381
- // update-begin--author:liaozhiyang---date:20240514---for:【issues/6205】高级查询组件增加保存条件自定义存储方式
382
- isCustomSave: {
383
- type: Boolean,
384
- default: !1
385
- },
386
- saveSearchData: {
387
- type: Array,
388
- default: () => []
389
- },
390
- save: {
391
- type: Function
392
- }
393
- // update-end--author:liaozhiyang---date:20240514---for:【issues/6205】高级查询组件增加保存条件自定义存储方式
394
- },
395
- components: {
396
- BasicModal: Ne,
397
- MinusCircleOutlined: ze,
398
- PlusOutlined: We,
399
- OnlineSuperQueryValComponent: Ke,
400
- FileTextOutlined: Ge,
401
- CloseCircleOutlined: Xe,
402
- AppstoreTwoTone: Ze,
403
- Divider: qe
404
- },
405
- emits: ["search"],
406
- setup(p, { emit: d }) {
407
- const [E, o] = Qe(), { createMessage: k } = Ee(), I = O({}), B = O(180), { prefixCls: te } = $e("super-query"), D = `${te}-tree-popup`, J = O(!0);
408
- let R = null;
409
- function H() {
410
- o.closeModal();
411
- }
412
- function U() {
413
- if (p.online === !0) {
414
- let e = Z(!0);
415
- e && e.length > 0 ? (g(e), d("search", e, N.value), H(), R = e) : k.warning("空条件无法查询!");
416
- } else {
417
- let e = Z(!0);
418
- if (e && e.length > 0) {
419
- let s = A(e);
420
- d("search", s);
421
- } else
422
- k.warning("空条件无法查询!");
423
- }
424
- }
425
- const g = (e) => {
426
- e.forEach((s) => {
427
- const v = s.val;
428
- if (s.type === "date" && typeof v == "string" && v != "") {
429
- const y = de.value[s.field];
430
- if (y) {
431
- let c = y.fieldExtendJson;
432
- if (c && (c = JSON.parse(c), c.picker && c.picker !== "default")) {
433
- const h = c.picker;
434
- h === "year" ? s.val = pe(v).set("month", 0).set("date", 1).format("YYYY-MM-DD") : h === "month" ? s.val = pe(v).set("date", 1).format("YYYY-MM-DD") : h === "week" && (s.val = pe(v).startOf("week").format("YYYY-MM-DD"));
435
- }
436
- }
437
- }
438
- });
439
- };
440
- function A(e) {
441
- let s = [];
442
- for (let y of e) {
443
- let c = y.field, h = y.val;
444
- h instanceof Array && (h = h.join(",")), s.push(ee($({}, y), {
445
- field: c,
446
- val: h
447
- }));
448
- }
449
- return s.length > 0 ? t.value = !0 : t.value = !1, {
450
- superQueryMatchType: N.value,
451
- superQueryParams: encodeURI(JSON.stringify(s))
452
- };
453
- }
454
- function M() {
455
- let e = A([]);
456
- d("search", e);
457
- }
458
- function K() {
459
- j.values = [], Y(!1);
460
- let e = A([]);
461
- R = null, d("search", e);
462
- }
463
- const z = (e) => {
464
- if (e) {
465
- const s = document.documentElement.clientHeight - 165;
466
- I.value = { maxHeight: `${s}px` }, B.value = s * 0.62;
467
- } else
468
- I.value = {}, B.value = 180;
469
- }, {
470
- formRef: le,
471
- init: W,
472
- dynamicRowValues: j,
473
- matchType: N,
474
- registerModal: q,
475
- handleSave: b,
476
- doSaveQueryInfo: oe,
477
- saveInfo: G,
478
- saveTreeData: F,
479
- handleTreeSelect: L,
480
- handleRemoveSaveInfo: ne,
481
- fieldTreeData: Q,
482
- addOne: Y,
483
- removeOne: X,
484
- setFormModel: u,
485
- getSchema: P,
486
- loading: T,
487
- getQueryInfo: Z,
488
- initDefaultValues: ce,
489
- saveModalLoading: ie,
490
- fieldProperties: de
491
- } = ot(p), t = O(!1);
492
- ae(() => p.status, (e) => {
493
- t.value = e;
494
- }, { immediate: !0 });
495
- function l() {
496
- t.value && R && (j.values = ue(R)), o.openModal(), Y(!0);
497
- }
498
- function r() {
499
- return document.getElementsByClassName("jee-super-query-form")[0];
500
- }
501
- function n(e) {
502
- }
503
- function _(e) {
504
- var v, y;
505
- e.val = "";
506
- const s = (c, h) => {
507
- const C = c.find((Fe) => Fe.value === h);
508
- (C == null ? void 0 : C.fieldType) === "string" && ["text"].includes((C == null ? void 0 : C.originView) || (C == null ? void 0 : C.view)) ? e.rule = "like" : e.rule = "eq";
509
- };
510
- if (((v = e.field) == null ? void 0 : v.indexOf("@")) == -1)
511
- s(Q.value, e.field);
512
- else {
513
- const c = e.field.split("@")[0], h = Q.value.find((C) => C.value === c);
514
- (y = h == null ? void 0 : h.children) != null && y.length && s(h.children, e.field);
515
- }
516
- }
517
- ae(() => p.config, (e) => {
518
- e && W(e);
519
- }, { immediate: !0 });
520
- const f = Oe(() => Q.value.find((s) => s.children) ? `${D} containTable` : `${D} noTable`);
521
- return {
522
- formRef: le,
523
- registerFormModal: E,
524
- init: W,
525
- handleChangeField: _,
526
- dynamicRowValues: j,
527
- matchType: N,
528
- historyCollapsed: J,
529
- registerModal: q,
530
- handleSubmit: U,
531
- handleCancel: H,
532
- handleSave: b,
533
- handleReset: K,
534
- doSaveQueryInfo: oe,
535
- saveInfo: G,
536
- saveTreeData: F,
537
- handleTreeSelect: L,
538
- handleRemoveSaveInfo: ne,
539
- fieldTreeData: Q,
540
- addOne: Y,
541
- removeOne: X,
542
- setFormModel: u,
543
- getSchema: P,
544
- loading: T,
545
- onFinish: n,
546
- getPopupContainer: r,
547
- superQueryFlag: t,
548
- handleOpen: l,
549
- initDefaultValues: ce,
550
- simpleImage: Le.PRESENTED_IMAGE_SIMPLE,
551
- saveModalLoading: ie,
552
- queryFormStyle: I,
553
- handleFullScreen: z,
554
- fieldTreeSelectHeight: B,
555
- getTreePopupClass: f,
556
- handleStop: M
557
- };
558
- }
559
- };
560
- const se = (p) => (Ae("data-v-79039fe8"), p = p(), Ve(), p), at = { class: "j-super-query-button" }, it = /* @__PURE__ */ se(() => /* @__PURE__ */ w("span", null, "执行查询中...", -1)), rt = /* @__PURE__ */ se(() => /* @__PURE__ */ w("span", null, "高级查询", -1)), ut = { style: { float: "left" } }, st = { slot: "description" }, ct = /* @__PURE__ */ se(() => /* @__PURE__ */ w("span", null, "没有任何查询条件", -1)), dt = /* @__PURE__ */ se(() => /* @__PURE__ */ w("div", null, "保存的查询", -1)), ft = ["title"], pt = { class: "icon-cancle" }, mt = { style: { height: "80px", "line-height": "75px", width: "100%", "text-align": "center" } };
561
- function vt(p, d, E, o, k, I) {
562
- const B = m("divider"), te = m("AppstoreTwoTone"), D = m("a-button"), J = m("a-button-group"), R = m("a-tooltip"), H = m("a-divider"), U = m("a-empty"), g = m("a-select-option"), A = m("a-select"), M = m("a-form-item"), K = m("a-col"), z = m("a-row"), le = m("a-tree-select"), W = m("online-super-query-val-component"), j = m("PlusOutlined"), N = m("MinusCircleOutlined"), q = m("a-space"), b = m("a-form"), oe = m("close-circle-outlined"), G = m("file-text-outlined"), F = m("a-tree"), L = m("Icon"), ne = m("a-card"), Q = m("BasicModal"), Y = m("a-input"), X = m("a-modal");
563
- return x(), he(ge, null, [
564
- w("div", at, [
565
- o.superQueryFlag ? (x(), V(R, {
566
- key: 0,
567
- mouseLeaveDelay: 0.2
568
- }, {
569
- title: i(() => [
570
- it,
571
- a(B, {
572
- type: "vertical",
573
- style: { "background-color": "#fff" }
574
- }),
575
- w("a", {
576
- onClick: d[0] || (d[0] = (...u) => o.handleStop && o.handleStop(...u))
577
- }, "取消查询")
578
- ]),
579
- default: i(() => [
580
- a(J, null, {
581
- default: i(() => [
582
- a(D, {
583
- type: "primary",
584
- onClick: o.handleOpen
585
- }, {
586
- default: i(() => [
587
- a(te, { spin: !0 }),
588
- rt
589
- ]),
590
- _: 1
591
- }, 8, ["onClick"])
592
- ]),
593
- _: 1
594
- })
595
- ]),
596
- _: 1
597
- })) : (x(), V(D, {
598
- key: 1,
599
- type: "primary",
600
- preIcon: "ant-design:filter-outlined",
601
- onClick: o.handleOpen
602
- }, {
603
- default: i(() => [
604
- S(" 高级查询 ")
605
- ]),
606
- _: 1
607
- }, 8, ["onClick"]))
608
- ]),
609
- (x(), V(xe, { to: "body" }, [
610
- a(Q, {
611
- title: "高级查询构造器",
612
- canFullscreen: !0,
613
- width: 850,
614
- onRegister: o.registerFormModal,
615
- onOk: o.handleSubmit,
616
- onFullScreen: o.handleFullScreen
617
- }, {
618
- footer: i(() => [
619
- w("div", ut, [
620
- a(D, {
621
- loading: o.loading,
622
- onClick: o.handleReset
623
- }, {
624
- default: i(() => [
625
- S("清空")
626
- ]),
627
- _: 1
628
- }, 8, ["loading", "onClick"]),
629
- a(D, {
630
- loading: o.loading,
631
- onClick: o.handleSave
632
- }, {
633
- default: i(() => [
634
- S("保存查询")
635
- ]),
636
- _: 1
637
- }, 8, ["loading", "onClick"])
638
- ]),
639
- a(D, {
640
- key: "submit",
641
- type: "primary",
642
- onClick: o.handleSubmit
643
- }, {
644
- default: i(() => [
645
- S("执行查询")
646
- ]),
647
- _: 1
648
- }, 8, ["onClick"]),
649
- a(D, {
650
- key: "back",
651
- onClick: o.handleCancel
652
- }, {
653
- default: i(() => [
654
- S("关闭")
655
- ]),
656
- _: 1
657
- }, 8, ["onClick"])
658
- ]),
659
- default: i(() => [
660
- o.dynamicRowValues.values.length == 0 ? (x(), V(U, { key: 0 }, {
661
- default: i(() => [
662
- w("div", st, [
663
- ct,
664
- a(H, { type: "vertical" }),
665
- w("a", {
666
- onClick: d[1] || (d[1] = (u) => o.addOne(-1))
667
- }, "点击新增")
668
- ])
669
- ]),
670
- _: 1
671
- })) : Be("", !0),
672
- a(z, {
673
- class: fe("j-super-query-modal-content")
674
- }, {
675
- default: i(() => [
676
- a(K, {
677
- sm: 24,
678
- md: 24
679
- }, {
680
- default: i(() => [
681
- Ce(a(z, null, {
682
- default: i(() => [
683
- a(K, {
684
- md: 12,
685
- xs: 24
686
- }, {
687
- default: i(() => [
688
- a(M, {
689
- label: "匹配模式",
690
- labelCol: { md: 6, xs: 24 },
691
- wrapperCol: { md: 18, xs: 24 },
692
- style: { width: "100%" }
693
- }, {
694
- default: i(() => [
695
- a(A, {
696
- value: o.matchType,
697
- "onUpdate:value": d[2] || (d[2] = (u) => o.matchType = u),
698
- getPopupContainer: (u) => u == null ? void 0 : u.parentNode,
699
- style: { width: "100%" }
700
- }, {
701
- default: i(() => [
702
- a(g, { value: "and" }, {
703
- default: i(() => [
704
- S("AND(所有条件匹配)")
705
- ]),
706
- _: 1
707
- }),
708
- a(g, { value: "or" }, {
709
- default: i(() => [
710
- S("OR(任意一个匹配)")
711
- ]),
712
- _: 1
713
- })
714
- ]),
715
- _: 1
716
- }, 8, ["value", "getPopupContainer"])
717
- ]),
718
- _: 1
719
- })
720
- ]),
721
- _: 1
722
- })
723
- ]),
724
- _: 1
725
- }, 512), [
726
- [Se, o.dynamicRowValues.values.length > 0]
727
- ]),
728
- Ce(a(b, {
729
- ref: "formRef",
730
- class: fe("jee-super-query-form"),
731
- model: o.dynamicRowValues,
732
- onFinish: o.onFinish,
733
- style: Me(o.queryFormStyle)
734
- }, {
735
- default: i(() => [
736
- (x(!0), he(ge, null, Pe(o.dynamicRowValues.values, (u, P) => (x(), V(q, {
737
- key: u.key,
738
- style: { display: "flex", "margin-bottom": "8px" },
739
- align: u.curLineAlign ? u.align : "baseline"
740
- }, {
741
- default: i(() => [
742
- a(M, {
743
- class: "field-clos",
744
- name: ["values", P, "field"]
745
- }, {
746
- default: i(() => [
747
- a(le, {
748
- popupClassName: o.getTreePopupClass,
749
- style: { width: "100%" },
750
- placeholder: "请选择字段",
751
- value: u.field,
752
- "onUpdate:value": (T) => u.field = T,
753
- "show-search": "",
754
- "tree-node-filter-prop": "title",
755
- "allow-clear": "",
756
- "tree-default-expand-all": "",
757
- "dropdown-style": { maxHeight: `${o.fieldTreeSelectHeight}px`, overflow: "auto" },
758
- listHeight: o.fieldTreeSelectHeight - 20,
759
- onChange: (T) => o.handleChangeField(u),
760
- "tree-data": o.fieldTreeData
761
- }, null, 8, ["popupClassName", "value", "onUpdate:value", "dropdown-style", "listHeight", "onChange", "tree-data"])
762
- ]),
763
- _: 2
764
- }, 1032, ["name"]),
765
- a(M, {
766
- class: "rule-clos",
767
- name: ["values", P, "rule"]
768
- }, {
769
- default: i(() => [
770
- a(A, {
771
- style: { width: "100%" },
772
- placeholder: "请选择匹配规则",
773
- value: u.rule,
774
- "onUpdate:value": (T) => u.rule = T
775
- }, {
776
- default: i(() => [
777
- a(g, { value: "eq" }, {
778
- default: i(() => [
779
- S("等于")
780
- ]),
781
- _: 1
782
- }),
783
- a(g, { value: "like" }, {
784
- default: i(() => [
785
- S("模糊")
786
- ]),
787
- _: 1
788
- }),
789
- a(g, { value: "right_like" }, {
790
- default: i(() => [
791
- S("以..开始")
792
- ]),
793
- _: 1
794
- }),
795
- a(g, { value: "left_like" }, {
796
- default: i(() => [
797
- S("以..结尾")
798
- ]),
799
- _: 1
800
- }),
801
- a(g, { value: "in" }, {
802
- default: i(() => [
803
- S("在...中")
804
- ]),
805
- _: 1
806
- }),
807
- a(g, { value: "ne" }, {
808
- default: i(() => [
809
- S("不等于")
810
- ]),
811
- _: 1
812
- }),
813
- a(g, { value: "gt" }, {
814
- default: i(() => [
815
- S("大于")
816
- ]),
817
- _: 1
818
- }),
819
- a(g, { value: "ge" }, {
820
- default: i(() => [
821
- S("大于等于")
822
- ]),
823
- _: 1
824
- }),
825
- a(g, { value: "lt" }, {
826
- default: i(() => [
827
- S("小于")
828
- ]),
829
- _: 1
830
- }),
831
- a(g, { value: "le" }, {
832
- default: i(() => [
833
- S("小于等于")
834
- ]),
835
- _: 1
836
- })
837
- ]),
838
- _: 2
839
- }, 1032, ["value", "onUpdate:value"])
840
- ]),
841
- _: 2
842
- }, 1032, ["name"]),
843
- a(M, {
844
- class: "component-clos",
845
- name: ["values", P, "val"]
846
- }, {
847
- default: i(() => [
848
- a(W, {
849
- style: { width: "100%" },
850
- schema: o.getSchema(u, P),
851
- formModel: u,
852
- setFormModel: (T, Z) => {
853
- o.setFormModel(T, Z, u);
854
- },
855
- onSubmit: o.handleSubmit
856
- }, null, 8, ["schema", "formModel", "setFormModel", "onSubmit"])
857
- ]),
858
- _: 2
859
- }, 1032, ["name"]),
860
- a(M, null, {
861
- default: i(() => [
862
- a(D, {
863
- onClick: (T) => o.addOne(P),
864
- style: { "margin-right": "6px" }
865
- }, {
866
- default: i(() => [
867
- a(j)
868
- ]),
869
- _: 2
870
- }, 1032, ["onClick"]),
871
- a(D, {
872
- onClick: (T) => o.removeOne(u)
873
- }, {
874
- default: i(() => [
875
- a(N)
876
- ]),
877
- _: 2
878
- }, 1032, ["onClick"])
879
- ]),
880
- _: 2
881
- }, 1024)
882
- ]),
883
- _: 2
884
- }, 1032, ["align"]))), 128))
885
- ]),
886
- _: 1
887
- }, 8, ["model", "onFinish", "style"]), [
888
- [Se, o.dynamicRowValues.values.length > 0]
889
- ])
890
- ]),
891
- _: 1
892
- })
893
- ]),
894
- _: 1
895
- }),
896
- a(ne, {
897
- class: fe(["j-super-query-history-card", { collapsed: o.historyCollapsed }]),
898
- bordered: !1
899
- }, {
900
- title: i(() => [
901
- dt
902
- ]),
903
- default: i(() => [
904
- o.saveTreeData.length === 0 ? (x(), V(U, {
905
- key: 0,
906
- class: "j-super-query-history-empty",
907
- image: o.simpleImage,
908
- description: "没有保存的查询"
909
- }, null, 8, ["image"])) : (x(), V(F, {
910
- key: 1,
911
- class: "j-super-query-history-tree",
912
- treeData: o.saveTreeData,
913
- selectedKeys: [],
914
- "show-icon": !0,
915
- onSelect: o.handleTreeSelect
916
- }, {
917
- title: i(({ title: u }) => [
918
- w("div", null, [
919
- w("span", { title: u }, Ie(u.length > 10 ? u.substring(0, 10) + "..." : u), 9, ft),
920
- w("span", pt, [
921
- a(oe, {
922
- onClick: (P) => o.handleRemoveSaveInfo(u)
923
- }, null, 8, ["onClick"])
924
- ])
925
- ])
926
- ]),
927
- custom: i(() => [
928
- a(G)
929
- ]),
930
- _: 1
931
- }, 8, ["treeData", "onSelect"])),
932
- w("div", {
933
- class: "collapse-box",
934
- onClick: d[3] || (d[3] = (u) => o.historyCollapsed = !o.historyCollapsed)
935
- }, [
936
- o.historyCollapsed ? (x(), V(L, {
937
- key: 0,
938
- icon: "ant-design:caret-left"
939
- })) : (x(), V(L, {
940
- key: 1,
941
- icon: "ant-design:caret-right"
942
- }))
943
- ])
944
- ]),
945
- _: 1
946
- }, 8, ["class"])
947
- ]),
948
- _: 1
949
- }, 8, ["onRegister", "onOk", "onFullScreen"])
950
- ])),
951
- a(X, {
952
- title: "请输入保存的名称",
953
- open: o.saveInfo.visible,
954
- onCancel: d[5] || (d[5] = (u) => o.saveInfo.visible = !1),
955
- onOk: o.doSaveQueryInfo,
956
- confirmLoading: o.saveModalLoading
957
- }, {
958
- default: i(() => [
959
- w("div", mt, [
960
- a(Y, {
961
- value: o.saveInfo.title,
962
- "onUpdate:value": d[4] || (d[4] = (u) => o.saveInfo.title = u),
963
- style: { width: "90%" },
964
- placeholder: "请输入保存的名称"
965
- }, null, 8, ["value"])
966
- ])
967
- ]),
968
- _: 1
969
- }, 8, ["open", "onOk", "confirmLoading"])
970
- ], 64);
971
- }
972
- const ol = /* @__PURE__ */ et(nt, [["render", vt], ["__scopeId", "data-v-79039fe8"]]);
973
- export {
974
- ol as default
975
- };