@opentiny/vue-search-box-saas 2.28.0 → 2.28.2
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/index.css +8 -3
- package/index.js +967 -906
- package/index.js.map +1 -1
- package/package.json +15 -20
package/index.js
CHANGED
|
@@ -1,37 +1,21 @@
|
|
|
1
1
|
import './index.css';
|
|
2
|
-
import { defineComponent as J, $prefix as
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
import Ie from "@opentiny/vue-date-picker";
|
|
10
|
-
import Ge from "@opentiny/vue-form";
|
|
11
|
-
import ke from "@opentiny/vue-form-item";
|
|
12
|
-
import Ke from "@opentiny/vue-popover";
|
|
13
|
-
import Ue from "@opentiny/vue-select";
|
|
14
|
-
import qe from "@opentiny/vue-option";
|
|
15
|
-
import { iconSearch as Ze, iconClose as Ye, iconHelpQuery as We } from "@opentiny/vue-icon";
|
|
16
|
-
import Ve from "@opentiny/vue-dropdown-item";
|
|
17
|
-
import Qe from "@opentiny/vue-checkbox";
|
|
18
|
-
import Xe from "@opentiny/vue-checkbox-group";
|
|
19
|
-
import Je from "@opentiny/vue-loading";
|
|
20
|
-
const et = (a, e, n, r = "0") => {
|
|
21
|
-
if (typeof a == "string" && typeof r == "string" && Te(e)) {
|
|
22
|
-
let o = a.length - e;
|
|
23
|
-
if (o > 0)
|
|
24
|
-
return n ? a.substr(0, e) : a.substr(o, e);
|
|
2
|
+
import { svg as de, defineComponent as J, $prefix as me, $props as ee, setup as fe } from "@opentiny/vue-common";
|
|
3
|
+
import { TinyDropdownItem as Ve, TinyFormItem as Ce, TinyCheckbox as Ge, TinyCheckboxGroup as Ke, TinyDatePicker as Te, TinyInput as Se, TinyButton as De, TinyLoading as Ue, TinyTag as Ze, TinyDropdown as qe, TinyDropdownMenu as Qe, TinyTooltip as Ye, TinyForm as We, TinyPopover as Xe, TinySelect as Je, TinyOption as et } from "@opentiny/vue";
|
|
4
|
+
const tt = (a, e, n, s = "0") => {
|
|
5
|
+
if (typeof a == "string" && typeof s == "string" && Me(e)) {
|
|
6
|
+
let r = a.length - e;
|
|
7
|
+
if (r > 0)
|
|
8
|
+
return n ? a.substr(0, e) : a.substr(r, e);
|
|
25
9
|
{
|
|
26
10
|
const t = [];
|
|
27
|
-
for (
|
|
28
|
-
t.push(
|
|
11
|
+
for (r = Math.abs(r) / s.length; r > 0; r--)
|
|
12
|
+
t.push(s);
|
|
29
13
|
const m = t.join("");
|
|
30
14
|
return n ? a + m : m + a;
|
|
31
15
|
}
|
|
32
16
|
}
|
|
33
|
-
},
|
|
34
|
-
|
|
17
|
+
}, at = Object.prototype.toString, nt = Object.prototype.hasOwnProperty, st = nt.toString;
|
|
18
|
+
st.call(Object);
|
|
35
19
|
const rt = {
|
|
36
20
|
"[object Error]": "error",
|
|
37
21
|
"[object Object]": "object",
|
|
@@ -43,13 +27,13 @@ const rt = {
|
|
|
43
27
|
"[object String]": "string",
|
|
44
28
|
"[object Number]": "number",
|
|
45
29
|
"[object Boolean]": "boolean"
|
|
46
|
-
}, ot = (a) => a == null,
|
|
30
|
+
}, ot = (a) => a == null, lt = (a) => ot(a) ? String(a) : rt[at.call(a)] || "object", Me = (a) => typeof a == "number" && isFinite(a), it = (a) => lt(a) === "date", $e = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], ct = new RegExp(
|
|
47
31
|
"^(\\d{4})(/|-)(((0)?[1-9])|(1[0-2]))((/|-)(((0)?[1-9])|([1-2][0-9])|(3[0-1])))?( ((0)?[0-9]|1[0-9]|20|21|22|23):([0-5]?[0-9])((:([0-5]?[0-9]))?(.([0-9]{1,6}))?)?)?$"
|
|
48
|
-
),
|
|
32
|
+
), ut = new RegExp(
|
|
49
33
|
"^(((0)?[1-9])|(1[0-2]))(/|-)(((0)?[1-9])|([1-2][0-9])|(3[0-1]))?(/|-)?(\\d{4})( ((0)?[0-9]|1[0-9]|20|21|22|23):([0-5]?[0-9])((:([0-5]?[0-9]))?(.([0-9]{1,6}))?)?)?$"
|
|
50
34
|
), pt = new RegExp(
|
|
51
35
|
"^(\\d{4})-(((0)?[1-9])|(1[0-2]))-(((0)?[1-9])|([1-2][0-9])|(3[0-1]))T(((0)?[0-9]|1[0-9]|20|21|22|23):([0-5]?[0-9])((:([0-5]?[0-9]))?(.([0-9]{1,6}))?)?)?(Z|([+-])((0)?[0-9]|1[0-9]|20|21|22|23):?([0-5]?[0-9]))$"
|
|
52
|
-
),
|
|
36
|
+
), dt = {
|
|
53
37
|
"y{1,4}": /y{1,4}/,
|
|
54
38
|
"M{1,2}": /M{1,2}/,
|
|
55
39
|
"d{1,2}": /d{1,2}/,
|
|
@@ -67,68 +51,68 @@ const rt = {
|
|
|
67
51
|
MINUTE: 59,
|
|
68
52
|
SECOND: 59,
|
|
69
53
|
MILLISECOND: 999
|
|
70
|
-
},
|
|
54
|
+
}, mt = "-12:00,-11:00,-10:00,-09:30,-08:00,-07:00,-06:00,-05:00,-04:30,-04:00,-03:30,-02:00,-01:00", ft = "-00:00,+00:00,+01:00,+02:00,+03:00,+03:30,+04:00,+04:30,+05:00,+05:30,+05:45,+06:00", ht = "+06:30,+07:00,+08:00,+09:00,+10:00,+10:30,+11:00,+11:30,+12:00,+12:45,+13:00,+14:00", vt = [].concat(mt.split(","), ft.split(","), ht.split(",")), bt = (a) => {
|
|
71
55
|
const e = 0 - a.getTimezoneOffset() / 60;
|
|
72
56
|
let n;
|
|
73
57
|
return e === 0 ? n = "Z" : e > 0 ? n = "+" + (e > 10 ? e : "0" + e) + "00" : n = (e < -10 ? e : "-0" + -e) + "00", n;
|
|
74
|
-
},
|
|
75
|
-
let l =
|
|
76
|
-
if (
|
|
77
|
-
return new Date(a, e, n,
|
|
78
|
-
},
|
|
58
|
+
}, Ee = (a) => a % 400 === 0 || a % 4 === 0 && a % 100 !== 0, Le = (a) => a > z.MILLISECOND ? Number(String(a).substring(0, 3)) : a, he = ({ year: a, month: e, date: n, hours: s, minutes: r, seconds: t, milliseconds: m }) => {
|
|
59
|
+
let l = $e[e];
|
|
60
|
+
if (Ee(a) && e === 1 && (l += 1), n <= l)
|
|
61
|
+
return new Date(a, e, n, s, r, t, Le(m));
|
|
62
|
+
}, gt = (a) => {
|
|
79
63
|
if (a.length === 23) {
|
|
80
|
-
const e = Number(a[1]), n = a[3] - 1,
|
|
81
|
-
return
|
|
82
|
-
date:
|
|
64
|
+
const e = Number(a[1]), n = a[3] - 1, s = Number(a[9] || 1), r = a[15] || 0, t = a[17] || 0, m = a[20] || 0, l = a[22] || 0;
|
|
65
|
+
return he({
|
|
66
|
+
date: s,
|
|
83
67
|
year: e,
|
|
84
|
-
hours:
|
|
68
|
+
hours: r,
|
|
85
69
|
month: n,
|
|
86
70
|
seconds: m,
|
|
87
71
|
minutes: t,
|
|
88
72
|
milliseconds: l
|
|
89
73
|
});
|
|
90
74
|
}
|
|
91
|
-
},
|
|
75
|
+
}, _t = (a) => {
|
|
92
76
|
if (a.length === 22) {
|
|
93
|
-
const e = Number(a[12]), n = a[1] - 1,
|
|
94
|
-
return
|
|
77
|
+
const e = Number(a[12]), n = a[1] - 1, s = Number(a[6] || 1), r = a[14] || 0, t = a[16] || 0, m = a[19] || 0, l = a[21] || 0;
|
|
78
|
+
return he({
|
|
95
79
|
year: e,
|
|
96
80
|
month: n,
|
|
97
|
-
date:
|
|
98
|
-
hours:
|
|
81
|
+
date: s,
|
|
82
|
+
hours: r,
|
|
99
83
|
minutes: t,
|
|
100
84
|
seconds: m,
|
|
101
85
|
milliseconds: l
|
|
102
86
|
});
|
|
103
87
|
}
|
|
104
|
-
},
|
|
88
|
+
}, xt = (a) => {
|
|
105
89
|
if (a.length !== 25)
|
|
106
90
|
return;
|
|
107
|
-
const e = Number(a[1]), n = a[2] - 1,
|
|
108
|
-
let
|
|
109
|
-
const
|
|
110
|
-
let f =
|
|
111
|
-
if (
|
|
112
|
-
if (
|
|
113
|
-
c = t -
|
|
91
|
+
const e = Number(a[1]), n = a[2] - 1, s = Number(a[6]), r = new Date(e, n, s).getTimezoneOffset(), t = a[12] || 0, m = a[14] || 0, l = a[17] || 0, o = a[19] || 0;
|
|
92
|
+
let u = a[20];
|
|
93
|
+
const p = a[21], i = a[22] || 0, d = a[24] || 0;
|
|
94
|
+
let f = $e[n], c, v;
|
|
95
|
+
if (Ee(e) && n === 1 && (f += 1), s <= f) {
|
|
96
|
+
if (u === "Z")
|
|
97
|
+
c = t - r / 60, v = m;
|
|
114
98
|
else {
|
|
115
|
-
if (
|
|
99
|
+
if (u.includes(":") || (u = u.substr(0, 3) + ":" + u.substr(3)), !vt.includes(u))
|
|
116
100
|
return;
|
|
117
|
-
c =
|
|
101
|
+
c = p === "+" ? t - i - r / 60 : Number(t) + Number(i) - r / 60, v = p === "+" ? m - d : Number(m) + Number(d);
|
|
118
102
|
}
|
|
119
|
-
return new Date(e, n,
|
|
103
|
+
return new Date(e, n, s, c, v, l, Le(o));
|
|
120
104
|
}
|
|
121
|
-
},
|
|
122
|
-
[it, bt],
|
|
105
|
+
}, oe = [
|
|
123
106
|
[ct, gt],
|
|
124
|
-
[
|
|
107
|
+
[ut, _t],
|
|
108
|
+
[pt, xt]
|
|
125
109
|
], yt = (a) => {
|
|
126
|
-
for (let e = 0, n =
|
|
127
|
-
const
|
|
128
|
-
if (
|
|
129
|
-
return
|
|
110
|
+
for (let e = 0, n = oe.length; e < n; e++) {
|
|
111
|
+
const s = oe[e][0].exec(a);
|
|
112
|
+
if (s && s.length > 0)
|
|
113
|
+
return oe[e][1](s);
|
|
130
114
|
}
|
|
131
|
-
},
|
|
115
|
+
}, wt = (a, e, n) => {
|
|
132
116
|
if (n)
|
|
133
117
|
switch (n) {
|
|
134
118
|
case "yyyy":
|
|
@@ -161,56 +145,56 @@ const rt = {
|
|
|
161
145
|
a[6] = e;
|
|
162
146
|
break;
|
|
163
147
|
}
|
|
164
|
-
},
|
|
148
|
+
}, It = (a, e) => {
|
|
165
149
|
const n = [0, -1, 0, 0, 0, 0];
|
|
166
150
|
if (a.length !== e.length)
|
|
167
151
|
return n;
|
|
168
|
-
let
|
|
152
|
+
let s = 0, r = 0;
|
|
169
153
|
for (let t = 0, m = a.length; t < m; t++) {
|
|
170
|
-
const l = a.substr(t, 1),
|
|
171
|
-
if (
|
|
172
|
-
let
|
|
173
|
-
if (
|
|
174
|
-
|
|
175
|
-
const i = e.indexOf(l,
|
|
176
|
-
|
|
154
|
+
const l = a.substr(t, 1), o = isNaN(Number(l)) || (l == null ? void 0 : l.trim()) === "";
|
|
155
|
+
if (o && l === e.substr(t, 1) || t === m - 1) {
|
|
156
|
+
let u, p;
|
|
157
|
+
if (o) {
|
|
158
|
+
u = a.substring(s, t), s = t + 1;
|
|
159
|
+
const i = e.indexOf(l, r);
|
|
160
|
+
p = e.substring(r, i === -1 ? e.length : i), r = i + 1;
|
|
177
161
|
} else
|
|
178
|
-
|
|
179
|
-
(
|
|
162
|
+
u = a.substring(s, m), p = e.substring(r, m);
|
|
163
|
+
(u.length === p.length || u) && wt(n, u, p);
|
|
180
164
|
}
|
|
181
165
|
}
|
|
182
166
|
return n;
|
|
183
|
-
}, U = (a, e, n) => isNaN(a) || a < e || a > n,
|
|
167
|
+
}, U = (a, e, n) => isNaN(a) || a < e || a > n, kt = ({ year: a, month: e, date: n, hours: s, minutes: r, seconds: t, milliseconds: m }) => U(a, 0, z.YEAR) || U(e, 0, z.MONTH) || U(n, 0, z.DATE) || U(s, 0, z.HOUR) || U(r, 0, z.MINUTE) || U(t, 0, z.SECOND) || U(m, 0, z.MILLISECOND), Vt = (a, e) => {
|
|
184
168
|
if (typeof e == "string") {
|
|
185
|
-
const n =
|
|
186
|
-
return
|
|
187
|
-
year:
|
|
188
|
-
month:
|
|
169
|
+
const n = It(a, e), s = Number(n[0]), r = Number(n[1]), t = Number(n[2] || 1), m = Number(n[3] || 0), l = Number(n[4] || 0), o = Number(n[5] || 0), u = Number(n[6] || 0);
|
|
170
|
+
return kt({
|
|
171
|
+
year: s,
|
|
172
|
+
month: r,
|
|
189
173
|
date: t,
|
|
190
174
|
hours: m,
|
|
191
175
|
minutes: l,
|
|
192
|
-
seconds:
|
|
193
|
-
milliseconds:
|
|
194
|
-
}) ? void 0 :
|
|
195
|
-
year:
|
|
176
|
+
seconds: o,
|
|
177
|
+
milliseconds: u
|
|
178
|
+
}) ? void 0 : he({
|
|
179
|
+
year: s,
|
|
196
180
|
date: t,
|
|
197
|
-
month:
|
|
181
|
+
month: r,
|
|
198
182
|
minutes: l,
|
|
199
183
|
hours: m,
|
|
200
|
-
milliseconds:
|
|
201
|
-
seconds:
|
|
184
|
+
milliseconds: u,
|
|
185
|
+
seconds: o
|
|
202
186
|
});
|
|
203
187
|
} else
|
|
204
188
|
return yt(a);
|
|
205
|
-
},
|
|
206
|
-
let
|
|
207
|
-
if (
|
|
208
|
-
const
|
|
209
|
-
return
|
|
189
|
+
}, Ne = (a, e, n) => {
|
|
190
|
+
let s;
|
|
191
|
+
if (Me(a) ? s = new Date(a) : typeof a == "string" && (s = Vt(a, e)), n) {
|
|
192
|
+
const r = n && Ne(n) || new Date(1, 1, 1, 0, 0, 0);
|
|
193
|
+
return s && s < r ? r : s;
|
|
210
194
|
}
|
|
211
|
-
return
|
|
195
|
+
return s;
|
|
212
196
|
}, ie = function(a, e = "yyyy/MM/dd hh:mm:ss") {
|
|
213
|
-
if (
|
|
197
|
+
if (it(a)) {
|
|
214
198
|
if (typeof e == "string") {
|
|
215
199
|
const n = {
|
|
216
200
|
"y{1,4}": a.getFullYear(),
|
|
@@ -221,46 +205,46 @@ const rt = {
|
|
|
221
205
|
"m{1,2}": a.getMinutes(),
|
|
222
206
|
"s{1,2}": a.getSeconds(),
|
|
223
207
|
"S{1,3}": a.getMilliseconds(),
|
|
224
|
-
"Z{1,1}":
|
|
208
|
+
"Z{1,1}": bt(a)
|
|
225
209
|
};
|
|
226
|
-
return Object.keys(n).forEach((
|
|
227
|
-
const
|
|
228
|
-
|
|
210
|
+
return Object.keys(n).forEach((s) => {
|
|
211
|
+
const r = e.match(dt[s]);
|
|
212
|
+
s && r && r.length && (e = e.replace(r[0], s === "Z{1,1}" ? n[s] : tt(n[s].toString(), r[0].length)));
|
|
229
213
|
}), e;
|
|
230
214
|
}
|
|
231
215
|
} else if (typeof a == "string" && arguments.length >= 2) {
|
|
232
216
|
let n = e;
|
|
233
217
|
arguments.length === 2 ? e = void 0 : n = arguments[2];
|
|
234
|
-
const
|
|
235
|
-
return
|
|
218
|
+
const s = Ne(a, e);
|
|
219
|
+
return s ? ie(s, n) : "";
|
|
236
220
|
}
|
|
237
221
|
}, k = (a, e = !0) => {
|
|
238
222
|
e ? a.visibleTimer = setTimeout(() => {
|
|
239
223
|
a.visible = !0;
|
|
240
224
|
}, 0) : (clearTimeout(a.visibleTimer), a.visibleTimer = null, a.visible = !1);
|
|
241
|
-
},
|
|
225
|
+
}, W = (a, e = !0) => {
|
|
242
226
|
if (!a.instance)
|
|
243
227
|
return;
|
|
244
228
|
a.popoverVisible = e;
|
|
245
229
|
const { dropdownRef: n } = a.instance;
|
|
246
230
|
e && n.state.visible && (clearTimeout(Number(n.state.timeout)), n.state.timeout = null, n.state.visible = !1);
|
|
247
|
-
},
|
|
231
|
+
}, Ct = (a, e = 200) => {
|
|
248
232
|
let n = null;
|
|
249
|
-
const
|
|
233
|
+
const s = function(...r) {
|
|
250
234
|
n && clearTimeout(n), n = setTimeout(() => {
|
|
251
|
-
a.apply(this,
|
|
235
|
+
a.apply(this, r), n = null;
|
|
252
236
|
}, e);
|
|
253
237
|
};
|
|
254
|
-
return
|
|
238
|
+
return s.cancel = () => {
|
|
255
239
|
n && (clearTimeout(n), n = null);
|
|
256
|
-
},
|
|
257
|
-
}, A = (a) => parseFloat(a).toString() !== "NaN",
|
|
240
|
+
}, s;
|
|
241
|
+
}, A = (a) => parseFloat(a).toString() !== "NaN", H = (a) => {
|
|
258
242
|
const e = Array.isArray(a) ? [] : {};
|
|
259
243
|
if (a && typeof a == "object") {
|
|
260
244
|
const n = Object.keys(a);
|
|
261
245
|
if (n.length)
|
|
262
|
-
n.forEach((
|
|
263
|
-
a[
|
|
246
|
+
n.forEach((s) => {
|
|
247
|
+
a[s] && typeof a[s] == "object" ? e[s] = H(a[s]) : e[s] = a[s];
|
|
264
248
|
});
|
|
265
249
|
else
|
|
266
250
|
return a;
|
|
@@ -268,206 +252,206 @@ const rt = {
|
|
|
268
252
|
return e;
|
|
269
253
|
}, te = (a, e = ["mergeTag", "options", "idMapKey"]) => {
|
|
270
254
|
const n = { ...a };
|
|
271
|
-
return e.forEach((
|
|
272
|
-
delete n[
|
|
255
|
+
return e.forEach((s) => {
|
|
256
|
+
delete n[s];
|
|
273
257
|
}), n;
|
|
274
258
|
}, O = (a, e, n = "") => {
|
|
275
|
-
const { valueMap:
|
|
276
|
-
return
|
|
259
|
+
const { valueMap: s, prevItem: r } = a, t = (r.label || n) + e;
|
|
260
|
+
return s.has(t);
|
|
277
261
|
}, ae = (a) => {
|
|
278
262
|
a.propItem = {}, a.inputValue = "";
|
|
279
|
-
}, R = ({ emit: a, state: e, nextTick: n, ...
|
|
280
|
-
|
|
281
|
-
const { tagList:
|
|
282
|
-
if (
|
|
263
|
+
}, R = ({ emit: a, state: e, nextTick: n, ...s }) => {
|
|
264
|
+
W(e, !1);
|
|
265
|
+
const { tagList: r = null, index: t = -1, newTag: m = null, newValue: l = null, oldValue: o = null, isEdit: u } = s;
|
|
266
|
+
if (u || ae(e), !r && t === -1 && !l)
|
|
283
267
|
return;
|
|
284
|
-
const
|
|
268
|
+
const p = o || H(e.innerModelValue);
|
|
285
269
|
let i = [];
|
|
286
|
-
l ? i = [...l] : t !== -1 ? (i = [...e.innerModelValue], m ? i.splice(t, 1, m) : i.splice(t, 1)) : i = [...e.innerModelValue, ...
|
|
287
|
-
},
|
|
288
|
-
const
|
|
289
|
-
return n && n[
|
|
270
|
+
l ? i = [...l] : t !== -1 ? (i = [...e.innerModelValue], m ? i.splice(t, 1, m) : i.splice(t, 1)) : i = [...e.innerModelValue, ...r], e.innerModelValue = i, a("update:modelValue", H(i)), a("change", H(i), p);
|
|
271
|
+
}, j = (a) => a, G = (a, e, n) => {
|
|
272
|
+
const s = e.idMapKey || a.idMapKey;
|
|
273
|
+
return n && n[s] !== void 0 ? { [s]: n[s] } : null;
|
|
290
274
|
};
|
|
291
|
-
function Tt({ props: a, state: e, emit: n, nextTick:
|
|
292
|
-
let
|
|
293
|
-
const t = (
|
|
294
|
-
if (
|
|
295
|
-
const
|
|
296
|
-
if (
|
|
297
|
-
const i =
|
|
275
|
+
function Tt({ props: a, state: e, emit: n, nextTick: s }) {
|
|
276
|
+
let r = H(e.inputValue);
|
|
277
|
+
const t = (u) => {
|
|
278
|
+
if (u) {
|
|
279
|
+
const p = e.recordItems.find((i) => i.label === u.label);
|
|
280
|
+
if (p && p.options) {
|
|
281
|
+
const i = p.options.find((d) => d.label === u.value);
|
|
298
282
|
i && (i.isChecked = !1);
|
|
299
283
|
}
|
|
300
284
|
}
|
|
301
285
|
};
|
|
302
286
|
return {
|
|
303
|
-
deleteTag: (
|
|
304
|
-
k(e, !1), t(
|
|
305
|
-
const
|
|
306
|
-
R({ emit: n, state: e, nextTick:
|
|
287
|
+
deleteTag: (u) => {
|
|
288
|
+
k(e, !1), t(u);
|
|
289
|
+
const p = a.modelValue.filter((i) => i !== u);
|
|
290
|
+
R({ emit: n, state: e, nextTick: s, newValue: p });
|
|
307
291
|
},
|
|
308
292
|
clearTag: () => {
|
|
309
|
-
k(e, !1), a.modelValue.forEach((
|
|
293
|
+
k(e, !1), a.modelValue.forEach((u) => t(u)), e.propItem = {}, e.inputValue = "", R({ emit: n, state: e, nextTick: s, newValue: [] }), n("clear");
|
|
310
294
|
},
|
|
311
295
|
backspaceDeleteTag: () => {
|
|
312
|
-
var
|
|
296
|
+
var u, p, i;
|
|
313
297
|
if (!e.inputValue) {
|
|
314
298
|
if (e.propItem.label) {
|
|
315
299
|
e.propItem = {};
|
|
316
300
|
return;
|
|
317
301
|
}
|
|
318
|
-
if (
|
|
302
|
+
if (r === "" && e.inputValue === "") {
|
|
319
303
|
k(e, !1);
|
|
320
304
|
const d = a.modelValue.length - 1;
|
|
321
305
|
t(a.modelValue[d]);
|
|
322
306
|
const f = e.innerModelValue.slice(0, a.modelValue.length - 1);
|
|
323
|
-
R({ emit: n, state: e, nextTick:
|
|
307
|
+
R({ emit: n, state: e, nextTick: s, newValue: f });
|
|
324
308
|
}
|
|
325
|
-
|
|
309
|
+
r = e.inputValue, (i = (p = (u = e == null ? void 0 : e.instance) == null ? void 0 : u.refs) == null ? void 0 : p.inputRef) != null && i.$el && e.instance.refs.inputRef.$el.click();
|
|
326
310
|
}
|
|
327
311
|
}
|
|
328
312
|
};
|
|
329
313
|
}
|
|
330
|
-
const
|
|
331
|
-
const { prevItem:
|
|
332
|
-
let l = null,
|
|
333
|
-
if (await a.$refs.formRef.validateField(["inputEditValue"], (
|
|
334
|
-
|
|
335
|
-
}),
|
|
336
|
-
let
|
|
337
|
-
const
|
|
338
|
-
let i =
|
|
314
|
+
const St = async (a, e, n) => {
|
|
315
|
+
const { prevItem: s, inputEditValue: r } = e, { operators: t } = s, m = te(s);
|
|
316
|
+
let l = null, o = !0;
|
|
317
|
+
if (await a.$refs.formRef.validateField(["inputEditValue"], (u) => {
|
|
318
|
+
u && (o = !1);
|
|
319
|
+
}), o) {
|
|
320
|
+
let u = null;
|
|
321
|
+
const p = e.operatorValue && t ? { operator: e.operatorValue } : null;
|
|
322
|
+
let i = r;
|
|
339
323
|
const d = {};
|
|
340
|
-
if (Array.isArray(
|
|
341
|
-
d.options = [], i = "",
|
|
342
|
-
const c = e.currentEditValue.find((h) => h.label === f),
|
|
343
|
-
if (i = i ? `${i} | ${
|
|
344
|
-
const h = G(n,
|
|
345
|
-
d.options.push({ label:
|
|
324
|
+
if (Array.isArray(r))
|
|
325
|
+
d.options = [], i = "", r.forEach((f) => {
|
|
326
|
+
const c = e.currentEditValue.find((h) => h.label === f), v = (c == null ? void 0 : c.label) || f;
|
|
327
|
+
if (i = i ? `${i} | ${v}` : v, c) {
|
|
328
|
+
const h = G(n, s, c);
|
|
329
|
+
d.options.push({ label: v, ...h });
|
|
346
330
|
} else
|
|
347
|
-
d.options.push({ label:
|
|
331
|
+
d.options.push({ label: v });
|
|
348
332
|
});
|
|
349
333
|
else if (Array.isArray(e.currentEditValue)) {
|
|
350
334
|
const f = e.currentEditValue.find((c) => c.label === i);
|
|
351
|
-
|
|
335
|
+
u = G(n, s, f);
|
|
352
336
|
}
|
|
353
|
-
l =
|
|
337
|
+
l = j({ ...m, label: e.selectValue, ...p, value: i, ...u, ...d });
|
|
354
338
|
}
|
|
355
339
|
return l;
|
|
356
|
-
},
|
|
357
|
-
const { prevItem:
|
|
358
|
-
let
|
|
359
|
-
if (await a.$refs.formRef.validateField(
|
|
360
|
-
i && (
|
|
361
|
-
}),
|
|
362
|
-
const { field: i, label: d, unit: f, type: c, operators:
|
|
363
|
-
let
|
|
364
|
-
m && l ?
|
|
365
|
-
const
|
|
366
|
-
|
|
340
|
+
}, Re = async (a, e, n) => {
|
|
341
|
+
const { prevItem: s } = e, r = `min${s.field}`, t = `max${s.field}`, m = e[r], l = e[t], o = [r, t];
|
|
342
|
+
let u = !0, p = null;
|
|
343
|
+
if (await a.$refs.formRef.validateField(o, (i) => {
|
|
344
|
+
i && (u = !1);
|
|
345
|
+
}), u) {
|
|
346
|
+
const { field: i, label: d, unit: f, type: c, operators: v } = s, h = f ? `${d}(${f})` : d;
|
|
347
|
+
let b = "";
|
|
348
|
+
m && l ? b = `${m}-${l}` : b = m ? `≥${m}` : `≤${l}`;
|
|
349
|
+
const x = G(n, s, s), T = e.operatorValue && v ? { operator: e.operatorValue } : null;
|
|
350
|
+
p = j({ type: c, field: i, label: h, value: b, ...x, start: m, end: l, ...T });
|
|
367
351
|
}
|
|
368
|
-
return
|
|
369
|
-
}, ce = async (a, e, n,
|
|
370
|
-
const { prevItem:
|
|
371
|
-
let
|
|
372
|
-
if (
|
|
352
|
+
return p;
|
|
353
|
+
}, ce = async (a, e, n, s) => {
|
|
354
|
+
const { prevItem: r, startDate: t, endDate: m, startDateTime: l, endDateTime: o } = e;
|
|
355
|
+
let u = null, p = null, i = !0, d = null, f = null;
|
|
356
|
+
if (s ? (u = l, p = o, f = ["startDateTime", "endDateTime"]) : (u = t, p = m, f = ["startDate", "endDate"]), await a.$refs.formRef.validateField(f, (c) => {
|
|
373
357
|
c && (i = !1);
|
|
374
358
|
}), i) {
|
|
375
|
-
const { operators: c } =
|
|
359
|
+
const { operators: c } = r, v = te(r);
|
|
376
360
|
let h = "";
|
|
377
|
-
if (
|
|
378
|
-
if (
|
|
361
|
+
if (u && p) {
|
|
362
|
+
if (u > p)
|
|
379
363
|
return;
|
|
380
|
-
|
|
364
|
+
u === p ? h = u : h = `${u}-${p}`;
|
|
381
365
|
} else
|
|
382
|
-
h =
|
|
383
|
-
const
|
|
384
|
-
d =
|
|
366
|
+
h = u ? `≥${u}` : `≤${p}`;
|
|
367
|
+
const b = G(n, r, r), x = e.operatorValue && c ? { operator: e.operatorValue } : null;
|
|
368
|
+
d = j({ ...v, value: h, start: u, end: p, ...b, ...x });
|
|
385
369
|
}
|
|
386
370
|
return d;
|
|
387
|
-
},
|
|
388
|
-
const { prevItem:
|
|
389
|
-
(a.curMinNumVar !==
|
|
390
|
-
const { curMinNumVar: i, curMaxNumVar: d } = a, f = A(l), c = A(
|
|
371
|
+
}, Pe = (a, e, n) => {
|
|
372
|
+
const { prevItem: s } = a, { field: r, start: t, end: m, min: l = s.min, max: o = s.max } = e, u = `min${r}`, p = `max${r}`;
|
|
373
|
+
(a.curMinNumVar !== u || a.curMaxNumVar !== p) && (delete a[a.curMinNumVar], delete a[a.curMaxNumVar], delete a.formRules[a.curMinNumVar], delete a.formRules[a.curMaxNumVar], a.curMinNumVar = u, a.curMaxNumVar = p), a[a.curMinNumVar] = t, a[a.curMaxNumVar] = m;
|
|
374
|
+
const { curMinNumVar: i, curMaxNumVar: d } = a, f = A(l), c = A(o);
|
|
391
375
|
f || c ? (a.formRules[i] = {
|
|
392
|
-
validator: (
|
|
393
|
-
const
|
|
394
|
-
!
|
|
376
|
+
validator: (v, h, b) => {
|
|
377
|
+
const x = A(h);
|
|
378
|
+
!x && A(a[d]) || x && (f && !c && h >= l || !f && c && h <= o || h >= l && h <= o) ? b() : (a.numberShowMessage = !!(h || a[d]), b(new Error(n("tvp.tvpSearchbox.rangeMinErr", [l, o]))));
|
|
395
379
|
}
|
|
396
380
|
}, a.formRules[d] = {
|
|
397
|
-
validator: (
|
|
398
|
-
const
|
|
399
|
-
!_ &&
|
|
381
|
+
validator: (v, h, b) => {
|
|
382
|
+
const x = A(a[i]), T = x && l < a[i] ? Number(a[i]) : l, g = A(T), _ = A(h);
|
|
383
|
+
!_ && x || _ && (g && !c && h >= T || !g && c && h <= o || h >= T && h <= o) ? b() : b(!_ && !x ? new Error(n("tvp.tvpSearchbox.rangeNumberTitle")) : new Error(n("tvp.tvpSearchbox.rangeMaxErr")));
|
|
400
384
|
}
|
|
401
385
|
}) : a.formRules[d] = {
|
|
402
|
-
validator: (
|
|
403
|
-
const
|
|
404
|
-
|
|
386
|
+
validator: (v, h, b) => {
|
|
387
|
+
const x = a[i], T = A(h), g = A(x);
|
|
388
|
+
T && !g || !T && g || T && g && h >= Number(x) ? b() : b(!T && !g ? new Error(n("tvp.tvpSearchbox.rangeNumberTitle")) : new Error(n("tvp.tvpSearchbox.rangeMaxErr")));
|
|
405
389
|
}
|
|
406
390
|
};
|
|
407
391
|
};
|
|
408
|
-
function
|
|
409
|
-
const
|
|
410
|
-
var
|
|
411
|
-
const { start: _, end: I, type:
|
|
412
|
-
if (n.backupList = g.options,
|
|
413
|
-
|
|
414
|
-
else if (
|
|
392
|
+
function Dt({ props: a, emit: e, state: n, t: s, format: r, nextTick: t, vm: m, cancelHandleInput: l }) {
|
|
393
|
+
const o = m || n.instance, u = (g) => {
|
|
394
|
+
var C, w, S;
|
|
395
|
+
const { start: _, end: I, type: y } = g;
|
|
396
|
+
if (n.backupList = g.options, y === "numRange")
|
|
397
|
+
Pe(n, g, s);
|
|
398
|
+
else if (y === "dateRange") {
|
|
415
399
|
const { dateRangeFormat: V } = n;
|
|
416
400
|
if (!n.startDate && _) {
|
|
417
|
-
const D =
|
|
401
|
+
const D = r(_, V);
|
|
418
402
|
n.startDate = n.endDate < D ? null : D;
|
|
419
403
|
}
|
|
420
404
|
if (!n.endDate && I) {
|
|
421
|
-
const D =
|
|
405
|
+
const D = r(I, V);
|
|
422
406
|
n.endDate = D < n.startDate ? null : D;
|
|
423
407
|
}
|
|
424
|
-
} else if (
|
|
408
|
+
} else if (y === "datetimeRange") {
|
|
425
409
|
const { datetimeRangeFormat: V } = n;
|
|
426
410
|
if (!n.startDateTime && _) {
|
|
427
|
-
const D =
|
|
411
|
+
const D = r(_, V);
|
|
428
412
|
n.startDateTime = n.endDateTime < D ? null : D;
|
|
429
413
|
}
|
|
430
414
|
if (!n.endDateTime && I) {
|
|
431
|
-
const D =
|
|
415
|
+
const D = r(I, V);
|
|
432
416
|
n.endDateTime = D < n.startDateTime ? null : D;
|
|
433
417
|
}
|
|
434
418
|
} else
|
|
435
|
-
n.backupList &&
|
|
419
|
+
n.backupList && y === "checkbox" && (n.filterList = n.backupList, n.checkboxGroup = [], (C = n.backupList) == null || C.forEach((V) => {
|
|
436
420
|
O(n, V.label) && n.checkboxGroup.push(`${g.label}${V.label}`), V.isFilter = !1;
|
|
437
421
|
}));
|
|
438
|
-
|
|
422
|
+
y !== "checkbox" && ((w = n.backupList) != null && w.length) && ((S = n.backupList) == null || S.forEach((V) => {
|
|
439
423
|
V.isFilter = !1, V.isChecked = O(n, V.label);
|
|
440
|
-
})), n.currentOperators = null, !n.backupList && !["dateRange", "datetimeRange", "numRange", "custom"].includes(
|
|
441
|
-
},
|
|
424
|
+
})), n.currentOperators = null, !n.backupList && !["dateRange", "datetimeRange", "numRange", "custom"].includes(y) ? k(n, !1) : k(n);
|
|
425
|
+
}, p = (g) => {
|
|
442
426
|
var w;
|
|
443
427
|
const { field: _, label: I } = g;
|
|
444
428
|
n.propItem = { ...n.propItem, label: I }, e("first-level-select", _);
|
|
445
|
-
const
|
|
429
|
+
const y = (w = o.$refs) == null ? void 0 : w.inputRef;
|
|
446
430
|
n.prevItem = g, n.backupPrevItem = g;
|
|
447
|
-
const { operators:
|
|
448
|
-
|
|
431
|
+
const { operators: C } = g;
|
|
432
|
+
C != null && C.length ? (n.operatorValue = "", n.currentOperators = C, k(n)) : (n.operatorValue = ":", u(g)), n.inputValue = "", y.focus();
|
|
449
433
|
}, i = (g) => {
|
|
450
|
-
n.operatorValue = g,
|
|
451
|
-
}, d = (g, _, I,
|
|
452
|
-
const { replace:
|
|
434
|
+
n.operatorValue = g, u(n.prevItem);
|
|
435
|
+
}, d = (g, _, I, y) => {
|
|
436
|
+
const { replace: C, operators: w, mergeTag: S } = g, V = te(g), { indexMap: D } = n, M = D.get(I), $ = G(a, g, _), B = n.operatorValue && w ? { operator: n.operatorValue } : null;
|
|
453
437
|
let P = null;
|
|
454
438
|
if (S) {
|
|
455
|
-
const K = { label:
|
|
439
|
+
const K = { label: y, ...$ };
|
|
456
440
|
if (M >= 0) {
|
|
457
|
-
const ne = `${n.innerModelValue[M].value} | ${
|
|
458
|
-
P =
|
|
441
|
+
const ne = `${n.innerModelValue[M].value} | ${y}`, se = [...n.innerModelValue[M].options, K];
|
|
442
|
+
P = j({ ...n.innerModelValue[M], value: ne, options: se });
|
|
459
443
|
} else
|
|
460
|
-
P =
|
|
444
|
+
P = j({ ...V, label: I, value: y, options: [K] });
|
|
461
445
|
} else
|
|
462
|
-
P =
|
|
463
|
-
if (O(n,
|
|
446
|
+
P = j({ ...V, label: I, value: y, ...$, ...B });
|
|
447
|
+
if (O(n, y, I)) {
|
|
464
448
|
ae(n);
|
|
465
449
|
return;
|
|
466
450
|
}
|
|
467
451
|
k(n, !1);
|
|
468
|
-
const N =
|
|
452
|
+
const N = H(n.innerModelValue);
|
|
469
453
|
let F = [];
|
|
470
|
-
if ((
|
|
454
|
+
if ((C || S) && M >= 0) {
|
|
471
455
|
const K = [...n.innerModelValue];
|
|
472
456
|
K.splice(M, 1), F = [...K, P];
|
|
473
457
|
} else
|
|
@@ -475,50 +459,50 @@ function St({ props: a, emit: e, state: n, t: r, format: o, nextTick: t, vm: m,
|
|
|
475
459
|
R({ emit: e, state: n, nextTick: t, newValue: F, oldValue: N });
|
|
476
460
|
}, f = (g) => {
|
|
477
461
|
var _;
|
|
478
|
-
(_ = n.propItem) != null && _.label ? c({ label: g }) :
|
|
462
|
+
(_ = n.propItem) != null && _.label ? c({ label: g }) : x();
|
|
479
463
|
}, c = (g, _ = !1) => {
|
|
480
464
|
var w;
|
|
481
465
|
k(n, !1), _ && (n.prevItem = g, n.backupPrevItem = g);
|
|
482
|
-
const { prevItem: I } = n,
|
|
483
|
-
if (!O(n,
|
|
466
|
+
const { prevItem: I } = n, y = g.value || g.label, C = (w = o.$refs) == null ? void 0 : w.inputRef;
|
|
467
|
+
if (!O(n, y)) {
|
|
484
468
|
const S = n.propItem.label || g.label;
|
|
485
|
-
d(I, g, S,
|
|
469
|
+
d(I, g, S, y);
|
|
486
470
|
}
|
|
487
|
-
|
|
488
|
-
},
|
|
471
|
+
C.focus();
|
|
472
|
+
}, v = (g, _) => {
|
|
489
473
|
if (g.label) {
|
|
490
474
|
if (e("second-level-enter", _), !_.options || !_.options.length)
|
|
491
475
|
return;
|
|
492
476
|
const I = _.options[0];
|
|
493
477
|
if (!I)
|
|
494
478
|
return;
|
|
495
|
-
if (!a.modelValue.find((
|
|
496
|
-
const
|
|
497
|
-
d(_, I,
|
|
479
|
+
if (!a.modelValue.find((C) => C.value === I.label)) {
|
|
480
|
+
const C = _.label, w = I.label;
|
|
481
|
+
d(_, I, C, w);
|
|
498
482
|
return;
|
|
499
483
|
}
|
|
500
484
|
} else
|
|
501
485
|
e("search", n.innerModelValue);
|
|
502
486
|
}, h = (g, _, I) => {
|
|
503
|
-
var
|
|
504
|
-
const
|
|
505
|
-
d(g,
|
|
506
|
-
},
|
|
507
|
-
var
|
|
487
|
+
var C;
|
|
488
|
+
const y = (C = n.backupList) == null ? void 0 : C.find((w) => w.label === I);
|
|
489
|
+
d(g, y, _.label, I);
|
|
490
|
+
}, b = (g, _, I) => {
|
|
491
|
+
var y, C;
|
|
508
492
|
if (_.label) {
|
|
509
493
|
const { regexp: w, replace: S, type: V, mergeTag: D } = I, M = V !== "checkbox" && S || V === "checkbox" && D ? [g] : g.split(a.splitInputValue);
|
|
510
494
|
if (w)
|
|
511
|
-
for (const
|
|
512
|
-
w.test(
|
|
495
|
+
for (const $ of M)
|
|
496
|
+
w.test($) && h(I, _, $);
|
|
513
497
|
else
|
|
514
|
-
for (const
|
|
515
|
-
h(I, _,
|
|
498
|
+
for (const $ of M)
|
|
499
|
+
h(I, _, $);
|
|
516
500
|
} else {
|
|
517
501
|
const { items: w, defaultField: S } = a, V = w.find((N) => {
|
|
518
502
|
const { regexp: F } = N;
|
|
519
503
|
return F && F.test(n.inputValue);
|
|
520
|
-
}) || (S ? w.find((N) => N.field === S) : n.allTypeAttri), { replace: D, type: M, mergeTag:
|
|
521
|
-
(
|
|
504
|
+
}) || (S ? w.find((N) => N.field === S) : n.allTypeAttri), { replace: D, type: M, mergeTag: $ } = V, B = M !== "checkbox" && D || M === "checkbox" && $ ? [g] : g.split(a.splitInputValue);
|
|
505
|
+
(y = V == null ? void 0 : V.options) != null && y.length && (n.backupList = [...V.options], (C = n.backupList) == null || C.forEach((N) => {
|
|
522
506
|
const F = N.value || N.label;
|
|
523
507
|
B.includes(F) && (N.isChecked = !0);
|
|
524
508
|
}));
|
|
@@ -526,40 +510,40 @@ function St({ props: a, emit: e, state: n, t: r, format: o, nextTick: t, vm: m,
|
|
|
526
510
|
for (const N of B)
|
|
527
511
|
d(V, {}, P, N);
|
|
528
512
|
}
|
|
529
|
-
},
|
|
513
|
+
}, x = () => {
|
|
530
514
|
const { inputValue: g, propItem: _, prevItem: I } = n;
|
|
531
515
|
if (l && l(), k(n, !1), !g)
|
|
532
|
-
|
|
516
|
+
v(_, I);
|
|
533
517
|
else {
|
|
534
|
-
const { maxlength:
|
|
535
|
-
if (
|
|
536
|
-
e("exceed",
|
|
518
|
+
const { maxlength: y } = a;
|
|
519
|
+
if (y && y < g.length) {
|
|
520
|
+
e("exceed", y);
|
|
537
521
|
return;
|
|
538
522
|
}
|
|
539
|
-
|
|
523
|
+
b(g, _, I);
|
|
540
524
|
}
|
|
541
525
|
};
|
|
542
|
-
return { selectPropItem:
|
|
526
|
+
return { selectPropItem: p, selectRadioItem: c, selectInputValue: f, createTag: x, helpClick: () => {
|
|
543
527
|
e("help");
|
|
544
528
|
}, setOperator: i };
|
|
545
529
|
}
|
|
546
|
-
const
|
|
530
|
+
const Mt = (a) => a.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), le = (a, e) => {
|
|
547
531
|
const n = [];
|
|
548
|
-
let
|
|
549
|
-
for (; (
|
|
550
|
-
const t =
|
|
551
|
-
t >
|
|
532
|
+
let s = 0, r;
|
|
533
|
+
for (; (r = a.exec(e)) !== null; ) {
|
|
534
|
+
const t = r.index, m = a.lastIndex;
|
|
535
|
+
t > s && n.push(e.slice(s, t)), n.push(e.slice(t, m)), s = m;
|
|
552
536
|
}
|
|
553
|
-
return
|
|
537
|
+
return s < e.length && n.push(e.slice(s)), n;
|
|
554
538
|
};
|
|
555
|
-
function
|
|
556
|
-
const
|
|
557
|
-
e.potentialOptions = await a.potentialOptions.getMatchList(
|
|
558
|
-
}, m =
|
|
559
|
-
var _, I,
|
|
560
|
-
const { recordItems: i, propItem: d } = e, f = typeof
|
|
561
|
-
if (
|
|
562
|
-
n("exceed",
|
|
539
|
+
function $t({ props: a, state: e, emit: n, nextTick: s }) {
|
|
540
|
+
const r = async (p) => {
|
|
541
|
+
e.potentialOptions = await a.potentialOptions.getMatchList(p), k(e, !0);
|
|
542
|
+
}, m = Ct((p) => {
|
|
543
|
+
var _, I, y, C;
|
|
544
|
+
const { recordItems: i, propItem: d } = e, f = typeof p == "string" ? p : p && p.target && typeof p.target.value == "string" ? p.target.value : e.inputValue || "", c = (_ = String(f)) == null ? void 0 : _.trim(), { maxlength: v } = a;
|
|
545
|
+
if (v && v < c.length) {
|
|
546
|
+
n("exceed", v);
|
|
563
547
|
return;
|
|
564
548
|
}
|
|
565
549
|
if (c.length === 0) {
|
|
@@ -569,211 +553,211 @@ function Mt({ props: a, state: e, emit: n, nextTick: r }) {
|
|
|
569
553
|
Object.keys(e.matchItems).forEach((w) => {
|
|
570
554
|
e.matchItems[w].attr = [], e.matchItems[w].attrValue = [];
|
|
571
555
|
});
|
|
572
|
-
const h =
|
|
573
|
-
if (
|
|
574
|
-
e.propItem = { ...e.propItem, label:
|
|
556
|
+
const h = Mt(c), b = new RegExp(h, "i"), x = d.label || !h ? null : i.find((w) => w.type === "map" && b.test(w.label));
|
|
557
|
+
if (x) {
|
|
558
|
+
e.propItem = { ...e.propItem, label: x.label }, e.inputValue = "", e.prevItem = x, e.backupPrevItem = x, e.backupList = x.options || [];
|
|
575
559
|
return;
|
|
576
560
|
}
|
|
577
|
-
e.filterList = (I = e.backupList) == null ? void 0 : I.filter((w) =>
|
|
578
|
-
const
|
|
561
|
+
e.filterList = (I = e.backupList) == null ? void 0 : I.filter((w) => b.test(w.label) ? (delete w.isFilter, O(e, w.label) && e.checkboxGroup.push(`${e.prevItem.label}${w.label}`), !0) : (w.isFilter = !0, !1));
|
|
562
|
+
const T = new RegExp(h, "ig"), g = c.toLowerCase();
|
|
579
563
|
if (e.propItem.label) {
|
|
580
|
-
(
|
|
564
|
+
(y = e.backupList) == null || y.forEach((w) => {
|
|
581
565
|
w.hightlighStr = g;
|
|
582
566
|
const S = w.label;
|
|
583
|
-
|
|
584
|
-
}), (
|
|
567
|
+
b.test(S) ? (w.match = le(T, S), w.isFilter = !1) : w.isFilter = !0;
|
|
568
|
+
}), (C = e.backupList) != null && C.length || c ? k(e) : k(e, !1);
|
|
585
569
|
return;
|
|
586
570
|
}
|
|
587
571
|
for (const w of i) {
|
|
588
572
|
const { options: S = [], groupKey: V = "0", ...D } = w, M = D.label;
|
|
589
|
-
if (
|
|
590
|
-
const
|
|
591
|
-
e.matchItems[V].attr.push({ ...w, match:
|
|
573
|
+
if (b.test(M)) {
|
|
574
|
+
const $ = le(T, M);
|
|
575
|
+
e.matchItems[V].attr.push({ ...w, match: $, hightlighStr: g });
|
|
592
576
|
}
|
|
593
|
-
for (const
|
|
594
|
-
const B = e.propItem.label ? M : `${M}:${
|
|
595
|
-
if (
|
|
596
|
-
const P = le(
|
|
577
|
+
for (const $ of S) {
|
|
578
|
+
const B = e.propItem.label ? M : `${M}:${$.label}`;
|
|
579
|
+
if (b.test(B)) {
|
|
580
|
+
const P = le(T, B);
|
|
597
581
|
e.matchItems[V].attrValue.push({
|
|
598
|
-
|
|
582
|
+
...$,
|
|
599
583
|
...D,
|
|
600
584
|
options: S,
|
|
601
585
|
hightlighStr: g,
|
|
602
|
-
value:
|
|
586
|
+
value: $.label,
|
|
603
587
|
match: P
|
|
604
588
|
});
|
|
605
589
|
}
|
|
606
590
|
}
|
|
607
591
|
}
|
|
608
|
-
h && a.potentialOptions && a.potentialOptions.getMatchList ?
|
|
592
|
+
h && a.potentialOptions && a.potentialOptions.getMatchList ? r(h) : k(e);
|
|
609
593
|
}, 500), l = () => {
|
|
610
594
|
m.cancel && m.cancel();
|
|
611
|
-
},
|
|
612
|
-
var
|
|
613
|
-
(
|
|
595
|
+
}, o = () => {
|
|
596
|
+
var p;
|
|
597
|
+
(p = e.backupList) == null || p.forEach((i) => i.isFilter && delete i.isFilter);
|
|
614
598
|
};
|
|
615
599
|
return {
|
|
616
600
|
handleInput: m,
|
|
617
|
-
selectFirstMap: (
|
|
618
|
-
var
|
|
619
|
-
const { options: d } =
|
|
601
|
+
selectFirstMap: (p, i) => {
|
|
602
|
+
var v;
|
|
603
|
+
const { options: d } = p, { prevItem: f, propItem: c } = e;
|
|
620
604
|
if (d)
|
|
621
|
-
k(e, !1), e.propItem = { ...e.propItem, value: `${
|
|
622
|
-
const
|
|
623
|
-
h.isChecked = O(e,
|
|
605
|
+
k(e, !1), e.propItem = { ...e.propItem, value: `${p.label}=` }, e.isShowTagKey = !1, e.inputValue = "", e.backupList = p.options || [], o(), (v = e.backupList) == null || v.forEach((h) => {
|
|
606
|
+
const b = c.value + h.label;
|
|
607
|
+
h.isChecked = O(e, b);
|
|
624
608
|
});
|
|
625
609
|
else {
|
|
626
|
-
if (
|
|
610
|
+
if (p.isChecked)
|
|
627
611
|
return;
|
|
628
|
-
k(e, !1), e.isShowTagKey = !0,
|
|
629
|
-
const { field: h, type:
|
|
630
|
-
R({ emit: n, state: e, nextTick:
|
|
612
|
+
k(e, !1), e.isShowTagKey = !0, o();
|
|
613
|
+
const { field: h, type: b } = f, x = c.value + p.label, T = G(a, f, p), _ = [j({ type: b, field: h, label: c.label, value: x, ...T })];
|
|
614
|
+
R({ emit: n, state: e, nextTick: s, tagList: _ });
|
|
631
615
|
}
|
|
632
616
|
i && k(e);
|
|
633
617
|
},
|
|
634
618
|
cancelHandleInput: l
|
|
635
619
|
};
|
|
636
620
|
}
|
|
637
|
-
function Et({ props: a, state: e, emit: n, nextTick:
|
|
621
|
+
function Et({ props: a, state: e, emit: n, nextTick: s }) {
|
|
638
622
|
return {
|
|
639
623
|
selectCheckbox: (t) => {
|
|
640
|
-
var
|
|
624
|
+
var p, i;
|
|
641
625
|
k(e, !1);
|
|
642
|
-
const { checkboxGroup: m, prevItem: l, propItem:
|
|
626
|
+
const { checkboxGroup: m, prevItem: l, propItem: o } = e, u = te(l);
|
|
643
627
|
if (t) {
|
|
644
|
-
const d = [], f =
|
|
628
|
+
const d = [], f = H(e.innerModelValue), { mergeTag: c, operators: v, label: h } = l;
|
|
645
629
|
if (c) {
|
|
646
|
-
let
|
|
647
|
-
const
|
|
648
|
-
if (g !== void 0 && e.innerModelValue.splice(g, 1), (
|
|
649
|
-
const { label: I } = _,
|
|
650
|
-
if (m.includes(
|
|
630
|
+
let b = "";
|
|
631
|
+
const x = [], { indexMap: T } = e, g = T.get(h);
|
|
632
|
+
if (g !== void 0 && e.innerModelValue.splice(g, 1), (p = e.backupList) == null || p.forEach((_) => {
|
|
633
|
+
const { label: I } = _, y = `${h}${I}`;
|
|
634
|
+
if (m.includes(y)) {
|
|
651
635
|
delete _.isFilter;
|
|
652
636
|
const w = G(a, l, _), S = { label: _.label, ...w };
|
|
653
|
-
|
|
637
|
+
b += b ? ` | ${I}` : I, x.push(S);
|
|
654
638
|
}
|
|
655
|
-
}),
|
|
656
|
-
const _ = { ...
|
|
639
|
+
}), x.length > 0) {
|
|
640
|
+
const _ = { ...u, value: b, options: x };
|
|
657
641
|
d.push(_);
|
|
658
642
|
}
|
|
659
643
|
} else {
|
|
660
|
-
const { valueMap:
|
|
661
|
-
if ((i = e.backupList) == null || i.forEach((
|
|
662
|
-
const { label: g } =
|
|
644
|
+
const { valueMap: b } = e, x = [];
|
|
645
|
+
if ((i = e.backupList) == null || i.forEach((T) => {
|
|
646
|
+
const { label: g } = T, _ = `${h}${g}`, I = m.includes(_);
|
|
663
647
|
if (I && !O(e, g)) {
|
|
664
|
-
const
|
|
665
|
-
d.push(w),
|
|
648
|
+
const y = G(a, l, T), C = e.operatorValue && v ? { operator: e.operatorValue } : null, w = j({ ...u, label: o.label, value: g, ...y, ...C });
|
|
649
|
+
d.push(w), T.isChecked = !0;
|
|
666
650
|
} else if (!I && O(e, g)) {
|
|
667
|
-
|
|
668
|
-
const
|
|
669
|
-
|
|
651
|
+
T.isChecked = !1;
|
|
652
|
+
const y = b.get(_);
|
|
653
|
+
x.push(y);
|
|
670
654
|
}
|
|
671
|
-
}),
|
|
672
|
-
const
|
|
673
|
-
R({ emit: n, state: e, nextTick:
|
|
655
|
+
}), x.length) {
|
|
656
|
+
const T = e.innerModelValue.filter((g, _) => g && !x.includes(_));
|
|
657
|
+
R({ emit: n, state: e, nextTick: s, newValue: T, oldValue: f });
|
|
674
658
|
return;
|
|
675
659
|
}
|
|
676
660
|
}
|
|
677
|
-
R({ emit: n, state: e, nextTick:
|
|
661
|
+
R({ emit: n, state: e, nextTick: s, tagList: d, oldValue: f });
|
|
678
662
|
} else
|
|
679
|
-
e.propItem = { ...
|
|
663
|
+
e.propItem = { ...o, label: "" }, e.inputValue = "";
|
|
680
664
|
}
|
|
681
665
|
};
|
|
682
666
|
}
|
|
683
|
-
function
|
|
684
|
-
const t =
|
|
667
|
+
function Lt({ props: a, state: e, emit: n, nextTick: s, vm: r }) {
|
|
668
|
+
const t = r || e.instance;
|
|
685
669
|
return {
|
|
686
|
-
onConfirmDate: async (
|
|
687
|
-
if (!
|
|
670
|
+
onConfirmDate: async (u, p = !1) => {
|
|
671
|
+
if (!u) {
|
|
688
672
|
e.propItem = { label: "" };
|
|
689
673
|
return;
|
|
690
674
|
}
|
|
691
|
-
const i = await ce(t, e, a,
|
|
675
|
+
const i = await ce(t, e, a, p);
|
|
692
676
|
if (i) {
|
|
693
677
|
k(e, !1);
|
|
694
678
|
const d = a.modelValue.filter((f) => f.type !== i.type || f.field !== i.field);
|
|
695
|
-
d.push(i), R({ emit: n, state: e, nextTick:
|
|
679
|
+
d.push(i), R({ emit: n, state: e, nextTick: s, newValue: d });
|
|
696
680
|
} else
|
|
697
681
|
k(e);
|
|
698
682
|
},
|
|
699
683
|
handleDateShow: () => k(e),
|
|
700
|
-
pickerOptions: (
|
|
684
|
+
pickerOptions: (u, p = "") => ({
|
|
701
685
|
disabledDate(i) {
|
|
702
|
-
const { maxTimeLength: d = 0, min: f, max: c } = e.prevItem,
|
|
686
|
+
const { maxTimeLength: d = 0, min: f, max: c } = e.prevItem, v = e[p], h = i.getTime();
|
|
703
687
|
if (d > 0)
|
|
704
688
|
if (f || c)
|
|
705
|
-
if (
|
|
706
|
-
const
|
|
707
|
-
return h <
|
|
708
|
-
} else if (!
|
|
709
|
-
const
|
|
710
|
-
return h <
|
|
689
|
+
if (p && v) {
|
|
690
|
+
const b = new Date(v).getTime(), x = !f && c ? b - d : Math.max(f.getTime(), b - d);
|
|
691
|
+
return h < x || h > b;
|
|
692
|
+
} else if (!p && u) {
|
|
693
|
+
const b = new Date(u).getTime(), x = f && !c ? b + d : Math.min(c.getTime(), b + d);
|
|
694
|
+
return h < b || h > x;
|
|
711
695
|
} else
|
|
712
696
|
return f && h < f.getTime() || c && h > c.getTime();
|
|
713
|
-
else if (
|
|
714
|
-
const
|
|
715
|
-
return h <
|
|
716
|
-
} else if (!
|
|
717
|
-
const
|
|
718
|
-
return h <
|
|
697
|
+
else if (p && v) {
|
|
698
|
+
const b = new Date(v).getTime(), x = b - d;
|
|
699
|
+
return h < x || h > b;
|
|
700
|
+
} else if (!p && u) {
|
|
701
|
+
const b = new Date(u).getTime(), x = b + d;
|
|
702
|
+
return h < b || h > x;
|
|
719
703
|
} else
|
|
720
704
|
return !1;
|
|
721
705
|
else if (f || c)
|
|
722
|
-
if (
|
|
723
|
-
const
|
|
724
|
-
return f && h < f.getTime() || h >
|
|
725
|
-
} else if (!
|
|
726
|
-
const
|
|
727
|
-
return h <
|
|
706
|
+
if (p && v) {
|
|
707
|
+
const b = new Date(v).getTime();
|
|
708
|
+
return f && h < f.getTime() || h > b;
|
|
709
|
+
} else if (!p && u) {
|
|
710
|
+
const b = new Date(u).getTime();
|
|
711
|
+
return h < b || c && h > c.getTime();
|
|
728
712
|
} else
|
|
729
713
|
return h < f || h > c;
|
|
730
|
-
else if (
|
|
731
|
-
const
|
|
732
|
-
return h >
|
|
733
|
-
} else if (!
|
|
734
|
-
const
|
|
735
|
-
return h <
|
|
714
|
+
else if (p && v) {
|
|
715
|
+
const b = new Date(v).getTime();
|
|
716
|
+
return h > b;
|
|
717
|
+
} else if (!p && u) {
|
|
718
|
+
const b = new Date(u).getTime();
|
|
719
|
+
return h < b;
|
|
736
720
|
} else
|
|
737
721
|
return !1;
|
|
738
722
|
}
|
|
739
723
|
})
|
|
740
724
|
};
|
|
741
725
|
}
|
|
742
|
-
function
|
|
743
|
-
const m = t || e.instance, l = async (
|
|
744
|
-
if (!
|
|
726
|
+
function Nt({ props: a, state: e, t: n, emit: s, nextTick: r, vm: t }) {
|
|
727
|
+
const m = t || e.instance, l = async (p) => {
|
|
728
|
+
if (!p) {
|
|
745
729
|
e.propItem = { ...e.propItem, label: "" };
|
|
746
730
|
return;
|
|
747
731
|
}
|
|
748
|
-
const i = await
|
|
732
|
+
const i = await Re(m, e, a);
|
|
749
733
|
if (i) {
|
|
750
734
|
k(e, !1);
|
|
751
735
|
const d = a.modelValue.filter((f) => f.type !== i.type || f.field !== i.field);
|
|
752
|
-
d.push(i), R({ emit:
|
|
736
|
+
d.push(i), R({ emit: s, state: e, nextTick: r, newValue: d });
|
|
753
737
|
} else
|
|
754
738
|
k(e);
|
|
755
|
-
},
|
|
756
|
-
const { maxTimeLength: f = 0 } =
|
|
739
|
+
}, o = (p, i, d) => {
|
|
740
|
+
const { maxTimeLength: f = 0 } = p;
|
|
757
741
|
return {
|
|
758
742
|
[i]: {
|
|
759
|
-
validator: (c,
|
|
760
|
-
f > 0 && !
|
|
743
|
+
validator: (c, v, h) => {
|
|
744
|
+
f > 0 && !v ? h(new Error(n("tvp.tvpSearchbox.notBeNull"))) : !v && !e[d] ? h(new Error(n("tvp.tvpSearchbox.rangeDateTitle"))) : h();
|
|
761
745
|
}
|
|
762
746
|
},
|
|
763
747
|
[d]: {
|
|
764
|
-
validator: (c,
|
|
765
|
-
f > 0 && !
|
|
748
|
+
validator: (c, v, h) => {
|
|
749
|
+
f > 0 && !v ? h(new Error(n("tvp.tvpSearchbox.notBeNull"))) : !v && !e[i] ? h(new Error(n("tvp.tvpSearchbox.rangeDateTitle"))) : h();
|
|
766
750
|
}
|
|
767
751
|
}
|
|
768
752
|
};
|
|
769
753
|
};
|
|
770
754
|
return {
|
|
771
755
|
initFormRule: () => {
|
|
772
|
-
let
|
|
756
|
+
let p = {}, i = {};
|
|
773
757
|
a.items.forEach((d) => {
|
|
774
|
-
d.type === "dateRange" && (
|
|
758
|
+
d.type === "dateRange" && (p = o(d, "startDate", "endDate")), d.type === "datetimeRange" && (i = o(d, "startDateTime", "endDateTime"));
|
|
775
759
|
}), e.formRules = {
|
|
776
|
-
...
|
|
760
|
+
...p,
|
|
777
761
|
...i
|
|
778
762
|
}, a.editable && (e.formRules.inputEditValue = {
|
|
779
763
|
required: !0,
|
|
@@ -784,32 +768,32 @@ function Lt({ props: a, state: e, t: n, emit: r, nextTick: o, vm: t }) {
|
|
|
784
768
|
sizeChange: l
|
|
785
769
|
};
|
|
786
770
|
}
|
|
787
|
-
function
|
|
771
|
+
function Rt({ props: a, state: e, t: n, nextTick: s, format: r, emit: t, vm: m }) {
|
|
788
772
|
const l = (f) => {
|
|
789
773
|
var I;
|
|
790
|
-
const { operator: c, value:
|
|
774
|
+
const { operator: c, value: v, start: h, end: b } = f, { options: x, operators: T, type: g, mergeTag: _ } = e.prevItem;
|
|
791
775
|
if (g !== "custom") {
|
|
792
776
|
if (g === "numRange")
|
|
793
|
-
|
|
777
|
+
Pe(e, f, n);
|
|
794
778
|
else if (g === "dateRange") {
|
|
795
|
-
const { dateRangeFormat:
|
|
796
|
-
e.startDate =
|
|
779
|
+
const { dateRangeFormat: y } = e;
|
|
780
|
+
e.startDate = r(h, y), e.endDate = r(b, y);
|
|
797
781
|
} else if (g === "datetimeRange") {
|
|
798
|
-
const { datetimeRangeFormat:
|
|
799
|
-
e.startDateTime =
|
|
782
|
+
const { datetimeRangeFormat: y } = e;
|
|
783
|
+
e.startDateTime = r(h, y), e.endDateTime = r(b, y);
|
|
800
784
|
} else {
|
|
801
785
|
if (_) {
|
|
802
|
-
const
|
|
803
|
-
e.inputEditValue =
|
|
786
|
+
const y = ((I = f.options) == null ? void 0 : I.flatMap((C) => C.label)) || [];
|
|
787
|
+
e.inputEditValue = y, e.currentEditSelectTags = y;
|
|
804
788
|
} else
|
|
805
|
-
e.inputEditValue = Array.isArray(
|
|
806
|
-
e.currentEditValue =
|
|
789
|
+
e.inputEditValue = Array.isArray(v) ? v.join(",") : v || "";
|
|
790
|
+
e.currentEditValue = x;
|
|
807
791
|
}
|
|
808
|
-
e.operatorValue = c, e.currentOperators =
|
|
792
|
+
e.operatorValue = c, e.currentOperators = T;
|
|
809
793
|
}
|
|
810
|
-
},
|
|
811
|
-
var h,
|
|
812
|
-
if (!((
|
|
794
|
+
}, o = async () => {
|
|
795
|
+
var h, b;
|
|
796
|
+
if (!((b = (h = e.instance) == null ? void 0 : h.$refs) != null && b.formRef))
|
|
813
797
|
return;
|
|
814
798
|
const { prevItem: f } = e;
|
|
815
799
|
let c = [];
|
|
@@ -817,58 +801,58 @@ function Nt({ props: a, state: e, t: n, nextTick: r, format: o, emit: t, vm: m }
|
|
|
817
801
|
e.hasFormError = !1;
|
|
818
802
|
return;
|
|
819
803
|
}
|
|
820
|
-
let
|
|
821
|
-
await e.instance.$refs.formRef.validateField(c, (
|
|
822
|
-
|
|
823
|
-
}), e.hasFormError =
|
|
804
|
+
let v = !1;
|
|
805
|
+
await e.instance.$refs.formRef.validateField(c, (x) => {
|
|
806
|
+
x && (v = !0);
|
|
807
|
+
}), e.hasFormError = v;
|
|
824
808
|
};
|
|
825
809
|
return {
|
|
826
|
-
editTag: (f, c,
|
|
810
|
+
editTag: (f, c, v) => {
|
|
827
811
|
if (!a.editable || f.type && f.type === "map")
|
|
828
812
|
return;
|
|
829
813
|
k(e, !1), e.popoverVisible = !1;
|
|
830
|
-
const h =
|
|
831
|
-
|
|
832
|
-
const { popoverRef:
|
|
833
|
-
|
|
834
|
-
}), e.prevItem = e.recordItems.find((
|
|
814
|
+
const h = v.target.classList.contains("tiny-tag") ? v.target : v.srcElement.parentElement;
|
|
815
|
+
s(() => {
|
|
816
|
+
const { popoverRef: b } = e.instance.$refs;
|
|
817
|
+
b.state.referenceElm = h, b.state.popperElm && (b.state.popperElm.style.display = "none"), b.doDestroy(), e.popoverVisible = !0, o();
|
|
818
|
+
}), e.prevItem = e.recordItems.find((b) => b.field === f.field), !e.prevItem && (e.prevItem = f), e.selectValue = f.label, e.currentModelValueIndex = c, t("tagClick", f), l(f);
|
|
835
819
|
},
|
|
836
820
|
confirmEditTag: async (f) => {
|
|
837
821
|
if (!f) {
|
|
838
822
|
e.popoverVisible = !1;
|
|
839
823
|
return;
|
|
840
824
|
}
|
|
841
|
-
const { prevItem: c, currentModelValueIndex:
|
|
825
|
+
const { prevItem: c, currentModelValueIndex: v } = e;
|
|
842
826
|
let h = null;
|
|
843
|
-
c.type === "numRange" ? h = await
|
|
827
|
+
c.type === "numRange" ? h = await Re(e.instance, e, a) : c.type === "dateRange" ? h = await ce(e.instance, e, a, !1) : c.type === "datetimeRange" ? h = await ce(e.instance, e, a, !0) : h = await St(e.instance, e, a), h ? (k(e, !1), e.popoverVisible = !1, R({ emit: t, state: e, nextTick: s, index: v, newTag: h, isEdit: !0 })) : e.popoverVisible = !0, e.currentEditValue = [];
|
|
844
828
|
},
|
|
845
829
|
selectPropChange: (f, c) => {
|
|
846
|
-
c || (e.prevItem = f, l(f),
|
|
847
|
-
|
|
830
|
+
c || (e.prevItem = f, l(f), s(() => {
|
|
831
|
+
o();
|
|
848
832
|
}));
|
|
849
833
|
},
|
|
850
834
|
selectItemIsDisable: (f) => {
|
|
851
|
-
var
|
|
835
|
+
var v, h, b, x;
|
|
852
836
|
if (f.type && f.type === "map")
|
|
853
837
|
return !0;
|
|
854
|
-
if ((
|
|
855
|
-
return ((h = e.prevItem.operators) == null ? void 0 : h.length) !== ((
|
|
838
|
+
if ((v = e.prevItem) != null && v.operators || f.operators)
|
|
839
|
+
return ((h = e.prevItem.operators) == null ? void 0 : h.length) !== ((b = f.operators) == null ? void 0 : b.length);
|
|
856
840
|
const c = ["radio", "checkbox"];
|
|
857
|
-
return e.prevItem.type && c.includes(e.prevItem.type) ? f.type ? !c.includes(f.type) : !1 : ((
|
|
841
|
+
return e.prevItem.type && c.includes(e.prevItem.type) ? f.type ? !c.includes(f.type) : !1 : ((x = e.prevItem) == null ? void 0 : x.type) !== f.type;
|
|
858
842
|
},
|
|
859
|
-
checkFormValidation:
|
|
843
|
+
checkFormValidation: o
|
|
860
844
|
};
|
|
861
845
|
}
|
|
862
|
-
function
|
|
863
|
-
const
|
|
846
|
+
function Pt({ state: a, emit: e, nextTick: n }) {
|
|
847
|
+
const s = (m) => {
|
|
864
848
|
k(a, !1);
|
|
865
|
-
const { prevItem: l, indexMap:
|
|
866
|
-
if (
|
|
867
|
-
const d =
|
|
849
|
+
const { prevItem: l, indexMap: o } = a, { replace: u, label: p } = l, i = [];
|
|
850
|
+
if (u && o.has(p)) {
|
|
851
|
+
const d = o.get(p), f = { ...l, ...m };
|
|
868
852
|
R({ emit: e, state: a, nextTick: n, newTag: f, index: d });
|
|
869
853
|
return;
|
|
870
854
|
} else
|
|
871
|
-
!
|
|
855
|
+
!u && Array.isArray(m) ? m.forEach((d) => {
|
|
872
856
|
O(a, d.value) || i.push({ ...l, ...d });
|
|
873
857
|
}) : O(a, m.value) || i.push({ ...l, ...m });
|
|
874
858
|
R({ emit: e, state: a, nextTick: n, tagList: i });
|
|
@@ -879,26 +863,26 @@ function Rt({ state: a, emit: e, nextTick: n }) {
|
|
|
879
863
|
ae(a), k(a, !1);
|
|
880
864
|
return;
|
|
881
865
|
}
|
|
882
|
-
|
|
866
|
+
s(m);
|
|
883
867
|
},
|
|
884
868
|
handleEditConfirm: (m) => {
|
|
885
869
|
if (!m) {
|
|
886
|
-
|
|
870
|
+
W(a, !1);
|
|
887
871
|
return;
|
|
888
872
|
}
|
|
889
|
-
|
|
873
|
+
s(m);
|
|
890
874
|
}
|
|
891
875
|
};
|
|
892
876
|
}
|
|
893
|
-
function
|
|
877
|
+
function Ot({ props: a, state: e }) {
|
|
894
878
|
return {
|
|
895
879
|
initItems: () => {
|
|
896
880
|
e.groupItems = {}, e.recordItems.forEach((l) => {
|
|
897
|
-
var
|
|
898
|
-
const { groupKey:
|
|
899
|
-
if (e.groupItems[
|
|
900
|
-
const { options:
|
|
901
|
-
e.prevItem = l,
|
|
881
|
+
var u;
|
|
882
|
+
const { groupKey: o = "0" } = l;
|
|
883
|
+
if (e.groupItems[o] ? e.groupItems[o].push({ ...l }) : (e.groupItems[o] = [{ ...l }], e.matchItems[o] = { attr: [], attrValue: [] }), e.prevItem && l.field === e.prevItem.field && l !== e.prevItem) {
|
|
884
|
+
const { options: p, type: i } = l;
|
|
885
|
+
e.prevItem = l, p != null && p.length && (e.backupList = p), i === "checkbox" && (e.filterList = e.backupList, e.checkboxGroup = [], (u = e.backupList) == null || u.forEach((d) => {
|
|
902
886
|
const { label: f } = d;
|
|
903
887
|
O(e, f) && e.checkboxGroup.push(`${l.label}${f}`), d.isFilter = !1;
|
|
904
888
|
})), k(e, l.field === e.prevItem.field && l !== e.prevItem);
|
|
@@ -906,7 +890,7 @@ function Pt({ props: a, state: e }) {
|
|
|
906
890
|
});
|
|
907
891
|
},
|
|
908
892
|
watchOutsideClick: () => {
|
|
909
|
-
a.editable &&
|
|
893
|
+
a.editable && W(e, !1), e.isMouseDown = !1, k(e, !1);
|
|
910
894
|
},
|
|
911
895
|
watchMouseDown: () => {
|
|
912
896
|
e.isMouseDown = !0;
|
|
@@ -915,13 +899,13 @@ function Pt({ props: a, state: e }) {
|
|
|
915
899
|
e.isMouseDown && (e.isMouseDown = !1);
|
|
916
900
|
},
|
|
917
901
|
handleClick: (l) => {
|
|
918
|
-
var
|
|
919
|
-
const { backupPrevItem:
|
|
920
|
-
l.stopPropagation(), a.editable && (e.popoverVisible = !1, e.currentEditValue = [], e.propItem.label &&
|
|
902
|
+
var p;
|
|
903
|
+
const { backupPrevItem: o, prevItem: u } = e;
|
|
904
|
+
l.stopPropagation(), a.editable && (e.popoverVisible = !1, e.currentEditValue = [], e.propItem.label && o && o !== u && (e.prevItem = o)), e.hasBackupList && (((p = e.backupList) == null ? void 0 : p.length) === 0 || !e.backupList) && !e.inputValue || a.items.length === 0 ? k(e, !1) : k(e);
|
|
921
905
|
}
|
|
922
906
|
};
|
|
923
907
|
}
|
|
924
|
-
const
|
|
908
|
+
const Oe = {
|
|
925
909
|
tvp: {
|
|
926
910
|
tvpSearchbox: {
|
|
927
911
|
defaultPlaceholder: "请选择属性筛选,或输入关键字",
|
|
@@ -962,7 +946,7 @@ const Le = {
|
|
|
962
946
|
initUse: "搜索"
|
|
963
947
|
}
|
|
964
948
|
}
|
|
965
|
-
},
|
|
949
|
+
}, Fe = {
|
|
966
950
|
tvp: {
|
|
967
951
|
tvpSearchbox: {
|
|
968
952
|
defaultPlaceholder: "Select attribute filtering or enter keywords",
|
|
@@ -1003,66 +987,66 @@ const Le = {
|
|
|
1003
987
|
initUse: "Search"
|
|
1004
988
|
}
|
|
1005
989
|
}
|
|
1006
|
-
},
|
|
1007
|
-
"zh-CN":
|
|
1008
|
-
"en-US":
|
|
990
|
+
}, Y = "zh-CN", Z = {
|
|
991
|
+
"zh-CN": Oe,
|
|
992
|
+
"en-US": Fe
|
|
1009
993
|
};
|
|
1010
|
-
let
|
|
1011
|
-
const
|
|
1012
|
-
|
|
1013
|
-
},
|
|
1014
|
-
|
|
1015
|
-
},
|
|
1016
|
-
var a, e, n,
|
|
1017
|
-
if ((n = (e = (a =
|
|
1018
|
-
return
|
|
1019
|
-
if ((
|
|
1020
|
-
return
|
|
994
|
+
let E = null, ue = null;
|
|
995
|
+
const Ft = (a) => {
|
|
996
|
+
E = a;
|
|
997
|
+
}, Bt = (a) => {
|
|
998
|
+
ue = a;
|
|
999
|
+
}, ve = () => {
|
|
1000
|
+
var a, e, n, s, r;
|
|
1001
|
+
if ((n = (e = (a = E == null ? void 0 : E.config) == null ? void 0 : a.globalProperties) == null ? void 0 : e.$i18n) != null && n.locale)
|
|
1002
|
+
return E.config.globalProperties.$i18n.locale;
|
|
1003
|
+
if ((s = E == null ? void 0 : E.$i18n) != null && s.locale)
|
|
1004
|
+
return E.$i18n.locale;
|
|
1021
1005
|
if (typeof navigator < "u") {
|
|
1022
|
-
const t = navigator.language || ((
|
|
1006
|
+
const t = navigator.language || ((r = navigator.languages) == null ? void 0 : r[0]);
|
|
1023
1007
|
if (t)
|
|
1024
1008
|
return t.startsWith("zh") ? "zh-CN" : "en-US";
|
|
1025
1009
|
}
|
|
1026
|
-
return
|
|
1027
|
-
},
|
|
1010
|
+
return Y;
|
|
1011
|
+
}, pe = (a) => Z[a] || Z[Y], L = (a, e = {}) => {
|
|
1028
1012
|
var m, l;
|
|
1029
1013
|
if (!a)
|
|
1030
1014
|
return "";
|
|
1031
|
-
if (typeof
|
|
1015
|
+
if (typeof ue == "function")
|
|
1032
1016
|
try {
|
|
1033
|
-
const
|
|
1034
|
-
if (
|
|
1035
|
-
return
|
|
1036
|
-
} catch (
|
|
1037
|
-
console.warn("[TinySearchBox] globalT translation failed:",
|
|
1017
|
+
const o = ue(a, e);
|
|
1018
|
+
if (o && o !== a)
|
|
1019
|
+
return o;
|
|
1020
|
+
} catch (o) {
|
|
1021
|
+
console.warn("[TinySearchBox] globalT translation failed:", o);
|
|
1038
1022
|
}
|
|
1039
|
-
if ((l = (m =
|
|
1023
|
+
if ((l = (m = E == null ? void 0 : E.config) == null ? void 0 : m.globalProperties) != null && l.$t)
|
|
1040
1024
|
try {
|
|
1041
|
-
const
|
|
1042
|
-
if (
|
|
1043
|
-
return
|
|
1044
|
-
} catch (
|
|
1045
|
-
console.warn("[TinySearchBox] i18n translation failed:",
|
|
1025
|
+
const o = E.config.globalProperties.$t(a, e);
|
|
1026
|
+
if (o && o !== a)
|
|
1027
|
+
return o;
|
|
1028
|
+
} catch (o) {
|
|
1029
|
+
console.warn("[TinySearchBox] i18n translation failed:", o);
|
|
1046
1030
|
}
|
|
1047
|
-
if (
|
|
1031
|
+
if (E != null && E.$t)
|
|
1048
1032
|
try {
|
|
1049
|
-
const
|
|
1050
|
-
if (
|
|
1051
|
-
return
|
|
1052
|
-
} catch (
|
|
1053
|
-
console.warn("[TinySearchBox] i18n translation failed:",
|
|
1054
|
-
}
|
|
1055
|
-
const n =
|
|
1056
|
-
let t =
|
|
1057
|
-
for (const
|
|
1058
|
-
if (t && typeof t == "object" &&
|
|
1059
|
-
t = t[
|
|
1033
|
+
const o = E.$t(a, e);
|
|
1034
|
+
if (o && o !== a)
|
|
1035
|
+
return o;
|
|
1036
|
+
} catch (o) {
|
|
1037
|
+
console.warn("[TinySearchBox] i18n translation failed:", o);
|
|
1038
|
+
}
|
|
1039
|
+
const n = ve(), s = pe(n), r = a.split(".");
|
|
1040
|
+
let t = s;
|
|
1041
|
+
for (const o of r)
|
|
1042
|
+
if (t && typeof t == "object" && o in t)
|
|
1043
|
+
t = t[o];
|
|
1060
1044
|
else {
|
|
1061
|
-
if (n !==
|
|
1062
|
-
t =
|
|
1063
|
-
for (const
|
|
1064
|
-
if (t && typeof t == "object" &&
|
|
1065
|
-
t = t[
|
|
1045
|
+
if (n !== Y) {
|
|
1046
|
+
t = pe(Y);
|
|
1047
|
+
for (const p of r)
|
|
1048
|
+
if (t && typeof t == "object" && p in t)
|
|
1049
|
+
t = t[p];
|
|
1066
1050
|
else {
|
|
1067
1051
|
t = a;
|
|
1068
1052
|
break;
|
|
@@ -1071,25 +1055,25 @@ const Ot = (a) => {
|
|
|
1071
1055
|
t = a;
|
|
1072
1056
|
break;
|
|
1073
1057
|
}
|
|
1074
|
-
return typeof t == "string" && Object.keys(e).length > 0 ? t.replace(/\{(\w+)\}/g, (
|
|
1075
|
-
},
|
|
1076
|
-
|
|
1077
|
-
},
|
|
1078
|
-
a !==
|
|
1079
|
-
},
|
|
1058
|
+
return typeof t == "string" && Object.keys(e).length > 0 ? t.replace(/\{(\w+)\}/g, (o, u) => e[u] !== void 0 ? e[u] : o) : typeof t == "string" ? t : a;
|
|
1059
|
+
}, At = (a, e = {}) => a.map((n) => L(n, e)), zt = (a) => a in Z, Ht = () => Object.keys(Z), jt = (a, e) => {
|
|
1060
|
+
Z[a] = e;
|
|
1061
|
+
}, Gt = (a) => {
|
|
1062
|
+
a !== Y && delete Z[a];
|
|
1063
|
+
}, Kt = {
|
|
1080
1064
|
t: L,
|
|
1081
|
-
zhCN:
|
|
1082
|
-
enUS:
|
|
1083
|
-
tArray:
|
|
1084
|
-
setGlobalT:
|
|
1085
|
-
setGlobalApp:
|
|
1086
|
-
getCurrentLocale:
|
|
1087
|
-
getLocaleMessages:
|
|
1088
|
-
isLocaleSupported:
|
|
1089
|
-
getSupportedLocales:
|
|
1065
|
+
zhCN: Oe,
|
|
1066
|
+
enUS: Fe,
|
|
1067
|
+
tArray: At,
|
|
1068
|
+
setGlobalT: Bt,
|
|
1069
|
+
setGlobalApp: Ft,
|
|
1070
|
+
getCurrentLocale: ve,
|
|
1071
|
+
getLocaleMessages: pe,
|
|
1072
|
+
isLocaleSupported: zt,
|
|
1073
|
+
getSupportedLocales: Ht,
|
|
1090
1074
|
addLocale: jt,
|
|
1091
|
-
removeLocale:
|
|
1092
|
-
},
|
|
1075
|
+
removeLocale: Gt
|
|
1076
|
+
}, Ut = [
|
|
1093
1077
|
"t",
|
|
1094
1078
|
"state",
|
|
1095
1079
|
"isShowClose",
|
|
@@ -1116,8 +1100,8 @@ const Ot = (a) => {
|
|
|
1116
1100
|
"handleEditConfirm",
|
|
1117
1101
|
"showDropdown",
|
|
1118
1102
|
"showPopover"
|
|
1119
|
-
], X = (a, e) => a.emptyPlaceholder || e("tvp.tvpSearchbox.addPlaceholder"),
|
|
1120
|
-
const
|
|
1103
|
+
], X = (a, e) => a.emptyPlaceholder || e("tvp.tvpSearchbox.addPlaceholder"), Zt = ({ reactive: a, computed: e, api: n, i18n: s, watch: r, props: t, emit: m, vm: l }) => {
|
|
1104
|
+
const o = a({
|
|
1121
1105
|
innerModelValue: [...t.modelValue],
|
|
1122
1106
|
placeholder: t.modelValue.length > 0 ? L("tvp.tvpSearchbox.addPlaceholder") : X(t, L),
|
|
1123
1107
|
emitter: m,
|
|
@@ -1161,52 +1145,52 @@ const Ot = (a) => {
|
|
|
1161
1145
|
visibleTimer: null,
|
|
1162
1146
|
hasFormError: !1,
|
|
1163
1147
|
// 表单校验错误状态
|
|
1164
|
-
hasBackupList: e(() =>
|
|
1165
|
-
isIndeterminate: e(() =>
|
|
1148
|
+
hasBackupList: e(() => o.propItem.label && [void 0, "radio", "checkbox", "map"].includes(o.prevItem.type)),
|
|
1149
|
+
isIndeterminate: e(() => o.checkboxGroup.length > 0 && o.checkboxGroup.length !== o.filterList.length),
|
|
1166
1150
|
checkAll: e({
|
|
1167
|
-
get: () =>
|
|
1168
|
-
set: (
|
|
1169
|
-
|
|
1151
|
+
get: () => o.checkboxGroup.length && o.checkboxGroup.length === o.filterList.length,
|
|
1152
|
+
set: (u) => {
|
|
1153
|
+
u ? o.checkboxGroup = o.filterList.flatMap((p) => `${o.prevItem.label}${p.label}`) : o.checkboxGroup = [];
|
|
1170
1154
|
}
|
|
1171
1155
|
})
|
|
1172
1156
|
});
|
|
1173
|
-
return
|
|
1174
|
-
}, qt = (a, { getCurrentInstance: e, onMounted: n, onBeforeUnmount:
|
|
1175
|
-
const d = {}, f = a.emitter ? a.emitter.emit : l, c =
|
|
1176
|
-
return
|
|
1157
|
+
return o;
|
|
1158
|
+
}, qt = (a, { getCurrentInstance: e, onMounted: n, onBeforeUnmount: s, computed: r, reactive: t, watch: m }, { emit: l, nextTick: o, refs: u, vm: p, slots: i }) => {
|
|
1159
|
+
const d = {}, f = a.emitter ? a.emitter.emit : l, c = Zt({ reactive: t, computed: r, api: d, i18n: Kt, watch: m, props: a, emit: f, vm: p });
|
|
1160
|
+
return Qt({ api: d, state: c, t: L, props: a, emit: f, nextTick: o, vm: p, computed: r }), Yt({ watch: m, state: c, props: a, api: d, nextTick: o, vm: p }), c.instance = p, p && i && (p.slots = i), n(() => {
|
|
1177
1161
|
typeof document < "u" && (document.addEventListener("click", d.watchOutsideClick), document.addEventListener("mousedown", d.watchMouseDown), document.addEventListener("mousemove", d.watchMouseMove));
|
|
1178
|
-
}),
|
|
1162
|
+
}), s(() => {
|
|
1179
1163
|
typeof document < "u" && (document.removeEventListener("click", d.watchOutsideClick), document.removeEventListener("mousedown", d.watchMouseDown), document.removeEventListener("mousemove", d.watchMouseMove), c.localeCheckInterval && (clearInterval(c.localeCheckInterval), c.localeCheckInterval = null));
|
|
1180
1164
|
}), d;
|
|
1181
|
-
},
|
|
1182
|
-
const { deleteTag:
|
|
1165
|
+
}, Qt = ({ api: a, state: e, t: n, props: s, emit: r, nextTick: t, vm: m, computed: l }) => {
|
|
1166
|
+
const { deleteTag: o, clearTag: u, backspaceDeleteTag: p } = Tt({ props: s, state: e, emit: r, nextTick: t }), { editTag: i, confirmEditTag: d, selectPropChange: f, selectItemIsDisable: c, checkFormValidation: v } = Rt({ props: s, state: e, t: n, nextTick: t, format: ie, emit: r, vm: m }), { handleInput: h, selectFirstMap: b, cancelHandleInput: x } = $t({ props: s, state: e, emit: r, nextTick: t }), { selectPropItem: T, selectRadioItem: g, selectInputValue: _, createTag: I, helpClick: y, setOperator: C } = Dt({ props: s, emit: r, state: e, t: n, format: ie, nextTick: t, vm: m, cancelHandleInput: x }), { selectCheckbox: w } = Et({ props: s, state: e, emit: r, nextTick: t }), { onConfirmDate: S, handleDateShow: V, pickerOptions: D } = Lt({ props: s, state: e, emit: r, nextTick: t, vm: m }), { sizeChange: M, initFormRule: $ } = Nt({ props: s, state: e, t: n, emit: r, nextTick: t, vm: m }), { handleConfirm: B, handleEditConfirm: P } = Pt({ state: e, emit: r, nextTick: t }), { initItems: N, watchOutsideClick: F, watchMouseDown: K, watchMouseMove: ne, handleClick: se } = Ot({ props: s, state: e }), Be = l(() => s.modelValue.length || e.propItem.label || e.inputValue), Ae = () => ({
|
|
1183
1167
|
selectInputValue: _,
|
|
1184
|
-
selectPropItem:
|
|
1168
|
+
selectPropItem: T,
|
|
1185
1169
|
selectRadioItem: g,
|
|
1186
|
-
setOperator:
|
|
1170
|
+
setOperator: C,
|
|
1187
1171
|
selectCheckbox: w,
|
|
1188
1172
|
sizeChange: M,
|
|
1189
1173
|
onConfirmDate: S,
|
|
1190
|
-
selectFirstMap:
|
|
1174
|
+
selectFirstMap: b,
|
|
1191
1175
|
handleDateShow: V
|
|
1192
|
-
}),
|
|
1193
|
-
e.placeholder =
|
|
1194
|
-
},
|
|
1195
|
-
|
|
1176
|
+
}), re = (q) => {
|
|
1177
|
+
e.placeholder = q;
|
|
1178
|
+
}, ze = () => X(s, n);
|
|
1179
|
+
s.modelValue.length > 0 ? re(n("tvp.tvpSearchbox.addPlaceholder")) : re(ze()), Object.assign(a, {
|
|
1196
1180
|
t: n,
|
|
1197
1181
|
state: e,
|
|
1198
|
-
isShowClose:
|
|
1199
|
-
deleteTag:
|
|
1182
|
+
isShowClose: Be,
|
|
1183
|
+
deleteTag: o,
|
|
1200
1184
|
editTag: i,
|
|
1201
|
-
backspaceDeleteTag:
|
|
1185
|
+
backspaceDeleteTag: p,
|
|
1202
1186
|
createTag: I,
|
|
1203
|
-
clearTag:
|
|
1204
|
-
helpClick:
|
|
1187
|
+
clearTag: u,
|
|
1188
|
+
helpClick: y,
|
|
1205
1189
|
handleInput: h,
|
|
1206
|
-
handleClick:
|
|
1207
|
-
handleEvents: (
|
|
1208
|
-
const
|
|
1209
|
-
typeof
|
|
1190
|
+
handleClick: se,
|
|
1191
|
+
handleEvents: (q, He, je) => {
|
|
1192
|
+
const ge = Ae();
|
|
1193
|
+
typeof ge[q] == "function" ? ge[q](He, je) : console.warn(`[TinySearchBox] Unknown event: ${q}`);
|
|
1210
1194
|
},
|
|
1211
1195
|
pickerOptions: D,
|
|
1212
1196
|
resetInput: ae,
|
|
@@ -1216,71 +1200,71 @@ const Ot = (a) => {
|
|
|
1216
1200
|
handleConfirm: B,
|
|
1217
1201
|
handleEditConfirm: P,
|
|
1218
1202
|
showDropdown: k,
|
|
1219
|
-
showPopover:
|
|
1220
|
-
checkFormValidation:
|
|
1221
|
-
setPlaceholder:
|
|
1203
|
+
showPopover: W,
|
|
1204
|
+
checkFormValidation: v,
|
|
1205
|
+
setPlaceholder: re,
|
|
1222
1206
|
initItems: N,
|
|
1223
|
-
initFormRule:
|
|
1207
|
+
initFormRule: $,
|
|
1224
1208
|
watchOutsideClick: F,
|
|
1225
1209
|
watchMouseDown: K,
|
|
1226
1210
|
watchMouseMove: ne
|
|
1227
1211
|
});
|
|
1228
|
-
}, Yt = ({ watch: a, state: e, props: n, api:
|
|
1229
|
-
var
|
|
1212
|
+
}, Yt = ({ watch: a, state: e, props: n, api: s, nextTick: r, vm: t }) => {
|
|
1213
|
+
var p;
|
|
1230
1214
|
const m = () => {
|
|
1231
1215
|
var i;
|
|
1232
1216
|
if (e.propItem.label) {
|
|
1233
1217
|
const { placeholder: d, type: f } = e.prevItem;
|
|
1234
|
-
d ?
|
|
1218
|
+
d ? s.setPlaceholder(d) : f === "map" ? s.setPlaceholder(L("tvp.tvpSearchbox.tagPlaceholder")) : (i = e.backupList) != null && i.length ? s.setPlaceholder(L("tvp.tvpSearchbox.dynamicPlaceholder", { newValue: e.propItem.label })) : s.setPlaceholder(L("tvp.tvpSearchbox.addPlaceholder"));
|
|
1235
1219
|
} else {
|
|
1236
1220
|
const d = n.modelValue.length > 0 ? L("tvp.tvpSearchbox.addPlaceholder") : X(n, L);
|
|
1237
|
-
|
|
1221
|
+
s.setPlaceholder(d);
|
|
1238
1222
|
}
|
|
1239
1223
|
}, l = () => {
|
|
1240
1224
|
var i, d, f;
|
|
1241
|
-
return (i = t == null ? void 0 : t.$i18n) != null && i.locale ? t.$i18n.locale : (f = (d = t == null ? void 0 : t.proxy) == null ? void 0 : d.$i18n) != null && f.locale ? t.proxy.$i18n.locale :
|
|
1225
|
+
return (i = t == null ? void 0 : t.$i18n) != null && i.locale ? t.$i18n.locale : (f = (d = t == null ? void 0 : t.proxy) == null ? void 0 : d.$i18n) != null && f.locale ? t.proxy.$i18n.locale : ve();
|
|
1242
1226
|
};
|
|
1243
|
-
let
|
|
1227
|
+
let o = l();
|
|
1244
1228
|
if (t != null && t.$i18n)
|
|
1245
1229
|
try {
|
|
1246
1230
|
t.$watch(
|
|
1247
1231
|
() => t.$i18n.locale,
|
|
1248
1232
|
(i) => {
|
|
1249
|
-
i !==
|
|
1233
|
+
i !== o && (o = i, m());
|
|
1250
1234
|
},
|
|
1251
1235
|
{ immediate: !1 }
|
|
1252
1236
|
);
|
|
1253
1237
|
} catch (i) {
|
|
1254
1238
|
console.warn("[TinySearchBox] Unable to watch i18n.locale via vm.$watch:", i);
|
|
1255
1239
|
}
|
|
1256
|
-
if ((
|
|
1240
|
+
if ((p = t == null ? void 0 : t.proxy) != null && p.$i18n)
|
|
1257
1241
|
try {
|
|
1258
1242
|
a(
|
|
1259
1243
|
() => t.proxy.$i18n.locale,
|
|
1260
1244
|
(i) => {
|
|
1261
|
-
i !==
|
|
1245
|
+
i !== o && (o = i, m());
|
|
1262
1246
|
},
|
|
1263
1247
|
{ immediate: !1 }
|
|
1264
1248
|
);
|
|
1265
1249
|
} catch (i) {
|
|
1266
1250
|
console.warn("[TinySearchBox] Unable to watch i18n.locale via watch:", i);
|
|
1267
1251
|
}
|
|
1268
|
-
const
|
|
1252
|
+
const u = () => {
|
|
1269
1253
|
const i = l();
|
|
1270
|
-
i !==
|
|
1254
|
+
i !== o && (o = i, m());
|
|
1271
1255
|
};
|
|
1272
|
-
typeof window < "u" && (e.localeCheckInterval = setInterval(
|
|
1256
|
+
typeof window < "u" && (e.localeCheckInterval = setInterval(u, 200)), a(
|
|
1273
1257
|
() => n.modelValue,
|
|
1274
1258
|
() => {
|
|
1275
|
-
|
|
1259
|
+
u();
|
|
1276
1260
|
}
|
|
1277
1261
|
), a(
|
|
1278
1262
|
() => n.items,
|
|
1279
1263
|
(i) => {
|
|
1280
1264
|
const d = e.visible, f = e.prevItem && e.prevItem.field;
|
|
1281
|
-
e.recordItems =
|
|
1282
|
-
if (
|
|
1283
|
-
const c = e.recordItems.find((
|
|
1265
|
+
e.recordItems = H(i), s.initItems(), s.initFormRule(), r(() => {
|
|
1266
|
+
if (s.initItems(), s.initFormRule(), d && e.propItem.label) {
|
|
1267
|
+
const c = e.recordItems.find((v) => v.field === f) || e.prevItem;
|
|
1284
1268
|
e.prevItem = c || {}, e.backupList = c && c.options ? [...c.options] : [], e.filterList = e.backupList ? [...e.backupList] : [], k(e);
|
|
1285
1269
|
}
|
|
1286
1270
|
});
|
|
@@ -1317,8 +1301,8 @@ const Ot = (a) => {
|
|
|
1317
1301
|
return e.curMinNumVar && e.curMaxNumVar && (i[e.curMinNumVar] = e[e.curMinNumVar], i[e.curMaxNumVar] = e[e.curMaxNumVar]), i;
|
|
1318
1302
|
},
|
|
1319
1303
|
() => {
|
|
1320
|
-
e.popoverVisible &&
|
|
1321
|
-
|
|
1304
|
+
e.popoverVisible && r(() => {
|
|
1305
|
+
s.checkFormValidation();
|
|
1322
1306
|
});
|
|
1323
1307
|
},
|
|
1324
1308
|
{ deep: !0 }
|
|
@@ -1332,16 +1316,16 @@ const Ot = (a) => {
|
|
|
1332
1316
|
(i) => {
|
|
1333
1317
|
if (i) {
|
|
1334
1318
|
if (e.indexMap.clear(), e.valueMap.clear(), i.forEach((d, f) => {
|
|
1335
|
-
var
|
|
1319
|
+
var v;
|
|
1336
1320
|
const c = `${d.label}${d.value}`;
|
|
1337
|
-
e.indexMap.set(d.label, f), e.valueMap.set(c, f), ((
|
|
1338
|
-
const
|
|
1339
|
-
e.valueMap.set(
|
|
1321
|
+
e.indexMap.set(d.label, f), e.valueMap.set(c, f), ((v = d.options) == null ? void 0 : v.length) > 0 && d.options.forEach((h) => {
|
|
1322
|
+
const b = `${d.label}${h.label}`;
|
|
1323
|
+
e.valueMap.set(b, f);
|
|
1340
1324
|
});
|
|
1341
|
-
}),
|
|
1325
|
+
}), W(e, !1), i.length === 0 && s.setPlaceholder(X(n, L)), n.editable && !e.inputEditValue.length && i[0]) {
|
|
1342
1326
|
const d = i[0];
|
|
1343
1327
|
if ((e.recordItems.find((c) => c.field === d.field) || d).mergeTag && d.options) {
|
|
1344
|
-
const c = d.options.flatMap((
|
|
1328
|
+
const c = d.options.flatMap((v) => v.label) || [];
|
|
1345
1329
|
e.inputEditValue = c, e.currentEditSelectTags = c;
|
|
1346
1330
|
} else {
|
|
1347
1331
|
const c = d.value;
|
|
@@ -1358,12 +1342,83 @@ const Ot = (a) => {
|
|
|
1358
1342
|
);
|
|
1359
1343
|
};
|
|
1360
1344
|
var Wt = function() {
|
|
1361
|
-
var
|
|
1362
|
-
return
|
|
1345
|
+
var e = this, n = e.$createElement, s = e._self._c || n;
|
|
1346
|
+
return s("svg", e._g({
|
|
1347
|
+
attrs: {
|
|
1348
|
+
viewBox: "0 0 16 16",
|
|
1349
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
1350
|
+
}
|
|
1351
|
+
}, e.$listeners), [s("path", {
|
|
1352
|
+
attrs: {
|
|
1353
|
+
d: "M12.49 3.3a.5.5 0 0 1 .05.62L8.58 7.89l3.91 3.88c.21.19.23.48.05.71-.17.19-.49.24-.71.06L7.88 8.58 4 12.49c-.18.17-.5.18-.68.01a.496.496 0 0 1-.08-.67l3.93-3.94L3.29 4a.524.524 0 0 1 .04-.71c.17-.14.42-.16.58-.05l3.97 3.93 3.9-3.87c.18-.22.51-.22.71 0Z",
|
|
1354
|
+
"fill-rule": "evenodd"
|
|
1355
|
+
}
|
|
1356
|
+
})]);
|
|
1357
|
+
}, _e = {
|
|
1358
|
+
render: Wt
|
|
1359
|
+
}, Xt = function() {
|
|
1360
|
+
return de({
|
|
1361
|
+
name: "IconClose",
|
|
1362
|
+
component: _e,
|
|
1363
|
+
filledComponent: _e
|
|
1364
|
+
})();
|
|
1365
|
+
}, Jt = function() {
|
|
1366
|
+
var e = this, n = e.$createElement, s = e._self._c || n;
|
|
1367
|
+
return s("svg", e._g({
|
|
1368
|
+
attrs: {
|
|
1369
|
+
viewBox: "0 0 16 16",
|
|
1370
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
1371
|
+
}
|
|
1372
|
+
}, e.$listeners), [s("path", {
|
|
1373
|
+
attrs: {
|
|
1374
|
+
d: "M8 0a8 8 0 0 0-8 8 8 8 0 0 0 8 8 8 8 0 0 0 8-8 8 8 0 0 0-8-8Zm4.86 12.86a6.84 6.84 0 0 1-2.185 1.474c-.847.36-1.747.541-2.675.541a6.835 6.835 0 0 1-4.86-2.012 6.84 6.84 0 0 1-1.474-2.186A6.822 6.822 0 0 1 1.125 8a6.835 6.835 0 0 1 2.013-4.86 6.84 6.84 0 0 1 2.185-1.474A6.822 6.822 0 0 1 8 1.125a6.835 6.835 0 0 1 4.86 2.013 6.84 6.84 0 0 1 1.474 2.185c.36.849.541 1.749.541 2.677a6.835 6.835 0 0 1-2.014 4.86ZM7.92 10.374a.563.563 0 0 1-.56-.619c.075-.779.647-1.409 1.277-2.038C9.644 6.708 9.66 6.387 9.678 6.048a1.447 1.447 0 0 0-.412-1.08 1.756 1.756 0 0 0-1.27-.54h-.002a1.682 1.682 0 0 0-1.677 1.68.562.562 0 1 1-1.125 0c0-.749.29-1.452.819-1.981a2.785 2.785 0 0 1 1.98-.824 2.887 2.887 0 0 1 2.09.89c.502.529.758 1.209.72 1.915-.039.723-.26 1.294-1.37 2.403-.562.562-.917.984-.953 1.355a.563.563 0 0 1-.56.507Zm-.697 1.646a.677.677 0 1 0 1.353 0 .677.677 0 0 0-1.353 0Z",
|
|
1375
|
+
"fill-rule": "nonzero"
|
|
1376
|
+
}
|
|
1377
|
+
})]);
|
|
1378
|
+
}, xe = {
|
|
1379
|
+
render: Jt
|
|
1380
|
+
}, ea = function() {
|
|
1381
|
+
return de({
|
|
1382
|
+
name: "IconHelpQuery",
|
|
1383
|
+
component: xe,
|
|
1384
|
+
filledComponent: xe
|
|
1385
|
+
})();
|
|
1386
|
+
}, ta = function() {
|
|
1387
|
+
var e = this, n = e.$createElement, s = e._self._c || n;
|
|
1388
|
+
return s("svg", e._g({
|
|
1389
|
+
staticStyle: {
|
|
1390
|
+
"enable-background": "new 0 0 16 16"
|
|
1391
|
+
},
|
|
1392
|
+
attrs: {
|
|
1393
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1394
|
+
viewBox: "0 0 16 16",
|
|
1395
|
+
"xml:space": "preserve"
|
|
1396
|
+
}
|
|
1397
|
+
}, e.$listeners), [s("rect", {
|
|
1398
|
+
staticStyle: {
|
|
1399
|
+
fill: "none"
|
|
1400
|
+
}
|
|
1401
|
+
}), s("path", {
|
|
1402
|
+
staticClass: "search_svg__st1",
|
|
1403
|
+
attrs: {
|
|
1404
|
+
d: "M7.22 1.67c3.04 0 5.5 2.46 5.5 5.5 0 1.33-.47 2.55-1.25 3.49l2.73 2.69c.19.19.19.51 0 .7s-.51.19-.7 0l-2.73-2.68c-.96.81-2.19 1.3-3.54 1.3-3.04 0-5.5-2.46-5.5-5.5s2.46-5.5 5.49-5.5zm0 1.01a4.5 4.5 0 1 0 0 9 4.5 4.5 0 0 0 0-9z"
|
|
1405
|
+
}
|
|
1406
|
+
})]);
|
|
1407
|
+
}, ye = {
|
|
1408
|
+
render: ta
|
|
1409
|
+
}, aa = function() {
|
|
1410
|
+
return de({
|
|
1411
|
+
name: "IconSearch",
|
|
1412
|
+
component: ye,
|
|
1413
|
+
filledComponent: ye
|
|
1414
|
+
})();
|
|
1415
|
+
}, na = function() {
|
|
1416
|
+
var a, e, n = this, s = n.$createElement, r = n._self._c || s;
|
|
1417
|
+
return r("div", {
|
|
1363
1418
|
attrs: {
|
|
1364
1419
|
tiny_mode: "pc"
|
|
1365
1420
|
}
|
|
1366
|
-
}, [
|
|
1421
|
+
}, [r("tiny-dropdown-item", {
|
|
1367
1422
|
directives: [{
|
|
1368
1423
|
name: "show",
|
|
1369
1424
|
rawName: "v-show",
|
|
@@ -1381,7 +1436,7 @@ var Wt = function() {
|
|
|
1381
1436
|
return n.selectInputValue(n.state.inputValue);
|
|
1382
1437
|
}
|
|
1383
1438
|
}
|
|
1384
|
-
}, [
|
|
1439
|
+
}, [r("span", [n._v(" " + n._s(n.t("tvp.tvpSearchbox.initUse")) + """ + n._s(n.state.inputValue) + """)])]), r("div", {
|
|
1385
1440
|
directives: [{
|
|
1386
1441
|
name: "show",
|
|
1387
1442
|
rawName: "v-show",
|
|
@@ -1389,13 +1444,13 @@ var Wt = function() {
|
|
|
1389
1444
|
expression: "!state.propItem.label && state.inputValue?.trim()"
|
|
1390
1445
|
}]
|
|
1391
1446
|
}, [n._l(n.state.matchItems, function(t, m) {
|
|
1392
|
-
return
|
|
1447
|
+
return r("div", {
|
|
1393
1448
|
key: m
|
|
1394
|
-
}, [t.attr.length ?
|
|
1449
|
+
}, [t.attr.length ? r("div", [r("span", {
|
|
1395
1450
|
staticClass: "tvp-search-box__filter-type"
|
|
1396
|
-
}, [n._v(n._s(m === "0" ? n.t("tvp.tvpSearchbox.attributeType") : m))]), n._l(t.attr, function(l,
|
|
1397
|
-
return
|
|
1398
|
-
key: l.label +
|
|
1451
|
+
}, [n._v(n._s(m === "0" ? n.t("tvp.tvpSearchbox.attributeType") : m))]), n._l(t.attr, function(l, o) {
|
|
1452
|
+
return r("tiny-dropdown-item", {
|
|
1453
|
+
key: l.label + o,
|
|
1399
1454
|
staticClass: "tvp-search-box__filter-item tvp-search-box__dropdown-item",
|
|
1400
1455
|
attrs: {
|
|
1401
1456
|
"item-data": l
|
|
@@ -1405,18 +1460,18 @@ var Wt = function() {
|
|
|
1405
1460
|
return n.selectPropItem(l);
|
|
1406
1461
|
}
|
|
1407
1462
|
}
|
|
1408
|
-
}, [
|
|
1409
|
-
return
|
|
1410
|
-
key:
|
|
1411
|
-
}, [
|
|
1463
|
+
}, [r("span", n._l(l.match, function(u) {
|
|
1464
|
+
return r("span", {
|
|
1465
|
+
key: u
|
|
1466
|
+
}, [u.toLowerCase() === l.hightlighStr ? r("span", {
|
|
1412
1467
|
staticClass: "tvp-search-box__text-highlight"
|
|
1413
|
-
}, [n._v(n._s(
|
|
1468
|
+
}, [n._v(n._s(u))]) : r("span", [n._v(n._s(u))])]);
|
|
1414
1469
|
}), 0)]);
|
|
1415
|
-
})], 2) : n._e(), t.attrValue.length ? [
|
|
1470
|
+
})], 2) : n._e(), t.attrValue.length ? [r("span", {
|
|
1416
1471
|
staticClass: "tvp-search-box__filter-type"
|
|
1417
|
-
}, [n._v(n._s(n.t("tvp.tvpSearchbox.propertyValue", [m === "0" ? n.t("tvp.tvpSearchbox.attributeType") : m])))]), n._l(t.attrValue, function(l,
|
|
1418
|
-
return
|
|
1419
|
-
key: l.label +
|
|
1472
|
+
}, [n._v(n._s(n.t("tvp.tvpSearchbox.propertyValue", [m === "0" ? n.t("tvp.tvpSearchbox.attributeType") : m])))]), n._l(t.attrValue, function(l, o) {
|
|
1473
|
+
return r("tiny-dropdown-item", {
|
|
1474
|
+
key: l.label + o,
|
|
1420
1475
|
staticClass: "tvp-search-box__filter-item tvp-search-box__dropdown-item",
|
|
1421
1476
|
attrs: {
|
|
1422
1477
|
disabled: l.isChecked,
|
|
@@ -1427,30 +1482,30 @@ var Wt = function() {
|
|
|
1427
1482
|
return n.selectRadioItem(l, !0);
|
|
1428
1483
|
}
|
|
1429
1484
|
}
|
|
1430
|
-
}, [
|
|
1431
|
-
return
|
|
1432
|
-
key:
|
|
1433
|
-
}, [
|
|
1485
|
+
}, [r("span", n._l(l.match, function(u) {
|
|
1486
|
+
return r("span", {
|
|
1487
|
+
key: u
|
|
1488
|
+
}, [u.toLowerCase() === l.hightlighStr ? r("span", {
|
|
1434
1489
|
staticClass: "tvp-search-box__text-highlight"
|
|
1435
|
-
}, [n._v(n._s(
|
|
1490
|
+
}, [n._v(n._s(u))]) : r("span", [n._v(n._s(u))])]);
|
|
1436
1491
|
}), 0)]);
|
|
1437
1492
|
})] : n._e()], 2);
|
|
1438
|
-
}),
|
|
1493
|
+
}), r("div", {
|
|
1439
1494
|
directives: [{
|
|
1440
1495
|
name: "show",
|
|
1441
1496
|
rawName: "v-show",
|
|
1442
1497
|
value: n.state.potentialOptions,
|
|
1443
1498
|
expression: "state.potentialOptions"
|
|
1444
1499
|
}]
|
|
1445
|
-
}, [
|
|
1500
|
+
}, [r("span", {
|
|
1446
1501
|
staticClass: "tvp-search-box__filter-type"
|
|
1447
|
-
}, [n._v(n._s(n.t("tvp.tvpSearchbox.matched")))]),
|
|
1502
|
+
}, [n._v(n._s(n.t("tvp.tvpSearchbox.matched")))]), r("div", {
|
|
1448
1503
|
staticClass: "tvp-search-box__potential-box",
|
|
1449
1504
|
attrs: {
|
|
1450
1505
|
id: "potential-loading"
|
|
1451
1506
|
}
|
|
1452
|
-
}, [n.state.potentialOptions ?
|
|
1453
|
-
return
|
|
1507
|
+
}, [n.state.potentialOptions ? r("div", n._l(n.state.potentialOptions, function(t, m) {
|
|
1508
|
+
return r("tiny-dropdown-item", {
|
|
1454
1509
|
key: t.label + m,
|
|
1455
1510
|
staticClass: "tvp-search-box__filter-item tvp-search-box__dropdown-item",
|
|
1456
1511
|
attrs: {
|
|
@@ -1461,10 +1516,10 @@ var Wt = function() {
|
|
|
1461
1516
|
return n.selectRadioItem(t, !0);
|
|
1462
1517
|
}
|
|
1463
1518
|
}
|
|
1464
|
-
}, [n._v(" " + n._s(t.label) + ": "),
|
|
1519
|
+
}, [n._v(" " + n._s(t.label) + ": "), r("span", {
|
|
1465
1520
|
staticClass: "tvp-search-box__text-highlight"
|
|
1466
1521
|
}, [n._v(n._s(t.value))])]);
|
|
1467
|
-
}), 1) : n._e()])])], 2),
|
|
1522
|
+
}), 1) : n._e()])])], 2), r("div", {
|
|
1468
1523
|
directives: [{
|
|
1469
1524
|
name: "show",
|
|
1470
1525
|
rawName: "v-show",
|
|
@@ -1473,13 +1528,13 @@ var Wt = function() {
|
|
|
1473
1528
|
}],
|
|
1474
1529
|
staticClass: "tvp-search-box__first-panel"
|
|
1475
1530
|
}, n._l(n.state.groupItems, function(t, m) {
|
|
1476
|
-
return
|
|
1531
|
+
return r("div", {
|
|
1477
1532
|
key: m
|
|
1478
|
-
}, [t.length ?
|
|
1533
|
+
}, [t.length ? r("span", {
|
|
1479
1534
|
staticClass: "tvp-search-box__filter-type"
|
|
1480
|
-
}, [n._v(n._s(m === "0" ? n.t("tvp.tvpSearchbox.attributeType") : m))]) : n._e(), n._l(t, function(l,
|
|
1481
|
-
return
|
|
1482
|
-
key: (l.field || l.label) +
|
|
1535
|
+
}, [n._v(n._s(m === "0" ? n.t("tvp.tvpSearchbox.attributeType") : m))]) : n._e(), n._l(t, function(l, o) {
|
|
1536
|
+
return r("tiny-dropdown-item", {
|
|
1537
|
+
key: (l.field || l.label) + o,
|
|
1483
1538
|
staticClass: "tvp-search-box__dropdown-item",
|
|
1484
1539
|
attrs: {
|
|
1485
1540
|
"item-data": l
|
|
@@ -1489,61 +1544,61 @@ var Wt = function() {
|
|
|
1489
1544
|
return n.selectPropItem(l);
|
|
1490
1545
|
}
|
|
1491
1546
|
}
|
|
1492
|
-
}, [
|
|
1547
|
+
}, [r("span", {
|
|
1493
1548
|
attrs: {
|
|
1494
1549
|
title: l.label
|
|
1495
1550
|
}
|
|
1496
1551
|
}, [n._v(n._s(l.label))])]);
|
|
1497
1552
|
})], 2);
|
|
1498
1553
|
}), 0)], 1);
|
|
1499
|
-
},
|
|
1500
|
-
function
|
|
1501
|
-
var
|
|
1502
|
-
e && (
|
|
1503
|
-
var
|
|
1504
|
-
if (m ? (
|
|
1554
|
+
}, sa = [];
|
|
1555
|
+
function be(a, e, n, s, r, t, m, l) {
|
|
1556
|
+
var o = typeof a == "function" ? a.options : a;
|
|
1557
|
+
e && (o.render = e, o.staticRenderFns = n, o._compiled = !0), s && (o.functional = !0), t && (o._scopeId = "data-v-" + t);
|
|
1558
|
+
var u;
|
|
1559
|
+
if (m ? (u = function(d) {
|
|
1505
1560
|
d = d || // cached call
|
|
1506
1561
|
this.$vnode && this.$vnode.ssrContext || // stateful
|
|
1507
|
-
this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext, !d && typeof __VUE_SSR_CONTEXT__ < "u" && (d = __VUE_SSR_CONTEXT__),
|
|
1508
|
-
},
|
|
1509
|
-
|
|
1562
|
+
this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext, !d && typeof __VUE_SSR_CONTEXT__ < "u" && (d = __VUE_SSR_CONTEXT__), r && r.call(this, d), d && d._registeredComponents && d._registeredComponents.add(m);
|
|
1563
|
+
}, o._ssrRegister = u) : r && (u = l ? function() {
|
|
1564
|
+
r.call(
|
|
1510
1565
|
this,
|
|
1511
|
-
(
|
|
1566
|
+
(o.functional ? this.parent : this).$root.$options.shadowRoot
|
|
1512
1567
|
);
|
|
1513
|
-
} :
|
|
1514
|
-
if (
|
|
1515
|
-
|
|
1516
|
-
var
|
|
1517
|
-
|
|
1518
|
-
return
|
|
1568
|
+
} : r), u)
|
|
1569
|
+
if (o.functional) {
|
|
1570
|
+
o._injectStyles = u;
|
|
1571
|
+
var p = o.render;
|
|
1572
|
+
o.render = function(f, c) {
|
|
1573
|
+
return u.call(c), p(f, c);
|
|
1519
1574
|
};
|
|
1520
1575
|
} else {
|
|
1521
|
-
var i =
|
|
1522
|
-
|
|
1576
|
+
var i = o.beforeCreate;
|
|
1577
|
+
o.beforeCreate = i ? [].concat(i, u) : [u];
|
|
1523
1578
|
}
|
|
1524
1579
|
return {
|
|
1525
1580
|
exports: a,
|
|
1526
|
-
options:
|
|
1581
|
+
options: o
|
|
1527
1582
|
};
|
|
1528
1583
|
}
|
|
1529
|
-
const
|
|
1530
|
-
const
|
|
1531
|
-
n("events", l,
|
|
1584
|
+
const ra = (a, e, { emit: n }) => {
|
|
1585
|
+
const s = a.handleEvents || a.events || ((l, o, u) => {
|
|
1586
|
+
n("events", l, o, u);
|
|
1532
1587
|
});
|
|
1533
1588
|
return {
|
|
1534
1589
|
selectInputValue: (l) => {
|
|
1535
|
-
|
|
1590
|
+
s("selectInputValue", l);
|
|
1536
1591
|
},
|
|
1537
1592
|
selectPropItem: (l) => {
|
|
1538
|
-
|
|
1593
|
+
s("selectPropItem", l);
|
|
1539
1594
|
},
|
|
1540
|
-
selectRadioItem: (l,
|
|
1541
|
-
|
|
1595
|
+
selectRadioItem: (l, o) => {
|
|
1596
|
+
s("selectRadioItem", l, o);
|
|
1542
1597
|
},
|
|
1543
1598
|
t: L
|
|
1544
1599
|
};
|
|
1545
|
-
},
|
|
1546
|
-
name:
|
|
1600
|
+
}, oa = ["selectInputValue", "selectPropItem", "selectRadioItem", "t"], la = J({
|
|
1601
|
+
name: me + "SearchBoxFirstLevelPanel",
|
|
1547
1602
|
components: {
|
|
1548
1603
|
TinyDropdownItem: Ve
|
|
1549
1604
|
},
|
|
@@ -1566,58 +1621,58 @@ const Xt = (a, e, { emit: n }) => {
|
|
|
1566
1621
|
default: null
|
|
1567
1622
|
}
|
|
1568
1623
|
},
|
|
1569
|
-
emits: ["events"],
|
|
1624
|
+
emits: ["events", "click"],
|
|
1570
1625
|
setup(a, e) {
|
|
1571
|
-
return
|
|
1626
|
+
return fe({ props: a, context: e, renderless: ra, api: oa });
|
|
1572
1627
|
}
|
|
1573
|
-
}),
|
|
1574
|
-
var
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1628
|
+
}), we = {};
|
|
1629
|
+
var ia = /* @__PURE__ */ be(
|
|
1630
|
+
la,
|
|
1631
|
+
na,
|
|
1632
|
+
sa,
|
|
1578
1633
|
!1,
|
|
1579
|
-
|
|
1634
|
+
ca,
|
|
1580
1635
|
null,
|
|
1581
1636
|
null,
|
|
1582
1637
|
null
|
|
1583
1638
|
);
|
|
1584
|
-
function
|
|
1585
|
-
for (let e in
|
|
1586
|
-
this[e] =
|
|
1639
|
+
function ca(a) {
|
|
1640
|
+
for (let e in we)
|
|
1641
|
+
this[e] = we[e];
|
|
1587
1642
|
}
|
|
1588
|
-
const
|
|
1589
|
-
return
|
|
1643
|
+
const ua = /* @__PURE__ */ function() {
|
|
1644
|
+
return ia.exports;
|
|
1590
1645
|
}();
|
|
1591
|
-
var
|
|
1592
|
-
var a, e = this, n = e.$createElement,
|
|
1593
|
-
return
|
|
1646
|
+
var pa = function() {
|
|
1647
|
+
var a, e = this, n = e.$createElement, s = e._self._c || n;
|
|
1648
|
+
return s("div", {
|
|
1594
1649
|
attrs: {
|
|
1595
1650
|
tiny_mode: "pc"
|
|
1596
1651
|
}
|
|
1597
|
-
}, [(a = e.state.currentOperators) !== null && a !== void 0 && a.length ?
|
|
1652
|
+
}, [(a = e.state.currentOperators) !== null && a !== void 0 && a.length ? s("div", [s("span", {
|
|
1598
1653
|
staticClass: "tvp-search-box__filter-type"
|
|
1599
|
-
}, [e._v(e._s(e.t("tvp.tvpSearchbox.operator")))]), e._l(e.state.currentOperators, function(
|
|
1600
|
-
return
|
|
1654
|
+
}, [e._v(e._s(e.t("tvp.tvpSearchbox.operator")))]), e._l(e.state.currentOperators, function(r, t) {
|
|
1655
|
+
return s("tiny-dropdown-item", {
|
|
1601
1656
|
directives: [{
|
|
1602
1657
|
name: "show",
|
|
1603
1658
|
rawName: "v-show",
|
|
1604
|
-
value:
|
|
1659
|
+
value: r.includes(e.state.inputValue),
|
|
1605
1660
|
expression: "item.includes(state.inputValue)"
|
|
1606
1661
|
}],
|
|
1607
|
-
key:
|
|
1662
|
+
key: r + t,
|
|
1608
1663
|
staticClass: "tvp-search-box__dropdown-item",
|
|
1609
1664
|
attrs: {
|
|
1610
1665
|
"item-data": {
|
|
1611
|
-
label:
|
|
1666
|
+
label: r
|
|
1612
1667
|
}
|
|
1613
1668
|
},
|
|
1614
1669
|
on: {
|
|
1615
1670
|
"item-click": function() {
|
|
1616
|
-
return e.setOperator(
|
|
1671
|
+
return e.setOperator(r);
|
|
1617
1672
|
}
|
|
1618
1673
|
}
|
|
1619
|
-
}, [e._v(" " + e._s(
|
|
1620
|
-
})], 2) : !e.state.prevItem.type || e.state.prevItem.type === "radio" ?
|
|
1674
|
+
}, [e._v(" " + e._s(r) + " ")]);
|
|
1675
|
+
})], 2) : !e.state.prevItem.type || e.state.prevItem.type === "radio" ? s("div", {
|
|
1621
1676
|
directives: [{
|
|
1622
1677
|
name: "loading",
|
|
1623
1678
|
rawName: "v-loading",
|
|
@@ -1625,41 +1680,41 @@ var ra = function() {
|
|
|
1625
1680
|
expression: "isLoading"
|
|
1626
1681
|
}],
|
|
1627
1682
|
class: ["tvp-search-box__radio-wrap", e.isLoading && "tvp-search-box__loading-box"]
|
|
1628
|
-
}, e._l(e.state.backupList, function(
|
|
1629
|
-
return
|
|
1683
|
+
}, e._l(e.state.backupList, function(r, t) {
|
|
1684
|
+
return s("tiny-dropdown-item", {
|
|
1630
1685
|
directives: [{
|
|
1631
1686
|
name: "show",
|
|
1632
1687
|
rawName: "v-show",
|
|
1633
|
-
value: !
|
|
1688
|
+
value: !r.isFilter || !e.state.inputValue,
|
|
1634
1689
|
expression: "!item.isFilter || !state.inputValue"
|
|
1635
1690
|
}],
|
|
1636
|
-
key: t + (
|
|
1691
|
+
key: t + (r.field || r.label),
|
|
1637
1692
|
staticClass: "tvp-search-box__dropdown-item",
|
|
1638
1693
|
attrs: {
|
|
1639
|
-
disabled:
|
|
1640
|
-
"item-data":
|
|
1694
|
+
disabled: r.isChecked,
|
|
1695
|
+
"item-data": r
|
|
1641
1696
|
},
|
|
1642
1697
|
on: {
|
|
1643
1698
|
"item-click": function() {
|
|
1644
|
-
return e.selectRadioItem(
|
|
1699
|
+
return e.selectRadioItem(r);
|
|
1645
1700
|
}
|
|
1646
1701
|
}
|
|
1647
|
-
}, [
|
|
1702
|
+
}, [r.match ? s("span", {
|
|
1648
1703
|
attrs: {
|
|
1649
|
-
title:
|
|
1704
|
+
title: r.label
|
|
1650
1705
|
}
|
|
1651
|
-
}, e._l(
|
|
1652
|
-
return
|
|
1706
|
+
}, e._l(r.match, function(m) {
|
|
1707
|
+
return s("span", {
|
|
1653
1708
|
key: m
|
|
1654
|
-
}, [m.toLowerCase() ===
|
|
1709
|
+
}, [m.toLowerCase() === r.hightlighStr ? s("span", {
|
|
1655
1710
|
staticClass: "tvp-search-box__text-highlight"
|
|
1656
|
-
}, [e._v(e._s(m))]) :
|
|
1657
|
-
}), 0) :
|
|
1711
|
+
}, [e._v(e._s(m))]) : s("span", [e._v(e._s(m))])]);
|
|
1712
|
+
}), 0) : s("span", {
|
|
1658
1713
|
attrs: {
|
|
1659
|
-
title:
|
|
1714
|
+
title: r.label
|
|
1660
1715
|
}
|
|
1661
|
-
}, [e._v(e._s(
|
|
1662
|
-
}), 1) : e.state.prevItem.type === "checkbox" ?
|
|
1716
|
+
}, [e._v(e._s(r.label))])]);
|
|
1717
|
+
}), 1) : e.state.prevItem.type === "checkbox" ? s("div", {
|
|
1663
1718
|
directives: [{
|
|
1664
1719
|
name: "loading",
|
|
1665
1720
|
rawName: "v-loading",
|
|
@@ -1667,158 +1722,158 @@ var ra = function() {
|
|
|
1667
1722
|
expression: "isLoading"
|
|
1668
1723
|
}],
|
|
1669
1724
|
class: e.isLoading && "tvp-search-box__loading-box"
|
|
1670
|
-
}, [e.showCheckBoxList ?
|
|
1725
|
+
}, [e.showCheckBoxList ? s("div", [s("div", {
|
|
1671
1726
|
staticClass: "tvp-search-box__checkbox-wrap"
|
|
1672
|
-
}, [
|
|
1727
|
+
}, [s("tiny-checkbox-group", {
|
|
1673
1728
|
staticClass: "tvp-search-box__checkbox",
|
|
1674
1729
|
model: {
|
|
1675
1730
|
value: e.state.checkAll,
|
|
1676
|
-
callback: function(
|
|
1677
|
-
e.$set(e.state, "checkAll",
|
|
1731
|
+
callback: function(r) {
|
|
1732
|
+
e.$set(e.state, "checkAll", r);
|
|
1678
1733
|
},
|
|
1679
1734
|
expression: "state.checkAll"
|
|
1680
1735
|
}
|
|
1681
|
-
}, [
|
|
1736
|
+
}, [s("tiny-dropdown-item", {
|
|
1682
1737
|
staticClass: "tvp-search-box__dropdown-item tvp-search-box__checkbox-item"
|
|
1683
|
-
}, [
|
|
1738
|
+
}, [s("tiny-checkbox", {
|
|
1684
1739
|
attrs: {
|
|
1685
1740
|
indeterminate: e.state.isIndeterminate
|
|
1686
1741
|
},
|
|
1687
1742
|
model: {
|
|
1688
1743
|
value: e.state.checkAll,
|
|
1689
|
-
callback: function(
|
|
1690
|
-
e.$set(e.state, "checkAll",
|
|
1744
|
+
callback: function(r) {
|
|
1745
|
+
e.$set(e.state, "checkAll", r);
|
|
1691
1746
|
},
|
|
1692
1747
|
expression: "state.checkAll"
|
|
1693
1748
|
}
|
|
1694
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.selectAll")) + " ")])], 1)], 1),
|
|
1749
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.selectAll")) + " ")])], 1)], 1), s("tiny-checkbox-group", {
|
|
1695
1750
|
staticClass: "tvp-search-box__checkbox",
|
|
1696
1751
|
model: {
|
|
1697
1752
|
value: e.state.checkboxGroup,
|
|
1698
|
-
callback: function(
|
|
1699
|
-
e.$set(e.state, "checkboxGroup",
|
|
1753
|
+
callback: function(r) {
|
|
1754
|
+
e.$set(e.state, "checkboxGroup", r);
|
|
1700
1755
|
},
|
|
1701
1756
|
expression: "state.checkboxGroup"
|
|
1702
1757
|
}
|
|
1703
|
-
}, e._l(e.state.backupList, function(
|
|
1704
|
-
return
|
|
1758
|
+
}, e._l(e.state.backupList, function(r, t) {
|
|
1759
|
+
return s("tiny-dropdown-item", {
|
|
1705
1760
|
directives: [{
|
|
1706
1761
|
name: "show",
|
|
1707
1762
|
rawName: "v-show",
|
|
1708
|
-
value: !
|
|
1763
|
+
value: !r.isFilter,
|
|
1709
1764
|
expression: "!item.isFilter"
|
|
1710
1765
|
}],
|
|
1711
|
-
key: (
|
|
1766
|
+
key: (r.field || r.label) + t,
|
|
1712
1767
|
staticClass: "tvp-search-box__dropdown-item tvp-search-box__checkbox-item"
|
|
1713
|
-
}, [
|
|
1768
|
+
}, [s("tiny-checkbox", {
|
|
1714
1769
|
staticClass: "tvp-search-box__checkbox-item-label",
|
|
1715
1770
|
attrs: {
|
|
1716
|
-
label: e.state.prevItem.label +
|
|
1717
|
-
title:
|
|
1771
|
+
label: e.state.prevItem.label + r.label,
|
|
1772
|
+
title: r.label
|
|
1718
1773
|
}
|
|
1719
|
-
}, [e._v(" " + e._s(
|
|
1720
|
-
}), 1)], 1),
|
|
1774
|
+
}, [e._v(" " + e._s(r.label) + " ")])], 1);
|
|
1775
|
+
}), 1)], 1), s("div", {
|
|
1721
1776
|
staticClass: "tvp-search-box__checkbox-btn"
|
|
1722
|
-
}, [
|
|
1777
|
+
}, [s("tiny-button", {
|
|
1723
1778
|
attrs: {
|
|
1724
1779
|
size: "mini"
|
|
1725
1780
|
},
|
|
1726
1781
|
on: {
|
|
1727
|
-
click: function(
|
|
1782
|
+
click: function(r) {
|
|
1728
1783
|
return e.selectCheckbox(!1);
|
|
1729
1784
|
}
|
|
1730
1785
|
}
|
|
1731
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.cancel")) + " ")]),
|
|
1786
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.cancel")) + " ")]), s("tiny-button", {
|
|
1732
1787
|
attrs: {
|
|
1733
1788
|
size: "mini"
|
|
1734
1789
|
},
|
|
1735
1790
|
on: {
|
|
1736
|
-
click: function(
|
|
1791
|
+
click: function(r) {
|
|
1737
1792
|
return e.selectCheckbox(!0);
|
|
1738
1793
|
}
|
|
1739
1794
|
}
|
|
1740
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.confirm")) + " ")])], 1)]) : e._e()]) : e.state.prevItem.type === "numRange" ?
|
|
1795
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.confirm")) + " ")])], 1)]) : e._e()]) : e.state.prevItem.type === "numRange" ? s("div", {
|
|
1741
1796
|
staticClass: "tvp-search-box__panel-box"
|
|
1742
|
-
}, [
|
|
1797
|
+
}, [s("div", {
|
|
1743
1798
|
staticClass: "tvp-search-box__number"
|
|
1744
|
-
}, [
|
|
1799
|
+
}, [s("div", {
|
|
1745
1800
|
staticClass: "tvp-search-box__dropdown-title"
|
|
1746
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeNumberTitle")) + " ")]),
|
|
1801
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeNumberTitle")) + " ")]), s("div", {
|
|
1747
1802
|
staticClass: "tvp-search-box__dropdown-start"
|
|
1748
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.minValueText")) + "(" + e._s(e.state.prevItem.unit) + ") ")]),
|
|
1803
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.minValueText")) + "(" + e._s(e.state.prevItem.unit) + ") ")]), s("tiny-form-item", {
|
|
1749
1804
|
staticClass: "tvp-search-box__number-item",
|
|
1750
1805
|
attrs: {
|
|
1751
1806
|
prop: e.state.curMinNumVar,
|
|
1752
1807
|
"show-message": e.state.numberShowMessage
|
|
1753
1808
|
}
|
|
1754
|
-
}, [
|
|
1809
|
+
}, [s("tiny-input", {
|
|
1755
1810
|
staticClass: "tvp-search-box__number-input",
|
|
1756
1811
|
attrs: {
|
|
1757
1812
|
type: "number"
|
|
1758
1813
|
},
|
|
1759
1814
|
model: {
|
|
1760
1815
|
value: e.state[e.state.curMinNumVar],
|
|
1761
|
-
callback: function(
|
|
1762
|
-
e.$set(e.state, e.state.curMinNumVar,
|
|
1816
|
+
callback: function(r) {
|
|
1817
|
+
e.$set(e.state, e.state.curMinNumVar, r);
|
|
1763
1818
|
},
|
|
1764
1819
|
expression: "state[state.curMinNumVar]"
|
|
1765
1820
|
}
|
|
1766
|
-
})], 1),
|
|
1821
|
+
})], 1), s("div", {
|
|
1767
1822
|
staticClass: "tvp-search-box__dropdown-end"
|
|
1768
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.maxValueText")) + "(" + e._s(e.state.prevItem.unit) + ") ")]),
|
|
1823
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.maxValueText")) + "(" + e._s(e.state.prevItem.unit) + ") ")]), s("tiny-form-item", {
|
|
1769
1824
|
staticClass: "tvp-search-box__number-item",
|
|
1770
1825
|
attrs: {
|
|
1771
1826
|
prop: e.state.curMaxNumVar
|
|
1772
1827
|
}
|
|
1773
|
-
}, [
|
|
1828
|
+
}, [s("tiny-input", {
|
|
1774
1829
|
staticClass: "tvp-search-box__number-input",
|
|
1775
1830
|
attrs: {
|
|
1776
1831
|
type: "number"
|
|
1777
1832
|
},
|
|
1778
1833
|
model: {
|
|
1779
1834
|
value: e.state[e.state.curMaxNumVar],
|
|
1780
|
-
callback: function(
|
|
1781
|
-
e.$set(e.state, e.state.curMaxNumVar,
|
|
1835
|
+
callback: function(r) {
|
|
1836
|
+
e.$set(e.state, e.state.curMaxNumVar, r);
|
|
1782
1837
|
},
|
|
1783
1838
|
expression: "state[state.curMaxNumVar]"
|
|
1784
1839
|
}
|
|
1785
|
-
})], 1)], 1),
|
|
1840
|
+
})], 1)], 1), s("div", {
|
|
1786
1841
|
staticClass: "tvp-search-box__bottom-btn"
|
|
1787
|
-
}, [
|
|
1842
|
+
}, [s("tiny-button", {
|
|
1788
1843
|
attrs: {
|
|
1789
1844
|
size: "mini"
|
|
1790
1845
|
},
|
|
1791
1846
|
on: {
|
|
1792
|
-
click: function(
|
|
1847
|
+
click: function(r) {
|
|
1793
1848
|
return e.sizeChange(!1);
|
|
1794
1849
|
}
|
|
1795
1850
|
}
|
|
1796
|
-
}, [e._v(e._s(e.t("tvp.tvpSearchbox.cancel")))]),
|
|
1851
|
+
}, [e._v(e._s(e.t("tvp.tvpSearchbox.cancel")))]), s("tiny-button", {
|
|
1797
1852
|
attrs: {
|
|
1798
1853
|
size: "mini"
|
|
1799
1854
|
},
|
|
1800
1855
|
on: {
|
|
1801
|
-
click: function(
|
|
1802
|
-
return
|
|
1856
|
+
click: function(r) {
|
|
1857
|
+
return r.stopPropagation(), e.sizeChange(!0);
|
|
1803
1858
|
}
|
|
1804
1859
|
}
|
|
1805
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.confirm")) + " ")])], 1)]) : e.state.prevItem.type === "dateRange" ?
|
|
1860
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.confirm")) + " ")])], 1)]) : e.state.prevItem.type === "dateRange" ? s("div", {
|
|
1806
1861
|
staticClass: "tvp-search-box__panel-box"
|
|
1807
|
-
}, [
|
|
1862
|
+
}, [s("div", {
|
|
1808
1863
|
staticClass: "tvp-search-box__date-wrap"
|
|
1809
|
-
}, [
|
|
1864
|
+
}, [s("div", {
|
|
1810
1865
|
staticClass: "tvp-search-box__dropdown-title"
|
|
1811
1866
|
}, [e._v(" " + e._s(e.state.prevItem.maxTimeLength > 0 ? e.t("tvp.tvpSearchbox.timeLengthTitle", {
|
|
1812
1867
|
value: (e.state.prevItem.maxTimeLength / 864e5).toFixed(1)
|
|
1813
|
-
}) : e.t("tvp.tvpSearchbox.rangeDateTitle")) + " ")]),
|
|
1868
|
+
}) : e.t("tvp.tvpSearchbox.rangeDateTitle")) + " ")]), s("div", {
|
|
1814
1869
|
staticClass: "tvp-search-box__dropdown-start"
|
|
1815
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeBeginLabel")) + " ")]),
|
|
1870
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeBeginLabel")) + " ")]), s("tiny-form-item", {
|
|
1816
1871
|
staticClass: "tvp-search-box__date-item",
|
|
1817
1872
|
attrs: {
|
|
1818
1873
|
prop: "startDate",
|
|
1819
1874
|
"show-message": !!e.state.prevItem.maxTimeLength
|
|
1820
1875
|
}
|
|
1821
|
-
}, [
|
|
1876
|
+
}, [s("tiny-date-picker", {
|
|
1822
1877
|
staticClass: "tvp-search-box__date-picker",
|
|
1823
1878
|
attrs: {
|
|
1824
1879
|
format: e.state.prevItem.format || e.state.dateRangeFormat,
|
|
@@ -1830,19 +1885,19 @@ var ra = function() {
|
|
|
1830
1885
|
},
|
|
1831
1886
|
model: {
|
|
1832
1887
|
value: e.state.startDate,
|
|
1833
|
-
callback: function(
|
|
1834
|
-
e.$set(e.state, "startDate",
|
|
1888
|
+
callback: function(r) {
|
|
1889
|
+
e.$set(e.state, "startDate", r);
|
|
1835
1890
|
},
|
|
1836
1891
|
expression: "state.startDate"
|
|
1837
1892
|
}
|
|
1838
|
-
})], 1),
|
|
1893
|
+
})], 1), s("div", {
|
|
1839
1894
|
staticClass: "tvp-search-box__dropdown-end"
|
|
1840
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeEndLabel")) + " ")]),
|
|
1895
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeEndLabel")) + " ")]), s("tiny-form-item", {
|
|
1841
1896
|
staticClass: "tvp-search-box__date-item",
|
|
1842
1897
|
attrs: {
|
|
1843
1898
|
prop: "endDate"
|
|
1844
1899
|
}
|
|
1845
|
-
}, [
|
|
1900
|
+
}, [s("tiny-date-picker", {
|
|
1846
1901
|
staticClass: "tvp-search-box__date-picker",
|
|
1847
1902
|
attrs: {
|
|
1848
1903
|
format: e.state.prevItem.format || e.state.dateRangeFormat,
|
|
@@ -1855,48 +1910,48 @@ var ra = function() {
|
|
|
1855
1910
|
},
|
|
1856
1911
|
model: {
|
|
1857
1912
|
value: e.state.endDate,
|
|
1858
|
-
callback: function(
|
|
1859
|
-
e.$set(e.state, "endDate",
|
|
1913
|
+
callback: function(r) {
|
|
1914
|
+
e.$set(e.state, "endDate", r);
|
|
1860
1915
|
},
|
|
1861
1916
|
expression: "state.endDate"
|
|
1862
1917
|
}
|
|
1863
|
-
})], 1)], 1),
|
|
1918
|
+
})], 1)], 1), s("div", {
|
|
1864
1919
|
staticClass: "tvp-search-box__bottom-btn"
|
|
1865
|
-
}, [
|
|
1920
|
+
}, [s("tiny-button", {
|
|
1866
1921
|
attrs: {
|
|
1867
1922
|
size: "mini"
|
|
1868
1923
|
},
|
|
1869
1924
|
on: {
|
|
1870
|
-
click: function(
|
|
1925
|
+
click: function(r) {
|
|
1871
1926
|
return e.onConfirmDate(!1);
|
|
1872
1927
|
}
|
|
1873
1928
|
}
|
|
1874
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.cancel")) + " ")]),
|
|
1929
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.cancel")) + " ")]), s("tiny-button", {
|
|
1875
1930
|
attrs: {
|
|
1876
1931
|
size: "mini"
|
|
1877
1932
|
},
|
|
1878
1933
|
on: {
|
|
1879
|
-
click: function(
|
|
1934
|
+
click: function(r) {
|
|
1880
1935
|
return e.onConfirmDate(!0);
|
|
1881
1936
|
}
|
|
1882
1937
|
}
|
|
1883
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.confirm")) + " ")])], 1)]) : e.state.prevItem.type === "datetimeRange" ?
|
|
1938
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.confirm")) + " ")])], 1)]) : e.state.prevItem.type === "datetimeRange" ? s("div", {
|
|
1884
1939
|
staticClass: "tvp-search-box__panel-box"
|
|
1885
|
-
}, [
|
|
1940
|
+
}, [s("div", {
|
|
1886
1941
|
staticClass: "tvp-search-box__date-wrap"
|
|
1887
|
-
}, [
|
|
1942
|
+
}, [s("div", {
|
|
1888
1943
|
staticClass: "tvp-search-box__dropdown-title"
|
|
1889
1944
|
}, [e._v(" " + e._s(e.state.prevItem.maxTimeLength > 0 ? e.t("tvp.tvpSearchbox.timeLengthTitle", {
|
|
1890
1945
|
value: (e.state.prevItem.maxTimeLength / 864e5).toFixed(1)
|
|
1891
|
-
}) : e.t("tvp.tvpSearchbox.rangeDateTitle")) + " ")]),
|
|
1946
|
+
}) : e.t("tvp.tvpSearchbox.rangeDateTitle")) + " ")]), s("div", {
|
|
1892
1947
|
staticClass: "tvp-search-box__dropdown-start"
|
|
1893
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeBeginLabel")) + " ")]),
|
|
1948
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeBeginLabel")) + " ")]), s("tiny-form-item", {
|
|
1894
1949
|
staticClass: "tvp-search-box__date-item",
|
|
1895
1950
|
attrs: {
|
|
1896
1951
|
prop: "startDateTime",
|
|
1897
1952
|
"show-message": !!e.state.prevItem.maxTimeLength
|
|
1898
1953
|
}
|
|
1899
|
-
}, [
|
|
1954
|
+
}, [s("tiny-date-picker", {
|
|
1900
1955
|
staticClass: "tvp-search-box__date-picker",
|
|
1901
1956
|
attrs: {
|
|
1902
1957
|
type: "datetime",
|
|
@@ -1911,19 +1966,19 @@ var ra = function() {
|
|
|
1911
1966
|
},
|
|
1912
1967
|
model: {
|
|
1913
1968
|
value: e.state.startDateTime,
|
|
1914
|
-
callback: function(
|
|
1915
|
-
e.$set(e.state, "startDateTime",
|
|
1969
|
+
callback: function(r) {
|
|
1970
|
+
e.$set(e.state, "startDateTime", r);
|
|
1916
1971
|
},
|
|
1917
1972
|
expression: "state.startDateTime"
|
|
1918
1973
|
}
|
|
1919
|
-
})], 1),
|
|
1974
|
+
})], 1), s("div", {
|
|
1920
1975
|
staticClass: "tvp-search-box__dropdown-end"
|
|
1921
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeEndLabel")) + " ")]),
|
|
1976
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.rangeEndLabel")) + " ")]), s("tiny-form-item", {
|
|
1922
1977
|
staticClass: "tvp-search-box__date-item",
|
|
1923
1978
|
attrs: {
|
|
1924
1979
|
prop: "endDateTime"
|
|
1925
1980
|
}
|
|
1926
|
-
}, [
|
|
1981
|
+
}, [s("tiny-date-picker", {
|
|
1927
1982
|
staticClass: "tvp-search-box__date-picker",
|
|
1928
1983
|
attrs: {
|
|
1929
1984
|
type: "datetime",
|
|
@@ -1938,105 +1993,105 @@ var ra = function() {
|
|
|
1938
1993
|
},
|
|
1939
1994
|
model: {
|
|
1940
1995
|
value: e.state.endDateTime,
|
|
1941
|
-
callback: function(
|
|
1942
|
-
e.$set(e.state, "endDateTime",
|
|
1996
|
+
callback: function(r) {
|
|
1997
|
+
e.$set(e.state, "endDateTime", r);
|
|
1943
1998
|
},
|
|
1944
1999
|
expression: "state.endDateTime"
|
|
1945
2000
|
}
|
|
1946
|
-
})], 1)], 1),
|
|
2001
|
+
})], 1)], 1), s("div", {
|
|
1947
2002
|
staticClass: "tvp-search-box__bottom-btn"
|
|
1948
|
-
}, [
|
|
2003
|
+
}, [s("tiny-button", {
|
|
1949
2004
|
attrs: {
|
|
1950
2005
|
size: "mini"
|
|
1951
2006
|
},
|
|
1952
2007
|
on: {
|
|
1953
|
-
click: function(
|
|
2008
|
+
click: function(r) {
|
|
1954
2009
|
return e.onConfirmDate(!1, !0);
|
|
1955
2010
|
}
|
|
1956
2011
|
}
|
|
1957
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.cancel")) + " ")]),
|
|
2012
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.cancel")) + " ")]), s("tiny-button", {
|
|
1958
2013
|
attrs: {
|
|
1959
2014
|
size: "mini"
|
|
1960
2015
|
},
|
|
1961
2016
|
on: {
|
|
1962
|
-
click: function(
|
|
2017
|
+
click: function(r) {
|
|
1963
2018
|
return e.onConfirmDate(!0, !0);
|
|
1964
2019
|
}
|
|
1965
2020
|
}
|
|
1966
|
-
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.confirm")) + " ")])], 1)]) : e.state.prevItem.type === "map" ?
|
|
2021
|
+
}, [e._v(" " + e._s(e.t("tvp.tvpSearchbox.confirm")) + " ")])], 1)]) : e.state.prevItem.type === "map" ? s("div", {
|
|
1967
2022
|
directives: [{
|
|
1968
2023
|
name: "loading",
|
|
1969
2024
|
rawName: "v-loading",
|
|
1970
2025
|
value: e.isLoading,
|
|
1971
2026
|
expression: "isLoading"
|
|
1972
2027
|
}]
|
|
1973
|
-
}, [e.state.isShowTagKey ?
|
|
2028
|
+
}, [e.state.isShowTagKey ? s("span", {
|
|
1974
2029
|
staticClass: "tvp-search-box__filter-type"
|
|
1975
|
-
}, [e._v(e._s(e.t("tvp.tvpSearchbox.tagKey")))]) :
|
|
2030
|
+
}, [e._v(e._s(e.t("tvp.tvpSearchbox.tagKey")))]) : s("span", {
|
|
1976
2031
|
staticClass: "tvp-search-box__filter-type"
|
|
1977
|
-
}, [e._v(e._s(e.t("tvp.tvpSearchbox.tagValue")))]), e._l(e.state.backupList, function(
|
|
1978
|
-
return
|
|
2032
|
+
}, [e._v(e._s(e.t("tvp.tvpSearchbox.tagValue")))]), e._l(e.state.backupList, function(r, t) {
|
|
2033
|
+
return s("tiny-dropdown-item", {
|
|
1979
2034
|
directives: [{
|
|
1980
2035
|
name: "show",
|
|
1981
2036
|
rawName: "v-show",
|
|
1982
|
-
value: !
|
|
2037
|
+
value: !r.isFilter,
|
|
1983
2038
|
expression: "!item.isFilter"
|
|
1984
2039
|
}],
|
|
1985
|
-
key:
|
|
2040
|
+
key: r.label + r.value + t,
|
|
1986
2041
|
staticClass: "tvp-search-box__dropdown-item",
|
|
1987
2042
|
attrs: {
|
|
1988
|
-
disabled:
|
|
1989
|
-
"item-data":
|
|
2043
|
+
disabled: r.isChecked,
|
|
2044
|
+
"item-data": r
|
|
1990
2045
|
},
|
|
1991
2046
|
on: {
|
|
1992
2047
|
"item-click": function() {
|
|
1993
|
-
return e.selectFirstMap(
|
|
2048
|
+
return e.selectFirstMap(r, e.state.isShowTagKey);
|
|
1994
2049
|
}
|
|
1995
2050
|
}
|
|
1996
|
-
}, [
|
|
2051
|
+
}, [s("span", {
|
|
1997
2052
|
attrs: {
|
|
1998
|
-
title:
|
|
2053
|
+
title: r.label
|
|
1999
2054
|
}
|
|
2000
|
-
}, [e._v(e._s(
|
|
2055
|
+
}, [e._v(e._s(r.label))])]);
|
|
2001
2056
|
})], 2) : e._e()]);
|
|
2002
|
-
},
|
|
2003
|
-
const
|
|
2004
|
-
const { computed:
|
|
2005
|
-
n("events", c,
|
|
2057
|
+
}, da = [];
|
|
2058
|
+
const ma = (a, e, { emit: n }) => {
|
|
2059
|
+
const { computed: s } = e, r = a.handleEvents || a.events || ((c, v, h) => {
|
|
2060
|
+
n("events", c, v, h);
|
|
2006
2061
|
}), t = (c) => {
|
|
2007
|
-
|
|
2062
|
+
r("setOperator", c);
|
|
2008
2063
|
}, m = (c) => {
|
|
2009
|
-
|
|
2064
|
+
r("selectRadioItem", c);
|
|
2010
2065
|
}, l = (c) => {
|
|
2011
|
-
|
|
2012
|
-
},
|
|
2013
|
-
|
|
2014
|
-
},
|
|
2015
|
-
|
|
2016
|
-
},
|
|
2017
|
-
|
|
2066
|
+
r("selectCheckbox", c);
|
|
2067
|
+
}, o = (c) => {
|
|
2068
|
+
r("sizeChange", c);
|
|
2069
|
+
}, u = (c, v) => {
|
|
2070
|
+
r("onConfirmDate", c, v);
|
|
2071
|
+
}, p = (c, v) => {
|
|
2072
|
+
r("selectFirstMap", c, v);
|
|
2018
2073
|
}, i = (c) => {
|
|
2019
|
-
|
|
2020
|
-
}, d =
|
|
2074
|
+
r("handleDateShow", c);
|
|
2075
|
+
}, d = s(() => {
|
|
2021
2076
|
var c;
|
|
2022
2077
|
return a.state.hasBackupList && ((c = a.state.backupList) == null ? void 0 : c.length) === 0;
|
|
2023
|
-
}), f =
|
|
2078
|
+
}), f = s(() => {
|
|
2024
2079
|
var c;
|
|
2025
|
-
return (c = a.state.backupList) == null ? void 0 : c.find((
|
|
2080
|
+
return (c = a.state.backupList) == null ? void 0 : c.find((v) => !v.isFilter);
|
|
2026
2081
|
});
|
|
2027
2082
|
return {
|
|
2028
2083
|
setOperator: t,
|
|
2029
2084
|
selectRadioItem: m,
|
|
2030
2085
|
selectCheckbox: l,
|
|
2031
|
-
sizeChange:
|
|
2032
|
-
onConfirmDate:
|
|
2033
|
-
selectFirstMap:
|
|
2086
|
+
sizeChange: o,
|
|
2087
|
+
onConfirmDate: u,
|
|
2088
|
+
selectFirstMap: p,
|
|
2034
2089
|
handleDateShow: i,
|
|
2035
2090
|
isLoading: d,
|
|
2036
2091
|
showCheckBoxList: f,
|
|
2037
2092
|
t: L
|
|
2038
2093
|
};
|
|
2039
|
-
},
|
|
2094
|
+
}, fa = [
|
|
2040
2095
|
"setOperator",
|
|
2041
2096
|
"selectRadioItem",
|
|
2042
2097
|
"selectCheckbox",
|
|
@@ -2047,20 +2102,20 @@ const sa = (a, e, { emit: n }) => {
|
|
|
2047
2102
|
"isLoading",
|
|
2048
2103
|
"showCheckBoxList",
|
|
2049
2104
|
"t"
|
|
2050
|
-
],
|
|
2051
|
-
name:
|
|
2052
|
-
emits: ["events"],
|
|
2105
|
+
], ha = J({
|
|
2106
|
+
name: me + "SearchBoxSecondLevelPanel",
|
|
2107
|
+
emits: ["events", "click"],
|
|
2053
2108
|
components: {
|
|
2054
|
-
TinyFormItem:
|
|
2109
|
+
TinyFormItem: Ce,
|
|
2055
2110
|
TinyDropdownItem: Ve,
|
|
2056
|
-
TinyCheckbox:
|
|
2057
|
-
TinyCheckboxGroup:
|
|
2058
|
-
TinyDatePicker:
|
|
2059
|
-
TinyInput:
|
|
2060
|
-
TinyButton:
|
|
2111
|
+
TinyCheckbox: Ge,
|
|
2112
|
+
TinyCheckboxGroup: Ke,
|
|
2113
|
+
TinyDatePicker: Te,
|
|
2114
|
+
TinyInput: Se,
|
|
2115
|
+
TinyButton: De
|
|
2061
2116
|
},
|
|
2062
2117
|
directives: {
|
|
2063
|
-
loading:
|
|
2118
|
+
loading: Ue.directive
|
|
2064
2119
|
},
|
|
2065
2120
|
props: {
|
|
2066
2121
|
...ee,
|
|
@@ -2083,27 +2138,27 @@ const sa = (a, e, { emit: n }) => {
|
|
|
2083
2138
|
}
|
|
2084
2139
|
},
|
|
2085
2140
|
setup(a, e) {
|
|
2086
|
-
return
|
|
2141
|
+
return fe({ props: a, context: e, renderless: ma, api: fa });
|
|
2087
2142
|
}
|
|
2088
|
-
}),
|
|
2089
|
-
var
|
|
2090
|
-
|
|
2091
|
-
ra,
|
|
2092
|
-
oa,
|
|
2093
|
-
!1,
|
|
2143
|
+
}), Ie = {};
|
|
2144
|
+
var va = /* @__PURE__ */ be(
|
|
2145
|
+
ha,
|
|
2094
2146
|
pa,
|
|
2147
|
+
da,
|
|
2148
|
+
!1,
|
|
2149
|
+
ba,
|
|
2095
2150
|
null,
|
|
2096
2151
|
null,
|
|
2097
2152
|
null
|
|
2098
2153
|
);
|
|
2099
|
-
function
|
|
2100
|
-
for (let e in
|
|
2101
|
-
this[e] =
|
|
2154
|
+
function ba(a) {
|
|
2155
|
+
for (let e in Ie)
|
|
2156
|
+
this[e] = Ie[e];
|
|
2102
2157
|
}
|
|
2103
|
-
const
|
|
2104
|
-
return
|
|
2158
|
+
const ga = /* @__PURE__ */ function() {
|
|
2159
|
+
return va.exports;
|
|
2105
2160
|
}();
|
|
2106
|
-
const
|
|
2161
|
+
const _a = J({
|
|
2107
2162
|
model: {
|
|
2108
2163
|
prop: "modelValue",
|
|
2109
2164
|
event: "update:modelValue"
|
|
@@ -2172,62 +2227,62 @@ const da = J({
|
|
|
2172
2227
|
default: ""
|
|
2173
2228
|
}
|
|
2174
2229
|
},
|
|
2175
|
-
emits: ["update:modelValue", "change", "search", "exceed", "first-level-select", "second-level-enter", "clear"],
|
|
2230
|
+
emits: ["update:modelValue", "change", "search", "exceed", "first-level-select", "second-level-enter", "clear", "tagClick", "help"],
|
|
2176
2231
|
components: {
|
|
2177
|
-
TinyTag:
|
|
2178
|
-
TinyInput:
|
|
2179
|
-
TinyDropdown:
|
|
2180
|
-
TinyDropdownMenu:
|
|
2181
|
-
TinyButton:
|
|
2182
|
-
TinyTooltip:
|
|
2183
|
-
TinyDatePicker:
|
|
2184
|
-
TinyForm:
|
|
2185
|
-
TinyFormItem:
|
|
2186
|
-
TinyPopover:
|
|
2187
|
-
TinySelect:
|
|
2188
|
-
TinyOption:
|
|
2189
|
-
TinySearchBoxFirstLevelPanel:
|
|
2190
|
-
TinySearchBoxSecondLevelPanel:
|
|
2232
|
+
TinyTag: Ze,
|
|
2233
|
+
TinyInput: Se,
|
|
2234
|
+
TinyDropdown: qe,
|
|
2235
|
+
TinyDropdownMenu: Qe,
|
|
2236
|
+
TinyButton: De,
|
|
2237
|
+
TinyTooltip: Ye,
|
|
2238
|
+
TinyDatePicker: Te,
|
|
2239
|
+
TinyForm: We,
|
|
2240
|
+
TinyFormItem: Ce,
|
|
2241
|
+
TinyPopover: Xe,
|
|
2242
|
+
TinySelect: Je,
|
|
2243
|
+
TinyOption: et,
|
|
2244
|
+
TinySearchBoxFirstLevelPanel: ua,
|
|
2245
|
+
TinySearchBoxSecondLevelPanel: ga,
|
|
2191
2246
|
// 图标组件
|
|
2192
|
-
TinyIconSearch:
|
|
2193
|
-
TinyIconClose:
|
|
2194
|
-
TinyIconHelpQuery:
|
|
2247
|
+
TinyIconSearch: aa(),
|
|
2248
|
+
TinyIconClose: Xt(),
|
|
2249
|
+
TinyIconHelpQuery: ea()
|
|
2195
2250
|
},
|
|
2196
2251
|
setup(a, e) {
|
|
2197
|
-
return
|
|
2252
|
+
return fe({ props: a, context: e, renderless: qt, api: Ut });
|
|
2198
2253
|
}
|
|
2199
2254
|
});
|
|
2200
|
-
var
|
|
2201
|
-
var a, e, n,
|
|
2255
|
+
var xa = function() {
|
|
2256
|
+
var a, e, n, s, r, t = this, m = t.$createElement, l = t._self._c || m;
|
|
2202
2257
|
return l("div", {
|
|
2203
2258
|
class: ["tvp-search-box", t.size === "small" ? "tvp-search-box--small" : "", t.showPrefixIcon ? "" : "hide-prefix-icon"],
|
|
2204
2259
|
on: {
|
|
2205
|
-
click: function(
|
|
2206
|
-
return
|
|
2260
|
+
click: function(o) {
|
|
2261
|
+
return o.stopPropagation(), t.showPopover(t.state, !1);
|
|
2207
2262
|
}
|
|
2208
2263
|
}
|
|
2209
2264
|
}, [t.showPrefixIcon ? l("tiny-icon-search", {
|
|
2210
2265
|
staticClass: "tvp-search-box__prefix"
|
|
2211
|
-
}) : t._e(), t._l(t.modelValue, function(
|
|
2266
|
+
}) : t._e(), t._l(t.modelValue, function(o, u) {
|
|
2212
2267
|
return l("tiny-tag", {
|
|
2213
|
-
key:
|
|
2268
|
+
key: o.field + u,
|
|
2214
2269
|
staticClass: "tvp-search-box__tag",
|
|
2215
|
-
class: t.editable &&
|
|
2270
|
+
class: t.editable && o.type !== "map" ? "tvp-search-box__tag-editor" : "",
|
|
2216
2271
|
attrs: {
|
|
2217
2272
|
closable: "",
|
|
2218
|
-
title: `${
|
|
2273
|
+
title: `${o.label} ${o.operator || ":"} ${o.value}`
|
|
2219
2274
|
},
|
|
2220
2275
|
on: {
|
|
2221
|
-
close: function(
|
|
2222
|
-
return t.deleteTag(
|
|
2276
|
+
close: function(p) {
|
|
2277
|
+
return t.deleteTag(o);
|
|
2223
2278
|
},
|
|
2224
|
-
click: function(
|
|
2225
|
-
return
|
|
2279
|
+
click: function(p) {
|
|
2280
|
+
return p.stopPropagation(), t.editTag(o, u, p);
|
|
2226
2281
|
}
|
|
2227
2282
|
}
|
|
2228
2283
|
}, [l("span", {
|
|
2229
2284
|
staticClass: "tvp-search-box__tag-value"
|
|
2230
|
-
}, [t._v(t._s(
|
|
2285
|
+
}, [t._v(t._s(o.label) + " " + t._s(o.operator || ":") + " " + t._s(o.value) + " ")])]);
|
|
2231
2286
|
}), t.modelValue.length ? l("span", {
|
|
2232
2287
|
staticClass: "tvp-search-box__placeholder"
|
|
2233
2288
|
}) : t._e(), l("tiny-form", {
|
|
@@ -2280,10 +2335,10 @@ var ma = function() {
|
|
|
2280
2335
|
maxlength: t.maxlength && t.maxlength + 1
|
|
2281
2336
|
},
|
|
2282
2337
|
on: {
|
|
2283
|
-
keydown: [function(
|
|
2284
|
-
return !
|
|
2285
|
-
}, function(
|
|
2286
|
-
return !
|
|
2338
|
+
keydown: [function(o) {
|
|
2339
|
+
return !o.type.indexOf("key") && t._k(o.keyCode, "delete", [8, 46], o.key, ["Backspace", "Delete", "Del"]) ? null : (o.stopPropagation(), t.backspaceDeleteTag.apply(null, arguments));
|
|
2340
|
+
}, function(o) {
|
|
2341
|
+
return !o.type.indexOf("key") && t._k(o.keyCode, "enter", 13, o.key, "Enter") ? null : (o.stopPropagation(), t.createTag.apply(null, arguments));
|
|
2287
2342
|
}],
|
|
2288
2343
|
input: t.handleInput,
|
|
2289
2344
|
click: t.handleClick
|
|
@@ -2291,6 +2346,7 @@ var ma = function() {
|
|
|
2291
2346
|
scopedSlots: t._u([{
|
|
2292
2347
|
key: "suffix",
|
|
2293
2348
|
fn: function() {
|
|
2349
|
+
var o, u, p, i, d, f, c, v;
|
|
2294
2350
|
return [l("tiny-icon-close", {
|
|
2295
2351
|
directives: [{
|
|
2296
2352
|
name: "show",
|
|
@@ -2300,19 +2356,24 @@ var ma = function() {
|
|
|
2300
2356
|
}],
|
|
2301
2357
|
staticClass: "tvp-search-box__input-close",
|
|
2302
2358
|
on: {
|
|
2303
|
-
click: function(
|
|
2304
|
-
return
|
|
2359
|
+
click: function(h) {
|
|
2360
|
+
return h.stopPropagation(), t.clearTag.apply(null, arguments);
|
|
2305
2361
|
}
|
|
2306
2362
|
}
|
|
2307
2363
|
}), l("span", {
|
|
2308
2364
|
directives: [{
|
|
2309
2365
|
name: "show",
|
|
2310
2366
|
rawName: "v-show",
|
|
2311
|
-
value: t.isShowClose,
|
|
2312
|
-
expression:
|
|
2367
|
+
value: t.isShowClose && (t.showHelp || ((o = t.state.instance) === null || o === void 0 || (u = o.$slots) === null || u === void 0 ? void 0 : u["suffix-icon"]) || ((p = t.state.instance) === null || p === void 0 || (i = p.slots) === null || i === void 0 ? void 0 : i["suffix-icon"])),
|
|
2368
|
+
expression: `
|
|
2369
|
+
isShowClose &&
|
|
2370
|
+
(showHelp || state.instance?.$slots?.['suffix-icon'] || state.instance?.slots?.['suffix-icon'])
|
|
2371
|
+
`
|
|
2313
2372
|
}],
|
|
2314
2373
|
staticClass: "tvp-search-box__input-separator"
|
|
2315
|
-
}), t.
|
|
2374
|
+
}), (d = t.state.instance) !== null && d !== void 0 && (f = d.$slots) !== null && f !== void 0 && f["suffix-icon"] || (c = t.state.instance) !== null && c !== void 0 && (v = c.slots) !== null && v !== void 0 && v["suffix-icon"] ? l("span", {
|
|
2375
|
+
class: t.showHelp ? "tvp-search-box__suffix-icon-slot" : "tvp-search-box__suffix-icon-slot-no-help"
|
|
2376
|
+
}, [t._t("suffix-icon")], 2) : t._e(), t.showHelp ? l("tiny-tooltip", {
|
|
2316
2377
|
attrs: {
|
|
2317
2378
|
effect: "light",
|
|
2318
2379
|
content: t.t("tvp.tvpSearchbox.help"),
|
|
@@ -2321,25 +2382,25 @@ var ma = function() {
|
|
|
2321
2382
|
}, [l("tiny-icon-help-query", {
|
|
2322
2383
|
staticClass: "tvp-search-box__input-help",
|
|
2323
2384
|
on: {
|
|
2324
|
-
click: function(
|
|
2325
|
-
return
|
|
2385
|
+
click: function(h) {
|
|
2386
|
+
return h.stopPropagation(), t.helpClick.apply(null, arguments);
|
|
2326
2387
|
}
|
|
2327
2388
|
}
|
|
2328
2389
|
})], 1) : t._e(), l("tiny-icon-search", {
|
|
2329
2390
|
staticClass: "tvp-search-box__input-search",
|
|
2330
2391
|
on: {
|
|
2331
|
-
click: function(
|
|
2332
|
-
return
|
|
2392
|
+
click: function(h) {
|
|
2393
|
+
return h.stopPropagation(), t.createTag.apply(null, arguments);
|
|
2333
2394
|
}
|
|
2334
2395
|
}
|
|
2335
2396
|
})];
|
|
2336
2397
|
},
|
|
2337
2398
|
proxy: !0
|
|
2338
|
-
}]),
|
|
2399
|
+
}], null, !0),
|
|
2339
2400
|
model: {
|
|
2340
2401
|
value: t.state.inputValue,
|
|
2341
|
-
callback: function(
|
|
2342
|
-
t.$set(t.state, "inputValue",
|
|
2402
|
+
callback: function(o) {
|
|
2403
|
+
t.$set(t.state, "inputValue", o);
|
|
2343
2404
|
},
|
|
2344
2405
|
expression: "state.inputValue"
|
|
2345
2406
|
}
|
|
@@ -2349,8 +2410,8 @@ var ma = function() {
|
|
|
2349
2410
|
}]),
|
|
2350
2411
|
model: {
|
|
2351
2412
|
value: t.state.visible,
|
|
2352
|
-
callback: function(
|
|
2353
|
-
t.$set(t.state, "visible",
|
|
2413
|
+
callback: function(o) {
|
|
2414
|
+
t.$set(t.state, "visible", o);
|
|
2354
2415
|
},
|
|
2355
2416
|
expression: "state.visible"
|
|
2356
2417
|
}
|
|
@@ -2360,8 +2421,8 @@ var ma = function() {
|
|
|
2360
2421
|
"max-height": t.panelMaxHeight
|
|
2361
2422
|
},
|
|
2362
2423
|
on: {
|
|
2363
|
-
mouseup: function(
|
|
2364
|
-
return
|
|
2424
|
+
mouseup: function(o) {
|
|
2425
|
+
return o.stopPropagation(), (function() {
|
|
2365
2426
|
}).apply(null, arguments);
|
|
2366
2427
|
}
|
|
2367
2428
|
}
|
|
@@ -2405,7 +2466,7 @@ var ma = function() {
|
|
|
2405
2466
|
}) : l("div", {
|
|
2406
2467
|
staticClass: "tvp-search-box__panel-box",
|
|
2407
2468
|
on: {
|
|
2408
|
-
click: function(
|
|
2469
|
+
click: function(o) {
|
|
2409
2470
|
return t.showDropdown(t.state);
|
|
2410
2471
|
}
|
|
2411
2472
|
}
|
|
@@ -2426,8 +2487,8 @@ var ma = function() {
|
|
|
2426
2487
|
},
|
|
2427
2488
|
model: {
|
|
2428
2489
|
value: t.state.popoverVisible,
|
|
2429
|
-
callback: function(
|
|
2430
|
-
t.$set(t.state, "popoverVisible",
|
|
2490
|
+
callback: function(o) {
|
|
2491
|
+
t.$set(t.state, "popoverVisible", o);
|
|
2431
2492
|
},
|
|
2432
2493
|
expression: "state.popoverVisible"
|
|
2433
2494
|
}
|
|
@@ -2444,8 +2505,8 @@ var ma = function() {
|
|
|
2444
2505
|
},
|
|
2445
2506
|
model: {
|
|
2446
2507
|
value: t.state.selectValue,
|
|
2447
|
-
callback: function(
|
|
2448
|
-
t.$set(t.state, "selectValue",
|
|
2508
|
+
callback: function(o) {
|
|
2509
|
+
t.$set(t.state, "selectValue", o);
|
|
2449
2510
|
},
|
|
2450
2511
|
expression: "state.selectValue"
|
|
2451
2512
|
}
|
|
@@ -2457,21 +2518,21 @@ var ma = function() {
|
|
|
2457
2518
|
disabled: t.selectItemIsDisable(t.state.allTypeAttri)
|
|
2458
2519
|
},
|
|
2459
2520
|
on: {
|
|
2460
|
-
click: function(
|
|
2521
|
+
click: function(o) {
|
|
2461
2522
|
t.selectPropChange(t.state.allTypeAttri, t.selectItemIsDisable(t.state.allTypeAttri));
|
|
2462
2523
|
}
|
|
2463
2524
|
}
|
|
2464
|
-
}), t._l(t.state.recordItems, function(
|
|
2525
|
+
}), t._l(t.state.recordItems, function(o) {
|
|
2465
2526
|
return l("tiny-option", {
|
|
2466
|
-
key:
|
|
2527
|
+
key: o.label,
|
|
2467
2528
|
attrs: {
|
|
2468
|
-
label:
|
|
2469
|
-
value:
|
|
2470
|
-
disabled: t.selectItemIsDisable(
|
|
2529
|
+
label: o.label,
|
|
2530
|
+
value: o.label,
|
|
2531
|
+
disabled: t.selectItemIsDisable(o)
|
|
2471
2532
|
},
|
|
2472
2533
|
on: {
|
|
2473
|
-
click: function(
|
|
2474
|
-
t.selectPropChange(
|
|
2534
|
+
click: function(u) {
|
|
2535
|
+
t.selectPropChange(o, t.selectItemIsDisable(o));
|
|
2475
2536
|
}
|
|
2476
2537
|
}
|
|
2477
2538
|
});
|
|
@@ -2482,17 +2543,17 @@ var ma = function() {
|
|
|
2482
2543
|
}, [l("tiny-select", {
|
|
2483
2544
|
model: {
|
|
2484
2545
|
value: t.state.operatorValue,
|
|
2485
|
-
callback: function(
|
|
2486
|
-
t.$set(t.state, "operatorValue",
|
|
2546
|
+
callback: function(o) {
|
|
2547
|
+
t.$set(t.state, "operatorValue", o);
|
|
2487
2548
|
},
|
|
2488
2549
|
expression: "state.operatorValue"
|
|
2489
2550
|
}
|
|
2490
|
-
}, t._l(t.state.currentOperators, function(
|
|
2551
|
+
}, t._l(t.state.currentOperators, function(o) {
|
|
2491
2552
|
return l("tiny-option", {
|
|
2492
|
-
key:
|
|
2553
|
+
key: o,
|
|
2493
2554
|
attrs: {
|
|
2494
|
-
label:
|
|
2495
|
-
value:
|
|
2555
|
+
label: o,
|
|
2556
|
+
value: o
|
|
2496
2557
|
}
|
|
2497
2558
|
});
|
|
2498
2559
|
}), 1)], 1) : t._e(), t.state.prevItem.type !== "numRange" ? l("div", {
|
|
@@ -2502,28 +2563,28 @@ var ma = function() {
|
|
|
2502
2563
|
attrs: {
|
|
2503
2564
|
prop: "inputEditValue"
|
|
2504
2565
|
}
|
|
2505
|
-
}, [((
|
|
2566
|
+
}, [((s = t.state.currentEditValue) === null || s === void 0 ? void 0 : s.length) > 0 ? l("tiny-select", {
|
|
2506
2567
|
staticClass: "tvp-search-box-select",
|
|
2507
2568
|
attrs: {
|
|
2508
2569
|
multiple: !!t.state.prevItem.mergeTag,
|
|
2509
|
-
"allow-create": (
|
|
2570
|
+
"allow-create": (r = t.state.prevItem) === null || r === void 0 ? void 0 : r.allowCreate,
|
|
2510
2571
|
filterable: "",
|
|
2511
2572
|
"default-first-option": "",
|
|
2512
2573
|
clearable: ""
|
|
2513
2574
|
},
|
|
2514
2575
|
model: {
|
|
2515
2576
|
value: t.state.inputEditValue,
|
|
2516
|
-
callback: function(
|
|
2517
|
-
t.$set(t.state, "inputEditValue",
|
|
2577
|
+
callback: function(o) {
|
|
2578
|
+
t.$set(t.state, "inputEditValue", o);
|
|
2518
2579
|
},
|
|
2519
2580
|
expression: "state.inputEditValue"
|
|
2520
2581
|
}
|
|
2521
|
-
}, t._l(t.state.currentEditValue, function(
|
|
2582
|
+
}, t._l(t.state.currentEditValue, function(o) {
|
|
2522
2583
|
return l("tiny-option", {
|
|
2523
|
-
key:
|
|
2584
|
+
key: o.label,
|
|
2524
2585
|
attrs: {
|
|
2525
|
-
label:
|
|
2526
|
-
value:
|
|
2586
|
+
label: o.label,
|
|
2587
|
+
value: o.label
|
|
2527
2588
|
}
|
|
2528
2589
|
});
|
|
2529
2590
|
}), 1) : l("tiny-input", {
|
|
@@ -2532,8 +2593,8 @@ var ma = function() {
|
|
|
2532
2593
|
},
|
|
2533
2594
|
model: {
|
|
2534
2595
|
value: t.state.inputEditValue,
|
|
2535
|
-
callback: function(
|
|
2536
|
-
t.$set(t.state, "inputEditValue",
|
|
2596
|
+
callback: function(o) {
|
|
2597
|
+
t.$set(t.state, "inputEditValue", o);
|
|
2537
2598
|
},
|
|
2538
2599
|
expression: "state.inputEditValue"
|
|
2539
2600
|
}
|
|
@@ -2554,8 +2615,8 @@ var ma = function() {
|
|
|
2554
2615
|
},
|
|
2555
2616
|
model: {
|
|
2556
2617
|
value: t.state[t.state.curMinNumVar],
|
|
2557
|
-
callback: function(
|
|
2558
|
-
t.$set(t.state, t.state.curMinNumVar,
|
|
2618
|
+
callback: function(o) {
|
|
2619
|
+
t.$set(t.state, t.state.curMinNumVar, o);
|
|
2559
2620
|
},
|
|
2560
2621
|
expression: "state[state.curMinNumVar]"
|
|
2561
2622
|
}
|
|
@@ -2573,8 +2634,8 @@ var ma = function() {
|
|
|
2573
2634
|
},
|
|
2574
2635
|
model: {
|
|
2575
2636
|
value: t.state[t.state.curMaxNumVar],
|
|
2576
|
-
callback: function(
|
|
2577
|
-
t.$set(t.state, t.state.curMaxNumVar,
|
|
2637
|
+
callback: function(o) {
|
|
2638
|
+
t.$set(t.state, t.state.curMaxNumVar, o);
|
|
2578
2639
|
},
|
|
2579
2640
|
expression: "state[state.curMaxNumVar]"
|
|
2580
2641
|
}
|
|
@@ -2601,8 +2662,8 @@ var ma = function() {
|
|
|
2601
2662
|
},
|
|
2602
2663
|
model: {
|
|
2603
2664
|
value: t.state.startDate,
|
|
2604
|
-
callback: function(
|
|
2605
|
-
t.$set(t.state, "startDate",
|
|
2665
|
+
callback: function(o) {
|
|
2666
|
+
t.$set(t.state, "startDate", o);
|
|
2606
2667
|
},
|
|
2607
2668
|
expression: "state.startDate"
|
|
2608
2669
|
}
|
|
@@ -2622,8 +2683,8 @@ var ma = function() {
|
|
|
2622
2683
|
},
|
|
2623
2684
|
model: {
|
|
2624
2685
|
value: t.state.endDate,
|
|
2625
|
-
callback: function(
|
|
2626
|
-
t.$set(t.state, "endDate",
|
|
2686
|
+
callback: function(o) {
|
|
2687
|
+
t.$set(t.state, "endDate", o);
|
|
2627
2688
|
},
|
|
2628
2689
|
expression: "state.endDate"
|
|
2629
2690
|
}
|
|
@@ -2652,8 +2713,8 @@ var ma = function() {
|
|
|
2652
2713
|
},
|
|
2653
2714
|
model: {
|
|
2654
2715
|
value: t.state.startDateTime,
|
|
2655
|
-
callback: function(
|
|
2656
|
-
t.$set(t.state, "startDateTime",
|
|
2716
|
+
callback: function(o) {
|
|
2717
|
+
t.$set(t.state, "startDateTime", o);
|
|
2657
2718
|
},
|
|
2658
2719
|
expression: "state.startDateTime"
|
|
2659
2720
|
}
|
|
@@ -2675,8 +2736,8 @@ var ma = function() {
|
|
|
2675
2736
|
},
|
|
2676
2737
|
model: {
|
|
2677
2738
|
value: t.state.endDateTime,
|
|
2678
|
-
callback: function(
|
|
2679
|
-
t.$set(t.state, "endDateTime",
|
|
2739
|
+
callback: function(o) {
|
|
2740
|
+
t.$set(t.state, "endDateTime", o);
|
|
2680
2741
|
},
|
|
2681
2742
|
expression: "state.endDateTime"
|
|
2682
2743
|
}
|
|
@@ -2687,7 +2748,7 @@ var ma = function() {
|
|
|
2687
2748
|
size: "mini"
|
|
2688
2749
|
},
|
|
2689
2750
|
on: {
|
|
2690
|
-
click: function(
|
|
2751
|
+
click: function(o) {
|
|
2691
2752
|
return t.confirmEditTag(!1);
|
|
2692
2753
|
}
|
|
2693
2754
|
}
|
|
@@ -2697,7 +2758,7 @@ var ma = function() {
|
|
|
2697
2758
|
disabled: t.state.hasFormError
|
|
2698
2759
|
},
|
|
2699
2760
|
on: {
|
|
2700
|
-
click: function(
|
|
2761
|
+
click: function(o) {
|
|
2701
2762
|
return t.confirmEditTag(!0);
|
|
2702
2763
|
}
|
|
2703
2764
|
}
|
|
@@ -2709,25 +2770,25 @@ var ma = function() {
|
|
|
2709
2770
|
},
|
|
2710
2771
|
onConfirm: t.handleEditConfirm
|
|
2711
2772
|
})], 2)], 2)] : t._e()], 2)], 2);
|
|
2712
|
-
},
|
|
2713
|
-
const
|
|
2714
|
-
var
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2773
|
+
}, ya = [];
|
|
2774
|
+
const ke = {};
|
|
2775
|
+
var wa = /* @__PURE__ */ be(
|
|
2776
|
+
_a,
|
|
2777
|
+
xa,
|
|
2778
|
+
ya,
|
|
2718
2779
|
!1,
|
|
2719
|
-
|
|
2780
|
+
Ia,
|
|
2720
2781
|
null,
|
|
2721
2782
|
null,
|
|
2722
2783
|
null
|
|
2723
2784
|
);
|
|
2724
|
-
function
|
|
2725
|
-
for (let e in
|
|
2726
|
-
this[e] =
|
|
2785
|
+
function Ia(a) {
|
|
2786
|
+
for (let e in ke)
|
|
2787
|
+
this[e] = ke[e];
|
|
2727
2788
|
}
|
|
2728
|
-
const
|
|
2729
|
-
return
|
|
2730
|
-
}(),
|
|
2789
|
+
const ka = /* @__PURE__ */ function() {
|
|
2790
|
+
return wa.exports;
|
|
2791
|
+
}(), Va = {
|
|
2731
2792
|
...ee,
|
|
2732
2793
|
tiny_mode: {
|
|
2733
2794
|
type: String,
|
|
@@ -2813,23 +2874,23 @@ const ba = /* @__PURE__ */ function() {
|
|
|
2813
2874
|
type: Boolean,
|
|
2814
2875
|
default: !1
|
|
2815
2876
|
}
|
|
2816
|
-
},
|
|
2817
|
-
name:
|
|
2818
|
-
props:
|
|
2819
|
-
...
|
|
2820
|
-
}),
|
|
2821
|
-
|
|
2822
|
-
a.component(
|
|
2877
|
+
}, Q = J({
|
|
2878
|
+
name: me + "SearchBox",
|
|
2879
|
+
props: Va,
|
|
2880
|
+
...ka
|
|
2881
|
+
}), Ca = "3.28.2";
|
|
2882
|
+
Q.install = function(a) {
|
|
2883
|
+
a.component(Q.name, Q);
|
|
2823
2884
|
};
|
|
2824
|
-
|
|
2825
|
-
window && typeof window < "u" && window.Vue &&
|
|
2885
|
+
Q.version = Ca;
|
|
2886
|
+
window && typeof window < "u" && window.Vue && Q.install(window.Vue);
|
|
2826
2887
|
export {
|
|
2827
|
-
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
|
|
2888
|
+
ua as TinySearchBoxFirstLevelPanel,
|
|
2889
|
+
ga as TinySearchBoxSecondLevelPanel,
|
|
2890
|
+
Q as default,
|
|
2891
|
+
Fe as enUS,
|
|
2892
|
+
Ft as setGlobalApp,
|
|
2832
2893
|
L as t,
|
|
2833
|
-
|
|
2894
|
+
Oe as zhCN
|
|
2834
2895
|
};
|
|
2835
2896
|
//# sourceMappingURL=index.js.map
|