super-page-designer 2.0.41 → 2.0.48

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 (85) hide show
  1. package/dist/es/components/design/utils/assemblys-config.js +203 -116
  2. package/dist/es/components/design/utils/chart-design-util.js +9 -9
  3. package/dist/es/components/design/utils/form-design-util.d.ts +1 -1
  4. package/dist/es/components/design/utils/interfaces/page-design-types.d.ts +13 -13
  5. package/dist/es/components/design/utils/page-table-util.js +7 -2
  6. package/dist/es/components/design/views/assemblys/button/button/button-attr-advanced.vue.js +32 -14
  7. package/dist/es/components/design/views/assemblys/button/button/button-attr-base.vue.js +43 -7
  8. package/dist/es/components/design/views/assemblys/button/button/button-attr.vue2.js +7 -7
  9. package/dist/es/components/design/views/assemblys/button/component/condition-dialog.vue.js +16 -11
  10. package/dist/es/components/design/views/assemblys/button/dropdown/dropdown-attr-advanced.vue.js +5 -1
  11. package/dist/es/components/design/views/assemblys/button/print-label/printlabel-attr-advanced.vue.js +20 -6
  12. package/dist/es/components/design/views/assemblys/button/print-label/printlabel-attr.vue2.js +7 -7
  13. package/dist/es/components/design/views/assemblys/chart/column-line/column-line-attr-base.vue.js +36 -8
  14. package/dist/es/components/design/views/assemblys/chart/column-line/series/column-line-series-attr-base.vue.js +1 -1
  15. package/dist/es/components/design/views/assemblys/chart/common/common-attr-clickset.vue.js +244 -0
  16. package/dist/es/components/design/views/assemblys/chart/common/common-attr-clickset.vue2.js +4 -0
  17. package/dist/es/components/design/views/assemblys/chart/common/common-attr-data.vue.js +115 -30
  18. package/dist/es/components/design/views/assemblys/chart/common/common-attr-groupby.vue.js +2 -27
  19. package/dist/es/components/design/views/assemblys/chart/common-series/common-attr-dataset-columnline.vue.js +69 -3
  20. package/dist/es/components/design/views/assemblys/chart/pie/pie-attr-base.vue.js +36 -8
  21. package/dist/es/components/design/views/assemblys/chart/pie/pie-attr.vue2.js +11 -5
  22. package/dist/es/components/design/views/assemblys/chart/radar/series/series-attr-dataset.vue.js +69 -4
  23. package/dist/es/components/design/views/assemblys/chart/scatter/series/scatter-series-data.vue.js +115 -34
  24. package/dist/es/components/design/views/assemblys/common/common-advanced-basic-showcondition.vue.js +35 -10
  25. package/dist/es/components/design/views/assemblys/common/common-advanced-basic.vue.js +29 -3
  26. package/dist/es/components/design/views/assemblys/common/common-variable-bind.vue.js +2 -2
  27. package/dist/es/components/design/views/assemblys/common/common-variable-bind.vue2.js +1 -692
  28. package/dist/es/components/design/views/assemblys/common/common-variable-bind.vue3.js +692 -1
  29. package/dist/es/components/design/views/assemblys/data/component/column-config.vue.js +371 -168
  30. package/dist/es/components/design/views/assemblys/data/component/composite-header.vue.js +1 -1
  31. package/dist/es/components/design/views/assemblys/data/component/composite-header.vue2.js +18 -33
  32. package/dist/es/components/design/views/assemblys/data/component/configuration-value.vue.js +403 -0
  33. package/dist/es/components/design/views/assemblys/data/component/configuration-value.vue2.js +4 -0
  34. package/dist/es/components/design/views/assemblys/data/component/data-origin.vue.js +1 -1
  35. package/dist/es/components/design/views/assemblys/data/component/data-origin.vue2.js +60 -90
  36. package/dist/es/components/design/views/assemblys/data/component/dynamic-column.vue.js +781 -0
  37. package/dist/es/components/design/views/assemblys/data/component/dynamic-column.vue2.js +4 -0
  38. package/dist/es/components/design/views/assemblys/data/component/formatting.vue.js +534 -0
  39. package/dist/es/components/design/views/assemblys/data/component/formatting.vue2.js +4 -0
  40. package/dist/es/components/design/views/assemblys/data/component/table-children-column.vue.js +26 -10
  41. package/dist/es/components/design/views/assemblys/data/component/variate-select.vue.js +24 -2
  42. package/dist/es/components/design/views/assemblys/data/table/table-attr-base.vue.js +6 -117
  43. package/dist/es/components/design/views/assemblys/data/table/table-design.vue.js +1 -1
  44. package/dist/es/components/design/views/assemblys/data/table/table-design.vue2.js +77 -82
  45. package/dist/es/components/design/views/assemblys/data/table/tablecolumn-attr-base.vue.js +296 -73
  46. package/dist/es/components/design/views/assemblys/form/checkbox/checkbox-attr-advanced.vue.js +4 -1
  47. package/dist/es/components/design/views/assemblys/form/common/condition.vue.js +4 -1
  48. package/dist/es/components/design/views/assemblys/form/common/data-format.vue.js +2 -2
  49. package/dist/es/components/design/views/assemblys/form/common/data-origin-autoset.vue.js +7 -1
  50. package/dist/es/components/design/views/assemblys/form/common/data-origin.vue.js +1 -1
  51. package/dist/es/components/design/views/assemblys/form/common/data-origin.vue2.js +95 -36
  52. package/dist/es/components/design/views/assemblys/form/common/dataorigin-input-table.vue.js +152 -1
  53. package/dist/es/components/design/views/assemblys/form/common/dataorigin-input-table.vue2.js +1 -152
  54. package/dist/es/components/design/views/assemblys/form/common/suffixmodule.vue.js +190 -61
  55. package/dist/es/components/design/views/assemblys/form/date-picker/datepicker-attr-advanced.vue.js +4 -1
  56. package/dist/es/components/design/views/assemblys/form/date-picker/datepicker-attr-base.vue.js +55 -25
  57. package/dist/es/components/design/views/assemblys/form/date-picker/datepicker-design.vue2.js +11 -2
  58. package/dist/es/components/design/views/assemblys/form/dept-tree/depttree-attr-advanced.vue.js +4 -1
  59. package/dist/es/components/design/views/assemblys/form/dept-tree/depttree-attr-base.vue.js +6 -2
  60. package/dist/es/components/design/views/assemblys/form/dept-tree/depttree-design.vue2.js +30 -14
  61. package/dist/es/components/design/views/assemblys/form/file-upload/fileupload-attr-advanced.vue.js +4 -1
  62. package/dist/es/components/design/views/assemblys/form/input-number/input-number-attr-advanced.vue.js +4 -1
  63. package/dist/es/components/design/views/assemblys/form/input-number/input-number-attr-base.vue.js +6 -2
  64. package/dist/es/components/design/views/assemblys/form/input-number/input-number-design.vue2.js +30 -14
  65. package/dist/es/components/design/views/assemblys/form/input-text/inputtext-attr-advanced.vue.js +4 -1
  66. package/dist/es/components/design/views/assemblys/form/link/link-attr-advanced.vue.js +4 -1
  67. package/dist/es/components/design/views/assemblys/form/radio/radio-attr-advanced.vue.js +4 -1
  68. package/dist/es/components/design/views/assemblys/form/rich-text/richtext-attr-advanced.vue.js +4 -1
  69. package/dist/es/components/design/views/assemblys/form/select/select-attr-advanced.vue.js +4 -1
  70. package/dist/es/components/design/views/assemblys/form/select/select-attr-base.vue.js +6 -2
  71. package/dist/es/components/design/views/assemblys/form/select/select-design.vue2.js +12 -8
  72. package/dist/es/components/design/views/assemblys/form/switch/switch-attr-advanced.vue.js +4 -1
  73. package/dist/es/components/design/views/assemblys/form/textarea/textarea-attr-advanced.vue.js +4 -1
  74. package/dist/es/components/design/views/assemblys/form/textarea/textarea-attr-base.vue.js +19 -44
  75. package/dist/es/components/design/views/assemblys/form/textarea/textarea-design.vue2.js +29 -14
  76. package/dist/es/components/design/views/assemblys/object-design.vue.js +8 -3
  77. package/dist/es/components/design/views/assemblys/page/component/weight-field-input.vue.d.ts +9 -0
  78. package/dist/es/components/design/views/assemblys/page/component/weight-field-input.vue.js +51 -33
  79. package/dist/es/components/design/views/assemblys/page/page-attr-advanced.vue.js +6 -5
  80. package/dist/es/components/design/views/assemblys/workflow/component/combination.vue.js +1 -1
  81. package/dist/es/components/design/views/design/view/view-design-display.vue.js +7 -2
  82. package/dist/es/style.css +81 -81
  83. package/package.json +4 -4
  84. package/dist/es/components/design/views/assemblys/data/component/select-data-table.vue.js +0 -180
  85. package/dist/es/components/design/views/assemblys/data/component/select-data-table.vue2.js +0 -4
