@jeecg/online 3.4.3-beta → 3.4.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.
- package/AuthFieldConfig.js +1 -1
- package/CgformCopyList.js +3 -1
- package/CgformModal.js +19 -2
- package/CgreportModal.js +1 -0
- package/CheckDictTable.js +1 -1
- package/DetailForm.js +14 -10
- package/EnhanceJsHistory.js +1 -1
- package/EnhanceJsModal.js +7 -0
- package/ExtendConfigModal.js +1 -1
- package/FieldExtendJsonModal.js +270 -0
- package/FormSchemaFactory.js +150 -10
- package/LinkTableConfigModal.js +1 -1
- package/OnlineAutoList.js +3 -2
- package/OnlineAutoModal.js +7 -3
- package/OnlineAutoTreeList.js +3 -2
- package/OnlineDetailModal.js +1 -1
- package/OnlineForm.js +64 -41
- package/OnlineFormDetail.js +1 -1
- package/OnlineQueryForm.js +8 -4
- package/OnlineSearchFormItem.js +3 -3
- package/OnlineSelectCascade.js +27 -30
- package/PageAttributeTable.js +68 -27
- package/README.md +1 -0
- package/{OnlineSuperQuery.js → SuperQuery.js} +215 -126
- package/{OnlineSuperQueryValComponent.js → SuperQueryValComponent.js} +2 -2
- package/{OnlineSuperQueryValComponent.vue_vue_type_script_lang.js → SuperQueryValComponent.vue_vue_type_script_lang.js} +8 -2
- package/cgform.data.js +8 -8
- package/clipboard.js +565 -0
- package/index.js +15 -5
- package/index2.js +3 -1
- package/index3.js +33 -571
- package/main.index.js +2 -2
- package/package.json +1 -1
- package/style.css +1 -1
- package/useAutoForm.js +84 -48
- package/useCgformList.js +97 -5
- package/useListButton.js +8 -4
- package/useSchemas.js +18 -4
|
@@ -1,12 +1,31 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
+
var __spreadValues = (a, b) => {
|
|
9
|
+
for (var prop in b || (b = {}))
|
|
10
|
+
if (__hasOwnProp.call(b, prop))
|
|
11
|
+
__defNormalProp(a, prop, b[prop]);
|
|
12
|
+
if (__getOwnPropSymbols)
|
|
13
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
+
if (__propIsEnum.call(b, prop))
|
|
15
|
+
__defNormalProp(a, prop, b[prop]);
|
|
16
|
+
}
|
|
17
|
+
return a;
|
|
18
|
+
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
1
20
|
import { ref, reactive, watch, toRaw, resolveComponent, openBlock, createElementBlock, Fragment, createElementVNode, createBlock, withCtx, createVNode, createTextVNode, Teleport, createCommentVNode, normalizeClass, withDirectives, vShow, renderList, toDisplayString, pushScopeId, popScopeId } from "vue";
|
|
2
21
|
import { useModalInner, BasicModal, useModal } from "/@/components/Modal";
|
|
3
22
|
import { randomString } from "/@/utils/common/compUtils";
|
|
4
23
|
import { useMessage } from "/@/hooks/web/useMessage";
|
|
5
|
-
import { Modal, Divider } from "ant-design-vue";
|
|
24
|
+
import { Modal, Divider, Empty } from "ant-design-vue";
|
|
6
25
|
import { createLocalStorage } from "/@/utils/cache";
|
|
7
26
|
import { useRoute } from "vue-router";
|
|
8
|
-
import {
|
|
9
|
-
import { _ as _sfc_main$1 } from "./
|
|
27
|
+
import { F as FormSchemaFactory } from "./FormSchemaFactory.js";
|
|
28
|
+
import { _ as _sfc_main$1 } from "./SuperQueryValComponent.vue_vue_type_script_lang.js";
|
|
10
29
|
import { MinusCircleOutlined, PlusOutlined, FileTextOutlined, CloseCircleOutlined, AppstoreTwoTone } from "@ant-design/icons-vue";
|
|
11
30
|
import { _ as _export_sfc } from "./index.js";
|
|
12
31
|
import "/@/components/Form/src/jeecg/components/JUpload";
|
|
@@ -17,6 +36,16 @@ import "./_baseSlice.js";
|
|
|
17
36
|
import "./toString.js";
|
|
18
37
|
import "./isArray.js";
|
|
19
38
|
import "/@/components/jeecg/OnLine/JPopupOnlReport.vue";
|
|
39
|
+
const FORM_VIEW_TO_QUERY_VIEW = {
|
|
40
|
+
"password": "text",
|
|
41
|
+
"file": "text",
|
|
42
|
+
"image": "text",
|
|
43
|
+
"textarea": "text",
|
|
44
|
+
"umeditor": "text",
|
|
45
|
+
"markdown": "text",
|
|
46
|
+
"checkbox": "list_multi",
|
|
47
|
+
"radio": "list"
|
|
48
|
+
};
|
|
20
49
|
const SAVE_CODE_PRE = "JSuperQuerySaved_";
|
|
21
50
|
function useSuperQuery() {
|
|
22
51
|
const { createMessage: $message } = useMessage();
|
|
@@ -28,7 +57,7 @@ function useSuperQuery() {
|
|
|
28
57
|
const [registerModal, { setModalProps }] = useModalInner(() => {
|
|
29
58
|
setModalProps({ confirmLoading: false });
|
|
30
59
|
});
|
|
31
|
-
const view2QueryViewMap = Object.assign({}, { link_down: "text" }, FORM_VIEW_TO_QUERY_VIEW);
|
|
60
|
+
const view2QueryViewMap = Object.assign({}, { "link_down": "text" }, FORM_VIEW_TO_QUERY_VIEW);
|
|
32
61
|
function handleSubmit() {
|
|
33
62
|
console.log("handleSubmit", dynamicRowValues.values);
|
|
34
63
|
}
|
|
@@ -41,6 +70,9 @@ function useSuperQuery() {
|
|
|
41
70
|
const fieldProperties = ref({});
|
|
42
71
|
const fieldTreeData = ref([]);
|
|
43
72
|
function init(json) {
|
|
73
|
+
console.log("=============");
|
|
74
|
+
console.log("=============", json);
|
|
75
|
+
console.log("=============");
|
|
44
76
|
let { allFields, treeData } = getAllFields(json);
|
|
45
77
|
fieldProperties.value = allFields;
|
|
46
78
|
fieldTreeData.value = treeData;
|
|
@@ -99,6 +131,9 @@ function useSuperQuery() {
|
|
|
99
131
|
};
|
|
100
132
|
temp.setFunctionForFieldValue(setFieldValue);
|
|
101
133
|
let schema = temp.getFormItemSchema();
|
|
134
|
+
if (["empty", "not_empty"].includes(item.rule)) {
|
|
135
|
+
schema.componentProps = __spreadProps(__spreadValues({}, schema.componentProps), { disabled: true });
|
|
136
|
+
}
|
|
102
137
|
return schema;
|
|
103
138
|
}
|
|
104
139
|
const saveTreeData = ref("");
|
|
@@ -111,32 +146,25 @@ function useSuperQuery() {
|
|
|
111
146
|
});
|
|
112
147
|
const loading = ref(false);
|
|
113
148
|
const route = useRoute();
|
|
114
|
-
watch(
|
|
115
|
-
()
|
|
116
|
-
(
|
|
117
|
-
|
|
118
|
-
initSaveQueryInfoCode();
|
|
119
|
-
}
|
|
120
|
-
);
|
|
149
|
+
watch(() => route.fullPath, (val) => {
|
|
150
|
+
console.log("fullpath", val);
|
|
151
|
+
initSaveQueryInfoCode();
|
|
152
|
+
});
|
|
121
153
|
const currentPageSavedArray = ref([]);
|
|
122
|
-
watch(
|
|
123
|
-
|
|
124
|
-
(val)
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
slots: { icon: "custom" },
|
|
132
|
-
value: key
|
|
133
|
-
});
|
|
154
|
+
watch(() => currentPageSavedArray.value, (val) => {
|
|
155
|
+
let temp = [];
|
|
156
|
+
if (val && val.length > 0) {
|
|
157
|
+
val.map((item) => {
|
|
158
|
+
let key = randomString(16);
|
|
159
|
+
temp.push({
|
|
160
|
+
title: item.title,
|
|
161
|
+
slots: { icon: "custom" },
|
|
162
|
+
value: key
|
|
134
163
|
});
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
);
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
saveTreeData.value = temp;
|
|
167
|
+
}, { immediate: true, deep: true });
|
|
140
168
|
function initSaveQueryInfoCode() {
|
|
141
169
|
let code = SAVE_CODE_PRE + route.fullPath;
|
|
142
170
|
saveInfo.saveCode = code;
|
|
@@ -177,6 +205,7 @@ function useSuperQuery() {
|
|
|
177
205
|
});
|
|
178
206
|
$ls.set(saveCode, currentPageSavedArray.value);
|
|
179
207
|
saveInfo.visible = false;
|
|
208
|
+
$message.success("\u4FDD\u5B58\u6210\u529F");
|
|
180
209
|
}
|
|
181
210
|
});
|
|
182
211
|
} else {
|
|
@@ -187,6 +216,7 @@ function useSuperQuery() {
|
|
|
187
216
|
});
|
|
188
217
|
$ls.set(saveCode, currentPageSavedArray.value);
|
|
189
218
|
saveInfo.visible = false;
|
|
219
|
+
$message.success("\u4FDD\u5B58\u6210\u529F");
|
|
190
220
|
}
|
|
191
221
|
}
|
|
192
222
|
function getTitleIndex(title) {
|
|
@@ -201,6 +231,7 @@ function useSuperQuery() {
|
|
|
201
231
|
return index;
|
|
202
232
|
}
|
|
203
233
|
function getQueryInfo(isEmit = false) {
|
|
234
|
+
var _a;
|
|
204
235
|
let arr = dynamicRowValues.values;
|
|
205
236
|
if (!arr || arr.length == 0) {
|
|
206
237
|
return false;
|
|
@@ -208,21 +239,27 @@ function useSuperQuery() {
|
|
|
208
239
|
let fieldArray = [];
|
|
209
240
|
let fieldProps = fieldProperties.value;
|
|
210
241
|
for (let item of arr) {
|
|
211
|
-
|
|
242
|
+
let allowEmpty = ["empty", "not_empty"].includes(item.rule);
|
|
243
|
+
if (item.field && (allowEmpty || item.val || item.val === 0) && item.rule) {
|
|
244
|
+
let prop = fieldProps[item.field];
|
|
245
|
+
let formatValue = (_a = prop == null ? void 0 : prop.formatValue) != null ? _a : (v) => v;
|
|
212
246
|
let tempVal = toRaw(item.val);
|
|
213
247
|
if (tempVal instanceof Array) {
|
|
214
|
-
tempVal = tempVal.join(",");
|
|
248
|
+
tempVal = tempVal.map((v) => formatValue(v)).join(",");
|
|
249
|
+
} else {
|
|
250
|
+
tempVal = formatValue(tempVal);
|
|
215
251
|
}
|
|
252
|
+
let fieldName = getRealFieldName(item);
|
|
216
253
|
let obj = {
|
|
217
|
-
field:
|
|
254
|
+
field: fieldName,
|
|
218
255
|
rule: item.rule,
|
|
219
256
|
val: tempVal
|
|
220
257
|
};
|
|
221
258
|
if (isEmit === true) {
|
|
222
|
-
let
|
|
223
|
-
if (
|
|
224
|
-
obj["type"] =
|
|
225
|
-
obj["dbType"] =
|
|
259
|
+
let prop2 = fieldProps[item.field];
|
|
260
|
+
if (prop2) {
|
|
261
|
+
obj["type"] = prop2.view;
|
|
262
|
+
obj["dbType"] = prop2.type;
|
|
226
263
|
}
|
|
227
264
|
}
|
|
228
265
|
fieldArray.push(obj);
|
|
@@ -233,6 +270,13 @@ function useSuperQuery() {
|
|
|
233
270
|
}
|
|
234
271
|
return fieldArray;
|
|
235
272
|
}
|
|
273
|
+
function getRealFieldName(item) {
|
|
274
|
+
let fieldName = item.field;
|
|
275
|
+
if (fieldName.indexOf("@") > 0) {
|
|
276
|
+
fieldName = fieldName.replace("@", ",");
|
|
277
|
+
}
|
|
278
|
+
return fieldName;
|
|
279
|
+
}
|
|
236
280
|
function handleTreeSelect(key, { node }) {
|
|
237
281
|
console.log(key, node);
|
|
238
282
|
let title = node.dataRef.title;
|
|
@@ -256,33 +300,29 @@ function useSuperQuery() {
|
|
|
256
300
|
$ls.set(saveInfo.saveCode, currentPageSavedArray.value);
|
|
257
301
|
}
|
|
258
302
|
}
|
|
259
|
-
function getAllFields(
|
|
260
|
-
const { properties, table, title } = json;
|
|
303
|
+
function getAllFields(properties) {
|
|
261
304
|
let allFields = {};
|
|
262
305
|
let order = 1;
|
|
263
306
|
let treeData = [];
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
disabled: true,
|
|
268
|
-
children: []
|
|
269
|
-
};
|
|
270
|
-
treeData.push(mainNode);
|
|
307
|
+
if (properties.properties) {
|
|
308
|
+
properties = properties.properties;
|
|
309
|
+
}
|
|
271
310
|
Object.keys(properties).map((field) => {
|
|
272
311
|
let item = properties[field];
|
|
273
312
|
if (item.view == "table") {
|
|
274
|
-
let subProps = item["properties"];
|
|
313
|
+
let subProps = item["properties"] || item["fields"];
|
|
275
314
|
let subTableOrder = order * 100;
|
|
276
315
|
let subNode = {
|
|
277
316
|
title: item.title,
|
|
278
317
|
value: field,
|
|
279
318
|
disabled: true,
|
|
280
|
-
children: []
|
|
319
|
+
children: [],
|
|
320
|
+
order: subTableOrder
|
|
281
321
|
};
|
|
282
322
|
Object.keys(subProps).map((subField) => {
|
|
283
323
|
let subItem = subProps[subField];
|
|
284
324
|
subItem["order"] = subTableOrder + subItem["order"];
|
|
285
|
-
let subFieldKey = field + "
|
|
325
|
+
let subFieldKey = field + "@" + subField;
|
|
286
326
|
allFields[subFieldKey] = subItem;
|
|
287
327
|
subNode.children.push({
|
|
288
328
|
title: subItem.title,
|
|
@@ -295,9 +335,9 @@ function useSuperQuery() {
|
|
|
295
335
|
treeData.push(subNode);
|
|
296
336
|
order++;
|
|
297
337
|
} else {
|
|
298
|
-
let fieldKey =
|
|
338
|
+
let fieldKey = field;
|
|
299
339
|
allFields[fieldKey] = item;
|
|
300
|
-
|
|
340
|
+
treeData.push({
|
|
301
341
|
title: item.title,
|
|
302
342
|
value: fieldKey,
|
|
303
343
|
isLeaf: true,
|
|
@@ -305,11 +345,11 @@ function useSuperQuery() {
|
|
|
305
345
|
});
|
|
306
346
|
}
|
|
307
347
|
});
|
|
308
|
-
orderField(
|
|
348
|
+
orderField(treeData);
|
|
309
349
|
return { allFields, treeData };
|
|
310
350
|
}
|
|
311
351
|
function orderField(data) {
|
|
312
|
-
let arr = data.children;
|
|
352
|
+
let arr = data.children || data;
|
|
313
353
|
arr.sort(function(a, b) {
|
|
314
354
|
return a.order - b.order;
|
|
315
355
|
});
|
|
@@ -349,7 +389,7 @@ function useSuperQuery() {
|
|
|
349
389
|
initDefaultValues
|
|
350
390
|
};
|
|
351
391
|
}
|
|
352
|
-
var
|
|
392
|
+
var SuperQuery_vue_vue_type_style_index_0_scoped_true_lang = "";
|
|
353
393
|
const _sfc_main = {
|
|
354
394
|
name: "OnlineSuperQuery",
|
|
355
395
|
props: {
|
|
@@ -360,6 +400,10 @@ const _sfc_main = {
|
|
|
360
400
|
status: {
|
|
361
401
|
type: Boolean,
|
|
362
402
|
default: false
|
|
403
|
+
},
|
|
404
|
+
online: {
|
|
405
|
+
type: Boolean,
|
|
406
|
+
default: false
|
|
363
407
|
}
|
|
364
408
|
},
|
|
365
409
|
components: {
|
|
@@ -376,22 +420,57 @@ const _sfc_main = {
|
|
|
376
420
|
setup(props, { emit }) {
|
|
377
421
|
const [registerFormModal, formModal] = useModal();
|
|
378
422
|
const { createMessage: $message } = useMessage();
|
|
423
|
+
const historyCollapsed = ref(true);
|
|
379
424
|
function handleCancel() {
|
|
380
425
|
formModal.closeModal();
|
|
381
426
|
}
|
|
382
427
|
function handleSubmit() {
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
428
|
+
if (props.online === true) {
|
|
429
|
+
let dataArray = getQueryInfo(true);
|
|
430
|
+
if (dataArray && dataArray.length > 0) {
|
|
431
|
+
emit("search", dataArray, matchType.value);
|
|
432
|
+
} else {
|
|
433
|
+
$message.warning("\u7A7A\u6761\u4EF6\u65E0\u6CD5\u67E5\u8BE2\uFF01");
|
|
434
|
+
}
|
|
435
|
+
} else {
|
|
436
|
+
let dataArray = getQueryInfo(true);
|
|
437
|
+
if (dataArray && dataArray.length > 0) {
|
|
438
|
+
let result = getSuperQueryParams(dataArray);
|
|
439
|
+
emit("search", result);
|
|
440
|
+
} else {
|
|
441
|
+
$message.warning("\u7A7A\u6761\u4EF6\u65E0\u6CD5\u67E5\u8BE2\uFF01");
|
|
442
|
+
}
|
|
443
|
+
}
|
|
444
|
+
}
|
|
445
|
+
function getSuperQueryParams(dataArray) {
|
|
446
|
+
let arr = [];
|
|
447
|
+
for (let item of dataArray) {
|
|
448
|
+
let field = item.field;
|
|
449
|
+
let val = item.val;
|
|
450
|
+
if (val instanceof Array) {
|
|
451
|
+
val = val.join(",");
|
|
452
|
+
}
|
|
453
|
+
arr.push(__spreadProps(__spreadValues({}, item), {
|
|
454
|
+
field,
|
|
455
|
+
val
|
|
456
|
+
}));
|
|
457
|
+
}
|
|
458
|
+
if (arr.length > 0) {
|
|
459
|
+
superQueryFlag.value = true;
|
|
387
460
|
} else {
|
|
388
|
-
|
|
461
|
+
superQueryFlag.value = false;
|
|
389
462
|
}
|
|
463
|
+
let result = {
|
|
464
|
+
superQueryMatchType: matchType.value,
|
|
465
|
+
superQueryParams: encodeURI(JSON.stringify(arr))
|
|
466
|
+
};
|
|
467
|
+
return result;
|
|
390
468
|
}
|
|
391
469
|
function handleReset() {
|
|
392
470
|
dynamicRowValues.values = [];
|
|
393
471
|
addOne(false);
|
|
394
|
-
|
|
472
|
+
let result = getSuperQueryParams([]);
|
|
473
|
+
emit("search", result);
|
|
395
474
|
}
|
|
396
475
|
const {
|
|
397
476
|
formRef,
|
|
@@ -415,13 +494,9 @@ const _sfc_main = {
|
|
|
415
494
|
initDefaultValues
|
|
416
495
|
} = useSuperQuery();
|
|
417
496
|
const superQueryFlag = ref(false);
|
|
418
|
-
watch(
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
superQueryFlag.value = val;
|
|
422
|
-
},
|
|
423
|
-
{ immediate: true }
|
|
424
|
-
);
|
|
497
|
+
watch(() => props.status, (val) => {
|
|
498
|
+
superQueryFlag.value = val;
|
|
499
|
+
}, { immediate: true });
|
|
425
500
|
function handleOpen() {
|
|
426
501
|
formModal.openModal();
|
|
427
502
|
addOne(true);
|
|
@@ -435,6 +510,11 @@ const _sfc_main = {
|
|
|
435
510
|
function handleChangeField(item) {
|
|
436
511
|
item["val"] = "";
|
|
437
512
|
}
|
|
513
|
+
watch(() => props.config, (val) => {
|
|
514
|
+
if (val) {
|
|
515
|
+
init(val);
|
|
516
|
+
}
|
|
517
|
+
}, { immediate: true });
|
|
438
518
|
return {
|
|
439
519
|
formRef,
|
|
440
520
|
registerFormModal,
|
|
@@ -442,6 +522,7 @@ const _sfc_main = {
|
|
|
442
522
|
handleChangeField,
|
|
443
523
|
dynamicRowValues,
|
|
444
524
|
matchType,
|
|
525
|
+
historyCollapsed,
|
|
445
526
|
registerModal,
|
|
446
527
|
handleSubmit,
|
|
447
528
|
handleCancel,
|
|
@@ -462,11 +543,12 @@ const _sfc_main = {
|
|
|
462
543
|
getPopupContainer,
|
|
463
544
|
superQueryFlag,
|
|
464
545
|
handleOpen,
|
|
465
|
-
initDefaultValues
|
|
546
|
+
initDefaultValues,
|
|
547
|
+
simpleImage: Empty.PRESENTED_IMAGE_SIMPLE
|
|
466
548
|
};
|
|
467
549
|
}
|
|
468
550
|
};
|
|
469
|
-
const _withScopeId = (n) => (pushScopeId("data-v-
|
|
551
|
+
const _withScopeId = (n) => (pushScopeId("data-v-050f6852"), n = n(), popScopeId(), n);
|
|
470
552
|
const _hoisted_1 = { class: "j-super-query-button" };
|
|
471
553
|
const _hoisted_2 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("span", null, "\u5DF2\u6709\u9AD8\u7EA7\u67E5\u8BE2\u6761\u4EF6\u751F\u6548", -1));
|
|
472
554
|
const _hoisted_3 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("span", null, "\u9AD8\u7EA7\u67E5\u8BE2", -1));
|
|
@@ -499,6 +581,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
499
581
|
const _component_close_circle_outlined = resolveComponent("close-circle-outlined");
|
|
500
582
|
const _component_file_text_outlined = resolveComponent("file-text-outlined");
|
|
501
583
|
const _component_a_tree = resolveComponent("a-tree");
|
|
584
|
+
const _component_Icon = resolveComponent("Icon");
|
|
502
585
|
const _component_a_card = resolveComponent("a-card");
|
|
503
586
|
const _component_BasicModal = resolveComponent("BasicModal");
|
|
504
587
|
const _component_a_input = resolveComponent("a-input");
|
|
@@ -553,7 +636,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
553
636
|
createVNode(_component_BasicModal, {
|
|
554
637
|
title: "\u9AD8\u7EA7\u67E5\u8BE2\u6784\u9020\u5668",
|
|
555
638
|
canFullscreen: false,
|
|
556
|
-
width:
|
|
639
|
+
width: 700,
|
|
557
640
|
onRegister: $setup.registerFormModal,
|
|
558
641
|
onOk: $setup.handleSubmit
|
|
559
642
|
}, {
|
|
@@ -573,7 +656,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
573
656
|
onClick: $setup.handleSave
|
|
574
657
|
}, {
|
|
575
658
|
default: withCtx(() => [
|
|
576
|
-
createTextVNode("\u4FDD\u5B58\u67E5\u8BE2
|
|
659
|
+
createTextVNode("\u4FDD\u5B58\u67E5\u8BE2")
|
|
577
660
|
]),
|
|
578
661
|
_: 1
|
|
579
662
|
}, 8, ["loading", "onClick"])
|
|
@@ -617,7 +700,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
617
700
|
default: withCtx(() => [
|
|
618
701
|
createVNode(_component_a_col, {
|
|
619
702
|
sm: 24,
|
|
620
|
-
md:
|
|
703
|
+
md: 24
|
|
621
704
|
}, {
|
|
622
705
|
default: withCtx(() => [
|
|
623
706
|
withDirectives(createVNode(_component_a_row, null, {
|
|
@@ -628,7 +711,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
628
711
|
}, {
|
|
629
712
|
default: withCtx(() => [
|
|
630
713
|
createVNode(_component_a_form_item, {
|
|
631
|
-
label: "\
|
|
714
|
+
label: "\u5339\u914D\u6A21\u5F0F",
|
|
632
715
|
labelCol: { md: 6, xs: 24 },
|
|
633
716
|
wrapperCol: { md: 18, xs: 24 },
|
|
634
717
|
style: { "width": "100%" }
|
|
@@ -643,13 +726,13 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
643
726
|
default: withCtx(() => [
|
|
644
727
|
createVNode(_component_a_select_option, { value: "and" }, {
|
|
645
728
|
default: withCtx(() => [
|
|
646
|
-
createTextVNode("AND\uFF08\u6240\u6709\u6761\u4EF6\
|
|
729
|
+
createTextVNode("AND\uFF08\u6240\u6709\u6761\u4EF6\u5339\u914D\uFF09")
|
|
647
730
|
]),
|
|
648
731
|
_: 1
|
|
649
732
|
}),
|
|
650
733
|
createVNode(_component_a_select_option, { value: "or" }, {
|
|
651
734
|
default: withCtx(() => [
|
|
652
|
-
createTextVNode("OR\uFF08\
|
|
735
|
+
createTextVNode("OR\uFF08\u4EFB\u610F\u4E00\u4E2A\u5339\u914D\uFF09")
|
|
653
736
|
]),
|
|
654
737
|
_: 1
|
|
655
738
|
})
|
|
@@ -683,7 +766,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
683
766
|
default: withCtx(() => [
|
|
684
767
|
createVNode(_component_a_form_item, {
|
|
685
768
|
name: ["values", index, "field"],
|
|
686
|
-
style: { "width": "
|
|
769
|
+
style: { "width": "150px" }
|
|
687
770
|
}, {
|
|
688
771
|
default: withCtx(() => [
|
|
689
772
|
createVNode(_component_a_tree_select, {
|
|
@@ -704,7 +787,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
704
787
|
}, 1032, ["name"]),
|
|
705
788
|
createVNode(_component_a_form_item, {
|
|
706
789
|
name: ["values", index, "rule"],
|
|
707
|
-
style: { "width": "
|
|
790
|
+
style: { "width": "100px" }
|
|
708
791
|
}, {
|
|
709
792
|
default: withCtx(() => [
|
|
710
793
|
createVNode(_component_a_select, {
|
|
@@ -782,7 +865,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
782
865
|
}, 1032, ["name"]),
|
|
783
866
|
createVNode(_component_a_form_item, {
|
|
784
867
|
name: ["values", index, "val"],
|
|
785
|
-
style: { "width": "
|
|
868
|
+
style: { "width": "180px" }
|
|
786
869
|
}, {
|
|
787
870
|
default: withCtx(() => [
|
|
788
871
|
createVNode(_component_online_super_query_val_component, {
|
|
@@ -791,8 +874,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
791
874
|
formModel: item,
|
|
792
875
|
setFormModel: (key, value) => {
|
|
793
876
|
$setup.setFormModel(key, value, item);
|
|
794
|
-
}
|
|
795
|
-
|
|
877
|
+
},
|
|
878
|
+
onSubmit: $setup.handleSubmit
|
|
879
|
+
}, null, 8, ["schema", "formModel", "setFormModel", "onSubmit"])
|
|
796
880
|
]),
|
|
797
881
|
_: 2
|
|
798
882
|
}, 1032, ["name"]),
|
|
@@ -829,56 +913,61 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
829
913
|
])
|
|
830
914
|
]),
|
|
831
915
|
_: 1
|
|
832
|
-
})
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
916
|
+
})
|
|
917
|
+
]),
|
|
918
|
+
_: 1
|
|
919
|
+
}),
|
|
920
|
+
createVNode(_component_a_card, {
|
|
921
|
+
class: normalizeClass(["j-super-query-history-card", { "collapsed": $setup.historyCollapsed }]),
|
|
922
|
+
bordered: false
|
|
923
|
+
}, {
|
|
924
|
+
title: withCtx(() => [
|
|
925
|
+
_hoisted_7
|
|
926
|
+
]),
|
|
927
|
+
default: withCtx(() => [
|
|
928
|
+
$setup.saveTreeData.length === 0 ? (openBlock(), createBlock(_component_a_empty, {
|
|
929
|
+
key: 0,
|
|
930
|
+
class: "j-super-query-history-empty",
|
|
931
|
+
image: $setup.simpleImage,
|
|
932
|
+
description: "\u6CA1\u6709\u4FDD\u5B58\u7684\u67E5\u8BE2"
|
|
933
|
+
}, null, 8, ["image"])) : (openBlock(), createBlock(_component_a_tree, {
|
|
934
|
+
key: 1,
|
|
935
|
+
class: "j-super-query-history-tree",
|
|
936
|
+
treeData: $setup.saveTreeData,
|
|
937
|
+
selectedKeys: [],
|
|
938
|
+
"show-icon": true,
|
|
939
|
+
onSelect: $setup.handleTreeSelect
|
|
836
940
|
}, {
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
])
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
description: "\u6CA1\u6709\u4FDD\u5B58\u4EFB\u4F55\u67E5\u8BE2"
|
|
850
|
-
})) : (openBlock(), createBlock(_component_a_tree, {
|
|
851
|
-
key: 1,
|
|
852
|
-
class: "j-super-query-history-tree",
|
|
853
|
-
treeData: $setup.saveTreeData,
|
|
854
|
-
selectedKeys: [],
|
|
855
|
-
"show-icon": true,
|
|
856
|
-
onSelect: $setup.handleTreeSelect
|
|
857
|
-
}, {
|
|
858
|
-
title: withCtx(({ title }) => [
|
|
859
|
-
createElementVNode("div", null, [
|
|
860
|
-
createElementVNode("span", { title }, toDisplayString(title.length > 10 ? title.substring(0, 10) + "..." : title), 9, _hoisted_8),
|
|
861
|
-
createElementVNode("span", _hoisted_9, [
|
|
862
|
-
createVNode(_component_close_circle_outlined, {
|
|
863
|
-
onClick: ($event) => $setup.handleRemoveSaveInfo(title)
|
|
864
|
-
}, null, 8, ["onClick"])
|
|
865
|
-
])
|
|
866
|
-
])
|
|
867
|
-
]),
|
|
868
|
-
custom: withCtx(() => [
|
|
869
|
-
createVNode(_component_file_text_outlined)
|
|
870
|
-
]),
|
|
871
|
-
_: 1
|
|
872
|
-
}, 8, ["treeData", "onSelect"]))
|
|
873
|
-
]),
|
|
874
|
-
_: 1
|
|
875
|
-
})
|
|
941
|
+
title: withCtx(({ title }) => [
|
|
942
|
+
createElementVNode("div", null, [
|
|
943
|
+
createElementVNode("span", { title }, toDisplayString(title.length > 10 ? title.substring(0, 10) + "..." : title), 9, _hoisted_8),
|
|
944
|
+
createElementVNode("span", _hoisted_9, [
|
|
945
|
+
createVNode(_component_close_circle_outlined, {
|
|
946
|
+
onClick: ($event) => $setup.handleRemoveSaveInfo(title)
|
|
947
|
+
}, null, 8, ["onClick"])
|
|
948
|
+
])
|
|
949
|
+
])
|
|
950
|
+
]),
|
|
951
|
+
custom: withCtx(() => [
|
|
952
|
+
createVNode(_component_file_text_outlined)
|
|
876
953
|
]),
|
|
877
954
|
_: 1
|
|
878
|
-
})
|
|
955
|
+
}, 8, ["treeData", "onSelect"])),
|
|
956
|
+
createElementVNode("div", {
|
|
957
|
+
class: "collapse-box",
|
|
958
|
+
onClick: _cache[3] || (_cache[3] = ($event) => $setup.historyCollapsed = !$setup.historyCollapsed)
|
|
959
|
+
}, [
|
|
960
|
+
$setup.historyCollapsed ? (openBlock(), createBlock(_component_Icon, {
|
|
961
|
+
key: 0,
|
|
962
|
+
icon: "ant-design:caret-left"
|
|
963
|
+
})) : (openBlock(), createBlock(_component_Icon, {
|
|
964
|
+
key: 1,
|
|
965
|
+
icon: "ant-design:caret-right"
|
|
966
|
+
}))
|
|
967
|
+
])
|
|
879
968
|
]),
|
|
880
969
|
_: 1
|
|
881
|
-
})
|
|
970
|
+
}, 8, ["class"])
|
|
882
971
|
]),
|
|
883
972
|
_: 1
|
|
884
973
|
}, 8, ["onRegister", "onOk"])
|
|
@@ -886,14 +975,14 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
886
975
|
createVNode(_component_a_modal, {
|
|
887
976
|
title: "\u8BF7\u8F93\u5165\u4FDD\u5B58\u7684\u540D\u79F0",
|
|
888
977
|
visible: $setup.saveInfo.visible,
|
|
889
|
-
onCancel: _cache[
|
|
978
|
+
onCancel: _cache[5] || (_cache[5] = ($event) => $setup.saveInfo.visible = false),
|
|
890
979
|
onOk: $setup.doSaveQueryInfo
|
|
891
980
|
}, {
|
|
892
981
|
default: withCtx(() => [
|
|
893
982
|
createElementVNode("div", _hoisted_10, [
|
|
894
983
|
createVNode(_component_a_input, {
|
|
895
984
|
value: $setup.saveInfo.title,
|
|
896
|
-
"onUpdate:value": _cache[
|
|
985
|
+
"onUpdate:value": _cache[4] || (_cache[4] = ($event) => $setup.saveInfo.title = $event),
|
|
897
986
|
style: { "width": "90%" },
|
|
898
987
|
placeholder: "\u8BF7\u8F93\u5165\u4FDD\u5B58\u7684\u540D\u79F0"
|
|
899
988
|
}, null, 8, ["value"])
|
|
@@ -903,5 +992,5 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
903
992
|
}, 8, ["visible", "onOk"])
|
|
904
993
|
], 64);
|
|
905
994
|
}
|
|
906
|
-
var OnlineSuperQuery = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
995
|
+
var OnlineSuperQuery = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-050f6852"]]);
|
|
907
996
|
export { OnlineSuperQuery as default };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { _ as _sfc_main } from "./
|
|
2
|
-
export { _ as default } from "./
|
|
1
|
+
import { _ as _sfc_main } from "./SuperQueryValComponent.vue_vue_type_script_lang.js";
|
|
2
|
+
export { _ as default } from "./SuperQueryValComponent.vue_vue_type_script_lang.js";
|
|
3
3
|
import "vue";
|
|
4
4
|
import "/@/components/Form/src/componentMap";
|
|
5
5
|
import "/@/components/Form/src/helper";
|
|
@@ -75,7 +75,10 @@ var _sfc_main = defineComponent({
|
|
|
75
75
|
default: null
|
|
76
76
|
}
|
|
77
77
|
},
|
|
78
|
-
|
|
78
|
+
emits: ["submit"],
|
|
79
|
+
setup(props, {
|
|
80
|
+
emit
|
|
81
|
+
}) {
|
|
79
82
|
const getComponentsProps = computed(() => {
|
|
80
83
|
var _a;
|
|
81
84
|
const {
|
|
@@ -142,7 +145,10 @@ var _sfc_main = defineComponent({
|
|
|
142
145
|
[valueField || (isCheck ? "checked" : "value")]: props.formModel[field]
|
|
143
146
|
};
|
|
144
147
|
const compAttr = __spreadProps(__spreadValues(__spreadValues(__spreadValues({}, propsData), on), bindValue), {
|
|
145
|
-
allowClear: true
|
|
148
|
+
allowClear: true,
|
|
149
|
+
onPressEnter() {
|
|
150
|
+
emit("submit");
|
|
151
|
+
}
|
|
146
152
|
});
|
|
147
153
|
return createVNode(Comp, compAttr, null);
|
|
148
154
|
}
|