@farris/ui-vue 1.2.7 → 1.2.8
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/components/accordion/index.esm.js +79 -79
- package/components/avatar/index.esm.js +393 -440
- package/components/border-editor/index.esm.js +4 -4
- package/components/button/index.esm.js +1 -1
- package/components/button-edit/index.esm.js +353 -444
- package/components/button-group/index.esm.js +5 -5
- package/components/calendar/index.esm.js +176 -176
- package/components/capsule/index.esm.js +93 -93
- package/components/checkbox/index.esm.js +496 -542
- package/components/color-picker/index.esm.js +1 -1
- package/components/combo-list/index.esm.js +437 -483
- package/components/combo-tree/index.esm.js +8 -8
- package/components/component/index.esm.js +89 -89
- package/components/condition/index.esm.js +839 -726
- package/components/content-container/index.esm.js +61 -61
- package/components/data-grid/index.esm.js +4702 -4972
- package/components/data-view/index.esm.js +2999 -2875
- package/components/date-picker/index.esm.js +2626 -2672
- package/components/dependent-base/style.js +1 -0
- package/components/dependent-fluid/style.js +1 -0
- package/components/dependent-icon/style.js +1 -0
- package/components/dependent-input/style.js +1 -0
- package/components/dependent-table/style.js +1 -0
- package/components/designer-canvas/index.esm.js +478 -475
- package/components/designer-outline/index.esm.js +173 -131
- package/components/discussion-editor/index.esm.js +1 -1
- package/components/dropdown/index.esm.js +73 -73
- package/components/dynamic-form/index.esm.js +934 -976
- package/components/dynamic-resolver/index.esm.js +67 -35
- package/components/dynamic-view/index.esm.js +258 -249
- package/components/enum-editor/index.esm.js +3 -3
- package/components/events-editor/index.esm.js +178 -178
- package/components/expression-editor/index.esm.js +105 -105
- package/components/external-container/index.esm.js +1892 -1775
- package/components/field-selector/index.css +1 -1
- package/components/field-selector/index.esm.js +5245 -5514
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +1483 -1556
- package/components/flow-canvas/index.esm.js +678 -675
- package/components/image-cropper/index.esm.js +266 -266
- package/components/input-group/index.esm.js +668 -714
- package/components/layout/index.esm.js +148 -148
- package/components/list-nav/index.esm.js +109 -109
- package/components/list-view/index.esm.js +1679 -1563
- package/components/lookup/index.css +1 -1
- package/components/lookup/index.esm.js +6596 -6865
- package/components/mapping-editor/index.esm.js +5592 -5862
- package/components/message-box/index.esm.js +1 -1
- package/components/modal/index.esm.js +1 -1
- package/components/nav/index.esm.js +86 -86
- package/components/number-range/index.esm.js +1120 -0
- package/components/number-range/package.json +8 -0
- package/components/number-range/style.js +6 -0
- package/components/number-spinner/index.esm.js +1146 -0
- package/components/number-spinner/package.json +8 -0
- package/components/number-spinner/style.js +4 -0
- package/components/order/index.esm.js +988 -1034
- package/components/page-footer/index.esm.js +106 -106
- package/components/page-header/index.esm.js +1088 -1296
- package/components/pagination/index.esm.js +252 -252
- package/components/progress/index.esm.js +37 -37
- package/components/property-editor/index.esm.js +1416 -1462
- package/components/property-panel/index.css +1 -1
- package/components/property-panel/index.esm.js +757 -830
- package/components/query-solution/index.css +1 -0
- package/components/query-solution/index.esm.js +6935 -0
- package/components/query-solution/package.json +8 -0
- package/components/query-solution/style.js +2 -0
- package/components/radio-button/index.esm.js +64 -64
- package/components/radio-group/index.esm.js +452 -498
- package/components/rate/index.esm.js +92 -92
- package/components/response-layout/index.esm.js +33 -33
- package/components/response-layout-editor/index.esm.js +117 -117
- package/components/response-toolbar/index.esm.js +1021 -1238
- package/components/schema-selector/index.esm.js +3215 -3308
- package/components/search-box/index.esm.js +143 -143
- package/components/section/index.esm.js +209 -209
- package/components/smoke-detector/index.esm.js +22 -22
- package/components/spacing-editor/index.esm.js +2 -2
- package/components/splitter/index.esm.js +1097 -394
- package/components/step/index.esm.js +153 -153
- package/components/switch/index.esm.js +442 -488
- package/components/tabs/index.esm.js +1835 -2004
- package/components/tags/index.esm.js +215 -215
- package/components/text/index.esm.js +53 -53
- package/components/textarea/index.esm.js +451 -482
- package/components/time-picker/index.esm.js +1345 -1392
- package/components/transfer/index.esm.js +135 -135
- package/components/tree-grid/index.css +1 -1
- package/components/tree-grid/index.esm.js +5761 -6020
- package/components/tree-view/index.esm.js +2380 -2253
- package/components/uploader/index.esm.js +1 -1
- package/components/verify-detail/index.esm.js +232 -232
- package/components/video/index.esm.js +136 -136
- package/components/weather/index.esm.js +2 -2
- package/farris.all.esm.js +31630 -31224
- package/farris.all.umd.cjs +9 -9
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/checkbox/index.d.ts +1 -0
- package/types/data-grid/src/designer/column-header.design.component.d.ts +1 -1
- package/types/data-grid/src/designer/data-grid-column.props.d.ts +1 -0
- package/types/data-view/composition/types.d.ts +1 -1
- package/types/designer-canvas/src/composition/dg-control.d.ts +16 -350
- package/types/designer-canvas/src/types.d.ts +1 -1
- package/types/dynamic-form/index.d.ts +1 -0
- package/types/dynamic-form/src/types.d.ts +1 -1
- package/types/dynamic-resolver/index.d.ts +1 -0
- package/types/dynamic-resolver/src/binding-resolver.d.ts +1 -0
- package/types/dynamic-view/src/dynamic-view.component.d.ts +1 -1
- package/types/lookup/src/property-config/lookup.property-config.d.ts +2 -1
- package/types/modal/src/modal.props.d.ts +1 -4
- package/types/property-panel/src/composition/entity/base-property.d.ts +0 -12
- package/types/property-panel/src/composition/entity/input-base-property.d.ts +11 -26
- package/types/property-panel/src/composition/entity/schema-dom-mapping.d.ts +10 -8
- package/types/tabs/src/designer/tab-toolbar-item.props.d.ts +19 -0
- package/types/tabs/src/property-config/tabs.property-config.d.ts +6 -6
- package/types/tree-grid/src/designer/use-designer-rules.d.ts +3 -0
- package/types/tree-grid/src/property-config/tree-grid.property-config.d.ts +11 -0
- package/types/tree-grid/src/schema/column-resolver.d.ts +1 -1
- package/types/tree-grid/src/tree-grid.props.d.ts +8 -0
- package/components/accordion/index.umd.cjs +0 -1
- package/components/avatar/index.umd.cjs +0 -1
- package/components/border-editor/index.umd.cjs +0 -1
- package/components/button/index.umd.cjs +0 -1
- package/components/button-edit/index.umd.cjs +0 -1
- package/components/button-group/index.umd.cjs +0 -1
- package/components/calculator/index.umd.cjs +0 -1
- package/components/calendar/index.umd.cjs +0 -1
- package/components/capsule/index.umd.cjs +0 -1
- package/components/checkbox/index.umd.cjs +0 -1
- package/components/color-picker/index.umd.cjs +0 -3
- package/components/combo-list/index.umd.cjs +0 -1
- package/components/combo-tree/index.umd.cjs +0 -1
- package/components/common/index.umd.cjs +0 -1
- package/components/component/index.umd.cjs +0 -1
- package/components/condition/index.umd.cjs +0 -1
- package/components/content-container/index.umd.cjs +0 -1
- package/components/data-grid/index.umd.cjs +0 -1
- package/components/data-view/index.umd.cjs +0 -1
- package/components/date-picker/index.umd.cjs +0 -1
- package/components/designer-canvas/index.umd.cjs +0 -1
- package/components/designer-outline/index.umd.cjs +0 -1
- package/components/designer-toolbox/index.umd.cjs +0 -1
- package/components/discussion-editor/index.umd.cjs +0 -3
- package/components/discussion-list/index.umd.cjs +0 -1
- package/components/drawer/index.umd.cjs +0 -1
- package/components/dropdown/index.umd.cjs +0 -2
- package/components/dynamic-form/index.umd.cjs +0 -1
- package/components/dynamic-resolver/index.umd.cjs +0 -1
- package/components/dynamic-view/index.umd.cjs +0 -1
- package/components/enum-editor/index.umd.cjs +0 -1
- package/components/events-editor/index.umd.cjs +0 -1
- package/components/expression-editor/index.umd.cjs +0 -1
- package/components/external-container/index.umd.cjs +0 -1
- package/components/field-selector/index.umd.cjs +0 -1
- package/components/filter-bar/index.umd.cjs +0 -1
- package/components/flow-canvas/index.umd.cjs +0 -1
- package/components/image-cropper/index.umd.cjs +0 -1
- package/components/input-group/index.umd.cjs +0 -1
- package/components/layout/index.umd.cjs +0 -1
- package/components/list-nav/index.umd.cjs +0 -1
- package/components/list-view/index.umd.cjs +0 -1
- package/components/loading/index.umd.cjs +0 -8
- package/components/locale/index.umd.cjs +0 -1
- package/components/lookup/index.umd.cjs +0 -1
- package/components/mapping-editor/index.umd.cjs +0 -1
- package/components/message-box/index.umd.cjs +0 -1
- package/components/modal/index.umd.cjs +0 -1
- package/components/nav/index.umd.cjs +0 -3
- package/components/notify/index.umd.cjs +0 -1
- package/components/order/index.umd.cjs +0 -1
- package/components/page-footer/index.umd.cjs +0 -1
- package/components/page-header/index.umd.cjs +0 -1
- package/components/pagination/index.umd.cjs +0 -1
- package/components/popover/index.umd.cjs +0 -1
- package/components/progress/index.umd.cjs +0 -3
- package/components/property-editor/index.umd.cjs +0 -3
- package/components/property-panel/index.umd.cjs +0 -1
- package/components/radio-button/index.umd.cjs +0 -1
- package/components/radio-group/index.umd.cjs +0 -1
- package/components/rate/index.umd.cjs +0 -1
- package/components/response-layout/index.umd.cjs +0 -1
- package/components/response-layout-editor/index.umd.cjs +0 -1
- package/components/response-toolbar/index.umd.cjs +0 -1
- package/components/schema-selector/index.umd.cjs +0 -8
- package/components/search-box/index.umd.cjs +0 -1
- package/components/section/index.umd.cjs +0 -1
- package/components/smoke-detector/index.umd.cjs +0 -1
- package/components/spacing-editor/index.umd.cjs +0 -1
- package/components/splitter/index.umd.cjs +0 -1
- package/components/step/index.umd.cjs +0 -1
- package/components/switch/index.umd.cjs +0 -1
- package/components/tabs/index.umd.cjs +0 -1
- package/components/tags/index.umd.cjs +0 -1
- package/components/text/index.umd.cjs +0 -1
- package/components/textarea/index.umd.cjs +0 -1
- package/components/time-picker/index.umd.cjs +0 -1
- package/components/tooltip/index.umd.cjs +0 -1
- package/components/transfer/index.umd.cjs +0 -1
- package/components/tree-grid/index.umd.cjs +0 -1
- package/components/tree-view/index.umd.cjs +0 -1
- package/components/uploader/index.umd.cjs +0 -2
- package/components/verify-detail/index.umd.cjs +0 -1
- package/components/video/index.umd.cjs +0 -1
- package/components/weather/index.umd.cjs +0 -16
|
@@ -1,70 +1,71 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { ref as I, computed as
|
|
5
|
-
import
|
|
6
|
-
import { cloneDeep as
|
|
7
|
-
import
|
|
1
|
+
var Ce = Object.defineProperty;
|
|
2
|
+
var ke = (e, t, n) => t in e ? Ce(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
|
+
var T = (e, t, n) => ke(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
+
import { ref as I, computed as O, watch as z, defineComponent as X, onBeforeUnmount as Te, createVNode as k, createTextVNode as Y, onMounted as _, nextTick as oe, reactive as Fe, withDirectives as xe, resolveDirective as we, Fragment as re, mergeProps as Be } from "vue";
|
|
5
|
+
import Ie, { FDynamicFormGroup as Se } from "../dynamic-form/index.esm.js";
|
|
6
|
+
import { cloneDeep as J } from "lodash-es";
|
|
7
|
+
import te from "../combo-list/index.esm.js";
|
|
8
8
|
import "bignumber.js";
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
import
|
|
26
|
-
import
|
|
27
|
-
import
|
|
28
|
-
import _e from "
|
|
29
|
-
import
|
|
30
|
-
import
|
|
31
|
-
import
|
|
32
|
-
import
|
|
33
|
-
import
|
|
34
|
-
import
|
|
35
|
-
import
|
|
36
|
-
import
|
|
37
|
-
import
|
|
38
|
-
import
|
|
39
|
-
import
|
|
40
|
-
import
|
|
41
|
-
import
|
|
42
|
-
import
|
|
43
|
-
import
|
|
44
|
-
import
|
|
45
|
-
import
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import
|
|
50
|
-
import
|
|
51
|
-
import
|
|
52
|
-
import
|
|
53
|
-
import
|
|
54
|
-
import
|
|
55
|
-
import wt from "
|
|
56
|
-
import
|
|
57
|
-
import
|
|
58
|
-
import
|
|
59
|
-
import
|
|
60
|
-
import
|
|
61
|
-
import
|
|
62
|
-
import
|
|
63
|
-
import
|
|
64
|
-
import
|
|
65
|
-
import
|
|
66
|
-
import "
|
|
67
|
-
|
|
9
|
+
import Ve, { useNumber as Ee, useFormat as Me, useSpinner as Pe, useTextBox as Oe } from "../number-spinner/index.esm.js";
|
|
10
|
+
import je from "../accordion/index.esm.js";
|
|
11
|
+
import Le from "../avatar/index.esm.js";
|
|
12
|
+
import Ne from "../button-edit/index.esm.js";
|
|
13
|
+
import Ae from "../button-group/index.esm.js";
|
|
14
|
+
import Ge from "../calendar/index.esm.js";
|
|
15
|
+
import $e from "../capsule/index.esm.js";
|
|
16
|
+
import Re from "../checkbox/index.esm.js";
|
|
17
|
+
import qe from "../combo-tree/index.esm.js";
|
|
18
|
+
import De from "../component/index.esm.js";
|
|
19
|
+
import We from "../color-picker/index.esm.js";
|
|
20
|
+
import ze from "../content-container/index.esm.js";
|
|
21
|
+
import Ue from "../date-picker/index.esm.js";
|
|
22
|
+
import He from "../data-grid/index.esm.js";
|
|
23
|
+
import Qe from "../dropdown/index.esm.js";
|
|
24
|
+
import Ze from "../events-editor/index.esm.js";
|
|
25
|
+
import Je from "../filter-bar/index.esm.js";
|
|
26
|
+
import Xe from "../field-selector/index.esm.js";
|
|
27
|
+
import Ye from "../image-cropper/index.esm.js";
|
|
28
|
+
import _e from "../input-group/index.esm.js";
|
|
29
|
+
import Ke from "../layout/index.esm.js";
|
|
30
|
+
import et from "../list-nav/index.esm.js";
|
|
31
|
+
import tt from "../list-view/index.esm.js";
|
|
32
|
+
import nt from "../lookup/index.esm.js";
|
|
33
|
+
import ot from "../mapping-editor/index.esm.js";
|
|
34
|
+
import rt from "../nav/index.esm.js";
|
|
35
|
+
import at from "../number-range/index.esm.js";
|
|
36
|
+
import it from "../order/index.esm.js";
|
|
37
|
+
import lt from "../page-header/index.esm.js";
|
|
38
|
+
import st from "../page-footer/index.esm.js";
|
|
39
|
+
import ut from "../pagination/index.esm.js";
|
|
40
|
+
import ct from "../progress/index.esm.js";
|
|
41
|
+
import dt from "../query-solution/index.esm.js";
|
|
42
|
+
import pt from "../radio-group/index.esm.js";
|
|
43
|
+
import mt from "../rate/index.esm.js";
|
|
44
|
+
import ft from "../response-toolbar/index.esm.js";
|
|
45
|
+
import gt from "../response-layout/index.esm.js";
|
|
46
|
+
import ht from "../response-layout-editor/index.esm.js";
|
|
47
|
+
import vt from "../search-box/index.esm.js";
|
|
48
|
+
import yt from "../section/index.esm.js";
|
|
49
|
+
import bt from "../smoke-detector/index.esm.js";
|
|
50
|
+
import Ct from "../splitter/index.esm.js";
|
|
51
|
+
import kt from "../step/index.esm.js";
|
|
52
|
+
import Tt from "../switch/index.esm.js";
|
|
53
|
+
import Ft from "../tabs/index.esm.js";
|
|
54
|
+
import xt from "../tags/index.esm.js";
|
|
55
|
+
import wt from "../text/index.esm.js";
|
|
56
|
+
import Bt from "../time-picker/index.esm.js";
|
|
57
|
+
import It from "../transfer/index.esm.js";
|
|
58
|
+
import St from "../tree-view/index.esm.js";
|
|
59
|
+
import Vt from "../uploader/index.esm.js";
|
|
60
|
+
import Et from "../verify-detail/index.esm.js";
|
|
61
|
+
import Mt from "../weather/index.esm.js";
|
|
62
|
+
import Pt from "../video/index.esm.js";
|
|
63
|
+
import Ot from "../textarea/index.esm.js";
|
|
64
|
+
import jt from "../schema-selector/index.esm.js";
|
|
65
|
+
import Lt from "../tree-grid/index.esm.js";
|
|
66
|
+
import "../external-container/index.esm.js";
|
|
67
|
+
import "../dynamic-resolver/index.esm.js";
|
|
68
|
+
const ue = {
|
|
68
69
|
conditions: { type: Array, default: [] },
|
|
69
70
|
fields: { type: Array, default: [] },
|
|
70
71
|
key: { type: String, default: "" },
|
|
@@ -73,11 +74,11 @@ const ae = {
|
|
|
73
74
|
*/
|
|
74
75
|
isControlInline: { type: Boolean, default: !0 }
|
|
75
76
|
};
|
|
76
|
-
class
|
|
77
|
+
class Nt {
|
|
77
78
|
constructor(t = { value: [] }) {
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
79
|
+
T(this, "editorType", "check-box");
|
|
80
|
+
T(this, "value");
|
|
81
|
+
T(this, "valueType", "boolean");
|
|
81
82
|
this.value = t.value;
|
|
82
83
|
}
|
|
83
84
|
clear() {
|
|
@@ -93,13 +94,13 @@ class Ot {
|
|
|
93
94
|
return this.value.length === 0;
|
|
94
95
|
}
|
|
95
96
|
}
|
|
96
|
-
class
|
|
97
|
+
class At {
|
|
97
98
|
constructor(t = { textValue: "", value: "", valueField: "" }) {
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
99
|
+
T(this, "editorType", "combo-lookup");
|
|
100
|
+
T(this, "textValue");
|
|
101
|
+
T(this, "value");
|
|
102
|
+
T(this, "valueField");
|
|
103
|
+
T(this, "valueType", "text");
|
|
103
104
|
this.textValue = t.textValue, this.value = t.value, this.valueField = t.valueField;
|
|
104
105
|
}
|
|
105
106
|
clear() {
|
|
@@ -113,11 +114,11 @@ class jt {
|
|
|
113
114
|
return t[n[0]];
|
|
114
115
|
}
|
|
115
116
|
getTextValue(t) {
|
|
116
|
-
const n = t.split("."), o = this.value.split(",").map((r) => this.getPropValue(r,
|
|
117
|
+
const n = t.split("."), o = this.value.split(",").map((r) => this.getPropValue(r, J(n)));
|
|
117
118
|
return o && o.length ? o.join(",") : "";
|
|
118
119
|
}
|
|
119
120
|
getValue() {
|
|
120
|
-
const t = this.valueField.split("."), n = this.value.split(",").map((o) => this.getPropValue(o,
|
|
121
|
+
const t = this.valueField.split("."), n = this.value.split(",").map((o) => this.getPropValue(o, J(t)));
|
|
121
122
|
return n && n.length ? n.join(",") : "";
|
|
122
123
|
}
|
|
123
124
|
setValue(t) {
|
|
@@ -127,11 +128,11 @@ class jt {
|
|
|
127
128
|
return !this.valueField;
|
|
128
129
|
}
|
|
129
130
|
}
|
|
130
|
-
class
|
|
131
|
+
class Gt {
|
|
131
132
|
constructor(t = { value: "" }) {
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
133
|
+
T(this, "editorType", "date-picker");
|
|
134
|
+
T(this, "value");
|
|
135
|
+
T(this, "valueType", "datetime");
|
|
135
136
|
this.value = t.value;
|
|
136
137
|
}
|
|
137
138
|
setValue(t) {
|
|
@@ -147,12 +148,12 @@ class Lt {
|
|
|
147
148
|
this.value = void 0;
|
|
148
149
|
}
|
|
149
150
|
}
|
|
150
|
-
class
|
|
151
|
+
class ae {
|
|
151
152
|
constructor(t = { begin: "", end: "" }) {
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
153
|
+
T(this, "editorType", "date-range");
|
|
154
|
+
T(this, "begin", "");
|
|
155
|
+
T(this, "end", "");
|
|
156
|
+
T(this, "valueType", "datetime");
|
|
156
157
|
this.begin = t.begin, this.end = t.end;
|
|
157
158
|
}
|
|
158
159
|
clear() {
|
|
@@ -168,11 +169,11 @@ class oe {
|
|
|
168
169
|
return !this.begin || !this.end;
|
|
169
170
|
}
|
|
170
171
|
}
|
|
171
|
-
class
|
|
172
|
+
class $t {
|
|
172
173
|
constructor(t = { value: "" }) {
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
174
|
+
T(this, "editorType", "datetime-picker");
|
|
175
|
+
T(this, "value");
|
|
176
|
+
T(this, "valueType", "datetime");
|
|
176
177
|
this.value = t.value;
|
|
177
178
|
}
|
|
178
179
|
clear() {
|
|
@@ -188,14 +189,14 @@ class At {
|
|
|
188
189
|
return !this.value;
|
|
189
190
|
}
|
|
190
191
|
}
|
|
191
|
-
class
|
|
192
|
+
class Rt {
|
|
192
193
|
// 旧结构无,新结构为选中的value值,多选是以,分割的字符串
|
|
193
194
|
constructor(t = { value: "", dispalyText: "" }) {
|
|
194
|
-
|
|
195
|
-
|
|
195
|
+
T(this, "editorType", "combo-list");
|
|
196
|
+
T(this, "value");
|
|
196
197
|
// 旧结构{Type: '', Content: {value: string, name: string}} 新结构Array[{value: string, name: string}]
|
|
197
|
-
|
|
198
|
-
|
|
198
|
+
T(this, "valueType", "enum");
|
|
199
|
+
T(this, "displayText");
|
|
199
200
|
this.displayText = t.dispalyText, this.value = t.value;
|
|
200
201
|
}
|
|
201
202
|
clear() {
|
|
@@ -211,18 +212,18 @@ class Nt {
|
|
|
211
212
|
return !this.displayText;
|
|
212
213
|
}
|
|
213
214
|
}
|
|
214
|
-
class
|
|
215
|
+
class qt {
|
|
215
216
|
constructor(t = { value: [], displayText: "", displayField: "", isInputText: !1 }) {
|
|
216
|
-
|
|
217
|
+
T(this, "editorType", "input-group");
|
|
217
218
|
// 通过弹窗返回的若干个值对象构成的数组
|
|
218
|
-
|
|
219
|
-
|
|
219
|
+
T(this, "value");
|
|
220
|
+
T(this, "valueType", "text");
|
|
220
221
|
// 控件内显示的值
|
|
221
|
-
|
|
222
|
+
T(this, "displayText");
|
|
222
223
|
// 弹窗模式下,取列表中哪个字段的值映射到当前字段
|
|
223
|
-
|
|
224
|
+
T(this, "valueField");
|
|
224
225
|
// 是否是手动输入的值
|
|
225
|
-
|
|
226
|
+
T(this, "isInputText");
|
|
226
227
|
this.value = t.value, this.displayText = t.displayText, this.valueField = t.displayField, this.isInputText = t.isInputText;
|
|
227
228
|
}
|
|
228
229
|
clear() {
|
|
@@ -236,11 +237,11 @@ class $t {
|
|
|
236
237
|
return t[n[0]];
|
|
237
238
|
}
|
|
238
239
|
getTextValue(t) {
|
|
239
|
-
const n = t.split("."), o = this.value.map((r) => this.getPropValue(r,
|
|
240
|
+
const n = t.split("."), o = this.value.map((r) => this.getPropValue(r, J(n)));
|
|
240
241
|
return o && o.length ? o.join(",") : "";
|
|
241
242
|
}
|
|
242
243
|
getValue() {
|
|
243
|
-
const t = this.valueField.split(".") || [], n = this.value.map((o) => this.getPropValue(o,
|
|
244
|
+
const t = this.valueField.split(".") || [], n = this.value.map((o) => this.getPropValue(o, J(t)));
|
|
244
245
|
return n && n.length ? n.join(",") : "";
|
|
245
246
|
}
|
|
246
247
|
setValue(t) {
|
|
@@ -250,15 +251,15 @@ class $t {
|
|
|
250
251
|
return !this.displayText;
|
|
251
252
|
}
|
|
252
253
|
}
|
|
253
|
-
class
|
|
254
|
+
class Dt {
|
|
254
255
|
constructor(t = { textValue: "", value: [], valueField: "", isInputText: !1 }) {
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
256
|
+
T(this, "editorType", "lookup");
|
|
257
|
+
T(this, "textValue");
|
|
258
|
+
T(this, "value");
|
|
259
|
+
T(this, "valueField");
|
|
260
|
+
T(this, "valueType", "text");
|
|
260
261
|
// 帮助的值是否为手动输入的任意值,对应帮助的任意输入属性nosearch
|
|
261
|
-
|
|
262
|
+
T(this, "isInputText");
|
|
262
263
|
this.value = t.value, this.valueField = t.valueField, this.textValue = t.textValue, this.isInputText = t.isInputText;
|
|
263
264
|
}
|
|
264
265
|
clear() {
|
|
@@ -286,11 +287,11 @@ class Gt {
|
|
|
286
287
|
return !this.value.length;
|
|
287
288
|
}
|
|
288
289
|
}
|
|
289
|
-
class
|
|
290
|
+
class Wt {
|
|
290
291
|
constructor(t = { value: "" }) {
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
292
|
+
T(this, "editorType", "month-picker");
|
|
293
|
+
T(this, "value");
|
|
294
|
+
T(this, "valueType", "datetime");
|
|
294
295
|
this.value = t.value;
|
|
295
296
|
}
|
|
296
297
|
setValue(t) {
|
|
@@ -306,12 +307,12 @@ class Rt {
|
|
|
306
307
|
return !this.value;
|
|
307
308
|
}
|
|
308
309
|
}
|
|
309
|
-
class
|
|
310
|
+
class zt {
|
|
310
311
|
constructor(t = { begin: "", end: "" }) {
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
312
|
+
T(this, "editorType", "month-range");
|
|
313
|
+
T(this, "begin");
|
|
314
|
+
T(this, "end");
|
|
315
|
+
T(this, "valueType", "datetime");
|
|
315
316
|
this.begin = t.begin, this.end = t.end;
|
|
316
317
|
}
|
|
317
318
|
clear() {
|
|
@@ -327,12 +328,12 @@ class qt {
|
|
|
327
328
|
return !this.begin || !this.end;
|
|
328
329
|
}
|
|
329
330
|
}
|
|
330
|
-
class
|
|
331
|
+
class Ut {
|
|
331
332
|
constructor(t = { begin: null, end: null }) {
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
333
|
+
T(this, "editorType", "number-range");
|
|
334
|
+
T(this, "begin");
|
|
335
|
+
T(this, "end");
|
|
336
|
+
T(this, "valueType", "number");
|
|
336
337
|
this.begin = t.begin == null ? null : parseFloat(t.begin), this.end = t.end == null ? null : parseFloat(t.end);
|
|
337
338
|
}
|
|
338
339
|
clear() {
|
|
@@ -351,11 +352,11 @@ class Dt {
|
|
|
351
352
|
return this.begin == null && this.end == null;
|
|
352
353
|
}
|
|
353
354
|
}
|
|
354
|
-
class
|
|
355
|
+
class Ht {
|
|
355
356
|
constructor(t = { value: "" }) {
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
357
|
+
T(this, "editorType", "number-spinner");
|
|
358
|
+
T(this, "value");
|
|
359
|
+
T(this, "valueType", "number");
|
|
359
360
|
this.value = t.value == null ? null : parseFloat(t.value);
|
|
360
361
|
}
|
|
361
362
|
clear() {
|
|
@@ -371,11 +372,11 @@ class Wt {
|
|
|
371
372
|
return this.value == null;
|
|
372
373
|
}
|
|
373
374
|
}
|
|
374
|
-
class
|
|
375
|
+
class Qt {
|
|
375
376
|
constructor(t = { value: null }) {
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
377
|
+
T(this, "editorType", "radio-group");
|
|
378
|
+
T(this, "value");
|
|
379
|
+
T(this, "valueType", "enum");
|
|
379
380
|
this.value = t.value;
|
|
380
381
|
}
|
|
381
382
|
clear() {
|
|
@@ -391,11 +392,11 @@ class zt {
|
|
|
391
392
|
return !this.value;
|
|
392
393
|
}
|
|
393
394
|
}
|
|
394
|
-
class
|
|
395
|
+
class ce {
|
|
395
396
|
constructor(t = { value: "" }) {
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
397
|
+
T(this, "editorType", "text");
|
|
398
|
+
T(this, "value");
|
|
399
|
+
T(this, "valueType", "text");
|
|
399
400
|
this.value = t.value;
|
|
400
401
|
}
|
|
401
402
|
clear() {
|
|
@@ -411,45 +412,45 @@ class le {
|
|
|
411
412
|
return !this.value;
|
|
412
413
|
}
|
|
413
414
|
}
|
|
414
|
-
function
|
|
415
|
+
function de() {
|
|
415
416
|
function e(t, n) {
|
|
416
417
|
switch (t) {
|
|
417
418
|
case "check-box":
|
|
418
|
-
return new Ot(n);
|
|
419
|
-
case "combo-list":
|
|
420
419
|
return new Nt(n);
|
|
420
|
+
case "combo-list":
|
|
421
|
+
return new Rt(n);
|
|
421
422
|
case "combo-lookup":
|
|
422
|
-
return new
|
|
423
|
+
return new At(n);
|
|
423
424
|
case "input-group":
|
|
424
|
-
return new
|
|
425
|
+
return new qt(n);
|
|
425
426
|
case "date-picker":
|
|
426
|
-
return new
|
|
427
|
+
return new Gt(n);
|
|
427
428
|
case "date-range":
|
|
428
|
-
return new
|
|
429
|
+
return new ae(n);
|
|
429
430
|
case "datetime-picker":
|
|
430
|
-
return new
|
|
431
|
+
return new $t(n);
|
|
431
432
|
case "datetime-range":
|
|
432
|
-
return new
|
|
433
|
+
return new ae(n);
|
|
433
434
|
case "lookup":
|
|
434
|
-
return new
|
|
435
|
+
return new Dt(n);
|
|
435
436
|
case "month-picker":
|
|
436
|
-
return new
|
|
437
|
+
return new Wt(n);
|
|
437
438
|
case "month-range":
|
|
438
|
-
return new
|
|
439
|
+
return new zt(n);
|
|
439
440
|
case "number-range":
|
|
440
|
-
return new
|
|
441
|
+
return new Ut(n);
|
|
441
442
|
case "number-spinner":
|
|
442
|
-
return new
|
|
443
|
+
return new Ht(n);
|
|
443
444
|
case "radio-group":
|
|
444
|
-
return new
|
|
445
|
+
return new Qt(n);
|
|
445
446
|
default:
|
|
446
|
-
return new
|
|
447
|
+
return new ce(n);
|
|
447
448
|
}
|
|
448
449
|
}
|
|
449
450
|
return { createConditionValue: e };
|
|
450
451
|
}
|
|
451
|
-
function
|
|
452
|
-
const n = I(e.fields), o = I([]), r = /* @__PURE__ */ new Map(), { createConditionValue: p } =
|
|
452
|
+
function pe(e, t) {
|
|
453
|
+
const n = I(e.fields), o = I([]), r = /* @__PURE__ */ new Map(), { createConditionValue: p } = de();
|
|
453
454
|
function d(l) {
|
|
454
455
|
switch (l.editor ? l.editor.type : "input-group") {
|
|
455
456
|
case "date-range":
|
|
@@ -467,7 +468,7 @@ function ue(e, t) {
|
|
|
467
468
|
function b(l) {
|
|
468
469
|
return l.map((c) => Object.assign({}, c)).map((c) => (c.editor = d(c), c));
|
|
469
470
|
}
|
|
470
|
-
function
|
|
471
|
+
function w(l = !0) {
|
|
471
472
|
n.value.reduce((u, c) => (l || (c.editor = d(c)), u.set(c.labelCode, c), u), r);
|
|
472
473
|
}
|
|
473
474
|
function s(l) {
|
|
@@ -478,17 +479,17 @@ function ue(e, t) {
|
|
|
478
479
|
}
|
|
479
480
|
}), l;
|
|
480
481
|
}
|
|
481
|
-
return { convertToSingleControl: b, fields: n, fieldMap: r, fieldConditions: o, loadFieldConfigs:
|
|
482
|
+
return { convertToSingleControl: b, fields: n, fieldMap: r, fieldConditions: o, loadFieldConfigs: w, initialConditionValue: s };
|
|
482
483
|
}
|
|
483
|
-
function
|
|
484
|
-
const o = I(null), r = I(n), p = I(0), d =
|
|
484
|
+
function Zt(e, t, n) {
|
|
485
|
+
const o = I(null), r = I(n), p = I(0), d = O(() => s(p.value));
|
|
485
486
|
function b() {
|
|
486
|
-
r.value && (o.value = new ResizeObserver(
|
|
487
|
+
r.value && (o.value = new ResizeObserver(w((l) => {
|
|
487
488
|
const u = l[0];
|
|
488
489
|
p.value = u.contentRect.width;
|
|
489
490
|
})), o.value.observe(r.value));
|
|
490
491
|
}
|
|
491
|
-
function
|
|
492
|
+
function w(l, u) {
|
|
492
493
|
let c = null;
|
|
493
494
|
return function() {
|
|
494
495
|
const V = arguments;
|
|
@@ -501,70 +502,70 @@ function Ut(e, t, n) {
|
|
|
501
502
|
let c = "col-12";
|
|
502
503
|
return l > 250 * 6 ? c = "col-2" : l > 250 * 4 ? c = "col-3" : l > 250 * 3 ? c = "col-4" : l > 250 * 2 && (c = "col-6"), c;
|
|
503
504
|
}
|
|
504
|
-
return
|
|
505
|
+
return z([n], ([l]) => {
|
|
505
506
|
r.value = l, b();
|
|
506
507
|
}), {
|
|
507
508
|
conditionClass: d,
|
|
508
509
|
resizeObserver: o
|
|
509
510
|
};
|
|
510
511
|
}
|
|
511
|
-
const
|
|
512
|
+
const ie = /* @__PURE__ */ X({
|
|
512
513
|
name: "FConditionFields",
|
|
513
|
-
props:
|
|
514
|
+
props: ue,
|
|
514
515
|
emits: ["valueChange", "blur", "focus", "click", "input"],
|
|
515
516
|
setup(e, t) {
|
|
516
|
-
const n = I(), o = I(e.key), r = I(e.isControlInline), p = I(e.conditions), d =
|
|
517
|
+
const n = I(), o = I(e.key), r = I(e.isControlInline), p = I(e.conditions), d = pe(e), {
|
|
517
518
|
initialConditionValue: b,
|
|
518
|
-
fieldMap:
|
|
519
|
+
fieldMap: w,
|
|
519
520
|
loadFieldConfigs: s
|
|
520
|
-
} = d, l =
|
|
521
|
+
} = d, l = Zt(e, t, n), {
|
|
521
522
|
conditionClass: u,
|
|
522
523
|
resizeObserver: c
|
|
523
524
|
} = l;
|
|
524
|
-
s(!0), b(p.value),
|
|
525
|
-
var
|
|
526
|
-
(
|
|
527
|
-
}),
|
|
525
|
+
s(!0), b(p.value), Te(() => {
|
|
526
|
+
var F;
|
|
527
|
+
(F = c.value) == null || F.unobserve(n.value);
|
|
528
|
+
}), z(() => e.conditions, () => {
|
|
528
529
|
p.value = e.conditions;
|
|
529
530
|
});
|
|
530
|
-
const V =
|
|
531
|
+
const V = O(() => ({
|
|
531
532
|
// row: true,
|
|
532
533
|
"f-utils-flex-row-wrap": !0,
|
|
533
534
|
"farris-form": !0,
|
|
534
535
|
"farris-form-controls-inline": r.value
|
|
535
|
-
})),
|
|
536
|
-
function
|
|
537
|
-
t.emit("valueChange",
|
|
536
|
+
})), M = O(() => u.value);
|
|
537
|
+
function j(F, x) {
|
|
538
|
+
t.emit("valueChange", F, x);
|
|
538
539
|
}
|
|
539
|
-
function
|
|
540
|
-
return p.value.map((
|
|
540
|
+
function D() {
|
|
541
|
+
return p.value.map((F) => {
|
|
541
542
|
var x;
|
|
542
|
-
return
|
|
543
|
-
customClass:
|
|
544
|
-
label:
|
|
545
|
-
editor: (x =
|
|
546
|
-
modelValue:
|
|
547
|
-
"onUpdate:modelValue": (
|
|
548
|
-
onChange: (
|
|
549
|
-
|
|
543
|
+
return k(Se, {
|
|
544
|
+
customClass: M.value,
|
|
545
|
+
label: F.fieldName,
|
|
546
|
+
editor: (x = w.get(F.fieldCode)) == null ? void 0 : x.editor,
|
|
547
|
+
modelValue: F.value.value,
|
|
548
|
+
"onUpdate:modelValue": (P) => F.value.value = P,
|
|
549
|
+
onChange: (P) => {
|
|
550
|
+
j(P, F);
|
|
550
551
|
}
|
|
551
552
|
}, null);
|
|
552
553
|
});
|
|
553
554
|
}
|
|
554
|
-
return () =>
|
|
555
|
+
return () => k("div", {
|
|
555
556
|
class: V.value,
|
|
556
557
|
key: o.value,
|
|
557
558
|
ref: n
|
|
558
|
-
}, [
|
|
559
|
+
}, [D()]);
|
|
559
560
|
}
|
|
560
|
-
}),
|
|
561
|
-
function
|
|
562
|
-
const { properties: t, title: n } = e, o = Object.keys(t).reduce((r, p) => (r[p] = t[p].type === "object" && t[p].properties ?
|
|
561
|
+
}), Jt = {}, Xt = {};
|
|
562
|
+
function me(e) {
|
|
563
|
+
const { properties: t, title: n } = e, o = Object.keys(t).reduce((r, p) => (r[p] = t[p].type === "object" && t[p].properties ? me(t[p]) : J(t[p].default), r), {});
|
|
563
564
|
return o.id = `${n}-${Date.now()}`, o;
|
|
564
565
|
}
|
|
565
|
-
function
|
|
566
|
-
const n =
|
|
567
|
-
return Object.keys(e).reduce((o, r) => (o[r] = e[r], o), n), n;
|
|
566
|
+
function Yt(e, t) {
|
|
567
|
+
const n = me(t);
|
|
568
|
+
return Object.keys(e).reduce((o, r) => (o[r] && typeof o[r] == "object" ? Object.assign(o[r], e[r]) : o[r] = e[r], o), n), n;
|
|
568
569
|
}
|
|
569
570
|
function _t(e, t) {
|
|
570
571
|
return Object.keys(e).filter((o) => e[o] != null).reduce((o, r) => {
|
|
@@ -581,22 +582,22 @@ function _t(e, t) {
|
|
|
581
582
|
return o;
|
|
582
583
|
}, {});
|
|
583
584
|
}
|
|
584
|
-
function
|
|
585
|
-
const o =
|
|
585
|
+
function Kt(e, t, n = /* @__PURE__ */ new Map()) {
|
|
586
|
+
const o = Yt(e, t);
|
|
586
587
|
return _t(o, n);
|
|
587
588
|
}
|
|
588
|
-
function
|
|
589
|
+
function en(e = {}) {
|
|
589
590
|
function t(s, l, u, c) {
|
|
590
591
|
if (typeof u == "number")
|
|
591
592
|
return c[s].length === u;
|
|
592
593
|
if (typeof u == "object") {
|
|
593
|
-
const V = Object.keys(u)[0],
|
|
594
|
+
const V = Object.keys(u)[0], M = u[V];
|
|
594
595
|
if (V === "not")
|
|
595
|
-
return Number(c[s].length) !== Number(
|
|
596
|
+
return Number(c[s].length) !== Number(M);
|
|
596
597
|
if (V === "moreThan")
|
|
597
|
-
return Number(c[s].length) >= Number(
|
|
598
|
+
return Number(c[s].length) >= Number(M);
|
|
598
599
|
if (V === "lessThan")
|
|
599
|
-
return Number(c[s].length) <= Number(
|
|
600
|
+
return Number(c[s].length) <= Number(M);
|
|
600
601
|
}
|
|
601
602
|
return !1;
|
|
602
603
|
}
|
|
@@ -613,8 +614,8 @@ function Xt(e = {}) {
|
|
|
613
614
|
return typeof l == "number" ? [{ target: u, operator: "length", param: null, value: Number(l) }] : typeof l == "boolean" ? [{ target: u, operator: "getProperty", param: s, value: !!l }] : typeof l == "object" ? Object.keys(l).map((c) => {
|
|
614
615
|
if (c === "length")
|
|
615
616
|
return { target: u, operator: "length", param: null, value: l[c] };
|
|
616
|
-
const V = c,
|
|
617
|
-
return { target: u, operator: "getProperty", param: V, value:
|
|
617
|
+
const V = c, M = l[c];
|
|
618
|
+
return { target: u, operator: "getProperty", param: V, value: M };
|
|
618
619
|
}) : [];
|
|
619
620
|
}
|
|
620
621
|
function p(s) {
|
|
@@ -631,44 +632,82 @@ function Xt(e = {}) {
|
|
|
631
632
|
return !1;
|
|
632
633
|
}
|
|
633
634
|
function b(s, l) {
|
|
634
|
-
return p(s).reduce((V,
|
|
635
|
+
return p(s).reduce((V, M) => V && d(M, l), !0);
|
|
635
636
|
}
|
|
636
|
-
function
|
|
637
|
-
const u = Object.keys(s), c = u.includes("allOf"), V = u.includes("anyOf"),
|
|
638
|
-
return c ? !
|
|
637
|
+
function w(s, l) {
|
|
638
|
+
const u = Object.keys(s), c = u.includes("allOf"), V = u.includes("anyOf"), M = c || V, F = (M ? s[M ? c ? "allOf" : "anyOf" : "allOf"] : [s]).map((P) => b(P, l));
|
|
639
|
+
return c ? !F.includes(!1) : F.includes(!0);
|
|
639
640
|
}
|
|
640
|
-
return { parseValueSchema:
|
|
641
|
+
return { parseValueSchema: w };
|
|
641
642
|
}
|
|
642
|
-
const
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
643
|
+
const E = {
|
|
644
|
+
button: { type: "button", name: "按钮", icon: "Button" },
|
|
645
|
+
"response-toolbar": { type: "response-toolbar", name: "工具栏", icon: "ButtonGroup" },
|
|
646
|
+
"response-toolbar-item": { type: "response-toolbar-item", name: "按钮", icon: "Button" },
|
|
647
|
+
"content-container": { type: "content-container", name: "容器", icon: "ContentContainer" },
|
|
648
|
+
"input-group": { type: "input-group", name: "文本", icon: "TextBox" },
|
|
649
|
+
textarea: { type: "textarea", name: "多行文本", icon: "MultiTextBox" },
|
|
650
|
+
lookup: { type: "lookup", name: "帮助", icon: "LookupEdit" },
|
|
651
|
+
"number-spinner": { type: "number-spinner", name: "数值", icon: "NumericBox" },
|
|
652
|
+
"date-picker": { type: "date-picker", name: "日期", icon: "DateBox" },
|
|
653
|
+
switch: { type: "switch", name: "开关", icon: "SwitchField" },
|
|
654
|
+
"radio-group": { type: "radio-group", name: "单选组", icon: "RadioGroup" },
|
|
655
|
+
"check-box": { type: "check-box", name: "复选框", icon: "CheckBox" },
|
|
656
|
+
"check-group": { type: "check-group", name: "复选框组", icon: "CheckGroup" },
|
|
657
|
+
"combo-list": { type: "combo-list", name: "下拉列表", icon: "EnumField" },
|
|
658
|
+
"response-form": { type: "response-form", name: "卡片面板", icon: "Form" },
|
|
659
|
+
"response-layout": { type: "response-layout", name: "布局容器", icon: "ResponseLayout3" },
|
|
660
|
+
"response-layout-item": { type: "response-layout-item", name: "布局", icon: "ResponseLayout1" },
|
|
661
|
+
"tree-grid": { type: "tree-grid", name: "树表格", icon: "TreeGrid" },
|
|
662
|
+
"tree-grid-column": { type: "tree-grid-column", name: "树表格列" },
|
|
663
|
+
"data-grid": { type: "data-grid", name: "表格", icon: "DataGrid" },
|
|
664
|
+
"data-grid-column": { type: "data-grid-column", name: "表格列" },
|
|
665
|
+
module: { type: "Module", name: "模块", icon: "Module" },
|
|
666
|
+
component: { type: "component", name: "组件", icon: "Component" },
|
|
667
|
+
tabs: { type: "tabs", name: "标签页", icon: "Tab" },
|
|
668
|
+
"tab-page": { type: "tab-page", name: "标签页项", dependentParentControl: "Tab" },
|
|
669
|
+
"tab-toolbar-item": { type: "tab-toolbar-item", name: "标签页工具栏按钮", icon: "Button" },
|
|
670
|
+
"time-picker": { type: "time-picker", name: "时间选择", icon: "TimePicker" },
|
|
671
|
+
section: { type: "section", name: "分组面板", icon: "Section" },
|
|
672
|
+
"section-toolbar": { type: "section-toolbar", name: "分组面板工具栏" },
|
|
673
|
+
"section-toolbar-item": { type: "section-toolbar-item", name: "分组面板按钮" },
|
|
674
|
+
splitter: { type: "splitter", name: "分栏面板", icon: "Splitter" },
|
|
675
|
+
"splitter-pane": { type: "splitter-pane", name: "分栏面板项", dependentParentControl: "Splitter" },
|
|
676
|
+
"component-ref": { type: "component-ref", name: "组件引用节点" },
|
|
677
|
+
uploader: { type: "uploader", name: "附件上传", icon: "FileUpload" },
|
|
678
|
+
"page-header": { type: "page-header", name: "页头", icon: "Header" },
|
|
679
|
+
"page-footer": { type: "page-footer", name: "页脚", icon: "ModalFooter" },
|
|
680
|
+
"tab-toolbar": { type: "tab-toolbar", name: "标签页工具栏", icon: "TabToolbar" }
|
|
681
|
+
}, tn = {}, nn = {};
|
|
682
|
+
en();
|
|
683
|
+
function K(e, t, n = /* @__PURE__ */ new Map(), o = (d, b, w) => b, r = {}, p = (d) => d) {
|
|
684
|
+
return Jt[t.title] = t, Xt[t.title] = o, tn[t.title] = r, nn[t.title] = p, (d = {}) => {
|
|
685
|
+
const b = Kt(d, t, n), w = Object.keys(e).reduce((s, l) => (s[l] = e[l].default, s), {});
|
|
686
|
+
return Object.assign(w, b);
|
|
648
687
|
};
|
|
649
688
|
}
|
|
650
|
-
function
|
|
689
|
+
function fe(e, t) {
|
|
651
690
|
return { customClass: t.class, customStyle: t.style };
|
|
652
691
|
}
|
|
653
|
-
const
|
|
654
|
-
["appearance",
|
|
692
|
+
const ne = /* @__PURE__ */ new Map([
|
|
693
|
+
["appearance", fe]
|
|
655
694
|
]);
|
|
656
|
-
function
|
|
695
|
+
function on(e, t, n, o) {
|
|
657
696
|
const r = e.getSchemaByType("section");
|
|
658
697
|
return r.id = `${o}-section`, r.appearance = { class: "f-section-form f-section-in-main" }, r.mainTitle = "标题", r.contents = [t], r;
|
|
659
698
|
}
|
|
660
|
-
function
|
|
699
|
+
function rn(e, t, n, o) {
|
|
661
700
|
const r = e.getSchemaByType("component");
|
|
662
701
|
return r.id = `${o}-component`, r.componentType = "form-col-1", r.appearance = {
|
|
663
702
|
class: "f-struct-form f-struct-wrapper"
|
|
664
703
|
}, r.contents = [t], r;
|
|
665
704
|
}
|
|
666
|
-
function
|
|
705
|
+
function an(e, t, n) {
|
|
667
706
|
t.appearance = { class: "f-form-layout farris-form farris-form-controls-inline" };
|
|
668
|
-
const o =
|
|
669
|
-
return
|
|
707
|
+
const o = on(e, t, n, t.id);
|
|
708
|
+
return rn(e, o, n, t.id);
|
|
670
709
|
}
|
|
671
|
-
const
|
|
710
|
+
const ln = "https://json-schema.org/draft/2020-12/schema", sn = "https://farris-design.gitee.io/response-form.schema.json", un = "response-form", cn = "A Farris Data Collection Component", dn = "object", pn = {
|
|
672
711
|
id: {
|
|
673
712
|
description: "The unique identifier for a form group",
|
|
674
713
|
type: "string"
|
|
@@ -696,18 +735,18 @@ const on = "https://json-schema.org/draft/2020-12/schema", rn = "https://farris-
|
|
|
696
735
|
type: "array",
|
|
697
736
|
default: []
|
|
698
737
|
}
|
|
699
|
-
},
|
|
738
|
+
}, mn = [
|
|
700
739
|
"id",
|
|
701
740
|
"type"
|
|
702
|
-
],
|
|
703
|
-
$schema:
|
|
704
|
-
$id:
|
|
705
|
-
title:
|
|
706
|
-
description:
|
|
707
|
-
type:
|
|
708
|
-
properties:
|
|
709
|
-
required:
|
|
710
|
-
},
|
|
741
|
+
], fn = {
|
|
742
|
+
$schema: ln,
|
|
743
|
+
$id: sn,
|
|
744
|
+
title: un,
|
|
745
|
+
description: cn,
|
|
746
|
+
type: dn,
|
|
747
|
+
properties: pn,
|
|
748
|
+
required: mn
|
|
749
|
+
}, gn = "response-form", hn = "A Farris Component", vn = "object", yn = {
|
|
711
750
|
basic: {
|
|
712
751
|
description: "Basic Infomation",
|
|
713
752
|
title: "基本信息",
|
|
@@ -729,16 +768,16 @@ const on = "https://json-schema.org/draft/2020-12/schema", rn = "https://farris-
|
|
|
729
768
|
}
|
|
730
769
|
}
|
|
731
770
|
}
|
|
732
|
-
},
|
|
733
|
-
title:
|
|
734
|
-
description:
|
|
735
|
-
type:
|
|
736
|
-
categories:
|
|
737
|
-
},
|
|
771
|
+
}, bn = {
|
|
772
|
+
title: gn,
|
|
773
|
+
description: hn,
|
|
774
|
+
type: vn,
|
|
775
|
+
categories: yn
|
|
776
|
+
}, Cn = {
|
|
738
777
|
customClass: { type: String, default: "" }
|
|
739
778
|
};
|
|
740
|
-
|
|
741
|
-
const
|
|
779
|
+
K(Cn, fn, ne, an, bn);
|
|
780
|
+
const kn = "https://json-schema.org/draft/2020-12/schema", Tn = "https://farris-design.gitee.io/form-group.schema.json", Fn = "form-group", xn = "A Farris Input Component", wn = "object", Bn = {
|
|
742
781
|
id: {
|
|
743
782
|
description: "The unique identifier for a form group",
|
|
744
783
|
type: "string"
|
|
@@ -779,18 +818,18 @@ const yn = "https://json-schema.org/draft/2020-12/schema", bn = "https://farris-
|
|
|
779
818
|
description: "",
|
|
780
819
|
type: "number"
|
|
781
820
|
}
|
|
782
|
-
},
|
|
821
|
+
}, In = [
|
|
783
822
|
"id",
|
|
784
823
|
"type"
|
|
785
|
-
],
|
|
786
|
-
$schema:
|
|
787
|
-
$id:
|
|
788
|
-
title:
|
|
789
|
-
description:
|
|
824
|
+
], ge = {
|
|
825
|
+
$schema: kn,
|
|
826
|
+
$id: Tn,
|
|
827
|
+
title: Fn,
|
|
828
|
+
description: xn,
|
|
790
829
|
type: wn,
|
|
791
|
-
properties:
|
|
792
|
-
required:
|
|
793
|
-
},
|
|
830
|
+
properties: Bn,
|
|
831
|
+
required: In
|
|
832
|
+
}, he = {
|
|
794
833
|
id: { type: String, default: "" },
|
|
795
834
|
customClass: { type: String, default: "" },
|
|
796
835
|
/** 筛选组件配置器,具体配置项可查看各组件文档 */
|
|
@@ -804,43 +843,43 @@ const yn = "https://json-schema.org/draft/2020-12/schema", bn = "https://farris-
|
|
|
804
843
|
showLabel: { type: Boolean, default: !0 },
|
|
805
844
|
type: { type: String, default: "input-group" }
|
|
806
845
|
};
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
846
|
+
K(
|
|
847
|
+
he,
|
|
848
|
+
ge,
|
|
849
|
+
ne,
|
|
811
850
|
void 0
|
|
812
851
|
);
|
|
813
|
-
const
|
|
852
|
+
const Sn = {
|
|
814
853
|
id: { type: String },
|
|
815
854
|
required: { type: Boolean, default: !1 },
|
|
816
855
|
text: { type: String, default: "" },
|
|
817
856
|
title: { type: String }
|
|
818
|
-
},
|
|
857
|
+
}, Vn = /* @__PURE__ */ X({
|
|
819
858
|
name: "FDynamicFormLabel",
|
|
820
|
-
props:
|
|
859
|
+
props: Sn,
|
|
821
860
|
emits: [],
|
|
822
861
|
setup(e, t) {
|
|
823
862
|
const n = I(e.title || e.text), o = I(e.required), r = I(e.text);
|
|
824
|
-
return
|
|
863
|
+
return z(() => e.text, () => {
|
|
825
864
|
r.value = e.text;
|
|
826
|
-
}),
|
|
865
|
+
}), z(() => e.required, (p, d) => {
|
|
827
866
|
p !== d && (o.value = p);
|
|
828
|
-
}), () =>
|
|
867
|
+
}), () => k("label", {
|
|
829
868
|
class: "col-form-label",
|
|
830
869
|
title: n.value
|
|
831
|
-
}, [o.value &&
|
|
870
|
+
}, [o.value && k("span", {
|
|
832
871
|
class: "farris-label-info text-danger"
|
|
833
|
-
}, [
|
|
872
|
+
}, [Y("*")]), k("span", {
|
|
834
873
|
class: "farris-label-text"
|
|
835
874
|
}, [r.value])]);
|
|
836
875
|
}
|
|
837
|
-
}),
|
|
838
|
-
["appearance",
|
|
876
|
+
}), En = /* @__PURE__ */ new Map([
|
|
877
|
+
["appearance", fe]
|
|
839
878
|
]);
|
|
840
|
-
function
|
|
879
|
+
function Mn(e, t, n) {
|
|
841
880
|
return t;
|
|
842
881
|
}
|
|
843
|
-
const
|
|
882
|
+
const Pn = "https://json-schema.org/draft/2020-12/schema", On = "https://farris-design.gitee.io/input-group.schema.json", jn = "input-group", Ln = "A Farris Input Component", Nn = "object", An = {
|
|
844
883
|
id: {
|
|
845
884
|
description: "The unique identifier for a Input Group",
|
|
846
885
|
type: "string"
|
|
@@ -1042,18 +1081,18 @@ const Vn = "https://json-schema.org/draft/2020-12/schema", En = "https://farris-
|
|
|
1042
1081
|
type: "string",
|
|
1043
1082
|
default: ""
|
|
1044
1083
|
}
|
|
1045
|
-
},
|
|
1084
|
+
}, Gn = [
|
|
1046
1085
|
"id",
|
|
1047
1086
|
"type"
|
|
1048
|
-
],
|
|
1049
|
-
$schema:
|
|
1050
|
-
$id:
|
|
1051
|
-
title:
|
|
1052
|
-
description:
|
|
1053
|
-
type:
|
|
1054
|
-
properties:
|
|
1055
|
-
required:
|
|
1056
|
-
},
|
|
1087
|
+
], $n = {
|
|
1088
|
+
$schema: Pn,
|
|
1089
|
+
$id: On,
|
|
1090
|
+
title: jn,
|
|
1091
|
+
description: Ln,
|
|
1092
|
+
type: Nn,
|
|
1093
|
+
properties: An,
|
|
1094
|
+
required: Gn
|
|
1095
|
+
}, ve = {
|
|
1057
1096
|
/** 是否自动完成 */
|
|
1058
1097
|
autocomplete: { Type: String, default: "off" },
|
|
1059
1098
|
/** 自定义CLASS */
|
|
@@ -1120,67 +1159,67 @@ const Vn = "https://json-schema.org/draft/2020-12/schema", En = "https://farris-
|
|
|
1120
1159
|
*/
|
|
1121
1160
|
updateOn: { type: String, default: "blur" }
|
|
1122
1161
|
};
|
|
1123
|
-
|
|
1124
|
-
function
|
|
1125
|
-
const r = I(e.disabled), p = I(!1), d = I("text"), b = I(e.showBorder),
|
|
1162
|
+
K(ve, $n, En, Mn);
|
|
1163
|
+
function Rn(e, t, n, o) {
|
|
1164
|
+
const r = I(e.disabled), p = I(!1), d = I("text"), b = I(e.showBorder), w = I(e.textAlign), s = I(e.updateOn), l = O(() => e.editable || !e.readonly), u = O(() => e.editable && !e.disabled && !e.readonly), c = O(() => !e.disabled && p.value), V = O(() => n.value === "" || n.value === null || n.value === void 0), M = O(() => (e.disabled || e.readonly) && !e.forcePlaceholder ? "" : e.placeholder), j = O(() => e.readonly || !e.editable), D = O(() => e.enableTitle ? n.value : ""), F = O(() => ({
|
|
1126
1165
|
"form-control": !0,
|
|
1127
1166
|
"f-utils-fill": !0,
|
|
1128
|
-
"text-left":
|
|
1129
|
-
"text-center":
|
|
1130
|
-
"text-right":
|
|
1131
|
-
})), x =
|
|
1132
|
-
const
|
|
1167
|
+
"text-left": w.value === "left",
|
|
1168
|
+
"text-center": w.value === "center",
|
|
1169
|
+
"text-right": w.value === "right"
|
|
1170
|
+
})), x = O(() => {
|
|
1171
|
+
const i = {
|
|
1133
1172
|
"f-cmp-inputgroup": !0,
|
|
1134
1173
|
"input-group": !0,
|
|
1135
1174
|
"f-state-disable": r.value,
|
|
1136
1175
|
"f-state-editable": u.value,
|
|
1137
|
-
"f-state-readonly":
|
|
1176
|
+
"f-state-readonly": j.value,
|
|
1138
1177
|
"f-state-focus": c.value
|
|
1139
1178
|
};
|
|
1140
|
-
return (e.customClass || "").split(" ").reduce((S,
|
|
1141
|
-
}),
|
|
1142
|
-
function
|
|
1143
|
-
n.value =
|
|
1179
|
+
return (e.customClass || "").split(" ").reduce((S, W) => (S[W] = !0, S), i), i;
|
|
1180
|
+
}), P = O(() => b.value ? "" : "border-width : 0 ");
|
|
1181
|
+
function L(i, C = !0) {
|
|
1182
|
+
n.value = i, o.value !== i && (o.value = i), C && t.emit("change", i), t.emit("update:modelValue", i), t.emit("update:value", i);
|
|
1144
1183
|
}
|
|
1145
|
-
|
|
1184
|
+
z(
|
|
1146
1185
|
() => e.modelValue,
|
|
1147
|
-
(
|
|
1148
|
-
|
|
1186
|
+
(i, C) => {
|
|
1187
|
+
i !== C && (n.value = i, o.value = i);
|
|
1149
1188
|
}
|
|
1150
|
-
),
|
|
1151
|
-
|
|
1189
|
+
), z(() => e.disabled, (i, C) => {
|
|
1190
|
+
i !== C && (r.value = i);
|
|
1152
1191
|
});
|
|
1153
|
-
function $(
|
|
1154
|
-
return p.value = !1, t.emit("blur",
|
|
1192
|
+
function $(i) {
|
|
1193
|
+
return p.value = !1, t.emit("blur", i), i.stopPropagation(), !1;
|
|
1155
1194
|
}
|
|
1156
|
-
function
|
|
1157
|
-
t.emit("click",
|
|
1195
|
+
function R(i) {
|
|
1196
|
+
t.emit("click", i);
|
|
1158
1197
|
}
|
|
1159
|
-
function A(
|
|
1160
|
-
e.disabled || (b.value && (p.value = !0), l.value && t.emit("focus",
|
|
1198
|
+
function A(i) {
|
|
1199
|
+
e.disabled || (b.value && (p.value = !0), l.value && t.emit("focus", i));
|
|
1161
1200
|
}
|
|
1162
|
-
function
|
|
1163
|
-
t.emit("input",
|
|
1164
|
-
const C =
|
|
1201
|
+
function U(i) {
|
|
1202
|
+
t.emit("input", i.target.value);
|
|
1203
|
+
const C = i.target.value;
|
|
1165
1204
|
o.value = C, s.value === "input" && (t.emit("update:modelValue", C), t.emit("update:value", C));
|
|
1166
1205
|
}
|
|
1167
|
-
function i
|
|
1168
|
-
t.emit("keydown",
|
|
1206
|
+
function a(i) {
|
|
1207
|
+
t.emit("keydown", i);
|
|
1169
1208
|
}
|
|
1170
|
-
function
|
|
1171
|
-
t.emit("keyup",
|
|
1209
|
+
function f(i) {
|
|
1210
|
+
t.emit("keyup", i);
|
|
1172
1211
|
}
|
|
1173
|
-
function
|
|
1174
|
-
|
|
1212
|
+
function m(i) {
|
|
1213
|
+
i.target.tagName !== "INPUT" && i.preventDefault(), i.stopPropagation();
|
|
1175
1214
|
}
|
|
1176
|
-
function B(
|
|
1215
|
+
function B(i) {
|
|
1177
1216
|
if (s.value === "blur") {
|
|
1178
|
-
const C =
|
|
1179
|
-
|
|
1217
|
+
const C = i.target.value;
|
|
1218
|
+
i.stopPropagation(), L(C);
|
|
1180
1219
|
}
|
|
1181
1220
|
}
|
|
1182
1221
|
return {
|
|
1183
|
-
changeTextBoxValue:
|
|
1222
|
+
changeTextBoxValue: L,
|
|
1184
1223
|
disabled: r,
|
|
1185
1224
|
displayText: o,
|
|
1186
1225
|
editable: u,
|
|
@@ -1189,49 +1228,49 @@ function Nn(e, t, n, o) {
|
|
|
1189
1228
|
inputType: d,
|
|
1190
1229
|
isEmpty: V,
|
|
1191
1230
|
modelValue: n,
|
|
1192
|
-
readonly:
|
|
1231
|
+
readonly: j,
|
|
1193
1232
|
onBlur: $,
|
|
1194
|
-
onClick:
|
|
1233
|
+
onClick: R,
|
|
1195
1234
|
onFocus: A,
|
|
1196
|
-
onInput:
|
|
1197
|
-
onKeydown:
|
|
1198
|
-
onKeyup:
|
|
1199
|
-
onMousedown:
|
|
1235
|
+
onInput: U,
|
|
1236
|
+
onKeydown: a,
|
|
1237
|
+
onKeyup: f,
|
|
1238
|
+
onMousedown: m,
|
|
1200
1239
|
onTextBoxValueChange: B,
|
|
1201
|
-
placeholder:
|
|
1202
|
-
textBoxClass:
|
|
1203
|
-
textBoxTitle:
|
|
1204
|
-
inputGroupStyle:
|
|
1240
|
+
placeholder: M,
|
|
1241
|
+
textBoxClass: F,
|
|
1242
|
+
textBoxTitle: D,
|
|
1243
|
+
inputGroupStyle: P
|
|
1205
1244
|
};
|
|
1206
1245
|
}
|
|
1207
|
-
function
|
|
1208
|
-
const o = I(!1), r =
|
|
1209
|
-
function s(
|
|
1210
|
-
o.value =
|
|
1246
|
+
function qn(e, t, n) {
|
|
1247
|
+
const o = I(!1), r = O(() => e.enableClear && !e.readonly && !e.disabled), { changeTextBoxValue: p, displayText: d, hasFocused: b, isEmpty: w } = n;
|
|
1248
|
+
function s(j) {
|
|
1249
|
+
o.value = j;
|
|
1211
1250
|
}
|
|
1212
|
-
|
|
1251
|
+
z(d, () => {
|
|
1213
1252
|
b != null && b.value ? s(!!(d != null && d.value)) : s(!1);
|
|
1214
1253
|
});
|
|
1215
|
-
const l =
|
|
1254
|
+
const l = O(() => ({
|
|
1216
1255
|
"input-group-text": !0,
|
|
1217
1256
|
"input-group-clear": !0
|
|
1218
|
-
})), u =
|
|
1257
|
+
})), u = O(() => ({
|
|
1219
1258
|
width: "24px",
|
|
1220
1259
|
display: o.value ? "flex" : "none"
|
|
1221
1260
|
}));
|
|
1222
|
-
function c(
|
|
1223
|
-
|
|
1261
|
+
function c(j) {
|
|
1262
|
+
j.stopPropagation(), r.value && (p("", !0), s(!o.value), t.emit("clear"));
|
|
1224
1263
|
}
|
|
1225
|
-
function V(
|
|
1226
|
-
r.value && !
|
|
1264
|
+
function V(j) {
|
|
1265
|
+
r.value && !w.value && s(!0);
|
|
1227
1266
|
}
|
|
1228
|
-
function
|
|
1267
|
+
function M(j) {
|
|
1229
1268
|
r.value && s(!1);
|
|
1230
1269
|
}
|
|
1231
|
-
return { clearButtonClass: l, clearButtonStyle: u, hasShownClearButton: o, onClearValue: c, onMouseEnter: V, onMouseLeave:
|
|
1270
|
+
return { clearButtonClass: l, clearButtonStyle: u, hasShownClearButton: o, onClearValue: c, onMouseEnter: V, onMouseLeave: M, shouldShowClearButton: r };
|
|
1232
1271
|
}
|
|
1233
|
-
const
|
|
1234
|
-
function
|
|
1272
|
+
const Dn = ["moz", "ms", "webkit"];
|
|
1273
|
+
function Wn() {
|
|
1235
1274
|
let e = 0;
|
|
1236
1275
|
return (t) => {
|
|
1237
1276
|
const n = (/* @__PURE__ */ new Date()).getTime(), o = Math.max(0, 16 - (n - e)), r = setTimeout(() => {
|
|
@@ -1240,199 +1279,199 @@ function Rn() {
|
|
|
1240
1279
|
return e = n + o, r;
|
|
1241
1280
|
};
|
|
1242
1281
|
}
|
|
1243
|
-
function
|
|
1282
|
+
function zn() {
|
|
1244
1283
|
if (typeof window > "u")
|
|
1245
1284
|
return () => 0;
|
|
1246
1285
|
if (window.requestAnimationFrame)
|
|
1247
1286
|
return window.requestAnimationFrame.bind(window);
|
|
1248
|
-
const e =
|
|
1249
|
-
return e ? window[`${e}RequestAnimationFrame`] :
|
|
1287
|
+
const e = Dn.filter((t) => `${t}RequestAnimationFrame` in window)[0];
|
|
1288
|
+
return e ? window[`${e}RequestAnimationFrame`] : Wn();
|
|
1250
1289
|
}
|
|
1251
|
-
|
|
1252
|
-
function
|
|
1253
|
-
const n = I(e.groupText), o =
|
|
1254
|
-
return { appendedButtonClass:
|
|
1290
|
+
zn();
|
|
1291
|
+
function Un(e, t) {
|
|
1292
|
+
const n = I(e.groupText), o = O(() => e.showButtonWhenDisabled && (e.readonly || e.disabled)), r = O(() => e.enableClear || !!e.groupText);
|
|
1293
|
+
return { appendedButtonClass: O(() => ({
|
|
1255
1294
|
"input-group-append": !0,
|
|
1256
1295
|
"append-force-show": o.value
|
|
1257
1296
|
})), appendedContent: n, shouldShowAppendedButton: r };
|
|
1258
1297
|
}
|
|
1259
|
-
function
|
|
1260
|
-
const { appendedContent: r } = o, p = I(e.enableViewPassword), d =
|
|
1261
|
-
|
|
1262
|
-
d.value && (n.value = c || V ? "password" : n.value, r.value = c || V ?
|
|
1298
|
+
function Hn(e, t, n, o) {
|
|
1299
|
+
const { appendedContent: r } = o, p = I(e.enableViewPassword), d = O(() => e.type === "password"), b = '<span class="f-icon f-icon-eye" style="color: rgb(56, 143, 255);"></span>', w = '<span class="f-icon f-icon-eye"></span>', s = I(!1);
|
|
1300
|
+
z(() => [e.readonly, e.disabled], ([c, V]) => {
|
|
1301
|
+
d.value && (n.value = c || V ? "password" : n.value, r.value = c || V ? w : r.value);
|
|
1263
1302
|
});
|
|
1264
1303
|
function l() {
|
|
1265
|
-
return s.value = !s.value, n.value = s.value ? "text" : "password", r.value = s.value ? b :
|
|
1304
|
+
return s.value = !s.value, n.value = s.value ? "text" : "password", r.value = s.value ? b : w, !1;
|
|
1266
1305
|
}
|
|
1267
1306
|
function u() {
|
|
1268
|
-
n.value = d.value ? "password" : "text", r.value = d.value ? p.value ?
|
|
1307
|
+
n.value = d.value ? "password" : "text", r.value = d.value ? p.value ? w : "" : r.value;
|
|
1269
1308
|
}
|
|
1270
1309
|
return u(), { isPassword: d, onClickAppendedButton: l };
|
|
1271
1310
|
}
|
|
1272
|
-
function
|
|
1311
|
+
function Qn(e, t, n) {
|
|
1273
1312
|
const o = I(), {
|
|
1274
1313
|
onBlurTextBox: r,
|
|
1275
1314
|
onFocusTextBox: p,
|
|
1276
1315
|
onInput: d,
|
|
1277
1316
|
onKeyDown: b,
|
|
1278
|
-
textBoxValue:
|
|
1279
|
-
} = n, s =
|
|
1317
|
+
textBoxValue: w
|
|
1318
|
+
} = n, s = O(() => e.disabled || e.readonly || !e.editable ? "" : e.placeholder), l = O(() => ({
|
|
1280
1319
|
"form-control": !0,
|
|
1281
1320
|
"f-utils-fill": !0
|
|
1282
|
-
})), u =
|
|
1321
|
+
})), u = O(() => ({
|
|
1283
1322
|
"text-align": e.textAlign
|
|
1284
1323
|
}));
|
|
1285
|
-
function c(
|
|
1286
|
-
|
|
1324
|
+
function c(j) {
|
|
1325
|
+
j.stopPropagation();
|
|
1287
1326
|
}
|
|
1288
1327
|
function V() {
|
|
1289
1328
|
e.selectOnCreated, e.focusOnCreated;
|
|
1290
1329
|
}
|
|
1291
|
-
async function
|
|
1292
|
-
p(
|
|
1330
|
+
async function M(j) {
|
|
1331
|
+
p(j), await oe, V();
|
|
1293
1332
|
}
|
|
1294
|
-
return
|
|
1295
|
-
await
|
|
1296
|
-
}), () =>
|
|
1333
|
+
return _(async () => {
|
|
1334
|
+
await oe, V();
|
|
1335
|
+
}), () => k("input", {
|
|
1297
1336
|
ref: o,
|
|
1298
1337
|
class: l.value,
|
|
1299
1338
|
style: u.value,
|
|
1300
1339
|
type: "text",
|
|
1301
|
-
value:
|
|
1340
|
+
value: w.value,
|
|
1302
1341
|
disabled: e.disabled,
|
|
1303
1342
|
readonly: e.readonly || !e.editable,
|
|
1304
1343
|
placeholder: s.value,
|
|
1305
1344
|
onBlur: r,
|
|
1306
1345
|
onChange: c,
|
|
1307
|
-
onFocus:
|
|
1346
|
+
onFocus: M,
|
|
1308
1347
|
onInput: d,
|
|
1309
1348
|
onKeydown: b
|
|
1310
1349
|
}, null);
|
|
1311
1350
|
}
|
|
1312
|
-
function
|
|
1351
|
+
function Zn(e, t, n) {
|
|
1313
1352
|
const {
|
|
1314
1353
|
canDownward: o,
|
|
1315
1354
|
canUpward: r,
|
|
1316
1355
|
onClickDownButton: p,
|
|
1317
1356
|
onClickUpButton: d
|
|
1318
|
-
} = n, b =
|
|
1357
|
+
} = n, b = O(() => ({
|
|
1319
1358
|
"input-group-append": !0,
|
|
1320
1359
|
"btn-group": !0,
|
|
1321
1360
|
"btn-group-number": !0
|
|
1322
|
-
})),
|
|
1361
|
+
})), w = O(() => ({
|
|
1323
1362
|
btn: !0,
|
|
1324
1363
|
"btn-secondary": !0,
|
|
1325
1364
|
"btn-number-flag": !0
|
|
1326
|
-
})), s =
|
|
1365
|
+
})), s = O(() => ({
|
|
1327
1366
|
cursor: r() ? "pointer" : "not-allowed",
|
|
1328
1367
|
"margin-left": 0
|
|
1329
|
-
})), l =
|
|
1368
|
+
})), l = O(() => ({
|
|
1330
1369
|
cursor: o() ? "pointer" : "not-allowed",
|
|
1331
1370
|
"margin-left": 0
|
|
1332
1371
|
}));
|
|
1333
|
-
return () =>
|
|
1372
|
+
return () => k("div", {
|
|
1334
1373
|
class: b.value
|
|
1335
|
-
}, [
|
|
1374
|
+
}, [k("button", {
|
|
1336
1375
|
title: "upButton",
|
|
1337
|
-
class:
|
|
1376
|
+
class: w.value,
|
|
1338
1377
|
style: s.value,
|
|
1339
1378
|
onClick: d,
|
|
1340
1379
|
disabled: !r()
|
|
1341
|
-
}, [
|
|
1380
|
+
}, [k("span", {
|
|
1342
1381
|
class: "f-icon f-icon-arrow-chevron-up number-arrow-chevron"
|
|
1343
|
-
}, null)]),
|
|
1382
|
+
}, null)]), k("button", {
|
|
1344
1383
|
title: "downButton",
|
|
1345
|
-
class:
|
|
1384
|
+
class: w.value,
|
|
1346
1385
|
style: l.value,
|
|
1347
1386
|
onClick: p,
|
|
1348
1387
|
disabled: !o()
|
|
1349
|
-
}, [
|
|
1388
|
+
}, [k("span", {
|
|
1350
1389
|
class: "f-icon f-icon-arrow-chevron-down number-arrow-chevron"
|
|
1351
1390
|
}, null)])]);
|
|
1352
1391
|
}
|
|
1353
|
-
function
|
|
1354
|
-
const n =
|
|
1392
|
+
function Jn(e, t) {
|
|
1393
|
+
const n = Ee(e, t), o = Me(e, t, n), r = Pe(e, t, o, n), p = Oe(e, t, o, n, r), d = Zn(e, t, r), {
|
|
1355
1394
|
displayValue: b,
|
|
1356
|
-
modelValue:
|
|
1395
|
+
modelValue: w,
|
|
1357
1396
|
getRealValue: s
|
|
1358
|
-
} = n, l =
|
|
1397
|
+
} = n, l = Qn(e, t, p), {
|
|
1359
1398
|
format: u
|
|
1360
1399
|
} = o, {
|
|
1361
1400
|
isFocus: c
|
|
1362
|
-
} = p, V =
|
|
1363
|
-
return
|
|
1364
|
-
const
|
|
1365
|
-
b.value = u(
|
|
1366
|
-
}),
|
|
1367
|
-
const
|
|
1368
|
-
|
|
1369
|
-
}),
|
|
1370
|
-
|
|
1371
|
-
}),
|
|
1372
|
-
b.value = u(
|
|
1373
|
-
}), () =>
|
|
1401
|
+
} = p, V = O(() => !e.disabled && !e.readonly);
|
|
1402
|
+
return _(() => {
|
|
1403
|
+
const M = s(e.modelValue);
|
|
1404
|
+
b.value = u(M);
|
|
1405
|
+
}), z(() => [e.value], ([M]) => {
|
|
1406
|
+
const j = s(M);
|
|
1407
|
+
w.value = j, b.value = u(j);
|
|
1408
|
+
}), z(() => [e.modelValue], ([M]) => {
|
|
1409
|
+
M !== w.value && (w.value = M, !c.value && (b.value = u(s(M))));
|
|
1410
|
+
}), z(() => [e.precision, e.useThousands, e.prefix, e.suffix, e.showZero], () => {
|
|
1411
|
+
b.value = u(w.value);
|
|
1412
|
+
}), () => k("div", {
|
|
1374
1413
|
class: "input-group f-state-hover flex-row f-cmp-number-spinner"
|
|
1375
1414
|
}, [l(), V.value && d()]);
|
|
1376
1415
|
}
|
|
1377
|
-
function
|
|
1416
|
+
function Xn(e, t, n, o) {
|
|
1378
1417
|
const r = I(), p = I(e.autocomplete), d = I(e.enableTitle), {
|
|
1379
1418
|
isPassword: b
|
|
1380
|
-
} = n,
|
|
1419
|
+
} = n, w = I(e.minLength), s = I(e.maxLength), l = I(e.tabIndex), {
|
|
1381
1420
|
disabled: u,
|
|
1382
1421
|
displayText: c,
|
|
1383
1422
|
inputType: V,
|
|
1384
|
-
onBlur:
|
|
1385
|
-
onFocus:
|
|
1386
|
-
onInput:
|
|
1387
|
-
onClick:
|
|
1423
|
+
onBlur: M,
|
|
1424
|
+
onFocus: j,
|
|
1425
|
+
onInput: D,
|
|
1426
|
+
onClick: F,
|
|
1388
1427
|
onKeydown: x,
|
|
1389
|
-
onKeyup:
|
|
1390
|
-
onMousedown:
|
|
1428
|
+
onKeyup: P,
|
|
1429
|
+
onMousedown: L,
|
|
1391
1430
|
onTextBoxValueChange: $,
|
|
1392
|
-
readonly:
|
|
1431
|
+
readonly: R,
|
|
1393
1432
|
placeholder: A,
|
|
1394
|
-
textBoxClass:
|
|
1395
|
-
textBoxTitle:
|
|
1433
|
+
textBoxClass: U,
|
|
1434
|
+
textBoxTitle: a
|
|
1396
1435
|
} = o;
|
|
1397
|
-
return
|
|
1436
|
+
return _(() => {
|
|
1398
1437
|
e.selectOnCreated, e.focusOnCreated;
|
|
1399
|
-
}), () =>
|
|
1438
|
+
}), () => k("input", {
|
|
1400
1439
|
ref: r,
|
|
1401
1440
|
name: "input-group-value",
|
|
1402
1441
|
autocomplete: p.value,
|
|
1403
|
-
class:
|
|
1442
|
+
class: U.value,
|
|
1404
1443
|
disabled: u == null ? void 0 : u.value,
|
|
1405
1444
|
maxlength: s.value,
|
|
1406
|
-
minlength:
|
|
1445
|
+
minlength: w.value,
|
|
1407
1446
|
placeholder: A.value,
|
|
1408
|
-
readonly:
|
|
1447
|
+
readonly: R == null ? void 0 : R.value,
|
|
1409
1448
|
tabindex: l.value,
|
|
1410
|
-
title: d.value && !b.value ?
|
|
1449
|
+
title: d.value && !b.value ? a.value : "",
|
|
1411
1450
|
type: V.value,
|
|
1412
1451
|
value: c == null ? void 0 : c.value,
|
|
1413
|
-
onBlur:
|
|
1414
|
-
onClick:
|
|
1452
|
+
onBlur: M,
|
|
1453
|
+
onClick: F,
|
|
1415
1454
|
onChange: $,
|
|
1416
|
-
onFocus:
|
|
1417
|
-
onInput:
|
|
1455
|
+
onFocus: j,
|
|
1456
|
+
onInput: D,
|
|
1418
1457
|
onKeydown: x,
|
|
1419
|
-
onKeyup:
|
|
1420
|
-
onMousedown:
|
|
1458
|
+
onKeyup: P,
|
|
1459
|
+
onMousedown: L
|
|
1421
1460
|
}, null);
|
|
1422
1461
|
}
|
|
1423
|
-
function
|
|
1424
|
-
const n =
|
|
1462
|
+
function Yn(e, t) {
|
|
1463
|
+
const n = O(() => e.useExtendInfo && !!e.extendInfo), o = Fe({
|
|
1425
1464
|
content: e.extendInfo
|
|
1426
1465
|
});
|
|
1427
1466
|
function r() {
|
|
1428
1467
|
t.emit("updateExtendInfo");
|
|
1429
1468
|
}
|
|
1430
|
-
return () => n.value &&
|
|
1469
|
+
return () => n.value && xe(k("span", {
|
|
1431
1470
|
class: "input-group-before-tips",
|
|
1432
1471
|
onMouseenter: r
|
|
1433
|
-
}, [
|
|
1472
|
+
}, [k("i", {
|
|
1434
1473
|
class: "f-icon f-icon-info-circle"
|
|
1435
|
-
}, null),
|
|
1474
|
+
}, null), k("b", {
|
|
1436
1475
|
class: "tips-arrow"
|
|
1437
1476
|
}, null)]), [[we("tooltip"), o]]);
|
|
1438
1477
|
}
|
|
@@ -1440,98 +1479,98 @@ function _n(e, t, n, o, r) {
|
|
|
1440
1479
|
const {
|
|
1441
1480
|
appendedButtonClass: p,
|
|
1442
1481
|
appendedContent: d
|
|
1443
|
-
} = n, b =
|
|
1482
|
+
} = n, b = O(() => e.showButtonWhenDisabled && (!e.editable || !e.readonly) && !e.disabled), w = O(() => d.value && !t.slots.groupTextTemplate), s = O(() => !!t.slots.groupTextTemplate), {
|
|
1444
1483
|
clearButtonClass: l,
|
|
1445
1484
|
clearButtonStyle: u,
|
|
1446
1485
|
onClearValue: c,
|
|
1447
1486
|
shouldShowClearButton: V
|
|
1448
1487
|
} = o;
|
|
1449
|
-
function
|
|
1450
|
-
return
|
|
1488
|
+
function M() {
|
|
1489
|
+
return k("span", {
|
|
1451
1490
|
id: "clearIcon",
|
|
1452
1491
|
class: l.value,
|
|
1453
1492
|
style: u.value,
|
|
1454
1493
|
onClick: (A) => c(A)
|
|
1455
|
-
}, [
|
|
1494
|
+
}, [k("i", {
|
|
1456
1495
|
class: "f-icon modal_close"
|
|
1457
1496
|
}, null)]);
|
|
1458
1497
|
}
|
|
1459
|
-
function
|
|
1498
|
+
function j(A) {
|
|
1460
1499
|
t.emit("iconMouseEnter", A);
|
|
1461
1500
|
}
|
|
1462
|
-
function
|
|
1501
|
+
function D(A) {
|
|
1463
1502
|
t.emit("iconMouseLeave", A);
|
|
1464
1503
|
}
|
|
1465
|
-
function
|
|
1504
|
+
function F(A) {
|
|
1466
1505
|
b.value && t.emit("clickHandle", {
|
|
1467
1506
|
originalEvent: A
|
|
1468
1507
|
}), A.stopPropagation();
|
|
1469
1508
|
}
|
|
1470
|
-
const x = e.type === "password" ? r.onClickAppendedButton :
|
|
1471
|
-
function
|
|
1472
|
-
return
|
|
1509
|
+
const x = e.type === "password" ? r.onClickAppendedButton : F;
|
|
1510
|
+
function P() {
|
|
1511
|
+
return k("span", {
|
|
1473
1512
|
class: "input-group-text",
|
|
1474
|
-
onMouseenter: (A) =>
|
|
1475
|
-
onMouseleave: (A) =>
|
|
1513
|
+
onMouseenter: (A) => j(A),
|
|
1514
|
+
onMouseleave: (A) => D(A),
|
|
1476
1515
|
innerHTML: d.value,
|
|
1477
1516
|
onClick: (A) => x(A)
|
|
1478
1517
|
}, null);
|
|
1479
1518
|
}
|
|
1480
|
-
function
|
|
1519
|
+
function L() {
|
|
1481
1520
|
return t.slots.groupTextTemplate && t.slots.groupTextTemplate();
|
|
1482
1521
|
}
|
|
1483
1522
|
function $() {
|
|
1484
|
-
return
|
|
1523
|
+
return w.value ? P : s.value ? L : "";
|
|
1485
1524
|
}
|
|
1486
|
-
const
|
|
1487
|
-
return () =>
|
|
1525
|
+
const R = $();
|
|
1526
|
+
return () => k("div", {
|
|
1488
1527
|
class: p.value
|
|
1489
|
-
}, [V.value &&
|
|
1528
|
+
}, [V.value && M(), R && R()]);
|
|
1490
1529
|
}
|
|
1491
|
-
const
|
|
1530
|
+
const Kn = /* @__PURE__ */ X({
|
|
1492
1531
|
name: "FInputGroup",
|
|
1493
|
-
props:
|
|
1532
|
+
props: ve,
|
|
1494
1533
|
emits: ["clear", "change", "blur", "click", "clickHandle", "focus", "input", "keydown", "keyup", "iconMouseEnter", "iconMouseLeave", "update:modelValue", "update:value", "updateExtendInfo", "valueChange"],
|
|
1495
1534
|
setup(e, t) {
|
|
1496
|
-
const n = I(e.modelValue), o = I(e.modelValue), r =
|
|
1535
|
+
const n = I(e.modelValue), o = I(e.modelValue), r = Rn(e, t, n, o), {
|
|
1497
1536
|
inputGroupClass: p,
|
|
1498
1537
|
inputType: d,
|
|
1499
1538
|
inputGroupStyle: b
|
|
1500
|
-
} = r,
|
|
1539
|
+
} = r, w = Un(e), {
|
|
1501
1540
|
shouldShowAppendedButton: s
|
|
1502
|
-
} =
|
|
1541
|
+
} = w, l = qn(e, t, r), {
|
|
1503
1542
|
onMouseEnter: u,
|
|
1504
1543
|
onMouseLeave: c
|
|
1505
|
-
} = l, V =
|
|
1506
|
-
|
|
1507
|
-
n.value =
|
|
1508
|
-
}),
|
|
1509
|
-
n.value =
|
|
1510
|
-
}),
|
|
1544
|
+
} = l, V = Hn(e, t, d, w), M = Jn(e, t), j = Xn(e, t, V, r), D = _n(e, t, w, l, V), F = Yn(e, t), x = O(() => e.type === "number");
|
|
1545
|
+
z(() => [e.value], ([L]) => {
|
|
1546
|
+
n.value = L, o.value = L;
|
|
1547
|
+
}), z(() => [e.modelValue], ([L]) => {
|
|
1548
|
+
n.value = L, o.value = L;
|
|
1549
|
+
}), _(() => {
|
|
1511
1550
|
e.value && (n.value = e.value, o.value = e.value);
|
|
1512
1551
|
});
|
|
1513
|
-
const
|
|
1552
|
+
const P = () => k(re, null, [k("div", {
|
|
1514
1553
|
id: "inputGroup",
|
|
1515
1554
|
class: p.value,
|
|
1516
1555
|
style: b.value,
|
|
1517
1556
|
onMouseenter: u,
|
|
1518
1557
|
onMouseleave: c
|
|
1519
|
-
}, [x.value ?
|
|
1520
|
-
return () =>
|
|
1558
|
+
}, [x.value ? M() : k(re, null, [F(), j(), s.value && D()])])]);
|
|
1559
|
+
return () => P();
|
|
1521
1560
|
}
|
|
1522
1561
|
}), g = {}, h = {}, v = {}, y = {};
|
|
1523
|
-
let
|
|
1524
|
-
function
|
|
1525
|
-
|
|
1562
|
+
let le = !1;
|
|
1563
|
+
function eo() {
|
|
1564
|
+
le || (le = !0, Le.register(g, h, v, y), je.register(g, h, v, y), Ne.register(g, h, v, y), Ae.register(g, h, v, y), Ge.register(g, h, v, y), $e.register(g, h, v, y), Re.register(g, h, v, y), te.register(g, h, v, y), qe.register(g, h, v, y), De.register(g, h, v, y), ze.register(g, h, v, y), We.register(g, h, v, y), Ue.register(g, h, v, y), He.register(g, h, v, y), Qe.register(g, h, v, y), Ie.register(g, h, v, y), Ze.register(g, h, v, y), Je.register(g, h, v, y), Xe.register(g, h, v, y), Ye.register(g, h, v, y), _e.register(g, h, v, y), Ke.register(g, h, v, y), tt.register(g, h, v, y), et.register(g, h, v, y), nt.register(g, h, v, y), ot.register(g, h, v, y), rt.register(g, h, v, y), at.register(g, h, v, y), Ve.register(g, h, v, y), it.register(g, h, v, y), lt.register(g, h, v, y), st.register(g, h, v, y), ut.register(g, h, v, y), ct.register(g, h, v, y), dt.register(g, h, v, y), pt.register(g, h, v, y), mt.register(g, h, v, y), gt.register(g, h, v, y), ht.register(g, h, v, y), ft.register(g, h, v, y), jt.register(g, h, v), vt.register(g, h, v, y), yt.register(g, h, v, y), bt.register(g, h, v, y), Ct.register(g, h, v, y), kt.register(g, h, v, y), Tt.register(g, h, v, y), Ft.register(g, h, v, y), xt.register(g, h, v, y), wt.register(g, h, v, y), Bt.register(g, h, v, y), It.register(g, h, v, y), St.register(g, h, v, y), Et.register(g, h, v, y), Vt.register(g, h, v, y), Mt.register(g, h, v, y), Pt.register(g, h, v, y), Ot.register(g, h, v, y), Lt.register(g, h, v, y));
|
|
1526
1565
|
}
|
|
1527
|
-
function
|
|
1528
|
-
|
|
1566
|
+
function to() {
|
|
1567
|
+
eo();
|
|
1529
1568
|
function e(r, p) {
|
|
1530
1569
|
const d = h[r];
|
|
1531
1570
|
return d ? d(p) : {};
|
|
1532
1571
|
}
|
|
1533
1572
|
function t(r) {
|
|
1534
|
-
return g[r] ||
|
|
1573
|
+
return g[r] || Kn;
|
|
1535
1574
|
}
|
|
1536
1575
|
function n(r) {
|
|
1537
1576
|
switch (r) {
|
|
@@ -1586,71 +1625,145 @@ function Yn() {
|
|
|
1586
1625
|
return "onSchemaSelected";
|
|
1587
1626
|
case "mapping-editor":
|
|
1588
1627
|
return "onMappingFieldsChanged";
|
|
1628
|
+
case "textarea":
|
|
1629
|
+
return "onValueChange";
|
|
1589
1630
|
}
|
|
1590
1631
|
}
|
|
1591
1632
|
function o(r) {
|
|
1592
1633
|
switch (r) {
|
|
1593
1634
|
case "combo-list":
|
|
1594
1635
|
case "input-group":
|
|
1636
|
+
case "textarea":
|
|
1595
1637
|
return "onClear";
|
|
1596
1638
|
}
|
|
1597
1639
|
}
|
|
1598
1640
|
return { resolveEditorProps: e, resolveEditorType: t, getChangeFunctionName: n, getClearFunctionName: o };
|
|
1599
1641
|
}
|
|
1600
|
-
const
|
|
1642
|
+
const no = /* @__PURE__ */ X({
|
|
1601
1643
|
name: "FDynamicFormGroup",
|
|
1602
|
-
props:
|
|
1644
|
+
props: he,
|
|
1603
1645
|
emits: ["change", "update:modelValue"],
|
|
1604
1646
|
setup(e, t) {
|
|
1605
|
-
const n = I(e.id), o = I(e.customClass), r = I(e.editor), p = I(e.label), d = I(e.modelValue), b = I(e.readonly),
|
|
1647
|
+
const n = I(e.id), o = I(e.customClass), r = I(e.editor), p = I(e.label), d = I(e.modelValue), b = I(e.readonly), w = I(e.required), s = I(e.showLabel), l = I(e.visible);
|
|
1606
1648
|
I(e.type);
|
|
1607
1649
|
const u = I(), {
|
|
1608
1650
|
resolveEditorProps: c,
|
|
1609
1651
|
resolveEditorType: V,
|
|
1610
|
-
getChangeFunctionName:
|
|
1611
|
-
getClearFunctionName:
|
|
1612
|
-
} =
|
|
1652
|
+
getChangeFunctionName: M,
|
|
1653
|
+
getClearFunctionName: j
|
|
1654
|
+
} = to(), D = O(() => ({
|
|
1613
1655
|
"form-group": !0,
|
|
1614
1656
|
"farris-form-group": !0,
|
|
1615
1657
|
"common-group": !0,
|
|
1616
1658
|
"q-state-readonly": b.value
|
|
1617
1659
|
}));
|
|
1618
|
-
function
|
|
1619
|
-
d.value = $ !== void 0 ? $ :
|
|
1660
|
+
function F(L, $) {
|
|
1661
|
+
d.value = $ !== void 0 ? $ : L, t.emit("update:modelValue", d.value), t.emit("change", d.value);
|
|
1620
1662
|
}
|
|
1621
1663
|
function x() {
|
|
1622
1664
|
t.emit("update:modelValue", "");
|
|
1623
1665
|
}
|
|
1624
|
-
const
|
|
1625
|
-
const
|
|
1626
|
-
return
|
|
1666
|
+
const P = O(() => {
|
|
1667
|
+
const L = r.value.type || "input-group", $ = V(L), R = c(L, r.value), A = M(L), U = j(r.value.type);
|
|
1668
|
+
return R[A] = F, R[U] = x, () => k($, Be({
|
|
1627
1669
|
ref: u
|
|
1628
|
-
},
|
|
1670
|
+
}, R, {
|
|
1629
1671
|
modelValue: d.value,
|
|
1630
|
-
"onUpdate:modelValue": (
|
|
1672
|
+
"onUpdate:modelValue": (a) => d.value = a
|
|
1631
1673
|
}), null);
|
|
1632
1674
|
});
|
|
1633
|
-
return
|
|
1634
|
-
n.value =
|
|
1675
|
+
return z([() => e.id, () => e.customClass, () => e.editor, () => e.label, () => e.modelValue, () => e.readonly, () => e.required, () => e.showLabel, () => e.visible], ([L, $, R, A, U, a, f, m, B]) => {
|
|
1676
|
+
n.value = L, o.value = $, r.value = R, p.value = A, d.value = U, b.value = a, w.value = f, s.value = m, l.value = B;
|
|
1635
1677
|
}), t.expose({
|
|
1636
1678
|
editorRef: u
|
|
1637
|
-
}), () => l.value &&
|
|
1679
|
+
}), () => l.value && k("div", {
|
|
1638
1680
|
id: `${n.value}-input-group`,
|
|
1639
1681
|
class: o.value
|
|
1640
|
-
}, [
|
|
1682
|
+
}, [k("div", {
|
|
1641
1683
|
class: "farris-group-wrap"
|
|
1642
|
-
}, [
|
|
1643
|
-
class:
|
|
1644
|
-
}, [s.value &&
|
|
1684
|
+
}, [k("div", {
|
|
1685
|
+
class: D.value
|
|
1686
|
+
}, [s.value && k(Vn, {
|
|
1645
1687
|
id: `${n.value}-lable`,
|
|
1646
|
-
required:
|
|
1688
|
+
required: w.value,
|
|
1647
1689
|
text: p.value,
|
|
1648
1690
|
title: p.value
|
|
1649
|
-
}, null),
|
|
1691
|
+
}, null), k("div", {
|
|
1650
1692
|
class: "farris-input-wrap"
|
|
1651
|
-
}, [
|
|
1693
|
+
}, [P.value()])])])]);
|
|
1652
1694
|
}
|
|
1653
|
-
}),
|
|
1695
|
+
}), Z = class Z {
|
|
1696
|
+
/**
|
|
1697
|
+
* 根据绑定字段类型获取可用的输入类控件
|
|
1698
|
+
*/
|
|
1699
|
+
static getEditorTypesByMDataType(t) {
|
|
1700
|
+
const n = Z.fieldControlTypeMapping[t];
|
|
1701
|
+
return n || [{ key: "", value: "" }];
|
|
1702
|
+
}
|
|
1703
|
+
/**
|
|
1704
|
+
* 获取所有输入类控件
|
|
1705
|
+
*/
|
|
1706
|
+
static getAllInputTypes() {
|
|
1707
|
+
const t = [];
|
|
1708
|
+
for (let n in Z.fieldControlTypeMapping)
|
|
1709
|
+
Z.fieldControlTypeMapping[n].forEach((o) => {
|
|
1710
|
+
t.find((r) => r.key === o.key && r.value === o.value) || t.push({ key: o.key, value: o.value });
|
|
1711
|
+
});
|
|
1712
|
+
return t;
|
|
1713
|
+
}
|
|
1714
|
+
};
|
|
1715
|
+
/**
|
|
1716
|
+
* <字段类型,可配置的控件类型列表>的映射
|
|
1717
|
+
*/
|
|
1718
|
+
T(Z, "fieldControlTypeMapping", {
|
|
1719
|
+
String: [
|
|
1720
|
+
{ key: E["input-group"].type, value: E["input-group"].name },
|
|
1721
|
+
{ key: E.lookup.type, value: E.lookup.name },
|
|
1722
|
+
{ key: E["date-picker"].type, value: E["date-picker"].name },
|
|
1723
|
+
{ key: E["check-box"].type, value: E["check-box"].name },
|
|
1724
|
+
{ key: E["radio-group"].type, value: E["radio-group"].name },
|
|
1725
|
+
{ key: E["combo-list"].type, value: E["combo-list"].name },
|
|
1726
|
+
{ key: E.textarea.type, value: E.textarea.name }
|
|
1727
|
+
],
|
|
1728
|
+
Text: [
|
|
1729
|
+
{ key: E.textarea.type, value: E.textarea.name },
|
|
1730
|
+
{ key: E.lookup.type, value: E.lookup.name }
|
|
1731
|
+
],
|
|
1732
|
+
Decimal: [
|
|
1733
|
+
{ key: E["number-spinner"].type, value: E["number-spinner"].name }
|
|
1734
|
+
],
|
|
1735
|
+
Integer: [
|
|
1736
|
+
{ key: E["number-spinner"].type, value: E["number-spinner"].name }
|
|
1737
|
+
],
|
|
1738
|
+
Number: [
|
|
1739
|
+
{ key: E["number-spinner"].type, value: E["number-spinner"].name }
|
|
1740
|
+
],
|
|
1741
|
+
BigNumber: [
|
|
1742
|
+
{ key: E["number-spinner"].type, value: E["number-spinner"].name }
|
|
1743
|
+
],
|
|
1744
|
+
Date: [
|
|
1745
|
+
{ key: E["date-picker"].type, value: E["date-picker"].name }
|
|
1746
|
+
],
|
|
1747
|
+
DateTime: [
|
|
1748
|
+
{ key: E["date-picker"].type, value: E["date-picker"].name }
|
|
1749
|
+
],
|
|
1750
|
+
Boolean: [
|
|
1751
|
+
{ key: E.switch.type, value: E.switch.name },
|
|
1752
|
+
{ key: E["check-box"].type, value: E["check-box"].name }
|
|
1753
|
+
],
|
|
1754
|
+
Enum: [
|
|
1755
|
+
{ key: E["combo-list"].type, value: E["combo-list"].name },
|
|
1756
|
+
{ key: E["radio-group"].type, value: E["radio-group"].name }
|
|
1757
|
+
],
|
|
1758
|
+
Object: [
|
|
1759
|
+
{ key: E.lookup.type, value: E.lookup.name },
|
|
1760
|
+
{ key: E["combo-list"].type, value: E["combo-list"].name },
|
|
1761
|
+
{ key: E["radio-group"].type, value: E["radio-group"].name }
|
|
1762
|
+
]
|
|
1763
|
+
});
|
|
1764
|
+
let se = Z;
|
|
1765
|
+
I(0);
|
|
1766
|
+
const oo = {
|
|
1654
1767
|
id: { type: String, default: "" },
|
|
1655
1768
|
/** 筛选组件配置器,具体配置项可查看各组件文档 */
|
|
1656
1769
|
editor: { type: Object, default: {} },
|
|
@@ -1665,14 +1778,14 @@ const Kn = /* @__PURE__ */ Z({
|
|
|
1665
1778
|
*/
|
|
1666
1779
|
selectOnCreated: { type: Boolean, default: !1 }
|
|
1667
1780
|
};
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1781
|
+
K(
|
|
1782
|
+
oo,
|
|
1783
|
+
ge,
|
|
1784
|
+
ne,
|
|
1672
1785
|
void 0
|
|
1673
1786
|
);
|
|
1674
|
-
var
|
|
1675
|
-
const
|
|
1787
|
+
var ro = /* @__PURE__ */ ((e) => (e[e.IntType = 0] = "IntType", e[e.StringType = 1] = "StringType", e[e.BoolType = 2] = "BoolType", e))(ro || {}), ye = /* @__PURE__ */ ((e) => (e[e.Value = 0] = "Value", e[e.SmartHelp = 1] = "SmartHelp", e[e.Enum = 2] = "Enum", e[e.Express = 3] = "Express", e))(ye || {}), be = /* @__PURE__ */ ((e) => (e.Equal = "0", e.NotEqual = "1", e.Greater = "2", e.GreaterOrEqual = "3", e.Less = "4", e.LessOrEqual = "5", e.Like = "6", e.LikeStartWith = "7", e.LikeEndWith = "8", e))(be || {});
|
|
1788
|
+
const ao = [
|
|
1676
1789
|
{
|
|
1677
1790
|
value: "0",
|
|
1678
1791
|
name: "等于"
|
|
@@ -1709,7 +1822,7 @@ const no = [
|
|
|
1709
1822
|
value: "8",
|
|
1710
1823
|
name: "结束是"
|
|
1711
1824
|
}
|
|
1712
|
-
],
|
|
1825
|
+
], io = {
|
|
1713
1826
|
"button-edit": ["0", "1", " 6", "7", "8"],
|
|
1714
1827
|
"check-box": ["0"],
|
|
1715
1828
|
"combo-list": ["0", "1"],
|
|
@@ -1729,18 +1842,18 @@ const no = [
|
|
|
1729
1842
|
"radio-group": ["0"],
|
|
1730
1843
|
text: ["0", "1", " 6", "7", "8"]
|
|
1731
1844
|
};
|
|
1732
|
-
function
|
|
1845
|
+
function lo(e, t, n) {
|
|
1733
1846
|
const { fieldMap: o } = n;
|
|
1734
1847
|
function r(p) {
|
|
1735
1848
|
const d = o.get(p.fieldCode);
|
|
1736
1849
|
if (!d)
|
|
1737
1850
|
return [];
|
|
1738
|
-
const b = d.editor.type,
|
|
1739
|
-
return
|
|
1851
|
+
const b = d.editor.type, w = new Set(io[b]);
|
|
1852
|
+
return ao.filter((l) => w.has(l.value));
|
|
1740
1853
|
}
|
|
1741
1854
|
return { getCompareOperators: r };
|
|
1742
1855
|
}
|
|
1743
|
-
function
|
|
1856
|
+
function so() {
|
|
1744
1857
|
const e = I({ relation: 0, items: [], children: [], path: [], groupId: 0, level: 0 }), t = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Map();
|
|
1745
1858
|
let o = 0;
|
|
1746
1859
|
function r() {
|
|
@@ -1748,376 +1861,376 @@ function io() {
|
|
|
1748
1861
|
id: "",
|
|
1749
1862
|
fieldCode: "",
|
|
1750
1863
|
fieldName: "",
|
|
1751
|
-
compareType:
|
|
1752
|
-
valueType:
|
|
1753
|
-
value: new
|
|
1864
|
+
compareType: be.Equal,
|
|
1865
|
+
valueType: ye.Value,
|
|
1866
|
+
value: new ce(),
|
|
1754
1867
|
relation: 0,
|
|
1755
1868
|
conditionId: Date.now()
|
|
1756
1869
|
};
|
|
1757
1870
|
}
|
|
1758
|
-
function p(
|
|
1759
|
-
return { relation:
|
|
1871
|
+
function p(a, f) {
|
|
1872
|
+
return { relation: a, items: [], children: [], path: [], groupId: ++o, level: f };
|
|
1760
1873
|
}
|
|
1761
1874
|
function d() {
|
|
1762
|
-
const
|
|
1763
|
-
n.forEach((
|
|
1764
|
-
|
|
1765
|
-
}), t.forEach((
|
|
1766
|
-
|
|
1767
|
-
}), e.value =
|
|
1768
|
-
}
|
|
1769
|
-
function b(
|
|
1770
|
-
const
|
|
1771
|
-
let
|
|
1772
|
-
return
|
|
1875
|
+
const a = Object.assign({}, e.value);
|
|
1876
|
+
n.forEach((f, m) => {
|
|
1877
|
+
f.groupId === a.groupId && n.set(m, a);
|
|
1878
|
+
}), t.forEach((f, m) => {
|
|
1879
|
+
f.groupId === a.groupId && t.set(m, a);
|
|
1880
|
+
}), e.value = a;
|
|
1881
|
+
}
|
|
1882
|
+
function b(a) {
|
|
1883
|
+
const f = /* @__PURE__ */ new Map();
|
|
1884
|
+
let m = 0;
|
|
1885
|
+
return a.forEach((B, i) => {
|
|
1773
1886
|
var C, S;
|
|
1774
|
-
if (
|
|
1887
|
+
if (m += ((C = B.lBracket) == null ? void 0 : C.length) || 0, f.set(i, m), m -= ((S = B.rBracket) == null ? void 0 : S.length) || 0, m < 0)
|
|
1775
1888
|
throw new Error("The right bracket is out of range.");
|
|
1776
|
-
}),
|
|
1889
|
+
}), f;
|
|
1777
1890
|
}
|
|
1778
|
-
function
|
|
1779
|
-
for (let C = 0; C <
|
|
1780
|
-
const S =
|
|
1781
|
-
|
|
1891
|
+
function w(a, f, m, B, i) {
|
|
1892
|
+
for (let C = 0; C < f; C++) {
|
|
1893
|
+
const S = a + (C + 1), W = p(i, S);
|
|
1894
|
+
m.children.push(W), n.set(W.groupId, m), m = m.children[m.children.length - 1], B.push(m);
|
|
1782
1895
|
}
|
|
1783
|
-
return
|
|
1896
|
+
return m;
|
|
1784
1897
|
}
|
|
1785
|
-
function s(
|
|
1786
|
-
for (let
|
|
1898
|
+
function s(a, f, m, B, i) {
|
|
1899
|
+
for (let q = f; q <= 0; q++)
|
|
1787
1900
|
B.pop();
|
|
1788
1901
|
const C = B[B.length - 1];
|
|
1789
1902
|
if (!C)
|
|
1790
1903
|
throw new Error("The group path is out of range");
|
|
1791
|
-
const S =
|
|
1792
|
-
return C.children.push(
|
|
1904
|
+
const S = a + f, W = p(i, S);
|
|
1905
|
+
return C.children.push(W), n.set(W.groupId, C), m = C.children[C.children.length - 1], B.push(m), m;
|
|
1793
1906
|
}
|
|
1794
|
-
function l(
|
|
1795
|
-
|
|
1796
|
-
const
|
|
1797
|
-
return
|
|
1907
|
+
function l(a, f, m, B) {
|
|
1908
|
+
m.pop();
|
|
1909
|
+
const i = m[m.length - 1], C = p(B, a);
|
|
1910
|
+
return i.children.push(C), n.set(C.groupId, i), f = i.children[i.children.length - 1], m.push(f), f;
|
|
1798
1911
|
}
|
|
1799
|
-
function u(
|
|
1800
|
-
let S =
|
|
1912
|
+
function u(a, f, m, B, i, C) {
|
|
1913
|
+
let S = a[a.length - 1];
|
|
1801
1914
|
if (!S)
|
|
1802
1915
|
throw new Error("The group path is out of range");
|
|
1803
|
-
const
|
|
1804
|
-
if (
|
|
1805
|
-
return
|
|
1806
|
-
const
|
|
1807
|
-
return S =
|
|
1808
|
-
}
|
|
1809
|
-
function c(
|
|
1810
|
-
const
|
|
1811
|
-
return
|
|
1812
|
-
const
|
|
1813
|
-
|
|
1814
|
-
}), e.value =
|
|
1916
|
+
const W = f.get(B) || 0, q = f.get(m) || 0;
|
|
1917
|
+
if (m < 0 || m === B)
|
|
1918
|
+
return a[a.length - 1];
|
|
1919
|
+
const G = W - q, N = i && i.relation !== void 0 ? i.relation : 1;
|
|
1920
|
+
return S = G > 0 ? w(q, G, S, a, N) : S, S = G < 0 ? s(q, G, S, a, N) : S, S = G === 0 && q > 0 && W > 0 && i && C && !!i.rBracket && !!C.lBracket ? l(q, S, a, N) : S, S;
|
|
1921
|
+
}
|
|
1922
|
+
function c(a) {
|
|
1923
|
+
const m = { relation: a.length && a[0].relation !== void 0 ? a[0].relation : 1, items: [], children: [], path: [], groupId: 0, level: 0 }, B = [m], i = b(a);
|
|
1924
|
+
return a.forEach((C, S) => {
|
|
1925
|
+
const W = S - 1, q = a[W], G = u(B, i, W, S, q, C);
|
|
1926
|
+
G.items.push(C), t.set(C.conditionId, G);
|
|
1927
|
+
}), e.value = m, m;
|
|
1815
1928
|
}
|
|
1816
1929
|
function V() {
|
|
1817
|
-
const
|
|
1818
|
-
t.set(
|
|
1930
|
+
const a = r();
|
|
1931
|
+
t.set(a.conditionId, e.value), e.value.items.push(a);
|
|
1819
1932
|
}
|
|
1820
|
-
function
|
|
1821
|
-
if (!
|
|
1933
|
+
function M(a) {
|
|
1934
|
+
if (!a)
|
|
1822
1935
|
return;
|
|
1823
|
-
const
|
|
1824
|
-
if (
|
|
1825
|
-
const
|
|
1826
|
-
t.set(B.conditionId,
|
|
1936
|
+
const f = t.get(a.conditionId);
|
|
1937
|
+
if (f) {
|
|
1938
|
+
const m = f.items.findIndex((i) => i.conditionId === a.conditionId) + 1, B = r();
|
|
1939
|
+
t.set(B.conditionId, f), f.items.splice(m, 0, B), d();
|
|
1827
1940
|
}
|
|
1828
1941
|
}
|
|
1829
|
-
function
|
|
1830
|
-
const
|
|
1831
|
-
|
|
1942
|
+
function j(a) {
|
|
1943
|
+
const f = t.get(a.conditionId);
|
|
1944
|
+
f && (f.items = f.items.filter((m) => m.conditionId !== a.conditionId), t.delete(a.conditionId), U(), d());
|
|
1832
1945
|
}
|
|
1833
|
-
function
|
|
1834
|
-
|
|
1835
|
-
const S = C.conditionId !== void 0,
|
|
1946
|
+
function D(a, f, m, B) {
|
|
1947
|
+
a.reduce((i, C) => {
|
|
1948
|
+
const S = C.conditionId !== void 0, W = C.groupId !== void 0;
|
|
1836
1949
|
if (S) {
|
|
1837
|
-
const
|
|
1838
|
-
|
|
1950
|
+
const q = C;
|
|
1951
|
+
m.push(q), i.items.set(q.conditionId, q);
|
|
1839
1952
|
}
|
|
1840
|
-
if (
|
|
1841
|
-
const
|
|
1842
|
-
B.push(
|
|
1953
|
+
if (W) {
|
|
1954
|
+
const q = C;
|
|
1955
|
+
B.push(q), i.groups.set(q.groupId, q);
|
|
1843
1956
|
}
|
|
1844
|
-
return
|
|
1845
|
-
},
|
|
1957
|
+
return i;
|
|
1958
|
+
}, f);
|
|
1846
1959
|
}
|
|
1847
|
-
function
|
|
1848
|
-
|
|
1960
|
+
function F(a, f, m, B, i) {
|
|
1961
|
+
a && (a.items = f.length ? a.items.filter((C) => !m.has(C.conditionId)) : a.items, a.children = B.length ? a.children.filter((C) => !i.has(C.groupId)) : a.children);
|
|
1849
1962
|
}
|
|
1850
|
-
function x(
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
}),
|
|
1854
|
-
|
|
1963
|
+
function x(a, f, m) {
|
|
1964
|
+
f.forEach((B) => {
|
|
1965
|
+
a.items.push(B), t.set(B.conditionId, a);
|
|
1966
|
+
}), m.forEach((B) => {
|
|
1967
|
+
a.children.push(B), n.set(B.groupId, a);
|
|
1855
1968
|
});
|
|
1856
1969
|
}
|
|
1857
|
-
function
|
|
1858
|
-
const
|
|
1859
|
-
if (
|
|
1860
|
-
|
|
1861
|
-
const S = p(
|
|
1862
|
-
x(S,
|
|
1970
|
+
function P(a) {
|
|
1971
|
+
const f = a[0], m = f.conditionId !== void 0 ? t.get(f.conditionId) : n.get(f.groupId), B = { items: /* @__PURE__ */ new Map(), groups: /* @__PURE__ */ new Map() }, i = [], C = [];
|
|
1972
|
+
if (m) {
|
|
1973
|
+
D(a, B, i, C), F(m, i, B.items, C, B.groups);
|
|
1974
|
+
const S = p(m.relation, m.level + 1);
|
|
1975
|
+
x(S, i, C), m.children.push(S), n.set(S.groupId, m), d();
|
|
1863
1976
|
}
|
|
1864
1977
|
}
|
|
1865
|
-
function
|
|
1866
|
-
const
|
|
1867
|
-
B && (B.children = B.children.filter((
|
|
1868
|
-
B.items.push(
|
|
1869
|
-
}),
|
|
1870
|
-
B.children.push(
|
|
1978
|
+
function L(a) {
|
|
1979
|
+
const f = [...a.items], m = [...a.children], B = n.get(a.groupId);
|
|
1980
|
+
B && (B.children = B.children.filter((i) => i.groupId !== a.groupId), n.delete(a.groupId), f.forEach((i) => {
|
|
1981
|
+
B.items.push(i), t.set(i.conditionId, B);
|
|
1982
|
+
}), m.forEach((i) => {
|
|
1983
|
+
B.children.push(i), n.set(i.groupId, B);
|
|
1871
1984
|
}), d());
|
|
1872
1985
|
}
|
|
1873
|
-
function $(
|
|
1874
|
-
|
|
1986
|
+
function $(a) {
|
|
1987
|
+
a.relation = a.relation === 1 ? 2 : 1, d();
|
|
1875
1988
|
}
|
|
1876
|
-
let
|
|
1877
|
-
function A(
|
|
1878
|
-
const { relation:
|
|
1879
|
-
return (
|
|
1880
|
-
const S =
|
|
1881
|
-
return S[0].lBracket = (S[0].lBracket || "") + "(", S[S.length - 1].rBracket = (S[S.length - 1].rBracket || "") + ")", S[S.length - 1].relation =
|
|
1989
|
+
let R;
|
|
1990
|
+
function A(a) {
|
|
1991
|
+
const { relation: f } = a;
|
|
1992
|
+
return (a.children && a.children.length ? a.children.map((B, i, C) => {
|
|
1993
|
+
const S = R(B);
|
|
1994
|
+
return S[0].lBracket = (S[0].lBracket || "") + "(", S[S.length - 1].rBracket = (S[S.length - 1].rBracket || "") + ")", S[S.length - 1].relation = i < C.length - 1 ? f : 0, S;
|
|
1882
1995
|
}) : []).flat();
|
|
1883
1996
|
}
|
|
1884
|
-
|
|
1885
|
-
const { relation:
|
|
1886
|
-
return [...
|
|
1997
|
+
R = (a = e.value) => {
|
|
1998
|
+
const { relation: f } = a, m = a.items.map((i, C, S) => (i.lBracket = C === 0 ? "(" : "", i.rBracket = C === S.length - 1 ? ")" : "", i.relation = C < S.length - 1 ? f || 1 : 0, i)), B = A(a);
|
|
1999
|
+
return [...m, ...B];
|
|
1887
2000
|
};
|
|
1888
|
-
function
|
|
1889
|
-
const
|
|
1890
|
-
if (
|
|
1891
|
-
|
|
1892
|
-
}),
|
|
1893
|
-
const
|
|
1894
|
-
e.value.relation =
|
|
1895
|
-
} else
|
|
2001
|
+
function U(a) {
|
|
2002
|
+
const f = a || e.value;
|
|
2003
|
+
if (f.children.length && f.children.forEach((m) => {
|
|
2004
|
+
U(m);
|
|
2005
|
+
}), f.level === 0 && !f.items.length && f.children.length === 1) {
|
|
2006
|
+
const m = f.children[0];
|
|
2007
|
+
e.value.relation = m.relation, L(m);
|
|
2008
|
+
} else f.items.length === 0 && f.children.length <= 1 && L(f);
|
|
1896
2009
|
}
|
|
1897
2010
|
return {
|
|
1898
2011
|
addCondition: V,
|
|
1899
2012
|
changeGroupRelation: $,
|
|
1900
2013
|
conditionGroupMap: t,
|
|
1901
|
-
getConditions:
|
|
1902
|
-
group:
|
|
2014
|
+
getConditions: R,
|
|
2015
|
+
group: P,
|
|
1903
2016
|
groupParentMap: n,
|
|
1904
|
-
insertConditionTo:
|
|
2017
|
+
insertConditionTo: M,
|
|
1905
2018
|
loadConditionGroup: c,
|
|
1906
2019
|
refresh: d,
|
|
1907
|
-
removeCondition:
|
|
2020
|
+
removeCondition: j,
|
|
1908
2021
|
rootGroup: e,
|
|
1909
|
-
unGroup:
|
|
2022
|
+
unGroup: L
|
|
1910
2023
|
};
|
|
1911
2024
|
}
|
|
1912
|
-
function
|
|
2025
|
+
function uo(e, t, n) {
|
|
1913
2026
|
const o = I(/* @__PURE__ */ new Set()), r = I(/* @__PURE__ */ new Set()), { conditionGroupMap: p, groupParentMap: d } = n;
|
|
1914
|
-
let b,
|
|
1915
|
-
function s(
|
|
1916
|
-
let x = b.level <=
|
|
1917
|
-
const
|
|
1918
|
-
for (;
|
|
1919
|
-
|
|
1920
|
-
return
|
|
1921
|
-
}
|
|
1922
|
-
function l(
|
|
1923
|
-
r.value.add(
|
|
1924
|
-
}
|
|
1925
|
-
function u(
|
|
1926
|
-
const { conditionId: x } =
|
|
2027
|
+
let b, w;
|
|
2028
|
+
function s(F) {
|
|
2029
|
+
let x = b.level <= F.level ? b : F, P = b.level > F.level ? b : F;
|
|
2030
|
+
const L = [];
|
|
2031
|
+
for (; P && x && P !== x; )
|
|
2032
|
+
P.level > x.level ? (L.push(P), P = d.get(P.groupId)) : P.level === x.level && (x = d.get(x.groupId), x && L.unshift(x));
|
|
2033
|
+
return L;
|
|
2034
|
+
}
|
|
2035
|
+
function l(F) {
|
|
2036
|
+
r.value.add(F.groupId), F.items.forEach((x) => o.value.add(x.conditionId)), F.children.forEach((x) => l(x));
|
|
2037
|
+
}
|
|
2038
|
+
function u(F) {
|
|
2039
|
+
const { conditionId: x } = F;
|
|
1927
2040
|
o.value.add(x), b = o.value.size === 0 ? p.get(x) : b;
|
|
1928
|
-
const
|
|
1929
|
-
s(
|
|
2041
|
+
const P = p.get(F.conditionId);
|
|
2042
|
+
s(P).forEach(($) => l($));
|
|
1930
2043
|
}
|
|
1931
|
-
const c =
|
|
1932
|
-
r.value.delete(
|
|
1933
|
-
const x = d.get(
|
|
2044
|
+
const c = O(() => o.value.size === 0 && r.value.size === 1), V = function(F) {
|
|
2045
|
+
r.value.delete(F.groupId), F.items.forEach((P) => w(P)), F.children.forEach((P) => !c.value && V(P));
|
|
2046
|
+
const x = d.get(F.groupId);
|
|
1934
2047
|
x && r.value.has(x.groupId) && V(x);
|
|
1935
2048
|
};
|
|
1936
|
-
|
|
1937
|
-
const { conditionId: x } =
|
|
2049
|
+
w = function(F) {
|
|
2050
|
+
const { conditionId: x } = F;
|
|
1938
2051
|
if (o.value.has(x) && o.value.delete(x), r.value.size > 0) {
|
|
1939
|
-
const
|
|
1940
|
-
|
|
2052
|
+
const P = p.get(x);
|
|
2053
|
+
P && r.value.has(P.groupId) && V(P);
|
|
1941
2054
|
}
|
|
1942
2055
|
};
|
|
1943
|
-
function
|
|
1944
|
-
const { conditionId: x } =
|
|
1945
|
-
o.value.size === 0 && (b = p.get(x)), o.value.has(x) ?
|
|
2056
|
+
function M(F) {
|
|
2057
|
+
const { conditionId: x } = F;
|
|
2058
|
+
o.value.size === 0 && (b = p.get(x)), o.value.has(x) ? w(F) : u(F);
|
|
1946
2059
|
}
|
|
1947
|
-
function
|
|
1948
|
-
const
|
|
1949
|
-
return b && (b.items.filter((x) => o.value.has(x.conditionId)).forEach((x) =>
|
|
2060
|
+
function j() {
|
|
2061
|
+
const F = [];
|
|
2062
|
+
return b && (b.items.filter((x) => o.value.has(x.conditionId)).forEach((x) => F.push(x)), b.children.filter((x) => r.value.has(x.groupId)).forEach((x) => F.push(x))), F;
|
|
1950
2063
|
}
|
|
1951
|
-
function
|
|
2064
|
+
function D() {
|
|
1952
2065
|
o.value.clear(), r.value.clear();
|
|
1953
2066
|
}
|
|
1954
|
-
return { clear:
|
|
2067
|
+
return { clear: D, getSelectedGroupItem: j, selectedItems: o, toggleSelect: M };
|
|
1955
2068
|
}
|
|
1956
|
-
const
|
|
2069
|
+
const ee = /* @__PURE__ */ X({
|
|
1957
2070
|
name: "FConditionList",
|
|
1958
|
-
props:
|
|
2071
|
+
props: ue,
|
|
1959
2072
|
emits: ["valueChange", "labelCodeChange", "compareTypeChange"],
|
|
1960
2073
|
setup(e, t) {
|
|
1961
|
-
const n = I(e.key), o = I(e.conditions), r =
|
|
2074
|
+
const n = I(e.key), o = I(e.conditions), r = pe(e), {
|
|
1962
2075
|
convertToSingleControl: p,
|
|
1963
2076
|
fields: d,
|
|
1964
2077
|
fieldMap: b,
|
|
1965
|
-
loadFieldConfigs:
|
|
1966
|
-
} = r, s =
|
|
2078
|
+
loadFieldConfigs: w
|
|
2079
|
+
} = r, s = so(), {
|
|
1967
2080
|
addCondition: l,
|
|
1968
2081
|
changeGroupRelation: u,
|
|
1969
2082
|
getConditions: c,
|
|
1970
2083
|
group: V,
|
|
1971
|
-
insertConditionTo:
|
|
1972
|
-
loadConditionGroup:
|
|
1973
|
-
refresh:
|
|
1974
|
-
removeCondition:
|
|
2084
|
+
insertConditionTo: M,
|
|
2085
|
+
loadConditionGroup: j,
|
|
2086
|
+
refresh: D,
|
|
2087
|
+
removeCondition: F,
|
|
1975
2088
|
rootGroup: x,
|
|
1976
|
-
unGroup:
|
|
2089
|
+
unGroup: P
|
|
1977
2090
|
} = s, {
|
|
1978
|
-
createConditionValue:
|
|
1979
|
-
} =
|
|
1980
|
-
selectedItems:
|
|
2091
|
+
createConditionValue: L
|
|
2092
|
+
} = de(), $ = uo(e, t, s), {
|
|
2093
|
+
selectedItems: R,
|
|
1981
2094
|
toggleSelect: A
|
|
1982
2095
|
} = $, {
|
|
1983
|
-
getCompareOperators:
|
|
1984
|
-
} =
|
|
1985
|
-
|
|
1986
|
-
function
|
|
1987
|
-
var
|
|
1988
|
-
const
|
|
2096
|
+
getCompareOperators: U
|
|
2097
|
+
} = lo(e, t, r);
|
|
2098
|
+
w(!1), d.value = p(d.value), j(o.value);
|
|
2099
|
+
function a(G) {
|
|
2100
|
+
var Q;
|
|
2101
|
+
const N = ((Q = b.get(G.fieldCode)) == null ? void 0 : Q.editor) || {
|
|
1989
2102
|
type: "text"
|
|
1990
2103
|
};
|
|
1991
|
-
|
|
2104
|
+
G.value = L(N.type, void 0), t.emit("labelCodeChange", G);
|
|
1992
2105
|
}
|
|
1993
|
-
function
|
|
1994
|
-
t.emit("compareTypeChange",
|
|
2106
|
+
function f(G, N) {
|
|
2107
|
+
t.emit("compareTypeChange", N);
|
|
1995
2108
|
}
|
|
1996
|
-
function
|
|
2109
|
+
function m() {
|
|
1997
2110
|
}
|
|
1998
2111
|
t.expose({
|
|
1999
2112
|
getConditions: c
|
|
2000
2113
|
});
|
|
2001
|
-
function B(
|
|
2002
|
-
t.emit("valueChange",
|
|
2114
|
+
function B(G, N) {
|
|
2115
|
+
t.emit("valueChange", G, N);
|
|
2003
2116
|
}
|
|
2004
|
-
function
|
|
2005
|
-
return
|
|
2006
|
-
var
|
|
2007
|
-
return
|
|
2117
|
+
function i(G) {
|
|
2118
|
+
return G.items.map((N) => {
|
|
2119
|
+
var Q;
|
|
2120
|
+
return k("div", {
|
|
2008
2121
|
class: "condition-list-item",
|
|
2009
|
-
key:
|
|
2010
|
-
}, [
|
|
2122
|
+
key: N.conditionId
|
|
2123
|
+
}, [k("div", {
|
|
2011
2124
|
class: "condition-list-item-type mr-3"
|
|
2012
|
-
}, [
|
|
2125
|
+
}, [k(te, {
|
|
2013
2126
|
"value-field": "labelCode",
|
|
2014
2127
|
"text-field": "name",
|
|
2015
2128
|
"id-field": "id",
|
|
2016
2129
|
data: d.value,
|
|
2017
|
-
modelValue:
|
|
2018
|
-
"onUpdate:modelValue": (
|
|
2019
|
-
onChange: (
|
|
2020
|
-
}, null)]),
|
|
2130
|
+
modelValue: N.fieldCode,
|
|
2131
|
+
"onUpdate:modelValue": (H) => N.fieldCode = H,
|
|
2132
|
+
onChange: (H) => a(N)
|
|
2133
|
+
}, null)]), k("div", {
|
|
2021
2134
|
class: "condition-list-item-compare mr-3"
|
|
2022
|
-
}, [
|
|
2135
|
+
}, [k(te, {
|
|
2023
2136
|
"value-field": "value",
|
|
2024
2137
|
"text-field": "name",
|
|
2025
2138
|
"id-field": "id",
|
|
2026
|
-
data:
|
|
2027
|
-
modelValue:
|
|
2028
|
-
"onUpdate:modelValue": (
|
|
2029
|
-
onChange: (
|
|
2030
|
-
}, null)]),
|
|
2139
|
+
data: U(N),
|
|
2140
|
+
modelValue: N.compareType,
|
|
2141
|
+
"onUpdate:modelValue": (H) => N.compareType = H,
|
|
2142
|
+
onChange: (H) => f(H, N)
|
|
2143
|
+
}, null)]), k("div", {
|
|
2031
2144
|
class: "condition-list-item-control mr-3"
|
|
2032
|
-
}, [
|
|
2033
|
-
editor: (
|
|
2145
|
+
}, [k(no, {
|
|
2146
|
+
editor: (Q = b.get(N.fieldCode)) == null ? void 0 : Q.editor,
|
|
2034
2147
|
showLabel: !1,
|
|
2035
|
-
modelValue:
|
|
2036
|
-
"onUpdate:modelValue": (
|
|
2037
|
-
onChange: (
|
|
2038
|
-
B(
|
|
2148
|
+
modelValue: N.value.value,
|
|
2149
|
+
"onUpdate:modelValue": (H) => N.value.value = H,
|
|
2150
|
+
onChange: (H) => {
|
|
2151
|
+
B(H, N);
|
|
2039
2152
|
}
|
|
2040
|
-
}, null)]),
|
|
2153
|
+
}, null)]), k("div", {
|
|
2041
2154
|
class: "condition-list-item-extend"
|
|
2042
|
-
}, [
|
|
2155
|
+
}, [k("span", {
|
|
2043
2156
|
class: "f-icon f-icon-plus-sm mr-2",
|
|
2044
|
-
onClick: () =>
|
|
2045
|
-
}, null),
|
|
2157
|
+
onClick: () => M(N)
|
|
2158
|
+
}, null), k("span", {
|
|
2046
2159
|
class: "f-icon f-icon-minus-sm",
|
|
2047
|
-
onClick: () =>
|
|
2048
|
-
}, null)]),
|
|
2160
|
+
onClick: () => F(N)
|
|
2161
|
+
}, null)]), k("div", {
|
|
2049
2162
|
class: "custom-control custom-checkbox"
|
|
2050
|
-
}, [
|
|
2163
|
+
}, [k("input", {
|
|
2051
2164
|
title: "selection",
|
|
2052
2165
|
class: "custom-control-input",
|
|
2053
2166
|
type: "checkbox",
|
|
2054
|
-
checked:
|
|
2055
|
-
}, null),
|
|
2167
|
+
checked: R.value.has(N.conditionId)
|
|
2168
|
+
}, null), k("label", {
|
|
2056
2169
|
class: "custom-control-label",
|
|
2057
|
-
onClick: () => A(
|
|
2170
|
+
onClick: () => A(N)
|
|
2058
2171
|
}, null)])]);
|
|
2059
2172
|
});
|
|
2060
2173
|
}
|
|
2061
|
-
function C(
|
|
2062
|
-
return
|
|
2174
|
+
function C(G) {
|
|
2175
|
+
return k("div", {
|
|
2063
2176
|
class: "condition-list-relation"
|
|
2064
|
-
}, [
|
|
2177
|
+
}, [k("span", {
|
|
2065
2178
|
class: "condition-list-relation-close f-icon-filter-cancel btn-link",
|
|
2066
|
-
onClick: () =>
|
|
2067
|
-
}, null),
|
|
2179
|
+
onClick: () => P(G)
|
|
2180
|
+
}, null), k("span", {
|
|
2068
2181
|
class: "condition-list-relation-text btn-link",
|
|
2069
|
-
onClick: () => u(
|
|
2070
|
-
}, [
|
|
2182
|
+
onClick: () => u(G)
|
|
2183
|
+
}, [G.relation === 1 ? "与" : "或"])]);
|
|
2071
2184
|
}
|
|
2072
|
-
function S(
|
|
2073
|
-
return
|
|
2185
|
+
function S(G) {
|
|
2186
|
+
return k("div", {
|
|
2074
2187
|
class: "condition-list-content"
|
|
2075
|
-
}, [
|
|
2188
|
+
}, [k("div", {
|
|
2076
2189
|
class: "condition-list-content-group"
|
|
2077
|
-
}, [
|
|
2190
|
+
}, [i(G), G.children && G.children.map((N) => S(N))]), C(G)]);
|
|
2078
2191
|
}
|
|
2079
|
-
function
|
|
2192
|
+
function W() {
|
|
2080
2193
|
V($.getSelectedGroupItem()), $.clear();
|
|
2081
2194
|
}
|
|
2082
|
-
function
|
|
2083
|
-
return
|
|
2195
|
+
function q() {
|
|
2196
|
+
return k("div", {
|
|
2084
2197
|
class: "condition-list-bottom"
|
|
2085
|
-
}, [
|
|
2198
|
+
}, [k("div", {
|
|
2086
2199
|
class: "add-condition-btn mb-1 mr-3",
|
|
2087
2200
|
onClick: l
|
|
2088
|
-
}, [
|
|
2201
|
+
}, [k("span", {
|
|
2089
2202
|
class: "f-icon f-icon-filter-add"
|
|
2090
|
-
}, null),
|
|
2203
|
+
}, null), k("span", {
|
|
2091
2204
|
class: "ml-1"
|
|
2092
|
-
}, [
|
|
2205
|
+
}, [Y("添加条件")])]), k("div", {
|
|
2093
2206
|
class: "add-condition-btn mb-1",
|
|
2094
|
-
onClick:
|
|
2095
|
-
}, [
|
|
2207
|
+
onClick: W
|
|
2208
|
+
}, [k("span", {
|
|
2096
2209
|
class: "f-icon f-icon-filter-grouping"
|
|
2097
|
-
}, null),
|
|
2210
|
+
}, null), k("span", {
|
|
2098
2211
|
class: "ml-1"
|
|
2099
|
-
}, [
|
|
2212
|
+
}, [Y("生成条件组")])]), k("div", {
|
|
2100
2213
|
class: "condition-list-reset add-condition-btn",
|
|
2101
|
-
onClick:
|
|
2102
|
-
}, [
|
|
2214
|
+
onClick: m
|
|
2215
|
+
}, [Y("重置")])]);
|
|
2103
2216
|
}
|
|
2104
|
-
return () =>
|
|
2217
|
+
return () => k("div", {
|
|
2105
2218
|
class: "condition-list",
|
|
2106
2219
|
key: n.value
|
|
2107
|
-
}, [
|
|
2220
|
+
}, [k("div", {
|
|
2108
2221
|
class: "condition-list-body"
|
|
2109
|
-
}, [S(x.value)]),
|
|
2222
|
+
}, [S(x.value)]), q()]);
|
|
2110
2223
|
}
|
|
2111
2224
|
});
|
|
2112
|
-
|
|
2113
|
-
e.component(
|
|
2225
|
+
ee.install = (e) => {
|
|
2226
|
+
e.component(ie.name, ie).component(ee.name, ee);
|
|
2114
2227
|
};
|
|
2115
2228
|
export {
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2229
|
+
ro as EnumType,
|
|
2230
|
+
ie as FConditionFields,
|
|
2231
|
+
ee as FConditionList,
|
|
2232
|
+
ye as ValueType,
|
|
2233
|
+
ue as conditionProps,
|
|
2234
|
+
ee as default,
|
|
2235
|
+
so as useCondition
|
|
2123
2236
|
};
|