@@ -1 +1,692 @@
1
-
1
+ import { defineComponent, ref, onMounted, onUnmounted, computed, watch, resolveComponent, openBlock, createElementBlock, toDisplayString, createBlock, withCtx, createVNode, withDirectives, withModifiers, unref, vShow, createElementVNode, createTextVNode, normalizeStyle, createCommentVNode, nextTick, pushScopeId, popScopeId } from "vue";
2
+ import { CircleClose, Plus, InfoFilled, Search } from "@element-plus/icons-vue";
3
+ import http from "agilebuilder-ui/src/utils/request";
4
+ import { deepCopy, getUuidv4 } from "../../../utils/common-util.js";
5
+ import { getTypeOptions, taskVarOptions, contextVarOptions } from "./common-variable-bind-option.js";
6
+ import { usePageContextStore } from "../../../../../stores/page-store.js";
7
+ const _withScopeId = (n) => (pushScopeId("data-v-8cdbf8c5"), n = n(), popScopeId(), n);
8
+ const _hoisted_1 = { key: 0 };
9
+ const _hoisted_2 = { style: { "margin-top": "10px", "font-size": "10px", "display": "flex", "align-items": "center", "justify-self": "center" } };
10
+ const _hoisted_3 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("span", { style: { "margin-left": "5px" } }, "输入变量名后点击加号按钮添加", -1));
11
+ const _hoisted_4 = { style: { "font-size": "10px", "line-height": "40px" } };
12
+ const _hoisted_5 = { style: { "margin-top": "4px", "margin-bottom": "8px", "font-size": "10px", "display": "flex", "align-items": "center", "justify-self": "center" } };
13
+ const _hoisted_6 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("span", { style: { "margin-left": "5px" } }, "输入变量名后点击加号按钮添加", -1));
14
+ const _hoisted_7 = {
15
+ key: 0,
16
+ style: { "display": "flex" }
17
+ };
18
+ const _hoisted_8 = ["title"];
19
+ const _hoisted_9 = ["title"];
20
+ const _hoisted_10 = { class: "totalStyle" };
21
+ const _sfc_main = /* @__PURE__ */ defineComponent({
22
+ ...{
23
+ name: "ValueSetInput",
24
+ inheritAttrs: false
25
+ },
26
+ __name: "common-variable-bind",
27
+ props: {
28
+ modelValue: {
29
+ type: [String],
30
+ default: null
31
+ },
32
+ paramTypes: {
33
+ type: Array,
34
+ default: () => []
35
+ },
36
+ size: {
37
+ type: String,
38
+ default: "small"
39
+ },
40
+ showLabel: {
41
+ type: Boolean,
42
+ default: false
43
+ },
44
+ // 是否需要方法参数
45
+ needParams: {
46
+ type: Boolean,
47
+ default: false
48
+ },
49
+ isRange: {
50
+ type: Boolean,
51
+ default: false
52
+ }
53
+ },
54
+ emits: ["update:modelValue"],
55
+ setup(__props, { emit: __emit }) {
56
+ const pageContextUtil = usePageContextStore();
57
+ const emits = __emit;
58
+ const props = __props;
59
+ const popoverVisible = ref(false);
60
+ const defalutValue = ref("");
61
+ const inputRef = ref(null);
62
+ const contentRef = ref(null);
63
+ const typeOptions = ref([]);
64
+ const showInput = ref(false);
65
+ const labelValue = ref("");
66
+ const paramType = ref("");
67
+ const paramValue = ref("");
68
+ const valueOptions = ref([]);
69
+ const selectOptions = ref({});
70
+ const searchValue = ref("");
71
+ const popoverRef = ref(null);
72
+ const selectInputType = ["context", "system", "task", "data", "page"];
73
+ onMounted(() => {
74
+ window.addEventListener("click", handleClickOutside);
75
+ const pageContext = pageContextUtil.pageContext;
76
+ let hasTask = false;
77
+ let hasData = false;
78
+ if (pageContext && (!pageContext.pageType || pageContext.pageType == "form") && pageContext.tableName) {
79
+ hasData = true;
80
+ }
81
+ if (pageContext && pageContext.workflowCode && hasData) {
82
+ hasTask = true;
83
+ }
84
+ let newOptions = getTypeOptions(props.paramTypes, props.needParams);
85
+ if (!hasData) {
86
+ newOptions = newOptions.filter((item) => item.value != "data");
87
+ }
88
+ if (!hasTask) {
89
+ newOptions = newOptions.filter((item) => item.value != "task");
90
+ }
91
+ typeOptions.value = newOptions;
92
+ setSelectOptions();
93
+ if (props.modelValue) {
94
+ const [type, val] = props.modelValue.slice(0, props.modelValue.length - 1).slice(2).split(".");
95
+ paramType.value = type;
96
+ paramValue.value = val;
97
+ if (selectInputType.includes(type)) {
98
+ showInput.value = false;
99
+ }
100
+ setValueOptions(paramType.value);
101
+ labelValue.value = formatter();
102
+ defalutValue.value = props.modelValue;
103
+ }
104
+ if (!paramType.value) {
105
+ paramType.value = newOptions.length > 0 ? newOptions[0].value : "";
106
+ setValueOptions(paramType.value);
107
+ }
108
+ console.log("popoverRef", popoverRef.value);
109
+ });
110
+ onUnmounted(() => {
111
+ window.removeEventListener("click", handleClickOutside);
112
+ });
113
+ let lastTarget = null;
114
+ function handleClickOutside(event) {
115
+ if (!popoverVisible.value) {
116
+ return;
117
+ }
118
+ if (paramTypeCheck) {
119
+ paramTypeCheck = false;
120
+ return;
121
+ }
122
+ let popoverDom = null;
123
+ if (contentRef.value) {
124
+ popoverDom = contentRef.value.$el.parentNode;
125
+ }
126
+ if (!event.target || !popoverDom) {
127
+ return;
128
+ }
129
+ if (event.target === lastTarget) {
130
+ console.log("与最后的点击一致");
131
+ return;
132
+ }
133
+ const inputDom = inputRef.value ? inputRef.value.input : null;
134
+ if (inputDom && (event.target === inputDom || inputDom.contains(event.target))) {
135
+ console.log("click contains input");
136
+ return;
137
+ }
138
+ if (event.target === popoverDom || popoverDom.contains(event.target)) {
139
+ console.log("click contains");
140
+ lastTarget = event.target;
141
+ } else {
142
+ if (contentRef.value.$el) {
143
+ console.log("contentRef.value.$el.contains", contentRef.value.$el.contains(event.target));
144
+ }
145
+ console.log("click contains--------not");
146
+ if (popoverVisible.value) {
147
+ closePopover(true);
148
+ }
149
+ }
150
+ }
151
+ const symbolUnits = ref([
152
+ {
153
+ label: "天",
154
+ value: "d"
155
+ },
156
+ {
157
+ label: "周",
158
+ value: "w"
159
+ },
160
+ {
161
+ label: "月",
162
+ value: "m"
163
+ },
164
+ {
165
+ label: "年",
166
+ value: "y"
167
+ }
168
+ ]);
169
+ const symbolUnitFormatter = (unit) => {
170
+ const items = symbolUnits.value.filter((item) => {
171
+ return item.value == unit;
172
+ });
173
+ if (items.length > 0) {
174
+ return items[0].label;
175
+ } else {
176
+ return "";
177
+ }
178
+ };
179
+ let popoverTimeout = null;
180
+ function closePopover(immediate) {
181
+ clearTimeout(popoverTimeout);
182
+ if (immediate) {
183
+ popoverVisible.value = false;
184
+ } else {
185
+ popoverTimeout = setTimeout(() => {
186
+ popoverVisible.value = false;
187
+ }, 2e3);
188
+ }
189
+ }
190
+ function openPopover() {
191
+ clearTimeout(popoverTimeout);
192
+ popoverVisible.value = true;
193
+ }
194
+ const filterTableData = computed(
195
+ () => (
196
+ //等于System时为全部
197
+ valueOptions.value.filter(
198
+ (data) => !searchValue.value || paramType.value == "system" || data.label.toLowerCase().includes(searchValue.value.toLowerCase()) || data.value.toLowerCase().includes(searchValue.value.toLowerCase())
199
+ )
200
+ )
201
+ );
202
+ watch(searchValue, () => {
203
+ if (paramType.value == "system") {
204
+ querySystemParams();
205
+ }
206
+ });
207
+ let lastSystemQuery = null;
208
+ function querySystemParams() {
209
+ if (lastSystemQuery == searchValue.value) {
210
+ return;
211
+ }
212
+ const param = {
213
+ query: searchValue.value
214
+ };
215
+ lastSystemQuery = searchValue.value;
216
+ http.post(window["$vueApp"].config.globalProperties.baseAPI + "/component/system-params/query", param).then((results) => {
217
+ const tempOptions = [];
218
+ for (let result of results) {
219
+ tempOptions.push({
220
+ value: result.propKey,
221
+ label: result.propKey + " (" + result.propValue + ")"
222
+ });
223
+ }
224
+ selectOptions.value.systemVarOptions = tempOptions;
225
+ if (paramType.value == "system") {
226
+ setValueOptions(paramType.value);
227
+ }
228
+ });
229
+ }
230
+ const tableHeight = computed(() => {
231
+ let height = 185;
232
+ if (paramType.value == "page") {
233
+ height = 170;
234
+ }
235
+ return height;
236
+ });
237
+ const searchWidthStyle = computed(() => {
238
+ const style = {};
239
+ if (paramType.value == "page") {
240
+ style.width = "210px";
241
+ }
242
+ return style;
243
+ });
244
+ function setSelectOptions() {
245
+ selectOptions.value.dataModelOptions = pageContextUtil.pageContextVarOptions.dataOptions;
246
+ selectOptions.value.pageVarOptions = pageContextUtil.pageContextVarOptions.pageVarOptions;
247
+ }
248
+ function formatter() {
249
+ if (props.modelValue) {
250
+ return paramType.value + "." + getValueLabel(paramType.value, paramValue.value);
251
+ }
252
+ return props.modelValue;
253
+ }
254
+ let paramTypeCheck = false;
255
+ function paramTypeChange(selParamType) {
256
+ if (selParamType) {
257
+ if (Array.isArray(selParamType)) {
258
+ if (selParamType.length > 0) {
259
+ selParamType = selParamType[0];
260
+ }
261
+ }
262
+ }
263
+ paramType.value = selParamType;
264
+ paramValue.value = "";
265
+ if (selectInputType.includes(selParamType)) {
266
+ showInput.value = false;
267
+ setValueOptions(selParamType);
268
+ } else {
269
+ showInput.value = true;
270
+ }
271
+ if (paramType.value == "system") {
272
+ querySystemParams();
273
+ }
274
+ paramTypeCheck = true;
275
+ }
276
+ function setValueOptions(value) {
277
+ if (value === "context") {
278
+ let options = contextVarOptions;
279
+ if (props.isRange) {
280
+ options = deepCopy(options);
281
+ for (let i = 0; i < options.length; i++) {
282
+ let o = options[i];
283
+ if (o.value == "currentDate") {
284
+ options.splice(i + 1, 0, {
285
+ value: "currentDate",
286
+ symbolUnit: "d",
287
+ symbol: "-",
288
+ type: "range"
289
+ });
290
+ break;
291
+ }
292
+ }
293
+ }
294
+ valueOptions.value = options;
295
+ } else if (value === "system") {
296
+ valueOptions.value = selectOptions.value.systemVarOptions || [];
297
+ } else if (value === "task") {
298
+ valueOptions.value = taskVarOptions;
299
+ } else if (value === "data") {
300
+ valueOptions.value = selectOptions.value.dataModelOptions || [];
301
+ } else if (value === "params") {
302
+ valueOptions.value = selectOptions.value.paramsVarOptions || [];
303
+ } else if (value === "page") {
304
+ valueOptions.value = selectOptions.value.pageVarOptions || [];
305
+ }
306
+ }
307
+ function clearSelect() {
308
+ defalutValue.value = "";
309
+ emits("update:modelValue", defalutValue.value);
310
+ popoverRef.value.hide();
311
+ }
312
+ function selectRow(row) {
313
+ if (row.type == "range") {
314
+ if (row.symbolNum === "") {
315
+ ElMessage.warning("周期不能为空!");
316
+ return;
317
+ }
318
+ if (isNaN(row.symbolNum)) {
319
+ ElMessage.warning("周期为无效的数字!");
320
+ return;
321
+ }
322
+ if (row.symbolNum != "0") {
323
+ paramValue.value = row.value + row.symbol + row.symbolNum + row.symbolUnit;
324
+ } else {
325
+ paramValue.value = row.value;
326
+ }
327
+ } else {
328
+ paramValue.value = row.value;
329
+ }
330
+ defalutValue.value = "${" + paramType.value + "." + paramValue.value + "}";
331
+ emits("update:modelValue", defalutValue.value, row.alias);
332
+ closePopover(true);
333
+ }
334
+ function addRequestParam(paramName) {
335
+ paramValue.value = paramName;
336
+ addInputParams();
337
+ }
338
+ function addInputParams() {
339
+ if (!paramValue.value) {
340
+ ElMessage.warning("请输入参数名");
341
+ return;
342
+ }
343
+ defalutValue.value = "${" + paramType.value + "." + paramValue.value + "}";
344
+ emits("update:modelValue", defalutValue.value);
345
+ closePopover(true);
346
+ }
347
+ function addPageParams() {
348
+ searchValue.value = searchValue.value.trim();
349
+ if (!searchValue.value) {
350
+ ElMessage.warning("请输入参数名");
351
+ return;
352
+ }
353
+ const tempValues = selectOptions.value.pageVarOptions || [];
354
+ for (let t of tempValues) {
355
+ if (t.value === searchValue.value) {
356
+ ElMessage.warning("该变量已存在!");
357
+ return;
358
+ }
359
+ }
360
+ const variable = {
361
+ code: getUuidv4(),
362
+ name: searchValue.value,
363
+ alias: searchValue.value,
364
+ type: "string",
365
+ defaultValue: ""
366
+ };
367
+ if (!pageContextUtil.pageContext.variables) {
368
+ pageContextUtil.pageContext.variables = [];
369
+ }
370
+ pageContextUtil.pageContext.variables.push(variable);
371
+ pageContextUtil.setPageContext(pageContextUtil.pageContext);
372
+ selectOptions.value.pageVarOptions = pageContextUtil.pageContextVarOptions.pageVarOptions;
373
+ valueOptions.value = selectOptions.value.pageVarOptions || [];
374
+ paramValue.value = searchValue.value;
375
+ defalutValue.value = "${" + paramType.value + "." + searchValue.value + "}";
376
+ searchValue.value = "";
377
+ emits("update:modelValue", defalutValue.value);
378
+ closePopover(true);
379
+ }
380
+ function getValueLabel(valueType, value) {
381
+ if (selectInputType.includes(valueType)) {
382
+ if (valueType === "context" && value && value.startsWith("currentDate") && value.length > 11) {
383
+ const str = value.substring(11);
384
+ const symbol = str.substring(0, 1);
385
+ const num = str.substring(1, str.length - 1);
386
+ const unit = str.substring(str.length - 1);
387
+ return num + symbolUnitFormatter(unit) + ("+" === symbol ? "后" : "前");
388
+ }
389
+ const option = valueOptions.value.find((item) => item.value === value);
390
+ if (option) {
391
+ return option.label;
392
+ }
393
+ }
394
+ return value;
395
+ }
396
+ const tableRef = ref();
397
+ function handSelectRow() {
398
+ if (!props.showLabel && !showInput.value) {
399
+ const index = filterTableData.value.findIndex((item) => item.value === paramValue.value);
400
+ if (index > -1) {
401
+ tableRef.value.setCurrentRow(filterTableData.value[index]);
402
+ }
403
+ }
404
+ }
405
+ function showPopover() {
406
+ openPopover();
407
+ nextTick(() => {
408
+ setSelectOptions();
409
+ if (paramType.value) {
410
+ setValueOptions(paramType.value);
411
+ }
412
+ handSelectRow();
413
+ });
414
+ }
415
+ return (_ctx, _cache) => {
416
+ const _component_el_icon = resolveComponent("el-icon");
417
+ const _component_el_input = resolveComponent("el-input");
418
+ const _component_el_cascader_panel = resolveComponent("el-cascader-panel");
419
+ const _component_el_col = resolveComponent("el-col");
420
+ const _component_el_empty = resolveComponent("el-empty");
421
+ const _component_el_button = resolveComponent("el-button");
422
+ const _component_el_table_column = resolveComponent("el-table-column");
423
+ const _component_el_option = resolveComponent("el-option");
424
+ const _component_el_select = resolveComponent("el-select");
425
+ const _component_el_table = resolveComponent("el-table");
426
+ const _component_el_row = resolveComponent("el-row");
427
+ const _component_el_popover = resolveComponent("el-popover");
428
+ return __props.showLabel ? (openBlock(), createElementBlock("span", _hoisted_1, toDisplayString(defalutValue.value), 1)) : (openBlock(), createBlock(_component_el_popover, {
429
+ key: 1,
430
+ ref_key: "popoverRef",
431
+ ref: popoverRef,
432
+ visible: popoverVisible.value,
433
+ width: 400
434
+ }, {
435
+ reference: withCtx(() => [
436
+ createVNode(_component_el_input, {
437
+ readonly: "",
438
+ size: __props.size,
439
+ title: defalutValue.value,
440
+ ref_key: "inputRef",
441
+ ref: inputRef,
442
+ onClick: showPopover,
443
+ formatter,
444
+ modelValue: defalutValue.value,
445
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => defalutValue.value = $event),
446
+ placeholder: "请选择"
447
+ }, {
448
+ suffix: withCtx(() => [
449
+ withDirectives(createVNode(_component_el_icon, {
450
+ style: { "cursor": "pointer" },
451
+ onClick: withModifiers(clearSelect, ["stop"])
452
+ }, {
453
+ default: withCtx(() => [
454
+ createVNode(unref(CircleClose))
455
+ ]),
456
+ _: 1
457
+ }, 512), [
458
+ [vShow, defalutValue.value]
459
+ ])
460
+ ]),
461
+ _: 1
462
+ }, 8, ["size", "title", "modelValue"])
463
+ ]),
464
+ default: withCtx(() => [
465
+ createVNode(_component_el_row, {
466
+ ref_key: "contentRef",
467
+ ref: contentRef
468
+ }, {
469
+ default: withCtx(() => [
470
+ createVNode(_component_el_col, { span: 8 }, {
471
+ default: withCtx(() => [
472
+ createVNode(_component_el_cascader_panel, {
473
+ modelValue: paramType.value,
474
+ "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => paramType.value = $event),
475
+ onChange: paramTypeChange,
476
+ props: { emitPath: true },
477
+ size: "small",
478
+ options: typeOptions.value,
479
+ style: { "height": "240px", "width": "100%" }
480
+ }, null, 8, ["modelValue", "options"])
481
+ ]),
482
+ _: 1
483
+ }),
484
+ !paramType.value ? (openBlock(), createBlock(_component_el_col, {
485
+ key: 0,
486
+ span: 16
487
+ }, {
488
+ default: withCtx(() => [
489
+ createVNode(_component_el_empty, {
490
+ description: "请选择类型",
491
+ "image-size": 40
492
+ })
493
+ ]),
494
+ _: 1
495
+ })) : showInput.value ? (openBlock(), createBlock(_component_el_col, {
496
+ key: 1,
497
+ span: 16,
498
+ style: { "padding-left": "10px" }
499
+ }, {
500
+ default: withCtx(() => [
501
+ createVNode(_component_el_input, {
502
+ style: { "width": "210px" },
503
+ size: "small",
504
+ modelValue: paramValue.value,
505
+ "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => paramValue.value = $event),
506
+ placeholder: "请手动输入"
507
+ }, null, 8, ["modelValue"]),
508
+ createVNode(_component_el_button, {
509
+ style: { "float": "right" },
510
+ onClick: addInputParams,
511
+ size: "small",
512
+ type: "primary",
513
+ icon: unref(Plus),
514
+ circle: ""
515
+ }, null, 8, ["icon"]),
516
+ createElementVNode("div", _hoisted_2, [
517
+ createVNode(_component_el_icon, null, {
518
+ default: withCtx(() => [
519
+ createVNode(unref(InfoFilled))
520
+ ]),
521
+ _: 1
522
+ }),
523
+ _hoisted_3
524
+ ]),
525
+ withDirectives(createElementVNode("div", _hoisted_4, [
526
+ createTextVNode(" 常用参数: "),
527
+ createVNode(_component_el_button, {
528
+ type: "primary",
529
+ size: "small",
530
+ onClick: _cache[3] || (_cache[3] = ($event) => addRequestParam("query"))
531
+ }, {
532
+ default: withCtx(() => [
533
+ createTextVNode("query")
534
+ ]),
535
+ _: 1
536
+ })
537
+ ], 512), [
538
+ [vShow, paramType.value == "request"]
539
+ ])
540
+ ]),
541
+ _: 1
542
+ })) : (openBlock(), createBlock(_component_el_col, {
543
+ key: 2,
544
+ span: 16,
545
+ style: { "padding-left": "10px" }
546
+ }, {
547
+ default: withCtx(() => [
548
+ createVNode(_component_el_input, {
549
+ size: "small",
550
+ modelValue: searchValue.value,
551
+ "onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => searchValue.value = $event),
552
+ placeholder: "搜索",
553
+ "suffix-icon": unref(Search),
554
+ style: normalizeStyle([{ "margin-bottom": "5px", "height": "25px" }, searchWidthStyle.value])
555
+ }, null, 8, ["modelValue", "suffix-icon", "style"]),
556
+ withDirectives(createVNode(_component_el_button, {
557
+ style: { "float": "right" },
558
+ onClick: addPageParams,
559
+ size: "small",
560
+ type: "primary",
561
+ icon: unref(Plus),
562
+ circle: ""
563
+ }, null, 8, ["icon"]), [
564
+ [vShow, paramType.value == "page"]
565
+ ]),
566
+ withDirectives(createElementVNode("div", _hoisted_5, [
567
+ createVNode(_component_el_icon, null, {
568
+ default: withCtx(() => [
569
+ createVNode(unref(InfoFilled))
570
+ ]),
571
+ _: 1
572
+ }),
573
+ _hoisted_6
574
+ ], 512), [
575
+ [vShow, paramType.value == "page"]
576
+ ]),
577
+ createVNode(_component_el_table, {
578
+ ref_key: "tableRef",
579
+ ref: tableRef,
580
+ height: tableHeight.value,
581
+ "show-header": false,
582
+ size: "small",
583
+ "current-row-key": "code",
584
+ "row-key": "code",
585
+ "tree-props": { children: "items" },
586
+ "highlight-current-row": true,
587
+ data: filterTableData.value
588
+ }, {
589
+ default: withCtx(() => [
590
+ createVNode(_component_el_table_column, { width: "65" }, {
591
+ default: withCtx((scope) => [
592
+ createVNode(_component_el_button, {
593
+ size: "small",
594
+ onClick: ($event) => selectRow(scope.row)
595
+ }, {
596
+ default: withCtx(() => [
597
+ createTextVNode(" 选择 ")
598
+ ]),
599
+ _: 2
600
+ }, 1032, ["onClick"])
601
+ ]),
602
+ _: 1
603
+ }),
604
+ createVNode(_component_el_table_column, {
605
+ label: "Date",
606
+ prop: "label"
607
+ }, {
608
+ default: withCtx((scope) => [
609
+ paramType.value == "context" && scope.row.type == "range" ? (openBlock(), createElementBlock("div", _hoisted_7, [
610
+ createVNode(_component_el_input, {
611
+ size: "small",
612
+ modelValue: scope.row.symbolNum,
613
+ "onUpdate:modelValue": ($event) => scope.row.symbolNum = $event,
614
+ placeholder: "",
615
+ style: { "width": "35px", "margin-left": "4px" }
616
+ }, null, 8, ["modelValue", "onUpdate:modelValue"]),
617
+ createVNode(_component_el_select, {
618
+ size: "small",
619
+ style: { "margin-left": "4px", "width": "50px" },
620
+ modelValue: scope.row.symbolUnit,
621
+ "onUpdate:modelValue": ($event) => scope.row.symbolUnit = $event,
622
+ placeholder: ""
623
+ }, {
624
+ default: withCtx(() => [
625
+ createVNode(_component_el_option, {
626
+ label: "天",
627
+ value: "d"
628
+ }),
629
+ createVNode(_component_el_option, {
630
+ label: "周",
631
+ value: "w"
632
+ }),
633
+ createVNode(_component_el_option, {
634
+ label: "月",
635
+ value: "m"
636
+ }),
637
+ createVNode(_component_el_option, {
638
+ label: "年",
639
+ value: "y"
640
+ })
641
+ ]),
642
+ _: 2
643
+ }, 1032, ["modelValue", "onUpdate:modelValue"]),
644
+ createVNode(_component_el_select, {
645
+ size: "small",
646
+ style: { "margin-left": "4px", "width": "50px" },
647
+ modelValue: scope.row.symbol,
648
+ "onUpdate:modelValue": ($event) => scope.row.symbol = $event,
649
+ placeholder: ""
650
+ }, {
651
+ default: withCtx(() => [
652
+ createVNode(_component_el_option, {
653
+ label: "前",
654
+ value: "-"
655
+ }),
656
+ createVNode(_component_el_option, {
657
+ label: "后",
658
+ value: "+"
659
+ })
660
+ ]),
661
+ _: 2
662
+ }, 1032, ["modelValue", "onUpdate:modelValue"])
663
+ ])) : createCommentVNode("", true),
664
+ paramType.value == "data" ? (openBlock(), createElementBlock("span", {
665
+ key: 1,
666
+ title: scope.row.label + " " + scope.row.value
667
+ }, toDisplayString(scope.row.label + " " + scope.row.value), 9, _hoisted_8)) : (openBlock(), createElementBlock("span", {
668
+ key: 2,
669
+ title: scope.row.label
670
+ }, toDisplayString(scope.row.label), 9, _hoisted_9))
671
+ ]),
672
+ _: 1
673
+ })
674
+ ]),
675
+ _: 1
676
+ }, 8, ["height", "data"]),
677
+ createElementVNode("div", _hoisted_10, "总计:" + toDisplayString(filterTableData.value.length), 1)
678
+ ]),
679
+ _: 1
680
+ }))
681
+ ]),
682
+ _: 1
683
+ }, 512)
684
+ ]),
685
+ _: 1
686
+ }, 8, ["visible"]));
687
+ };
688
+ }
689
+ });
690
+ export {
691
+ _sfc_main as default
692
+ };