@farris/ui-vue 1.7.0-beta.3 → 1.7.0-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/avatar/index.esm.js +10 -1
- package/components/avatar/index.umd.cjs +1 -1
- package/components/calendar/index.esm.js +178 -176
- package/components/calendar/index.umd.cjs +2 -2
- package/components/collection-property-editor/index.esm.js +48 -46
- package/components/collection-property-editor/index.umd.cjs +2 -2
- package/components/combo-list/index.esm.js +319 -300
- package/components/combo-list/index.umd.cjs +1 -1
- package/components/comment/index.esm.js +2287 -1161
- package/components/comment/index.umd.cjs +7 -7
- package/components/component/index.esm.js +3 -1
- package/components/component/index.umd.cjs +2 -2
- package/components/condition/index.esm.js +926 -901
- package/components/condition/index.umd.cjs +2 -2
- package/components/data-view/index.esm.js +898 -899
- package/components/data-view/index.umd.cjs +1 -1
- package/components/drawer/index.esm.js +3 -1
- package/components/drawer/index.umd.cjs +2 -2
- package/components/dynamic-form/index.esm.js +239 -221
- package/components/dynamic-form/index.umd.cjs +1 -1
- package/components/dynamic-resolver/index.esm.js +11 -9
- package/components/dynamic-resolver/index.umd.cjs +2 -2
- package/components/expression-editor/index.esm.js +1299 -1279
- package/components/expression-editor/index.umd.cjs +4 -4
- package/components/filter-bar/index.esm.js +731 -678
- package/components/filter-bar/index.umd.cjs +2 -2
- package/components/filter-condition-editor/index.esm.js +1792 -1772
- package/components/filter-condition-editor/index.umd.cjs +4 -4
- package/components/image/index.esm.js +246 -240
- package/components/image/index.umd.cjs +2 -2
- package/components/language-textbox/index.esm.js +9 -7
- package/components/language-textbox/index.umd.cjs +2 -2
- package/components/list-view/index.esm.js +1 -1
- package/components/list-view/index.umd.cjs +1 -1
- package/components/locale/index.esm.js +2009 -886
- package/components/locale/index.umd.cjs +6 -6
- package/components/number-range/index.esm.js +190 -181
- package/components/number-range/index.umd.cjs +1 -1
- package/components/order/index.esm.js +734 -714
- package/components/order/index.umd.cjs +5 -5
- package/components/property-panel/index.esm.js +60 -49
- package/components/property-panel/index.umd.cjs +3 -3
- package/components/query-solution/index.esm.js +2461 -2500
- package/components/query-solution/index.umd.cjs +6 -6
- package/components/radio-group/index.esm.js +30 -30
- package/components/radio-group/index.umd.cjs +1 -1
- package/components/schema-selector/index.esm.js +238 -238
- package/components/schema-selector/index.umd.cjs +4 -4
- package/components/section/index.esm.js +217 -302
- package/components/section/index.umd.cjs +2 -2
- package/components/sort-condition-editor/index.esm.js +1793 -1773
- package/components/sort-condition-editor/index.umd.cjs +4 -4
- package/components/transfer/index.esm.js +155 -155
- package/components/transfer/index.umd.cjs +3 -3
- package/designer/data-grid/index.esm.js +895 -867
- package/designer/data-grid/index.umd.cjs +5 -5
- package/designer/data-view/index.esm.js +145 -144
- package/designer/data-view/index.umd.cjs +2 -2
- package/designer/drawer/index.esm.js +73 -71
- package/designer/drawer/index.umd.cjs +2 -2
- package/designer/dynamic-form/index.esm.js +87 -65
- package/designer/dynamic-form/index.umd.cjs +2 -2
- package/designer/farris-designer.all.esm.js +14 -3
- package/designer/farris-designer.all.umd.cjs +3 -3
- package/designer/input-group/index.esm.js +34 -14
- package/designer/input-group/index.umd.cjs +1 -1
- package/designer/list-view/index.esm.js +1 -1
- package/designer/list-view/index.umd.cjs +1 -1
- package/designer/radio-group/index.esm.js +15 -2
- package/designer/radio-group/index.umd.cjs +1 -1
- package/designer/section/index.esm.js +129 -119
- package/designer/section/index.umd.cjs +1 -1
- package/designer/time-picker/index.esm.js +140 -131
- package/designer/time-picker/index.umd.cjs +1 -1
- package/farris.all.esm.js +13578 -12394
- package/farris.all.umd.cjs +26 -26
- package/index.css +1 -1
- package/locales/data-grid/ui/en.json +2 -1
- package/locales/data-grid/ui/zh-CHS.json +2 -1
- package/locales/data-grid/ui/zh-CHT.json +2 -1
- package/locales/designer/en.json +12 -10
- package/locales/designer/zh-CHS.json +19 -17
- package/locales/designer/zh-CHT.json +19 -17
- package/locales/ui/en.json +4 -2
- package/locales/ui/zh-CHS.json +11 -9
- package/locales/ui/zh-CHT.json +11 -9
- package/package.json +1 -1
- package/package.zip +0 -0
- package/types/combo-list/src/composition/types.d.ts +1 -0
- package/types/condition/src/composition/condition-value/number-spinner-value.d.ts +1 -1
- package/types/condition/src/composition/use-field-config.d.ts +1 -1
- package/types/condition/src/condition.props.d.ts +1 -1
- package/types/data-view/designer/property-config/use-command-option.d.ts +12 -0
- package/types/image/src/property-config/image.property-config.d.ts +5 -5
- package/types/locale/src/lib/locale.service.d.ts +2 -2
- package/types/property-panel/src/composition/entity/input-base-property.d.ts +7 -0
- package/types/query-solution/src/designer/query-solution-config/composition/use-util.d.ts +0 -20
- package/types/section/src/designer/section.design.props.d.ts +17 -0
- package/types/section/src/section.props.d.ts +0 -25
|
@@ -1,80 +1,80 @@
|
|
|
1
|
-
import { computed as
|
|
2
|
-
function q(i, a,
|
|
3
|
-
const { getGridHeaderCells:
|
|
1
|
+
import { computed as _, watch as B, ref as T, createVNode as N, Fragment as z, createTextVNode as G } from "vue";
|
|
2
|
+
function q(i, a, o, t, s) {
|
|
3
|
+
const { getGridHeaderCells: d } = s, f = 120, b = 50, I = _(() => {
|
|
4
4
|
var e;
|
|
5
5
|
return ((e = i.rowNumber) == null ? void 0 : e.enable) || !1;
|
|
6
|
-
}), A =
|
|
6
|
+
}), A = _(() => {
|
|
7
7
|
var e, r;
|
|
8
8
|
return ((e = i.selection) == null ? void 0 : e.multiSelect) || ((r = i.selection) == null ? void 0 : r.showCheckbox) || !1;
|
|
9
|
-
}),
|
|
9
|
+
}), D = _(
|
|
10
10
|
() => {
|
|
11
11
|
var e;
|
|
12
|
-
return 0 + (
|
|
12
|
+
return 0 + (I.value ? ((e = i.rowNumber) == null ? void 0 : e.width) || 32 : 0) + (A.value ? b : 0);
|
|
13
13
|
}
|
|
14
|
-
),
|
|
14
|
+
), P = _(() => {
|
|
15
15
|
var e;
|
|
16
16
|
return (e = i.columnOption) == null ? void 0 : e.fitColumns;
|
|
17
|
-
}), M =
|
|
17
|
+
}), M = _(() => {
|
|
18
18
|
var e;
|
|
19
|
-
return
|
|
19
|
+
return P.value && ((e = i.columnOption) == null ? void 0 : e.fitMode) || "none";
|
|
20
20
|
});
|
|
21
|
-
function O(e, r,
|
|
21
|
+
function O(e, r, u) {
|
|
22
22
|
const m = parseInt(e.width, 10) / 100;
|
|
23
|
-
return
|
|
23
|
+
return u * m;
|
|
24
24
|
}
|
|
25
|
-
function W(e, r,
|
|
26
|
-
return typeof e.width == "string" ? O(e, r,
|
|
25
|
+
function W(e, r, u) {
|
|
26
|
+
return typeof e.width == "string" ? O(e, r, u) : e.width || f;
|
|
27
27
|
}
|
|
28
28
|
function F(e, r) {
|
|
29
|
-
const
|
|
29
|
+
const u = [], m = [];
|
|
30
30
|
let h = 0;
|
|
31
31
|
e.value.primaryColumns.forEach((p) => {
|
|
32
|
-
typeof p.width == "string" ? m.push(p) : (p.width = p.width || f, h += p.width,
|
|
32
|
+
typeof p.width == "string" ? m.push(p) : (p.width = p.width || f, h += p.width, u.push(p));
|
|
33
33
|
});
|
|
34
|
-
const y = r * (
|
|
35
|
-
|
|
36
|
-
const
|
|
37
|
-
p.actualWidth =
|
|
34
|
+
const y = r * (u.length / e.value.primaryColumns.length);
|
|
35
|
+
u.forEach((p) => {
|
|
36
|
+
const c = y * (p.width / h);
|
|
37
|
+
p.actualWidth = c, e.value.primaryColumnsWidth += p.actualWidth;
|
|
38
38
|
});
|
|
39
39
|
const w = r - y;
|
|
40
40
|
m.forEach((p) => {
|
|
41
|
-
const
|
|
42
|
-
p.actualWidth =
|
|
41
|
+
const c = O(p, e.value, w);
|
|
42
|
+
p.actualWidth = c, e.value.primaryColumnsWidth += p.actualWidth;
|
|
43
43
|
});
|
|
44
44
|
}
|
|
45
45
|
function C(e, r) {
|
|
46
|
-
const
|
|
46
|
+
const u = [], m = [], h = /* @__PURE__ */ new WeakMap();
|
|
47
47
|
let y = 0, w = 0;
|
|
48
|
-
if (e.value.primaryColumns.forEach((
|
|
49
|
-
if (typeof
|
|
50
|
-
const g = O(
|
|
51
|
-
h.set(
|
|
48
|
+
if (e.value.primaryColumns.forEach((c) => {
|
|
49
|
+
if (typeof c.width == "string") {
|
|
50
|
+
const g = O(c, e.value, r);
|
|
51
|
+
h.set(c, g), y += g, m.push(c);
|
|
52
52
|
} else
|
|
53
|
-
|
|
53
|
+
c.width = c.width || f, w += c.width, u.push(c);
|
|
54
54
|
}), r - y > w) {
|
|
55
|
-
const
|
|
55
|
+
const c = r - y;
|
|
56
56
|
m.forEach((g) => {
|
|
57
57
|
g.actualWidth = h.get(g) || f, e.value.primaryColumnsWidth += g.actualWidth;
|
|
58
|
-
}),
|
|
59
|
-
g.actualWidth =
|
|
58
|
+
}), u.forEach((g) => {
|
|
59
|
+
g.actualWidth = c * (g.width / w), e.value.primaryColumnsWidth += g.actualWidth;
|
|
60
60
|
});
|
|
61
61
|
} else
|
|
62
62
|
F(e, r);
|
|
63
63
|
}
|
|
64
64
|
function v(e, r) {
|
|
65
|
-
e.value.primaryColumns.forEach((
|
|
66
|
-
|
|
65
|
+
e.value.primaryColumns.forEach((u) => {
|
|
66
|
+
u.actualWidth = W(u, e.value, r), e.value.primaryColumnsWidth += u.actualWidth;
|
|
67
67
|
});
|
|
68
68
|
}
|
|
69
|
-
const
|
|
69
|
+
const E = {
|
|
70
70
|
expand: C,
|
|
71
71
|
none: v,
|
|
72
72
|
percentage: F
|
|
73
73
|
};
|
|
74
|
-
function
|
|
75
|
-
e.value.leftHeaderColumns = Array.from(
|
|
74
|
+
function R(e) {
|
|
75
|
+
e.value.leftHeaderColumns = Array.from(d(e.value.leftColumns).values()), e.value.primaryHeaderColumns = Array.from(d(e.value.primaryColumns).values()), e.value.rightHeaderColumns = Array.from(d(e.value.rightColumns).values());
|
|
76
76
|
}
|
|
77
|
-
function
|
|
77
|
+
function S(e) {
|
|
78
78
|
e.value.leftColumnsWidth = 0, e.value.primaryColumnsWidth = 0, e.value.rightColumnsWidth = 0, e.value.leftColumns.forEach((r) => {
|
|
79
79
|
e.value.leftColumnsWidth += r.actualWidth || 0;
|
|
80
80
|
}), e.value.primaryColumns.forEach((r) => {
|
|
@@ -83,28 +83,28 @@ function q(i, a, u, t, s) {
|
|
|
83
83
|
e.value.rightColumnsWidth += r.actualWidth || 0;
|
|
84
84
|
}), e.value = Object.assign({}, e.value);
|
|
85
85
|
}
|
|
86
|
-
function n(e, r,
|
|
86
|
+
function n(e, r, u) {
|
|
87
87
|
var g;
|
|
88
88
|
let m = 0;
|
|
89
89
|
const h = e.value.primaryColumns, y = e.value.rightColumns;
|
|
90
90
|
e.value.rightColumns.forEach((k) => {
|
|
91
91
|
k.actualWidth = W(k, e.value, r), m += k.actualWidth;
|
|
92
92
|
});
|
|
93
|
-
const w =
|
|
94
|
-
if (p && p(e, w), e.value.primaryColumnsWidth + m <=
|
|
93
|
+
const w = u - m, p = E[M.value];
|
|
94
|
+
if (p && p(e, w), e.value.primaryColumnsWidth + m <= u)
|
|
95
95
|
return e.value.primaryColumns = [...h, ...y], e.value.primaryColumnsWidth += m, e.value.rightColumns = [], e.value.rightColumnsWidth = 0, !0;
|
|
96
|
-
const
|
|
97
|
-
return
|
|
96
|
+
const c = /* @__PURE__ */ new Map();
|
|
97
|
+
return c.set("primary", []), c.set("right", []), e.value.primaryColumns.reduce((k, V) => {
|
|
98
98
|
var $, H;
|
|
99
|
-
return
|
|
100
|
-
},
|
|
99
|
+
return V.fixed === "right" ? ($ = k.get("right")) == null || $.push(V) : (H = k.get("primary")) == null || H.push(V), k;
|
|
100
|
+
}, c), (g = c.get("right")) != null && g.length && (e.value.primaryColumns = [...c.get("primary") || []], e.value.rightColumns = [...c.get("right") || []]), e.value.primaryColumnsWidth = 0, e.value.rightColumnsWidth = 0, !1;
|
|
101
101
|
}
|
|
102
102
|
function l() {
|
|
103
|
-
if (
|
|
103
|
+
if (o.value) {
|
|
104
104
|
a.value.leftColumnsWidth = 0, a.value.primaryColumnsWidth = 0, a.value.rightColumnsWidth = 0;
|
|
105
|
-
const e =
|
|
106
|
-
a.value.leftColumns.forEach((
|
|
107
|
-
|
|
105
|
+
const e = o.value.clientWidth - D.value;
|
|
106
|
+
a.value.leftColumns.forEach((u) => {
|
|
107
|
+
u.actualWidth = W(u, a.value, e), a.value.leftColumnsWidth += u.actualWidth;
|
|
108
108
|
});
|
|
109
109
|
const r = e - a.value.leftColumnsWidth;
|
|
110
110
|
if (n(a, e, r))
|
|
@@ -113,10 +113,10 @@ function q(i, a, u, t, s) {
|
|
|
113
113
|
a.value.rightColumns.forEach((h) => {
|
|
114
114
|
h.actualWidth = W(h, a.value, e), a.value.rightColumnsWidth += h.actualWidth;
|
|
115
115
|
});
|
|
116
|
-
const
|
|
117
|
-
m && m(a,
|
|
116
|
+
const u = e - a.value.leftColumnsWidth - a.value.rightColumnsWidth, m = E[M.value];
|
|
117
|
+
m && m(a, u), t.value = u;
|
|
118
118
|
}
|
|
119
|
-
|
|
119
|
+
R(a), a.value = Object.assign({}, a.value);
|
|
120
120
|
}
|
|
121
121
|
}
|
|
122
122
|
return B(() => {
|
|
@@ -125,12 +125,12 @@ function q(i, a, u, t, s) {
|
|
|
125
125
|
}, (e, r) => {
|
|
126
126
|
e !== r && e && l();
|
|
127
127
|
}), B(M, (e, r) => {
|
|
128
|
-
e !== r &&
|
|
129
|
-
}), { calculateColumnHeaders:
|
|
128
|
+
e !== r && P.value && l();
|
|
129
|
+
}), { calculateColumnHeaders: R, calculateColumnsSize: l, calculateColumnsWidth: S };
|
|
130
130
|
}
|
|
131
131
|
const L = "";
|
|
132
132
|
function K(i) {
|
|
133
|
-
const t =
|
|
133
|
+
const t = T({
|
|
134
134
|
defaultColumnWidth: 120,
|
|
135
135
|
headerDepth: 1,
|
|
136
136
|
leftColumns: [],
|
|
@@ -166,11 +166,11 @@ function K(i) {
|
|
|
166
166
|
summaryColumns: []
|
|
167
167
|
};
|
|
168
168
|
}
|
|
169
|
-
const
|
|
170
|
-
const n =
|
|
169
|
+
const d = T(i.summary), f = _(() => {
|
|
170
|
+
const n = d.value;
|
|
171
171
|
return (n == null ? void 0 : n.groupFields) || [];
|
|
172
172
|
});
|
|
173
|
-
function
|
|
173
|
+
function b() {
|
|
174
174
|
t.value.rightColumns.forEach((e) => {
|
|
175
175
|
e.showSetting = !1;
|
|
176
176
|
}), t.value.primaryColumns.forEach((e) => {
|
|
@@ -179,14 +179,14 @@ function K(i) {
|
|
|
179
179
|
const n = t.value.rightColumns, l = t.value.primaryColumns;
|
|
180
180
|
n.length > 0 ? n[n.length - 1].showSetting = !0 : l.length > 0 && (l[l.length - 1].showSetting = !0);
|
|
181
181
|
}
|
|
182
|
-
function
|
|
182
|
+
function I(n) {
|
|
183
183
|
s();
|
|
184
184
|
const l = /* @__PURE__ */ new Map();
|
|
185
|
-
return f.value && f.value.reduce((e, r) => (e.set(r, !0), e), l), n.reduce((e, r) => (r.filter = r.filter || L, r.fixed === "left" ? (t.value.leftColumns.push(r), t.value.leftColumnsMap.set(r.field, r), t.value.leftColumnsWidth += r.actualWidth) : r.fixed === "right" ? (t.value.rightColumns.push(r), t.value.rightColumnsMap.set(r.field, r), t.value.rightColumnsWidth += r.actualWidth) : (t.value.primaryColumns.push(r), t.value.primaryColumnsMap.set(r.field, r), t.value.primaryColumnsWidth += r.actualWidth), l.has(r.field) && t.value.summaryColumns.push(r), e), t),
|
|
185
|
+
return f.value && f.value.reduce((e, r) => (e.set(r, !0), e), l), n.reduce((e, r) => (r.filter = r.filter || L, r.fixed === "left" ? (t.value.leftColumns.push(r), t.value.leftColumnsMap.set(r.field, r), t.value.leftColumnsWidth += r.actualWidth) : r.fixed === "right" ? (t.value.rightColumns.push(r), t.value.rightColumnsMap.set(r.field, r), t.value.rightColumnsWidth += r.actualWidth) : (t.value.primaryColumns.push(r), t.value.primaryColumnsMap.set(r.field, r), t.value.primaryColumnsWidth += r.actualWidth), l.has(r.field) && t.value.summaryColumns.push(r), e), t), b(), t;
|
|
186
186
|
}
|
|
187
|
-
|
|
188
|
-
const A =
|
|
189
|
-
function
|
|
187
|
+
I(i.columns);
|
|
188
|
+
const A = _(() => t.value.leftColumns.length > 0), D = _(() => t.value.rightColumns.length > 0);
|
|
189
|
+
function P(n, l) {
|
|
190
190
|
return l.sortable && l.sort && l.sort !== "none" && n.push(l), n;
|
|
191
191
|
}
|
|
192
192
|
function M(n, l) {
|
|
@@ -204,71 +204,71 @@ function K(i) {
|
|
|
204
204
|
}
|
|
205
205
|
function C() {
|
|
206
206
|
const n = [];
|
|
207
|
-
t.value.leftColumns.reduce(
|
|
207
|
+
t.value.leftColumns.reduce(P, n), t.value.primaryColumns.reduce(P, n), t.value.rightColumns.reduce(P, n);
|
|
208
208
|
const l = Math.max(...n.map((e) => e.sortOrder || 0));
|
|
209
209
|
return n.sort(O).map((e) => {
|
|
210
210
|
const r = e.sortOrder || l + 1;
|
|
211
211
|
return e.sortOrder = r, e;
|
|
212
212
|
}).sort(M).map((e, r) => {
|
|
213
|
-
const
|
|
214
|
-
return e.sortOrder =
|
|
213
|
+
const u = r + 1;
|
|
214
|
+
return e.sortOrder = u, e;
|
|
215
215
|
});
|
|
216
216
|
}
|
|
217
217
|
function v(n, l, e) {
|
|
218
|
-
const r = n.map((
|
|
219
|
-
const m = e.getSorterByColumn(
|
|
220
|
-
return { field:
|
|
218
|
+
const r = n.map((u) => {
|
|
219
|
+
const m = e.getSorterByColumn(u), h = u.sort === "asc", y = u.sort === "desc", w = h ? m.ascend : y ? m.decend : void 0;
|
|
220
|
+
return { field: u.field, compare: w };
|
|
221
221
|
});
|
|
222
222
|
l.setSorters(r);
|
|
223
223
|
}
|
|
224
|
-
function
|
|
224
|
+
function E(n, l) {
|
|
225
225
|
const e = C();
|
|
226
226
|
v(e, n, l);
|
|
227
227
|
}
|
|
228
|
-
function
|
|
228
|
+
function R(n) {
|
|
229
229
|
}
|
|
230
|
-
function
|
|
230
|
+
function S(n) {
|
|
231
231
|
}
|
|
232
232
|
return {
|
|
233
|
-
applyColumnSorter:
|
|
233
|
+
applyColumnSorter: E,
|
|
234
234
|
collectionFilterableColumns: F,
|
|
235
235
|
applySortableColumns: v,
|
|
236
236
|
collectionSortableColumns: C,
|
|
237
237
|
columnContext: t,
|
|
238
238
|
hasLeftFixedColumn: A,
|
|
239
|
-
hasRightFixedColumn:
|
|
240
|
-
updateColumnRenderContext:
|
|
241
|
-
updateColumnSettingIcon:
|
|
242
|
-
sortFromServer:
|
|
243
|
-
createSortConditions:
|
|
239
|
+
hasRightFixedColumn: D,
|
|
240
|
+
updateColumnRenderContext: I,
|
|
241
|
+
updateColumnSettingIcon: b,
|
|
242
|
+
sortFromServer: R,
|
|
243
|
+
createSortConditions: S
|
|
244
244
|
};
|
|
245
245
|
}
|
|
246
|
-
function Y(i, a,
|
|
247
|
-
const
|
|
246
|
+
function Y(i, a, o, t, s, d, f, b) {
|
|
247
|
+
const I = T(t.value - 1 + s), A = T(0), { renderDataRow: D } = d, P = f ? f.renderGroupRow : D, M = b ? b.renderSummaryRow : D;
|
|
248
248
|
function O(C) {
|
|
249
|
-
let v =
|
|
250
|
-
return C.__fv_data_grid_group_row__ && (v =
|
|
249
|
+
let v = D;
|
|
250
|
+
return C.__fv_data_grid_group_row__ && (v = P), C.__fv_data_grid_group_summary__ && (v = M), v;
|
|
251
251
|
}
|
|
252
|
-
function W(C, v,
|
|
253
|
-
const { dataView:
|
|
254
|
-
if (
|
|
255
|
-
const l =
|
|
252
|
+
function W(C, v, E, R) {
|
|
253
|
+
const { dataView: S } = o, n = [];
|
|
254
|
+
if (S.value.length > 0) {
|
|
255
|
+
const l = R ? Date.now().toString() : "";
|
|
256
256
|
let e = C, r = 0;
|
|
257
|
-
const
|
|
258
|
-
for (; n.length <
|
|
259
|
-
const m =
|
|
260
|
-
|
|
257
|
+
const u = v - C + 1;
|
|
258
|
+
for (; n.length < u && e < S.value.length; ) {
|
|
259
|
+
const m = S.value[e], h = S.value[e - 1] || E, y = n[r - 1], w = h ? (h.__fv_data_position__ || 0) + (h.__fv_data_height__ || 0) : 0, c = O(m)(m, h, y, e, w, a.value, n);
|
|
260
|
+
c.refreshKey = l, n.push(c), r++, e++;
|
|
261
261
|
}
|
|
262
262
|
}
|
|
263
|
-
return A.value = n.length > 0 ? n[0].index : 0,
|
|
263
|
+
return A.value = n.length > 0 ? n[0].index : 0, I.value = n.length > 0 ? n[n.length - 1].index : 0, n;
|
|
264
264
|
}
|
|
265
|
-
function F(C, v,
|
|
266
|
-
const
|
|
267
|
-
|
|
268
|
-
const { dataView: l } =
|
|
265
|
+
function F(C, v, E) {
|
|
266
|
+
const R = v.groupField || "", { groupValue: S, raw: n } = v;
|
|
267
|
+
o[C](R, S, n.groupParents || []);
|
|
268
|
+
const { dataView: l } = o, e = E[0].index, r = Math.min(e + t.value + s + 1, l.value.length - 1);
|
|
269
269
|
return W(e, r);
|
|
270
270
|
}
|
|
271
|
-
return { getVisualData: W, maxVisibleRowIndex:
|
|
271
|
+
return { getVisualData: W, maxVisibleRowIndex: I, minVisibleRowIndex: A, toggleGroupRow: F };
|
|
272
272
|
}
|
|
273
273
|
function J() {
|
|
274
274
|
function i(a) {
|
|
@@ -369,10 +369,10 @@ function Q() {
|
|
|
369
369
|
// }
|
|
370
370
|
// },
|
|
371
371
|
},
|
|
372
|
-
setPropertyRelates(
|
|
373
|
-
switch (
|
|
372
|
+
setPropertyRelates(o, t) {
|
|
373
|
+
switch (o && o.propertyID) {
|
|
374
374
|
case "fitColumns": {
|
|
375
|
-
t.fit =
|
|
375
|
+
t.fit = o.propertyValue, t.columns && (o.propertyValue ? t.columns.forEach((s) => {
|
|
376
376
|
s.resizable = !1;
|
|
377
377
|
}) : t.columns.forEach((s) => {
|
|
378
378
|
s.resizable = !0;
|
|
@@ -386,7 +386,8 @@ function Q() {
|
|
|
386
386
|
return { getColumnOptionProperties: i };
|
|
387
387
|
}
|
|
388
388
|
function X(i) {
|
|
389
|
-
function a(
|
|
389
|
+
function a(o) {
|
|
390
|
+
var t, s;
|
|
390
391
|
return {
|
|
391
392
|
title: "操作列",
|
|
392
393
|
description: "",
|
|
@@ -416,7 +417,7 @@ function X(i) {
|
|
|
416
417
|
description: "操作列按钮集合",
|
|
417
418
|
title: "操作项",
|
|
418
419
|
type: "array",
|
|
419
|
-
visible:
|
|
420
|
+
visible: ((t = o.command) == null ? void 0 : t.enableType) === "custom",
|
|
420
421
|
$converter: "/converter/column-command.converter",
|
|
421
422
|
editor: {
|
|
422
423
|
columns: [
|
|
@@ -429,25 +430,25 @@ function X(i) {
|
|
|
429
430
|
requiredFields: ["value", "text"],
|
|
430
431
|
uniqueFields: ["value", "text"]
|
|
431
432
|
}
|
|
433
|
+
},
|
|
434
|
+
formatter: {
|
|
435
|
+
title: "操作列模板",
|
|
436
|
+
$converter: "/converter/column-command.converter",
|
|
437
|
+
type: "string",
|
|
438
|
+
visible: ((s = o.command) == null ? void 0 : s.enableType) === "custom" && !!o.command.formatter,
|
|
439
|
+
description: "操作列模板",
|
|
440
|
+
refreshPanelAfterChanged: !0,
|
|
441
|
+
editor: {
|
|
442
|
+
type: "code-editor",
|
|
443
|
+
language: "html"
|
|
444
|
+
}
|
|
432
445
|
}
|
|
433
|
-
// formatter: {
|
|
434
|
-
// title: '操作列模板',
|
|
435
|
-
// $converter: '/converter/column-command.converter',
|
|
436
|
-
// type: 'string',
|
|
437
|
-
// visible: propertyData.command?.enableType === 'custom',
|
|
438
|
-
// description: '操作列模板',
|
|
439
|
-
// refreshPanelAfterChanged: true,
|
|
440
|
-
// editor: {
|
|
441
|
-
// type: "code-editor",
|
|
442
|
-
// language: "html",
|
|
443
|
-
// }
|
|
444
|
-
// }
|
|
445
446
|
},
|
|
446
|
-
setPropertyRelates(
|
|
447
|
-
var
|
|
448
|
-
switch (
|
|
447
|
+
setPropertyRelates(d, f) {
|
|
448
|
+
var b;
|
|
449
|
+
switch (d && d.propertyID) {
|
|
449
450
|
case "enableType": {
|
|
450
|
-
(
|
|
451
|
+
(d.propertyValue === "custom" || d.propertyValue === "default") && ((b = i.getFormDesignerInstance()) == null || b.reloadPropertyPanel());
|
|
451
452
|
break;
|
|
452
453
|
}
|
|
453
454
|
}
|
|
@@ -476,7 +477,7 @@ function Z() {
|
|
|
476
477
|
}
|
|
477
478
|
function j() {
|
|
478
479
|
function i(a) {
|
|
479
|
-
var
|
|
480
|
+
var o;
|
|
480
481
|
return {
|
|
481
482
|
title: "分组",
|
|
482
483
|
description: "",
|
|
@@ -491,7 +492,7 @@ function j() {
|
|
|
491
492
|
showSummary: {
|
|
492
493
|
title: "显示分组合计行",
|
|
493
494
|
type: "boolean",
|
|
494
|
-
visible: !!((
|
|
495
|
+
visible: !!((o = a.group) != null && o.enable),
|
|
495
496
|
$converter: "/converter/group.converter",
|
|
496
497
|
description: "显示分组合计行"
|
|
497
498
|
}
|
|
@@ -509,11 +510,11 @@ function j() {
|
|
|
509
510
|
function x() {
|
|
510
511
|
function i(a) {
|
|
511
512
|
var t, s;
|
|
512
|
-
const
|
|
513
|
-
{
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
},
|
|
513
|
+
const o = [
|
|
514
|
+
// {
|
|
515
|
+
// label: 'beforeUpdate',
|
|
516
|
+
// name: '更新数据前事件'
|
|
517
|
+
// },
|
|
517
518
|
{
|
|
518
519
|
label: "onClickRow",
|
|
519
520
|
name: "行点击事件"
|
|
@@ -531,7 +532,7 @@ function x() {
|
|
|
531
532
|
name: "过滤事件"
|
|
532
533
|
}
|
|
533
534
|
];
|
|
534
|
-
return a.type !== "tree-grid" &&
|
|
535
|
+
return a.type !== "tree-grid" && o.push(
|
|
535
536
|
{
|
|
536
537
|
label: "onSortChanged",
|
|
537
538
|
name: "排序事件"
|
|
@@ -552,7 +553,7 @@ function x() {
|
|
|
552
553
|
label: "onUnSelectAll",
|
|
553
554
|
name: "取消全选事件"
|
|
554
555
|
}
|
|
555
|
-
), ((t = a.pagination) == null ? void 0 : t.enable) !== !1 && a.type !== "tree-grid" &&
|
|
556
|
+
), ((t = a.pagination) == null ? void 0 : t.enable) !== !1 && a.type !== "tree-grid" && o.push(
|
|
556
557
|
{
|
|
557
558
|
label: "onPageIndexChanged",
|
|
558
559
|
name: "切换页码事件"
|
|
@@ -561,7 +562,7 @@ function x() {
|
|
|
561
562
|
label: "onPageSizeChanged",
|
|
562
563
|
name: "分页条数变化事件"
|
|
563
564
|
}
|
|
564
|
-
), (s = a.command) != null && s.enable &&
|
|
565
|
+
), (s = a.command) != null && s.enable && o.push(
|
|
565
566
|
{
|
|
566
567
|
label: "onClickEditCommand",
|
|
567
568
|
name: "操作列编辑事件"
|
|
@@ -574,13 +575,13 @@ function x() {
|
|
|
574
575
|
label: "onHandleAction",
|
|
575
576
|
name: "自定义操作列点击事件"
|
|
576
577
|
}
|
|
577
|
-
),
|
|
578
|
+
), o;
|
|
578
579
|
}
|
|
579
580
|
return { initEvent: i };
|
|
580
581
|
}
|
|
581
582
|
function ee() {
|
|
582
583
|
function i(a) {
|
|
583
|
-
var
|
|
584
|
+
var o, t, s;
|
|
584
585
|
return {
|
|
585
586
|
title: "多选配置",
|
|
586
587
|
$converter: "/converter/grid-selection.converter",
|
|
@@ -592,7 +593,7 @@ function ee() {
|
|
|
592
593
|
refreshPanelAfterChanged: !0
|
|
593
594
|
},
|
|
594
595
|
showCheckbox: {
|
|
595
|
-
visible: !!((
|
|
596
|
+
visible: !!((o = a.selection) != null && o.multiSelect),
|
|
596
597
|
$converter: "/converter/grid-selection.converter",
|
|
597
598
|
title: "显示复选框",
|
|
598
599
|
type: "boolean",
|
|
@@ -614,10 +615,10 @@ function ee() {
|
|
|
614
615
|
// type: 'boolean'
|
|
615
616
|
// }
|
|
616
617
|
},
|
|
617
|
-
setPropertyRelates(
|
|
618
|
-
switch (
|
|
618
|
+
setPropertyRelates(d, f) {
|
|
619
|
+
switch (d && d.propertyID) {
|
|
619
620
|
case "multiSelect":
|
|
620
|
-
a.selection.showCheckbox =
|
|
621
|
+
a.selection.showCheckbox = d.propertyValue;
|
|
621
622
|
break;
|
|
622
623
|
}
|
|
623
624
|
}
|
|
@@ -627,7 +628,7 @@ function ee() {
|
|
|
627
628
|
}
|
|
628
629
|
function te() {
|
|
629
630
|
function i(a) {
|
|
630
|
-
var
|
|
631
|
+
var o, t;
|
|
631
632
|
return {
|
|
632
633
|
title: "行号配置",
|
|
633
634
|
$converter: "/converter/row-number.converter",
|
|
@@ -639,7 +640,7 @@ function te() {
|
|
|
639
640
|
refreshPanelAfterChanged: !0
|
|
640
641
|
},
|
|
641
642
|
width: {
|
|
642
|
-
visible: !!((
|
|
643
|
+
visible: !!((o = a.rowNumber) != null && o.enable),
|
|
643
644
|
title: "宽度",
|
|
644
645
|
type: "number"
|
|
645
646
|
},
|
|
@@ -654,7 +655,7 @@ function te() {
|
|
|
654
655
|
return { getRowNumber: i };
|
|
655
656
|
}
|
|
656
657
|
function re() {
|
|
657
|
-
function i(a,
|
|
658
|
+
function i(a, o) {
|
|
658
659
|
var t, s;
|
|
659
660
|
return {
|
|
660
661
|
title: "分页",
|
|
@@ -666,7 +667,7 @@ function re() {
|
|
|
666
667
|
type: "boolean",
|
|
667
668
|
refreshPanelAfterChanged: !0,
|
|
668
669
|
editor: {
|
|
669
|
-
readonly:
|
|
670
|
+
readonly: o
|
|
670
671
|
}
|
|
671
672
|
},
|
|
672
673
|
// mode: {
|
|
@@ -741,7 +742,7 @@ function ne() {
|
|
|
741
742
|
type: "grid-field-editor",
|
|
742
743
|
viewModelId: s,
|
|
743
744
|
gridData: t,
|
|
744
|
-
getLatestGridData: (
|
|
745
|
+
getLatestGridData: (d) => t
|
|
745
746
|
},
|
|
746
747
|
// 这个属性,标记当属性变更得时候触发重新更新属性
|
|
747
748
|
refreshPanelAfterChanged: !0
|
|
@@ -761,19 +762,19 @@ function ne() {
|
|
|
761
762
|
// max: 1000
|
|
762
763
|
// },
|
|
763
764
|
},
|
|
764
|
-
setPropertyRelates(
|
|
765
|
-
switch (
|
|
765
|
+
setPropertyRelates(d, f) {
|
|
766
|
+
switch (d && d.propertyID) {
|
|
766
767
|
case "useBlankWhenDataIsEmpty":
|
|
767
768
|
t.emptyDataHeight = t.useBlankWhenDataIsEmpty ? 36 : 240;
|
|
768
769
|
break;
|
|
769
770
|
case "columns":
|
|
770
|
-
t.columns =
|
|
771
|
+
t.columns = d.propertyValue || [];
|
|
771
772
|
break;
|
|
772
773
|
}
|
|
773
774
|
}
|
|
774
775
|
};
|
|
775
776
|
}
|
|
776
|
-
function
|
|
777
|
+
function o(t, s) {
|
|
777
778
|
return {
|
|
778
779
|
title: "外观",
|
|
779
780
|
properties: {
|
|
@@ -808,19 +809,19 @@ function ne() {
|
|
|
808
809
|
// visible:false
|
|
809
810
|
// }
|
|
810
811
|
},
|
|
811
|
-
setPropertyRelates(
|
|
812
|
-
switch (
|
|
812
|
+
setPropertyRelates(d, f) {
|
|
813
|
+
switch (d && d.propertyID) {
|
|
813
814
|
case "useBlankWhenDataIsEmpty":
|
|
814
815
|
t.emptyDataHeight = t.useBlankWhenDataIsEmpty ? 36 : 240;
|
|
815
816
|
break;
|
|
816
817
|
case "fields":
|
|
817
|
-
t.fields =
|
|
818
|
+
t.fields = d.propertyValue || [];
|
|
818
819
|
break;
|
|
819
820
|
}
|
|
820
821
|
}
|
|
821
822
|
};
|
|
822
823
|
}
|
|
823
|
-
return { getDataGrid: a, getTreeGrid:
|
|
824
|
+
return { getDataGrid: a, getTreeGrid: o };
|
|
824
825
|
}
|
|
825
826
|
function ae() {
|
|
826
827
|
function i(a) {
|