@gisce/ooui 2.43.0-alpha.3 → 2.43.0
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/README.md +0 -2
- package/dist/SearchFilter.d.ts.map +1 -1
- package/dist/helpers/onChangeParser.d.ts.map +1 -1
- package/dist/index.d.ts +1 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/ooui.es.js +1421 -1634
- package/dist/ooui.es.js.map +1 -1
- package/package.json +1 -1
- package/src/SearchFilter.ts +0 -3
- package/src/helpers/onChangeParser.ts +1 -8
- package/src/index.ts +0 -4
- package/dist/Kanban.d.ts +0 -101
- package/dist/Kanban.d.ts.map +0 -1
- package/dist/KanbanCard.d.ts +0 -13
- package/dist/KanbanCard.d.ts.map +0 -1
- package/src/Kanban.ts +0 -315
- package/src/KanbanCard.ts +0 -84
- package/src/spec/Kanban.spec.ts +0 -402
- package/src/spec/kanbanCard.spec.ts +0 -217
package/dist/ooui.es.js
CHANGED
|
@@ -1,260 +1,260 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { decode as
|
|
5
|
-
import { evaluateCondition as
|
|
6
|
-
import * as
|
|
7
|
-
import
|
|
8
|
-
const
|
|
9
|
-
entry:
|
|
10
|
-
values:
|
|
11
|
-
fields:
|
|
1
|
+
var be = Object.defineProperty;
|
|
2
|
+
var ye = (i, t, e) => t in i ? be(i, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : i[t] = e;
|
|
3
|
+
var r = (i, t, e) => (ye(i, typeof t != "symbol" ? t + "" : t, e), e);
|
|
4
|
+
import { decode as xe } from "html-entities";
|
|
5
|
+
import { evaluateCondition as pe } from "@gisce/conscheck";
|
|
6
|
+
import * as D from "txml";
|
|
7
|
+
import W from "moment";
|
|
8
|
+
const we = (i = !1) => (i = JSON.parse(i.toString().toLowerCase()), +i > 0), ve = ({
|
|
9
|
+
entry: i,
|
|
10
|
+
values: t,
|
|
11
|
+
fields: e
|
|
12
12
|
}) => {
|
|
13
|
-
let [
|
|
14
|
-
const
|
|
15
|
-
fieldName:
|
|
16
|
-
valueInObject:
|
|
13
|
+
let [s, n, a] = i, l = t[s];
|
|
14
|
+
const o = X({
|
|
15
|
+
fieldName: s,
|
|
16
|
+
valueInObject: l,
|
|
17
17
|
expectedValue: a,
|
|
18
|
-
fields:
|
|
18
|
+
fields: e
|
|
19
19
|
});
|
|
20
|
-
if (
|
|
21
|
-
return
|
|
22
|
-
switch (
|
|
20
|
+
if (o.directOutcome !== void 0)
|
|
21
|
+
return o.directOutcome;
|
|
22
|
+
switch (o.modifiedValueInObject !== null && (l = o.modifiedValueInObject), o.modifiedExpectedValue !== null && (a = o.modifiedExpectedValue), n.toLowerCase()) {
|
|
23
23
|
case "=":
|
|
24
24
|
case "==":
|
|
25
|
-
return
|
|
25
|
+
return l == a;
|
|
26
26
|
case "<>":
|
|
27
27
|
case "!=":
|
|
28
|
-
return
|
|
28
|
+
return l != a;
|
|
29
29
|
case ">":
|
|
30
|
-
return
|
|
30
|
+
return l > a;
|
|
31
31
|
case ">=":
|
|
32
|
-
return
|
|
32
|
+
return l >= a;
|
|
33
33
|
case "<":
|
|
34
|
-
return
|
|
34
|
+
return l < a;
|
|
35
35
|
case "<=":
|
|
36
|
-
return
|
|
36
|
+
return l <= a;
|
|
37
37
|
case "in":
|
|
38
|
-
return a.includes(
|
|
38
|
+
return a.includes(l);
|
|
39
39
|
case "not in":
|
|
40
|
-
return !a.includes(
|
|
40
|
+
return !a.includes(l);
|
|
41
41
|
default:
|
|
42
42
|
return !1;
|
|
43
43
|
}
|
|
44
|
-
},
|
|
45
|
-
fieldName:
|
|
46
|
-
valueInObject:
|
|
47
|
-
expectedValue:
|
|
48
|
-
fields:
|
|
44
|
+
}, m = (i) => xe(i, { level: "xml" }), X = ({
|
|
45
|
+
fieldName: i,
|
|
46
|
+
valueInObject: t,
|
|
47
|
+
expectedValue: e,
|
|
48
|
+
fields: s = {}
|
|
49
49
|
}) => {
|
|
50
|
-
const
|
|
51
|
-
modifiedValueInObject:
|
|
50
|
+
const n = {
|
|
51
|
+
modifiedValueInObject: t,
|
|
52
52
|
modifiedExpectedValue: null,
|
|
53
53
|
directOutcome: void 0
|
|
54
54
|
};
|
|
55
|
-
return i
|
|
55
|
+
return s[i] === void 0 ? {
|
|
56
56
|
modifiedValueInObject: null,
|
|
57
57
|
modifiedExpectedValue: null,
|
|
58
58
|
directOutcome: !1
|
|
59
|
-
} :
|
|
59
|
+
} : t === void 0 && s[i].type !== "boolean" && s[i].type !== "many2one" && s[i].type !== "selection" && typeof e != "boolean" ? {
|
|
60
60
|
modifiedValueInObject: null,
|
|
61
61
|
modifiedExpectedValue: null,
|
|
62
62
|
directOutcome: !1
|
|
63
|
-
} : (
|
|
64
|
-
},
|
|
65
|
-
attrs:
|
|
66
|
-
values:
|
|
67
|
-
fields:
|
|
68
|
-
widgetType:
|
|
63
|
+
} : (n.modifiedValueInObject = s[i].type === "boolean" ? !!t : t, s[i].type === "many2one" && e === !1 && t === void 0 ? n.modifiedExpectedValue = void 0 : (n.modifiedValueInObject === void 0 ? n.modifiedValueInObject = !1 : Array.isArray(n.modifiedValueInObject) && n.modifiedValueInObject[0] !== void 0 && (n.modifiedValueInObject = n.modifiedValueInObject[0]), n.modifiedValueInObject === null && (n.modifiedValueInObject = !1)), s[i].type === "many2one" && Array.isArray(n.modifiedValueInObject) && n.modifiedValueInObject[0] === void 0 && (n.modifiedValueInObject = !1), s[i].type === "boolean" && (e === 0 || e === 1) && (n.modifiedExpectedValue = e !== 0), n);
|
|
64
|
+
}, J = ({
|
|
65
|
+
attrs: i,
|
|
66
|
+
values: t,
|
|
67
|
+
fields: e,
|
|
68
|
+
widgetType: s
|
|
69
69
|
}) => {
|
|
70
|
-
const
|
|
71
|
-
for (const
|
|
72
|
-
const x = u[
|
|
73
|
-
x ?
|
|
74
|
-
}
|
|
75
|
-
return
|
|
76
|
-
},
|
|
77
|
-
if (
|
|
70
|
+
const h = i.replace(/\(/g, "[").replace(/\)/g, "]").replace(/'/g, '"').replace(/True/g, "true").replace(/False/g, "false"), _ = m(h), u = JSON.parse(_), d = {};
|
|
71
|
+
for (const g of Object.keys(u)) {
|
|
72
|
+
const x = u[g].map((y) => ve({ entry: y, values: t, fields: e })).every((y) => y);
|
|
73
|
+
x ? d[g] = !0 : g === "readonly" && !x && s === "button" && (d[g] = !1);
|
|
74
|
+
}
|
|
75
|
+
return d;
|
|
76
|
+
}, U = (i) => {
|
|
77
|
+
if (i === void 0)
|
|
78
78
|
return {};
|
|
79
|
-
if (typeof
|
|
79
|
+
if (typeof i == "string")
|
|
80
80
|
try {
|
|
81
|
-
return JSON.parse(
|
|
81
|
+
return JSON.parse(i.replace(/'/g, '"'));
|
|
82
82
|
} catch {
|
|
83
83
|
return console.error("Error parsing widget_props"), {};
|
|
84
84
|
}
|
|
85
85
|
else
|
|
86
|
-
return
|
|
87
|
-
},
|
|
88
|
-
attrs:
|
|
89
|
-
values:
|
|
90
|
-
fields:
|
|
91
|
-
widgetType:
|
|
86
|
+
return i;
|
|
87
|
+
}, Fe = ({
|
|
88
|
+
attrs: i,
|
|
89
|
+
values: t,
|
|
90
|
+
fields: e,
|
|
91
|
+
widgetType: s
|
|
92
92
|
}) => {
|
|
93
93
|
try {
|
|
94
|
-
const
|
|
95
|
-
|
|
96
|
-
),
|
|
97
|
-
for (const
|
|
98
|
-
const
|
|
99
|
-
object:
|
|
100
|
-
condition: a[
|
|
94
|
+
const n = m(i), a = JSON.parse(
|
|
95
|
+
n.replace(/'/g, '"')
|
|
96
|
+
), l = {};
|
|
97
|
+
for (const o of Object.keys(a)) {
|
|
98
|
+
const h = pe({
|
|
99
|
+
object: t,
|
|
100
|
+
condition: a[o],
|
|
101
101
|
evaluateFieldComparison: ({
|
|
102
102
|
fieldName: _,
|
|
103
103
|
valueInObject: u,
|
|
104
|
-
expectedValue:
|
|
105
|
-
}) =>
|
|
104
|
+
expectedValue: d
|
|
105
|
+
}) => X({
|
|
106
106
|
fieldName: _,
|
|
107
107
|
valueInObject: u,
|
|
108
|
-
expectedValue:
|
|
109
|
-
fields:
|
|
108
|
+
expectedValue: d,
|
|
109
|
+
fields: e
|
|
110
110
|
})
|
|
111
111
|
});
|
|
112
|
-
|
|
112
|
+
h ? l[o] = !0 : o === "readonly" && !h && s === "button" && (l[o] = !1);
|
|
113
113
|
}
|
|
114
|
-
return
|
|
115
|
-
} catch (
|
|
116
|
-
throw console.error(
|
|
117
|
-
"Error parsing new json_attrs. Original string: " +
|
|
118
|
-
) :
|
|
119
|
-
}
|
|
120
|
-
},
|
|
121
|
-
tagAttributes:
|
|
122
|
-
values:
|
|
123
|
-
fields:
|
|
124
|
-
widgetType:
|
|
125
|
-
fallbackMode:
|
|
114
|
+
return l;
|
|
115
|
+
} catch (n) {
|
|
116
|
+
throw console.error(n), n instanceof SyntaxError ? new Error(
|
|
117
|
+
"Error parsing new json_attrs. Original string: " + i
|
|
118
|
+
) : n;
|
|
119
|
+
}
|
|
120
|
+
}, Ce = ({
|
|
121
|
+
tagAttributes: i,
|
|
122
|
+
values: t,
|
|
123
|
+
fields: e,
|
|
124
|
+
widgetType: s,
|
|
125
|
+
fallbackMode: n = !0
|
|
126
126
|
}) => {
|
|
127
127
|
let a = {};
|
|
128
|
-
if (
|
|
128
|
+
if (i.json_attrs)
|
|
129
129
|
try {
|
|
130
|
-
a =
|
|
131
|
-
attrs:
|
|
132
|
-
values:
|
|
133
|
-
fields:
|
|
134
|
-
widgetType:
|
|
130
|
+
a = Fe({
|
|
131
|
+
attrs: i.json_attrs,
|
|
132
|
+
values: t,
|
|
133
|
+
fields: e,
|
|
134
|
+
widgetType: s
|
|
135
135
|
});
|
|
136
|
-
} catch (
|
|
137
|
-
if (
|
|
138
|
-
a =
|
|
139
|
-
attrs:
|
|
140
|
-
values:
|
|
141
|
-
fields:
|
|
142
|
-
widgetType:
|
|
136
|
+
} catch (l) {
|
|
137
|
+
if (n && i.attrs)
|
|
138
|
+
a = J({
|
|
139
|
+
attrs: i.attrs,
|
|
140
|
+
values: t,
|
|
141
|
+
fields: e,
|
|
142
|
+
widgetType: s
|
|
143
143
|
});
|
|
144
144
|
else
|
|
145
|
-
throw
|
|
145
|
+
throw l;
|
|
146
146
|
}
|
|
147
147
|
else
|
|
148
|
-
|
|
149
|
-
attrs:
|
|
150
|
-
values:
|
|
151
|
-
fields:
|
|
152
|
-
widgetType:
|
|
148
|
+
i.attrs && (a = J({
|
|
149
|
+
attrs: i.attrs,
|
|
150
|
+
values: t,
|
|
151
|
+
fields: e,
|
|
152
|
+
widgetType: s
|
|
153
153
|
}));
|
|
154
154
|
return {
|
|
155
|
-
...
|
|
155
|
+
...i,
|
|
156
156
|
...a,
|
|
157
157
|
attrs: void 0,
|
|
158
158
|
json_attrs: void 0
|
|
159
159
|
};
|
|
160
|
-
},
|
|
161
|
-
constructor(
|
|
160
|
+
}, w = (i) => i === 1 || i === "1" || i === !0 || i === "True" || i === "true", P = class P {
|
|
161
|
+
constructor(t) {
|
|
162
162
|
/**
|
|
163
163
|
* Determines if widget is read only (default is undefined)
|
|
164
164
|
*/
|
|
165
|
-
|
|
165
|
+
r(this, "_readOnly");
|
|
166
166
|
/**
|
|
167
167
|
* Column span (default is 1)
|
|
168
168
|
*/
|
|
169
|
-
|
|
169
|
+
r(this, "_colspan");
|
|
170
170
|
/**
|
|
171
171
|
* Invisible fields (default is false)
|
|
172
172
|
*/
|
|
173
|
-
|
|
173
|
+
r(this, "_invisible");
|
|
174
174
|
/**
|
|
175
175
|
* Widget type
|
|
176
176
|
*/
|
|
177
|
-
|
|
177
|
+
r(this, "_type", "");
|
|
178
178
|
/**
|
|
179
179
|
* Context
|
|
180
180
|
*/
|
|
181
|
-
|
|
181
|
+
r(this, "_context");
|
|
182
182
|
/**
|
|
183
183
|
* Domain
|
|
184
184
|
*/
|
|
185
|
-
|
|
185
|
+
r(this, "_domain");
|
|
186
186
|
/**
|
|
187
187
|
* Unique key for widget
|
|
188
188
|
*/
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
189
|
+
r(this, "_key");
|
|
190
|
+
r(this, "_parsedWidgetProps", {});
|
|
191
|
+
r(this, "_isFunction");
|
|
192
|
+
r(this, "_isSortable", !1);
|
|
193
193
|
/**
|
|
194
194
|
* Base type of the field
|
|
195
195
|
*/
|
|
196
|
-
|
|
197
|
-
this._colspan = P._defaultColspan, this._invisible = !1,
|
|
196
|
+
r(this, "_fieldType", "");
|
|
197
|
+
this._colspan = P._defaultColspan, this._invisible = !1, t && (t.colspan && (this._colspan = +t.colspan), t.readonly !== void 0 && (this._readOnly = w(t.readonly)), t.invisible && (t.invisible === 1 || t.invisible === "1" || t.invisible === !0) && (this._invisible = !0), t.type && (this._type = t.type), t.context && (this._context = t.context), t.domain && (typeof t.domain != "string" ? this._domain = m(JSON.stringify(t.domain)) : this._domain = m(t.domain)), t.type && (this._fieldType = t.fieldsWidgetType), t.widget_props && (this._parsedWidgetProps = U(t.widget_props)), t.key && (this._key = t.key), t.is_function && (this._isFunction = t.is_function), t.is_sortable && (this._isSortable = t.is_sortable));
|
|
198
198
|
}
|
|
199
199
|
static get defaultColspan() {
|
|
200
200
|
return P._defaultColspan;
|
|
201
201
|
}
|
|
202
|
-
static set defaultColspan(
|
|
203
|
-
P._defaultColspan =
|
|
202
|
+
static set defaultColspan(t) {
|
|
203
|
+
P._defaultColspan = t;
|
|
204
204
|
}
|
|
205
205
|
get readOnly() {
|
|
206
206
|
return this._readOnly;
|
|
207
207
|
}
|
|
208
|
-
set readOnly(
|
|
209
|
-
this._readOnly =
|
|
208
|
+
set readOnly(t) {
|
|
209
|
+
this._readOnly = t;
|
|
210
210
|
}
|
|
211
211
|
get colspan() {
|
|
212
212
|
return this._colspan;
|
|
213
213
|
}
|
|
214
|
-
set colspan(
|
|
215
|
-
this._colspan = +
|
|
214
|
+
set colspan(t) {
|
|
215
|
+
this._colspan = +t;
|
|
216
216
|
}
|
|
217
217
|
get invisible() {
|
|
218
218
|
return this._invisible;
|
|
219
219
|
}
|
|
220
|
-
set invisible(
|
|
221
|
-
this._invisible =
|
|
220
|
+
set invisible(t) {
|
|
221
|
+
this._invisible = t;
|
|
222
222
|
}
|
|
223
223
|
get type() {
|
|
224
224
|
return this._type;
|
|
225
225
|
}
|
|
226
|
-
set type(
|
|
227
|
-
this._type =
|
|
226
|
+
set type(t) {
|
|
227
|
+
this._type = t;
|
|
228
228
|
}
|
|
229
229
|
get context() {
|
|
230
230
|
return this._context;
|
|
231
231
|
}
|
|
232
|
-
set context(
|
|
233
|
-
this._context =
|
|
232
|
+
set context(t) {
|
|
233
|
+
this._context = t;
|
|
234
234
|
}
|
|
235
235
|
get domain() {
|
|
236
236
|
return this._domain;
|
|
237
237
|
}
|
|
238
|
-
set domain(
|
|
239
|
-
this._domain =
|
|
238
|
+
set domain(t) {
|
|
239
|
+
this._domain = t;
|
|
240
240
|
}
|
|
241
241
|
get key() {
|
|
242
242
|
return this._key;
|
|
243
243
|
}
|
|
244
|
-
set key(
|
|
245
|
-
this._key =
|
|
244
|
+
set key(t) {
|
|
245
|
+
this._key = t;
|
|
246
246
|
}
|
|
247
247
|
get parsedWidgetProps() {
|
|
248
248
|
return this._parsedWidgetProps;
|
|
249
249
|
}
|
|
250
|
-
set parsedWidgetProps(
|
|
251
|
-
this._parsedWidgetProps =
|
|
250
|
+
set parsedWidgetProps(t) {
|
|
251
|
+
this._parsedWidgetProps = t;
|
|
252
252
|
}
|
|
253
253
|
get isFunction() {
|
|
254
254
|
return this._isFunction;
|
|
255
255
|
}
|
|
256
|
-
set isFunction(
|
|
257
|
-
this._isFunction =
|
|
256
|
+
set isFunction(t) {
|
|
257
|
+
this._isFunction = t;
|
|
258
258
|
}
|
|
259
259
|
get isSortable() {
|
|
260
260
|
return this._isSortable;
|
|
@@ -266,105 +266,105 @@ const Ct = (s = !1) => (s = JSON.parse(s.toString().toLowerCase()), +s > 0), kt
|
|
|
266
266
|
/**
|
|
267
267
|
* Default colspan
|
|
268
268
|
*/
|
|
269
|
-
|
|
269
|
+
r(P, "_defaultColspan", 1);
|
|
270
270
|
let k = P;
|
|
271
271
|
class f extends k {
|
|
272
|
-
constructor(
|
|
273
|
-
super(
|
|
272
|
+
constructor(e) {
|
|
273
|
+
super(e);
|
|
274
274
|
/**
|
|
275
275
|
* Field identifier
|
|
276
276
|
*
|
|
277
277
|
* Corresponds to the field's name attribute from xml
|
|
278
278
|
*/
|
|
279
|
-
|
|
279
|
+
r(this, "_id", "");
|
|
280
280
|
/**
|
|
281
281
|
* Label
|
|
282
282
|
*/
|
|
283
|
-
|
|
283
|
+
r(this, "_label", "");
|
|
284
284
|
/**
|
|
285
285
|
* No label
|
|
286
286
|
*
|
|
287
287
|
* This field hasn't got to show the label
|
|
288
288
|
*
|
|
289
289
|
*/
|
|
290
|
-
|
|
290
|
+
r(this, "_nolabel", !1);
|
|
291
291
|
/**
|
|
292
292
|
*
|
|
293
293
|
* Required field
|
|
294
294
|
*
|
|
295
295
|
*/
|
|
296
|
-
|
|
296
|
+
r(this, "_required", !1);
|
|
297
297
|
/**
|
|
298
298
|
* Tooltip
|
|
299
299
|
*/
|
|
300
|
-
|
|
300
|
+
r(this, "_tooltip");
|
|
301
301
|
/**
|
|
302
302
|
* Tooltip inline
|
|
303
303
|
*/
|
|
304
|
-
|
|
304
|
+
r(this, "_tooltipInline", !1);
|
|
305
305
|
/**
|
|
306
306
|
* Activated (default is true)
|
|
307
307
|
*/
|
|
308
|
-
|
|
308
|
+
r(this, "_activated", !0);
|
|
309
309
|
/**
|
|
310
310
|
* Sum - sum parameter (label), this will mean that we have to sum this field in the tree
|
|
311
311
|
*/
|
|
312
|
-
|
|
312
|
+
r(this, "_sum");
|
|
313
313
|
/**
|
|
314
314
|
* Values and keys
|
|
315
315
|
*/
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
this._activated = !0,
|
|
316
|
+
r(this, "_selectionValues", /* @__PURE__ */ new Map([]));
|
|
317
|
+
r(this, "_autoRefresh", !1);
|
|
318
|
+
r(this, "_raw_props");
|
|
319
|
+
this._activated = !0, e && (this._raw_props = e, e.name && (this._id = e.name), e.activated && (this._activated = e.activated), e.string && (this._label = m(e.string)), e.help && (this._tooltip = m(e.help)), e.nolabel && (e.nolabel === "1" || typeof e.nolabel == "boolean" && e.nolabel === !0) && (this._nolabel = !0), e.required && (e.required === "1" || e.required === !0 || e.required === "True") && (this._required = !0), e.sum && (this._sum = m(e.sum)), e.selection && (this._selectionValues = new Map(e.selection)), e.help_inline && (this.tooltipInline = we(e.help_inline)), e.autorefresh && (this.autoRefresh = w(e.autorefresh)));
|
|
320
320
|
}
|
|
321
321
|
get id() {
|
|
322
322
|
return this._id;
|
|
323
323
|
}
|
|
324
|
-
set id(
|
|
325
|
-
this._id =
|
|
324
|
+
set id(e) {
|
|
325
|
+
this._id = e;
|
|
326
326
|
}
|
|
327
327
|
get label() {
|
|
328
328
|
return this._label;
|
|
329
329
|
}
|
|
330
|
-
set label(
|
|
331
|
-
this._label =
|
|
330
|
+
set label(e) {
|
|
331
|
+
this._label = e;
|
|
332
332
|
}
|
|
333
333
|
get nolabel() {
|
|
334
334
|
return this._nolabel;
|
|
335
335
|
}
|
|
336
|
-
set nolabel(
|
|
337
|
-
this._nolabel =
|
|
336
|
+
set nolabel(e) {
|
|
337
|
+
this._nolabel = e;
|
|
338
338
|
}
|
|
339
339
|
get required() {
|
|
340
340
|
return this._required;
|
|
341
341
|
}
|
|
342
|
-
set required(
|
|
343
|
-
this._required =
|
|
342
|
+
set required(e) {
|
|
343
|
+
this._required = e;
|
|
344
344
|
}
|
|
345
345
|
get tooltip() {
|
|
346
346
|
return this._tooltip;
|
|
347
347
|
}
|
|
348
|
-
set tooltip(
|
|
349
|
-
this._tooltip =
|
|
348
|
+
set tooltip(e) {
|
|
349
|
+
this._tooltip = e;
|
|
350
350
|
}
|
|
351
351
|
get tooltipInline() {
|
|
352
352
|
return this._tooltipInline;
|
|
353
353
|
}
|
|
354
|
-
set tooltipInline(
|
|
355
|
-
this._tooltipInline =
|
|
354
|
+
set tooltipInline(e) {
|
|
355
|
+
this._tooltipInline = e;
|
|
356
356
|
}
|
|
357
357
|
get activated() {
|
|
358
358
|
return this._activated;
|
|
359
359
|
}
|
|
360
|
-
set activated(
|
|
361
|
-
this._activated =
|
|
360
|
+
set activated(e) {
|
|
361
|
+
this._activated = e;
|
|
362
362
|
}
|
|
363
363
|
get sum() {
|
|
364
364
|
return this._sum;
|
|
365
365
|
}
|
|
366
|
-
set sum(
|
|
367
|
-
this._sum =
|
|
366
|
+
set sum(e) {
|
|
367
|
+
this._sum = e;
|
|
368
368
|
}
|
|
369
369
|
get suffix() {
|
|
370
370
|
return this._parsedWidgetProps.suffix || "";
|
|
@@ -375,20 +375,20 @@ class f extends k {
|
|
|
375
375
|
get selectionValues() {
|
|
376
376
|
return this._selectionValues;
|
|
377
377
|
}
|
|
378
|
-
set selectionValues(
|
|
379
|
-
this._selectionValues =
|
|
378
|
+
set selectionValues(e) {
|
|
379
|
+
this._selectionValues = e;
|
|
380
380
|
}
|
|
381
381
|
get autoRefresh() {
|
|
382
382
|
return this._autoRefresh ?? !1;
|
|
383
383
|
}
|
|
384
|
-
set autoRefresh(
|
|
385
|
-
this._autoRefresh =
|
|
384
|
+
set autoRefresh(e) {
|
|
385
|
+
this._autoRefresh = e;
|
|
386
386
|
}
|
|
387
387
|
get readOnly() {
|
|
388
388
|
return this.autoRefresh ? !0 : super.readOnly;
|
|
389
389
|
}
|
|
390
|
-
set readOnly(
|
|
391
|
-
super.readOnly =
|
|
390
|
+
set readOnly(e) {
|
|
391
|
+
super.readOnly = e;
|
|
392
392
|
}
|
|
393
393
|
get raw_props() {
|
|
394
394
|
return this._raw_props;
|
|
@@ -397,119 +397,119 @@ class f extends k {
|
|
|
397
397
|
* Returns this instance in case this id matches param id.
|
|
398
398
|
* @param {string} id id (name) to find
|
|
399
399
|
*/
|
|
400
|
-
findById(
|
|
401
|
-
return this._id ===
|
|
400
|
+
findById(e) {
|
|
401
|
+
return this._id === e ? this : null;
|
|
402
402
|
}
|
|
403
403
|
}
|
|
404
|
-
class
|
|
404
|
+
class ke extends f {
|
|
405
405
|
}
|
|
406
|
-
class
|
|
407
|
-
findById(
|
|
406
|
+
class K extends k {
|
|
407
|
+
findById(t) {
|
|
408
408
|
return null;
|
|
409
409
|
}
|
|
410
410
|
}
|
|
411
|
-
class
|
|
412
|
-
constructor(
|
|
413
|
-
super({ ...
|
|
411
|
+
class Z extends f {
|
|
412
|
+
constructor(e) {
|
|
413
|
+
super({ ...e, nolabel: !0 });
|
|
414
414
|
/**
|
|
415
415
|
* Label text
|
|
416
416
|
*/
|
|
417
|
-
|
|
417
|
+
r(this, "_text", "");
|
|
418
418
|
/**
|
|
419
419
|
* Align text
|
|
420
420
|
*/
|
|
421
|
-
|
|
421
|
+
r(this, "_align", "left");
|
|
422
422
|
/**
|
|
423
423
|
* Label type
|
|
424
424
|
*/
|
|
425
|
-
|
|
425
|
+
r(this, "_labelType", "default");
|
|
426
426
|
/**
|
|
427
427
|
* Label size
|
|
428
428
|
*/
|
|
429
|
-
|
|
429
|
+
r(this, "_labelSize");
|
|
430
430
|
/**
|
|
431
431
|
* Id of the field that this label goes with. Null if it's an independent label
|
|
432
432
|
*/
|
|
433
|
-
|
|
434
|
-
|
|
433
|
+
r(this, "_fieldForLabel", null);
|
|
434
|
+
e != null && e.fieldForLabel && (this._fieldForLabel = e.fieldForLabel), e.widget_props && (this.parsedWidgetProps.label_type && (this.labelType = this.parsedWidgetProps.label_type), this.parsedWidgetProps.label_size && (this.labelSize = this.parsedWidgetProps.label_size)), e != null && e.align && (this.align = e.align);
|
|
435
435
|
}
|
|
436
436
|
get text() {
|
|
437
437
|
return this._text;
|
|
438
438
|
}
|
|
439
|
-
set text(
|
|
440
|
-
this._text =
|
|
439
|
+
set text(e) {
|
|
440
|
+
this._text = e;
|
|
441
441
|
}
|
|
442
442
|
get align() {
|
|
443
443
|
return this._align;
|
|
444
444
|
}
|
|
445
|
-
set align(
|
|
446
|
-
this._align =
|
|
445
|
+
set align(e) {
|
|
446
|
+
this._align = e;
|
|
447
447
|
}
|
|
448
448
|
get labelType() {
|
|
449
449
|
return this._labelType;
|
|
450
450
|
}
|
|
451
|
-
set labelType(
|
|
452
|
-
this._labelType =
|
|
451
|
+
set labelType(e) {
|
|
452
|
+
this._labelType = e;
|
|
453
453
|
}
|
|
454
454
|
get labelSize() {
|
|
455
455
|
return this._labelSize;
|
|
456
456
|
}
|
|
457
|
-
set labelSize(
|
|
458
|
-
this._labelSize =
|
|
457
|
+
set labelSize(e) {
|
|
458
|
+
this._labelSize = e;
|
|
459
459
|
}
|
|
460
460
|
get humanDate() {
|
|
461
|
-
var
|
|
462
|
-
return
|
|
461
|
+
var e;
|
|
462
|
+
return w(((e = this._parsedWidgetProps) == null ? void 0 : e.human_date) ?? !1);
|
|
463
463
|
}
|
|
464
464
|
get fieldForLabel() {
|
|
465
465
|
return this._fieldForLabel;
|
|
466
466
|
}
|
|
467
|
-
set fieldForLabel(
|
|
468
|
-
this._fieldForLabel =
|
|
467
|
+
set fieldForLabel(e) {
|
|
468
|
+
this._fieldForLabel = e;
|
|
469
469
|
}
|
|
470
470
|
}
|
|
471
|
-
class
|
|
472
|
-
constructor(
|
|
471
|
+
class V {
|
|
472
|
+
constructor(t = 4, e = 6, s = !1, n = void 0) {
|
|
473
473
|
/**
|
|
474
474
|
* Number of columns the container is divided
|
|
475
475
|
*/
|
|
476
|
-
|
|
476
|
+
r(this, "_columns");
|
|
477
477
|
/**
|
|
478
478
|
* Number of columns to use
|
|
479
479
|
*/
|
|
480
|
-
|
|
480
|
+
r(this, "_colspan");
|
|
481
481
|
/**
|
|
482
482
|
* Number of rows
|
|
483
483
|
*/
|
|
484
|
-
|
|
485
|
-
|
|
484
|
+
r(this, "_rows");
|
|
485
|
+
r(this, "_index");
|
|
486
486
|
/**
|
|
487
487
|
* Determines if widget is read only (default is false)
|
|
488
488
|
*/
|
|
489
|
-
|
|
489
|
+
r(this, "_readOnly");
|
|
490
490
|
/**
|
|
491
491
|
* Unique key for container
|
|
492
492
|
*/
|
|
493
|
-
|
|
494
|
-
this._columns =
|
|
493
|
+
r(this, "_key");
|
|
494
|
+
this._columns = t, this._colspan = e, this._rows = [[]], this._index = 0, this._readOnly = s, this._key = n;
|
|
495
495
|
}
|
|
496
496
|
get columns() {
|
|
497
497
|
return this._columns;
|
|
498
498
|
}
|
|
499
|
-
set columns(
|
|
500
|
-
this._columns =
|
|
499
|
+
set columns(t) {
|
|
500
|
+
this._columns = t;
|
|
501
501
|
}
|
|
502
502
|
get colspan() {
|
|
503
503
|
return this._colspan;
|
|
504
504
|
}
|
|
505
|
-
set colspan(
|
|
506
|
-
this._colspan =
|
|
505
|
+
set colspan(t) {
|
|
506
|
+
this._colspan = t;
|
|
507
507
|
}
|
|
508
508
|
get rows() {
|
|
509
509
|
return this._rows;
|
|
510
510
|
}
|
|
511
|
-
set rows(
|
|
512
|
-
this._rows =
|
|
511
|
+
set rows(t) {
|
|
512
|
+
this._rows = t;
|
|
513
513
|
}
|
|
514
514
|
get index() {
|
|
515
515
|
return this._index;
|
|
@@ -517,344 +517,344 @@ class z {
|
|
|
517
517
|
get readOnly() {
|
|
518
518
|
return this._readOnly;
|
|
519
519
|
}
|
|
520
|
-
set readOnly(
|
|
521
|
-
this._readOnly =
|
|
520
|
+
set readOnly(t) {
|
|
521
|
+
this._readOnly = t;
|
|
522
522
|
}
|
|
523
523
|
get key() {
|
|
524
524
|
return this._key;
|
|
525
525
|
}
|
|
526
|
-
set key(
|
|
527
|
-
this._key =
|
|
526
|
+
set key(t) {
|
|
527
|
+
this._key = t;
|
|
528
528
|
}
|
|
529
529
|
/**
|
|
530
530
|
* Returns the next free position
|
|
531
531
|
*/
|
|
532
532
|
freePosition() {
|
|
533
|
-
const
|
|
534
|
-
return this._columns -
|
|
533
|
+
const t = this._rows[this._index].filter((e) => !e.invisible).reduce((e, s) => e + s.colspan, 0);
|
|
534
|
+
return this._columns - t;
|
|
535
535
|
}
|
|
536
|
-
addWidget(
|
|
537
|
-
const
|
|
538
|
-
if (
|
|
536
|
+
addWidget(t, e) {
|
|
537
|
+
const s = [], n = e ? e.addLabel : !0;
|
|
538
|
+
if (t instanceof K) {
|
|
539
539
|
this._rows.push([]), this._index++;
|
|
540
540
|
return;
|
|
541
541
|
}
|
|
542
|
-
if (
|
|
543
|
-
|
|
544
|
-
const
|
|
545
|
-
name:
|
|
546
|
-
string:
|
|
547
|
-
invisible:
|
|
548
|
-
help:
|
|
549
|
-
fieldForLabel:
|
|
550
|
-
key: `${
|
|
542
|
+
if (t.colspan > this._columns && (t.colspan = this._columns), t.readOnly = t.readOnly || this.readOnly, n && t instanceof f && !t.nolabel) {
|
|
543
|
+
t.colspan > 1 && (t.colspan -= 1);
|
|
544
|
+
const l = new Z({
|
|
545
|
+
name: t.id + "_label",
|
|
546
|
+
string: t.label,
|
|
547
|
+
invisible: t.invisible,
|
|
548
|
+
help: t.tooltip,
|
|
549
|
+
fieldForLabel: t.id,
|
|
550
|
+
key: `${t.key}-label`
|
|
551
551
|
});
|
|
552
|
-
|
|
552
|
+
l.type = "label", s.push(l), s.push(t);
|
|
553
553
|
} else
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
(
|
|
554
|
+
s.push(t);
|
|
555
|
+
s.reduce(
|
|
556
|
+
(l, o) => l + o.colspan,
|
|
557
557
|
0
|
|
558
|
-
) > this.freePosition() && (this._rows.push([]), this._index++), this._rows[this._index] = this._rows[this._index].concat(
|
|
558
|
+
) > this.freePosition() && (this._rows.push([]), this._index++), this._rows[this._index] = this._rows[this._index].concat(s);
|
|
559
559
|
}
|
|
560
560
|
/**
|
|
561
561
|
* Traverses children to find a matching container or widget with the exact same id.
|
|
562
562
|
* @param {string} id id (name) of the field or container to find
|
|
563
563
|
*/
|
|
564
|
-
findById(
|
|
565
|
-
var
|
|
566
|
-
let
|
|
567
|
-
return (
|
|
568
|
-
|
|
569
|
-
|
|
564
|
+
findById(t) {
|
|
565
|
+
var s;
|
|
566
|
+
let e = null;
|
|
567
|
+
return (s = this._rows) != null && s.length && this._rows.forEach((n) => {
|
|
568
|
+
e || n != null && n.length && n.forEach((a) => {
|
|
569
|
+
e || a && (e = a.findById(t));
|
|
570
570
|
});
|
|
571
|
-
}),
|
|
571
|
+
}), e;
|
|
572
572
|
}
|
|
573
573
|
}
|
|
574
574
|
const O = class O extends k {
|
|
575
|
-
constructor(
|
|
576
|
-
super(
|
|
575
|
+
constructor(e) {
|
|
576
|
+
super(e);
|
|
577
577
|
/**
|
|
578
578
|
* Field identifier
|
|
579
579
|
*
|
|
580
580
|
* Corresponds to the field's name attribute from xml
|
|
581
581
|
*/
|
|
582
|
-
|
|
582
|
+
r(this, "_id", "");
|
|
583
583
|
/**
|
|
584
584
|
* Container
|
|
585
585
|
*/
|
|
586
|
-
|
|
586
|
+
r(this, "_container");
|
|
587
587
|
/**
|
|
588
588
|
* Must expand widget
|
|
589
589
|
*/
|
|
590
|
-
|
|
590
|
+
r(this, "_mustExpand", !1);
|
|
591
591
|
/**
|
|
592
592
|
* Container label
|
|
593
593
|
*/
|
|
594
|
-
|
|
595
|
-
this._container = new
|
|
596
|
-
|
|
594
|
+
r(this, "_label", "");
|
|
595
|
+
this._container = new V(
|
|
596
|
+
e == null ? void 0 : e.col,
|
|
597
597
|
O._defaultColspan,
|
|
598
598
|
this.readOnly,
|
|
599
|
-
|
|
600
|
-
),
|
|
599
|
+
e == null ? void 0 : e.key
|
|
600
|
+
), e && (e.name && (this._id = e.name), e.colspan ? this._container.colspan = +e.colspan : this._mustExpand = !0, e.string && (this._label = m(e.string)));
|
|
601
601
|
}
|
|
602
602
|
get id() {
|
|
603
603
|
return this._id;
|
|
604
604
|
}
|
|
605
|
-
set id(
|
|
606
|
-
this._id =
|
|
605
|
+
set id(e) {
|
|
606
|
+
this._id = e;
|
|
607
607
|
}
|
|
608
608
|
static get defaultColspan() {
|
|
609
609
|
return O._defaultColspan;
|
|
610
610
|
}
|
|
611
|
-
static set defaultColspan(
|
|
612
|
-
O._defaultColspan =
|
|
611
|
+
static set defaultColspan(e) {
|
|
612
|
+
O._defaultColspan = e;
|
|
613
613
|
}
|
|
614
614
|
get container() {
|
|
615
615
|
return this._container;
|
|
616
616
|
}
|
|
617
|
-
set container(
|
|
618
|
-
this._container =
|
|
617
|
+
set container(e) {
|
|
618
|
+
this._container = e;
|
|
619
619
|
}
|
|
620
620
|
get colspan() {
|
|
621
621
|
return this._container.colspan;
|
|
622
622
|
}
|
|
623
|
-
set colspan(
|
|
624
|
-
this._container.colspan = +
|
|
623
|
+
set colspan(e) {
|
|
624
|
+
this._container.colspan = +e;
|
|
625
625
|
}
|
|
626
626
|
get mustExpand() {
|
|
627
627
|
return this._mustExpand;
|
|
628
628
|
}
|
|
629
|
-
set mustExpand(
|
|
630
|
-
this._mustExpand =
|
|
629
|
+
set mustExpand(e) {
|
|
630
|
+
this._mustExpand = e;
|
|
631
631
|
}
|
|
632
632
|
get label() {
|
|
633
633
|
return this._label;
|
|
634
634
|
}
|
|
635
|
-
set label(
|
|
636
|
-
this._label =
|
|
635
|
+
set label(e) {
|
|
636
|
+
this._label = e;
|
|
637
637
|
}
|
|
638
638
|
/**
|
|
639
639
|
* Calls container's findById method to find the widgets matching with param id
|
|
640
640
|
* @param {string} id id to find
|
|
641
641
|
*/
|
|
642
|
-
findById(
|
|
643
|
-
return
|
|
642
|
+
findById(e) {
|
|
643
|
+
return e === this.id ? this : this.container.findById(e);
|
|
644
644
|
}
|
|
645
645
|
};
|
|
646
|
-
|
|
647
|
-
let
|
|
648
|
-
const
|
|
649
|
-
constructor(
|
|
650
|
-
super(
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
this.colspan =
|
|
646
|
+
r(O, "_defaultColspan", 6);
|
|
647
|
+
let v = O;
|
|
648
|
+
const T = class T extends v {
|
|
649
|
+
constructor(e) {
|
|
650
|
+
super(e);
|
|
651
|
+
r(this, "_tabPosition", "top");
|
|
652
|
+
r(this, "_pages", []);
|
|
653
|
+
this.colspan = T._defaultColspan, e && (e.colspan && (this.colspan = e.colspan), e.tabpos && (this._tabPosition = e.tabpos));
|
|
654
654
|
}
|
|
655
655
|
static get defaultColspan() {
|
|
656
|
-
return
|
|
656
|
+
return T._defaultColspan;
|
|
657
657
|
}
|
|
658
|
-
static set defaultColspan(
|
|
659
|
-
|
|
658
|
+
static set defaultColspan(e) {
|
|
659
|
+
T._defaultColspan = e;
|
|
660
660
|
}
|
|
661
661
|
get tabPosition() {
|
|
662
662
|
return this._tabPosition;
|
|
663
663
|
}
|
|
664
|
-
set tabPosition(
|
|
665
|
-
this._tabPosition =
|
|
664
|
+
set tabPosition(e) {
|
|
665
|
+
this._tabPosition = e;
|
|
666
666
|
}
|
|
667
667
|
get pages() {
|
|
668
668
|
return [].concat.apply([], this._container.rows);
|
|
669
669
|
}
|
|
670
670
|
};
|
|
671
|
-
|
|
672
|
-
let
|
|
673
|
-
class
|
|
674
|
-
constructor(
|
|
675
|
-
super(
|
|
676
|
-
|
|
677
|
-
|
|
671
|
+
r(T, "_defaultColspan", 3);
|
|
672
|
+
let N = T;
|
|
673
|
+
class j extends v {
|
|
674
|
+
constructor(e) {
|
|
675
|
+
super(e);
|
|
676
|
+
r(this, "_loading", !1);
|
|
677
|
+
e && e.loading && (this._loading = e.loading);
|
|
678
678
|
}
|
|
679
679
|
get loading() {
|
|
680
680
|
return this._loading;
|
|
681
681
|
}
|
|
682
|
-
set loading(
|
|
683
|
-
this._loading =
|
|
682
|
+
set loading(e) {
|
|
683
|
+
this._loading = e;
|
|
684
684
|
}
|
|
685
685
|
}
|
|
686
|
-
class
|
|
687
|
-
constructor(
|
|
688
|
-
super(
|
|
689
|
-
|
|
690
|
-
|
|
686
|
+
class Pe extends j {
|
|
687
|
+
constructor(e) {
|
|
688
|
+
super(e);
|
|
689
|
+
r(this, "_icon", null);
|
|
690
|
+
e.icon && (this._icon = e.icon);
|
|
691
691
|
}
|
|
692
692
|
get icon() {
|
|
693
693
|
return this._icon;
|
|
694
694
|
}
|
|
695
|
-
set icon(
|
|
696
|
-
this._icon =
|
|
695
|
+
set icon(e) {
|
|
696
|
+
this._icon = e;
|
|
697
697
|
}
|
|
698
698
|
}
|
|
699
|
-
class
|
|
700
|
-
constructor(
|
|
701
|
-
var
|
|
702
|
-
super(
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
if (
|
|
699
|
+
class Oe extends j {
|
|
700
|
+
constructor(e) {
|
|
701
|
+
var s;
|
|
702
|
+
super(e);
|
|
703
|
+
r(this, "_icon", null);
|
|
704
|
+
r(this, "_height");
|
|
705
|
+
r(this, "_backgroundColor");
|
|
706
|
+
if (e && (e.icon && (this._icon = e.icon), e.height))
|
|
707
707
|
try {
|
|
708
|
-
this._height = parseInt(
|
|
708
|
+
this._height = parseInt(e.height);
|
|
709
709
|
} catch {
|
|
710
710
|
console.log("Error parsing height"), this._height = void 0;
|
|
711
711
|
}
|
|
712
|
-
(
|
|
712
|
+
(s = this._parsedWidgetProps) != null && s.backgroundColor && (this._backgroundColor = this._parsedWidgetProps.backgroundColor);
|
|
713
713
|
}
|
|
714
714
|
get icon() {
|
|
715
715
|
return this._icon;
|
|
716
716
|
}
|
|
717
|
-
set icon(
|
|
718
|
-
this._icon =
|
|
717
|
+
set icon(e) {
|
|
718
|
+
this._icon = e;
|
|
719
719
|
}
|
|
720
720
|
get height() {
|
|
721
721
|
return this._height;
|
|
722
722
|
}
|
|
723
|
-
set height(
|
|
724
|
-
this._height =
|
|
723
|
+
set height(e) {
|
|
724
|
+
this._height = e;
|
|
725
725
|
}
|
|
726
726
|
get backgroundColor() {
|
|
727
727
|
return this._backgroundColor;
|
|
728
728
|
}
|
|
729
|
-
set backgroundColor(
|
|
730
|
-
this._backgroundColor =
|
|
729
|
+
set backgroundColor(e) {
|
|
730
|
+
this._backgroundColor = e;
|
|
731
731
|
}
|
|
732
732
|
}
|
|
733
|
-
class
|
|
734
|
-
constructor(
|
|
733
|
+
class ee extends f {
|
|
734
|
+
constructor(e) {
|
|
735
735
|
super({
|
|
736
|
-
...
|
|
737
|
-
nolabel: (
|
|
736
|
+
...e,
|
|
737
|
+
nolabel: (e == null ? void 0 : e.nolabel) !== void 0 ? e.nolabel : !0
|
|
738
738
|
});
|
|
739
739
|
/**
|
|
740
740
|
* Type
|
|
741
741
|
*/
|
|
742
|
-
|
|
742
|
+
r(this, "_buttonType", "workflow");
|
|
743
743
|
/**
|
|
744
744
|
* Button caption
|
|
745
745
|
*/
|
|
746
|
-
|
|
746
|
+
r(this, "_caption", "");
|
|
747
747
|
/**
|
|
748
748
|
* Button icon
|
|
749
749
|
*/
|
|
750
|
-
|
|
750
|
+
r(this, "_icon");
|
|
751
751
|
/**
|
|
752
752
|
* Confirm string for modal in button types workflow
|
|
753
753
|
*/
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
if (
|
|
758
|
-
if (
|
|
759
|
-
const
|
|
760
|
-
(
|
|
754
|
+
r(this, "_confirmMessage", "");
|
|
755
|
+
r(this, "_primary", !1);
|
|
756
|
+
r(this, "_danger", !1);
|
|
757
|
+
if (e) {
|
|
758
|
+
if (e.string && (this._caption = m(e.string)), e.buttonType && (this._buttonType = e.buttonType), e.confirm && (this._confirmMessage = m(e.confirm)), e.special && e.special === "cancel" && (this._buttonType = "cancel"), e.icon && (this._icon = e.icon), e.primary) {
|
|
759
|
+
const s = e.primary;
|
|
760
|
+
(s === "1" || s === 1 || s === !0) && (this._primary = !0);
|
|
761
761
|
}
|
|
762
|
-
if (
|
|
763
|
-
const
|
|
764
|
-
(
|
|
762
|
+
if (e.danger) {
|
|
763
|
+
const s = e.danger;
|
|
764
|
+
(s === "1" || s === 1 || s === !0) && (this._danger = !0);
|
|
765
765
|
}
|
|
766
766
|
}
|
|
767
767
|
}
|
|
768
768
|
get buttonType() {
|
|
769
769
|
return this._buttonType;
|
|
770
770
|
}
|
|
771
|
-
set buttonType(
|
|
772
|
-
this._buttonType =
|
|
771
|
+
set buttonType(e) {
|
|
772
|
+
this._buttonType = e;
|
|
773
773
|
}
|
|
774
774
|
get caption() {
|
|
775
775
|
return this._caption;
|
|
776
776
|
}
|
|
777
|
-
set caption(
|
|
778
|
-
this._caption =
|
|
777
|
+
set caption(e) {
|
|
778
|
+
this._caption = e;
|
|
779
779
|
}
|
|
780
780
|
get icon() {
|
|
781
781
|
return this._icon;
|
|
782
782
|
}
|
|
783
|
-
set icon(
|
|
784
|
-
this._icon =
|
|
783
|
+
set icon(e) {
|
|
784
|
+
this._icon = e;
|
|
785
785
|
}
|
|
786
786
|
get confirmMessage() {
|
|
787
787
|
return this._confirmMessage;
|
|
788
788
|
}
|
|
789
|
-
set confirmMessage(
|
|
790
|
-
this._confirmMessage =
|
|
789
|
+
set confirmMessage(e) {
|
|
790
|
+
this._confirmMessage = e;
|
|
791
791
|
}
|
|
792
792
|
get primary() {
|
|
793
793
|
return this._primary;
|
|
794
794
|
}
|
|
795
|
-
set primary(
|
|
796
|
-
this._primary =
|
|
795
|
+
set primary(e) {
|
|
796
|
+
this._primary = e;
|
|
797
797
|
}
|
|
798
798
|
get danger() {
|
|
799
799
|
return this._danger;
|
|
800
800
|
}
|
|
801
|
-
set danger(
|
|
802
|
-
this._danger =
|
|
801
|
+
set danger(e) {
|
|
802
|
+
this._danger = e;
|
|
803
803
|
}
|
|
804
804
|
}
|
|
805
|
-
class
|
|
806
|
-
constructor(
|
|
807
|
-
super(
|
|
808
|
-
|
|
809
|
-
|
|
805
|
+
class Te extends v {
|
|
806
|
+
constructor(e) {
|
|
807
|
+
super(e);
|
|
808
|
+
r(this, "_defaultName", "");
|
|
809
|
+
e.default && (this._defaultName = e.default);
|
|
810
810
|
}
|
|
811
811
|
get defaultName() {
|
|
812
812
|
return this._defaultName;
|
|
813
813
|
}
|
|
814
814
|
get defaultButton() {
|
|
815
|
-
return this.buttons.find((
|
|
815
|
+
return this.buttons.find((s) => s.id === this.defaultName) || this.buttons[0];
|
|
816
816
|
}
|
|
817
817
|
get colspan() {
|
|
818
|
-
var
|
|
819
|
-
return ((
|
|
818
|
+
var e;
|
|
819
|
+
return ((e = this.defaultButton) == null ? void 0 : e.colspan) || 1;
|
|
820
820
|
}
|
|
821
|
-
set colspan(
|
|
822
|
-
this.defaultButton && (this.defaultButton.colspan =
|
|
821
|
+
set colspan(e) {
|
|
822
|
+
this.defaultButton && (this.defaultButton.colspan = e);
|
|
823
823
|
}
|
|
824
824
|
get secondaryButtons() {
|
|
825
825
|
return this.buttons.filter(
|
|
826
|
-
(
|
|
827
|
-
var
|
|
828
|
-
return
|
|
826
|
+
(s) => {
|
|
827
|
+
var n;
|
|
828
|
+
return s.id !== ((n = this.defaultButton) == null ? void 0 : n.id);
|
|
829
829
|
}
|
|
830
830
|
);
|
|
831
831
|
}
|
|
832
832
|
get buttons() {
|
|
833
|
-
return this._container.rows.flat().filter((
|
|
833
|
+
return this._container.rows.flat().filter((e) => !e.invisible);
|
|
834
834
|
}
|
|
835
835
|
}
|
|
836
|
-
class
|
|
836
|
+
class We extends f {
|
|
837
837
|
}
|
|
838
|
-
class
|
|
839
|
-
constructor(
|
|
840
|
-
super(
|
|
838
|
+
class A extends f {
|
|
839
|
+
constructor(e) {
|
|
840
|
+
super(e);
|
|
841
841
|
/**
|
|
842
842
|
* Field place holder
|
|
843
843
|
*/
|
|
844
|
-
|
|
844
|
+
r(this, "_placeholder", "");
|
|
845
845
|
/**
|
|
846
846
|
* Field size
|
|
847
847
|
*/
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
848
|
+
r(this, "_size");
|
|
849
|
+
r(this, "_isPassword", !1);
|
|
850
|
+
r(this, "_translatable", !1);
|
|
851
|
+
e && (e.size && (this._size = e.size), e.password && (this.isPassword = e.password === "True"), e.translate && (this.translatable = e.translate === "True" || e.translate === !0));
|
|
852
852
|
}
|
|
853
853
|
get placeholder() {
|
|
854
854
|
return this._placeholder;
|
|
855
855
|
}
|
|
856
|
-
set placeholder(
|
|
857
|
-
this._placeholder =
|
|
856
|
+
set placeholder(e) {
|
|
857
|
+
this._placeholder = e;
|
|
858
858
|
}
|
|
859
859
|
get showCount() {
|
|
860
860
|
return this.parsedWidgetProps.showCount || !1;
|
|
@@ -862,57 +862,57 @@ class R extends f {
|
|
|
862
862
|
get size() {
|
|
863
863
|
return this._size;
|
|
864
864
|
}
|
|
865
|
-
set size(
|
|
866
|
-
this._size =
|
|
865
|
+
set size(e) {
|
|
866
|
+
this._size = e;
|
|
867
867
|
}
|
|
868
868
|
get isPassword() {
|
|
869
869
|
return this._isPassword;
|
|
870
870
|
}
|
|
871
|
-
set isPassword(
|
|
872
|
-
this._isPassword =
|
|
871
|
+
set isPassword(e) {
|
|
872
|
+
this._isPassword = e;
|
|
873
873
|
}
|
|
874
874
|
get translatable() {
|
|
875
875
|
return this._translatable;
|
|
876
876
|
}
|
|
877
|
-
set translatable(
|
|
878
|
-
this._translatable =
|
|
877
|
+
set translatable(e) {
|
|
878
|
+
this._translatable = e;
|
|
879
879
|
}
|
|
880
880
|
}
|
|
881
|
-
class
|
|
882
|
-
constructor(
|
|
883
|
-
super(
|
|
881
|
+
class L extends f {
|
|
882
|
+
constructor(e) {
|
|
883
|
+
super(e);
|
|
884
884
|
/**
|
|
885
885
|
* Field place holder
|
|
886
886
|
*/
|
|
887
|
-
|
|
887
|
+
r(this, "_placeholder", "");
|
|
888
888
|
/**
|
|
889
889
|
* Field size
|
|
890
890
|
*/
|
|
891
|
-
|
|
891
|
+
r(this, "_size");
|
|
892
892
|
/**
|
|
893
893
|
* Must expand widget
|
|
894
894
|
*/
|
|
895
|
-
|
|
895
|
+
r(this, "_mustExpand", !1);
|
|
896
896
|
/**
|
|
897
897
|
* Height
|
|
898
898
|
*/
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
if (
|
|
902
|
-
if (
|
|
899
|
+
r(this, "_height");
|
|
900
|
+
r(this, "_translatable", !1);
|
|
901
|
+
if (e) {
|
|
902
|
+
if (e.placeholder && (this._placeholder = m(e.placeholder)), e.colspan || (this._mustExpand = !0), e.height)
|
|
903
903
|
try {
|
|
904
|
-
this._height = parseInt(
|
|
904
|
+
this._height = parseInt(e.height);
|
|
905
905
|
} catch {
|
|
906
906
|
this._height = void 0;
|
|
907
907
|
}
|
|
908
|
-
|
|
908
|
+
e.translate && (this.translatable = e.translate === "True" || e.translate === !0), e.size && (this.size = parseInt(e.size));
|
|
909
909
|
}
|
|
910
910
|
}
|
|
911
911
|
get placeholder() {
|
|
912
912
|
return this._placeholder;
|
|
913
913
|
}
|
|
914
|
-
set placeholder(
|
|
915
|
-
this._placeholder =
|
|
914
|
+
set placeholder(e) {
|
|
915
|
+
this._placeholder = e;
|
|
916
916
|
}
|
|
917
917
|
get showCount() {
|
|
918
918
|
return this.parsedWidgetProps.showCount || !1;
|
|
@@ -920,68 +920,68 @@ class $ extends f {
|
|
|
920
920
|
get size() {
|
|
921
921
|
return this._size;
|
|
922
922
|
}
|
|
923
|
-
set size(
|
|
924
|
-
this._size =
|
|
923
|
+
set size(e) {
|
|
924
|
+
this._size = e;
|
|
925
925
|
}
|
|
926
926
|
get mustExpand() {
|
|
927
927
|
return this._mustExpand;
|
|
928
928
|
}
|
|
929
|
-
set mustExpand(
|
|
930
|
-
this._mustExpand =
|
|
929
|
+
set mustExpand(e) {
|
|
930
|
+
this._mustExpand = e;
|
|
931
931
|
}
|
|
932
932
|
get height() {
|
|
933
933
|
return this._height;
|
|
934
934
|
}
|
|
935
|
-
set height(
|
|
936
|
-
this._height =
|
|
935
|
+
set height(e) {
|
|
936
|
+
this._height = e;
|
|
937
937
|
}
|
|
938
938
|
get translatable() {
|
|
939
939
|
return this._translatable;
|
|
940
940
|
}
|
|
941
|
-
set translatable(
|
|
942
|
-
this._translatable =
|
|
941
|
+
set translatable(e) {
|
|
942
|
+
this._translatable = e;
|
|
943
943
|
}
|
|
944
944
|
}
|
|
945
|
-
class
|
|
946
|
-
constructor(
|
|
947
|
-
super(
|
|
945
|
+
class z extends f {
|
|
946
|
+
constructor(e) {
|
|
947
|
+
super(e);
|
|
948
948
|
/**
|
|
949
949
|
* Field size
|
|
950
950
|
*/
|
|
951
|
-
|
|
952
|
-
|
|
951
|
+
r(this, "_size", 150);
|
|
952
|
+
e && e.size && (this._size = e.size);
|
|
953
953
|
}
|
|
954
954
|
get size() {
|
|
955
955
|
return this._size;
|
|
956
956
|
}
|
|
957
|
-
set size(
|
|
958
|
-
this._size =
|
|
957
|
+
set size(e) {
|
|
958
|
+
this._size = e;
|
|
959
959
|
}
|
|
960
960
|
}
|
|
961
|
-
class
|
|
962
|
-
constructor(
|
|
963
|
-
super(
|
|
961
|
+
class ze extends f {
|
|
962
|
+
constructor(e) {
|
|
963
|
+
super(e);
|
|
964
964
|
/**
|
|
965
965
|
* Field size
|
|
966
966
|
*/
|
|
967
|
-
|
|
967
|
+
r(this, "_size", 150);
|
|
968
968
|
/**
|
|
969
969
|
* Relation
|
|
970
970
|
*/
|
|
971
|
-
|
|
972
|
-
|
|
971
|
+
r(this, "_relation", "");
|
|
972
|
+
e && (e.size && (this._size = e.size), e.relation && (this._relation = e.relation));
|
|
973
973
|
}
|
|
974
974
|
get size() {
|
|
975
975
|
return this._size;
|
|
976
976
|
}
|
|
977
|
-
set size(
|
|
978
|
-
this._size =
|
|
977
|
+
set size(e) {
|
|
978
|
+
this._size = e;
|
|
979
979
|
}
|
|
980
980
|
get relation() {
|
|
981
981
|
return this._relation;
|
|
982
982
|
}
|
|
983
|
-
set relation(
|
|
984
|
-
this._relation =
|
|
983
|
+
set relation(e) {
|
|
984
|
+
this._relation = e;
|
|
985
985
|
}
|
|
986
986
|
get showFolder() {
|
|
987
987
|
return this.parsedWidgetProps.showFolder;
|
|
@@ -993,311 +993,311 @@ class St extends f {
|
|
|
993
993
|
return this.parsedWidgetProps.showMenu;
|
|
994
994
|
}
|
|
995
995
|
}
|
|
996
|
-
class
|
|
996
|
+
class Ie extends L {
|
|
997
997
|
}
|
|
998
|
-
class
|
|
999
|
-
constructor(
|
|
1000
|
-
super(
|
|
1001
|
-
}
|
|
1002
|
-
}
|
|
1003
|
-
class Vt extends f {
|
|
1004
|
-
constructor(e) {
|
|
1005
|
-
super(e);
|
|
998
|
+
class te extends f {
|
|
999
|
+
constructor(t) {
|
|
1000
|
+
super(t);
|
|
1006
1001
|
}
|
|
1007
1002
|
}
|
|
1008
|
-
class
|
|
1003
|
+
class Se extends f {
|
|
1009
1004
|
constructor(t) {
|
|
1010
1005
|
super(t);
|
|
1006
|
+
}
|
|
1007
|
+
}
|
|
1008
|
+
class G extends f {
|
|
1009
|
+
constructor(e) {
|
|
1010
|
+
super(e);
|
|
1011
1011
|
/**
|
|
1012
1012
|
* Integer digits
|
|
1013
1013
|
*
|
|
1014
1014
|
* Number of integer digits that will be part of the float
|
|
1015
1015
|
*/
|
|
1016
|
-
|
|
1016
|
+
r(this, "_integerDigits", 16);
|
|
1017
1017
|
/**
|
|
1018
1018
|
* Decimal digits
|
|
1019
1019
|
*
|
|
1020
1020
|
* Number of decimal digits that will be part of the float
|
|
1021
1021
|
*/
|
|
1022
|
-
|
|
1023
|
-
if (
|
|
1024
|
-
const [
|
|
1025
|
-
this._integerDigits =
|
|
1022
|
+
r(this, "_decimalDigits", 2);
|
|
1023
|
+
if (e != null && e.digits) {
|
|
1024
|
+
const [s, n] = e.digits;
|
|
1025
|
+
this._integerDigits = s, this._decimalDigits = n;
|
|
1026
1026
|
}
|
|
1027
1027
|
}
|
|
1028
1028
|
get integerDigits() {
|
|
1029
1029
|
return this._integerDigits;
|
|
1030
1030
|
}
|
|
1031
|
-
set integerDigits(
|
|
1032
|
-
this._integerDigits =
|
|
1031
|
+
set integerDigits(e) {
|
|
1032
|
+
this._integerDigits = e;
|
|
1033
1033
|
}
|
|
1034
1034
|
get decimalDigits() {
|
|
1035
1035
|
return this._decimalDigits;
|
|
1036
1036
|
}
|
|
1037
|
-
set decimalDigits(
|
|
1038
|
-
this._decimalDigits =
|
|
1037
|
+
set decimalDigits(e) {
|
|
1038
|
+
this._decimalDigits = e;
|
|
1039
1039
|
}
|
|
1040
1040
|
}
|
|
1041
|
-
class
|
|
1041
|
+
class Ee extends G {
|
|
1042
1042
|
}
|
|
1043
|
-
class
|
|
1043
|
+
class Ve extends f {
|
|
1044
1044
|
}
|
|
1045
|
-
class
|
|
1045
|
+
class Ye extends G {
|
|
1046
1046
|
}
|
|
1047
|
-
class
|
|
1048
|
-
constructor(e) {
|
|
1049
|
-
super(e);
|
|
1050
|
-
}
|
|
1051
|
-
}
|
|
1052
|
-
class At extends f {
|
|
1047
|
+
class De extends f {
|
|
1053
1048
|
constructor(t) {
|
|
1054
1049
|
super(t);
|
|
1055
|
-
|
|
1056
|
-
|
|
1050
|
+
}
|
|
1051
|
+
}
|
|
1052
|
+
class je extends f {
|
|
1053
|
+
constructor(e) {
|
|
1054
|
+
super(e);
|
|
1055
|
+
r(this, "_timezone");
|
|
1056
|
+
this._timezone = (e == null ? void 0 : e.timezone) || void 0;
|
|
1057
1057
|
}
|
|
1058
1058
|
get timezone() {
|
|
1059
1059
|
return this._timezone;
|
|
1060
1060
|
}
|
|
1061
|
-
set timezone(
|
|
1062
|
-
this._timezone =
|
|
1061
|
+
set timezone(e) {
|
|
1062
|
+
this._timezone = e;
|
|
1063
1063
|
}
|
|
1064
1064
|
}
|
|
1065
|
-
class
|
|
1066
|
-
constructor(
|
|
1067
|
-
super(
|
|
1065
|
+
class ie extends f {
|
|
1066
|
+
constructor(e) {
|
|
1067
|
+
super(e);
|
|
1068
1068
|
/**
|
|
1069
1069
|
* Field size
|
|
1070
1070
|
*/
|
|
1071
|
-
|
|
1071
|
+
r(this, "_size", 150);
|
|
1072
1072
|
/**
|
|
1073
1073
|
* Relation
|
|
1074
1074
|
*/
|
|
1075
|
-
|
|
1075
|
+
r(this, "_relation", "");
|
|
1076
1076
|
/**
|
|
1077
1077
|
* Inv_field
|
|
1078
1078
|
*/
|
|
1079
|
-
|
|
1079
|
+
r(this, "_inv_field");
|
|
1080
1080
|
/**
|
|
1081
1081
|
* Views
|
|
1082
1082
|
*/
|
|
1083
|
-
|
|
1083
|
+
r(this, "_views", null);
|
|
1084
1084
|
/**
|
|
1085
1085
|
* Mode
|
|
1086
1086
|
*/
|
|
1087
|
-
|
|
1087
|
+
r(this, "_mode", []);
|
|
1088
1088
|
/**
|
|
1089
1089
|
* Must expand widget
|
|
1090
1090
|
*/
|
|
1091
|
-
|
|
1091
|
+
r(this, "_mustExpand", !1);
|
|
1092
1092
|
/**
|
|
1093
1093
|
* Height
|
|
1094
1094
|
*/
|
|
1095
|
-
|
|
1095
|
+
r(this, "_height");
|
|
1096
1096
|
/**
|
|
1097
1097
|
* Infinite mode
|
|
1098
1098
|
*/
|
|
1099
|
-
|
|
1100
|
-
if (
|
|
1101
|
-
if (
|
|
1099
|
+
r(this, "_infinite");
|
|
1100
|
+
if (e) {
|
|
1101
|
+
if (e.size && (this._size = e.size), e.relation && (this._relation = e.relation), e.mode && (this._mode = e.mode.split(",")), e.views && (this._views = e.views), e.colspan ? this.colspan = e.colspan : this._mustExpand = !0, e.inv_field && (this._inv_field = e.inv_field), e.height)
|
|
1102
1102
|
try {
|
|
1103
|
-
this._height = parseInt(
|
|
1103
|
+
this._height = parseInt(e.height);
|
|
1104
1104
|
} catch {
|
|
1105
1105
|
this._height = void 0;
|
|
1106
1106
|
}
|
|
1107
|
-
|
|
1107
|
+
e.widget_props && (this._infinite = e.widget_props.infinite);
|
|
1108
1108
|
}
|
|
1109
1109
|
}
|
|
1110
1110
|
get size() {
|
|
1111
1111
|
return this._size;
|
|
1112
1112
|
}
|
|
1113
|
-
set size(
|
|
1114
|
-
this._size =
|
|
1113
|
+
set size(e) {
|
|
1114
|
+
this._size = e;
|
|
1115
1115
|
}
|
|
1116
1116
|
get relation() {
|
|
1117
1117
|
return this._relation;
|
|
1118
1118
|
}
|
|
1119
|
-
set relation(
|
|
1120
|
-
this._relation =
|
|
1119
|
+
set relation(e) {
|
|
1120
|
+
this._relation = e;
|
|
1121
1121
|
}
|
|
1122
1122
|
get inv_field() {
|
|
1123
1123
|
return this._inv_field;
|
|
1124
1124
|
}
|
|
1125
|
-
set inv_field(
|
|
1126
|
-
this._inv_field =
|
|
1125
|
+
set inv_field(e) {
|
|
1126
|
+
this._inv_field = e;
|
|
1127
1127
|
}
|
|
1128
1128
|
get views() {
|
|
1129
1129
|
return this._views;
|
|
1130
1130
|
}
|
|
1131
|
-
set views(
|
|
1132
|
-
this._views =
|
|
1131
|
+
set views(e) {
|
|
1132
|
+
this._views = e;
|
|
1133
1133
|
}
|
|
1134
1134
|
get mode() {
|
|
1135
1135
|
return this._mode;
|
|
1136
1136
|
}
|
|
1137
|
-
set mode(
|
|
1138
|
-
this._mode =
|
|
1137
|
+
set mode(e) {
|
|
1138
|
+
this._mode = e;
|
|
1139
1139
|
}
|
|
1140
1140
|
get mustExpand() {
|
|
1141
1141
|
return this._mustExpand;
|
|
1142
1142
|
}
|
|
1143
|
-
set mustExpand(
|
|
1144
|
-
this._mustExpand =
|
|
1143
|
+
set mustExpand(e) {
|
|
1144
|
+
this._mustExpand = e;
|
|
1145
1145
|
}
|
|
1146
1146
|
get height() {
|
|
1147
1147
|
return this._height;
|
|
1148
1148
|
}
|
|
1149
|
-
set height(
|
|
1150
|
-
this._height =
|
|
1149
|
+
set height(e) {
|
|
1150
|
+
this._height = e;
|
|
1151
1151
|
}
|
|
1152
1152
|
get infinite() {
|
|
1153
1153
|
return this._infinite;
|
|
1154
1154
|
}
|
|
1155
|
-
set infinite(
|
|
1156
|
-
this._infinite =
|
|
1155
|
+
set infinite(e) {
|
|
1156
|
+
this._infinite = e;
|
|
1157
1157
|
}
|
|
1158
1158
|
}
|
|
1159
|
-
class
|
|
1160
|
-
constructor(
|
|
1161
|
-
super(
|
|
1159
|
+
class Me extends k {
|
|
1160
|
+
constructor(e) {
|
|
1161
|
+
super(e);
|
|
1162
1162
|
/**
|
|
1163
1163
|
* Label
|
|
1164
1164
|
*/
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1165
|
+
r(this, "_label", "");
|
|
1166
|
+
r(this, "_icon", null);
|
|
1167
|
+
e && (e.string && (this._label = m(e.string)), e.icon && (this._icon = e.icon));
|
|
1168
1168
|
}
|
|
1169
1169
|
get label() {
|
|
1170
1170
|
return this._label;
|
|
1171
1171
|
}
|
|
1172
|
-
set label(
|
|
1173
|
-
this._label =
|
|
1172
|
+
set label(e) {
|
|
1173
|
+
this._label = e;
|
|
1174
1174
|
}
|
|
1175
1175
|
get icon() {
|
|
1176
1176
|
return this._icon;
|
|
1177
1177
|
}
|
|
1178
|
-
set icon(
|
|
1179
|
-
this._icon =
|
|
1178
|
+
set icon(e) {
|
|
1179
|
+
this._icon = e;
|
|
1180
1180
|
}
|
|
1181
|
-
findById(
|
|
1181
|
+
findById(e) {
|
|
1182
1182
|
return null;
|
|
1183
1183
|
}
|
|
1184
1184
|
}
|
|
1185
|
-
class
|
|
1185
|
+
class Ne extends z {
|
|
1186
1186
|
}
|
|
1187
|
-
class
|
|
1188
|
-
constructor(
|
|
1189
|
-
super(
|
|
1187
|
+
class Ae extends f {
|
|
1188
|
+
constructor(e) {
|
|
1189
|
+
super(e);
|
|
1190
1190
|
/**
|
|
1191
1191
|
* Filename field name
|
|
1192
1192
|
*/
|
|
1193
|
-
|
|
1194
|
-
|
|
1193
|
+
r(this, "_filenameField", "");
|
|
1194
|
+
e && e.filename && (this._filenameField = e.filename);
|
|
1195
1195
|
}
|
|
1196
1196
|
get filenameField() {
|
|
1197
1197
|
return this._filenameField;
|
|
1198
1198
|
}
|
|
1199
|
-
set filenameField(
|
|
1200
|
-
this._filenameField =
|
|
1199
|
+
set filenameField(e) {
|
|
1200
|
+
this._filenameField = e;
|
|
1201
1201
|
}
|
|
1202
1202
|
}
|
|
1203
|
-
class
|
|
1204
|
-
constructor(
|
|
1205
|
-
super(
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
if (
|
|
1209
|
-
if (
|
|
1210
|
-
const
|
|
1211
|
-
this._width = isNaN(
|
|
1203
|
+
class Be extends f {
|
|
1204
|
+
constructor(e) {
|
|
1205
|
+
super(e);
|
|
1206
|
+
r(this, "_width");
|
|
1207
|
+
r(this, "_height");
|
|
1208
|
+
if (e) {
|
|
1209
|
+
if (e.width) {
|
|
1210
|
+
const s = parseInt(e.width);
|
|
1211
|
+
this._width = isNaN(s) ? void 0 : s;
|
|
1212
1212
|
}
|
|
1213
|
-
if (
|
|
1214
|
-
const
|
|
1215
|
-
this._height = isNaN(
|
|
1213
|
+
if (e.height) {
|
|
1214
|
+
const s = parseInt(e.height);
|
|
1215
|
+
this._height = isNaN(s) ? void 0 : s;
|
|
1216
1216
|
}
|
|
1217
1217
|
}
|
|
1218
1218
|
}
|
|
1219
1219
|
get width() {
|
|
1220
1220
|
return this._width;
|
|
1221
1221
|
}
|
|
1222
|
-
set width(
|
|
1223
|
-
this._width =
|
|
1222
|
+
set width(e) {
|
|
1223
|
+
this._width = e;
|
|
1224
1224
|
}
|
|
1225
1225
|
get height() {
|
|
1226
1226
|
return this._height;
|
|
1227
1227
|
}
|
|
1228
|
-
set height(
|
|
1229
|
-
this._height =
|
|
1228
|
+
set height(e) {
|
|
1229
|
+
this._height = e;
|
|
1230
1230
|
}
|
|
1231
1231
|
get showControls() {
|
|
1232
|
-
var
|
|
1233
|
-
return ((
|
|
1232
|
+
var e;
|
|
1233
|
+
return ((e = this.parsedWidgetProps) == null ? void 0 : e.showControls) ?? !0;
|
|
1234
1234
|
}
|
|
1235
1235
|
}
|
|
1236
|
-
class
|
|
1237
|
-
constructor(
|
|
1238
|
-
super({ ...
|
|
1236
|
+
class Re extends f {
|
|
1237
|
+
constructor(e) {
|
|
1238
|
+
super({ ...e, nolabel: !0 });
|
|
1239
1239
|
/**
|
|
1240
1240
|
* Icon name
|
|
1241
1241
|
*/
|
|
1242
|
-
|
|
1242
|
+
r(this, "_name", "");
|
|
1243
1243
|
/**
|
|
1244
1244
|
* Icon size
|
|
1245
1245
|
*/
|
|
1246
|
-
|
|
1246
|
+
r(this, "_size", 16);
|
|
1247
1247
|
/**
|
|
1248
1248
|
* Icon color
|
|
1249
1249
|
*/
|
|
1250
|
-
|
|
1251
|
-
|
|
1250
|
+
r(this, "_color", "");
|
|
1251
|
+
e && (e.name && (this._name = e.name), e.size && (this._size = e.size), e.color && (this._color = e.color));
|
|
1252
1252
|
}
|
|
1253
1253
|
get name() {
|
|
1254
1254
|
return this._name;
|
|
1255
1255
|
}
|
|
1256
|
-
set name(
|
|
1257
|
-
this._name =
|
|
1256
|
+
set name(e) {
|
|
1257
|
+
this._name = e;
|
|
1258
1258
|
}
|
|
1259
1259
|
get size() {
|
|
1260
1260
|
return this._size;
|
|
1261
1261
|
}
|
|
1262
|
-
set size(
|
|
1263
|
-
this._size =
|
|
1262
|
+
set size(e) {
|
|
1263
|
+
this._size = e;
|
|
1264
1264
|
}
|
|
1265
1265
|
get color() {
|
|
1266
1266
|
return this._color;
|
|
1267
1267
|
}
|
|
1268
|
-
set color(
|
|
1269
|
-
this._color =
|
|
1270
|
-
}
|
|
1271
|
-
}
|
|
1272
|
-
class $t extends f {
|
|
1273
|
-
constructor(e) {
|
|
1274
|
-
super(e);
|
|
1268
|
+
set color(e) {
|
|
1269
|
+
this._color = e;
|
|
1275
1270
|
}
|
|
1276
1271
|
}
|
|
1277
|
-
class
|
|
1272
|
+
class Le extends f {
|
|
1278
1273
|
constructor(t) {
|
|
1279
1274
|
super(t);
|
|
1275
|
+
}
|
|
1276
|
+
}
|
|
1277
|
+
class Ge extends ie {
|
|
1278
|
+
constructor(e) {
|
|
1279
|
+
super(e);
|
|
1280
1280
|
/**
|
|
1281
1281
|
* Title field
|
|
1282
1282
|
*/
|
|
1283
|
-
|
|
1283
|
+
r(this, "_titleField");
|
|
1284
1284
|
/**
|
|
1285
1285
|
* Summary field
|
|
1286
1286
|
*/
|
|
1287
|
-
|
|
1287
|
+
r(this, "_summaryField");
|
|
1288
1288
|
this._titleField = "", this._summaryField = "", this._parsedWidgetProps && (this._titleField = this._parsedWidgetProps.titleField, this._summaryField = this.parsedWidgetProps.summaryField);
|
|
1289
1289
|
}
|
|
1290
1290
|
get titleField() {
|
|
1291
1291
|
return this._titleField;
|
|
1292
1292
|
}
|
|
1293
|
-
set titleField(
|
|
1294
|
-
this._titleField =
|
|
1293
|
+
set titleField(e) {
|
|
1294
|
+
this._titleField = e;
|
|
1295
1295
|
}
|
|
1296
1296
|
get summaryField() {
|
|
1297
1297
|
return this._summaryField;
|
|
1298
1298
|
}
|
|
1299
|
-
set summaryField(
|
|
1300
|
-
this._summaryField =
|
|
1299
|
+
set summaryField(e) {
|
|
1300
|
+
this._summaryField = e;
|
|
1301
1301
|
}
|
|
1302
1302
|
get iconField() {
|
|
1303
1303
|
return this.parsedWidgetProps.iconField;
|
|
@@ -1306,51 +1306,51 @@ class qt extends nt {
|
|
|
1306
1306
|
return this.parsedWidgetProps.colorField;
|
|
1307
1307
|
}
|
|
1308
1308
|
}
|
|
1309
|
-
class
|
|
1310
|
-
constructor(
|
|
1311
|
-
super(
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1309
|
+
class $e extends z {
|
|
1310
|
+
constructor(e) {
|
|
1311
|
+
super(e);
|
|
1312
|
+
r(this, "_nolabel", !0);
|
|
1313
|
+
r(this, "_card");
|
|
1314
|
+
r(this, "_icon");
|
|
1315
|
+
r(this, "_suffix");
|
|
1316
|
+
r(this, "_color", "");
|
|
1317
1317
|
/**
|
|
1318
1318
|
* Action id
|
|
1319
1319
|
*/
|
|
1320
|
-
|
|
1320
|
+
r(this, "_actionId");
|
|
1321
1321
|
/**
|
|
1322
1322
|
* Action field
|
|
1323
1323
|
*/
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
if (this._card = !1, this._icon = "", this._suffix = "", this._autoRefresh = !1, this._parsedWidgetProps && (this._card = this._parsedWidgetProps.card || !1, this._icon =
|
|
1328
|
-
if (
|
|
1324
|
+
r(this, "_actionField");
|
|
1325
|
+
r(this, "_height");
|
|
1326
|
+
r(this, "_autoRefresh");
|
|
1327
|
+
if (this._card = !1, this._icon = "", this._suffix = "", this._autoRefresh = !1, this._parsedWidgetProps && (this._card = this._parsedWidgetProps.card || !1, this._icon = m(this._parsedWidgetProps.icon) || "", this._suffix = this._parsedWidgetProps.suffix || "", this._color = m(this._parsedWidgetProps.color) || ""), e) {
|
|
1328
|
+
if (e.action_id && (this._actionId = parseInt(e.action_id)), e.action_field && (this._actionField = e.action_field), e.height)
|
|
1329
1329
|
try {
|
|
1330
|
-
this._height = parseInt(
|
|
1331
|
-
} catch (
|
|
1332
|
-
console.error(
|
|
1330
|
+
this._height = parseInt(e.height);
|
|
1331
|
+
} catch (s) {
|
|
1332
|
+
console.error(s);
|
|
1333
1333
|
}
|
|
1334
|
-
this._autoRefresh =
|
|
1334
|
+
this._autoRefresh = w(e.autorefresh);
|
|
1335
1335
|
}
|
|
1336
1336
|
}
|
|
1337
1337
|
get card() {
|
|
1338
1338
|
return this._card;
|
|
1339
1339
|
}
|
|
1340
|
-
set card(
|
|
1341
|
-
this._card =
|
|
1340
|
+
set card(e) {
|
|
1341
|
+
this._card = e;
|
|
1342
1342
|
}
|
|
1343
1343
|
get icon() {
|
|
1344
1344
|
return this._icon;
|
|
1345
1345
|
}
|
|
1346
|
-
set icon(
|
|
1347
|
-
this._icon =
|
|
1346
|
+
set icon(e) {
|
|
1347
|
+
this._icon = e;
|
|
1348
1348
|
}
|
|
1349
1349
|
get suffix() {
|
|
1350
1350
|
return this._suffix;
|
|
1351
1351
|
}
|
|
1352
|
-
set suffix(
|
|
1353
|
-
this._suffix =
|
|
1352
|
+
set suffix(e) {
|
|
1353
|
+
this._suffix = e;
|
|
1354
1354
|
}
|
|
1355
1355
|
get color() {
|
|
1356
1356
|
return this._color;
|
|
@@ -1358,635 +1358,635 @@ class Jt extends S {
|
|
|
1358
1358
|
get actionId() {
|
|
1359
1359
|
return this._actionId;
|
|
1360
1360
|
}
|
|
1361
|
-
set actionId(
|
|
1362
|
-
this._actionId =
|
|
1361
|
+
set actionId(e) {
|
|
1362
|
+
this._actionId = e;
|
|
1363
1363
|
}
|
|
1364
1364
|
get actionField() {
|
|
1365
1365
|
return this._actionField;
|
|
1366
1366
|
}
|
|
1367
|
-
set actionField(
|
|
1368
|
-
this._actionField =
|
|
1367
|
+
set actionField(e) {
|
|
1368
|
+
this._actionField = e;
|
|
1369
1369
|
}
|
|
1370
1370
|
get height() {
|
|
1371
1371
|
return this._height;
|
|
1372
1372
|
}
|
|
1373
|
-
set height(
|
|
1374
|
-
this._height =
|
|
1373
|
+
set height(e) {
|
|
1374
|
+
this._height = e;
|
|
1375
1375
|
}
|
|
1376
1376
|
get autoRefresh() {
|
|
1377
1377
|
return this._autoRefresh;
|
|
1378
1378
|
}
|
|
1379
|
-
set autoRefresh(
|
|
1380
|
-
this._autoRefresh =
|
|
1379
|
+
set autoRefresh(e) {
|
|
1380
|
+
this._autoRefresh = e;
|
|
1381
1381
|
}
|
|
1382
1382
|
}
|
|
1383
|
-
class
|
|
1384
|
-
constructor(
|
|
1385
|
-
super(
|
|
1383
|
+
class se extends f {
|
|
1384
|
+
constructor(e) {
|
|
1385
|
+
super(e);
|
|
1386
1386
|
/**
|
|
1387
1387
|
* Field size
|
|
1388
1388
|
*/
|
|
1389
|
-
|
|
1389
|
+
r(this, "_size", 150);
|
|
1390
1390
|
/**
|
|
1391
1391
|
* Relation
|
|
1392
1392
|
*/
|
|
1393
|
-
|
|
1393
|
+
r(this, "_relation", "");
|
|
1394
1394
|
/**
|
|
1395
1395
|
* Inv_field
|
|
1396
1396
|
*/
|
|
1397
|
-
|
|
1397
|
+
r(this, "_inv_field");
|
|
1398
1398
|
/**
|
|
1399
1399
|
* field to define the value to show
|
|
1400
1400
|
*/
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1401
|
+
r(this, "_field", "name");
|
|
1402
|
+
r(this, "_columns", 4);
|
|
1403
|
+
e && (e.size && (this._size = e.size), e.relation && (this._relation = e.relation), e.inv_field && (this._inv_field = e.inv_field), this.parsedWidgetProps.hasOwnProperty("field") && (this._field = this.parsedWidgetProps.field), this.parsedWidgetProps.columns && (this._columns = this.parsedWidgetProps.columns));
|
|
1404
1404
|
}
|
|
1405
1405
|
get size() {
|
|
1406
1406
|
return this._size;
|
|
1407
1407
|
}
|
|
1408
|
-
set size(
|
|
1409
|
-
this._size =
|
|
1408
|
+
set size(e) {
|
|
1409
|
+
this._size = e;
|
|
1410
1410
|
}
|
|
1411
1411
|
get relation() {
|
|
1412
1412
|
return this._relation;
|
|
1413
1413
|
}
|
|
1414
|
-
set relation(
|
|
1415
|
-
this._relation =
|
|
1414
|
+
set relation(e) {
|
|
1415
|
+
this._relation = e;
|
|
1416
1416
|
}
|
|
1417
1417
|
get inv_field() {
|
|
1418
1418
|
return this._inv_field;
|
|
1419
1419
|
}
|
|
1420
|
-
set inv_field(
|
|
1421
|
-
this._inv_field =
|
|
1420
|
+
set inv_field(e) {
|
|
1421
|
+
this._inv_field = e;
|
|
1422
1422
|
}
|
|
1423
1423
|
get field() {
|
|
1424
1424
|
return this._field;
|
|
1425
1425
|
}
|
|
1426
|
-
set field(
|
|
1427
|
-
this._field =
|
|
1426
|
+
set field(e) {
|
|
1427
|
+
this._field = e;
|
|
1428
1428
|
}
|
|
1429
1429
|
get columns() {
|
|
1430
1430
|
return this._columns;
|
|
1431
1431
|
}
|
|
1432
|
-
set columns(
|
|
1433
|
-
this._columns =
|
|
1432
|
+
set columns(e) {
|
|
1433
|
+
this._columns = e;
|
|
1434
1434
|
}
|
|
1435
1435
|
}
|
|
1436
|
-
class
|
|
1436
|
+
class qe extends se {
|
|
1437
1437
|
}
|
|
1438
|
-
class
|
|
1438
|
+
class Je extends z {
|
|
1439
1439
|
get colors() {
|
|
1440
1440
|
return this._parsedWidgetProps.colors || {};
|
|
1441
1441
|
}
|
|
1442
1442
|
get colorField() {
|
|
1443
|
-
var
|
|
1444
|
-
return ((
|
|
1443
|
+
var t;
|
|
1444
|
+
return ((t = this._parsedWidgetProps) == null ? void 0 : t.colorField) || null;
|
|
1445
1445
|
}
|
|
1446
1446
|
}
|
|
1447
|
-
class
|
|
1448
|
-
constructor(
|
|
1449
|
-
super(
|
|
1447
|
+
class He extends z {
|
|
1448
|
+
constructor(e) {
|
|
1449
|
+
super(e);
|
|
1450
1450
|
/**
|
|
1451
1451
|
* Define the direction
|
|
1452
1452
|
*/
|
|
1453
|
-
|
|
1454
|
-
|
|
1453
|
+
r(this, "_direction", "horizontal");
|
|
1454
|
+
e && this.parsedWidgetProps.hasOwnProperty("direction") && (this._direction = this.parsedWidgetProps.direction);
|
|
1455
1455
|
}
|
|
1456
1456
|
get direction() {
|
|
1457
1457
|
return this._direction;
|
|
1458
1458
|
}
|
|
1459
|
-
set direction(
|
|
1460
|
-
this._direction =
|
|
1459
|
+
set direction(e) {
|
|
1460
|
+
this._direction = e;
|
|
1461
1461
|
}
|
|
1462
1462
|
}
|
|
1463
|
-
class
|
|
1463
|
+
class Qe extends te {
|
|
1464
1464
|
}
|
|
1465
|
-
class
|
|
1466
|
-
constructor(
|
|
1467
|
-
super(
|
|
1465
|
+
class Xe extends f {
|
|
1466
|
+
constructor(e) {
|
|
1467
|
+
super(e);
|
|
1468
1468
|
/**
|
|
1469
1469
|
* Relation
|
|
1470
1470
|
*/
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1471
|
+
r(this, "_relation", "");
|
|
1472
|
+
r(this, "_errorField", null);
|
|
1473
|
+
r(this, "_lastStep", !0);
|
|
1474
|
+
e && (e.relation && (this._relation = e.relation), this.parsedWidgetProps.hasOwnProperty("error_field") && (this._errorField = this.parsedWidgetProps.error_field), this.parsedWidgetProps.hasOwnProperty("last_step") && (this._lastStep = this.parsedWidgetProps.last_step));
|
|
1475
1475
|
}
|
|
1476
1476
|
get relation() {
|
|
1477
1477
|
return this._relation;
|
|
1478
1478
|
}
|
|
1479
|
-
set relation(
|
|
1480
|
-
this._relation =
|
|
1479
|
+
set relation(e) {
|
|
1480
|
+
this._relation = e;
|
|
1481
1481
|
}
|
|
1482
1482
|
get errorField() {
|
|
1483
1483
|
return this._errorField;
|
|
1484
1484
|
}
|
|
1485
|
-
set errorField(
|
|
1486
|
-
this._errorField =
|
|
1485
|
+
set errorField(e) {
|
|
1486
|
+
this._errorField = e;
|
|
1487
1487
|
}
|
|
1488
1488
|
get lastStep() {
|
|
1489
1489
|
return this._lastStep;
|
|
1490
1490
|
}
|
|
1491
|
-
set lastStep(
|
|
1492
|
-
this._lastStep =
|
|
1491
|
+
set lastStep(e) {
|
|
1492
|
+
this._lastStep = e;
|
|
1493
1493
|
}
|
|
1494
1494
|
}
|
|
1495
|
-
class
|
|
1496
|
-
constructor(
|
|
1497
|
-
super(
|
|
1498
|
-
|
|
1499
|
-
|
|
1495
|
+
class re extends L {
|
|
1496
|
+
constructor(e) {
|
|
1497
|
+
super(e);
|
|
1498
|
+
r(this, "_lang", null);
|
|
1499
|
+
e && this.parsedWidgetProps.lang && (this._lang = this.parsedWidgetProps.lang);
|
|
1500
1500
|
}
|
|
1501
1501
|
get lang() {
|
|
1502
1502
|
return this._lang;
|
|
1503
1503
|
}
|
|
1504
|
-
set lang(
|
|
1505
|
-
this._lang =
|
|
1504
|
+
set lang(e) {
|
|
1505
|
+
this._lang = e;
|
|
1506
1506
|
}
|
|
1507
1507
|
}
|
|
1508
|
-
class
|
|
1509
|
-
constructor(e) {
|
|
1510
|
-
super(e);
|
|
1511
|
-
}
|
|
1512
|
-
}
|
|
1513
|
-
class te extends F {
|
|
1508
|
+
class Ue extends f {
|
|
1514
1509
|
constructor(t) {
|
|
1515
1510
|
super(t);
|
|
1511
|
+
}
|
|
1512
|
+
}
|
|
1513
|
+
class Ke extends v {
|
|
1514
|
+
constructor(e) {
|
|
1515
|
+
super(e);
|
|
1516
1516
|
/**
|
|
1517
1517
|
* Alert type
|
|
1518
1518
|
*/
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1519
|
+
r(this, "_alertType", "info");
|
|
1520
|
+
r(this, "_title", "");
|
|
1521
|
+
r(this, "_text", "");
|
|
1522
|
+
r(this, "_icon", null);
|
|
1523
|
+
e && (e.alert_type && (this._alertType = e.alert_type), e.title && (this._title = e.title), e.text && (this._text = e.text), e.icon && (this._icon = e.icon));
|
|
1524
1524
|
}
|
|
1525
1525
|
get alertType() {
|
|
1526
1526
|
return this._alertType;
|
|
1527
1527
|
}
|
|
1528
|
-
set alertType(
|
|
1529
|
-
this._alertType =
|
|
1528
|
+
set alertType(e) {
|
|
1529
|
+
this._alertType = e;
|
|
1530
1530
|
}
|
|
1531
1531
|
get title() {
|
|
1532
1532
|
return this._title;
|
|
1533
1533
|
}
|
|
1534
|
-
set title(
|
|
1535
|
-
this._title =
|
|
1534
|
+
set title(e) {
|
|
1535
|
+
this._title = e;
|
|
1536
1536
|
}
|
|
1537
1537
|
get text() {
|
|
1538
1538
|
return this._text;
|
|
1539
1539
|
}
|
|
1540
|
-
set text(
|
|
1541
|
-
this._text =
|
|
1540
|
+
set text(e) {
|
|
1541
|
+
this._text = e;
|
|
1542
1542
|
}
|
|
1543
1543
|
get icon() {
|
|
1544
1544
|
return this._icon;
|
|
1545
1545
|
}
|
|
1546
|
-
set icon(
|
|
1547
|
-
this._icon =
|
|
1546
|
+
set icon(e) {
|
|
1547
|
+
this._icon = e;
|
|
1548
1548
|
}
|
|
1549
1549
|
get buttons() {
|
|
1550
|
-
return this._container.rows.flat().filter((
|
|
1550
|
+
return this._container.rows.flat().filter((e) => !e.invisible);
|
|
1551
1551
|
}
|
|
1552
1552
|
}
|
|
1553
|
-
class
|
|
1554
|
-
constructor(
|
|
1555
|
-
super(
|
|
1553
|
+
class Ze extends f {
|
|
1554
|
+
constructor(e) {
|
|
1555
|
+
super(e);
|
|
1556
1556
|
/**
|
|
1557
1557
|
* Height of the comments component
|
|
1558
1558
|
*/
|
|
1559
|
-
|
|
1560
|
-
if (
|
|
1561
|
-
const
|
|
1562
|
-
this._height = isNaN(
|
|
1559
|
+
r(this, "_height");
|
|
1560
|
+
if (e.height) {
|
|
1561
|
+
const s = parseInt(e.height);
|
|
1562
|
+
this._height = isNaN(s) ? void 0 : s;
|
|
1563
1563
|
}
|
|
1564
1564
|
}
|
|
1565
1565
|
get height() {
|
|
1566
1566
|
return this._height;
|
|
1567
1567
|
}
|
|
1568
|
-
set height(
|
|
1569
|
-
this._height =
|
|
1568
|
+
set height(e) {
|
|
1569
|
+
this._height = e;
|
|
1570
1570
|
}
|
|
1571
1571
|
}
|
|
1572
|
-
class
|
|
1572
|
+
class H extends re {
|
|
1573
1573
|
constructor() {
|
|
1574
1574
|
super(...arguments);
|
|
1575
|
-
|
|
1575
|
+
r(this, "_lang", "json");
|
|
1576
1576
|
}
|
|
1577
1577
|
}
|
|
1578
|
-
class
|
|
1579
|
-
constructor(
|
|
1580
|
-
super(
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1578
|
+
class et extends f {
|
|
1579
|
+
constructor(e) {
|
|
1580
|
+
super(e);
|
|
1581
|
+
r(this, "_multi", !1);
|
|
1582
|
+
r(this, "_size");
|
|
1583
|
+
e && e.size && (this.size = e.size), this.parsedWidgetProps.multi && (this.multi = this.parsedWidgetProps.multi);
|
|
1584
1584
|
}
|
|
1585
1585
|
get multi() {
|
|
1586
1586
|
return this._multi;
|
|
1587
1587
|
}
|
|
1588
|
-
set multi(
|
|
1589
|
-
this._multi =
|
|
1588
|
+
set multi(e) {
|
|
1589
|
+
this._multi = e;
|
|
1590
1590
|
}
|
|
1591
1591
|
get size() {
|
|
1592
1592
|
return this._size;
|
|
1593
1593
|
}
|
|
1594
|
-
set size(
|
|
1595
|
-
this._size =
|
|
1594
|
+
set size(e) {
|
|
1595
|
+
this._size = e;
|
|
1596
1596
|
}
|
|
1597
1597
|
}
|
|
1598
|
-
class
|
|
1599
|
-
constructor(
|
|
1600
|
-
super(
|
|
1601
|
-
|
|
1602
|
-
|
|
1598
|
+
class tt extends v {
|
|
1599
|
+
constructor(e) {
|
|
1600
|
+
super(e);
|
|
1601
|
+
r(this, "_autoPlay", !0);
|
|
1602
|
+
e && "auto_play" in e && (this._autoPlay = w(e.auto_play));
|
|
1603
1603
|
}
|
|
1604
1604
|
get autoPlay() {
|
|
1605
1605
|
return this._autoPlay;
|
|
1606
1606
|
}
|
|
1607
|
-
set autoPlay(
|
|
1608
|
-
this._autoPlay =
|
|
1607
|
+
set autoPlay(e) {
|
|
1608
|
+
this._autoPlay = e;
|
|
1609
1609
|
}
|
|
1610
1610
|
get items() {
|
|
1611
|
-
return this._container.rows.flat().filter((
|
|
1611
|
+
return this._container.rows.flat().filter((e) => !e.invisible);
|
|
1612
1612
|
}
|
|
1613
1613
|
}
|
|
1614
|
-
class
|
|
1614
|
+
class it extends A {
|
|
1615
1615
|
get showText() {
|
|
1616
1616
|
return this.parsedWidgetProps.show_text ?? !0;
|
|
1617
1617
|
}
|
|
1618
1618
|
}
|
|
1619
|
-
class
|
|
1619
|
+
class st extends f {
|
|
1620
1620
|
get width() {
|
|
1621
|
-
var
|
|
1622
|
-
return (
|
|
1621
|
+
var t;
|
|
1622
|
+
return (t = this.parsedWidgetProps) == null ? void 0 : t.width;
|
|
1623
1623
|
}
|
|
1624
1624
|
get border() {
|
|
1625
|
-
var
|
|
1626
|
-
return ((
|
|
1625
|
+
var t;
|
|
1626
|
+
return ((t = this.parsedWidgetProps) == null ? void 0 : t.border) ?? !1;
|
|
1627
1627
|
}
|
|
1628
1628
|
get showValue() {
|
|
1629
|
-
var
|
|
1630
|
-
return console.log(this.parsedWidgetProps), ((
|
|
1629
|
+
var t;
|
|
1630
|
+
return console.log(this.parsedWidgetProps), ((t = this.parsedWidgetProps) == null ? void 0 : t.showValue) ?? !1;
|
|
1631
1631
|
}
|
|
1632
1632
|
}
|
|
1633
|
-
class
|
|
1634
|
-
constructor(
|
|
1635
|
-
super(
|
|
1636
|
-
|
|
1637
|
-
|
|
1633
|
+
class rt extends j {
|
|
1634
|
+
constructor(e) {
|
|
1635
|
+
super(e);
|
|
1636
|
+
r(this, "_title", null);
|
|
1637
|
+
r(this, "_icon", null);
|
|
1638
1638
|
/**
|
|
1639
1639
|
* Height of the card component
|
|
1640
1640
|
*/
|
|
1641
|
-
|
|
1642
|
-
if (
|
|
1643
|
-
const
|
|
1644
|
-
this._height = isNaN(
|
|
1641
|
+
r(this, "_height");
|
|
1642
|
+
if (e && (e.title && (this._title = e.title), e.icon && (this._icon = e.icon), e.height)) {
|
|
1643
|
+
const s = parseInt(e.height);
|
|
1644
|
+
this._height = isNaN(s) ? void 0 : s;
|
|
1645
1645
|
}
|
|
1646
1646
|
}
|
|
1647
1647
|
get title() {
|
|
1648
1648
|
return this._title;
|
|
1649
1649
|
}
|
|
1650
|
-
set title(
|
|
1651
|
-
this._title =
|
|
1650
|
+
set title(e) {
|
|
1651
|
+
this._title = e;
|
|
1652
1652
|
}
|
|
1653
1653
|
get icon() {
|
|
1654
1654
|
return this._icon;
|
|
1655
1655
|
}
|
|
1656
|
-
set icon(
|
|
1657
|
-
this._icon =
|
|
1656
|
+
set icon(e) {
|
|
1657
|
+
this._icon = e;
|
|
1658
1658
|
}
|
|
1659
1659
|
get height() {
|
|
1660
1660
|
return this._height;
|
|
1661
1661
|
}
|
|
1662
|
-
set height(
|
|
1663
|
-
this._height =
|
|
1662
|
+
set height(e) {
|
|
1663
|
+
this._height = e;
|
|
1664
1664
|
}
|
|
1665
1665
|
}
|
|
1666
|
-
class
|
|
1666
|
+
class $ {
|
|
1667
1667
|
constructor() {
|
|
1668
1668
|
/**
|
|
1669
1669
|
* Widget class
|
|
1670
1670
|
*/
|
|
1671
|
-
|
|
1671
|
+
r(this, "_widgetClass");
|
|
1672
1672
|
}
|
|
1673
|
-
setWidgetClass(
|
|
1674
|
-
switch (
|
|
1673
|
+
setWidgetClass(t) {
|
|
1674
|
+
switch (t) {
|
|
1675
1675
|
case "notebook":
|
|
1676
|
-
this._widgetClass =
|
|
1676
|
+
this._widgetClass = N;
|
|
1677
1677
|
break;
|
|
1678
1678
|
case "page":
|
|
1679
|
-
this._widgetClass =
|
|
1679
|
+
this._widgetClass = Pe;
|
|
1680
1680
|
break;
|
|
1681
1681
|
case "group":
|
|
1682
|
-
this._widgetClass =
|
|
1682
|
+
this._widgetClass = Oe;
|
|
1683
1683
|
break;
|
|
1684
1684
|
case "card":
|
|
1685
|
-
this._widgetClass =
|
|
1685
|
+
this._widgetClass = rt;
|
|
1686
1686
|
break;
|
|
1687
1687
|
case "label":
|
|
1688
|
-
this._widgetClass =
|
|
1688
|
+
this._widgetClass = Z;
|
|
1689
1689
|
break;
|
|
1690
1690
|
case "char":
|
|
1691
|
-
this._widgetClass =
|
|
1691
|
+
this._widgetClass = A;
|
|
1692
1692
|
break;
|
|
1693
1693
|
case "text":
|
|
1694
|
-
this._widgetClass =
|
|
1694
|
+
this._widgetClass = L;
|
|
1695
1695
|
break;
|
|
1696
1696
|
case "button":
|
|
1697
|
-
this._widgetClass =
|
|
1697
|
+
this._widgetClass = ee;
|
|
1698
1698
|
break;
|
|
1699
1699
|
case "buttonGroup":
|
|
1700
|
-
this._widgetClass =
|
|
1700
|
+
this._widgetClass = Te;
|
|
1701
1701
|
break;
|
|
1702
1702
|
case "action_buttons":
|
|
1703
|
-
this._widgetClass =
|
|
1703
|
+
this._widgetClass = We;
|
|
1704
1704
|
break;
|
|
1705
1705
|
case "selection":
|
|
1706
|
-
this._widgetClass =
|
|
1706
|
+
this._widgetClass = z;
|
|
1707
1707
|
break;
|
|
1708
1708
|
case "many2one":
|
|
1709
1709
|
case "many2one_lazy":
|
|
1710
|
-
this._widgetClass =
|
|
1710
|
+
this._widgetClass = ze;
|
|
1711
1711
|
break;
|
|
1712
1712
|
case "boolean":
|
|
1713
|
-
this._widgetClass =
|
|
1713
|
+
this._widgetClass = te;
|
|
1714
1714
|
break;
|
|
1715
1715
|
case "integer":
|
|
1716
|
-
this._widgetClass =
|
|
1716
|
+
this._widgetClass = Se;
|
|
1717
1717
|
break;
|
|
1718
1718
|
case "float":
|
|
1719
|
-
this._widgetClass =
|
|
1719
|
+
this._widgetClass = G;
|
|
1720
1720
|
break;
|
|
1721
1721
|
case "float_time":
|
|
1722
|
-
this._widgetClass =
|
|
1722
|
+
this._widgetClass = Ee;
|
|
1723
1723
|
break;
|
|
1724
1724
|
case "date":
|
|
1725
|
-
this._widgetClass =
|
|
1725
|
+
this._widgetClass = De;
|
|
1726
1726
|
break;
|
|
1727
1727
|
case "datetime":
|
|
1728
|
-
this._widgetClass =
|
|
1728
|
+
this._widgetClass = je;
|
|
1729
1729
|
break;
|
|
1730
1730
|
case "progressbar":
|
|
1731
|
-
this._widgetClass =
|
|
1731
|
+
this._widgetClass = Ye;
|
|
1732
1732
|
break;
|
|
1733
1733
|
case "markdown":
|
|
1734
|
-
this._widgetClass =
|
|
1734
|
+
this._widgetClass = Ie;
|
|
1735
1735
|
break;
|
|
1736
1736
|
case "many2many":
|
|
1737
1737
|
case "one2many":
|
|
1738
1738
|
case "one2many_list":
|
|
1739
|
-
this._widgetClass =
|
|
1739
|
+
this._widgetClass = ie;
|
|
1740
1740
|
break;
|
|
1741
1741
|
case "newline":
|
|
1742
|
-
this._widgetClass =
|
|
1742
|
+
this._widgetClass = K;
|
|
1743
1743
|
break;
|
|
1744
1744
|
case "separator":
|
|
1745
|
-
this._widgetClass =
|
|
1745
|
+
this._widgetClass = Me;
|
|
1746
1746
|
break;
|
|
1747
1747
|
case "url":
|
|
1748
|
-
this._widgetClass =
|
|
1748
|
+
this._widgetClass = A;
|
|
1749
1749
|
break;
|
|
1750
1750
|
case "email":
|
|
1751
|
-
this._widgetClass =
|
|
1751
|
+
this._widgetClass = et;
|
|
1752
1752
|
break;
|
|
1753
1753
|
case "reference":
|
|
1754
|
-
this._widgetClass =
|
|
1754
|
+
this._widgetClass = Ne;
|
|
1755
1755
|
break;
|
|
1756
1756
|
case "binary":
|
|
1757
|
-
this._widgetClass =
|
|
1757
|
+
this._widgetClass = Ae;
|
|
1758
1758
|
break;
|
|
1759
1759
|
case "image":
|
|
1760
|
-
this._widgetClass =
|
|
1760
|
+
this._widgetClass = Be;
|
|
1761
1761
|
break;
|
|
1762
1762
|
case "icon":
|
|
1763
|
-
this._widgetClass =
|
|
1763
|
+
this._widgetClass = Re;
|
|
1764
1764
|
break;
|
|
1765
1765
|
case "fiber_grid":
|
|
1766
|
-
this._widgetClass =
|
|
1766
|
+
this._widgetClass = Le;
|
|
1767
1767
|
break;
|
|
1768
1768
|
case "timeline":
|
|
1769
|
-
this._widgetClass =
|
|
1769
|
+
this._widgetClass = Ge;
|
|
1770
1770
|
break;
|
|
1771
1771
|
case "indicator":
|
|
1772
|
-
this._widgetClass =
|
|
1772
|
+
this._widgetClass = $e;
|
|
1773
1773
|
break;
|
|
1774
1774
|
case "tags":
|
|
1775
|
-
this._widgetClass =
|
|
1775
|
+
this._widgetClass = qe;
|
|
1776
1776
|
break;
|
|
1777
1777
|
case "tag":
|
|
1778
|
-
this._widgetClass =
|
|
1778
|
+
this._widgetClass = Je;
|
|
1779
1779
|
break;
|
|
1780
1780
|
case "avatar":
|
|
1781
|
-
this._widgetClass =
|
|
1781
|
+
this._widgetClass = ke;
|
|
1782
1782
|
break;
|
|
1783
1783
|
case "radio":
|
|
1784
|
-
this._widgetClass =
|
|
1784
|
+
this._widgetClass = He;
|
|
1785
1785
|
break;
|
|
1786
1786
|
case "multicheckbox":
|
|
1787
|
-
this._widgetClass =
|
|
1787
|
+
this._widgetClass = se;
|
|
1788
1788
|
break;
|
|
1789
1789
|
case "switch":
|
|
1790
|
-
this._widgetClass =
|
|
1790
|
+
this._widgetClass = Qe;
|
|
1791
1791
|
break;
|
|
1792
1792
|
case "steps":
|
|
1793
|
-
this._widgetClass =
|
|
1793
|
+
this._widgetClass = Xe;
|
|
1794
1794
|
break;
|
|
1795
1795
|
case "codeeditor":
|
|
1796
|
-
this._widgetClass =
|
|
1796
|
+
this._widgetClass = re;
|
|
1797
1797
|
break;
|
|
1798
1798
|
case "time":
|
|
1799
|
-
this._widgetClass =
|
|
1799
|
+
this._widgetClass = Ue;
|
|
1800
1800
|
break;
|
|
1801
1801
|
case "html_preview":
|
|
1802
|
-
this._widgetClass =
|
|
1802
|
+
this._widgetClass = Ve;
|
|
1803
1803
|
break;
|
|
1804
1804
|
case "alert":
|
|
1805
|
-
this._widgetClass =
|
|
1805
|
+
this._widgetClass = Ke;
|
|
1806
1806
|
break;
|
|
1807
1807
|
case "comments_timeline":
|
|
1808
|
-
this._widgetClass =
|
|
1808
|
+
this._widgetClass = Ze;
|
|
1809
1809
|
break;
|
|
1810
1810
|
case "json":
|
|
1811
|
-
this._widgetClass =
|
|
1811
|
+
this._widgetClass = H;
|
|
1812
1812
|
break;
|
|
1813
1813
|
case "arrow_steps":
|
|
1814
|
-
this._widgetClass =
|
|
1814
|
+
this._widgetClass = H;
|
|
1815
1815
|
break;
|
|
1816
1816
|
case "spinner":
|
|
1817
|
-
this._widgetClass =
|
|
1817
|
+
this._widgetClass = j;
|
|
1818
1818
|
break;
|
|
1819
1819
|
case "carousel":
|
|
1820
|
-
this._widgetClass =
|
|
1820
|
+
this._widgetClass = tt;
|
|
1821
1821
|
break;
|
|
1822
1822
|
case "colorPicker":
|
|
1823
|
-
this._widgetClass =
|
|
1823
|
+
this._widgetClass = it;
|
|
1824
1824
|
break;
|
|
1825
1825
|
case "qrcode":
|
|
1826
|
-
this._widgetClass =
|
|
1826
|
+
this._widgetClass = st;
|
|
1827
1827
|
break;
|
|
1828
1828
|
}
|
|
1829
1829
|
}
|
|
1830
|
-
createWidget(
|
|
1830
|
+
createWidget(t, e) {
|
|
1831
1831
|
this._widgetClass = void 0;
|
|
1832
|
-
let
|
|
1833
|
-
switch (this.setWidgetClass(
|
|
1832
|
+
let s = t;
|
|
1833
|
+
switch (this.setWidgetClass(t), this._widgetClass === void 0 && (s = e.fieldsWidgetType, this.setWidgetClass(e.fieldsWidgetType)), this._widgetClass === void 0 && (this._widgetClass = k), t) {
|
|
1834
1834
|
case "notebook":
|
|
1835
1835
|
case "page":
|
|
1836
1836
|
case "group":
|
|
1837
1837
|
case "card":
|
|
1838
|
-
return new this._widgetClass({ ...
|
|
1838
|
+
return new this._widgetClass({ ...e, type: s });
|
|
1839
1839
|
case "button":
|
|
1840
1840
|
return new this._widgetClass({
|
|
1841
|
-
...
|
|
1842
|
-
type:
|
|
1843
|
-
buttonType:
|
|
1841
|
+
...e,
|
|
1842
|
+
type: t,
|
|
1843
|
+
buttonType: e.type
|
|
1844
1844
|
});
|
|
1845
1845
|
default:
|
|
1846
|
-
return new this._widgetClass({ ...
|
|
1846
|
+
return new this._widgetClass({ ...e, type: s });
|
|
1847
1847
|
}
|
|
1848
1848
|
}
|
|
1849
1849
|
}
|
|
1850
|
-
const
|
|
1851
|
-
fieldName:
|
|
1852
|
-
values:
|
|
1853
|
-
fields:
|
|
1850
|
+
const nt = ({
|
|
1851
|
+
fieldName: i,
|
|
1852
|
+
values: t,
|
|
1853
|
+
fields: e
|
|
1854
1854
|
}) => {
|
|
1855
|
-
var
|
|
1856
|
-
if (!s)
|
|
1857
|
-
return {};
|
|
1858
|
-
const i = (o = t[s]) == null ? void 0 : o.states;
|
|
1855
|
+
var l;
|
|
1859
1856
|
if (!i)
|
|
1860
1857
|
return {};
|
|
1861
|
-
const
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1858
|
+
const s = (l = e[i]) == null ? void 0 : l.states;
|
|
1859
|
+
if (!s)
|
|
1860
|
+
return {};
|
|
1861
|
+
const n = {}, a = {};
|
|
1862
|
+
for (const o of Object.keys(s))
|
|
1863
|
+
if (t.state === o) {
|
|
1864
|
+
const h = s[o];
|
|
1865
|
+
for (const _ of h) {
|
|
1866
|
+
const [u, d] = _;
|
|
1867
|
+
a[u] || (a[u] = []), a[u].push(d);
|
|
1868
1868
|
}
|
|
1869
1869
|
}
|
|
1870
|
-
for (const
|
|
1871
|
-
const
|
|
1872
|
-
|
|
1870
|
+
for (const o of Object.keys(a)) {
|
|
1871
|
+
const h = a[o];
|
|
1872
|
+
n[o] = h.some((_) => _);
|
|
1873
1873
|
}
|
|
1874
|
-
return
|
|
1875
|
-
},
|
|
1876
|
-
states:
|
|
1877
|
-
values:
|
|
1874
|
+
return n;
|
|
1875
|
+
}, at = ({
|
|
1876
|
+
states: i,
|
|
1877
|
+
values: t
|
|
1878
1878
|
}) => {
|
|
1879
|
-
if (!(
|
|
1879
|
+
if (!(t != null && t.state))
|
|
1880
1880
|
return {};
|
|
1881
|
-
const
|
|
1882
|
-
return
|
|
1881
|
+
const e = i.split(",");
|
|
1882
|
+
return e.length === 0 ? {} : e.includes(t.state) ? {} : { invisible: !0 };
|
|
1883
1883
|
};
|
|
1884
|
-
function
|
|
1885
|
-
values:
|
|
1886
|
-
fieldName:
|
|
1887
|
-
fields:
|
|
1884
|
+
function lt({
|
|
1885
|
+
values: i = {},
|
|
1886
|
+
fieldName: t,
|
|
1887
|
+
fields: e = {}
|
|
1888
1888
|
}) {
|
|
1889
|
-
var
|
|
1890
|
-
const
|
|
1891
|
-
return
|
|
1889
|
+
var n;
|
|
1890
|
+
const s = ((n = e[t]) == null ? void 0 : n.type) || "passthrough";
|
|
1891
|
+
return s === "many2one" ? i[t] ? i[t][0] || null : !1 : s === "one2many" || s === "many2many" ? i[t].map((a) => a.id) : i != null && i[t] ? i == null ? void 0 : i[t] : t.includes("'") ? t : parseInt(t);
|
|
1892
1892
|
}
|
|
1893
|
-
const
|
|
1894
|
-
context:
|
|
1895
|
-
values:
|
|
1896
|
-
fields:
|
|
1893
|
+
const ne = ({
|
|
1894
|
+
context: i,
|
|
1895
|
+
values: t,
|
|
1896
|
+
fields: e
|
|
1897
1897
|
}) => {
|
|
1898
1898
|
try {
|
|
1899
|
-
if (!
|
|
1899
|
+
if (!i)
|
|
1900
1900
|
return;
|
|
1901
|
-
if (
|
|
1902
|
-
return s;
|
|
1903
|
-
const i = ot(s);
|
|
1904
|
-
if (i !== null)
|
|
1901
|
+
if (le(i) || typeof i != "string")
|
|
1905
1902
|
return i;
|
|
1906
|
-
|
|
1903
|
+
const s = ae(i);
|
|
1904
|
+
if (s !== null)
|
|
1905
|
+
return s;
|
|
1906
|
+
if (i.trim().length === 0)
|
|
1907
1907
|
return;
|
|
1908
|
-
const
|
|
1909
|
-
return
|
|
1910
|
-
const b =
|
|
1911
|
-
if (!
|
|
1912
|
-
const x =
|
|
1913
|
-
values:
|
|
1914
|
-
fields:
|
|
1908
|
+
const d = i.replace(/"/g, "'").replace(/\s/g, "").replace(/True/g, "true").replace(/False/g, "false").replace(/\{/g, "").replace(/\}/g, "").split(",").map((c) => c.split(":")), g = {};
|
|
1909
|
+
return d.forEach((c) => {
|
|
1910
|
+
const b = c[1];
|
|
1911
|
+
if (!c[1].includes("'") && c[1] !== "true" && c[1] !== "false") {
|
|
1912
|
+
const x = lt({
|
|
1913
|
+
values: t,
|
|
1914
|
+
fields: e,
|
|
1915
1915
|
fieldName: b === "active_id" ? "id" : b
|
|
1916
1916
|
});
|
|
1917
|
-
|
|
1917
|
+
g[c[0].replace(/'/g, "")] = x || void 0;
|
|
1918
1918
|
} else
|
|
1919
|
-
|
|
1919
|
+
c[1] === "true" ? g[c[0].replace(/'/g, "")] = !0 : c[1] === "false" ? g[c[0].replace(/'/g, "")] = !1 : g[c[0].replace(/'/g, "")] = c[1].replace(
|
|
1920
1920
|
/'/g,
|
|
1921
1921
|
""
|
|
1922
1922
|
);
|
|
1923
|
-
}),
|
|
1923
|
+
}), g;
|
|
1924
1924
|
} catch {
|
|
1925
1925
|
return;
|
|
1926
1926
|
}
|
|
1927
|
-
},
|
|
1928
|
-
const
|
|
1927
|
+
}, St = (i) => {
|
|
1928
|
+
const t = [];
|
|
1929
1929
|
try {
|
|
1930
|
-
return !
|
|
1931
|
-
!
|
|
1932
|
-
}),
|
|
1930
|
+
return !i || le(i) || typeof i != "string" ? t : ae(i) !== null ? [] : (i.trim().length === 0 || i.replace(/"/g, "'").replace(/\s/g, "").replace(/True/g, "true").replace(/False/g, "false").replace(/\{/g, "").replace(/\}/g, "").split(",").map((d) => d.split(":")).forEach((d) => {
|
|
1931
|
+
!d[1].includes("'") && d[1] !== "true" && d[1] !== "false" && t.push(d[1].replace(/'/g, ""));
|
|
1932
|
+
}), t);
|
|
1933
1933
|
} catch {
|
|
1934
1934
|
}
|
|
1935
|
-
return
|
|
1935
|
+
return t;
|
|
1936
1936
|
};
|
|
1937
|
-
function
|
|
1937
|
+
function ae(i) {
|
|
1938
1938
|
try {
|
|
1939
|
-
return JSON.parse(
|
|
1939
|
+
return JSON.parse(i.replace(/'/g, '"'));
|
|
1940
1940
|
} catch {
|
|
1941
1941
|
return null;
|
|
1942
1942
|
}
|
|
1943
1943
|
}
|
|
1944
|
-
function
|
|
1945
|
-
return typeof
|
|
1944
|
+
function le(i) {
|
|
1945
|
+
return typeof i == "object" && i !== null && typeof i != "string";
|
|
1946
1946
|
}
|
|
1947
|
-
const
|
|
1948
|
-
const
|
|
1947
|
+
const ot = (i) => {
|
|
1948
|
+
const t = i.trim().replace(")", "").split("("), e = t[0], n = t[1].split(",").map((a) => a.trim());
|
|
1949
1949
|
return {
|
|
1950
|
-
method:
|
|
1951
|
-
args:
|
|
1950
|
+
method: e,
|
|
1951
|
+
args: n
|
|
1952
1952
|
};
|
|
1953
1953
|
};
|
|
1954
|
-
function
|
|
1955
|
-
const
|
|
1956
|
-
function
|
|
1957
|
-
const
|
|
1958
|
-
for (const a of
|
|
1959
|
-
a instanceof
|
|
1960
|
-
|
|
1954
|
+
function ct(i) {
|
|
1955
|
+
const t = [];
|
|
1956
|
+
function e(s) {
|
|
1957
|
+
const n = [];
|
|
1958
|
+
for (const a of s)
|
|
1959
|
+
a instanceof v ? e(a._container.rows.flat()) : n.push(a);
|
|
1960
|
+
n.length > 0 && t.push(n);
|
|
1961
1961
|
}
|
|
1962
|
-
for (const
|
|
1963
|
-
|
|
1964
|
-
return
|
|
1962
|
+
for (const s of i)
|
|
1963
|
+
e(s);
|
|
1964
|
+
return t.flat();
|
|
1965
1965
|
}
|
|
1966
|
-
class
|
|
1967
|
-
constructor(
|
|
1966
|
+
class Et {
|
|
1967
|
+
constructor(t, e = 4) {
|
|
1968
1968
|
/**
|
|
1969
1969
|
* Object containing fields specification of the form.
|
|
1970
1970
|
*/
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1971
|
+
r(this, "_fields");
|
|
1972
|
+
r(this, "_container");
|
|
1973
|
+
r(this, "_string", null);
|
|
1974
1974
|
/**
|
|
1975
1975
|
* Widget type
|
|
1976
1976
|
*/
|
|
1977
|
-
|
|
1977
|
+
r(this, "_type", "form");
|
|
1978
1978
|
/**
|
|
1979
1979
|
* Determines if form is read only (default is false)
|
|
1980
1980
|
*/
|
|
1981
|
-
|
|
1981
|
+
r(this, "_readOnly", !1);
|
|
1982
1982
|
/**
|
|
1983
1983
|
* Context
|
|
1984
1984
|
*/
|
|
1985
|
-
|
|
1985
|
+
r(this, "_context", {});
|
|
1986
1986
|
/**
|
|
1987
1987
|
* Collection of onChange actions for fields
|
|
1988
1988
|
*/
|
|
1989
|
-
|
|
1989
|
+
r(this, "_onChangeFields", {});
|
|
1990
1990
|
/*
|
|
1991
1991
|
_widgets = {
|
|
1992
1992
|
*[Symbol.iterator]() {
|
|
@@ -2005,20 +2005,20 @@ class Ee {
|
|
|
2005
2005
|
/**
|
|
2006
2006
|
* Unique key for container
|
|
2007
2007
|
*/
|
|
2008
|
-
|
|
2008
|
+
r(this, "_keyIdx", 0);
|
|
2009
2009
|
/**
|
|
2010
2010
|
* List of invisible fields
|
|
2011
2011
|
*/
|
|
2012
|
-
|
|
2012
|
+
r(this, "_invisibleFields", []);
|
|
2013
2013
|
/**
|
|
2014
2014
|
* List of autorefreshable fields
|
|
2015
2015
|
*/
|
|
2016
|
-
|
|
2016
|
+
r(this, "_autorefreshableFields", []);
|
|
2017
2017
|
/**
|
|
2018
2018
|
* Context for each field in the form
|
|
2019
2019
|
*/
|
|
2020
|
-
|
|
2021
|
-
this._fields =
|
|
2020
|
+
r(this, "_contextForFields", {});
|
|
2021
|
+
this._fields = t, this._container = new V(e, 6, !1, "root");
|
|
2022
2022
|
}
|
|
2023
2023
|
get fields() {
|
|
2024
2024
|
return this._fields;
|
|
@@ -2035,32 +2035,32 @@ class Ee {
|
|
|
2035
2035
|
get readOnly() {
|
|
2036
2036
|
return this._readOnly;
|
|
2037
2037
|
}
|
|
2038
|
-
set readOnly(
|
|
2039
|
-
this._readOnly =
|
|
2038
|
+
set readOnly(t) {
|
|
2039
|
+
this._readOnly = t;
|
|
2040
2040
|
}
|
|
2041
2041
|
get context() {
|
|
2042
2042
|
return this._context;
|
|
2043
2043
|
}
|
|
2044
|
-
set context(
|
|
2045
|
-
this._context =
|
|
2044
|
+
set context(t) {
|
|
2045
|
+
this._context = t;
|
|
2046
2046
|
}
|
|
2047
2047
|
get onChangeFields() {
|
|
2048
2048
|
return this._onChangeFields;
|
|
2049
2049
|
}
|
|
2050
|
-
set onChangeFields(
|
|
2051
|
-
this._onChangeFields =
|
|
2050
|
+
set onChangeFields(t) {
|
|
2051
|
+
this._onChangeFields = t;
|
|
2052
2052
|
}
|
|
2053
2053
|
get keyIdx() {
|
|
2054
2054
|
return this._keyIdx;
|
|
2055
2055
|
}
|
|
2056
|
-
set keyIdx(
|
|
2057
|
-
this._keyIdx =
|
|
2056
|
+
set keyIdx(t) {
|
|
2057
|
+
this._keyIdx = t;
|
|
2058
2058
|
}
|
|
2059
2059
|
get invisibleFields() {
|
|
2060
2060
|
return this._invisibleFields;
|
|
2061
2061
|
}
|
|
2062
|
-
set invisibleFields(
|
|
2063
|
-
this._invisibleFields =
|
|
2062
|
+
set invisibleFields(t) {
|
|
2063
|
+
this._invisibleFields = t;
|
|
2064
2064
|
}
|
|
2065
2065
|
get autorefreshableFields() {
|
|
2066
2066
|
return this._autorefreshableFields;
|
|
@@ -2068,139 +2068,139 @@ class Ee {
|
|
|
2068
2068
|
get contextForFields() {
|
|
2069
2069
|
return this._contextForFields;
|
|
2070
2070
|
}
|
|
2071
|
-
set contextForFields(
|
|
2072
|
-
this._contextForFields =
|
|
2071
|
+
set contextForFields(t) {
|
|
2072
|
+
this._contextForFields = t;
|
|
2073
2073
|
}
|
|
2074
|
-
parse(
|
|
2075
|
-
var
|
|
2076
|
-
const { values:
|
|
2077
|
-
this._string = ((
|
|
2074
|
+
parse(t, e) {
|
|
2075
|
+
var o;
|
|
2076
|
+
const { values: s = {}, readOnly: n = !1 } = e || {}, a = D.parse(t).filter((h) => h.tagName === "form")[0];
|
|
2077
|
+
this._string = ((o = a.attributes) == null ? void 0 : o.string) || null, this._string && (this._string = m(this._string)), this._readOnly = n, this._context = s.id ? { active_id: s.id, active_ids: [s.id] } : {}, this._invisibleFields = [], this.parseNode({
|
|
2078
2078
|
fields: a.children,
|
|
2079
2079
|
container: this._container,
|
|
2080
|
-
values:
|
|
2080
|
+
values: s
|
|
2081
2081
|
});
|
|
2082
|
-
const
|
|
2083
|
-
|
|
2084
|
-
const _ =
|
|
2085
|
-
_._id && _._context && (this._contextForFields[_._id] =
|
|
2086
|
-
}), this._autorefreshableFields =
|
|
2082
|
+
const l = ct(this._container._rows);
|
|
2083
|
+
l.forEach((h) => {
|
|
2084
|
+
const _ = h;
|
|
2085
|
+
_._id && _._context && (this._contextForFields[_._id] = h._context);
|
|
2086
|
+
}), this._autorefreshableFields = l.filter((h) => h instanceof f && h.autoRefresh).map((h) => h._id);
|
|
2087
2087
|
}
|
|
2088
2088
|
parseNode({
|
|
2089
|
-
fields:
|
|
2090
|
-
container:
|
|
2091
|
-
values:
|
|
2089
|
+
fields: t,
|
|
2090
|
+
container: e,
|
|
2091
|
+
values: s
|
|
2092
2092
|
}) {
|
|
2093
|
-
const
|
|
2094
|
-
|
|
2095
|
-
var
|
|
2096
|
-
const { tagName:
|
|
2097
|
-
let _ =
|
|
2098
|
-
if (
|
|
2099
|
-
const { name:
|
|
2100
|
-
if (
|
|
2101
|
-
_ =
|
|
2102
|
-
else if (
|
|
2103
|
-
if (!this._fields[
|
|
2093
|
+
const n = new $();
|
|
2094
|
+
t.filter((a) => typeof a == "object").forEach((a) => {
|
|
2095
|
+
var F, C;
|
|
2096
|
+
const { tagName: l, attributes: o, children: h } = a;
|
|
2097
|
+
let _ = l, u = o;
|
|
2098
|
+
if (l === "field") {
|
|
2099
|
+
const { name: p, widget: I } = o;
|
|
2100
|
+
if (I)
|
|
2101
|
+
_ = I;
|
|
2102
|
+
else if (p) {
|
|
2103
|
+
if (!this._fields[p])
|
|
2104
2104
|
throw new Error(
|
|
2105
|
-
`Field ${
|
|
2105
|
+
`Field ${p} doesn't exist in fields defintion`
|
|
2106
2106
|
);
|
|
2107
|
-
_ = this._fields[
|
|
2108
|
-
...
|
|
2109
|
-
...this._fields[
|
|
2107
|
+
_ = this._fields[p].type, o.widget_props = {
|
|
2108
|
+
...U(o.widget_props),
|
|
2109
|
+
...this._fields[p].widget_props || {}
|
|
2110
2110
|
};
|
|
2111
2111
|
}
|
|
2112
2112
|
u = {
|
|
2113
|
-
...this._fields[
|
|
2114
|
-
...
|
|
2115
|
-
fieldsWidgetType: this._fields[
|
|
2113
|
+
...this._fields[p],
|
|
2114
|
+
...o,
|
|
2115
|
+
fieldsWidgetType: this._fields[p].type
|
|
2116
2116
|
};
|
|
2117
2117
|
}
|
|
2118
|
-
const
|
|
2118
|
+
const d = Ce({
|
|
2119
2119
|
tagAttributes: u,
|
|
2120
|
-
values:
|
|
2120
|
+
values: s,
|
|
2121
2121
|
fields: this._fields,
|
|
2122
|
-
widgetType:
|
|
2122
|
+
widgetType: l
|
|
2123
2123
|
});
|
|
2124
|
-
let
|
|
2125
|
-
|
|
2124
|
+
let g;
|
|
2125
|
+
l === "button" && u.states ? g = at({
|
|
2126
2126
|
states: u.states,
|
|
2127
|
-
values:
|
|
2128
|
-
}) :
|
|
2127
|
+
values: s
|
|
2128
|
+
}) : g = nt({
|
|
2129
2129
|
fieldName: u.name,
|
|
2130
|
-
values:
|
|
2130
|
+
values: s,
|
|
2131
2131
|
fields: this._fields
|
|
2132
2132
|
});
|
|
2133
|
-
const
|
|
2134
|
-
context: u.context || ((
|
|
2135
|
-
values:
|
|
2133
|
+
const c = ne({
|
|
2134
|
+
context: u.context || ((F = this._fields[u.name]) == null ? void 0 : F.context),
|
|
2135
|
+
values: s,
|
|
2136
2136
|
fields: this._fields
|
|
2137
2137
|
});
|
|
2138
|
-
u.on_change && (this._onChangeFields[u.name] =
|
|
2138
|
+
u.on_change && (this._onChangeFields[u.name] = ot(
|
|
2139
2139
|
u.on_change
|
|
2140
2140
|
));
|
|
2141
2141
|
let b;
|
|
2142
|
-
|
|
2142
|
+
Q(u.domain) ? b = u.domain : Q((C = this._fields[u.name]) == null ? void 0 : C.domain) && (b = this._fields[u.name].domain), this._keyIdx = this._keyIdx + 1;
|
|
2143
2143
|
const x = {
|
|
2144
|
-
...
|
|
2145
|
-
...
|
|
2146
|
-
context:
|
|
2144
|
+
...d,
|
|
2145
|
+
...g,
|
|
2146
|
+
context: c,
|
|
2147
2147
|
domain: b,
|
|
2148
2148
|
key: `${this._keyIdx}`
|
|
2149
2149
|
};
|
|
2150
|
-
|
|
2151
|
-
const y =
|
|
2152
|
-
y.invisible && y instanceof f && this._invisibleFields.push(x.name), y instanceof
|
|
2153
|
-
fields:
|
|
2150
|
+
e.readOnly && (x.readonly = !0);
|
|
2151
|
+
const y = n.createWidget(_, x);
|
|
2152
|
+
y.invisible && y instanceof f && this._invisibleFields.push(x.name), y instanceof v && this.parseNode({
|
|
2153
|
+
fields: h,
|
|
2154
2154
|
container: y.container,
|
|
2155
|
-
values:
|
|
2156
|
-
}), y instanceof
|
|
2155
|
+
values: s
|
|
2156
|
+
}), y instanceof ee && y.readOnly !== void 0 || (y.readOnly = y.readOnly || this.readOnly), e.addWidget(y);
|
|
2157
2157
|
});
|
|
2158
2158
|
}
|
|
2159
2159
|
/**
|
|
2160
2160
|
* Calls container's findById method to find the widgets matching with param id
|
|
2161
2161
|
* @param {string} id id to find
|
|
2162
2162
|
*/
|
|
2163
|
-
findById(
|
|
2164
|
-
return this.container.findById(
|
|
2163
|
+
findById(t) {
|
|
2164
|
+
return this.container.findById(t);
|
|
2165
2165
|
}
|
|
2166
2166
|
}
|
|
2167
|
-
function
|
|
2168
|
-
return
|
|
2167
|
+
function Q(i) {
|
|
2168
|
+
return i ? Array.isArray(i) && i.length > 0 ? !0 : typeof i == "string" && i !== "" && i !== "[]" : !1;
|
|
2169
2169
|
}
|
|
2170
|
-
class
|
|
2171
|
-
constructor(
|
|
2170
|
+
class Vt {
|
|
2171
|
+
constructor(t) {
|
|
2172
2172
|
/**
|
|
2173
2173
|
* Object containing fields specification of the form.
|
|
2174
2174
|
*/
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2175
|
+
r(this, "_fields");
|
|
2176
|
+
r(this, "_columns", []);
|
|
2177
|
+
r(this, "_string", null);
|
|
2178
2178
|
/**
|
|
2179
2179
|
* Widget type
|
|
2180
2180
|
*/
|
|
2181
|
-
|
|
2181
|
+
r(this, "_type", "tree");
|
|
2182
2182
|
/**
|
|
2183
2183
|
* Color expression value
|
|
2184
2184
|
*/
|
|
2185
|
-
|
|
2186
|
-
|
|
2185
|
+
r(this, "_colors", null);
|
|
2186
|
+
r(this, "_status", null);
|
|
2187
2187
|
/**
|
|
2188
2188
|
* Editable value
|
|
2189
2189
|
*/
|
|
2190
|
-
|
|
2190
|
+
r(this, "_editable", null);
|
|
2191
2191
|
/**
|
|
2192
2192
|
* Context for each field in the form
|
|
2193
2193
|
*/
|
|
2194
|
-
|
|
2194
|
+
r(this, "_contextForFields", {});
|
|
2195
2195
|
/**
|
|
2196
2196
|
* List of autorefreshable fields
|
|
2197
2197
|
*/
|
|
2198
|
-
|
|
2198
|
+
r(this, "_autorefreshableFields", []);
|
|
2199
2199
|
/**
|
|
2200
2200
|
* Is infinite
|
|
2201
2201
|
*/
|
|
2202
|
-
|
|
2203
|
-
this._fields =
|
|
2202
|
+
r(this, "_infinite", !1);
|
|
2203
|
+
this._fields = t;
|
|
2204
2204
|
}
|
|
2205
2205
|
get fields() {
|
|
2206
2206
|
return this._fields;
|
|
@@ -2226,8 +2226,8 @@ class Ve {
|
|
|
2226
2226
|
get contextForFields() {
|
|
2227
2227
|
return this._contextForFields;
|
|
2228
2228
|
}
|
|
2229
|
-
set contextForFields(
|
|
2230
|
-
this._contextForFields =
|
|
2229
|
+
set contextForFields(t) {
|
|
2230
|
+
this._contextForFields = t;
|
|
2231
2231
|
}
|
|
2232
2232
|
get autorefreshableFields() {
|
|
2233
2233
|
return this._autorefreshableFields;
|
|
@@ -2235,41 +2235,41 @@ class Ve {
|
|
|
2235
2235
|
get infinite() {
|
|
2236
2236
|
return this._infinite;
|
|
2237
2237
|
}
|
|
2238
|
-
set infinite(
|
|
2239
|
-
this._infinite =
|
|
2238
|
+
set infinite(t) {
|
|
2239
|
+
this._infinite = t;
|
|
2240
2240
|
}
|
|
2241
|
-
parse(
|
|
2242
|
-
const
|
|
2243
|
-
this._string =
|
|
2244
|
-
const
|
|
2245
|
-
|
|
2246
|
-
const { tagName: a, attributes:
|
|
2247
|
-
let
|
|
2241
|
+
parse(t) {
|
|
2242
|
+
const e = D.parse(t).filter((n) => n.tagName === "tree")[0];
|
|
2243
|
+
this._string = e.attributes.string || null, this._string && (this._string = m(this._string)), this._colors = e.attributes.colors || null, this._colors && (this._colors = m(this._colors)), this._status = e.attributes.status || null, this._status && (this._status = m(this._status)), this._editable = e.attributes.editable || null, this._infinite = e.attributes.infinite || !1;
|
|
2244
|
+
const s = new $();
|
|
2245
|
+
e.children.forEach((n) => {
|
|
2246
|
+
const { tagName: a, attributes: l } = n;
|
|
2247
|
+
let o = null;
|
|
2248
2248
|
if (a === "field") {
|
|
2249
|
-
const { name:
|
|
2250
|
-
let u =
|
|
2251
|
-
if (
|
|
2252
|
-
if (!this._fields[
|
|
2253
|
-
throw new Error(`Field ${
|
|
2254
|
-
const
|
|
2255
|
-
|
|
2256
|
-
const
|
|
2257
|
-
context:
|
|
2249
|
+
const { name: h, widget: _ } = l;
|
|
2250
|
+
let u = l;
|
|
2251
|
+
if (h) {
|
|
2252
|
+
if (!this._fields[h])
|
|
2253
|
+
throw new Error(`Field ${h} doesn't exist in fields defintion`);
|
|
2254
|
+
const d = this._fields[h];
|
|
2255
|
+
o = d.type, (Array.isArray(d == null ? void 0 : d.domain) && (d == null ? void 0 : d.domain.length) === 0 || (d == null ? void 0 : d.domain) === !1) && l.domain && l.domain.length > 0 && delete d.domain;
|
|
2256
|
+
const g = ne({
|
|
2257
|
+
context: l.context || d.context,
|
|
2258
2258
|
values: {},
|
|
2259
2259
|
fields: this._fields
|
|
2260
2260
|
});
|
|
2261
2261
|
u = {
|
|
2262
|
-
...
|
|
2263
|
-
...
|
|
2264
|
-
fieldsWidgetType:
|
|
2265
|
-
context:
|
|
2266
|
-
}, this._contextForFields[
|
|
2262
|
+
...d,
|
|
2263
|
+
...l,
|
|
2264
|
+
fieldsWidgetType: d == null ? void 0 : d.type,
|
|
2265
|
+
context: g
|
|
2266
|
+
}, this._contextForFields[h] = g;
|
|
2267
2267
|
}
|
|
2268
|
-
if (_ && (
|
|
2269
|
-
const
|
|
2270
|
-
this._columns.push(
|
|
2268
|
+
if (_ && (o = _), !u.invisible) {
|
|
2269
|
+
const d = s.createWidget(o, u);
|
|
2270
|
+
this._columns.push(d);
|
|
2271
2271
|
}
|
|
2272
|
-
|
|
2272
|
+
w(u.autorefresh) && this._autorefreshableFields.push(h);
|
|
2273
2273
|
}
|
|
2274
2274
|
});
|
|
2275
2275
|
}
|
|
@@ -2277,220 +2277,11 @@ class Ve {
|
|
|
2277
2277
|
* Find the widgets matching with param id
|
|
2278
2278
|
* @param {string} id id to find
|
|
2279
2279
|
*/
|
|
2280
|
-
findById(
|
|
2281
|
-
return this._columns.find((
|
|
2282
|
-
}
|
|
2283
|
-
}
|
|
2284
|
-
class Ye {
|
|
2285
|
-
constructor(e) {
|
|
2286
|
-
/**
|
|
2287
|
-
* Object containing fields specification of the kanban.
|
|
2288
|
-
*/
|
|
2289
|
-
n(this, "_fields");
|
|
2290
|
-
/**
|
|
2291
|
-
* Array of field widgets to display in cards
|
|
2292
|
-
*/
|
|
2293
|
-
n(this, "_card_fields", []);
|
|
2294
|
-
/**
|
|
2295
|
-
* Array of button widgets to display in cards
|
|
2296
|
-
*/
|
|
2297
|
-
n(this, "_buttons", []);
|
|
2298
|
-
n(this, "_string", null);
|
|
2299
|
-
n(this, "_status", null);
|
|
2300
|
-
/**
|
|
2301
|
-
* Widget type
|
|
2302
|
-
*/
|
|
2303
|
-
n(this, "_type", "kanban");
|
|
2304
|
-
/**
|
|
2305
|
-
* Field that defines the columns (e.g., "state")
|
|
2306
|
-
*/
|
|
2307
|
-
n(this, "_column_field", "state");
|
|
2308
|
-
/**
|
|
2309
|
-
* Domain for filtering columns (for many2one fields)
|
|
2310
|
-
* Example: "[('fold', '!=', True)]"
|
|
2311
|
-
*/
|
|
2312
|
-
n(this, "_column_domain", null);
|
|
2313
|
-
/**
|
|
2314
|
-
* Enable dragging cards between columns
|
|
2315
|
-
*/
|
|
2316
|
-
n(this, "_drag", !0);
|
|
2317
|
-
/**
|
|
2318
|
-
* Field name to use for sorting cards within columns
|
|
2319
|
-
*/
|
|
2320
|
-
n(this, "_sort");
|
|
2321
|
-
/**
|
|
2322
|
-
* Enable setting max cards per column (WIP limits)
|
|
2323
|
-
*/
|
|
2324
|
-
n(this, "_set_max_cards", !1);
|
|
2325
|
-
/**
|
|
2326
|
-
* Color expression value (e.g., "blue:state=='draft';green:state=='done'")
|
|
2327
|
-
*/
|
|
2328
|
-
n(this, "_colors", null);
|
|
2329
|
-
/**
|
|
2330
|
-
* Custom function to call when a card moves between columns
|
|
2331
|
-
* Example: "handle_state_change" or with args "handle_state_change(field, from, to)"
|
|
2332
|
-
* If not defined, the frontend should use the default on_change_column method
|
|
2333
|
-
*/
|
|
2334
|
-
n(this, "_on_change_column", null);
|
|
2335
|
-
/**
|
|
2336
|
-
* Context for each field in the kanban
|
|
2337
|
-
*/
|
|
2338
|
-
n(this, "_contextForFields", {});
|
|
2339
|
-
/**
|
|
2340
|
-
* Map of fields that have sum aggregation
|
|
2341
|
-
* Key: field name, Value: sum label (e.g., "Total hours")
|
|
2342
|
-
*/
|
|
2343
|
-
n(this, "_aggregations", {});
|
|
2344
|
-
this._fields = e;
|
|
2345
|
-
}
|
|
2346
|
-
get fields() {
|
|
2347
|
-
return this._fields;
|
|
2348
|
-
}
|
|
2349
|
-
get card_fields() {
|
|
2350
|
-
return this._card_fields;
|
|
2351
|
-
}
|
|
2352
|
-
get buttons() {
|
|
2353
|
-
return this._buttons;
|
|
2354
|
-
}
|
|
2355
|
-
get string() {
|
|
2356
|
-
return this._string;
|
|
2357
|
-
}
|
|
2358
|
-
get status() {
|
|
2359
|
-
return this._status;
|
|
2360
|
-
}
|
|
2361
|
-
get type() {
|
|
2362
|
-
return this._type;
|
|
2363
|
-
}
|
|
2364
|
-
get column_field() {
|
|
2365
|
-
return this._column_field;
|
|
2366
|
-
}
|
|
2367
|
-
get column_domain() {
|
|
2368
|
-
return this._column_domain;
|
|
2369
|
-
}
|
|
2370
|
-
get drag() {
|
|
2371
|
-
return this._drag;
|
|
2372
|
-
}
|
|
2373
|
-
get sort() {
|
|
2374
|
-
return this._sort;
|
|
2375
|
-
}
|
|
2376
|
-
get set_max_cards() {
|
|
2377
|
-
return this._set_max_cards;
|
|
2378
|
-
}
|
|
2379
|
-
get colors() {
|
|
2380
|
-
return this._colors;
|
|
2381
|
-
}
|
|
2382
|
-
get on_change_column() {
|
|
2383
|
-
return this._on_change_column;
|
|
2384
|
-
}
|
|
2385
|
-
get contextForFields() {
|
|
2386
|
-
return this._contextForFields;
|
|
2387
|
-
}
|
|
2388
|
-
set contextForFields(e) {
|
|
2389
|
-
this._contextForFields = e;
|
|
2390
|
-
}
|
|
2391
|
-
get aggregations() {
|
|
2392
|
-
return this._aggregations;
|
|
2393
|
-
}
|
|
2394
|
-
parse(e) {
|
|
2395
|
-
const t = I.parse(e).filter((r) => r.tagName === "kanban")[0];
|
|
2396
|
-
this._string = t.attributes.string || null, this._string && (this._string = g(this._string)), this._column_field = t.attributes.column_field || "state", this._column_domain = t.attributes.column_domain || null, this._drag = t.attributes.drag !== void 0 ? p(t.attributes.drag) : !0, this._sort = t.attributes.sort || void 0, this._set_max_cards = t.attributes.set_max_cards !== void 0 ? p(t.attributes.set_max_cards) : !1, this._colors = t.attributes.colors || null, this._colors && (this._colors = g(this._colors)), this._status = t.attributes.status || null, this._status && (this._status = g(this._status)), t.attributes.on_change_column && (this._on_change_column = dt(t.attributes.on_change_column));
|
|
2397
|
-
const i = new E();
|
|
2398
|
-
t.children.forEach((r) => {
|
|
2399
|
-
const { tagName: a, attributes: o } = r;
|
|
2400
|
-
a === "field" ? this._parseField(r, o, i) : a === "button" && this._parseButton(r, o);
|
|
2401
|
-
});
|
|
2402
|
-
}
|
|
2403
|
-
_parseField(e, t, i) {
|
|
2404
|
-
const { name: r, widget: a, sum: o } = t;
|
|
2405
|
-
if (!r)
|
|
2406
|
-
return;
|
|
2407
|
-
if (!this._fields[r])
|
|
2408
|
-
throw new Error(`Field ${r} doesn't exist in fields definition`);
|
|
2409
|
-
const l = this._fields[r];
|
|
2410
|
-
let c = l.type;
|
|
2411
|
-
(Array.isArray(l == null ? void 0 : l.domain) && (l == null ? void 0 : l.domain.length) === 0 || (l == null ? void 0 : l.domain) === !1) && t.domain && t.domain.length > 0 && delete l.domain;
|
|
2412
|
-
const _ = J({
|
|
2413
|
-
context: t.context || l.context,
|
|
2414
|
-
values: {},
|
|
2415
|
-
fields: this._fields
|
|
2416
|
-
}), u = {
|
|
2417
|
-
...l,
|
|
2418
|
-
...t,
|
|
2419
|
-
fieldsWidgetType: l == null ? void 0 : l.type,
|
|
2420
|
-
context: _
|
|
2421
|
-
};
|
|
2422
|
-
if (this._contextForFields[r] = _, a && (c = a), !u.invisible) {
|
|
2423
|
-
const h = i.createWidget(
|
|
2424
|
-
c,
|
|
2425
|
-
u
|
|
2426
|
-
);
|
|
2427
|
-
o && (h.sum = g(o), this._aggregations[r] = g(o)), this._card_fields.push(h);
|
|
2428
|
-
}
|
|
2429
|
-
}
|
|
2430
|
-
_parseButton(e, t) {
|
|
2431
|
-
const { name: i, type: r, string: a, states: o } = t;
|
|
2432
|
-
if (!i)
|
|
2433
|
-
return;
|
|
2434
|
-
const l = {
|
|
2435
|
-
...t,
|
|
2436
|
-
name: i,
|
|
2437
|
-
buttonType: r || "object",
|
|
2438
|
-
string: a || ""
|
|
2439
|
-
}, c = new A(l);
|
|
2440
|
-
o && (c.states = o), this._buttons.push(c);
|
|
2441
|
-
}
|
|
2442
|
-
/**
|
|
2443
|
-
* Find the widgets matching with param id
|
|
2444
|
-
* @param {string} id id to find
|
|
2445
|
-
*/
|
|
2446
|
-
findById(e) {
|
|
2447
|
-
const t = this._card_fields.find((r) => r.findById ? r.findById(e) : !1);
|
|
2448
|
-
return t || this._buttons.find((r) => r.findById ? r.findById(e) : !1) || null;
|
|
2449
|
-
}
|
|
2450
|
-
}
|
|
2451
|
-
class De {
|
|
2452
|
-
constructor(e) {
|
|
2453
|
-
n(this, "_kanbanDef");
|
|
2454
|
-
this._kanbanDef = e;
|
|
2455
|
-
}
|
|
2456
|
-
get kanbanDef() {
|
|
2457
|
-
return this._kanbanDef;
|
|
2458
|
-
}
|
|
2459
|
-
parse(e, t) {
|
|
2460
|
-
const i = (t == null ? void 0 : t.readOnly) ?? !1, r = new z(1, 12, i), a = new E();
|
|
2461
|
-
let o = 0;
|
|
2462
|
-
return this._kanbanDef.card_fields.forEach((l) => {
|
|
2463
|
-
o++;
|
|
2464
|
-
const c = tt({
|
|
2465
|
-
tagAttributes: l.raw_props || {},
|
|
2466
|
-
values: e,
|
|
2467
|
-
fields: this._kanbanDef.fields,
|
|
2468
|
-
widgetType: l.type || "field"
|
|
2469
|
-
}), _ = {
|
|
2470
|
-
...l.raw_props || {},
|
|
2471
|
-
...c,
|
|
2472
|
-
key: `field_${o}`
|
|
2473
|
-
};
|
|
2474
|
-
i && (_.readonly = !0);
|
|
2475
|
-
const u = l.type || "field", h = a.createWidget(u, _);
|
|
2476
|
-
r.addWidget(h, { addLabel: !l.nolabel });
|
|
2477
|
-
}), this._kanbanDef.buttons.forEach((l) => {
|
|
2478
|
-
o++;
|
|
2479
|
-
const c = l.states ? lt({
|
|
2480
|
-
states: l.states,
|
|
2481
|
-
values: e
|
|
2482
|
-
}) : {}, _ = {
|
|
2483
|
-
...l.raw_props || {},
|
|
2484
|
-
...c,
|
|
2485
|
-
key: `button_${o}`
|
|
2486
|
-
};
|
|
2487
|
-
i && (_.readonly = !0);
|
|
2488
|
-
const u = new A(_);
|
|
2489
|
-
r.addWidget(u, { addLabel: !1 });
|
|
2490
|
-
}), r;
|
|
2280
|
+
findById(t) {
|
|
2281
|
+
return this._columns.find((e) => e.findById ? e.findById(t) : !1);
|
|
2491
2282
|
}
|
|
2492
2283
|
}
|
|
2493
|
-
const
|
|
2284
|
+
const ht = {
|
|
2494
2285
|
text: "text",
|
|
2495
2286
|
many2one: "many2one",
|
|
2496
2287
|
char: "char",
|
|
@@ -2503,19 +2294,19 @@ const de = {
|
|
|
2503
2294
|
date: "date",
|
|
2504
2295
|
datetime: "datetime"
|
|
2505
2296
|
};
|
|
2506
|
-
class
|
|
2507
|
-
constructor(
|
|
2297
|
+
class Yt {
|
|
2298
|
+
constructor(t, e, s = 8) {
|
|
2508
2299
|
/**
|
|
2509
2300
|
* Object containing the specific fields for primary and secondary search fields
|
|
2510
2301
|
*/
|
|
2511
|
-
|
|
2302
|
+
r(this, "_searchFields");
|
|
2512
2303
|
/**
|
|
2513
2304
|
* Object containing all the fields specification of the whole form
|
|
2514
2305
|
*/
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
this._searchFields =
|
|
2306
|
+
r(this, "_fields");
|
|
2307
|
+
r(this, "_simpleSearchContainer");
|
|
2308
|
+
r(this, "_advancedSearchContainer");
|
|
2309
|
+
this._searchFields = t, this._fields = e, this._simpleSearchContainer = new V(s), this._advancedSearchContainer = new V(s);
|
|
2519
2310
|
}
|
|
2520
2311
|
get searchFields() {
|
|
2521
2312
|
return this._searchFields;
|
|
@@ -2530,62 +2321,60 @@ class je {
|
|
|
2530
2321
|
return this._advancedSearchContainer;
|
|
2531
2322
|
}
|
|
2532
2323
|
parse() {
|
|
2533
|
-
const
|
|
2324
|
+
const t = new $();
|
|
2534
2325
|
this.parseFields(
|
|
2535
2326
|
this.searchFields.primary,
|
|
2536
|
-
|
|
2537
|
-
).forEach((
|
|
2538
|
-
this.simpleSearchContainer.addWidget(
|
|
2327
|
+
t
|
|
2328
|
+
).forEach((n) => {
|
|
2329
|
+
this.simpleSearchContainer.addWidget(n, { addLabel: !1 }), this.advancedSearchContainer.addWidget(n, { addLabel: !1 });
|
|
2539
2330
|
}), this.parseFields(
|
|
2540
2331
|
this.searchFields.secondary,
|
|
2541
|
-
|
|
2542
|
-
).forEach((
|
|
2543
|
-
this.advancedSearchContainer.addWidget(
|
|
2332
|
+
t
|
|
2333
|
+
).forEach((n) => {
|
|
2334
|
+
this.advancedSearchContainer.addWidget(n, { addLabel: !1 });
|
|
2544
2335
|
});
|
|
2545
2336
|
}
|
|
2546
|
-
parseFields(
|
|
2547
|
-
return
|
|
2548
|
-
const
|
|
2549
|
-
...this.fields[
|
|
2550
|
-
name:
|
|
2337
|
+
parseFields(t, e) {
|
|
2338
|
+
return t.map((s) => {
|
|
2339
|
+
const n = {
|
|
2340
|
+
...this.fields[s],
|
|
2341
|
+
name: s,
|
|
2551
2342
|
colspan: 2,
|
|
2552
|
-
fieldsWidgetType: this.fields[
|
|
2553
|
-
}, { type: a, widget:
|
|
2554
|
-
let
|
|
2555
|
-
return
|
|
2556
|
-
`[SearchFilter] Field "${i}" has unsupported type "${a}"`
|
|
2557
|
-
), l = a), t.createWidget(l, r);
|
|
2343
|
+
fieldsWidgetType: this.fields[s].type
|
|
2344
|
+
}, { type: a, widget: l } = n;
|
|
2345
|
+
let o = l ?? a;
|
|
2346
|
+
return ht[o] === void 0 && (o = a), e.createWidget(o, n);
|
|
2558
2347
|
});
|
|
2559
2348
|
}
|
|
2560
2349
|
/**
|
|
2561
2350
|
* Calls container's findById method to find the widgets matching with param id
|
|
2562
2351
|
* @param {string} id id to find
|
|
2563
2352
|
*/
|
|
2564
|
-
findById(
|
|
2565
|
-
return this.advancedSearchContainer.findById(
|
|
2353
|
+
findById(t) {
|
|
2354
|
+
return this.advancedSearchContainer.findById(t);
|
|
2566
2355
|
}
|
|
2567
2356
|
}
|
|
2568
|
-
const
|
|
2569
|
-
domain:
|
|
2570
|
-
widgetFieldName:
|
|
2357
|
+
const Dt = ({
|
|
2358
|
+
domain: i,
|
|
2359
|
+
widgetFieldName: t
|
|
2571
2360
|
}) => {
|
|
2572
|
-
const
|
|
2573
|
-
return
|
|
2574
|
-
if (!Array.isArray(
|
|
2361
|
+
const e = [];
|
|
2362
|
+
return i.forEach((s) => {
|
|
2363
|
+
if (!Array.isArray(s))
|
|
2575
2364
|
return;
|
|
2576
|
-
const [
|
|
2577
|
-
let
|
|
2578
|
-
|
|
2579
|
-
|
|
2580
|
-
|
|
2581
|
-
)) : (
|
|
2582
|
-
}),
|
|
2583
|
-
},
|
|
2584
|
-
class
|
|
2585
|
-
constructor(
|
|
2586
|
-
|
|
2587
|
-
|
|
2588
|
-
|
|
2365
|
+
const [n, a, l] = s;
|
|
2366
|
+
let o, h;
|
|
2367
|
+
n.indexOf(".") !== -1 ? (o = n.substr(0, n.indexOf(".")), h = n.substr(
|
|
2368
|
+
n.indexOf(".") + 1,
|
|
2369
|
+
n.length - 1
|
|
2370
|
+
)) : (o = n, h = "id"), o === t && e.push([h, a, l]);
|
|
2371
|
+
}), e;
|
|
2372
|
+
}, jt = (i) => typeof i != "string" ? [] : i.replace(/[()[\]]/g, "").split(",").map((t) => t.trim()).filter((t) => !t.includes("'"));
|
|
2373
|
+
class dt {
|
|
2374
|
+
constructor(t) {
|
|
2375
|
+
r(this, "_action_id", null);
|
|
2376
|
+
r(this, "_position", null);
|
|
2377
|
+
t.action_id && (this._action_id = t.action_id), t.position && (this._position = t.position);
|
|
2589
2378
|
}
|
|
2590
2379
|
get action_id() {
|
|
2591
2380
|
return this._action_id;
|
|
@@ -2594,15 +2383,15 @@ class ue {
|
|
|
2594
2383
|
return this._position;
|
|
2595
2384
|
}
|
|
2596
2385
|
}
|
|
2597
|
-
class
|
|
2598
|
-
constructor(
|
|
2599
|
-
|
|
2600
|
-
|
|
2601
|
-
const
|
|
2602
|
-
this._string =
|
|
2603
|
-
const { children:
|
|
2604
|
-
|
|
2605
|
-
|
|
2386
|
+
class Mt {
|
|
2387
|
+
constructor(t) {
|
|
2388
|
+
r(this, "_string", null);
|
|
2389
|
+
r(this, "_items", []);
|
|
2390
|
+
const e = D.parse(t).filter((n) => n.tagName === "dashboard")[0];
|
|
2391
|
+
this._string = e.attributes.string || null;
|
|
2392
|
+
const { children: s } = e;
|
|
2393
|
+
s.forEach((n) => {
|
|
2394
|
+
n.tagName === "dashboard_item" && this._items.push(new dt(n.attributes));
|
|
2606
2395
|
});
|
|
2607
2396
|
}
|
|
2608
2397
|
get string() {
|
|
@@ -2612,16 +2401,16 @@ class Me {
|
|
|
2612
2401
|
return this._items;
|
|
2613
2402
|
}
|
|
2614
2403
|
}
|
|
2615
|
-
class
|
|
2616
|
-
constructor(
|
|
2617
|
-
|
|
2618
|
-
|
|
2619
|
-
|
|
2620
|
-
|
|
2621
|
-
|
|
2622
|
-
if (this._string =
|
|
2623
|
-
const
|
|
2624
|
-
(
|
|
2404
|
+
class oe {
|
|
2405
|
+
constructor(t) {
|
|
2406
|
+
r(this, "_string", null);
|
|
2407
|
+
r(this, "_type");
|
|
2408
|
+
r(this, "_timerange", null);
|
|
2409
|
+
r(this, "_interval", 1);
|
|
2410
|
+
r(this, "_y_range", "default");
|
|
2411
|
+
if (this._string = t.attributes.string || null, this._timerange = t.attributes.timerange || null, t.attributes.interval && (this._interval = parseInt(t.attributes.interval)), t.attributes.y_range) {
|
|
2412
|
+
const e = t.attributes.y_range;
|
|
2413
|
+
(e === "auto" || e === "full" || e === "default") && (this._y_range = e);
|
|
2625
2414
|
}
|
|
2626
2415
|
}
|
|
2627
2416
|
get string() {
|
|
@@ -2640,17 +2429,17 @@ class ut {
|
|
|
2640
2429
|
return this._y_range;
|
|
2641
2430
|
}
|
|
2642
2431
|
}
|
|
2643
|
-
class
|
|
2644
|
-
constructor(
|
|
2645
|
-
super(
|
|
2646
|
-
|
|
2647
|
-
|
|
2648
|
-
|
|
2649
|
-
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
this._type =
|
|
2432
|
+
class ce extends oe {
|
|
2433
|
+
constructor(e, s) {
|
|
2434
|
+
super(s);
|
|
2435
|
+
r(this, "_color", null);
|
|
2436
|
+
r(this, "_icon", null);
|
|
2437
|
+
r(this, "_totalDomain", null);
|
|
2438
|
+
r(this, "_showPercent", !1);
|
|
2439
|
+
r(this, "_progressbar", !1);
|
|
2440
|
+
r(this, "_showTotal", !0);
|
|
2441
|
+
r(this, "_suffix", null);
|
|
2442
|
+
this._type = e, this._color = s.attributes.color || null, this._color && (this._color = m(this._color)), this._icon = s.attributes.icon || null, this._icon && (this._icon = m(this._icon)), this._suffix = s.attributes.suffix || null, this._totalDomain = m(s.attributes.totalDomain) || null, this._showPercent = w(s.attributes.showPercent), this._progressbar = w(s.attributes.progressbar), this._showTotal = s.attributes.showTotal !== void 0 ? w(s.attributes.showTotal) : !!this._totalDomain;
|
|
2654
2443
|
}
|
|
2655
2444
|
get color() {
|
|
2656
2445
|
return this._color;
|
|
@@ -2674,16 +2463,16 @@ class ht extends ut {
|
|
|
2674
2463
|
return this._suffix;
|
|
2675
2464
|
}
|
|
2676
2465
|
}
|
|
2677
|
-
class
|
|
2678
|
-
constructor(
|
|
2679
|
-
super(
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
const { children:
|
|
2683
|
-
|
|
2466
|
+
class ut extends ce {
|
|
2467
|
+
constructor(e, s) {
|
|
2468
|
+
super(e, s);
|
|
2469
|
+
r(this, "_field");
|
|
2470
|
+
r(this, "_operator");
|
|
2471
|
+
const { children: n } = s;
|
|
2472
|
+
n.forEach((a) => {
|
|
2684
2473
|
if (a.tagName === "field") {
|
|
2685
|
-
const
|
|
2686
|
-
this._field =
|
|
2474
|
+
const l = a.attributes.name, o = a.attributes.operator;
|
|
2475
|
+
this._field = l || void 0, this._operator = o;
|
|
2687
2476
|
}
|
|
2688
2477
|
});
|
|
2689
2478
|
}
|
|
@@ -2694,44 +2483,44 @@ class he extends ht {
|
|
|
2694
2483
|
return this._operator;
|
|
2695
2484
|
}
|
|
2696
2485
|
}
|
|
2697
|
-
const
|
|
2698
|
-
const
|
|
2699
|
-
let
|
|
2700
|
-
if (
|
|
2701
|
-
if (
|
|
2702
|
-
const
|
|
2703
|
-
if (!
|
|
2704
|
-
throw new Error(`Field ${
|
|
2705
|
-
if (!
|
|
2486
|
+
const _t = (i) => {
|
|
2487
|
+
const t = [];
|
|
2488
|
+
let e;
|
|
2489
|
+
if (i.forEach((s) => {
|
|
2490
|
+
if (s.tagName === "field") {
|
|
2491
|
+
const n = s.attributes.axis, a = s.attributes.operator, l = s.attributes.name, o = s.attributes.label || void 0, h = s.attributes.stacked || void 0;
|
|
2492
|
+
if (!n)
|
|
2493
|
+
throw new Error(`Field ${l} doesn't have an axis`);
|
|
2494
|
+
if (!l)
|
|
2706
2495
|
throw new Error("Missing name attribute for field");
|
|
2707
|
-
|
|
2708
|
-
name:
|
|
2709
|
-
}) :
|
|
2710
|
-
new
|
|
2711
|
-
name:
|
|
2496
|
+
n === "x" ? e = new mt({
|
|
2497
|
+
name: l
|
|
2498
|
+
}) : n === "y" && t.push(
|
|
2499
|
+
new gt({
|
|
2500
|
+
name: l,
|
|
2712
2501
|
operator: a,
|
|
2713
|
-
label:
|
|
2714
|
-
stacked:
|
|
2502
|
+
label: o,
|
|
2503
|
+
stacked: h
|
|
2715
2504
|
})
|
|
2716
2505
|
);
|
|
2717
2506
|
}
|
|
2718
|
-
}), !
|
|
2507
|
+
}), !e)
|
|
2719
2508
|
throw new Error("No x axis found");
|
|
2720
|
-
if (!
|
|
2509
|
+
if (!t.length)
|
|
2721
2510
|
throw new Error("No y axis found. At least we need one y axis");
|
|
2722
2511
|
return {
|
|
2723
|
-
x:
|
|
2724
|
-
y:
|
|
2512
|
+
x: e,
|
|
2513
|
+
y: t
|
|
2725
2514
|
};
|
|
2726
2515
|
};
|
|
2727
|
-
class M extends
|
|
2728
|
-
constructor(
|
|
2729
|
-
super(
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
this._type =
|
|
2733
|
-
const
|
|
2734
|
-
this._x =
|
|
2516
|
+
class M extends oe {
|
|
2517
|
+
constructor(e, s) {
|
|
2518
|
+
super(s);
|
|
2519
|
+
r(this, "_x");
|
|
2520
|
+
r(this, "_y");
|
|
2521
|
+
this._type = e;
|
|
2522
|
+
const n = _t(s.children);
|
|
2523
|
+
this._x = n.x, this._y = n.y;
|
|
2735
2524
|
}
|
|
2736
2525
|
get x() {
|
|
2737
2526
|
return this._x;
|
|
@@ -2740,26 +2529,26 @@ class M extends ut {
|
|
|
2740
2529
|
return this._y;
|
|
2741
2530
|
}
|
|
2742
2531
|
}
|
|
2743
|
-
const
|
|
2744
|
-
indicator:
|
|
2745
|
-
indicatorField:
|
|
2532
|
+
const ft = {
|
|
2533
|
+
indicator: ce,
|
|
2534
|
+
indicatorField: ut,
|
|
2746
2535
|
line: M,
|
|
2747
2536
|
bar: M,
|
|
2748
2537
|
pie: M
|
|
2749
|
-
},
|
|
2750
|
-
const
|
|
2751
|
-
if (!
|
|
2752
|
-
throw new Error(`${
|
|
2753
|
-
const
|
|
2754
|
-
if (!
|
|
2755
|
-
throw new Error(`${
|
|
2756
|
-
return new
|
|
2538
|
+
}, Nt = (i) => {
|
|
2539
|
+
const t = D.parse(i).filter((n) => n.tagName === "graph")[0], e = t.attributes.type;
|
|
2540
|
+
if (!e)
|
|
2541
|
+
throw new Error(`${e} is not a valid graph`);
|
|
2542
|
+
const s = ft[e];
|
|
2543
|
+
if (!s)
|
|
2544
|
+
throw new Error(`${e} not found as a GraphModel`);
|
|
2545
|
+
return new s(e, t);
|
|
2757
2546
|
};
|
|
2758
|
-
class
|
|
2759
|
-
constructor({ name:
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
this._name =
|
|
2547
|
+
class he {
|
|
2548
|
+
constructor({ name: t, axis: e }) {
|
|
2549
|
+
r(this, "_name");
|
|
2550
|
+
r(this, "_axis");
|
|
2551
|
+
this._name = t, this._axis = e;
|
|
2763
2552
|
}
|
|
2764
2553
|
get name() {
|
|
2765
2554
|
return this._name;
|
|
@@ -2768,18 +2557,18 @@ class _t {
|
|
|
2768
2557
|
return this._axis;
|
|
2769
2558
|
}
|
|
2770
2559
|
}
|
|
2771
|
-
class
|
|
2560
|
+
class gt extends he {
|
|
2772
2561
|
constructor({
|
|
2773
|
-
name:
|
|
2774
|
-
operator:
|
|
2775
|
-
label:
|
|
2562
|
+
name: e,
|
|
2563
|
+
operator: s,
|
|
2564
|
+
label: n,
|
|
2776
2565
|
stacked: a
|
|
2777
2566
|
}) {
|
|
2778
|
-
super({ name:
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
this._operator =
|
|
2567
|
+
super({ name: e, axis: "y" });
|
|
2568
|
+
r(this, "_operator");
|
|
2569
|
+
r(this, "_label");
|
|
2570
|
+
r(this, "_stacked");
|
|
2571
|
+
this._operator = s, this._label = n, this._stacked = a;
|
|
2783
2572
|
}
|
|
2784
2573
|
get operator() {
|
|
2785
2574
|
return this._operator;
|
|
@@ -2791,78 +2580,78 @@ class ge extends _t {
|
|
|
2791
2580
|
return this._stacked;
|
|
2792
2581
|
}
|
|
2793
2582
|
}
|
|
2794
|
-
class
|
|
2795
|
-
constructor({ name:
|
|
2796
|
-
super({ name:
|
|
2583
|
+
class mt extends he {
|
|
2584
|
+
constructor({ name: t }) {
|
|
2585
|
+
super({ name: t, axis: "x" });
|
|
2797
2586
|
}
|
|
2798
2587
|
}
|
|
2799
|
-
const
|
|
2800
|
-
const
|
|
2801
|
-
return
|
|
2802
|
-
|
|
2803
|
-
}),
|
|
2588
|
+
const bt = ({ ooui: i }) => {
|
|
2589
|
+
const e = [i.x.name];
|
|
2590
|
+
return i.y ? (i.y.forEach((s) => {
|
|
2591
|
+
s.operator !== "count" && !e.includes(s.name) && e.push(s.name), s.label && !e.includes(s.label) && e.push(s.label);
|
|
2592
|
+
}), e) : [];
|
|
2804
2593
|
};
|
|
2805
|
-
function
|
|
2806
|
-
fields:
|
|
2807
|
-
values:
|
|
2808
|
-
fieldName:
|
|
2594
|
+
function q({
|
|
2595
|
+
fields: i,
|
|
2596
|
+
values: t,
|
|
2597
|
+
fieldName: e
|
|
2809
2598
|
}) {
|
|
2810
|
-
const
|
|
2811
|
-
if (!
|
|
2812
|
-
throw new Error(`Field ${
|
|
2813
|
-
if (
|
|
2814
|
-
return
|
|
2815
|
-
if (
|
|
2816
|
-
const
|
|
2817
|
-
return
|
|
2599
|
+
const s = i[e], n = t[e];
|
|
2600
|
+
if (!s)
|
|
2601
|
+
throw new Error(`Field ${e} not found`);
|
|
2602
|
+
if (s.type === "many2one")
|
|
2603
|
+
return n ? { value: n[0], label: n[1] } : { value: !1, label: void 0 };
|
|
2604
|
+
if (s.type === "selection") {
|
|
2605
|
+
const l = s.selection.find((o) => o[0] === n);
|
|
2606
|
+
return l ? { value: n, label: l[1] } : { value: !1, label: void 0 };
|
|
2818
2607
|
}
|
|
2819
|
-
return { value:
|
|
2608
|
+
return { value: n, label: n };
|
|
2820
2609
|
}
|
|
2821
|
-
const
|
|
2610
|
+
const At = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2822
2611
|
__proto__: null,
|
|
2823
|
-
getFieldsToRetrieve:
|
|
2824
|
-
getValueAndLabelForField:
|
|
2612
|
+
getFieldsToRetrieve: bt,
|
|
2613
|
+
getValueAndLabelForField: q
|
|
2825
2614
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
2826
|
-
function
|
|
2827
|
-
values:
|
|
2828
|
-
timerange:
|
|
2829
|
-
interval:
|
|
2615
|
+
function yt({
|
|
2616
|
+
values: i,
|
|
2617
|
+
timerange: t,
|
|
2618
|
+
interval: e = 1
|
|
2830
2619
|
}) {
|
|
2831
|
-
const
|
|
2832
|
-
values: s,
|
|
2833
|
-
timerange: e
|
|
2834
|
-
});
|
|
2835
|
-
return xe({
|
|
2620
|
+
const s = wt({
|
|
2836
2621
|
values: i,
|
|
2837
|
-
timerange:
|
|
2838
|
-
|
|
2622
|
+
timerange: t
|
|
2623
|
+
});
|
|
2624
|
+
return xt({
|
|
2625
|
+
values: s,
|
|
2626
|
+
timerange: t,
|
|
2627
|
+
interval: e
|
|
2839
2628
|
});
|
|
2840
2629
|
}
|
|
2841
|
-
function
|
|
2842
|
-
values:
|
|
2843
|
-
timerange:
|
|
2844
|
-
interval:
|
|
2630
|
+
function xt({
|
|
2631
|
+
values: i,
|
|
2632
|
+
timerange: t,
|
|
2633
|
+
interval: e = 1
|
|
2845
2634
|
}) {
|
|
2846
|
-
let
|
|
2847
|
-
const
|
|
2848
|
-
values:
|
|
2635
|
+
let s = [];
|
|
2636
|
+
const n = ue({
|
|
2637
|
+
values: i,
|
|
2849
2638
|
groupBy: "type-stacked"
|
|
2850
|
-
}), a = `${
|
|
2851
|
-
return Object.keys(
|
|
2852
|
-
const
|
|
2853
|
-
for (let _ = 0; _ <
|
|
2854
|
-
const u =
|
|
2855
|
-
if (
|
|
2639
|
+
}), a = `${t}s`;
|
|
2640
|
+
return Object.keys(n).forEach((o) => {
|
|
2641
|
+
const h = n[o];
|
|
2642
|
+
for (let _ = 0; _ < h.length; _++) {
|
|
2643
|
+
const u = h[_];
|
|
2644
|
+
if (s.push(u), _ === h.length - 1)
|
|
2856
2645
|
return;
|
|
2857
|
-
const
|
|
2858
|
-
if (!
|
|
2859
|
-
const
|
|
2860
|
-
dates: [
|
|
2861
|
-
timerange:
|
|
2862
|
-
interval:
|
|
2646
|
+
const d = u.x, g = h[_ + 1].x;
|
|
2647
|
+
if (!de([d, g], a)) {
|
|
2648
|
+
const c = pt({
|
|
2649
|
+
dates: [d, g],
|
|
2650
|
+
timerange: t,
|
|
2651
|
+
interval: e
|
|
2863
2652
|
});
|
|
2864
|
-
|
|
2865
|
-
|
|
2653
|
+
s = s.concat(
|
|
2654
|
+
c.map((b) => ({
|
|
2866
2655
|
x: b,
|
|
2867
2656
|
value: 0,
|
|
2868
2657
|
type: u.type,
|
|
@@ -2871,122 +2660,122 @@ function xe({
|
|
|
2871
2660
|
);
|
|
2872
2661
|
}
|
|
2873
2662
|
}
|
|
2874
|
-
}),
|
|
2663
|
+
}), s.sort((o, h) => o.x < h.x ? -1 : o.x > h.x ? 1 : 0);
|
|
2875
2664
|
}
|
|
2876
|
-
function
|
|
2877
|
-
dates:
|
|
2878
|
-
timerange:
|
|
2879
|
-
interval:
|
|
2665
|
+
function pt({
|
|
2666
|
+
dates: i,
|
|
2667
|
+
timerange: t,
|
|
2668
|
+
interval: e = 1
|
|
2880
2669
|
}) {
|
|
2881
|
-
const
|
|
2882
|
-
if (
|
|
2883
|
-
return
|
|
2884
|
-
const a =
|
|
2885
|
-
for (let
|
|
2886
|
-
const
|
|
2887
|
-
if (!
|
|
2888
|
-
const _ =
|
|
2889
|
-
|
|
2890
|
-
|
|
2891
|
-
), u =
|
|
2670
|
+
const s = [], n = `${t}s`;
|
|
2671
|
+
if (i.length === 1)
|
|
2672
|
+
return i;
|
|
2673
|
+
const a = i.sort((l, o) => l < o ? -1 : l > o ? 1 : 0);
|
|
2674
|
+
for (let l = 0; l < a.length - 1; l++) {
|
|
2675
|
+
const o = a[l], h = a[l + 1];
|
|
2676
|
+
if (!de([o, h], n)) {
|
|
2677
|
+
const _ = W(o, E(n)).add(
|
|
2678
|
+
e,
|
|
2679
|
+
n
|
|
2680
|
+
), u = W(h, E(n));
|
|
2892
2681
|
for (; _.isBefore(u); )
|
|
2893
|
-
|
|
2682
|
+
s.push(_.format(E(n))), _.add(e, n);
|
|
2894
2683
|
}
|
|
2895
2684
|
}
|
|
2896
|
-
return
|
|
2685
|
+
return s;
|
|
2897
2686
|
}
|
|
2898
|
-
function
|
|
2899
|
-
values:
|
|
2900
|
-
timerange:
|
|
2687
|
+
function wt({
|
|
2688
|
+
values: i,
|
|
2689
|
+
timerange: t
|
|
2901
2690
|
}) {
|
|
2902
|
-
const
|
|
2903
|
-
values:
|
|
2904
|
-
timerange:
|
|
2905
|
-
}),
|
|
2906
|
-
values:
|
|
2691
|
+
const e = vt({
|
|
2692
|
+
values: i,
|
|
2693
|
+
timerange: t
|
|
2694
|
+
}), s = [], n = ue({
|
|
2695
|
+
values: e,
|
|
2907
2696
|
groupBy: "all"
|
|
2908
2697
|
});
|
|
2909
|
-
return Object.keys(
|
|
2910
|
-
const
|
|
2911
|
-
values:
|
|
2912
|
-
operator:
|
|
2698
|
+
return Object.keys(n).forEach((a) => {
|
|
2699
|
+
const l = n[a], o = l[0].operator === "count" ? "+" : l[0].operator, h = Y({
|
|
2700
|
+
values: l.map((_) => _.value),
|
|
2701
|
+
operator: o
|
|
2913
2702
|
});
|
|
2914
|
-
|
|
2915
|
-
...
|
|
2916
|
-
value:
|
|
2703
|
+
s.push({
|
|
2704
|
+
...l[0],
|
|
2705
|
+
value: h
|
|
2917
2706
|
});
|
|
2918
|
-
}),
|
|
2707
|
+
}), s;
|
|
2919
2708
|
}
|
|
2920
|
-
function
|
|
2921
|
-
values:
|
|
2922
|
-
timerange:
|
|
2709
|
+
function vt({
|
|
2710
|
+
values: i,
|
|
2711
|
+
timerange: t
|
|
2923
2712
|
}) {
|
|
2924
|
-
return
|
|
2925
|
-
...
|
|
2926
|
-
x:
|
|
2927
|
-
date:
|
|
2928
|
-
timerange:
|
|
2713
|
+
return i.map((e) => ({
|
|
2714
|
+
...e,
|
|
2715
|
+
x: Ft({
|
|
2716
|
+
date: e.x,
|
|
2717
|
+
timerange: t
|
|
2929
2718
|
})
|
|
2930
2719
|
}));
|
|
2931
2720
|
}
|
|
2932
|
-
function
|
|
2933
|
-
date:
|
|
2934
|
-
timerange:
|
|
2721
|
+
function Ft({
|
|
2722
|
+
date: i,
|
|
2723
|
+
timerange: t
|
|
2935
2724
|
}) {
|
|
2936
|
-
let
|
|
2937
|
-
const
|
|
2938
|
-
switch (
|
|
2725
|
+
let e = Ct(i);
|
|
2726
|
+
const s = W(i, e);
|
|
2727
|
+
switch (t) {
|
|
2939
2728
|
case "hour": {
|
|
2940
|
-
|
|
2729
|
+
e = "YYYY-MM-DD HH:00";
|
|
2941
2730
|
break;
|
|
2942
2731
|
}
|
|
2943
2732
|
case "day": {
|
|
2944
|
-
|
|
2733
|
+
e = "YYYY-MM-DD";
|
|
2945
2734
|
break;
|
|
2946
2735
|
}
|
|
2947
2736
|
case "week": {
|
|
2948
|
-
|
|
2737
|
+
e = "YYYY-WW";
|
|
2949
2738
|
break;
|
|
2950
2739
|
}
|
|
2951
2740
|
case "month": {
|
|
2952
|
-
|
|
2741
|
+
e = "YYYY-MM";
|
|
2953
2742
|
break;
|
|
2954
2743
|
}
|
|
2955
2744
|
case "year": {
|
|
2956
|
-
|
|
2745
|
+
e = "YYYY";
|
|
2957
2746
|
break;
|
|
2958
2747
|
}
|
|
2959
2748
|
}
|
|
2960
|
-
return
|
|
2749
|
+
return s.format(e);
|
|
2961
2750
|
}
|
|
2962
|
-
function
|
|
2963
|
-
return
|
|
2751
|
+
function Ct(i) {
|
|
2752
|
+
return i.indexOf(":") ? "YYYY-MM-DD HH:mm:ss" : "YYYY-MM-DD";
|
|
2964
2753
|
}
|
|
2965
|
-
function
|
|
2966
|
-
let
|
|
2967
|
-
const
|
|
2968
|
-
if (
|
|
2754
|
+
function de(i, t) {
|
|
2755
|
+
let e = !1;
|
|
2756
|
+
const s = E(t);
|
|
2757
|
+
if (i.length === 0)
|
|
2969
2758
|
return !1;
|
|
2970
|
-
if (
|
|
2759
|
+
if (i.length === 1)
|
|
2971
2760
|
return !0;
|
|
2972
|
-
for (let
|
|
2973
|
-
const a =
|
|
2974
|
-
Math.abs(
|
|
2761
|
+
for (let n = 0; n < i.length - 1; n++) {
|
|
2762
|
+
const a = W(i[n], s), o = W(i[n + 1], s).diff(a, t);
|
|
2763
|
+
Math.abs(o) === 1 ? e = !0 : e = !1;
|
|
2975
2764
|
}
|
|
2976
|
-
return
|
|
2765
|
+
return e;
|
|
2977
2766
|
}
|
|
2978
|
-
function
|
|
2979
|
-
values:
|
|
2980
|
-
groupBy:
|
|
2767
|
+
function ue({
|
|
2768
|
+
values: i,
|
|
2769
|
+
groupBy: t
|
|
2981
2770
|
}) {
|
|
2982
|
-
const
|
|
2983
|
-
return
|
|
2984
|
-
const
|
|
2985
|
-
|
|
2986
|
-
}),
|
|
2771
|
+
const e = {};
|
|
2772
|
+
return i.forEach((s) => {
|
|
2773
|
+
const n = s.x, a = s.type, l = s.stacked, o = t === "all" ? `${n}-${a}-${l}` : `${a}-${l}`;
|
|
2774
|
+
e[o] || (e[o] = []), e[o].push(s);
|
|
2775
|
+
}), e;
|
|
2987
2776
|
}
|
|
2988
|
-
function
|
|
2989
|
-
switch (
|
|
2777
|
+
function E(i) {
|
|
2778
|
+
switch (i) {
|
|
2990
2779
|
case "days":
|
|
2991
2780
|
return "YYYY-MM-DD";
|
|
2992
2781
|
case "weeks":
|
|
@@ -3000,7 +2789,7 @@ function D(s) {
|
|
|
3000
2789
|
return "YYYY-MM-DD HH:mm";
|
|
3001
2790
|
}
|
|
3002
2791
|
}
|
|
3003
|
-
const
|
|
2792
|
+
const kt = {
|
|
3004
2793
|
count: "count",
|
|
3005
2794
|
"+": "sum",
|
|
3006
2795
|
"-": "subtract",
|
|
@@ -3008,262 +2797,260 @@ const ke = {
|
|
|
3008
2797
|
avg: "average",
|
|
3009
2798
|
min: "min",
|
|
3010
2799
|
max: "max"
|
|
3011
|
-
},
|
|
3012
|
-
ooui:
|
|
3013
|
-
values:
|
|
3014
|
-
fields:
|
|
3015
|
-
options:
|
|
2800
|
+
}, Pt = ({
|
|
2801
|
+
ooui: i,
|
|
2802
|
+
values: t,
|
|
2803
|
+
fields: e,
|
|
2804
|
+
options: s
|
|
3016
2805
|
}) => {
|
|
3017
|
-
const
|
|
3018
|
-
fieldName:
|
|
3019
|
-
values:
|
|
3020
|
-
fields:
|
|
2806
|
+
const n = R({
|
|
2807
|
+
fieldName: i.x.name,
|
|
2808
|
+
values: t,
|
|
2809
|
+
fields: e
|
|
3021
2810
|
}), a = [];
|
|
3022
|
-
|
|
3023
|
-
Object.keys(
|
|
3024
|
-
const x =
|
|
3025
|
-
if (
|
|
3026
|
-
const
|
|
3027
|
-
fieldName:
|
|
2811
|
+
i.y.forEach((c) => {
|
|
2812
|
+
Object.keys(n).forEach((b) => {
|
|
2813
|
+
const x = n[b].label, y = n[b].entries;
|
|
2814
|
+
if (c.label) {
|
|
2815
|
+
const F = R({
|
|
2816
|
+
fieldName: c.label,
|
|
3028
2817
|
values: y,
|
|
3029
|
-
fields:
|
|
2818
|
+
fields: e
|
|
3030
2819
|
});
|
|
3031
|
-
Object.keys(
|
|
3032
|
-
const
|
|
3033
|
-
entries:
|
|
3034
|
-
fields:
|
|
3035
|
-
fieldName:
|
|
3036
|
-
}),
|
|
3037
|
-
values:
|
|
3038
|
-
operator:
|
|
2820
|
+
Object.keys(F).forEach((C) => {
|
|
2821
|
+
const p = F[C].entries, I = F[C].label, ge = B({
|
|
2822
|
+
entries: p,
|
|
2823
|
+
fields: e,
|
|
2824
|
+
fieldName: c.name
|
|
2825
|
+
}), me = Y({
|
|
2826
|
+
values: ge,
|
|
2827
|
+
operator: c.operator
|
|
3039
2828
|
});
|
|
3040
2829
|
a.push({
|
|
3041
2830
|
x: x || !1,
|
|
3042
|
-
value:
|
|
3043
|
-
type:
|
|
3044
|
-
operator:
|
|
3045
|
-
stacked:
|
|
2831
|
+
value: me,
|
|
2832
|
+
type: I,
|
|
2833
|
+
operator: c.operator,
|
|
2834
|
+
stacked: c.stacked
|
|
3046
2835
|
});
|
|
3047
2836
|
});
|
|
3048
2837
|
} else {
|
|
3049
|
-
const
|
|
2838
|
+
const F = B({
|
|
3050
2839
|
entries: y,
|
|
3051
|
-
fields:
|
|
3052
|
-
fieldName:
|
|
3053
|
-
}), C =
|
|
3054
|
-
values:
|
|
3055
|
-
operator:
|
|
2840
|
+
fields: e,
|
|
2841
|
+
fieldName: c.name
|
|
2842
|
+
}), C = Y({
|
|
2843
|
+
values: F,
|
|
2844
|
+
operator: c.operator
|
|
3056
2845
|
});
|
|
3057
2846
|
a.push({
|
|
3058
2847
|
x: x || !1,
|
|
3059
2848
|
value: C,
|
|
3060
|
-
type:
|
|
3061
|
-
yAxis:
|
|
3062
|
-
fields:
|
|
2849
|
+
type: _e({
|
|
2850
|
+
yAxis: c,
|
|
2851
|
+
fields: e
|
|
3063
2852
|
}),
|
|
3064
|
-
operator:
|
|
3065
|
-
stacked:
|
|
2853
|
+
operator: c.operator,
|
|
2854
|
+
stacked: c.stacked
|
|
3066
2855
|
});
|
|
3067
2856
|
}
|
|
3068
2857
|
});
|
|
3069
2858
|
});
|
|
3070
|
-
const
|
|
3071
|
-
let _ = [...a.sort((
|
|
3072
|
-
|
|
2859
|
+
const l = i.y.some((c) => c.label !== void 0), o = i.y.some((c) => c.stacked !== void 0);
|
|
2860
|
+
let _ = [...a.sort((c, b) => c.x < b.x ? -1 : c.x > b.x ? 1 : 0)];
|
|
2861
|
+
o && i.y.filter((c) => c.stacked !== void 0).length > 1 && (_ = _.map((c) => ({ ...c, type: `${c.type} - ${c.stacked}` })));
|
|
3073
2862
|
let u = [..._];
|
|
3074
|
-
|
|
3075
|
-
(
|
|
2863
|
+
i.type === "pie" && u.some((c) => c.x === !1) ? u = u.map((c) => c.x === !1 ? { ...c, x: (s == null ? void 0 : s.uninformedString) || "Not informed" } : c) : _.some((c) => c.x === !1) && (u = u.filter(
|
|
2864
|
+
(c) => c.x !== !1
|
|
3076
2865
|
));
|
|
3077
|
-
let
|
|
3078
|
-
|
|
3079
|
-
values:
|
|
3080
|
-
timerange:
|
|
3081
|
-
interval:
|
|
3082
|
-
}) :
|
|
3083
|
-
const
|
|
3084
|
-
data:
|
|
3085
|
-
isGroup:
|
|
3086
|
-
isStack:
|
|
2866
|
+
let d = u;
|
|
2867
|
+
i.timerange ? d = yt({
|
|
2868
|
+
values: d,
|
|
2869
|
+
timerange: i.timerange,
|
|
2870
|
+
interval: i.interval
|
|
2871
|
+
}) : i.type == "pie" && (d = u.sort((c, b) => b.value - c.value));
|
|
2872
|
+
const g = {
|
|
2873
|
+
data: d,
|
|
2874
|
+
isGroup: o || l,
|
|
2875
|
+
isStack: o
|
|
3087
2876
|
};
|
|
3088
|
-
if (
|
|
3089
|
-
mode:
|
|
3090
|
-
},
|
|
3091
|
-
const { min:
|
|
3092
|
-
|
|
2877
|
+
if (i.type === "line" && i.y_range && (g.yAxisOpts = {
|
|
2878
|
+
mode: i.y_range
|
|
2879
|
+
}, i.y_range === "auto")) {
|
|
2880
|
+
const { min: c, max: b } = fe(d);
|
|
2881
|
+
g.yAxisOpts.valueOpts = { min: c, max: b };
|
|
3093
2882
|
}
|
|
3094
|
-
return
|
|
2883
|
+
return g;
|
|
3095
2884
|
};
|
|
3096
|
-
function
|
|
3097
|
-
entries:
|
|
3098
|
-
fieldName:
|
|
3099
|
-
fields:
|
|
2885
|
+
function B({
|
|
2886
|
+
entries: i,
|
|
2887
|
+
fieldName: t,
|
|
2888
|
+
fields: e
|
|
3100
2889
|
}) {
|
|
3101
|
-
return
|
|
3102
|
-
fieldName:
|
|
3103
|
-
values:
|
|
3104
|
-
fields:
|
|
3105
|
-
})).map(({ value:
|
|
2890
|
+
return i.map((s) => q({
|
|
2891
|
+
fieldName: t,
|
|
2892
|
+
values: s,
|
|
2893
|
+
fields: e
|
|
2894
|
+
})).map(({ value: s, label: n }) => n);
|
|
3106
2895
|
}
|
|
3107
|
-
function
|
|
3108
|
-
operator:
|
|
3109
|
-
values:
|
|
2896
|
+
function Y({
|
|
2897
|
+
operator: i,
|
|
2898
|
+
values: t
|
|
3110
2899
|
}) {
|
|
3111
|
-
switch (
|
|
2900
|
+
switch (i) {
|
|
3112
2901
|
case "count":
|
|
3113
|
-
return
|
|
2902
|
+
return t.length;
|
|
3114
2903
|
case "+":
|
|
3115
|
-
return
|
|
3116
|
-
|
|
3117
|
-
return
|
|
2904
|
+
return S(
|
|
2905
|
+
t.reduce(function(e, s) {
|
|
2906
|
+
return e + s;
|
|
3118
2907
|
})
|
|
3119
2908
|
);
|
|
3120
2909
|
case "-":
|
|
3121
|
-
return
|
|
3122
|
-
|
|
3123
|
-
return
|
|
2910
|
+
return S(
|
|
2911
|
+
t.reduce(function(e, s) {
|
|
2912
|
+
return e - s;
|
|
3124
2913
|
})
|
|
3125
2914
|
);
|
|
3126
2915
|
case "*":
|
|
3127
|
-
return
|
|
3128
|
-
|
|
3129
|
-
return
|
|
2916
|
+
return S(
|
|
2917
|
+
t.reduce(function(e, s) {
|
|
2918
|
+
return e * s;
|
|
3130
2919
|
})
|
|
3131
2920
|
);
|
|
3132
2921
|
case "avg": {
|
|
3133
|
-
const
|
|
3134
|
-
return
|
|
2922
|
+
const s = t.reduce((n, a) => n + a, 0) / t.length || 0;
|
|
2923
|
+
return S(s);
|
|
3135
2924
|
}
|
|
3136
2925
|
case "min":
|
|
3137
|
-
return Math.min(...
|
|
2926
|
+
return Math.min(...t);
|
|
3138
2927
|
case "max":
|
|
3139
|
-
return Math.max(...
|
|
2928
|
+
return Math.max(...t);
|
|
3140
2929
|
}
|
|
3141
2930
|
}
|
|
3142
|
-
function
|
|
3143
|
-
return Math.round((
|
|
2931
|
+
function S(i) {
|
|
2932
|
+
return Math.round((i + Number.EPSILON) * 100) / 100;
|
|
3144
2933
|
}
|
|
3145
|
-
function
|
|
3146
|
-
fieldName:
|
|
3147
|
-
fields:
|
|
3148
|
-
values:
|
|
2934
|
+
function R({
|
|
2935
|
+
fieldName: i,
|
|
2936
|
+
fields: t,
|
|
2937
|
+
values: e
|
|
3149
2938
|
}) {
|
|
3150
|
-
const
|
|
3151
|
-
return
|
|
3152
|
-
const { value: a, label:
|
|
3153
|
-
fields:
|
|
3154
|
-
values:
|
|
3155
|
-
fieldName:
|
|
2939
|
+
const s = {};
|
|
2940
|
+
return e.forEach((n) => {
|
|
2941
|
+
const { value: a, label: l } = q({
|
|
2942
|
+
fields: t,
|
|
2943
|
+
values: n,
|
|
2944
|
+
fieldName: i
|
|
3156
2945
|
});
|
|
3157
|
-
|
|
3158
|
-
}),
|
|
3159
|
-
}
|
|
3160
|
-
function
|
|
3161
|
-
let
|
|
3162
|
-
return Object.keys(
|
|
3163
|
-
const
|
|
3164
|
-
|
|
3165
|
-
}),
|
|
2946
|
+
s[a] || (s[a] = { label: l, entries: [] }), s[a].entries.push(n);
|
|
2947
|
+
}), s;
|
|
2948
|
+
}
|
|
2949
|
+
function Ot(i) {
|
|
2950
|
+
let t = [];
|
|
2951
|
+
return Object.keys(i).forEach((e) => {
|
|
2952
|
+
const s = i[e];
|
|
2953
|
+
t = t.concat(s.entries);
|
|
2954
|
+
}), t;
|
|
3166
2955
|
}
|
|
3167
|
-
function
|
|
3168
|
-
yAxis:
|
|
3169
|
-
fields:
|
|
2956
|
+
function _e({
|
|
2957
|
+
yAxis: i,
|
|
2958
|
+
fields: t
|
|
3170
2959
|
}) {
|
|
3171
|
-
const
|
|
3172
|
-
return
|
|
2960
|
+
const e = t[i.name];
|
|
2961
|
+
return e != null && e.string ? e.string : i.name;
|
|
3173
2962
|
}
|
|
3174
|
-
function
|
|
3175
|
-
if (
|
|
2963
|
+
function fe(i, t = 0.1) {
|
|
2964
|
+
if (i.length === 0)
|
|
3176
2965
|
throw new Error("The values array cannot be empty.");
|
|
3177
|
-
const
|
|
2966
|
+
const e = i.map((l) => l.value), s = Math.min(...e), n = Math.max(...e), a = (n - s) * t;
|
|
3178
2967
|
return {
|
|
3179
|
-
min:
|
|
3180
|
-
max:
|
|
2968
|
+
min: s - a,
|
|
2969
|
+
max: n + a
|
|
3181
2970
|
};
|
|
3182
2971
|
}
|
|
3183
|
-
const
|
|
2972
|
+
const Bt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
3184
2973
|
__proto__: null,
|
|
3185
|
-
getAllObjectsInGroupedValues:
|
|
3186
|
-
getMinMax:
|
|
3187
|
-
getValueForOperator:
|
|
3188
|
-
getValuesForYField:
|
|
3189
|
-
getValuesGroupedByField:
|
|
3190
|
-
getYAxisFieldname:
|
|
3191
|
-
labelsForOperator:
|
|
3192
|
-
processGraphData:
|
|
2974
|
+
getAllObjectsInGroupedValues: Ot,
|
|
2975
|
+
getMinMax: fe,
|
|
2976
|
+
getValueForOperator: Y,
|
|
2977
|
+
getValuesForYField: B,
|
|
2978
|
+
getValuesGroupedByField: R,
|
|
2979
|
+
getYAxisFieldname: _e,
|
|
2980
|
+
labelsForOperator: kt,
|
|
2981
|
+
processGraphData: Pt
|
|
3193
2982
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
3194
2983
|
export {
|
|
3195
|
-
|
|
3196
|
-
|
|
3197
|
-
|
|
3198
|
-
|
|
3199
|
-
|
|
3200
|
-
|
|
3201
|
-
|
|
3202
|
-
|
|
3203
|
-
|
|
3204
|
-
|
|
3205
|
-
|
|
3206
|
-
|
|
3207
|
-
|
|
3208
|
-
|
|
3209
|
-
|
|
3210
|
-
|
|
3211
|
-
|
|
3212
|
-
|
|
3213
|
-
|
|
3214
|
-
|
|
2984
|
+
We as ActionButtons,
|
|
2985
|
+
Ke as Alert,
|
|
2986
|
+
ke as Avatar,
|
|
2987
|
+
Ae as Binary,
|
|
2988
|
+
te as Boolean,
|
|
2989
|
+
ee as Button,
|
|
2990
|
+
Te as ButtonGroup,
|
|
2991
|
+
rt as Card,
|
|
2992
|
+
tt as Carousel,
|
|
2993
|
+
A as Char,
|
|
2994
|
+
re as CodeEditor,
|
|
2995
|
+
it as ColorPicker,
|
|
2996
|
+
Ze as Comments,
|
|
2997
|
+
V as Container,
|
|
2998
|
+
v as ContainerWidget,
|
|
2999
|
+
Mt as Dashboard,
|
|
3000
|
+
dt as DashboardItem,
|
|
3001
|
+
De as Date,
|
|
3002
|
+
je as DateTime,
|
|
3003
|
+
et as Email,
|
|
3215
3004
|
f as Field,
|
|
3216
|
-
|
|
3217
|
-
|
|
3218
|
-
|
|
3219
|
-
|
|
3220
|
-
|
|
3005
|
+
G as Float,
|
|
3006
|
+
Ee as FloatTime,
|
|
3007
|
+
Et as Form,
|
|
3008
|
+
oe as Graph,
|
|
3009
|
+
he as GraphAxis,
|
|
3221
3010
|
M as GraphChart,
|
|
3222
|
-
|
|
3223
|
-
|
|
3224
|
-
|
|
3225
|
-
|
|
3226
|
-
|
|
3227
|
-
|
|
3228
|
-
|
|
3229
|
-
|
|
3230
|
-
|
|
3231
|
-
|
|
3232
|
-
|
|
3233
|
-
|
|
3234
|
-
|
|
3235
|
-
|
|
3236
|
-
|
|
3237
|
-
|
|
3238
|
-
|
|
3239
|
-
|
|
3240
|
-
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
|
|
3245
|
-
|
|
3246
|
-
|
|
3247
|
-
|
|
3248
|
-
|
|
3249
|
-
|
|
3250
|
-
|
|
3251
|
-
|
|
3252
|
-
|
|
3253
|
-
|
|
3254
|
-
|
|
3255
|
-
|
|
3256
|
-
|
|
3257
|
-
|
|
3258
|
-
qt as Timeline,
|
|
3259
|
-
Ve as Tree,
|
|
3011
|
+
ce as GraphIndicator,
|
|
3012
|
+
ut as GraphIndicatorField,
|
|
3013
|
+
mt as GraphXAxis,
|
|
3014
|
+
gt as GraphYAxis,
|
|
3015
|
+
Oe as Group,
|
|
3016
|
+
Ve as HTMLPreview,
|
|
3017
|
+
Re as Icon,
|
|
3018
|
+
Be as Image,
|
|
3019
|
+
$e as Indicator,
|
|
3020
|
+
Se as Integer,
|
|
3021
|
+
H as JSONField,
|
|
3022
|
+
Z as Label,
|
|
3023
|
+
ze as Many2one,
|
|
3024
|
+
Ie as Markdown,
|
|
3025
|
+
se as MultiCheckbox,
|
|
3026
|
+
K as NewLine,
|
|
3027
|
+
N as Notebook,
|
|
3028
|
+
ie as One2many,
|
|
3029
|
+
Pe as Page,
|
|
3030
|
+
Ye as ProgressBar,
|
|
3031
|
+
st as QRCode,
|
|
3032
|
+
He as Radio,
|
|
3033
|
+
Ne as Reference,
|
|
3034
|
+
ht as SearchFieldTypes,
|
|
3035
|
+
Yt as SearchFilter,
|
|
3036
|
+
z as Selection,
|
|
3037
|
+
Me as Separator,
|
|
3038
|
+
j as Spinner,
|
|
3039
|
+
Xe as Steps,
|
|
3040
|
+
Qe as Switch,
|
|
3041
|
+
Je as Tag,
|
|
3042
|
+
qe as Tags,
|
|
3043
|
+
L as Text,
|
|
3044
|
+
Ue as Time,
|
|
3045
|
+
Ge as Timeline,
|
|
3046
|
+
Vt as Tree,
|
|
3260
3047
|
k as Widget,
|
|
3261
|
-
|
|
3262
|
-
|
|
3263
|
-
|
|
3264
|
-
|
|
3265
|
-
|
|
3266
|
-
|
|
3267
|
-
|
|
3048
|
+
At as graphFieldUtils,
|
|
3049
|
+
Bt as graphProcessor,
|
|
3050
|
+
ne as parseContext,
|
|
3051
|
+
St as parseContextFields,
|
|
3052
|
+
jt as parseDomainFields,
|
|
3053
|
+
Nt as parseGraph,
|
|
3054
|
+
Dt as transformDomainForChildWidget
|
|
3268
3055
|
};
|
|
3269
3056
|
//# sourceMappingURL=ooui.es.js.map
|