@gisce/react-ooui 1.2.0-rc.21 → 1.2.0-rc.23
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/dist/context/ContentRootContext.d.ts.map +1 -1
- package/dist/helpers/formHelper.d.ts +2 -1
- package/dist/helpers/formHelper.d.ts.map +1 -1
- package/dist/react-ooui.es.js +1167 -1143
- package/dist/react-ooui.es.js.map +1 -1
- package/dist/react-ooui.umd.js +10 -10
- package/dist/react-ooui.umd.js.map +1 -1
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/views/RootView.d.ts.map +1 -1
- package/dist/widgets/base/many2one/Many2one.d.ts.map +1 -1
- package/dist/widgets/base/one2many/One2manyInput.d.ts.map +1 -1
- package/dist/widgets/custom/MultiCheckbox.d.ts.map +1 -1
- package/dist/widgets/custom/Tags.d.ts.map +1 -1
- package/dist/widgets/views/Form.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/context/ContentRootContext.tsx +1 -0
- package/src/helpers/formHelper.ts +21 -2
- package/src/types/index.ts +1 -0
- package/src/views/RootView.tsx +5 -3
- package/src/widgets/base/many2one/Many2one.tsx +7 -8
- package/src/widgets/base/one2many/One2manyInput.tsx +1 -0
- package/src/widgets/custom/MultiCheckbox.tsx +1 -0
- package/src/widgets/custom/Tags.tsx +27 -28
- package/src/widgets/views/Form.tsx +13 -15
package/dist/react-ooui.es.js
CHANGED
|
@@ -4757,8 +4757,8 @@ function requireReactIs_development() {
|
|
|
4757
4757
|
}
|
|
4758
4758
|
function O(M) {
|
|
4759
4759
|
if (typeof M == "object" && M !== null) {
|
|
4760
|
-
var
|
|
4761
|
-
switch (
|
|
4760
|
+
var pe = M.$$typeof;
|
|
4761
|
+
switch (pe) {
|
|
4762
4762
|
case r:
|
|
4763
4763
|
var ge = M.type;
|
|
4764
4764
|
switch (ge) {
|
|
@@ -4779,11 +4779,11 @@ function requireReactIs_development() {
|
|
|
4779
4779
|
case c:
|
|
4780
4780
|
return Fe;
|
|
4781
4781
|
default:
|
|
4782
|
-
return
|
|
4782
|
+
return pe;
|
|
4783
4783
|
}
|
|
4784
4784
|
}
|
|
4785
4785
|
case o:
|
|
4786
|
-
return
|
|
4786
|
+
return pe;
|
|
4787
4787
|
}
|
|
4788
4788
|
}
|
|
4789
4789
|
}
|
|
@@ -4803,7 +4803,7 @@ function requireReactIs_development() {
|
|
|
4803
4803
|
function ie(M) {
|
|
4804
4804
|
return typeof M == "object" && M !== null && M.$$typeof === r;
|
|
4805
4805
|
}
|
|
4806
|
-
function
|
|
4806
|
+
function ce(M) {
|
|
4807
4807
|
return O(M) === p;
|
|
4808
4808
|
}
|
|
4809
4809
|
function me(M) {
|
|
@@ -4821,13 +4821,13 @@ function requireReactIs_development() {
|
|
|
4821
4821
|
function ve(M) {
|
|
4822
4822
|
return O(M) === l;
|
|
4823
4823
|
}
|
|
4824
|
-
function
|
|
4824
|
+
function Oe(M) {
|
|
4825
4825
|
return O(M) === s;
|
|
4826
4826
|
}
|
|
4827
4827
|
function D(M) {
|
|
4828
4828
|
return O(M) === h;
|
|
4829
4829
|
}
|
|
4830
|
-
reactIs_development.AsyncMode = S, reactIs_development.ConcurrentMode = T, reactIs_development.ContextConsumer = G, reactIs_development.ContextProvider = E, reactIs_development.Element = P, reactIs_development.ForwardRef = B, reactIs_development.Fragment = N, reactIs_development.Lazy = L, reactIs_development.Memo = W, reactIs_development.Portal = K, reactIs_development.Profiler = H, reactIs_development.StrictMode = z, reactIs_development.Suspense = U, reactIs_development.isAsyncMode = ae, reactIs_development.isConcurrentMode = ne, reactIs_development.isContextConsumer = J, reactIs_development.isContextProvider = oe, reactIs_development.isElement = ie, reactIs_development.isForwardRef =
|
|
4830
|
+
reactIs_development.AsyncMode = S, reactIs_development.ConcurrentMode = T, reactIs_development.ContextConsumer = G, reactIs_development.ContextProvider = E, reactIs_development.Element = P, reactIs_development.ForwardRef = B, reactIs_development.Fragment = N, reactIs_development.Lazy = L, reactIs_development.Memo = W, reactIs_development.Portal = K, reactIs_development.Profiler = H, reactIs_development.StrictMode = z, reactIs_development.Suspense = U, reactIs_development.isAsyncMode = ae, reactIs_development.isConcurrentMode = ne, reactIs_development.isContextConsumer = J, reactIs_development.isContextProvider = oe, reactIs_development.isElement = ie, reactIs_development.isForwardRef = ce, reactIs_development.isFragment = me, reactIs_development.isLazy = Q, reactIs_development.isMemo = te, reactIs_development.isPortal = he, reactIs_development.isProfiler = ve, reactIs_development.isStrictMode = Oe, reactIs_development.isSuspense = D, reactIs_development.isValidElementType = x, reactIs_development.typeOf = O;
|
|
4831
4831
|
}()), reactIs_development;
|
|
4832
4832
|
}
|
|
4833
4833
|
(function(e) {
|
|
@@ -5421,8 +5421,8 @@ var _excluded$7 = ["prefixCls", "onPressEnter", "defaultValue", "value", "autoSi
|
|
|
5421
5421
|
if (L === RESIZE_START)
|
|
5422
5422
|
W(RESIZE_MEASURING);
|
|
5423
5423
|
else if (L === RESIZE_MEASURING) {
|
|
5424
|
-
var
|
|
5425
|
-
W(RESIZE_STABLE), U(
|
|
5424
|
+
var ce = calculateAutoSizeStyle(x.current, !1, T, G);
|
|
5425
|
+
W(RESIZE_STABLE), U(ce);
|
|
5426
5426
|
} else
|
|
5427
5427
|
P();
|
|
5428
5428
|
}, [L]);
|
|
@@ -7962,9 +7962,9 @@ var FormContext$1 = /* @__PURE__ */ React$n.createContext({
|
|
|
7962
7962
|
onValuesChange: v,
|
|
7963
7963
|
onFieldsChange: function(oe) {
|
|
7964
7964
|
if (x.triggerFormChange(a, oe), C) {
|
|
7965
|
-
for (var ie = arguments.length,
|
|
7966
|
-
|
|
7967
|
-
C.apply(void 0, [oe].concat(
|
|
7965
|
+
for (var ie = arguments.length, ce = new Array(ie > 1 ? ie - 1 : 0), me = 1; me < ie; me++)
|
|
7966
|
+
ce[me - 1] = arguments[me];
|
|
7967
|
+
C.apply(void 0, [oe].concat(ce));
|
|
7968
7968
|
}
|
|
7969
7969
|
},
|
|
7970
7970
|
onFinish: function(oe) {
|
|
@@ -10077,42 +10077,42 @@ function useStatus(e, r, o, a) {
|
|
|
10077
10077
|
function ie() {
|
|
10078
10078
|
return o();
|
|
10079
10079
|
}
|
|
10080
|
-
var
|
|
10080
|
+
var ce = useRef(!1);
|
|
10081
10081
|
function me(Re) {
|
|
10082
10082
|
var Ae = ie();
|
|
10083
10083
|
if (!(Re && !Re.deadline && Re.target !== Ae)) {
|
|
10084
|
-
var
|
|
10085
|
-
H === STATUS_APPEAR &&
|
|
10084
|
+
var et = ce.current, Ht;
|
|
10085
|
+
H === STATUS_APPEAR && et ? Ht = S == null ? void 0 : S(Ae, Re) : H === STATUS_ENTER && et ? Ht = T == null ? void 0 : T(Ae, Re) : H === STATUS_LEAVE && et && (Ht = G == null ? void 0 : G(Ae, Re)), H !== STATUS_NONE && et && Ht !== !1 && (z(STATUS_NONE, !0), ne(null, !0));
|
|
10086
10086
|
}
|
|
10087
10087
|
}
|
|
10088
10088
|
var Q = useDomMotionEvents(me), te = _slicedToArray(Q, 1), he = te[0], ve = React$n.useMemo(function() {
|
|
10089
|
-
var Re, Ae,
|
|
10089
|
+
var Re, Ae, et;
|
|
10090
10090
|
switch (H) {
|
|
10091
10091
|
case STATUS_APPEAR:
|
|
10092
10092
|
return Re = {}, _defineProperty$1(Re, STEP_PREPARE, m), _defineProperty$1(Re, STEP_START, C), _defineProperty$1(Re, STEP_ACTIVE, y), Re;
|
|
10093
10093
|
case STATUS_ENTER:
|
|
10094
10094
|
return Ae = {}, _defineProperty$1(Ae, STEP_PREPARE, g), _defineProperty$1(Ae, STEP_START, w), _defineProperty$1(Ae, STEP_ACTIVE, x), Ae;
|
|
10095
10095
|
case STATUS_LEAVE:
|
|
10096
|
-
return
|
|
10096
|
+
return et = {}, _defineProperty$1(et, STEP_PREPARE, v), _defineProperty$1(et, STEP_START, I), _defineProperty$1(et, STEP_ACTIVE, O), et;
|
|
10097
10097
|
default:
|
|
10098
10098
|
return {};
|
|
10099
10099
|
}
|
|
10100
|
-
}, [H]),
|
|
10100
|
+
}, [H]), Oe = useStepQueue(H, function(Re) {
|
|
10101
10101
|
if (Re === STEP_PREPARE) {
|
|
10102
10102
|
var Ae = ve[STEP_PREPARE];
|
|
10103
10103
|
return Ae ? Ae(ie()) : SkipStep;
|
|
10104
10104
|
}
|
|
10105
|
-
if (
|
|
10106
|
-
var
|
|
10107
|
-
ne(((
|
|
10105
|
+
if (pe in ve) {
|
|
10106
|
+
var et;
|
|
10107
|
+
ne(((et = ve[pe]) === null || et === void 0 ? void 0 : et.call(ve, ie(), null)) || null);
|
|
10108
10108
|
}
|
|
10109
|
-
return
|
|
10109
|
+
return pe === STEP_ACTIVE && (he(ie()), p > 0 && (clearTimeout(oe.current), oe.current = setTimeout(function() {
|
|
10110
10110
|
me({
|
|
10111
10111
|
deadline: !0
|
|
10112
10112
|
});
|
|
10113
10113
|
}, p))), DoStep;
|
|
10114
|
-
}), D = _slicedToArray(
|
|
10115
|
-
|
|
10114
|
+
}), D = _slicedToArray(Oe, 2), M = D[0], pe = D[1], ge = isActive(pe);
|
|
10115
|
+
ce.current = ge, useIsomorphicLayoutEffect(function() {
|
|
10116
10116
|
L(r);
|
|
10117
10117
|
var Re = J.current;
|
|
10118
10118
|
if (J.current = !0, !!e) {
|
|
@@ -10130,10 +10130,10 @@ function useStatus(e, r, o, a) {
|
|
|
10130
10130
|
useEffect(function() {
|
|
10131
10131
|
N && (Fe.current = !0), N !== void 0 && H === STATUS_NONE && ((Fe.current || N) && (E == null || E(N)), Fe.current = !0);
|
|
10132
10132
|
}, [N, H]);
|
|
10133
|
-
var
|
|
10134
|
-
return ve[STEP_PREPARE] &&
|
|
10133
|
+
var Te = ae;
|
|
10134
|
+
return ve[STEP_PREPARE] && pe === STEP_START && (Te = _objectSpread2$g({
|
|
10135
10135
|
transition: "none"
|
|
10136
|
-
},
|
|
10136
|
+
}, Te)), [H, pe, Te, N != null ? N : r];
|
|
10137
10137
|
}
|
|
10138
10138
|
var DomWrapper = /* @__PURE__ */ function(e) {
|
|
10139
10139
|
_inherits(o, e);
|
|
@@ -10927,11 +10927,11 @@ function requireMessage() {
|
|
|
10927
10927
|
J.top !== void 0 && (I = J.top, C = null), J.duration !== void 0 && (w = J.duration), J.prefixCls !== void 0 && (x = J.prefixCls), J.getContainer !== void 0 && (T = J.getContainer, C = null), J.transitionName !== void 0 && (O = J.transitionName, C = null, S = !0), J.maxCount !== void 0 && (G = J.maxCount, C = null), J.rtl !== void 0 && (E = J.rtl);
|
|
10928
10928
|
}
|
|
10929
10929
|
function N(J, oe) {
|
|
10930
|
-
var ie = J.prefixCls,
|
|
10930
|
+
var ie = J.prefixCls, ce = J.getPopupContainer, me = (0, g.globalConfig)(), Q = me.getPrefixCls, te = me.getRootPrefixCls, he = me.getIconPrefixCls, ve = Q("message", ie || x), Oe = te(J.rootPrefixCls, ve), D = he();
|
|
10931
10931
|
if (C) {
|
|
10932
10932
|
oe({
|
|
10933
10933
|
prefixCls: ve,
|
|
10934
|
-
rootPrefixCls:
|
|
10934
|
+
rootPrefixCls: Oe,
|
|
10935
10935
|
iconPrefixCls: D,
|
|
10936
10936
|
instance: C
|
|
10937
10937
|
});
|
|
@@ -10939,28 +10939,28 @@ function requireMessage() {
|
|
|
10939
10939
|
}
|
|
10940
10940
|
var M = {
|
|
10941
10941
|
prefixCls: ve,
|
|
10942
|
-
transitionName: S ? O : "".concat(
|
|
10942
|
+
transitionName: S ? O : "".concat(Oe, "-").concat(O),
|
|
10943
10943
|
style: {
|
|
10944
10944
|
top: I
|
|
10945
10945
|
},
|
|
10946
|
-
getContainer: T ||
|
|
10946
|
+
getContainer: T || ce,
|
|
10947
10947
|
maxCount: G
|
|
10948
10948
|
};
|
|
10949
|
-
h.default.newInstance(M, function(
|
|
10949
|
+
h.default.newInstance(M, function(pe) {
|
|
10950
10950
|
if (C) {
|
|
10951
10951
|
oe({
|
|
10952
10952
|
prefixCls: ve,
|
|
10953
|
-
rootPrefixCls:
|
|
10953
|
+
rootPrefixCls: Oe,
|
|
10954
10954
|
iconPrefixCls: D,
|
|
10955
10955
|
instance: C
|
|
10956
10956
|
});
|
|
10957
10957
|
return;
|
|
10958
10958
|
}
|
|
10959
|
-
C =
|
|
10959
|
+
C = pe, process.env.NODE_ENV === "test" && (C.config = M), oe({
|
|
10960
10960
|
prefixCls: ve,
|
|
10961
|
-
rootPrefixCls:
|
|
10961
|
+
rootPrefixCls: Oe,
|
|
10962
10962
|
iconPrefixCls: D,
|
|
10963
|
-
instance:
|
|
10963
|
+
instance: pe
|
|
10964
10964
|
});
|
|
10965
10965
|
});
|
|
10966
10966
|
}
|
|
@@ -10973,7 +10973,7 @@ function requireMessage() {
|
|
|
10973
10973
|
}, W = Object.keys(L);
|
|
10974
10974
|
e.typeList = W;
|
|
10975
10975
|
function K(J, oe, ie) {
|
|
10976
|
-
var
|
|
10976
|
+
var ce, me = J.duration !== void 0 ? J.duration : w, Q = L[J.type], te = (0, p.default)("".concat(oe, "-custom-content"), (ce = {}, (0, s.default)(ce, "".concat(oe, "-").concat(J.type), J.type), (0, s.default)(ce, "".concat(oe, "-rtl"), E === !0), ce));
|
|
10977
10977
|
return {
|
|
10978
10978
|
key: J.key,
|
|
10979
10979
|
duration: me,
|
|
@@ -10994,18 +10994,18 @@ function requireMessage() {
|
|
|
10994
10994
|
return typeof J.onClose == "function" && J.onClose(), me(!0);
|
|
10995
10995
|
};
|
|
10996
10996
|
N(J, function(te) {
|
|
10997
|
-
var he = te.prefixCls, ve = te.iconPrefixCls,
|
|
10998
|
-
|
|
10997
|
+
var he = te.prefixCls, ve = te.iconPrefixCls, Oe = te.instance;
|
|
10998
|
+
Oe.notice(K((0, a.default)((0, a.default)({}, J), {
|
|
10999
10999
|
key: oe,
|
|
11000
11000
|
onClose: Q
|
|
11001
11001
|
}), he, ve));
|
|
11002
11002
|
});
|
|
11003
|
-
}),
|
|
11003
|
+
}), ce = function() {
|
|
11004
11004
|
C && C.removeNotice(oe);
|
|
11005
11005
|
};
|
|
11006
|
-
return
|
|
11006
|
+
return ce.then = function(me, Q) {
|
|
11007
11007
|
return ie.then(me, Q);
|
|
11008
|
-
},
|
|
11008
|
+
}, ce.promise = ie, ce;
|
|
11009
11009
|
}
|
|
11010
11010
|
function z(J) {
|
|
11011
11011
|
return Object.prototype.toString.call(J) === "[object Object]" && !!J.content;
|
|
@@ -11016,8 +11016,8 @@ function requireMessage() {
|
|
|
11016
11016
|
destroy: function(oe) {
|
|
11017
11017
|
if (C)
|
|
11018
11018
|
if (oe) {
|
|
11019
|
-
var ie = C,
|
|
11020
|
-
|
|
11019
|
+
var ie = C, ce = ie.removeNotice;
|
|
11020
|
+
ce(oe);
|
|
11021
11021
|
} else {
|
|
11022
11022
|
var me = C, Q = me.destroy;
|
|
11023
11023
|
Q(), C = null;
|
|
@@ -11025,12 +11025,12 @@ function requireMessage() {
|
|
|
11025
11025
|
}
|
|
11026
11026
|
};
|
|
11027
11027
|
function re(J, oe) {
|
|
11028
|
-
J[oe] = function(ie,
|
|
11028
|
+
J[oe] = function(ie, ce, me) {
|
|
11029
11029
|
return z(ie) ? J.open((0, a.default)((0, a.default)({}, ie), {
|
|
11030
11030
|
type: oe
|
|
11031
|
-
})) : (typeof
|
|
11031
|
+
})) : (typeof ce == "function" && (me = ce, ce = void 0), J.open({
|
|
11032
11032
|
content: ie,
|
|
11033
|
-
duration:
|
|
11033
|
+
duration: ce,
|
|
11034
11034
|
type: oe,
|
|
11035
11035
|
onClose: me
|
|
11036
11036
|
}));
|
|
@@ -11117,13 +11117,13 @@ var notification = {}, regeneratorRuntime = { exports: {} };
|
|
|
11117
11117
|
function U(ae, ne, J, oe) {
|
|
11118
11118
|
var ie = g(H[ae], H, ne);
|
|
11119
11119
|
if (ie.type !== "throw") {
|
|
11120
|
-
var
|
|
11120
|
+
var ce = ie.arg, me = ce.value;
|
|
11121
11121
|
return me && r(me) == "object" && l.call(me, "__await") ? z.resolve(me.__await).then(function(Q) {
|
|
11122
11122
|
U("next", Q, J, oe);
|
|
11123
11123
|
}, function(Q) {
|
|
11124
11124
|
U("throw", Q, J, oe);
|
|
11125
11125
|
}) : z.resolve(me).then(function(Q) {
|
|
11126
|
-
|
|
11126
|
+
ce.value = Q, J(ce);
|
|
11127
11127
|
}, function(Q) {
|
|
11128
11128
|
return U("throw", Q, J, oe);
|
|
11129
11129
|
});
|
|
@@ -11134,8 +11134,8 @@ var notification = {}, regeneratorRuntime = { exports: {} };
|
|
|
11134
11134
|
c(this, "_invoke", {
|
|
11135
11135
|
value: function(ne, J) {
|
|
11136
11136
|
function oe() {
|
|
11137
|
-
return new z(function(ie,
|
|
11138
|
-
U(ne, J, ie,
|
|
11137
|
+
return new z(function(ie, ce) {
|
|
11138
|
+
U(ne, J, ie, ce);
|
|
11139
11139
|
});
|
|
11140
11140
|
}
|
|
11141
11141
|
return re = re ? re.then(oe, oe) : oe();
|
|
@@ -11299,8 +11299,8 @@ var notification = {}, regeneratorRuntime = { exports: {} };
|
|
|
11299
11299
|
if (this.done)
|
|
11300
11300
|
throw z;
|
|
11301
11301
|
var U = this;
|
|
11302
|
-
function re(
|
|
11303
|
-
return J.type = "throw", J.arg = z, U.next =
|
|
11302
|
+
function re(ce, me) {
|
|
11303
|
+
return J.type = "throw", J.arg = z, U.next = ce, me && (U.method = "next", U.arg = void 0), !!me;
|
|
11304
11304
|
}
|
|
11305
11305
|
for (var ae = this.tryEntries.length - 1; ae >= 0; --ae) {
|
|
11306
11306
|
var ne = this.tryEntries[ae], J = ne.completion;
|
|
@@ -11588,35 +11588,35 @@ function requireNotification() {
|
|
|
11588
11588
|
value: !0
|
|
11589
11589
|
}), e.getInstance = e.default = void 0;
|
|
11590
11590
|
var a = o(regeneratorRuntime.exports), s = o(_extends$1.exports), l = o(defineProperty.exports), c = o(CheckCircleOutlined$3.exports), u = o(CloseCircleOutlined$3.exports), d = o(CloseOutlined$3.exports), f = o(ExclamationCircleOutlined$3.exports), p = o(InfoCircleOutlined$3.exports), h = o(classnames.exports), m = o(require$$11$1), g = r(React__default), v = r(requireConfigProvider()), C = o(requireUseNotification()), w = function(ne, J, oe, ie) {
|
|
11591
|
-
function
|
|
11591
|
+
function ce(me) {
|
|
11592
11592
|
return me instanceof oe ? me : new oe(function(Q) {
|
|
11593
11593
|
Q(me);
|
|
11594
11594
|
});
|
|
11595
11595
|
}
|
|
11596
11596
|
return new (oe || (oe = Promise))(function(me, Q) {
|
|
11597
|
-
function te(
|
|
11597
|
+
function te(Oe) {
|
|
11598
11598
|
try {
|
|
11599
|
-
ve(ie.next(
|
|
11599
|
+
ve(ie.next(Oe));
|
|
11600
11600
|
} catch (D) {
|
|
11601
11601
|
Q(D);
|
|
11602
11602
|
}
|
|
11603
11603
|
}
|
|
11604
|
-
function he(
|
|
11604
|
+
function he(Oe) {
|
|
11605
11605
|
try {
|
|
11606
|
-
ve(ie.throw(
|
|
11606
|
+
ve(ie.throw(Oe));
|
|
11607
11607
|
} catch (D) {
|
|
11608
11608
|
Q(D);
|
|
11609
11609
|
}
|
|
11610
11610
|
}
|
|
11611
|
-
function ve(
|
|
11612
|
-
|
|
11611
|
+
function ve(Oe) {
|
|
11612
|
+
Oe.done ? me(Oe.value) : ce(Oe.value).then(te, he);
|
|
11613
11613
|
}
|
|
11614
11614
|
ve((ie = ie.apply(ne, J || [])).next());
|
|
11615
11615
|
});
|
|
11616
11616
|
}, I = {}, y = 4.5, x = 24, O = 24, S = "", T = "topRight", G, E, P = !1, B;
|
|
11617
11617
|
function N(ne) {
|
|
11618
|
-
var J = ne.duration, oe = ne.placement, ie = ne.bottom,
|
|
11619
|
-
te !== void 0 && (S = te), J !== void 0 && (y = J), oe !== void 0 ? T = oe : ne.rtl && (T = "topLeft"), ie !== void 0 && (O = ie),
|
|
11618
|
+
var J = ne.duration, oe = ne.placement, ie = ne.bottom, ce = ne.top, me = ne.getContainer, Q = ne.closeIcon, te = ne.prefixCls;
|
|
11619
|
+
te !== void 0 && (S = te), J !== void 0 && (y = J), oe !== void 0 ? T = oe : ne.rtl && (T = "topLeft"), ie !== void 0 && (O = ie), ce !== void 0 && (x = ce), me !== void 0 && (G = me), Q !== void 0 && (E = Q), ne.rtl !== void 0 && (P = ne.rtl), ne.maxCount !== void 0 && (B = ne.maxCount);
|
|
11620
11620
|
}
|
|
11621
11621
|
function L(ne) {
|
|
11622
11622
|
var J = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : x, oe = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : O, ie;
|
|
@@ -11671,29 +11671,29 @@ function requireNotification() {
|
|
|
11671
11671
|
return ie;
|
|
11672
11672
|
}
|
|
11673
11673
|
function W(ne, J) {
|
|
11674
|
-
var oe = ne.placement, ie = oe === void 0 ? T : oe,
|
|
11674
|
+
var oe = ne.placement, ie = oe === void 0 ? T : oe, ce = ne.top, me = ne.bottom, Q = ne.getContainer, te = Q === void 0 ? G : Q, he = ne.prefixCls, ve = (0, v.globalConfig)(), Oe = ve.getPrefixCls, D = ve.getIconPrefixCls, M = Oe("notification", he || S), pe = D(), ge = "".concat(M, "-").concat(ie), Fe = I[ge];
|
|
11675
11675
|
if (Fe) {
|
|
11676
11676
|
Promise.resolve(Fe).then(function(Re) {
|
|
11677
11677
|
J({
|
|
11678
11678
|
prefixCls: "".concat(M, "-notice"),
|
|
11679
|
-
iconPrefixCls:
|
|
11679
|
+
iconPrefixCls: pe,
|
|
11680
11680
|
instance: Re
|
|
11681
11681
|
});
|
|
11682
11682
|
});
|
|
11683
11683
|
return;
|
|
11684
11684
|
}
|
|
11685
|
-
var
|
|
11685
|
+
var Te = (0, h.default)("".concat(M, "-").concat(ie), (0, l.default)({}, "".concat(M, "-rtl"), P === !0));
|
|
11686
11686
|
I[ge] = new Promise(function(Re) {
|
|
11687
11687
|
m.default.newInstance({
|
|
11688
11688
|
prefixCls: M,
|
|
11689
|
-
className:
|
|
11690
|
-
style: L(ie,
|
|
11689
|
+
className: Te,
|
|
11690
|
+
style: L(ie, ce, me),
|
|
11691
11691
|
getContainer: te,
|
|
11692
11692
|
maxCount: B
|
|
11693
11693
|
}, function(Ae) {
|
|
11694
11694
|
Re(Ae), J({
|
|
11695
11695
|
prefixCls: "".concat(M, "-notice"),
|
|
11696
|
-
iconPrefixCls:
|
|
11696
|
+
iconPrefixCls: pe,
|
|
11697
11697
|
instance: Ae
|
|
11698
11698
|
});
|
|
11699
11699
|
});
|
|
@@ -11706,17 +11706,17 @@ function requireNotification() {
|
|
|
11706
11706
|
warning: f.default
|
|
11707
11707
|
};
|
|
11708
11708
|
function H(ne, J, oe) {
|
|
11709
|
-
var ie = ne.duration,
|
|
11710
|
-
|
|
11709
|
+
var ie = ne.duration, ce = ne.icon, me = ne.type, Q = ne.description, te = ne.message, he = ne.btn, ve = ne.onClose, Oe = ne.onClick, D = ne.key, M = ne.style, pe = ne.className, ge = ne.closeIcon, Fe = ge === void 0 ? E : ge, Te = ne.props, Re = ie === void 0 ? y : ie, Ae = null;
|
|
11710
|
+
ce ? Ae = /* @__PURE__ */ g.createElement("span", {
|
|
11711
11711
|
className: "".concat(J, "-icon")
|
|
11712
11712
|
}, ne.icon) : me && (Ae = /* @__PURE__ */ g.createElement(K[me] || null, {
|
|
11713
11713
|
className: "".concat(J, "-icon ").concat(J, "-icon-").concat(me)
|
|
11714
11714
|
}));
|
|
11715
|
-
var
|
|
11715
|
+
var et = /* @__PURE__ */ g.createElement("span", {
|
|
11716
11716
|
className: "".concat(J, "-close-x")
|
|
11717
11717
|
}, Fe || /* @__PURE__ */ g.createElement(d.default, {
|
|
11718
11718
|
className: "".concat(J, "-close-icon")
|
|
11719
|
-
})),
|
|
11719
|
+
})), Ht = !Q && Ae ? /* @__PURE__ */ g.createElement("span", {
|
|
11720
11720
|
className: "".concat(J, "-message-single-line-auto-margin")
|
|
11721
11721
|
}) : null;
|
|
11722
11722
|
return {
|
|
@@ -11727,26 +11727,26 @@ function requireNotification() {
|
|
|
11727
11727
|
role: "alert"
|
|
11728
11728
|
}, Ae, /* @__PURE__ */ g.createElement("div", {
|
|
11729
11729
|
className: "".concat(J, "-message")
|
|
11730
|
-
},
|
|
11730
|
+
}, Ht, te), /* @__PURE__ */ g.createElement("div", {
|
|
11731
11731
|
className: "".concat(J, "-description")
|
|
11732
11732
|
}, Q), he ? /* @__PURE__ */ g.createElement("span", {
|
|
11733
11733
|
className: "".concat(J, "-btn")
|
|
11734
11734
|
}, he) : null)),
|
|
11735
11735
|
duration: Re,
|
|
11736
11736
|
closable: !0,
|
|
11737
|
-
closeIcon:
|
|
11737
|
+
closeIcon: et,
|
|
11738
11738
|
onClose: ve,
|
|
11739
|
-
onClick:
|
|
11739
|
+
onClick: Oe,
|
|
11740
11740
|
key: D,
|
|
11741
11741
|
style: M || {},
|
|
11742
|
-
className: (0, h.default)(
|
|
11743
|
-
props:
|
|
11742
|
+
className: (0, h.default)(pe, (0, l.default)({}, "".concat(J, "-").concat(me), !!me)),
|
|
11743
|
+
props: Te
|
|
11744
11744
|
};
|
|
11745
11745
|
}
|
|
11746
11746
|
function z(ne) {
|
|
11747
11747
|
W(ne, function(J) {
|
|
11748
|
-
var oe = J.prefixCls, ie = J.iconPrefixCls,
|
|
11749
|
-
|
|
11748
|
+
var oe = J.prefixCls, ie = J.iconPrefixCls, ce = J.instance;
|
|
11749
|
+
ce.notice(H(ne, oe, ie));
|
|
11750
11750
|
});
|
|
11751
11751
|
}
|
|
11752
11752
|
var U = {
|
|
@@ -11776,14 +11776,14 @@ function requireNotification() {
|
|
|
11776
11776
|
}), U.warn = U.warning, U.useNotification = (0, C.default)(W, H);
|
|
11777
11777
|
var re = function(J) {
|
|
11778
11778
|
return w(void 0, void 0, void 0, /* @__PURE__ */ (0, a.default)().mark(function oe() {
|
|
11779
|
-
return (0, a.default)().wrap(function(
|
|
11779
|
+
return (0, a.default)().wrap(function(ce) {
|
|
11780
11780
|
for (; ; )
|
|
11781
|
-
switch (
|
|
11781
|
+
switch (ce.prev = ce.next) {
|
|
11782
11782
|
case 0:
|
|
11783
|
-
return
|
|
11783
|
+
return ce.abrupt("return", process.env.NODE_ENV === "test" ? I[J] : null);
|
|
11784
11784
|
case 1:
|
|
11785
11785
|
case "end":
|
|
11786
|
-
return
|
|
11786
|
+
return ce.stop();
|
|
11787
11787
|
}
|
|
11788
11788
|
}, oe);
|
|
11789
11789
|
}));
|
|
@@ -11955,53 +11955,53 @@ function requireConfigProvider() {
|
|
|
11955
11955
|
};
|
|
11956
11956
|
e.globalConfig = B;
|
|
11957
11957
|
var N = function(H) {
|
|
11958
|
-
var z, U, re = H.children, ae = H.csp, ne = H.autoInsertSpaceInButton, J = H.form, oe = H.locale, ie = H.componentSize,
|
|
11959
|
-
var
|
|
11960
|
-
if (
|
|
11961
|
-
return
|
|
11962
|
-
var
|
|
11963
|
-
return Ae ? "".concat(
|
|
11964
|
-
}, [ve.getPrefixCls, H.prefixCls]),
|
|
11958
|
+
var z, U, re = H.children, ae = H.csp, ne = H.autoInsertSpaceInButton, J = H.form, oe = H.locale, ie = H.componentSize, ce = H.direction, me = H.space, Q = H.virtual, te = H.dropdownMatchSelectWidth, he = H.legacyLocale, ve = H.parentContext, Oe = H.iconPrefixCls, D = H.componentDisabled, M = u.useCallback(function(Ae, et) {
|
|
11959
|
+
var Ht = H.prefixCls;
|
|
11960
|
+
if (et)
|
|
11961
|
+
return et;
|
|
11962
|
+
var Jt = Ht || ve.getPrefixCls("");
|
|
11963
|
+
return Ae ? "".concat(Jt, "-").concat(Ae) : Jt;
|
|
11964
|
+
}, [ve.getPrefixCls, H.prefixCls]), pe = (0, a.default)((0, a.default)({}, ve), {
|
|
11965
11965
|
csp: ae,
|
|
11966
11966
|
autoInsertSpaceInButton: ne,
|
|
11967
11967
|
locale: oe || he,
|
|
11968
|
-
direction:
|
|
11968
|
+
direction: ce,
|
|
11969
11969
|
space: me,
|
|
11970
11970
|
virtual: Q,
|
|
11971
11971
|
dropdownMatchSelectWidth: te,
|
|
11972
11972
|
getPrefixCls: M
|
|
11973
11973
|
});
|
|
11974
11974
|
y.forEach(function(Ae) {
|
|
11975
|
-
var
|
|
11976
|
-
|
|
11975
|
+
var et = H[Ae];
|
|
11976
|
+
et && (pe[Ae] = et);
|
|
11977
11977
|
});
|
|
11978
11978
|
var ge = (0, c.default)(function() {
|
|
11979
|
-
return
|
|
11980
|
-
},
|
|
11981
|
-
var
|
|
11982
|
-
return
|
|
11983
|
-
return Ae[
|
|
11979
|
+
return pe;
|
|
11980
|
+
}, pe, function(Ae, et) {
|
|
11981
|
+
var Ht = Object.keys(Ae), Jt = Object.keys(et);
|
|
11982
|
+
return Ht.length !== Jt.length || Ht.some(function(Yt) {
|
|
11983
|
+
return Ae[Yt] !== et[Yt];
|
|
11984
11984
|
});
|
|
11985
11985
|
}), Fe = u.useMemo(function() {
|
|
11986
11986
|
return {
|
|
11987
|
-
prefixCls:
|
|
11987
|
+
prefixCls: Oe,
|
|
11988
11988
|
csp: ae
|
|
11989
11989
|
};
|
|
11990
|
-
}, [
|
|
11991
|
-
return oe && (Re = ((z = oe.Form) === null || z === void 0 ? void 0 : z.defaultValidateMessages) || ((U = p.default.Form) === null || U === void 0 ? void 0 : U.defaultValidateMessages) || {}), J && J.validateMessages && (Re = (0, a.default)((0, a.default)({}, Re), J.validateMessages)), Object.keys(Re).length > 0 && (
|
|
11990
|
+
}, [Oe, ae]), Te = re, Re = {};
|
|
11991
|
+
return oe && (Re = ((z = oe.Form) === null || z === void 0 ? void 0 : z.defaultValidateMessages) || ((U = p.default.Form) === null || U === void 0 ? void 0 : U.defaultValidateMessages) || {}), J && J.validateMessages && (Re = (0, a.default)((0, a.default)({}, Re), J.validateMessages)), Object.keys(Re).length > 0 && (Te = /* @__PURE__ */ u.createElement(l.FormProvider, {
|
|
11992
11992
|
validateMessages: Re
|
|
11993
|
-
}, re)), oe && (
|
|
11993
|
+
}, re)), oe && (Te = /* @__PURE__ */ u.createElement(d.default, {
|
|
11994
11994
|
locale: oe,
|
|
11995
11995
|
_ANT_MARK__: d.ANT_MARK
|
|
11996
|
-
},
|
|
11996
|
+
}, Te)), (Oe || ae) && (Te = /* @__PURE__ */ u.createElement(s.default.Provider, {
|
|
11997
11997
|
value: Fe
|
|
11998
|
-
},
|
|
11998
|
+
}, Te)), ie && (Te = /* @__PURE__ */ u.createElement(w.SizeContextProvider, {
|
|
11999
11999
|
size: ie
|
|
12000
|
-
},
|
|
12000
|
+
}, Te)), D !== void 0 && (Te = /* @__PURE__ */ u.createElement(C.DisabledContextProvider, {
|
|
12001
12001
|
disabled: D
|
|
12002
|
-
},
|
|
12002
|
+
}, Te)), /* @__PURE__ */ u.createElement(g.ConfigContext.Provider, {
|
|
12003
12003
|
value: ge
|
|
12004
|
-
},
|
|
12004
|
+
}, Te);
|
|
12005
12005
|
}, L = function(H) {
|
|
12006
12006
|
return u.useEffect(function() {
|
|
12007
12007
|
H.direction && (h.default.config({
|
|
@@ -12314,9 +12314,9 @@ var _excluded$1 = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnte
|
|
|
12314
12314
|
var oe;
|
|
12315
12315
|
(oe = L.current) === null || oe === void 0 || oe.blur();
|
|
12316
12316
|
},
|
|
12317
|
-
setSelectionRange: function(oe, ie,
|
|
12317
|
+
setSelectionRange: function(oe, ie, ce) {
|
|
12318
12318
|
var me;
|
|
12319
|
-
(me = L.current) === null || me === void 0 || me.setSelectionRange(oe, ie,
|
|
12319
|
+
(me = L.current) === null || me === void 0 || me.setSelectionRange(oe, ie, ce);
|
|
12320
12320
|
},
|
|
12321
12321
|
select: function() {
|
|
12322
12322
|
var oe;
|
|
@@ -12371,11 +12371,11 @@ var _excluded$1 = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnte
|
|
|
12371
12371
|
}, ne = function() {
|
|
12372
12372
|
var oe = Number(g) > 0;
|
|
12373
12373
|
if (v || C) {
|
|
12374
|
-
var ie = fixControlledValue(T),
|
|
12374
|
+
var ie = fixControlledValue(T), ce = _toConsumableArray(ie).length, me = _typeof$2(C) === "object" ? C.formatter({
|
|
12375
12375
|
value: ie,
|
|
12376
|
-
count:
|
|
12376
|
+
count: ce,
|
|
12377
12377
|
maxLength: g
|
|
12378
|
-
}) : "".concat(
|
|
12378
|
+
}) : "".concat(ce).concat(oe ? " / ".concat(g) : "");
|
|
12379
12379
|
return /* @__PURE__ */ jsxs(Fragment, {
|
|
12380
12380
|
children: [!!C && /* @__PURE__ */ jsx("span", {
|
|
12381
12381
|
className: classNames("".concat(f, "-show-count-suffix"), _defineProperty$1({}, "".concat(f, "-show-count-has-suffix"), !!v)),
|
|
@@ -12612,32 +12612,32 @@ function hasPrefixSuffix(e) {
|
|
|
12612
12612
|
}
|
|
12613
12613
|
}
|
|
12614
12614
|
var E = /* @__PURE__ */ (0, p.forwardRef)(function(B, N) {
|
|
12615
|
-
var L, W, K, H = B.prefixCls, z = B.bordered, U = z === void 0 ? !0 : z, re = B.status, ae = B.size, ne = B.disabled, J = B.onBlur, oe = B.onFocus, ie = B.suffix,
|
|
12615
|
+
var L, W, K, H = B.prefixCls, z = B.bordered, U = z === void 0 ? !0 : z, re = B.status, ae = B.size, ne = B.disabled, J = B.onBlur, oe = B.onFocus, ie = B.suffix, ce = B.allowClear, me = B.addonAfter, Q = B.addonBefore, te = B.className, he = B.onChange, ve = O(B, ["prefixCls", "bordered", "status", "size", "disabled", "onBlur", "onFocus", "suffix", "allowClear", "addonAfter", "addonBefore", "className", "onChange"]), Oe = p.default.useContext(h.ConfigContext), D = Oe.getPrefixCls, M = Oe.direction, pe = Oe.input, ge = D("input", H), Fe = (0, p.useRef)(null), Te = (0, C.useCompactItemContext)(ge, M), Re = Te.compactSize, Ae = Te.compactItemClassnames, et = p.default.useContext(g.default), Ht = Re || ae || et, Jt = p.default.useContext(m.default), Yt = ne != null ? ne : Jt, Pe = (0, p.useContext)(v.FormItemInputContext), jt = Pe.status, it = Pe.hasFeedback, Qt = Pe.feedbackIcon, xt = (0, w.getMergedStatus)(jt, re), Pt = (0, x.hasPrefixSuffix)(B) || !!it, kt = (0, p.useRef)(Pt);
|
|
12616
12616
|
(0, p.useEffect)(function() {
|
|
12617
|
-
var
|
|
12618
|
-
|
|
12619
|
-
}, [
|
|
12620
|
-
var
|
|
12621
|
-
|
|
12622
|
-
},
|
|
12623
|
-
|
|
12624
|
-
},
|
|
12625
|
-
|
|
12626
|
-
},
|
|
12627
|
-
return (0, l.default)(
|
|
12617
|
+
var un;
|
|
12618
|
+
Pt && !kt.current && process.env.NODE_ENV !== "production" && (0, I.default)(document.activeElement === ((un = Fe.current) === null || un === void 0 ? void 0 : un.input), "Input", "When Input is focused, dynamic add or remove prefix / suffix will make it lose focus caused by dom structure change. Read more: https://ant.design/components/input/#FAQ"), kt.current = Pt;
|
|
12619
|
+
}, [Pt]);
|
|
12620
|
+
var cn = (0, y.default)(Fe, !0), Ze = function(gn) {
|
|
12621
|
+
cn(), J == null || J(gn);
|
|
12622
|
+
}, _t = function(gn) {
|
|
12623
|
+
cn(), oe == null || oe(gn);
|
|
12624
|
+
}, en = function(gn) {
|
|
12625
|
+
cn(), he == null || he(gn);
|
|
12626
|
+
}, Xt = (it || ie) && /* @__PURE__ */ p.default.createElement(p.default.Fragment, null, ie, it && Qt), tn;
|
|
12627
|
+
return (0, l.default)(ce) === "object" && (ce == null ? void 0 : ce.clearIcon) ? tn = ce : ce && (tn = {
|
|
12628
12628
|
clearIcon: /* @__PURE__ */ p.default.createElement(c.default, null)
|
|
12629
12629
|
}), /* @__PURE__ */ p.default.createElement(d.default, (0, s.default)({
|
|
12630
12630
|
ref: (0, f.composeRef)(N, Fe),
|
|
12631
12631
|
prefixCls: ge,
|
|
12632
|
-
autoComplete:
|
|
12632
|
+
autoComplete: pe == null ? void 0 : pe.autoComplete
|
|
12633
12633
|
}, ve, {
|
|
12634
|
-
disabled:
|
|
12635
|
-
onBlur:
|
|
12636
|
-
onFocus:
|
|
12637
|
-
suffix:
|
|
12634
|
+
disabled: Yt || void 0,
|
|
12635
|
+
onBlur: Ze,
|
|
12636
|
+
onFocus: _t,
|
|
12637
|
+
suffix: Xt,
|
|
12638
12638
|
allowClear: tn,
|
|
12639
12639
|
className: (0, u.default)(te, Ae),
|
|
12640
|
-
onChange:
|
|
12640
|
+
onChange: en,
|
|
12641
12641
|
addonAfter: me && /* @__PURE__ */ p.default.createElement(C.NoCompactStyle, null, /* @__PURE__ */ p.default.createElement(v.NoFormStyle, {
|
|
12642
12642
|
override: !0,
|
|
12643
12643
|
status: !0
|
|
@@ -12646,10 +12646,10 @@ function hasPrefixSuffix(e) {
|
|
|
12646
12646
|
override: !0,
|
|
12647
12647
|
status: !0
|
|
12648
12648
|
}, Q)),
|
|
12649
|
-
inputClassName: (0, u.default)((L = {}, (0, a.default)(L, "".concat(ge, "-sm"),
|
|
12650
|
-
affixWrapperClassName: (0, u.default)((W = {}, (0, a.default)(W, "".concat(ge, "-affix-wrapper-sm"),
|
|
12649
|
+
inputClassName: (0, u.default)((L = {}, (0, a.default)(L, "".concat(ge, "-sm"), Ht === "small"), (0, a.default)(L, "".concat(ge, "-lg"), Ht === "large"), (0, a.default)(L, "".concat(ge, "-rtl"), M === "rtl"), (0, a.default)(L, "".concat(ge, "-borderless"), !U), L), !Pt && (0, w.getStatusClassNames)(ge, xt)),
|
|
12650
|
+
affixWrapperClassName: (0, u.default)((W = {}, (0, a.default)(W, "".concat(ge, "-affix-wrapper-sm"), Ht === "small"), (0, a.default)(W, "".concat(ge, "-affix-wrapper-lg"), Ht === "large"), (0, a.default)(W, "".concat(ge, "-affix-wrapper-rtl"), M === "rtl"), (0, a.default)(W, "".concat(ge, "-affix-wrapper-borderless"), !U), W), (0, w.getStatusClassNames)("".concat(ge, "-affix-wrapper"), xt, it)),
|
|
12651
12651
|
wrapperClassName: (0, u.default)((0, a.default)({}, "".concat(ge, "-group-rtl"), M === "rtl")),
|
|
12652
|
-
groupClassName: (0, u.default)((K = {}, (0, a.default)(K, "".concat(ge, "-group-wrapper-sm"),
|
|
12652
|
+
groupClassName: (0, u.default)((K = {}, (0, a.default)(K, "".concat(ge, "-group-wrapper-sm"), Ht === "small"), (0, a.default)(K, "".concat(ge, "-group-wrapper-lg"), Ht === "large"), (0, a.default)(K, "".concat(ge, "-group-wrapper-rtl"), M === "rtl"), K), (0, w.getStatusClassNames)("".concat(ge, "-group-wrapper"), xt, it))
|
|
12653
12653
|
}));
|
|
12654
12654
|
}), P = E;
|
|
12655
12655
|
e.default = P;
|
|
@@ -12676,86 +12676,86 @@ function hasPrefixSuffix(e) {
|
|
|
12676
12676
|
return P ? W = S(N, L) : (0, u.default)(B || "").length < N.length && (0, u.default)(N || "").length > L && (W = B), W;
|
|
12677
12677
|
}
|
|
12678
12678
|
var G = /* @__PURE__ */ m.forwardRef(function(P, B) {
|
|
12679
|
-
var N, L = P.prefixCls, W = P.bordered, K = W === void 0 ? !0 : W, H = P.showCount, z = H === void 0 ? !1 : H, U = P.maxLength, re = P.className, ae = P.style, ne = P.size, J = P.disabled, oe = P.onCompositionStart, ie = P.onCompositionEnd,
|
|
12679
|
+
var N, L = P.prefixCls, W = P.bordered, K = W === void 0 ? !0 : W, H = P.showCount, z = H === void 0 ? !1 : H, U = P.maxLength, re = P.className, ae = P.style, ne = P.size, J = P.disabled, oe = P.onCompositionStart, ie = P.onCompositionEnd, ce = P.onChange, me = P.status, Q = O(P, ["prefixCls", "bordered", "showCount", "maxLength", "className", "style", "size", "disabled", "onCompositionStart", "onCompositionEnd", "onChange", "status"]), te = m.useContext(g.ConfigContext), he = te.getPrefixCls, ve = te.direction, Oe = m.useContext(C.default), D = m.useContext(v.default), M = J != null ? J : D, pe = m.useContext(w.FormItemInputContext), ge = pe.status, Fe = pe.hasFeedback, Te = pe.isFormItemInput, Re = pe.feedbackIcon, Ae = (0, I.getMergedStatus)(ge, me), et = m.useRef(null), Ht = m.useRef(null), Jt = m.useState(!1), Yt = (0, c.default)(Jt, 2), Pe = Yt[0], jt = Yt[1], it = m.useRef(), Qt = m.useRef(0), xt = (0, p.default)(Q.defaultValue, {
|
|
12680
12680
|
value: Q.value
|
|
12681
|
-
}),
|
|
12682
|
-
Q.value === void 0 && (
|
|
12683
|
-
},
|
|
12684
|
-
|
|
12685
|
-
}, tn = function(
|
|
12686
|
-
var
|
|
12687
|
-
|
|
12688
|
-
var
|
|
12689
|
-
if (
|
|
12690
|
-
var
|
|
12691
|
-
|
|
12681
|
+
}), Pt = (0, c.default)(xt, 2), kt = Pt[0], cn = Pt[1], Ze = Q.hidden, _t = function(dn, sn) {
|
|
12682
|
+
Q.value === void 0 && (cn(dn), sn == null || sn());
|
|
12683
|
+
}, en = Number(U) > 0, Xt = function(dn) {
|
|
12684
|
+
jt(!0), it.current = kt, Qt.current = dn.currentTarget.selectionStart, oe == null || oe(dn);
|
|
12685
|
+
}, tn = function(dn) {
|
|
12686
|
+
var sn;
|
|
12687
|
+
jt(!1);
|
|
12688
|
+
var pn = dn.currentTarget.value;
|
|
12689
|
+
if (en) {
|
|
12690
|
+
var In = Qt.current >= U + 1 || Qt.current === ((sn = it.current) === null || sn === void 0 ? void 0 : sn.length);
|
|
12691
|
+
pn = T(In, it.current, pn, U);
|
|
12692
12692
|
}
|
|
12693
|
-
|
|
12694
|
-
},
|
|
12695
|
-
var
|
|
12696
|
-
if (!
|
|
12697
|
-
var
|
|
12698
|
-
|
|
12693
|
+
pn !== kt && (_t(pn), (0, x.resolveOnChange)(dn.currentTarget, dn, ce, pn)), ie == null || ie(dn);
|
|
12694
|
+
}, un = function(dn) {
|
|
12695
|
+
var sn = dn.target.value;
|
|
12696
|
+
if (!Pe && en) {
|
|
12697
|
+
var pn = dn.target.selectionStart >= U + 1 || dn.target.selectionStart === sn.length || !dn.target.selectionStart;
|
|
12698
|
+
sn = T(pn, kt, sn, U);
|
|
12699
12699
|
}
|
|
12700
|
-
|
|
12701
|
-
}, gn = function(
|
|
12702
|
-
var
|
|
12703
|
-
|
|
12704
|
-
},
|
|
12700
|
+
_t(sn), (0, x.resolveOnChange)(dn.currentTarget, dn, ce, sn);
|
|
12701
|
+
}, gn = function(dn) {
|
|
12702
|
+
var sn, pn, In;
|
|
12703
|
+
_t(""), (sn = et.current) === null || sn === void 0 || sn.focus(), (0, x.resolveOnChange)((In = (pn = et.current) === null || pn === void 0 ? void 0 : pn.resizableTextArea) === null || In === void 0 ? void 0 : In.textArea, dn, ce);
|
|
12704
|
+
}, mn = he("input", L);
|
|
12705
12705
|
m.useImperativeHandle(B, function() {
|
|
12706
12706
|
var On;
|
|
12707
12707
|
return {
|
|
12708
|
-
resizableTextArea: (On =
|
|
12709
|
-
focus: function(
|
|
12710
|
-
var
|
|
12711
|
-
(0, x.triggerFocus)((
|
|
12708
|
+
resizableTextArea: (On = et.current) === null || On === void 0 ? void 0 : On.resizableTextArea,
|
|
12709
|
+
focus: function(sn) {
|
|
12710
|
+
var pn, In;
|
|
12711
|
+
(0, x.triggerFocus)((In = (pn = et.current) === null || pn === void 0 ? void 0 : pn.resizableTextArea) === null || In === void 0 ? void 0 : In.textArea, sn);
|
|
12712
12712
|
},
|
|
12713
12713
|
blur: function() {
|
|
12714
|
-
var
|
|
12715
|
-
return (
|
|
12714
|
+
var sn;
|
|
12715
|
+
return (sn = et.current) === null || sn === void 0 ? void 0 : sn.blur();
|
|
12716
12716
|
}
|
|
12717
12717
|
};
|
|
12718
12718
|
});
|
|
12719
|
-
var
|
|
12719
|
+
var an = /* @__PURE__ */ m.createElement(f.default, (0, l.default)({}, (0, h.default)(Q, ["allowClear"]), {
|
|
12720
12720
|
disabled: M,
|
|
12721
|
-
className: (0, d.default)((N = {}, (0, s.default)(N, "".concat(
|
|
12721
|
+
className: (0, d.default)((N = {}, (0, s.default)(N, "".concat(mn, "-borderless"), !K), (0, s.default)(N, re, re && !z), (0, s.default)(N, "".concat(mn, "-sm"), Oe === "small" || ne === "small"), (0, s.default)(N, "".concat(mn, "-lg"), Oe === "large" || ne === "large"), N), (0, I.getStatusClassNames)(mn, Ae)),
|
|
12722
12722
|
style: z ? {
|
|
12723
12723
|
resize: ae == null ? void 0 : ae.resize
|
|
12724
12724
|
} : ae,
|
|
12725
|
-
prefixCls:
|
|
12726
|
-
onCompositionStart:
|
|
12727
|
-
onChange:
|
|
12725
|
+
prefixCls: mn,
|
|
12726
|
+
onCompositionStart: Xt,
|
|
12727
|
+
onChange: un,
|
|
12728
12728
|
onCompositionEnd: tn,
|
|
12729
|
-
ref:
|
|
12730
|
-
})),
|
|
12731
|
-
!
|
|
12729
|
+
ref: et
|
|
12730
|
+
})), fn = (0, x.fixControlledValue)(kt);
|
|
12731
|
+
!Pe && en && (Q.value === null || Q.value === void 0) && (fn = S(fn, U));
|
|
12732
12732
|
var _n = /* @__PURE__ */ m.createElement(y.default, (0, l.default)({
|
|
12733
12733
|
disabled: M
|
|
12734
12734
|
}, Q, {
|
|
12735
|
-
prefixCls:
|
|
12735
|
+
prefixCls: mn,
|
|
12736
12736
|
direction: ve,
|
|
12737
12737
|
inputType: "text",
|
|
12738
|
-
value:
|
|
12739
|
-
element:
|
|
12738
|
+
value: fn,
|
|
12739
|
+
element: an,
|
|
12740
12740
|
handleReset: gn,
|
|
12741
|
-
ref:
|
|
12741
|
+
ref: Ht,
|
|
12742
12742
|
bordered: K,
|
|
12743
12743
|
status: me,
|
|
12744
12744
|
style: z ? void 0 : ae
|
|
12745
12745
|
}));
|
|
12746
12746
|
if (z || Fe) {
|
|
12747
|
-
var
|
|
12747
|
+
var $n, yn = (0, u.default)(fn).length, jn = "";
|
|
12748
12748
|
return (0, a.default)(z) === "object" ? jn = z.formatter({
|
|
12749
|
-
value:
|
|
12750
|
-
count:
|
|
12749
|
+
value: fn,
|
|
12750
|
+
count: yn,
|
|
12751
12751
|
maxLength: U
|
|
12752
|
-
}) : jn = "".concat(
|
|
12753
|
-
hidden:
|
|
12754
|
-
className: (0, d.default)("".concat(
|
|
12752
|
+
}) : jn = "".concat(yn).concat(en ? " / ".concat(U) : ""), /* @__PURE__ */ m.createElement("div", {
|
|
12753
|
+
hidden: Ze,
|
|
12754
|
+
className: (0, d.default)("".concat(mn, "-textarea"), ($n = {}, (0, s.default)($n, "".concat(mn, "-textarea-rtl"), ve === "rtl"), (0, s.default)($n, "".concat(mn, "-textarea-show-count"), z), (0, s.default)($n, "".concat(mn, "-textarea-in-form-item"), Te), $n), (0, I.getStatusClassNames)("".concat(mn, "-textarea"), Ae, Fe), re),
|
|
12755
12755
|
style: ae,
|
|
12756
12756
|
"data-count": jn
|
|
12757
12757
|
}, _n, Fe && /* @__PURE__ */ m.createElement("span", {
|
|
12758
|
-
className: "".concat(
|
|
12758
|
+
className: "".concat(mn, "-textarea-suffix")
|
|
12759
12759
|
}, Re));
|
|
12760
12760
|
}
|
|
12761
12761
|
return _n;
|
|
@@ -13803,8 +13803,8 @@ function require_stream_writable() {
|
|
|
13803
13803
|
function T(Q, te, he) {
|
|
13804
13804
|
r = r || require_stream_duplex(), Q = Q || {}, typeof he != "boolean" && (he = te instanceof r), this.objectMode = !!Q.objectMode, he && (this.objectMode = this.objectMode || !!Q.writableObjectMode), this.highWaterMark = p(this, Q, "writableHighWaterMark", he), this.finalCalled = !1, this.needDrain = !1, this.ending = !1, this.ended = !1, this.finished = !1, this.destroyed = !1;
|
|
13805
13805
|
var ve = Q.decodeStrings === !1;
|
|
13806
|
-
this.decodeStrings = !ve, this.defaultEncoding = Q.defaultEncoding || "utf8", this.length = 0, this.writing = !1, this.corked = 0, this.sync = !0, this.bufferProcessing = !1, this.onwrite = function(
|
|
13807
|
-
z(te,
|
|
13806
|
+
this.decodeStrings = !ve, this.defaultEncoding = Q.defaultEncoding || "utf8", this.length = 0, this.writing = !1, this.corked = 0, this.sync = !0, this.bufferProcessing = !1, this.onwrite = function(Oe) {
|
|
13807
|
+
z(te, Oe);
|
|
13808
13808
|
}, this.writecb = null, this.writelen = 0, this.bufferedRequest = null, this.lastBufferedRequest = null, this.pendingcb = 0, this.prefinished = !1, this.errorEmitted = !1, this.emitClose = Q.emitClose !== !1, this.autoDestroy = !!Q.autoDestroy, this.bufferedRequestCount = 0, this.corkedRequestsFree = new e(this);
|
|
13809
13809
|
}
|
|
13810
13810
|
T.prototype.getBuffer = function() {
|
|
@@ -13844,12 +13844,12 @@ function require_stream_writable() {
|
|
|
13844
13844
|
O(Q, he), process.nextTick(te, he);
|
|
13845
13845
|
}
|
|
13846
13846
|
function B(Q, te, he, ve) {
|
|
13847
|
-
var
|
|
13848
|
-
return he === null ?
|
|
13847
|
+
var Oe;
|
|
13848
|
+
return he === null ? Oe = new I() : typeof he != "string" && !te.objectMode && (Oe = new m("chunk", ["string", "Buffer"], he)), Oe ? (O(Q, Oe), process.nextTick(ve, Oe), !1) : !0;
|
|
13849
13849
|
}
|
|
13850
13850
|
E.prototype.write = function(Q, te, he) {
|
|
13851
|
-
var ve = this._writableState,
|
|
13852
|
-
return D && !s.isBuffer(Q) && (Q = c(Q)), typeof te == "function" && (he = te, te = null), D ? te = "buffer" : te || (te = ve.defaultEncoding), typeof he != "function" && (he = S), ve.ending ? P(this, he) : (D || B(this, ve, Q, he)) && (ve.pendingcb++,
|
|
13851
|
+
var ve = this._writableState, Oe = !1, D = !ve.objectMode && u(Q);
|
|
13852
|
+
return D && !s.isBuffer(Q) && (Q = c(Q)), typeof te == "function" && (he = te, te = null), D ? te = "buffer" : te || (te = ve.defaultEncoding), typeof he != "function" && (he = S), ve.ending ? P(this, he) : (D || B(this, ve, Q, he)) && (ve.pendingcb++, Oe = L(this, ve, D, Q, te, he)), Oe;
|
|
13853
13853
|
}, E.prototype.cork = function() {
|
|
13854
13854
|
this._writableState.corked++;
|
|
13855
13855
|
}, E.prototype.uncork = function() {
|
|
@@ -13874,45 +13874,45 @@ function require_stream_writable() {
|
|
|
13874
13874
|
return this._writableState.highWaterMark;
|
|
13875
13875
|
}
|
|
13876
13876
|
});
|
|
13877
|
-
function L(Q, te, he, ve,
|
|
13877
|
+
function L(Q, te, he, ve, Oe, D) {
|
|
13878
13878
|
if (!he) {
|
|
13879
|
-
var M = N(te, ve,
|
|
13880
|
-
ve !== M && (he = !0,
|
|
13879
|
+
var M = N(te, ve, Oe);
|
|
13880
|
+
ve !== M && (he = !0, Oe = "buffer", ve = M);
|
|
13881
13881
|
}
|
|
13882
|
-
var
|
|
13883
|
-
te.length +=
|
|
13882
|
+
var pe = te.objectMode ? 1 : ve.length;
|
|
13883
|
+
te.length += pe;
|
|
13884
13884
|
var ge = te.length < te.highWaterMark;
|
|
13885
13885
|
if (ge || (te.needDrain = !0), te.writing || te.corked) {
|
|
13886
13886
|
var Fe = te.lastBufferedRequest;
|
|
13887
13887
|
te.lastBufferedRequest = {
|
|
13888
13888
|
chunk: ve,
|
|
13889
|
-
encoding:
|
|
13889
|
+
encoding: Oe,
|
|
13890
13890
|
isBuf: he,
|
|
13891
13891
|
callback: D,
|
|
13892
13892
|
next: null
|
|
13893
13893
|
}, Fe ? Fe.next = te.lastBufferedRequest : te.bufferedRequest = te.lastBufferedRequest, te.bufferedRequestCount += 1;
|
|
13894
13894
|
} else
|
|
13895
|
-
W(Q, te, !1,
|
|
13895
|
+
W(Q, te, !1, pe, ve, Oe, D);
|
|
13896
13896
|
return ge;
|
|
13897
13897
|
}
|
|
13898
|
-
function W(Q, te, he, ve,
|
|
13899
|
-
te.writelen = ve, te.writecb = M, te.writing = !0, te.sync = !0, te.destroyed ? te.onwrite(new w("write")) : he ? Q._writev(
|
|
13898
|
+
function W(Q, te, he, ve, Oe, D, M) {
|
|
13899
|
+
te.writelen = ve, te.writecb = M, te.writing = !0, te.sync = !0, te.destroyed ? te.onwrite(new w("write")) : he ? Q._writev(Oe, te.onwrite) : Q._write(Oe, D, te.onwrite), te.sync = !1;
|
|
13900
13900
|
}
|
|
13901
|
-
function K(Q, te, he, ve,
|
|
13902
|
-
--te.pendingcb, he ? (process.nextTick(
|
|
13901
|
+
function K(Q, te, he, ve, Oe) {
|
|
13902
|
+
--te.pendingcb, he ? (process.nextTick(Oe, ve), process.nextTick(ie, Q, te), Q._writableState.errorEmitted = !0, O(Q, ve)) : (Oe(ve), Q._writableState.errorEmitted = !0, O(Q, ve), ie(Q, te));
|
|
13903
13903
|
}
|
|
13904
13904
|
function H(Q) {
|
|
13905
13905
|
Q.writing = !1, Q.writecb = null, Q.length -= Q.writelen, Q.writelen = 0;
|
|
13906
13906
|
}
|
|
13907
13907
|
function z(Q, te) {
|
|
13908
|
-
var he = Q._writableState, ve = he.sync,
|
|
13909
|
-
if (typeof
|
|
13908
|
+
var he = Q._writableState, ve = he.sync, Oe = he.writecb;
|
|
13909
|
+
if (typeof Oe != "function")
|
|
13910
13910
|
throw new v();
|
|
13911
13911
|
if (H(he), te)
|
|
13912
|
-
K(Q, he, ve, te,
|
|
13912
|
+
K(Q, he, ve, te, Oe);
|
|
13913
13913
|
else {
|
|
13914
13914
|
var D = ne(he) || Q.destroyed;
|
|
13915
|
-
!D && !he.corked && !he.bufferProcessing && he.bufferedRequest && ae(Q, he), ve ? process.nextTick(U, Q, he, D,
|
|
13915
|
+
!D && !he.corked && !he.bufferProcessing && he.bufferedRequest && ae(Q, he), ve ? process.nextTick(U, Q, he, D, Oe) : U(Q, he, D, Oe);
|
|
13916
13916
|
}
|
|
13917
13917
|
}
|
|
13918
13918
|
function U(Q, te, he, ve) {
|
|
@@ -13925,15 +13925,15 @@ function require_stream_writable() {
|
|
|
13925
13925
|
te.bufferProcessing = !0;
|
|
13926
13926
|
var he = te.bufferedRequest;
|
|
13927
13927
|
if (Q._writev && he && he.next) {
|
|
13928
|
-
var ve = te.bufferedRequestCount,
|
|
13928
|
+
var ve = te.bufferedRequestCount, Oe = new Array(ve), D = te.corkedRequestsFree;
|
|
13929
13929
|
D.entry = he;
|
|
13930
|
-
for (var M = 0,
|
|
13931
|
-
|
|
13932
|
-
|
|
13930
|
+
for (var M = 0, pe = !0; he; )
|
|
13931
|
+
Oe[M] = he, he.isBuf || (pe = !1), he = he.next, M += 1;
|
|
13932
|
+
Oe.allBuffers = pe, W(Q, te, !0, te.length, Oe, "", D.finish), te.pendingcb++, te.lastBufferedRequest = null, D.next ? (te.corkedRequestsFree = D.next, D.next = null) : te.corkedRequestsFree = new e(te), te.bufferedRequestCount = 0;
|
|
13933
13933
|
} else {
|
|
13934
13934
|
for (; he; ) {
|
|
13935
|
-
var ge = he.chunk, Fe = he.encoding,
|
|
13936
|
-
if (W(Q, te, !1, Re, ge, Fe,
|
|
13935
|
+
var ge = he.chunk, Fe = he.encoding, Te = he.callback, Re = te.objectMode ? 1 : ge.length;
|
|
13936
|
+
if (W(Q, te, !1, Re, ge, Fe, Te), he = he.next, te.bufferedRequestCount--, te.writing)
|
|
13937
13937
|
break;
|
|
13938
13938
|
}
|
|
13939
13939
|
he === null && (te.lastBufferedRequest = null);
|
|
@@ -13944,7 +13944,7 @@ function require_stream_writable() {
|
|
|
13944
13944
|
he(new g("_write()"));
|
|
13945
13945
|
}, E.prototype._writev = null, E.prototype.end = function(Q, te, he) {
|
|
13946
13946
|
var ve = this._writableState;
|
|
13947
|
-
return typeof Q == "function" ? (he = Q, Q = null, te = null) : typeof te == "function" && (he = te, te = null), Q != null && this.write(Q, te), ve.corked && (ve.corked = 1, this.uncork()), ve.ending ||
|
|
13947
|
+
return typeof Q == "function" ? (he = Q, Q = null, te = null) : typeof te == "function" && (he = te, te = null), Q != null && this.write(Q, te), ve.corked && (ve.corked = 1, this.uncork()), ve.ending || ce(this, ve, he), this;
|
|
13948
13948
|
}, Object.defineProperty(E.prototype, "writableLength", {
|
|
13949
13949
|
enumerable: !1,
|
|
13950
13950
|
get: function() {
|
|
@@ -13970,14 +13970,14 @@ function require_stream_writable() {
|
|
|
13970
13970
|
}
|
|
13971
13971
|
return he;
|
|
13972
13972
|
}
|
|
13973
|
-
function
|
|
13973
|
+
function ce(Q, te, he) {
|
|
13974
13974
|
te.ending = !0, ie(Q, te), he && (te.finished ? process.nextTick(he) : Q.once("finish", he)), te.ended = !0, Q.writable = !1;
|
|
13975
13975
|
}
|
|
13976
13976
|
function me(Q, te, he) {
|
|
13977
13977
|
var ve = Q.entry;
|
|
13978
13978
|
for (Q.entry = null; ve; ) {
|
|
13979
|
-
var
|
|
13980
|
-
te.pendingcb--,
|
|
13979
|
+
var Oe = ve.callback;
|
|
13980
|
+
te.pendingcb--, Oe(he), ve = ve.next;
|
|
13981
13981
|
}
|
|
13982
13982
|
te.corkedRequestsFree.next = Q;
|
|
13983
13983
|
}
|
|
@@ -14415,8 +14415,8 @@ function require_stream_readable() {
|
|
|
14415
14415
|
hasRequired_stream_readable = 1, _stream_readable = P;
|
|
14416
14416
|
var e;
|
|
14417
14417
|
P.ReadableState = E, events.exports.EventEmitter;
|
|
14418
|
-
var r = function(M,
|
|
14419
|
-
return M.listeners(
|
|
14418
|
+
var r = function(M, pe) {
|
|
14419
|
+
return M.listeners(pe).length;
|
|
14420
14420
|
}, o = streamBrowser, a = require$$0.Buffer, s = commonjsGlobal.Uint8Array || function() {
|
|
14421
14421
|
};
|
|
14422
14422
|
function l(D) {
|
|
@@ -14431,13 +14431,13 @@ function require_stream_readable() {
|
|
|
14431
14431
|
var f = requireBuffer_list(), p = destroy_1, h = state, m = h.getHighWaterMark, g = errorsBrowser.codes, v = g.ERR_INVALID_ARG_TYPE, C = g.ERR_STREAM_PUSH_AFTER_EOF, w = g.ERR_METHOD_NOT_IMPLEMENTED, I = g.ERR_STREAM_UNSHIFT_AFTER_END_EVENT, y, x, O;
|
|
14432
14432
|
inherits_browser.exports(P, o);
|
|
14433
14433
|
var S = p.errorOrDestroy, T = ["error", "close", "destroy", "pause", "resume"];
|
|
14434
|
-
function G(D, M,
|
|
14434
|
+
function G(D, M, pe) {
|
|
14435
14435
|
if (typeof D.prependListener == "function")
|
|
14436
|
-
return D.prependListener(M,
|
|
14437
|
-
!D._events || !D._events[M] ? D.on(M,
|
|
14436
|
+
return D.prependListener(M, pe);
|
|
14437
|
+
!D._events || !D._events[M] ? D.on(M, pe) : Array.isArray(D._events[M]) ? D._events[M].unshift(pe) : D._events[M] = [pe, D._events[M]];
|
|
14438
14438
|
}
|
|
14439
|
-
function E(D, M,
|
|
14440
|
-
e = e || require_stream_duplex(), D = D || {}, typeof
|
|
14439
|
+
function E(D, M, pe) {
|
|
14440
|
+
e = e || require_stream_duplex(), D = D || {}, typeof pe != "boolean" && (pe = M instanceof e), this.objectMode = !!D.objectMode, pe && (this.objectMode = this.objectMode || !!D.readableObjectMode), this.highWaterMark = m(this, D, "readableHighWaterMark", pe), this.buffer = new f(), this.length = 0, this.pipes = null, this.pipesCount = 0, this.flowing = null, this.ended = !1, this.endEmitted = !1, this.reading = !1, this.sync = !0, this.needReadable = !1, this.emittedReadable = !1, this.readableListening = !1, this.resumeScheduled = !1, this.paused = !0, this.emitClose = D.emitClose !== !1, this.autoDestroy = !!D.autoDestroy, this.destroyed = !1, this.defaultEncoding = D.defaultEncoding || "utf8", this.awaitDrain = 0, this.readingMore = !1, this.decoder = null, this.encoding = null, D.encoding && (y || (y = requireString_decoder().StringDecoder), this.decoder = new y(D.encoding), this.encoding = D.encoding);
|
|
14441
14441
|
}
|
|
14442
14442
|
function P(D) {
|
|
14443
14443
|
if (e = e || require_stream_duplex(), !(this instanceof P))
|
|
@@ -14456,41 +14456,41 @@ function require_stream_readable() {
|
|
|
14456
14456
|
}), P.prototype.destroy = p.destroy, P.prototype._undestroy = p.undestroy, P.prototype._destroy = function(D, M) {
|
|
14457
14457
|
M(D);
|
|
14458
14458
|
}, P.prototype.push = function(D, M) {
|
|
14459
|
-
var
|
|
14460
|
-
return
|
|
14459
|
+
var pe = this._readableState, ge;
|
|
14460
|
+
return pe.objectMode ? ge = !0 : typeof D == "string" && (M = M || pe.defaultEncoding, M !== pe.encoding && (D = a.from(D, M), M = ""), ge = !0), B(this, D, M, !1, ge);
|
|
14461
14461
|
}, P.prototype.unshift = function(D) {
|
|
14462
14462
|
return B(this, D, null, !0, !1);
|
|
14463
14463
|
};
|
|
14464
|
-
function B(D, M,
|
|
14464
|
+
function B(D, M, pe, ge, Fe) {
|
|
14465
14465
|
d("readableAddChunk", M);
|
|
14466
|
-
var
|
|
14466
|
+
var Te = D._readableState;
|
|
14467
14467
|
if (M === null)
|
|
14468
|
-
|
|
14468
|
+
Te.reading = !1, z(D, Te);
|
|
14469
14469
|
else {
|
|
14470
14470
|
var Re;
|
|
14471
|
-
if (Fe || (Re = L(
|
|
14471
|
+
if (Fe || (Re = L(Te, M)), Re)
|
|
14472
14472
|
S(D, Re);
|
|
14473
|
-
else if (
|
|
14474
|
-
if (typeof M != "string" && !
|
|
14475
|
-
|
|
14476
|
-
else if (
|
|
14473
|
+
else if (Te.objectMode || M && M.length > 0)
|
|
14474
|
+
if (typeof M != "string" && !Te.objectMode && Object.getPrototypeOf(M) !== a.prototype && (M = l(M)), ge)
|
|
14475
|
+
Te.endEmitted ? S(D, new I()) : N(D, Te, M, !0);
|
|
14476
|
+
else if (Te.ended)
|
|
14477
14477
|
S(D, new C());
|
|
14478
14478
|
else {
|
|
14479
|
-
if (
|
|
14479
|
+
if (Te.destroyed)
|
|
14480
14480
|
return !1;
|
|
14481
|
-
|
|
14481
|
+
Te.reading = !1, Te.decoder && !pe ? (M = Te.decoder.write(M), Te.objectMode || M.length !== 0 ? N(D, Te, M, !1) : ae(D, Te)) : N(D, Te, M, !1);
|
|
14482
14482
|
}
|
|
14483
14483
|
else
|
|
14484
|
-
ge || (
|
|
14484
|
+
ge || (Te.reading = !1, ae(D, Te));
|
|
14485
14485
|
}
|
|
14486
|
-
return !
|
|
14486
|
+
return !Te.ended && (Te.length < Te.highWaterMark || Te.length === 0);
|
|
14487
14487
|
}
|
|
14488
|
-
function N(D, M,
|
|
14489
|
-
M.flowing && M.length === 0 && !M.sync ? (M.awaitDrain = 0, D.emit("data",
|
|
14488
|
+
function N(D, M, pe, ge) {
|
|
14489
|
+
M.flowing && M.length === 0 && !M.sync ? (M.awaitDrain = 0, D.emit("data", pe)) : (M.length += M.objectMode ? 1 : pe.length, ge ? M.buffer.unshift(pe) : M.buffer.push(pe), M.needReadable && U(D)), ae(D, M);
|
|
14490
14490
|
}
|
|
14491
14491
|
function L(D, M) {
|
|
14492
|
-
var
|
|
14493
|
-
return !c(M) && typeof M != "string" && M !== void 0 && !D.objectMode && (
|
|
14492
|
+
var pe;
|
|
14493
|
+
return !c(M) && typeof M != "string" && M !== void 0 && !D.objectMode && (pe = new v("chunk", ["string", "Buffer", "Uint8Array"], M)), pe;
|
|
14494
14494
|
}
|
|
14495
14495
|
P.prototype.isPaused = function() {
|
|
14496
14496
|
return this._readableState.flowing === !1;
|
|
@@ -14498,8 +14498,8 @@ function require_stream_readable() {
|
|
|
14498
14498
|
y || (y = requireString_decoder().StringDecoder);
|
|
14499
14499
|
var M = new y(D);
|
|
14500
14500
|
this._readableState.decoder = M, this._readableState.encoding = this._readableState.decoder.encoding;
|
|
14501
|
-
for (var
|
|
14502
|
-
ge += M.write(
|
|
14501
|
+
for (var pe = this._readableState.buffer.head, ge = ""; pe !== null; )
|
|
14502
|
+
ge += M.write(pe.data), pe = pe.next;
|
|
14503
14503
|
return this._readableState.buffer.clear(), ge !== "" && this._readableState.buffer.push(ge), this._readableState.length = ge.length, this;
|
|
14504
14504
|
};
|
|
14505
14505
|
var W = 1073741824;
|
|
@@ -14511,21 +14511,21 @@ function require_stream_readable() {
|
|
|
14511
14511
|
}
|
|
14512
14512
|
P.prototype.read = function(D) {
|
|
14513
14513
|
d("read", D), D = parseInt(D, 10);
|
|
14514
|
-
var M = this._readableState,
|
|
14514
|
+
var M = this._readableState, pe = D;
|
|
14515
14515
|
if (D !== 0 && (M.emittedReadable = !1), D === 0 && M.needReadable && ((M.highWaterMark !== 0 ? M.length >= M.highWaterMark : M.length > 0) || M.ended))
|
|
14516
14516
|
return d("read: emitReadable", M.length, M.ended), M.length === 0 && M.ended ? he(this) : U(this), null;
|
|
14517
14517
|
if (D = H(D, M), D === 0 && M.ended)
|
|
14518
14518
|
return M.length === 0 && he(this), null;
|
|
14519
14519
|
var ge = M.needReadable;
|
|
14520
|
-
d("need readable", ge), (M.length === 0 || M.length - D < M.highWaterMark) && (ge = !0, d("length less than watermark", ge)), M.ended || M.reading ? (ge = !1, d("reading or ended", ge)) : ge && (d("do read"), M.reading = !0, M.sync = !0, M.length === 0 && (M.needReadable = !0), this._read(M.highWaterMark), M.sync = !1, M.reading || (D = H(
|
|
14520
|
+
d("need readable", ge), (M.length === 0 || M.length - D < M.highWaterMark) && (ge = !0, d("length less than watermark", ge)), M.ended || M.reading ? (ge = !1, d("reading or ended", ge)) : ge && (d("do read"), M.reading = !0, M.sync = !0, M.length === 0 && (M.needReadable = !0), this._read(M.highWaterMark), M.sync = !1, M.reading || (D = H(pe, M)));
|
|
14521
14521
|
var Fe;
|
|
14522
|
-
return D > 0 ? Fe = te(D, M) : Fe = null, Fe === null ? (M.needReadable = M.length <= M.highWaterMark, D = 0) : (M.length -= D, M.awaitDrain = 0), M.length === 0 && (M.ended || (M.needReadable = !0),
|
|
14522
|
+
return D > 0 ? Fe = te(D, M) : Fe = null, Fe === null ? (M.needReadable = M.length <= M.highWaterMark, D = 0) : (M.length -= D, M.awaitDrain = 0), M.length === 0 && (M.ended || (M.needReadable = !0), pe !== D && M.ended && he(this)), Fe !== null && this.emit("data", Fe), Fe;
|
|
14523
14523
|
};
|
|
14524
14524
|
function z(D, M) {
|
|
14525
14525
|
if (d("onEofChunk"), !M.ended) {
|
|
14526
14526
|
if (M.decoder) {
|
|
14527
|
-
var
|
|
14528
|
-
|
|
14527
|
+
var pe = M.decoder.end();
|
|
14528
|
+
pe && pe.length && (M.buffer.push(pe), M.length += M.objectMode ? 1 : pe.length);
|
|
14529
14529
|
}
|
|
14530
14530
|
M.ended = !0, M.sync ? U(D) : (M.needReadable = !1, M.emittedReadable || (M.emittedReadable = !0, re(D)));
|
|
14531
14531
|
}
|
|
@@ -14543,8 +14543,8 @@ function require_stream_readable() {
|
|
|
14543
14543
|
}
|
|
14544
14544
|
function ne(D, M) {
|
|
14545
14545
|
for (; !M.reading && !M.ended && (M.length < M.highWaterMark || M.flowing && M.length === 0); ) {
|
|
14546
|
-
var
|
|
14547
|
-
if (d("maybeReadMore read 0"), D.read(0),
|
|
14546
|
+
var pe = M.length;
|
|
14547
|
+
if (d("maybeReadMore read 0"), D.read(0), pe === M.length)
|
|
14548
14548
|
break;
|
|
14549
14549
|
}
|
|
14550
14550
|
M.readingMore = !1;
|
|
@@ -14552,7 +14552,7 @@ function require_stream_readable() {
|
|
|
14552
14552
|
P.prototype._read = function(D) {
|
|
14553
14553
|
S(this, new w("_read()"));
|
|
14554
14554
|
}, P.prototype.pipe = function(D, M) {
|
|
14555
|
-
var
|
|
14555
|
+
var pe = this, ge = this._readableState;
|
|
14556
14556
|
switch (ge.pipesCount) {
|
|
14557
14557
|
case 0:
|
|
14558
14558
|
ge.pipes = D;
|
|
@@ -14565,74 +14565,74 @@ function require_stream_readable() {
|
|
|
14565
14565
|
break;
|
|
14566
14566
|
}
|
|
14567
14567
|
ge.pipesCount += 1, d("pipe count=%d opts=%j", ge.pipesCount, M);
|
|
14568
|
-
var Fe = (!M || M.end !== !1) && D !== process.stdout && D !== process.stderr,
|
|
14569
|
-
ge.endEmitted ? process.nextTick(
|
|
14570
|
-
function Re(
|
|
14571
|
-
d("onunpipe"),
|
|
14568
|
+
var Fe = (!M || M.end !== !1) && D !== process.stdout && D !== process.stderr, Te = Fe ? Ae : Qt;
|
|
14569
|
+
ge.endEmitted ? process.nextTick(Te) : pe.once("end", Te), D.on("unpipe", Re);
|
|
14570
|
+
function Re(xt, Pt) {
|
|
14571
|
+
d("onunpipe"), xt === pe && Pt && Pt.hasUnpiped === !1 && (Pt.hasUnpiped = !0, Jt());
|
|
14572
14572
|
}
|
|
14573
14573
|
function Ae() {
|
|
14574
14574
|
d("onend"), D.end();
|
|
14575
14575
|
}
|
|
14576
|
-
var
|
|
14577
|
-
D.on("drain",
|
|
14578
|
-
var
|
|
14579
|
-
function
|
|
14580
|
-
d("cleanup"), D.removeListener("close",
|
|
14576
|
+
var et = J(pe);
|
|
14577
|
+
D.on("drain", et);
|
|
14578
|
+
var Ht = !1;
|
|
14579
|
+
function Jt() {
|
|
14580
|
+
d("cleanup"), D.removeListener("close", jt), D.removeListener("finish", it), D.removeListener("drain", et), D.removeListener("error", Pe), D.removeListener("unpipe", Re), pe.removeListener("end", Ae), pe.removeListener("end", Qt), pe.removeListener("data", Yt), Ht = !0, ge.awaitDrain && (!D._writableState || D._writableState.needDrain) && et();
|
|
14581
14581
|
}
|
|
14582
|
-
|
|
14583
|
-
function
|
|
14582
|
+
pe.on("data", Yt);
|
|
14583
|
+
function Yt(xt) {
|
|
14584
14584
|
d("ondata");
|
|
14585
|
-
var
|
|
14586
|
-
d("dest.write",
|
|
14585
|
+
var Pt = D.write(xt);
|
|
14586
|
+
d("dest.write", Pt), Pt === !1 && ((ge.pipesCount === 1 && ge.pipes === D || ge.pipesCount > 1 && Oe(ge.pipes, D) !== -1) && !Ht && (d("false write response, pause", ge.awaitDrain), ge.awaitDrain++), pe.pause());
|
|
14587
14587
|
}
|
|
14588
|
-
function
|
|
14589
|
-
d("onerror",
|
|
14588
|
+
function Pe(xt) {
|
|
14589
|
+
d("onerror", xt), Qt(), D.removeListener("error", Pe), r(D, "error") === 0 && S(D, xt);
|
|
14590
14590
|
}
|
|
14591
|
-
G(D, "error",
|
|
14592
|
-
function
|
|
14593
|
-
D.removeListener("finish",
|
|
14591
|
+
G(D, "error", Pe);
|
|
14592
|
+
function jt() {
|
|
14593
|
+
D.removeListener("finish", it), Qt();
|
|
14594
14594
|
}
|
|
14595
|
-
D.once("close",
|
|
14596
|
-
function
|
|
14597
|
-
d("onfinish"), D.removeListener("close",
|
|
14595
|
+
D.once("close", jt);
|
|
14596
|
+
function it() {
|
|
14597
|
+
d("onfinish"), D.removeListener("close", jt), Qt();
|
|
14598
14598
|
}
|
|
14599
|
-
D.once("finish",
|
|
14600
|
-
function
|
|
14601
|
-
d("unpipe"),
|
|
14599
|
+
D.once("finish", it);
|
|
14600
|
+
function Qt() {
|
|
14601
|
+
d("unpipe"), pe.unpipe(D);
|
|
14602
14602
|
}
|
|
14603
|
-
return D.emit("pipe",
|
|
14603
|
+
return D.emit("pipe", pe), ge.flowing || (d("pipe resume"), pe.resume()), D;
|
|
14604
14604
|
};
|
|
14605
14605
|
function J(D) {
|
|
14606
14606
|
return function() {
|
|
14607
|
-
var
|
|
14608
|
-
d("pipeOnDrain",
|
|
14607
|
+
var pe = D._readableState;
|
|
14608
|
+
d("pipeOnDrain", pe.awaitDrain), pe.awaitDrain && pe.awaitDrain--, pe.awaitDrain === 0 && r(D, "data") && (pe.flowing = !0, Q(D));
|
|
14609
14609
|
};
|
|
14610
14610
|
}
|
|
14611
14611
|
P.prototype.unpipe = function(D) {
|
|
14612
|
-
var M = this._readableState,
|
|
14612
|
+
var M = this._readableState, pe = {
|
|
14613
14613
|
hasUnpiped: !1
|
|
14614
14614
|
};
|
|
14615
14615
|
if (M.pipesCount === 0)
|
|
14616
14616
|
return this;
|
|
14617
14617
|
if (M.pipesCount === 1)
|
|
14618
|
-
return D && D !== M.pipes ? this : (D || (D = M.pipes), M.pipes = null, M.pipesCount = 0, M.flowing = !1, D && D.emit("unpipe", this,
|
|
14618
|
+
return D && D !== M.pipes ? this : (D || (D = M.pipes), M.pipes = null, M.pipesCount = 0, M.flowing = !1, D && D.emit("unpipe", this, pe), this);
|
|
14619
14619
|
if (!D) {
|
|
14620
14620
|
var ge = M.pipes, Fe = M.pipesCount;
|
|
14621
14621
|
M.pipes = null, M.pipesCount = 0, M.flowing = !1;
|
|
14622
|
-
for (var
|
|
14623
|
-
ge[
|
|
14622
|
+
for (var Te = 0; Te < Fe; Te++)
|
|
14623
|
+
ge[Te].emit("unpipe", this, {
|
|
14624
14624
|
hasUnpiped: !1
|
|
14625
14625
|
});
|
|
14626
14626
|
return this;
|
|
14627
14627
|
}
|
|
14628
|
-
var Re =
|
|
14629
|
-
return Re === -1 ? this : (M.pipes.splice(Re, 1), M.pipesCount -= 1, M.pipesCount === 1 && (M.pipes = M.pipes[0]), D.emit("unpipe", this,
|
|
14628
|
+
var Re = Oe(M.pipes, D);
|
|
14629
|
+
return Re === -1 ? this : (M.pipes.splice(Re, 1), M.pipesCount -= 1, M.pipesCount === 1 && (M.pipes = M.pipes[0]), D.emit("unpipe", this, pe), this);
|
|
14630
14630
|
}, P.prototype.on = function(D, M) {
|
|
14631
|
-
var
|
|
14632
|
-
return D === "data" ? (ge.readableListening = this.listenerCount("readable") > 0, ge.flowing !== !1 && this.resume()) : D === "readable" && !ge.endEmitted && !ge.readableListening && (ge.readableListening = ge.needReadable = !0, ge.flowing = !1, ge.emittedReadable = !1, d("on readable", ge.length, ge.reading), ge.length ? U(this) : ge.reading || process.nextTick(ie, this)),
|
|
14631
|
+
var pe = o.prototype.on.call(this, D, M), ge = this._readableState;
|
|
14632
|
+
return D === "data" ? (ge.readableListening = this.listenerCount("readable") > 0, ge.flowing !== !1 && this.resume()) : D === "readable" && !ge.endEmitted && !ge.readableListening && (ge.readableListening = ge.needReadable = !0, ge.flowing = !1, ge.emittedReadable = !1, d("on readable", ge.length, ge.reading), ge.length ? U(this) : ge.reading || process.nextTick(ie, this)), pe;
|
|
14633
14633
|
}, P.prototype.addListener = P.prototype.on, P.prototype.removeListener = function(D, M) {
|
|
14634
|
-
var
|
|
14635
|
-
return D === "readable" && process.nextTick(oe, this),
|
|
14634
|
+
var pe = o.prototype.removeListener.call(this, D, M);
|
|
14635
|
+
return D === "readable" && process.nextTick(oe, this), pe;
|
|
14636
14636
|
}, P.prototype.removeAllListeners = function(D) {
|
|
14637
14637
|
var M = o.prototype.removeAllListeners.apply(this, arguments);
|
|
14638
14638
|
return (D === "readable" || D === void 0) && process.nextTick(oe, this), M;
|
|
@@ -14646,9 +14646,9 @@ function require_stream_readable() {
|
|
|
14646
14646
|
}
|
|
14647
14647
|
P.prototype.resume = function() {
|
|
14648
14648
|
var D = this._readableState;
|
|
14649
|
-
return D.flowing || (d("resume"), D.flowing = !D.readableListening,
|
|
14649
|
+
return D.flowing || (d("resume"), D.flowing = !D.readableListening, ce(this, D)), D.paused = !1, this;
|
|
14650
14650
|
};
|
|
14651
|
-
function
|
|
14651
|
+
function ce(D, M) {
|
|
14652
14652
|
M.resumeScheduled || (M.resumeScheduled = !0, process.nextTick(me, D, M));
|
|
14653
14653
|
}
|
|
14654
14654
|
function me(D, M) {
|
|
@@ -14663,15 +14663,15 @@ function require_stream_readable() {
|
|
|
14663
14663
|
;
|
|
14664
14664
|
}
|
|
14665
14665
|
P.prototype.wrap = function(D) {
|
|
14666
|
-
var M = this,
|
|
14666
|
+
var M = this, pe = this._readableState, ge = !1;
|
|
14667
14667
|
D.on("end", function() {
|
|
14668
|
-
if (d("wrapped end"),
|
|
14669
|
-
var Re =
|
|
14668
|
+
if (d("wrapped end"), pe.decoder && !pe.ended) {
|
|
14669
|
+
var Re = pe.decoder.end();
|
|
14670
14670
|
Re && Re.length && M.push(Re);
|
|
14671
14671
|
}
|
|
14672
14672
|
M.push(null);
|
|
14673
14673
|
}), D.on("data", function(Re) {
|
|
14674
|
-
if (d("wrapped data"),
|
|
14674
|
+
if (d("wrapped data"), pe.decoder && (Re = pe.decoder.write(Re)), !(pe.objectMode && Re == null) && !(!pe.objectMode && (!Re || !Re.length))) {
|
|
14675
14675
|
var Ae = M.push(Re);
|
|
14676
14676
|
Ae || (ge = !0, D.pause());
|
|
14677
14677
|
}
|
|
@@ -14682,8 +14682,8 @@ function require_stream_readable() {
|
|
|
14682
14682
|
return D[Ae].apply(D, arguments);
|
|
14683
14683
|
};
|
|
14684
14684
|
}(Fe));
|
|
14685
|
-
for (var
|
|
14686
|
-
D.on(T[
|
|
14685
|
+
for (var Te = 0; Te < T.length; Te++)
|
|
14686
|
+
D.on(T[Te], this.emit.bind(this, T[Te]));
|
|
14687
14687
|
return this._read = function(Re) {
|
|
14688
14688
|
d("wrapped _read", Re), ge && (ge = !1, D.resume());
|
|
14689
14689
|
}, this;
|
|
@@ -14716,8 +14716,8 @@ function require_stream_readable() {
|
|
|
14716
14716
|
function te(D, M) {
|
|
14717
14717
|
if (M.length === 0)
|
|
14718
14718
|
return null;
|
|
14719
|
-
var
|
|
14720
|
-
return M.objectMode ?
|
|
14719
|
+
var pe;
|
|
14720
|
+
return M.objectMode ? pe = M.buffer.shift() : !D || D >= M.length ? (M.decoder ? pe = M.buffer.join("") : M.buffer.length === 1 ? pe = M.buffer.first() : pe = M.buffer.concat(M.length), M.buffer.clear()) : pe = M.buffer.consume(D, M.decoder), pe;
|
|
14721
14721
|
}
|
|
14722
14722
|
function he(D) {
|
|
14723
14723
|
var M = D._readableState;
|
|
@@ -14725,17 +14725,17 @@ function require_stream_readable() {
|
|
|
14725
14725
|
}
|
|
14726
14726
|
function ve(D, M) {
|
|
14727
14727
|
if (d("endReadableNT", D.endEmitted, D.length), !D.endEmitted && D.length === 0 && (D.endEmitted = !0, M.readable = !1, M.emit("end"), D.autoDestroy)) {
|
|
14728
|
-
var
|
|
14729
|
-
(!
|
|
14728
|
+
var pe = M._writableState;
|
|
14729
|
+
(!pe || pe.autoDestroy && pe.finished) && M.destroy();
|
|
14730
14730
|
}
|
|
14731
14731
|
}
|
|
14732
14732
|
typeof Symbol == "function" && (P.from = function(D, M) {
|
|
14733
14733
|
return O === void 0 && (O = requireFromBrowser()), O(P, D, M);
|
|
14734
14734
|
});
|
|
14735
|
-
function
|
|
14736
|
-
for (var
|
|
14737
|
-
if (D[
|
|
14738
|
-
return
|
|
14735
|
+
function Oe(D, M) {
|
|
14736
|
+
for (var pe = 0, ge = D.length; pe < ge; pe++)
|
|
14737
|
+
if (D[pe] === M)
|
|
14738
|
+
return pe;
|
|
14739
14739
|
return -1;
|
|
14740
14740
|
}
|
|
14741
14741
|
return _stream_readable;
|
|
@@ -17252,12 +17252,28 @@ const Image = (e) => {
|
|
|
17252
17252
|
}), r);
|
|
17253
17253
|
}, getOnChangePayload = ({
|
|
17254
17254
|
onChangeFieldActionArgs: e,
|
|
17255
|
-
values: r
|
|
17255
|
+
values: r,
|
|
17256
|
+
parentValues: o = {}
|
|
17256
17257
|
}) => {
|
|
17257
|
-
const
|
|
17258
|
-
return e.forEach((
|
|
17259
|
-
|
|
17260
|
-
|
|
17258
|
+
const a = {};
|
|
17259
|
+
return e.forEach((s) => {
|
|
17260
|
+
const l = s.split("");
|
|
17261
|
+
if (s === "True")
|
|
17262
|
+
a[s] = !0;
|
|
17263
|
+
else if (s === "False")
|
|
17264
|
+
a[s] = !1;
|
|
17265
|
+
else if (r[s])
|
|
17266
|
+
a[s] = r[s];
|
|
17267
|
+
else if (l[0] === "'" && l[l.length - 1] === "'" && l.filter((c) => c === "'").length === 2)
|
|
17268
|
+
a[s] = s.replace(/'/g, "");
|
|
17269
|
+
else if (l.includes("'"))
|
|
17270
|
+
a[s] = s;
|
|
17271
|
+
else if (s.indexOf("parent.") !== -1) {
|
|
17272
|
+
const c = s.replace("parent.", "");
|
|
17273
|
+
a[s] = o[c] || !1;
|
|
17274
|
+
} else
|
|
17275
|
+
a[s] = !1;
|
|
17276
|
+
}), a;
|
|
17261
17277
|
}, mergeSearchFields = (e) => {
|
|
17262
17278
|
const r = {
|
|
17263
17279
|
primary: [],
|
|
@@ -17339,6 +17355,7 @@ const transformPlainMany2Ones = ({
|
|
|
17339
17355
|
fields: w == null ? void 0 : w.getFields(),
|
|
17340
17356
|
values: w.getPlainValues()
|
|
17341
17357
|
}),
|
|
17358
|
+
fields: w == null ? void 0 : w.getFields(),
|
|
17342
17359
|
context: w.getContext()
|
|
17343
17360
|
});
|
|
17344
17361
|
T = [...T, ...P];
|
|
@@ -17786,18 +17803,18 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17786
17803
|
setLimit: S,
|
|
17787
17804
|
searchParams: T = [],
|
|
17788
17805
|
setSearchValues: G
|
|
17789
|
-
} = e, [E, P] = useState$1(!1), [B, N] = useState$1(!1), [L, W] = useState$1(), [K, H] = useState$1(1), [z, U] = useState$1(0), [re, ae] = useState$1(), [ne, J] = useState$1([]), [oe, ie] = useState$1(void 0),
|
|
17790
|
-
w == null || w([...
|
|
17806
|
+
} = e, [E, P] = useState$1(!1), [B, N] = useState$1(!1), [L, W] = useState$1(), [K, H] = useState$1(1), [z, U] = useState$1(0), [re, ae] = useState$1(), [ne, J] = useState$1([]), [oe, ie] = useState$1(void 0), ce = useRef(O || DEFAULT_SEARCH_LIMIT$1), me = useRef([]), Q = useCallback((Te) => {
|
|
17807
|
+
w == null || w([...Te]), J([...Te]);
|
|
17791
17808
|
}, []), te = useCallback(() => I || ne, [I, ne]), he = useCallback(async () => {
|
|
17792
|
-
const
|
|
17809
|
+
const Te = await ConnectionProvider.getHandler().nameSearch({
|
|
17793
17810
|
model: r,
|
|
17794
17811
|
payload: u,
|
|
17795
|
-
limit:
|
|
17812
|
+
limit: ce.current,
|
|
17796
17813
|
attrs: y,
|
|
17797
17814
|
context: f
|
|
17798
17815
|
});
|
|
17799
|
-
if (ae(
|
|
17800
|
-
const Re =
|
|
17816
|
+
if (ae(Te.length), p == null || p(Te.length), Te.length > 0) {
|
|
17817
|
+
const Re = Te.map((Pe) => Pe == null ? void 0 : Pe[0]), { colors: Ae } = getTree(h), et = await ConnectionProvider.getHandler().readEvalUiObjects({
|
|
17801
17818
|
model: r,
|
|
17802
17819
|
ids: Re,
|
|
17803
17820
|
arch: h == null ? void 0 : h.arch,
|
|
@@ -17806,14 +17823,14 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17806
17823
|
attrs: Ae && {
|
|
17807
17824
|
colors: Ae
|
|
17808
17825
|
}
|
|
17809
|
-
}),
|
|
17810
|
-
me.current = [...
|
|
17811
|
-
const
|
|
17812
|
-
resultsToSort:
|
|
17826
|
+
}), Ht = et[0];
|
|
17827
|
+
me.current = [...Ht], ie(getColorMap(et[1]));
|
|
17828
|
+
const Jt = Ht.map((Pe) => Pe.id), Yt = g !== void 0 ? sortResults({
|
|
17829
|
+
resultsToSort: Ht,
|
|
17813
17830
|
sorter: g,
|
|
17814
17831
|
fields: { ...h.fields, ...m.fields }
|
|
17815
17832
|
}) : [...me.current];
|
|
17816
|
-
Q(
|
|
17833
|
+
Q(Yt), Jt.length > 0 ? C == null || C(0) : C == null || C(void 0);
|
|
17817
17834
|
} else
|
|
17818
17835
|
Q([]), C == null || C(void 0);
|
|
17819
17836
|
d.current = !0;
|
|
@@ -17830,31 +17847,31 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17830
17847
|
C,
|
|
17831
17848
|
p
|
|
17832
17849
|
]), ve = useCallback(
|
|
17833
|
-
async (
|
|
17834
|
-
const { params: Re, newOffset: Ae } =
|
|
17835
|
-
params:
|
|
17836
|
-
limit:
|
|
17850
|
+
async (Te) => {
|
|
17851
|
+
const { params: Re, newOffset: Ae } = Te || {}, et = mergeParams(Re || T, y), { colors: Ht } = getTree(h), { totalItems: Jt, results: Yt, attrsEvaluated: Pe } = await ConnectionProvider.getHandler().searchForTree({
|
|
17852
|
+
params: et,
|
|
17853
|
+
limit: ce.current,
|
|
17837
17854
|
offset: Ae || z,
|
|
17838
17855
|
model: r,
|
|
17839
17856
|
fields: h.field_parent ? { ...h.fields, [h.field_parent]: {} } : h.fields,
|
|
17840
17857
|
context: f,
|
|
17841
|
-
attrs:
|
|
17858
|
+
attrs: Ht && { colors: Ht }
|
|
17842
17859
|
});
|
|
17843
|
-
ie(getColorMap(
|
|
17844
|
-
const
|
|
17845
|
-
resultsToSort:
|
|
17860
|
+
ie(getColorMap(Pe)), me.current = [...Yt];
|
|
17861
|
+
const jt = g !== void 0 ? sortResults({
|
|
17862
|
+
resultsToSort: Yt,
|
|
17846
17863
|
sorter: g,
|
|
17847
17864
|
fields: { ...h.fields, ...m.fields }
|
|
17848
17865
|
}) : [...me.current];
|
|
17849
|
-
if (Q(
|
|
17850
|
-
const
|
|
17851
|
-
(
|
|
17866
|
+
if (Q(jt), I && jt.length > 0) {
|
|
17867
|
+
const Qt = jt.findIndex(
|
|
17868
|
+
(xt) => x === xt.id
|
|
17852
17869
|
);
|
|
17853
|
-
|
|
17870
|
+
Qt === -1 ? C == null || C(0) : C == null || C(Qt);
|
|
17854
17871
|
} else
|
|
17855
17872
|
C == null || C(void 0);
|
|
17856
|
-
const
|
|
17857
|
-
ae(
|
|
17873
|
+
const it = await Jt;
|
|
17874
|
+
ae(it), p == null || p(it);
|
|
17858
17875
|
},
|
|
17859
17876
|
[
|
|
17860
17877
|
C,
|
|
@@ -17872,10 +17889,10 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17872
17889
|
z,
|
|
17873
17890
|
T
|
|
17874
17891
|
]
|
|
17875
|
-
),
|
|
17876
|
-
async (
|
|
17892
|
+
), Oe = useCallback(
|
|
17893
|
+
async (Te) => {
|
|
17877
17894
|
try {
|
|
17878
|
-
P(!0), c == null || c(!0), u && !d.current ? await he() : await ve(
|
|
17895
|
+
P(!0), c == null || c(!0), u && !d.current ? await he() : await ve(Te);
|
|
17879
17896
|
} catch (Re) {
|
|
17880
17897
|
W(Re.message);
|
|
17881
17898
|
} finally {
|
|
@@ -17904,22 +17921,22 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17904
17921
|
h
|
|
17905
17922
|
]
|
|
17906
17923
|
), D = useCallback(
|
|
17907
|
-
(
|
|
17908
|
-
v == null || v(
|
|
17909
|
-
const Re =
|
|
17924
|
+
(Te) => {
|
|
17925
|
+
v == null || v(Te);
|
|
17926
|
+
const Re = Te !== void 0 ? sortResults({
|
|
17910
17927
|
resultsToSort: te(),
|
|
17911
|
-
sorter:
|
|
17928
|
+
sorter: Te,
|
|
17912
17929
|
fields: { ...h.fields, ...m.fields }
|
|
17913
17930
|
}) : [...me.current];
|
|
17914
17931
|
Q(Re);
|
|
17915
17932
|
},
|
|
17916
17933
|
[v, te, h, m, Q]
|
|
17917
17934
|
), M = useCallback(
|
|
17918
|
-
(
|
|
17919
|
-
const { params: Re, searchValues: Ae, limit:
|
|
17920
|
-
E || (o == null || o(void 0), a == null || a([]), G == null || G(Ae), s == null || s(Re), l == null || l(!1), N(!0), W(void 0), H(1),
|
|
17935
|
+
(Te) => {
|
|
17936
|
+
const { params: Re, searchValues: Ae, limit: et, offset: Ht } = Te;
|
|
17937
|
+
E || (o == null || o(void 0), a == null || a([]), G == null || G(Ae), s == null || s(Re), l == null || l(!1), N(!0), W(void 0), H(1), et && (ce.current = et, S == null || S(et)), Ht && U(Ht), Oe({
|
|
17921
17938
|
params: Re,
|
|
17922
|
-
newOffset:
|
|
17939
|
+
newOffset: Ht
|
|
17923
17940
|
}));
|
|
17924
17941
|
},
|
|
17925
17942
|
[
|
|
@@ -17933,11 +17950,11 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17933
17950
|
H,
|
|
17934
17951
|
S,
|
|
17935
17952
|
U,
|
|
17936
|
-
|
|
17953
|
+
Oe
|
|
17937
17954
|
]
|
|
17938
|
-
),
|
|
17939
|
-
(
|
|
17940
|
-
P(!0), H(
|
|
17955
|
+
), pe = useCallback(
|
|
17956
|
+
(Te) => {
|
|
17957
|
+
P(!0), H(Te), U((Te - 1) * O);
|
|
17941
17958
|
},
|
|
17942
17959
|
[P, O, U, H]
|
|
17943
17960
|
), ge = useCallback(() => {
|
|
@@ -17952,8 +17969,8 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17952
17969
|
S,
|
|
17953
17970
|
O
|
|
17954
17971
|
]), Fe = useCallback(
|
|
17955
|
-
async (
|
|
17956
|
-
const Re =
|
|
17972
|
+
async (Te) => {
|
|
17973
|
+
const Re = Te[(h == null ? void 0 : h.field_parent) || "child_id"], Ae = await ConnectionProvider.getHandler().readObjects({
|
|
17957
17974
|
model: r,
|
|
17958
17975
|
ids: Re,
|
|
17959
17976
|
fields: h.field_parent ? { ...h.fields, [h.field_parent]: {} } : h.fields,
|
|
@@ -17966,7 +17983,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17966
17983
|
return {
|
|
17967
17984
|
submit: M,
|
|
17968
17985
|
clear: ge,
|
|
17969
|
-
fetchResults:
|
|
17986
|
+
fetchResults: Oe,
|
|
17970
17987
|
tableRefreshing: E,
|
|
17971
17988
|
searchFilterLoading: B,
|
|
17972
17989
|
searchError: L,
|
|
@@ -17974,7 +17991,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17974
17991
|
offset: z,
|
|
17975
17992
|
limit: O,
|
|
17976
17993
|
getResults: te,
|
|
17977
|
-
requestPageChange:
|
|
17994
|
+
requestPageChange: pe,
|
|
17978
17995
|
changeSort: D,
|
|
17979
17996
|
fetchChildrenForRecord: Fe,
|
|
17980
17997
|
colorsForResults: oe,
|
|
@@ -18007,7 +18024,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18007
18024
|
setSearchTreeNameSearch: G,
|
|
18008
18025
|
goToResourceId: E,
|
|
18009
18026
|
limit: P
|
|
18010
|
-
} = e, [B, N] = useState$1(!1), [L, W] = useState$1(!1), [K, H] = useState$1(!1), [z, U] = useState$1(!0), [re, ae] = useState$1(!0), [ne, J] = useState$1([]), [oe, ie] = useState$1(!1), [
|
|
18027
|
+
} = e, [B, N] = useState$1(!1), [L, W] = useState$1(!1), [K, H] = useState$1(!1), [z, U] = useState$1(!0), [re, ae] = useState$1(!0), [ne, J] = useState$1([]), [oe, ie] = useState$1(!1), [ce, me] = useState$1([]), [Q, te] = useState$1(!1), [he, ve] = useState$1(!0), [Oe, D] = useState$1(), [M, pe] = useState$1({}), [ge, Fe] = useState$1(P !== void 0 ? P : DEFAULT_SEARCH_LIMIT$1);
|
|
18011
18028
|
useEffect(() => {
|
|
18012
18029
|
m && m.length > 0 && !g && (v == null || v(0), p == null || p(m[0].id));
|
|
18013
18030
|
}, [m]), useEffect(() => {
|
|
@@ -18015,9 +18032,9 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18015
18032
|
}, [P]), useEffect(() => {
|
|
18016
18033
|
l.length === 1 ? D(l[0]) : l.length > 1 && D(l.filter((Re) => Re.view_id !== o.view_id)[0]);
|
|
18017
18034
|
}, [l]), useEffect(() => {
|
|
18018
|
-
(
|
|
18035
|
+
(Oe == null ? void 0 : Oe.view_id) === o.view_id && l.length > 1 && D(l.filter((Re) => Re.view_id !== o.view_id)[0]);
|
|
18019
18036
|
}, [o]);
|
|
18020
|
-
const
|
|
18037
|
+
const Te = () => {
|
|
18021
18038
|
var Re;
|
|
18022
18039
|
(Re = c.current) == null || Re.submitForm();
|
|
18023
18040
|
};
|
|
@@ -18033,7 +18050,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18033
18050
|
setFormHasChanges: W,
|
|
18034
18051
|
formRef: c,
|
|
18035
18052
|
searchTreeRef: u,
|
|
18036
|
-
onFormSave:
|
|
18053
|
+
onFormSave: Te,
|
|
18037
18054
|
onNewClicked: d,
|
|
18038
18055
|
currentId: f,
|
|
18039
18056
|
setCurrentId: p,
|
|
@@ -18055,7 +18072,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18055
18072
|
duplicatingItem: oe,
|
|
18056
18073
|
setDuplicatingItem: ie,
|
|
18057
18074
|
setSearchParams: me,
|
|
18058
|
-
searchParams:
|
|
18075
|
+
searchParams: ce,
|
|
18059
18076
|
searchVisible: Q,
|
|
18060
18077
|
setSearchVisible: te,
|
|
18061
18078
|
sorter: w,
|
|
@@ -18066,11 +18083,11 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18066
18083
|
setSearchTreeNameSearch: G,
|
|
18067
18084
|
setGraphIsLoading: ve,
|
|
18068
18085
|
graphIsLoading: he,
|
|
18069
|
-
previousView:
|
|
18086
|
+
previousView: Oe,
|
|
18070
18087
|
setPreviousView: D,
|
|
18071
18088
|
goToResourceId: E,
|
|
18072
18089
|
searchValues: M,
|
|
18073
|
-
setSearchValues:
|
|
18090
|
+
setSearchValues: pe,
|
|
18074
18091
|
limit: ge,
|
|
18075
18092
|
setLimit: Fe
|
|
18076
18093
|
},
|
|
@@ -18238,6 +18255,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18238
18255
|
...a
|
|
18239
18256
|
}
|
|
18240
18257
|
}),
|
|
18258
|
+
fields: E,
|
|
18241
18259
|
context: W
|
|
18242
18260
|
})), N.target === "new") {
|
|
18243
18261
|
const z = await ConnectionProvider.getHandler().getView({
|
|
@@ -18406,189 +18424,190 @@ function Form(e, r) {
|
|
|
18406
18424
|
forcedValues: T = {}
|
|
18407
18425
|
} = e, {
|
|
18408
18426
|
lang: G
|
|
18409
|
-
} = useContext(LocaleContext), [E, P] = useState$1(!1), [B, N] = useState$1(), [L, W] = useState$1(), [K] = Form$3.useForm(), [H, z] = useState$1(), [U, re] = useState$1(), ae = useContext(FormModalContext), [ne, J] = useState$1(), [oe, ie] = useState$1(!1),
|
|
18410
|
-
activeId: D
|
|
18411
|
-
|
|
18412
|
-
|
|
18413
|
-
|
|
18414
|
-
|
|
18415
|
-
|
|
18416
|
-
|
|
18417
|
-
|
|
18418
|
-
|
|
18419
|
-
|
|
18420
|
-
|
|
18427
|
+
} = useContext(LocaleContext), [E, P] = useState$1(!1), [B, N] = useState$1(), [L, W] = useState$1(), [K] = Form$3.useForm(), [H, z] = useState$1(), [U, re] = useState$1(), ae = useContext(FormModalContext), [ne, J] = useState$1(), [oe, ie] = useState$1(!1), ce = useRef(), me = useRef({}), Q = useRef({}), te = useRef(!1), he = useRef(!1), ve = ne < WIDTH_BREAKPOINT, Oe = useContext(FormContext$2), {
|
|
18428
|
+
activeId: D,
|
|
18429
|
+
getPlainValues: M
|
|
18430
|
+
} = Oe || {}, pe = useContext(ActionViewContext), {
|
|
18431
|
+
setFormIsSaving: ge = void 0,
|
|
18432
|
+
setFormHasChanges: Fe = void 0,
|
|
18433
|
+
setCurrentId: Te = void 0,
|
|
18434
|
+
setFormIsLoading: Re = void 0,
|
|
18435
|
+
setAttachments: Ae = void 0
|
|
18436
|
+
} = (O ? pe : {}) || {}, et = useContext(ContentRootContext), {
|
|
18437
|
+
processAction: Ht,
|
|
18438
|
+
globalValues: Jt
|
|
18439
|
+
} = et || {};
|
|
18421
18440
|
useImperativeHandle(r, () => ({
|
|
18422
18441
|
submitForm: sn,
|
|
18423
18442
|
getFields: Qt,
|
|
18424
|
-
getValues:
|
|
18425
|
-
getPlainValues:
|
|
18426
|
-
getContext:
|
|
18427
|
-
fetchValues:
|
|
18428
|
-
cancelUnsavedChanges:
|
|
18443
|
+
getValues: xt,
|
|
18444
|
+
getPlainValues: Pt,
|
|
18445
|
+
getContext: cn,
|
|
18446
|
+
fetchValues: an,
|
|
18447
|
+
cancelUnsavedChanges: _n,
|
|
18429
18448
|
clearAndReload: () => {
|
|
18430
|
-
|
|
18449
|
+
ce.current = void 0, W(void 0), mn();
|
|
18431
18450
|
}
|
|
18432
18451
|
})), useEffect(() => {
|
|
18433
18452
|
if (N(void 0), !(!o && !v)) {
|
|
18434
18453
|
if (!x) {
|
|
18435
|
-
|
|
18454
|
+
ce.current = void 0, W(void 0);
|
|
18436
18455
|
return;
|
|
18437
18456
|
}
|
|
18438
|
-
(a === void 0 && U || a !== void 0 && U && a < 0) && (
|
|
18457
|
+
(a === void 0 && U || a !== void 0 && U && a < 0) && (ce.current = void 0, W(void 0)), mn();
|
|
18439
18458
|
}
|
|
18440
18459
|
}, [a, o, g, v, x]), useEffect(() => {
|
|
18441
|
-
oe && (
|
|
18460
|
+
oe && (In({
|
|
18442
18461
|
elementHasLostFocus: !0
|
|
18443
18462
|
}), ie(!1));
|
|
18444
18463
|
}, [oe]);
|
|
18445
|
-
const
|
|
18446
|
-
|
|
18447
|
-
},
|
|
18448
|
-
|
|
18449
|
-
},
|
|
18450
|
-
|
|
18464
|
+
const Yt = (qe, Le, Tt) => {
|
|
18465
|
+
Fe == null || Fe(!1), ge == null || ge(!1), l == null || l(qe, Le, Tt), Te == null || Te(qe);
|
|
18466
|
+
}, Pe = () => {
|
|
18467
|
+
ge == null || ge(!1), s == null || s();
|
|
18468
|
+
}, jt = (qe) => {
|
|
18469
|
+
ge == null || ge(!1), f == null || f(qe);
|
|
18451
18470
|
};
|
|
18452
|
-
function
|
|
18453
|
-
return a ||
|
|
18471
|
+
function it() {
|
|
18472
|
+
return a || ce.current;
|
|
18454
18473
|
}
|
|
18455
18474
|
function Qt() {
|
|
18456
18475
|
return U;
|
|
18457
18476
|
}
|
|
18458
|
-
function
|
|
18459
|
-
const
|
|
18460
|
-
...
|
|
18461
|
-
...
|
|
18477
|
+
function xt() {
|
|
18478
|
+
const qe = {
|
|
18479
|
+
...Xt(U),
|
|
18480
|
+
...Ze()
|
|
18462
18481
|
};
|
|
18463
|
-
for (const
|
|
18464
|
-
Le
|
|
18465
|
-
return
|
|
18482
|
+
for (const Le in qe)
|
|
18483
|
+
qe[Le] === void 0 && delete qe[Le];
|
|
18484
|
+
return qe;
|
|
18466
18485
|
}
|
|
18467
|
-
function
|
|
18468
|
-
const
|
|
18486
|
+
function Pt() {
|
|
18487
|
+
const qe = xt(), Le = Qt();
|
|
18469
18488
|
let Tt = {};
|
|
18470
|
-
return Object.keys(
|
|
18471
|
-
const ln =
|
|
18472
|
-
|
|
18489
|
+
return Object.keys(qe).forEach((Zt) => {
|
|
18490
|
+
const ln = qe[Zt];
|
|
18491
|
+
Le[Zt] && Le[Zt].type === "many2one" && ln && Array.isArray(ln) && ln.length === 2 ? Tt[Zt] = ln[0] : Le[Zt] && (Le[Zt].type === "one2many" || Le[Zt].type === "many2many") && ln && ln.items ? Tt[Zt] = ln.items.filter((Ln) => Ln.operation !== "pendingRemove").map((Ln) => Ln.id) : Tt[Zt] = ln;
|
|
18473
18492
|
}), Tt;
|
|
18474
18493
|
}
|
|
18475
|
-
function
|
|
18476
|
-
const
|
|
18477
|
-
...
|
|
18494
|
+
function kt() {
|
|
18495
|
+
const qe = {
|
|
18496
|
+
...Xt(U)
|
|
18478
18497
|
};
|
|
18479
|
-
for (const
|
|
18480
|
-
Le
|
|
18481
|
-
return
|
|
18498
|
+
for (const Le in qe)
|
|
18499
|
+
qe[Le] === void 0 && delete qe[Le];
|
|
18500
|
+
return qe;
|
|
18482
18501
|
}
|
|
18483
|
-
function
|
|
18502
|
+
function cn() {
|
|
18484
18503
|
return {
|
|
18485
18504
|
...I,
|
|
18486
18505
|
...L == null ? void 0 : L.context
|
|
18487
18506
|
};
|
|
18488
18507
|
}
|
|
18489
|
-
function
|
|
18508
|
+
function Ze() {
|
|
18490
18509
|
return {
|
|
18491
|
-
id:
|
|
18492
|
-
active_id:
|
|
18493
|
-
active_ids: [
|
|
18510
|
+
id: it(),
|
|
18511
|
+
active_id: it(),
|
|
18512
|
+
active_ids: [it()],
|
|
18494
18513
|
parent_id: D,
|
|
18495
|
-
...
|
|
18514
|
+
...Jt
|
|
18496
18515
|
};
|
|
18497
18516
|
}
|
|
18498
|
-
const
|
|
18499
|
-
const
|
|
18517
|
+
const _t = async (qe) => {
|
|
18518
|
+
const Le = it() ? L == null ? void 0 : L.context : {};
|
|
18500
18519
|
return await ConnectionProvider.getHandler().defaultGet({
|
|
18501
18520
|
model: o,
|
|
18502
|
-
fields:
|
|
18521
|
+
fields: qe,
|
|
18503
18522
|
context: {
|
|
18504
18523
|
...I,
|
|
18505
|
-
...
|
|
18524
|
+
...Le
|
|
18506
18525
|
},
|
|
18507
18526
|
extraValues: S
|
|
18508
18527
|
});
|
|
18509
|
-
},
|
|
18528
|
+
}, en = () => Object.keys(getTouchedValues({
|
|
18510
18529
|
source: me.current,
|
|
18511
|
-
target:
|
|
18530
|
+
target: Xt(U),
|
|
18512
18531
|
fields: U
|
|
18513
|
-
})).length !== 0,
|
|
18514
|
-
const
|
|
18515
|
-
return processValues(
|
|
18516
|
-
},
|
|
18532
|
+
})).length !== 0, Xt = (qe) => {
|
|
18533
|
+
const Le = K.getFieldsValue(!0);
|
|
18534
|
+
return processValues(Le, qe);
|
|
18535
|
+
}, tn = (qe, Le) => {
|
|
18517
18536
|
yn({
|
|
18518
18537
|
values: {
|
|
18519
18538
|
...processValues(K.getFieldsValue(!0), U),
|
|
18520
|
-
[
|
|
18539
|
+
[qe]: Le
|
|
18521
18540
|
},
|
|
18522
18541
|
fields: U,
|
|
18523
18542
|
reset: !1
|
|
18524
18543
|
});
|
|
18525
|
-
},
|
|
18526
|
-
async function
|
|
18544
|
+
}, un = (qe) => K.getFieldsValue(!0)[qe];
|
|
18545
|
+
async function gn() {
|
|
18527
18546
|
try {
|
|
18528
18547
|
return await K.validateFields(), !1;
|
|
18529
18548
|
} catch {
|
|
18530
18549
|
return !0;
|
|
18531
18550
|
}
|
|
18532
18551
|
}
|
|
18533
|
-
const
|
|
18534
|
-
N(void 0),
|
|
18535
|
-
let
|
|
18552
|
+
const mn = async () => {
|
|
18553
|
+
N(void 0), Re == null || Re(!0);
|
|
18554
|
+
let qe;
|
|
18536
18555
|
try {
|
|
18537
|
-
v ?
|
|
18556
|
+
v ? qe = {
|
|
18538
18557
|
arch: v.arch,
|
|
18539
18558
|
fields: v.fields
|
|
18540
|
-
} :
|
|
18559
|
+
} : qe = await $n();
|
|
18541
18560
|
const {
|
|
18542
|
-
fields:
|
|
18561
|
+
fields: Le,
|
|
18543
18562
|
arch: Tt
|
|
18544
|
-
} =
|
|
18545
|
-
re(
|
|
18546
|
-
fields:
|
|
18563
|
+
} = qe;
|
|
18564
|
+
re(Le), z(Tt), await an({
|
|
18565
|
+
fields: Le,
|
|
18547
18566
|
arch: Tt
|
|
18548
18567
|
});
|
|
18549
|
-
} catch (
|
|
18550
|
-
N(
|
|
18568
|
+
} catch (Le) {
|
|
18569
|
+
N(Le != null && Le.message ? Le.message + Le.stack : Le), Re == null || Re(!1);
|
|
18551
18570
|
}
|
|
18552
|
-
},
|
|
18553
|
-
let
|
|
18554
|
-
|
|
18555
|
-
values:
|
|
18571
|
+
}, an = async (qe) => {
|
|
18572
|
+
let Le, Tt, Zt, ln;
|
|
18573
|
+
Re == null || Re(!0), N(void 0), qe ? (Tt = qe.fields, Zt = qe.arch) : (Tt = U, Zt = H), g ? Le = g : {
|
|
18574
|
+
values: Le,
|
|
18556
18575
|
defaultGetCalled: ln
|
|
18557
|
-
} = await
|
|
18576
|
+
} = await jn({
|
|
18558
18577
|
fields: Tt,
|
|
18559
|
-
arch:
|
|
18560
|
-
}), y && (
|
|
18578
|
+
arch: Zt
|
|
18579
|
+
}), y && (Le = {
|
|
18561
18580
|
...getValuesForDomain(y),
|
|
18562
|
-
...
|
|
18563
|
-
}), me.current = processValues(
|
|
18564
|
-
values:
|
|
18581
|
+
...Le
|
|
18582
|
+
}), me.current = processValues(Le, Tt), yn({
|
|
18583
|
+
values: Le,
|
|
18565
18584
|
fields: Tt,
|
|
18566
18585
|
reset: !0,
|
|
18567
18586
|
isDefaultGet: ln
|
|
18568
|
-
}),
|
|
18587
|
+
}), pn({
|
|
18569
18588
|
fields: Tt,
|
|
18570
|
-
arch:
|
|
18571
|
-
values:
|
|
18572
|
-
}),
|
|
18589
|
+
arch: Zt,
|
|
18590
|
+
values: Le
|
|
18591
|
+
}), Re == null || Re(!1), Fe == null || Fe(!1), ln && ie(!0);
|
|
18573
18592
|
};
|
|
18574
|
-
function fn(
|
|
18575
|
-
me.current[
|
|
18593
|
+
function fn(qe, Le) {
|
|
18594
|
+
me.current[qe] = Le, Fe == null || Fe(en());
|
|
18576
18595
|
}
|
|
18577
|
-
const
|
|
18578
|
-
|
|
18596
|
+
const _n = async () => new Promise(async (qe) => {
|
|
18597
|
+
en() ? showDialog$6({
|
|
18579
18598
|
lang: G,
|
|
18580
18599
|
onOk: () => {
|
|
18581
|
-
|
|
18600
|
+
Pe == null || Pe(), qe(!0);
|
|
18582
18601
|
},
|
|
18583
18602
|
onCancel: () => {
|
|
18584
|
-
|
|
18603
|
+
qe(!1);
|
|
18585
18604
|
}
|
|
18586
|
-
}) : (
|
|
18587
|
-
}),
|
|
18605
|
+
}) : (Pe == null || Pe(), qe(!0));
|
|
18606
|
+
}), $n = async () => {
|
|
18588
18607
|
if (u) {
|
|
18589
|
-
const
|
|
18608
|
+
const qe = await ConnectionProvider.getHandler().getActionStringForModel(o);
|
|
18590
18609
|
return (await ConnectionProvider.getHandler().getViewsForAction({
|
|
18591
|
-
action:
|
|
18610
|
+
action: qe,
|
|
18592
18611
|
context: I
|
|
18593
18612
|
})).views.get("form");
|
|
18594
18613
|
}
|
|
@@ -18598,61 +18617,61 @@ function Form(e, r) {
|
|
|
18598
18617
|
context: I
|
|
18599
18618
|
});
|
|
18600
18619
|
}, yn = ({
|
|
18601
|
-
values:
|
|
18602
|
-
fields:
|
|
18620
|
+
values: qe,
|
|
18621
|
+
fields: Le,
|
|
18603
18622
|
reset: Tt,
|
|
18604
|
-
isDefaultGet:
|
|
18623
|
+
isDefaultGet: Zt = !1
|
|
18605
18624
|
}) => {
|
|
18606
18625
|
const Ln = {
|
|
18607
18626
|
...Tt ? {} : K.getFieldsValue(!0),
|
|
18608
|
-
...
|
|
18609
|
-
},
|
|
18610
|
-
const Xn = Vn
|
|
18627
|
+
...qe
|
|
18628
|
+
}, Hn = processValues(Ln, Le), _r = Object.keys(Le).map((Vn) => {
|
|
18629
|
+
const Xn = Hn[Vn] !== void 0 ? Hn[Vn] : void 0;
|
|
18611
18630
|
return {
|
|
18612
|
-
name:
|
|
18631
|
+
name: Vn,
|
|
18613
18632
|
touched: !1,
|
|
18614
18633
|
value: Xn
|
|
18615
18634
|
};
|
|
18616
18635
|
});
|
|
18617
|
-
|
|
18618
|
-
},
|
|
18619
|
-
fields:
|
|
18620
|
-
arch:
|
|
18636
|
+
Zt || (Q.current = Hn), K.setFields(_r);
|
|
18637
|
+
}, jn = async ({
|
|
18638
|
+
fields: qe,
|
|
18639
|
+
arch: Le
|
|
18621
18640
|
}) => {
|
|
18622
|
-
let Tt = {},
|
|
18623
|
-
if (
|
|
18641
|
+
let Tt = {}, Zt = !1;
|
|
18642
|
+
if (it()) {
|
|
18624
18643
|
Tt = (await ConnectionProvider.getHandler().readObjects({
|
|
18625
18644
|
model: o,
|
|
18626
|
-
ids: [
|
|
18627
|
-
fields:
|
|
18645
|
+
ids: [it()],
|
|
18646
|
+
fields: qe,
|
|
18628
18647
|
context: I
|
|
18629
18648
|
}))[0];
|
|
18630
18649
|
const ln = await ConnectionProvider.getHandler().search({
|
|
18631
|
-
params: [["res_model", "=", o], ["res_id", "=",
|
|
18650
|
+
params: [["res_model", "=", o], ["res_id", "=", it()]],
|
|
18632
18651
|
fields: ["id", "name"],
|
|
18633
|
-
context:
|
|
18652
|
+
context: cn(),
|
|
18634
18653
|
model: "ir.attachment"
|
|
18635
18654
|
});
|
|
18636
|
-
|
|
18655
|
+
Ae == null || Ae(ln);
|
|
18637
18656
|
} else
|
|
18638
|
-
|
|
18657
|
+
Ae == null || Ae([]), Tt = await _t(qe), Zt = !0;
|
|
18639
18658
|
return {
|
|
18640
18659
|
values: Tt,
|
|
18641
|
-
defaultGetCalled:
|
|
18660
|
+
defaultGetCalled: Zt
|
|
18642
18661
|
};
|
|
18643
|
-
},
|
|
18662
|
+
}, On = async (qe) => {
|
|
18644
18663
|
const {
|
|
18645
|
-
callOnSubmitSucceed:
|
|
18646
|
-
} =
|
|
18647
|
-
if (
|
|
18664
|
+
callOnSubmitSucceed: Le = !0
|
|
18665
|
+
} = qe || {};
|
|
18666
|
+
if (it()) {
|
|
18648
18667
|
const Tt = getTouchedValues({
|
|
18649
18668
|
source: me.current,
|
|
18650
|
-
target:
|
|
18669
|
+
target: Xt(U),
|
|
18651
18670
|
fields: U
|
|
18652
18671
|
});
|
|
18653
18672
|
await ConnectionProvider.getHandler().update({
|
|
18654
18673
|
model: o,
|
|
18655
|
-
id:
|
|
18674
|
+
id: it(),
|
|
18656
18675
|
values: {
|
|
18657
18676
|
...Tt,
|
|
18658
18677
|
...T
|
|
@@ -18662,9 +18681,9 @@ function Form(e, r) {
|
|
|
18662
18681
|
...I,
|
|
18663
18682
|
...L == null ? void 0 : L.context
|
|
18664
18683
|
}
|
|
18665
|
-
}), me.current =
|
|
18684
|
+
}), me.current = Xt(U);
|
|
18666
18685
|
} else {
|
|
18667
|
-
const Tt =
|
|
18686
|
+
const Tt = Xt(U), Zt = await ConnectionProvider.getHandler().create({
|
|
18668
18687
|
model: o,
|
|
18669
18688
|
values: {
|
|
18670
18689
|
...Tt,
|
|
@@ -18676,113 +18695,114 @@ function Form(e, r) {
|
|
|
18676
18695
|
...L == null ? void 0 : L.context
|
|
18677
18696
|
}
|
|
18678
18697
|
});
|
|
18679
|
-
|
|
18698
|
+
ce.current = Zt, me.current = Tt;
|
|
18680
18699
|
}
|
|
18681
|
-
C && await C([
|
|
18682
|
-
},
|
|
18700
|
+
C && await C([it()]), !w && Le && (Yt == null || Yt(it(), xt(), kt()));
|
|
18701
|
+
}, dn = async (qe) => {
|
|
18683
18702
|
const {
|
|
18684
|
-
callOnSubmitSucceed:
|
|
18685
|
-
} =
|
|
18686
|
-
!w &&
|
|
18687
|
-
}, sn = async (
|
|
18688
|
-
let
|
|
18703
|
+
callOnSubmitSucceed: Le = !0
|
|
18704
|
+
} = qe || {};
|
|
18705
|
+
!w && Le && (Yt == null || Yt(it(), xt(), kt()));
|
|
18706
|
+
}, sn = async (qe) => {
|
|
18707
|
+
let Le = !1;
|
|
18689
18708
|
const {
|
|
18690
18709
|
callOnSubmitSucceed: Tt = !0
|
|
18691
|
-
} =
|
|
18692
|
-
if (he.current = !0, N(void 0), !
|
|
18693
|
-
return he.current = !1,
|
|
18694
|
-
if (await
|
|
18710
|
+
} = qe || {};
|
|
18711
|
+
if (he.current = !0, N(void 0), !en() && it() && Tt)
|
|
18712
|
+
return he.current = !1, Fe == null || Fe(!1), Pe == null || Pe(), !0;
|
|
18713
|
+
if (await gn())
|
|
18695
18714
|
return he.current = !1, showDialog$5(G), !1;
|
|
18696
|
-
P(!0),
|
|
18715
|
+
P(!0), ge == null || ge(!0);
|
|
18697
18716
|
try {
|
|
18698
|
-
m === "api" ? await
|
|
18717
|
+
m === "api" ? await On(qe) : await dn(qe), h && (ce.current = void 0, yn({
|
|
18699
18718
|
values: {},
|
|
18700
18719
|
fields: U,
|
|
18701
18720
|
reset: !0
|
|
18702
|
-
})), await
|
|
18703
|
-
} catch (
|
|
18704
|
-
he.current = !1, P(!1),
|
|
18721
|
+
})), await an(), Le = !0;
|
|
18722
|
+
} catch (Zt) {
|
|
18723
|
+
he.current = !1, P(!1), ge == null || ge(!1), jt == null || jt(Zt), N(Zt != null && Zt.message ? Zt.message : Zt);
|
|
18705
18724
|
} finally {
|
|
18706
|
-
he.current = !1,
|
|
18725
|
+
he.current = !1, ge == null || ge(!1), P(!1);
|
|
18707
18726
|
}
|
|
18708
|
-
return
|
|
18709
|
-
},
|
|
18710
|
-
fields:
|
|
18711
|
-
arch:
|
|
18727
|
+
return Le;
|
|
18728
|
+
}, pn = ({
|
|
18729
|
+
fields: qe,
|
|
18730
|
+
arch: Le,
|
|
18712
18731
|
values: Tt
|
|
18713
18732
|
}) => {
|
|
18714
18733
|
var ln;
|
|
18715
|
-
const
|
|
18716
|
-
|
|
18734
|
+
const Zt = new Form$4(qe);
|
|
18735
|
+
Zt.parse(Le, {
|
|
18717
18736
|
readOnly: p,
|
|
18718
18737
|
values: {
|
|
18719
18738
|
...Tt,
|
|
18720
|
-
...
|
|
18739
|
+
...Ze()
|
|
18721
18740
|
}
|
|
18722
|
-
}), W(
|
|
18723
|
-
},
|
|
18724
|
-
elementHasLostFocus:
|
|
18741
|
+
}), W(Zt), ae && Zt.string && ((ln = ae.setTitle) == null || ln.call(ae, Zt.string));
|
|
18742
|
+
}, In = async ({
|
|
18743
|
+
elementHasLostFocus: qe = !1
|
|
18725
18744
|
}) => {
|
|
18726
18745
|
if (he.current)
|
|
18727
18746
|
return;
|
|
18728
|
-
const
|
|
18747
|
+
const Le = getTouchedValues({
|
|
18729
18748
|
source: Q.current,
|
|
18730
|
-
target:
|
|
18749
|
+
target: Xt(U),
|
|
18731
18750
|
fields: U
|
|
18732
|
-
}), Tt = Object.keys(
|
|
18751
|
+
}), Tt = Object.keys(Le);
|
|
18733
18752
|
if (Tt.length !== 0) {
|
|
18734
18753
|
if (checkFieldsType({
|
|
18735
18754
|
changedFields: Tt,
|
|
18736
18755
|
fields: U,
|
|
18737
18756
|
types: ["text", "codeeditor", "email", "url", "char", "float", "float_time", "integer", "many2one"]
|
|
18738
|
-
}) &&
|
|
18757
|
+
}) && qe !== !0)
|
|
18739
18758
|
return;
|
|
18740
18759
|
{
|
|
18741
|
-
const
|
|
18742
|
-
Q.current =
|
|
18760
|
+
const Zt = processValues(K.getFieldsValue(!0), U);
|
|
18761
|
+
Q.current = Zt, d == null || d(Zt), Fe == null || Fe(!0), tr(Tt);
|
|
18743
18762
|
}
|
|
18744
18763
|
}
|
|
18745
|
-
},
|
|
18764
|
+
}, Wn = debounce_1(In, 100), tr = async (qe) => {
|
|
18746
18765
|
try {
|
|
18747
|
-
for (let
|
|
18748
|
-
const Tt = Le
|
|
18749
|
-
await
|
|
18766
|
+
for (let Le = 0; Le < qe.length; Le += 1) {
|
|
18767
|
+
const Tt = qe[Le];
|
|
18768
|
+
await nr(Tt);
|
|
18750
18769
|
}
|
|
18751
|
-
} catch (
|
|
18752
|
-
showDialog$8(
|
|
18770
|
+
} catch (Le) {
|
|
18771
|
+
showDialog$8(Le);
|
|
18753
18772
|
}
|
|
18754
|
-
},
|
|
18755
|
-
const
|
|
18756
|
-
if (!
|
|
18757
|
-
|
|
18773
|
+
}, nr = async (qe) => {
|
|
18774
|
+
const Le = L == null ? void 0 : L.onChangeFields[qe];
|
|
18775
|
+
if (!Le) {
|
|
18776
|
+
pn({
|
|
18758
18777
|
fields: U,
|
|
18759
18778
|
arch: H,
|
|
18760
|
-
values:
|
|
18779
|
+
values: Xt(U)
|
|
18761
18780
|
});
|
|
18762
18781
|
return;
|
|
18763
18782
|
}
|
|
18764
18783
|
const Tt = getOnChangePayload({
|
|
18765
18784
|
values: {
|
|
18766
|
-
...
|
|
18785
|
+
...Xt(U),
|
|
18767
18786
|
context: {
|
|
18768
18787
|
...I,
|
|
18769
18788
|
...L == null ? void 0 : L.context
|
|
18770
18789
|
}
|
|
18771
18790
|
},
|
|
18772
|
-
|
|
18773
|
-
|
|
18791
|
+
parentValues: M == null ? void 0 : M(),
|
|
18792
|
+
onChangeFieldActionArgs: Le.args
|
|
18793
|
+
}), Zt = await ConnectionProvider.getHandler().executeOnChange({
|
|
18774
18794
|
model: o,
|
|
18775
|
-
action:
|
|
18776
|
-
ids:
|
|
18795
|
+
action: Le.method,
|
|
18796
|
+
ids: it() ? [it()] : [],
|
|
18777
18797
|
payload: Tt,
|
|
18778
18798
|
fields: U
|
|
18779
18799
|
});
|
|
18780
|
-
if (
|
|
18800
|
+
if (Zt.value) {
|
|
18781
18801
|
const ln = {
|
|
18782
|
-
...
|
|
18783
|
-
...
|
|
18802
|
+
...Xt(U),
|
|
18803
|
+
...Zt.value
|
|
18784
18804
|
};
|
|
18785
|
-
|
|
18805
|
+
pn({
|
|
18786
18806
|
fields: U,
|
|
18787
18807
|
arch: H,
|
|
18788
18808
|
values: ln
|
|
@@ -18792,161 +18812,161 @@ function Form(e, r) {
|
|
|
18792
18812
|
reset: !1
|
|
18793
18813
|
});
|
|
18794
18814
|
}
|
|
18795
|
-
if (
|
|
18815
|
+
if (Zt.warning && Zt.warning.title && Zt.warning.message && !te.current) {
|
|
18796
18816
|
const {
|
|
18797
18817
|
title: ln,
|
|
18798
18818
|
message: Ln
|
|
18799
|
-
} =
|
|
18819
|
+
} = Zt.warning;
|
|
18800
18820
|
te.current = !0, showDialog$4(ln, Ln, () => {
|
|
18801
18821
|
te.current = !1;
|
|
18802
18822
|
});
|
|
18803
18823
|
}
|
|
18804
|
-
if (
|
|
18824
|
+
if (Zt.domain && Object.keys(Zt.domain).length > 0) {
|
|
18805
18825
|
const ln = mergeFieldsDomain({
|
|
18806
|
-
fieldsDomain:
|
|
18826
|
+
fieldsDomain: Zt.domain,
|
|
18807
18827
|
fields: U
|
|
18808
18828
|
});
|
|
18809
|
-
|
|
18829
|
+
pn({
|
|
18810
18830
|
fields: ln,
|
|
18811
18831
|
arch: H,
|
|
18812
|
-
values:
|
|
18832
|
+
values: Xt(ln)
|
|
18813
18833
|
}), re(ln);
|
|
18814
18834
|
}
|
|
18815
18835
|
};
|
|
18816
|
-
async function
|
|
18817
|
-
action:
|
|
18818
|
-
context:
|
|
18836
|
+
async function zn({
|
|
18837
|
+
action: qe,
|
|
18838
|
+
context: Le
|
|
18819
18839
|
}) {
|
|
18820
18840
|
const Tt = await ConnectionProvider.getHandler().execute({
|
|
18821
18841
|
model: o,
|
|
18822
|
-
action:
|
|
18823
|
-
payload: [
|
|
18842
|
+
action: qe,
|
|
18843
|
+
payload: [it()],
|
|
18824
18844
|
context: {
|
|
18825
|
-
...
|
|
18845
|
+
...Le,
|
|
18826
18846
|
...L == null ? void 0 : L.context,
|
|
18827
18847
|
...I
|
|
18828
18848
|
}
|
|
18829
18849
|
});
|
|
18830
18850
|
if (typeof Tt == "object" && Tt !== null && Object.keys(Tt).length === 0 && w)
|
|
18831
|
-
|
|
18851
|
+
Yt == null || Yt(it(), xt(), kt());
|
|
18832
18852
|
else if (Tt.type && Tt.type === "ir.actions.act_window_close")
|
|
18833
|
-
|
|
18853
|
+
Yt == null || Yt(it(), xt(), kt());
|
|
18834
18854
|
else if (Tt.type) {
|
|
18835
|
-
let
|
|
18836
|
-
Tt.context && (
|
|
18855
|
+
let Zt = {};
|
|
18856
|
+
Tt.context && (Zt = parseContext({
|
|
18837
18857
|
context: Tt.context,
|
|
18838
18858
|
fields: U,
|
|
18839
|
-
values:
|
|
18859
|
+
values: xt()
|
|
18840
18860
|
})), await Yn({
|
|
18841
18861
|
actionData: Tt,
|
|
18842
18862
|
context: {
|
|
18843
|
-
...
|
|
18844
|
-
...
|
|
18863
|
+
...Le,
|
|
18864
|
+
...Zt
|
|
18845
18865
|
}
|
|
18846
18866
|
});
|
|
18847
18867
|
} else
|
|
18848
|
-
await
|
|
18868
|
+
await an();
|
|
18849
18869
|
}
|
|
18850
|
-
async function
|
|
18851
|
-
action:
|
|
18870
|
+
async function Gn({
|
|
18871
|
+
action: qe
|
|
18852
18872
|
}) {
|
|
18853
|
-
const
|
|
18873
|
+
const Le = await ConnectionProvider.getHandler().executeWorkflow({
|
|
18854
18874
|
model: o,
|
|
18855
|
-
action:
|
|
18856
|
-
payload:
|
|
18875
|
+
action: qe,
|
|
18876
|
+
payload: it()
|
|
18857
18877
|
});
|
|
18858
|
-
|
|
18878
|
+
Le.type && Le.type === "ir.actions.act_window_close" ? Yt == null || Yt(it(), xt(), kt()) : await an();
|
|
18859
18879
|
}
|
|
18860
|
-
async function
|
|
18861
|
-
action:
|
|
18862
|
-
context:
|
|
18880
|
+
async function rr({
|
|
18881
|
+
action: qe,
|
|
18882
|
+
context: Le
|
|
18863
18883
|
}) {
|
|
18864
18884
|
const Tt = (await ConnectionProvider.getHandler().readObjects({
|
|
18865
18885
|
model: "ir.actions.actions",
|
|
18866
|
-
ids: [parseInt(
|
|
18886
|
+
ids: [parseInt(qe)],
|
|
18867
18887
|
context: I
|
|
18868
18888
|
}))[0];
|
|
18869
18889
|
await Yn({
|
|
18870
18890
|
actionData: Tt,
|
|
18871
|
-
context:
|
|
18891
|
+
context: Le
|
|
18872
18892
|
});
|
|
18873
18893
|
}
|
|
18874
18894
|
async function Yn({
|
|
18875
|
-
actionData:
|
|
18876
|
-
context:
|
|
18895
|
+
actionData: qe,
|
|
18896
|
+
context: Le
|
|
18877
18897
|
}) {
|
|
18878
18898
|
const {
|
|
18879
18899
|
closeParent: Tt
|
|
18880
|
-
} = await (
|
|
18881
|
-
actionData:
|
|
18900
|
+
} = await (Ht == null ? void 0 : Ht({
|
|
18901
|
+
actionData: qe,
|
|
18882
18902
|
fields: U,
|
|
18883
|
-
values:
|
|
18903
|
+
values: xt(),
|
|
18884
18904
|
context: {
|
|
18885
18905
|
...I,
|
|
18886
18906
|
...L == null ? void 0 : L.context,
|
|
18887
|
-
...
|
|
18907
|
+
...Le
|
|
18888
18908
|
},
|
|
18889
18909
|
onRefreshParentValues: () => {
|
|
18890
|
-
|
|
18910
|
+
an();
|
|
18891
18911
|
}
|
|
18892
18912
|
})) || {};
|
|
18893
|
-
!O && Tt && (
|
|
18913
|
+
!O && Tt && (Yt == null || Yt(it(), xt(), kt()));
|
|
18894
18914
|
}
|
|
18895
|
-
function
|
|
18896
|
-
|
|
18915
|
+
function Kn() {
|
|
18916
|
+
In({
|
|
18897
18917
|
elementHasLostFocus: !0
|
|
18898
18918
|
});
|
|
18899
18919
|
}
|
|
18900
|
-
async function
|
|
18901
|
-
type:
|
|
18902
|
-
action:
|
|
18920
|
+
async function Zn({
|
|
18921
|
+
type: qe,
|
|
18922
|
+
action: Le,
|
|
18903
18923
|
context: Tt
|
|
18904
18924
|
}) {
|
|
18905
|
-
if (
|
|
18906
|
-
|
|
18925
|
+
if (qe === "cancel") {
|
|
18926
|
+
Pe == null || Pe();
|
|
18907
18927
|
return;
|
|
18908
18928
|
}
|
|
18909
|
-
if (await
|
|
18929
|
+
if (await gn()) {
|
|
18910
18930
|
showDialog$5(G);
|
|
18911
18931
|
return;
|
|
18912
18932
|
}
|
|
18913
18933
|
try {
|
|
18914
18934
|
await sn({
|
|
18915
18935
|
callOnSubmitSucceed: !1
|
|
18916
|
-
}),
|
|
18917
|
-
action:
|
|
18936
|
+
}), qe === "object" ? await zn({
|
|
18937
|
+
action: Le,
|
|
18918
18938
|
context: Tt
|
|
18919
|
-
}) :
|
|
18920
|
-
action:
|
|
18921
|
-
}) :
|
|
18922
|
-
action:
|
|
18939
|
+
}) : qe === "workflow" ? await Gn({
|
|
18940
|
+
action: Le
|
|
18941
|
+
}) : qe === "action" && await rr({
|
|
18942
|
+
action: Le,
|
|
18923
18943
|
context: Tt
|
|
18924
18944
|
});
|
|
18925
|
-
} catch (
|
|
18926
|
-
showDialog$8(
|
|
18945
|
+
} catch (Zt) {
|
|
18946
|
+
showDialog$8(Zt);
|
|
18927
18947
|
}
|
|
18928
18948
|
}
|
|
18929
|
-
const
|
|
18949
|
+
const or = () => !L && !B ? /* @__PURE__ */ jsx(Spin, {}) : !o && !v || !x ? null : /* @__PURE__ */ jsx(Fragment, {
|
|
18930
18950
|
children: /* @__PURE__ */ jsx(FormProvider$2, {
|
|
18931
|
-
getValues:
|
|
18932
|
-
getPlainValues:
|
|
18951
|
+
getValues: xt,
|
|
18952
|
+
getPlainValues: Pt,
|
|
18933
18953
|
getFields: Qt,
|
|
18934
18954
|
domain: y,
|
|
18935
18955
|
activeId: a,
|
|
18936
18956
|
activeModel: o,
|
|
18937
|
-
setFieldValue:
|
|
18938
|
-
getFieldValue:
|
|
18939
|
-
executeButtonAction:
|
|
18940
|
-
getContext:
|
|
18957
|
+
setFieldValue: tn,
|
|
18958
|
+
getFieldValue: un,
|
|
18959
|
+
executeButtonAction: Zn,
|
|
18960
|
+
getContext: cn,
|
|
18941
18961
|
setOriginalValue: fn,
|
|
18942
18962
|
submitForm: sn,
|
|
18943
|
-
fetchValues:
|
|
18944
|
-
formHasChanges:
|
|
18945
|
-
elementHasLostFocus:
|
|
18963
|
+
fetchValues: an,
|
|
18964
|
+
formHasChanges: en,
|
|
18965
|
+
elementHasLostFocus: Kn,
|
|
18946
18966
|
children: /* @__PURE__ */ jsx(Form$3, {
|
|
18947
18967
|
form: K,
|
|
18948
18968
|
onFieldsChange: () => {
|
|
18949
|
-
|
|
18969
|
+
Wn({
|
|
18950
18970
|
elementHasLostFocus: !1
|
|
18951
18971
|
});
|
|
18952
18972
|
},
|
|
@@ -18957,7 +18977,7 @@ function Form(e, r) {
|
|
|
18957
18977
|
})
|
|
18958
18978
|
})
|
|
18959
18979
|
})
|
|
18960
|
-
}),
|
|
18980
|
+
}), ar = () => /* @__PURE__ */ jsxs(Fragment, {
|
|
18961
18981
|
children: [/* @__PURE__ */ jsx(Divider, {}), /* @__PURE__ */ jsx(Row, {
|
|
18962
18982
|
justify: "end",
|
|
18963
18983
|
children: /* @__PURE__ */ jsxs(Space, {
|
|
@@ -18965,7 +18985,7 @@ function Form(e, r) {
|
|
|
18965
18985
|
icon: /* @__PURE__ */ jsx(CloseOutlined$4, {}),
|
|
18966
18986
|
disabled: E,
|
|
18967
18987
|
onClick: async () => {
|
|
18968
|
-
await
|
|
18988
|
+
await _n();
|
|
18969
18989
|
},
|
|
18970
18990
|
children: "Cancel"
|
|
18971
18991
|
}), /* @__PURE__ */ jsx(Button$1, {
|
|
@@ -18983,21 +19003,21 @@ function Form(e, r) {
|
|
|
18983
19003
|
});
|
|
18984
19004
|
return x ? /* @__PURE__ */ jsx(Measure, {
|
|
18985
19005
|
bounds: !0,
|
|
18986
|
-
onResize: (
|
|
18987
|
-
var
|
|
18988
|
-
J((
|
|
19006
|
+
onResize: (qe) => {
|
|
19007
|
+
var Le;
|
|
19008
|
+
J((Le = qe.bounds) == null ? void 0 : Le.width);
|
|
18989
19009
|
},
|
|
18990
19010
|
children: ({
|
|
18991
|
-
measureRef:
|
|
19011
|
+
measureRef: qe
|
|
18992
19012
|
}) => /* @__PURE__ */ jsxs("div", {
|
|
18993
19013
|
className: "pb-2",
|
|
18994
|
-
ref:
|
|
19014
|
+
ref: qe,
|
|
18995
19015
|
children: [B && /* @__PURE__ */ jsx(Alert, {
|
|
18996
19016
|
className: "mt-10 mb-20",
|
|
18997
19017
|
message: JSON.stringify(B),
|
|
18998
19018
|
type: "error",
|
|
18999
19019
|
banner: !0
|
|
19000
|
-
}),
|
|
19020
|
+
}), or(), c && ar()]
|
|
19001
19021
|
})
|
|
19002
19022
|
}) : null;
|
|
19003
19023
|
}
|
|
@@ -19929,7 +19949,7 @@ function Tree(e) {
|
|
|
19929
19949
|
return null;
|
|
19930
19950
|
let re = [], ae = ((ne = p == null ? void 0 : p.selectedRowKeys) == null ? void 0 : ne.length) > 0 ? I.filter((J) => p == null ? void 0 : p.selectedRowKeys.includes(J.id)) : I;
|
|
19931
19951
|
return U.forEach((J) => {
|
|
19932
|
-
const oe = ae.reduce((ie,
|
|
19952
|
+
const oe = ae.reduce((ie, ce) => ce[J.field] && !isNaN(ce[J.field]) ? ie + ce[J.field] : ie, 0);
|
|
19933
19953
|
re.push(`${J.label}: ${Math.round(oe * 100) / 100}`);
|
|
19934
19954
|
}), /* @__PURE__ */ jsx("div", {
|
|
19935
19955
|
className: "p-1 pb-0 pl-2 mt-2 bg-gray-50",
|
|
@@ -19998,39 +20018,39 @@ function SearchTree(e, r) {
|
|
|
19998
20018
|
selectedRowItems: J = void 0,
|
|
19999
20019
|
setSelectedRowItems: oe = void 0,
|
|
20000
20020
|
searchParams: ie = [],
|
|
20001
|
-
setSearchParams:
|
|
20021
|
+
setSearchParams: ce = void 0,
|
|
20002
20022
|
searchVisible: me = !0,
|
|
20003
20023
|
setSearchVisible: Q = void 0,
|
|
20004
20024
|
sorter: te = void 0,
|
|
20005
20025
|
setSorter: he = void 0,
|
|
20006
20026
|
setTotalItems: ve = void 0,
|
|
20007
|
-
setSearchTreeNameSearch:
|
|
20027
|
+
setSearchTreeNameSearch: Oe = void 0,
|
|
20008
20028
|
setTreeIsLoading: D = void 0,
|
|
20009
20029
|
searchValues: M = {},
|
|
20010
|
-
setSearchValues:
|
|
20030
|
+
setSearchValues: pe = void 0,
|
|
20011
20031
|
limit: ge = DEFAULT_SEARCH_LIMIT$1,
|
|
20012
20032
|
setLimit: Fe = void 0
|
|
20013
20033
|
} = (p ? z : {}) || {}, {
|
|
20014
|
-
submit:
|
|
20034
|
+
submit: Te,
|
|
20015
20035
|
clear: Re,
|
|
20016
20036
|
fetchResults: Ae,
|
|
20017
|
-
tableRefreshing:
|
|
20018
|
-
searchFilterLoading:
|
|
20019
|
-
searchError:
|
|
20020
|
-
page:
|
|
20021
|
-
offset:
|
|
20022
|
-
getResults:
|
|
20023
|
-
requestPageChange:
|
|
20024
|
-
changeSort:
|
|
20025
|
-
fetchChildrenForRecord:
|
|
20026
|
-
colorsForResults:
|
|
20027
|
-
totalItems:
|
|
20037
|
+
tableRefreshing: et,
|
|
20038
|
+
searchFilterLoading: Ht,
|
|
20039
|
+
searchError: Jt,
|
|
20040
|
+
page: Yt,
|
|
20041
|
+
offset: Pe,
|
|
20042
|
+
getResults: jt,
|
|
20043
|
+
requestPageChange: it,
|
|
20044
|
+
changeSort: Qt,
|
|
20045
|
+
fetchChildrenForRecord: xt,
|
|
20046
|
+
colorsForResults: Pt,
|
|
20047
|
+
totalItems: kt
|
|
20028
20048
|
} = useSearch({
|
|
20029
20049
|
model: y,
|
|
20030
|
-
setSearchTreeNameSearch:
|
|
20050
|
+
setSearchTreeNameSearch: Oe,
|
|
20031
20051
|
setSelectedRowItems: oe,
|
|
20032
|
-
setSearchParams:
|
|
20033
|
-
setSearchValues:
|
|
20052
|
+
setSearchParams: ce,
|
|
20053
|
+
setSearchValues: pe,
|
|
20034
20054
|
searchParams: ie,
|
|
20035
20055
|
setSearchVisible: Q,
|
|
20036
20056
|
setTreeIsLoading: D,
|
|
@@ -20058,40 +20078,40 @@ function SearchTree(e, r) {
|
|
|
20058
20078
|
getDomain: () => d
|
|
20059
20079
|
})), useEffect(() => {
|
|
20060
20080
|
!C || f && (I.current = !1, Ae());
|
|
20061
|
-
}, [
|
|
20062
|
-
const
|
|
20081
|
+
}, [Yt, Pe, C, f, c]);
|
|
20082
|
+
const cn = async () => {
|
|
20063
20083
|
w(!1), v(!0), P(void 0), D == null || D(!0);
|
|
20064
20084
|
try {
|
|
20065
|
-
await
|
|
20066
|
-
} catch (
|
|
20067
|
-
P(
|
|
20085
|
+
await Ze(), w(!0);
|
|
20086
|
+
} catch (an) {
|
|
20087
|
+
P(an);
|
|
20068
20088
|
} finally {
|
|
20069
20089
|
v(!1), D == null || D(!1);
|
|
20070
20090
|
}
|
|
20071
|
-
},
|
|
20091
|
+
}, Ze = async () => {
|
|
20072
20092
|
x(o);
|
|
20073
|
-
let
|
|
20074
|
-
a || (
|
|
20093
|
+
let an = a;
|
|
20094
|
+
a || (an = await ConnectionProvider.getHandler().getView({
|
|
20075
20095
|
model: o,
|
|
20076
20096
|
type: "form",
|
|
20077
20097
|
context: h
|
|
20078
20098
|
}));
|
|
20079
|
-
let
|
|
20080
|
-
s || (
|
|
20099
|
+
let fn = s;
|
|
20100
|
+
s || (fn = await ConnectionProvider.getHandler().getView({
|
|
20081
20101
|
model: o,
|
|
20082
20102
|
type: "tree",
|
|
20083
20103
|
context: h
|
|
20084
|
-
})), G(
|
|
20104
|
+
})), G(an), S(fn);
|
|
20085
20105
|
};
|
|
20086
20106
|
useEffect(() => {
|
|
20087
|
-
|
|
20107
|
+
cn();
|
|
20088
20108
|
}, [o]);
|
|
20089
|
-
const
|
|
20090
|
-
Fe == null || Fe(
|
|
20091
|
-
},
|
|
20109
|
+
const _t = (an) => {
|
|
20110
|
+
Fe == null || Fe(an);
|
|
20111
|
+
}, en = async (an) => {
|
|
20092
20112
|
const {
|
|
20093
|
-
id:
|
|
20094
|
-
} =
|
|
20113
|
+
id: fn
|
|
20114
|
+
} = an;
|
|
20095
20115
|
L.current || (L.current = await ConnectionProvider.getHandler().treeButOpen({
|
|
20096
20116
|
id: O.view_id,
|
|
20097
20117
|
model: y,
|
|
@@ -20102,35 +20122,35 @@ function SearchTree(e, r) {
|
|
|
20102
20122
|
actionData: _n,
|
|
20103
20123
|
fields: O.fields,
|
|
20104
20124
|
values: {
|
|
20105
|
-
active_id:
|
|
20106
|
-
...
|
|
20125
|
+
active_id: fn,
|
|
20126
|
+
...an
|
|
20107
20127
|
},
|
|
20108
20128
|
context: h
|
|
20109
20129
|
}));
|
|
20110
|
-
},
|
|
20130
|
+
}, Xt = async (an) => {
|
|
20111
20131
|
const {
|
|
20112
|
-
id:
|
|
20113
|
-
} =
|
|
20132
|
+
id: fn
|
|
20133
|
+
} = an;
|
|
20114
20134
|
if (O != null && O.isExpandable) {
|
|
20115
20135
|
try {
|
|
20116
|
-
await
|
|
20136
|
+
await en(an);
|
|
20117
20137
|
} catch (_n) {
|
|
20118
20138
|
showDialog$8(_n);
|
|
20119
20139
|
}
|
|
20120
20140
|
return;
|
|
20121
20141
|
}
|
|
20122
20142
|
l({
|
|
20123
|
-
id:
|
|
20143
|
+
id: fn,
|
|
20124
20144
|
model: y,
|
|
20125
20145
|
formView: T,
|
|
20126
20146
|
treeView: O
|
|
20127
20147
|
});
|
|
20128
20148
|
};
|
|
20129
|
-
function tn(
|
|
20130
|
-
const
|
|
20131
|
-
oe == null || oe(
|
|
20149
|
+
function tn(an) {
|
|
20150
|
+
const fn = jt().filter((_n) => an.includes(_n.id));
|
|
20151
|
+
oe == null || oe(fn), m == null || m(an);
|
|
20132
20152
|
}
|
|
20133
|
-
function
|
|
20153
|
+
function un() {
|
|
20134
20154
|
return O != null && O.isExpandable ? W - 160 : W - (B + 210);
|
|
20135
20155
|
}
|
|
20136
20156
|
const gn = () => !O || !T ? null : /* @__PURE__ */ jsxs(Fragment, {
|
|
@@ -20142,38 +20162,38 @@ function SearchTree(e, r) {
|
|
|
20142
20162
|
searchFields: mergeSearchFields([T.search_fields, O.search_fields]),
|
|
20143
20163
|
onClear: Re,
|
|
20144
20164
|
limit: ge,
|
|
20145
|
-
offset:
|
|
20146
|
-
isSearching:
|
|
20147
|
-
onSubmit:
|
|
20148
|
-
onLimitChange:
|
|
20165
|
+
offset: Pe,
|
|
20166
|
+
isSearching: Ht,
|
|
20167
|
+
onSubmit: Te,
|
|
20168
|
+
onLimitChange: _t,
|
|
20149
20169
|
setSearchFilterHeight: N,
|
|
20150
|
-
searchError:
|
|
20170
|
+
searchError: Jt,
|
|
20151
20171
|
searchVisible: me,
|
|
20152
20172
|
searchValues: M
|
|
20153
20173
|
}), /* @__PURE__ */ jsx(Tree, {
|
|
20154
|
-
total:
|
|
20174
|
+
total: kt,
|
|
20155
20175
|
limit: ge,
|
|
20156
|
-
page:
|
|
20176
|
+
page: Yt,
|
|
20157
20177
|
treeView: O,
|
|
20158
|
-
results:
|
|
20159
|
-
onRequestPageChange:
|
|
20160
|
-
loading:
|
|
20161
|
-
onRowClicked:
|
|
20162
|
-
scrollY: u ||
|
|
20163
|
-
colorsForResults:
|
|
20178
|
+
results: jt(),
|
|
20179
|
+
onRequestPageChange: it,
|
|
20180
|
+
loading: et,
|
|
20181
|
+
onRowClicked: Xt,
|
|
20182
|
+
scrollY: u || un(),
|
|
20183
|
+
colorsForResults: Pt,
|
|
20164
20184
|
rowSelection: {
|
|
20165
|
-
selectedRowKeys: J == null ? void 0 : J.map((
|
|
20185
|
+
selectedRowKeys: J == null ? void 0 : J.map((an) => an.id),
|
|
20166
20186
|
onChange: tn
|
|
20167
20187
|
},
|
|
20168
20188
|
sorter: te,
|
|
20169
|
-
onChangeSort:
|
|
20170
|
-
onFetchChildrenForRecord: O.isExpandable ?
|
|
20189
|
+
onChangeSort: Qt,
|
|
20190
|
+
onFetchChildrenForRecord: O.isExpandable ? xt : void 0,
|
|
20171
20191
|
childField: O.field_parent
|
|
20172
20192
|
})]
|
|
20173
|
-
}),
|
|
20174
|
-
return
|
|
20193
|
+
}), mn = E || Jt;
|
|
20194
|
+
return mn ? /* @__PURE__ */ jsx(Alert, {
|
|
20175
20195
|
className: "mt-10",
|
|
20176
|
-
message:
|
|
20196
|
+
message: mn,
|
|
20177
20197
|
type: "error",
|
|
20178
20198
|
banner: !0
|
|
20179
20199
|
}) : /* @__PURE__ */ jsx("div", {
|
|
@@ -20359,7 +20379,7 @@ const SearchTree$1 = forwardRef(SearchTree), SearchModal = (e) => {
|
|
|
20359
20379
|
}
|
|
20360
20380
|
}
|
|
20361
20381
|
}, oe = async (te) => {
|
|
20362
|
-
if (await
|
|
20382
|
+
if (await ce(), K.current && K.current.length > 0) {
|
|
20363
20383
|
const he = await ConnectionProvider.getHandler().searchAllIds({
|
|
20364
20384
|
params: K.current,
|
|
20365
20385
|
model: l,
|
|
@@ -20392,13 +20412,14 @@ const SearchTree$1 = forwardRef(SearchTree), SearchModal = (e) => {
|
|
|
20392
20412
|
w(!1);
|
|
20393
20413
|
}
|
|
20394
20414
|
};
|
|
20395
|
-
async function
|
|
20415
|
+
async function ce() {
|
|
20396
20416
|
f && (K.current = await ConnectionProvider.getHandler().evalDomain({
|
|
20397
20417
|
domain: f,
|
|
20398
20418
|
values: transformPlainMany2Ones({
|
|
20399
20419
|
fields: B(),
|
|
20400
20420
|
values: P()
|
|
20401
20421
|
}),
|
|
20422
|
+
fields: B(),
|
|
20402
20423
|
context: N()
|
|
20403
20424
|
})), E && E.length > 0 && (K.current = K.current.concat(transformDomainForChildWidget({
|
|
20404
20425
|
domain: E,
|
|
@@ -22283,7 +22304,7 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22283
22304
|
function H() {
|
|
22284
22305
|
d && K(g());
|
|
22285
22306
|
}
|
|
22286
|
-
var z = useVisibleStatus(o, H), U = _slicedToArray(z, 2), re = U[0], ae = U[1], ne = useState$1(0), J = _slicedToArray(ne, 2), oe = J[0], ie = J[1],
|
|
22307
|
+
var z = useVisibleStatus(o, H), U = _slicedToArray(z, 2), re = U[0], ae = U[1], ne = useState$1(0), J = _slicedToArray(ne, 2), oe = J[0], ie = J[1], ce = useRef();
|
|
22287
22308
|
useLayoutEffect$2(function() {
|
|
22288
22309
|
re === "alignPre" && ie(0);
|
|
22289
22310
|
}, [re]);
|
|
@@ -22291,31 +22312,31 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22291
22312
|
return m || g;
|
|
22292
22313
|
}
|
|
22293
22314
|
function Q() {
|
|
22294
|
-
var
|
|
22295
|
-
(
|
|
22315
|
+
var pe;
|
|
22316
|
+
(pe = S.current) === null || pe === void 0 || pe.forceAlign();
|
|
22296
22317
|
}
|
|
22297
|
-
function te(
|
|
22318
|
+
function te(pe, ge) {
|
|
22298
22319
|
var Fe = v(ge);
|
|
22299
|
-
P !== Fe && B(Fe), ie(function(
|
|
22300
|
-
return
|
|
22301
|
-
}), re === "align" && (C == null || C(
|
|
22320
|
+
P !== Fe && B(Fe), ie(function(Te) {
|
|
22321
|
+
return Te + 1;
|
|
22322
|
+
}), re === "align" && (C == null || C(pe, ge));
|
|
22302
22323
|
}
|
|
22303
22324
|
useLayoutEffect$2(function() {
|
|
22304
22325
|
re === "align" && (oe < 3 ? Q() : ae(function() {
|
|
22305
|
-
var
|
|
22306
|
-
(
|
|
22326
|
+
var pe;
|
|
22327
|
+
(pe = ce.current) === null || pe === void 0 || pe.call(ce);
|
|
22307
22328
|
}));
|
|
22308
22329
|
}, [oe]);
|
|
22309
22330
|
var he = _objectSpread2$g({}, getMotion(e));
|
|
22310
|
-
["onAppearEnd", "onEnterEnd", "onLeaveEnd"].forEach(function(
|
|
22311
|
-
var ge = he[
|
|
22312
|
-
he[
|
|
22313
|
-
return ae(), ge == null ? void 0 : ge(Fe,
|
|
22331
|
+
["onAppearEnd", "onEnterEnd", "onLeaveEnd"].forEach(function(pe) {
|
|
22332
|
+
var ge = he[pe];
|
|
22333
|
+
he[pe] = function(Fe, Te) {
|
|
22334
|
+
return ae(), ge == null ? void 0 : ge(Fe, Te);
|
|
22314
22335
|
};
|
|
22315
22336
|
});
|
|
22316
22337
|
function ve() {
|
|
22317
|
-
return new Promise(function(
|
|
22318
|
-
|
|
22338
|
+
return new Promise(function(pe) {
|
|
22339
|
+
ce.current = pe;
|
|
22319
22340
|
});
|
|
22320
22341
|
}
|
|
22321
22342
|
React$n.useEffect(function() {
|
|
@@ -22328,7 +22349,7 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22328
22349
|
}
|
|
22329
22350
|
};
|
|
22330
22351
|
});
|
|
22331
|
-
var
|
|
22352
|
+
var Oe = _objectSpread2$g(_objectSpread2$g({}, W), {}, {
|
|
22332
22353
|
zIndex: u,
|
|
22333
22354
|
opacity: re === "motion" || re === "stable" || !o ? void 0 : 0,
|
|
22334
22355
|
pointerEvents: !o && re !== "stable" ? "none" : void 0
|
|
@@ -22347,8 +22368,8 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22347
22368
|
onEnterPrepare: ve,
|
|
22348
22369
|
removeOnLeave: f,
|
|
22349
22370
|
forceRender: p,
|
|
22350
|
-
children: function(
|
|
22351
|
-
var Fe =
|
|
22371
|
+
children: function(pe, ge) {
|
|
22372
|
+
var Fe = pe.className, Te = pe.style, Re = classNames(a, s, P, Fe);
|
|
22352
22373
|
return /* @__PURE__ */ jsx(RcAlign, {
|
|
22353
22374
|
target: me(),
|
|
22354
22375
|
ref: S,
|
|
@@ -22364,7 +22385,7 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22364
22385
|
onMouseDownCapture: y,
|
|
22365
22386
|
onTouchStartCapture: x,
|
|
22366
22387
|
onClick: O,
|
|
22367
|
-
style: _objectSpread2$g(_objectSpread2$g({},
|
|
22388
|
+
style: _objectSpread2$g(_objectSpread2$g({}, Te), Oe),
|
|
22368
22389
|
children: M
|
|
22369
22390
|
})
|
|
22370
22391
|
}, "popup");
|
|
@@ -23176,72 +23197,72 @@ placements$1.default = _default$1;
|
|
|
23176
23197
|
}
|
|
23177
23198
|
var O = /* @__PURE__ */ f.forwardRef(function(T, G) {
|
|
23178
23199
|
var E, P = f.useContext(p.ConfigContext), B = P.getPopupContainer, N = P.getPrefixCls, L = P.direction;
|
|
23179
|
-
process.env.NODE_ENV !== "production" && [["visible", "open"], ["defaultVisible", "defaultOpen"], ["onVisibleChange", "onOpenChange"], ["afterVisibleChange", "afterOpenChange"]].forEach(function(
|
|
23180
|
-
var
|
|
23181
|
-
process.env.NODE_ENV !== "production" && (0, C.default)(!(
|
|
23200
|
+
process.env.NODE_ENV !== "production" && [["visible", "open"], ["defaultVisible", "defaultOpen"], ["onVisibleChange", "onOpenChange"], ["afterVisibleChange", "afterOpenChange"]].forEach(function(Qt) {
|
|
23201
|
+
var xt = (0, s.default)(Qt, 2), Pt = xt[0], kt = xt[1];
|
|
23202
|
+
process.env.NODE_ENV !== "production" && (0, C.default)(!(Pt in T), "Tooltip", "`".concat(Pt, "` is deprecated which will be removed in next major version, please use `").concat(kt, "` instead."));
|
|
23182
23203
|
});
|
|
23183
23204
|
var W = (0, d.default)(!1, {
|
|
23184
23205
|
value: T.open !== void 0 ? T.open : T.visible,
|
|
23185
23206
|
defaultValue: T.defaultOpen !== void 0 ? T.defaultOpen : T.defaultVisible
|
|
23186
23207
|
}), K = (0, s.default)(W, 2), H = K[0], z = K[1], U = function() {
|
|
23187
|
-
var
|
|
23188
|
-
return !
|
|
23189
|
-
}, re = function(
|
|
23190
|
-
var
|
|
23191
|
-
z(U() ? !1 :
|
|
23208
|
+
var xt = T.title, Pt = T.overlay;
|
|
23209
|
+
return !xt && !Pt && xt !== 0;
|
|
23210
|
+
}, re = function(xt) {
|
|
23211
|
+
var Pt, kt;
|
|
23212
|
+
z(U() ? !1 : xt), U() || ((Pt = T.onOpenChange) === null || Pt === void 0 || Pt.call(T, xt), (kt = T.onVisibleChange) === null || kt === void 0 || kt.call(T, xt));
|
|
23192
23213
|
}, ae = function() {
|
|
23193
|
-
var
|
|
23194
|
-
return
|
|
23195
|
-
arrowPointAtCenter:
|
|
23196
|
-
autoAdjustOverflow:
|
|
23214
|
+
var xt = T.builtinPlacements, Pt = T.arrowPointAtCenter, kt = Pt === void 0 ? !1 : Pt, cn = T.autoAdjustOverflow, Ze = cn === void 0 ? !0 : cn;
|
|
23215
|
+
return xt || (0, g.default)({
|
|
23216
|
+
arrowPointAtCenter: kt,
|
|
23217
|
+
autoAdjustOverflow: Ze
|
|
23197
23218
|
});
|
|
23198
|
-
}, ne = function(
|
|
23199
|
-
var
|
|
23200
|
-
var
|
|
23201
|
-
return
|
|
23219
|
+
}, ne = function(xt, Pt) {
|
|
23220
|
+
var kt = ae(), cn = Object.keys(kt).find(function(en) {
|
|
23221
|
+
var Xt, tn;
|
|
23222
|
+
return kt[en].points[0] === ((Xt = Pt.points) === null || Xt === void 0 ? void 0 : Xt[0]) && kt[en].points[1] === ((tn = Pt.points) === null || tn === void 0 ? void 0 : tn[1]);
|
|
23202
23223
|
});
|
|
23203
|
-
if (!!
|
|
23204
|
-
var
|
|
23224
|
+
if (!!cn) {
|
|
23225
|
+
var Ze = xt.getBoundingClientRect(), _t = {
|
|
23205
23226
|
top: "50%",
|
|
23206
23227
|
left: "50%"
|
|
23207
23228
|
};
|
|
23208
|
-
/top|Bottom/.test(
|
|
23229
|
+
/top|Bottom/.test(cn) ? _t.top = "".concat(Ze.height - Pt.offset[1], "px") : /Top|bottom/.test(cn) && (_t.top = "".concat(-Pt.offset[1], "px")), /left|Right/.test(cn) ? _t.left = "".concat(Ze.width - Pt.offset[0], "px") : /right|Left/.test(cn) && (_t.left = "".concat(-Pt.offset[0], "px")), xt.style.transformOrigin = "".concat(_t.left, " ").concat(_t.top);
|
|
23209
23230
|
}
|
|
23210
23231
|
}, J = function() {
|
|
23211
|
-
var
|
|
23212
|
-
return
|
|
23213
|
-
}, oe = T.getPopupContainer, ie = T.placement,
|
|
23214
|
-
!("open" in T) && !("visible" in T) && U() && (
|
|
23215
|
-
var
|
|
23216
|
-
return ge && !y.test(ge) && (
|
|
23232
|
+
var xt = T.title, Pt = T.overlay;
|
|
23233
|
+
return xt === 0 ? xt : Pt || xt || "";
|
|
23234
|
+
}, oe = T.getPopupContainer, ie = T.placement, ce = ie === void 0 ? "top" : ie, me = T.mouseEnterDelay, Q = me === void 0 ? 0.1 : me, te = T.mouseLeaveDelay, he = te === void 0 ? 0.1 : te, ve = w(T, ["getPopupContainer", "placement", "mouseEnterDelay", "mouseLeaveDelay"]), Oe = T.prefixCls, D = T.openClassName, M = T.getTooltipContainer, pe = T.overlayClassName, ge = T.color, Fe = T.overlayInnerStyle, Te = T.children, Re = N("tooltip", Oe), Ae = N(), et = H;
|
|
23235
|
+
!("open" in T) && !("visible" in T) && U() && (et = !1);
|
|
23236
|
+
var Ht = x((0, v.isValidElement)(Te) && !(0, v.isFragment)(Te) ? Te : /* @__PURE__ */ f.createElement("span", null, Te), Re), Jt = Ht.props, Yt = !Jt.className || typeof Jt.className == "string" ? (0, c.default)(Jt.className, (0, a.default)({}, D || "".concat(Re, "-open"), !0)) : Jt.className, Pe = (0, c.default)(pe, (E = {}, (0, a.default)(E, "".concat(Re, "-rtl"), L === "rtl"), (0, a.default)(E, "".concat(Re, "-").concat(ge), ge && y.test(ge)), E)), jt = Fe, it = {};
|
|
23237
|
+
return ge && !y.test(ge) && (jt = (0, l.default)((0, l.default)({}, Fe), {
|
|
23217
23238
|
background: ge
|
|
23218
|
-
}),
|
|
23239
|
+
}), it = {
|
|
23219
23240
|
"--antd-arrow-background-color": ge
|
|
23220
23241
|
}), /* @__PURE__ */ f.createElement(u.default, (0, l.default)({}, ve, {
|
|
23221
|
-
placement:
|
|
23242
|
+
placement: ce,
|
|
23222
23243
|
mouseEnterDelay: Q,
|
|
23223
23244
|
mouseLeaveDelay: he,
|
|
23224
23245
|
prefixCls: Re,
|
|
23225
|
-
overlayClassName:
|
|
23246
|
+
overlayClassName: Pe,
|
|
23226
23247
|
getTooltipContainer: oe || M || B,
|
|
23227
23248
|
ref: G,
|
|
23228
23249
|
builtinPlacements: ae(),
|
|
23229
23250
|
overlay: J(),
|
|
23230
|
-
visible:
|
|
23251
|
+
visible: et,
|
|
23231
23252
|
onVisibleChange: re,
|
|
23232
23253
|
onPopupAlign: ne,
|
|
23233
|
-
overlayInnerStyle:
|
|
23254
|
+
overlayInnerStyle: jt,
|
|
23234
23255
|
arrowContent: /* @__PURE__ */ f.createElement("span", {
|
|
23235
23256
|
className: "".concat(Re, "-arrow-content"),
|
|
23236
|
-
style:
|
|
23257
|
+
style: it
|
|
23237
23258
|
}),
|
|
23238
23259
|
motion: {
|
|
23239
23260
|
motionName: (0, m.getTransitionName)(Ae, "zoom-big-fast", T.transitionName),
|
|
23240
23261
|
motionDeadline: 1e3
|
|
23241
23262
|
}
|
|
23242
|
-
}),
|
|
23243
|
-
className:
|
|
23244
|
-
}) :
|
|
23263
|
+
}), et ? (0, v.cloneElement)(Ht, {
|
|
23264
|
+
className: Yt
|
|
23265
|
+
}) : Ht);
|
|
23245
23266
|
});
|
|
23246
23267
|
process.env.NODE_ENV !== "production" && (O.displayName = "Tooltip");
|
|
23247
23268
|
var S = O;
|
|
@@ -23291,10 +23312,10 @@ EnterOutlined$2.default = _default;
|
|
|
23291
23312
|
ne(G);
|
|
23292
23313
|
}, [G]), d.useEffect(function() {
|
|
23293
23314
|
if (K.current && K.current.resizableTextArea) {
|
|
23294
|
-
var
|
|
23295
|
-
|
|
23296
|
-
var D =
|
|
23297
|
-
|
|
23315
|
+
var Oe = K.current.resizableTextArea.textArea;
|
|
23316
|
+
Oe.focus();
|
|
23317
|
+
var D = Oe.value.length;
|
|
23318
|
+
Oe.setSelectionRange(D, D);
|
|
23298
23319
|
}
|
|
23299
23320
|
}, []);
|
|
23300
23321
|
var J = function(D) {
|
|
@@ -23304,14 +23325,14 @@ EnterOutlined$2.default = _default;
|
|
|
23304
23325
|
H.current = !0;
|
|
23305
23326
|
}, ie = function() {
|
|
23306
23327
|
H.current = !1;
|
|
23307
|
-
},
|
|
23328
|
+
}, ce = function(D) {
|
|
23308
23329
|
var M = D.keyCode;
|
|
23309
23330
|
H.current || (z.current = M);
|
|
23310
23331
|
}, me = function() {
|
|
23311
23332
|
E(ae.trim());
|
|
23312
23333
|
}, Q = function(D) {
|
|
23313
|
-
var M = D.keyCode,
|
|
23314
|
-
z.current === M && !H.current && !
|
|
23334
|
+
var M = D.keyCode, pe = D.ctrlKey, ge = D.altKey, Fe = D.metaKey, Te = D.shiftKey;
|
|
23335
|
+
z.current === M && !H.current && !pe && !ge && !Fe && !Te && (M === u.default.ENTER ? (me(), B == null || B()) : M === u.default.ESC && P());
|
|
23315
23336
|
}, te = function() {
|
|
23316
23337
|
me();
|
|
23317
23338
|
}, he = N ? "".concat(C, "-").concat(N) : "", ve = (0, c.default)(C, "".concat(C, "-edit-content"), (0, a.default)({}, "".concat(C, "-rtl"), x === "rtl"), I, he);
|
|
@@ -23323,7 +23344,7 @@ EnterOutlined$2.default = _default;
|
|
|
23323
23344
|
maxLength: O,
|
|
23324
23345
|
value: ae,
|
|
23325
23346
|
onChange: J,
|
|
23326
|
-
onKeyDown:
|
|
23347
|
+
onKeyDown: ce,
|
|
23327
23348
|
onKeyUp: Q,
|
|
23328
23349
|
onCompositionStart: oe,
|
|
23329
23350
|
onCompositionEnd: ie,
|
|
@@ -23423,30 +23444,30 @@ var Ellipsis = {};
|
|
|
23423
23444
|
return x;
|
|
23424
23445
|
}
|
|
23425
23446
|
var m = 0, g = 1, v = 2, C = 3, w = 4, I = function(O) {
|
|
23426
|
-
var S = O.enabledMeasure, T = O.children, G = O.text, E = O.width, P = O.fontSize, B = O.rows, N = O.onEllipsis, L = d.useState([0, 0, 0]), W = (0, s.default)(L, 2), K = (0, s.default)(W[0], 3), H = K[0], z = K[1], U = K[2], re = W[1], ae = d.useState(m), ne = (0, s.default)(ae, 2), J = ne[0], oe = ne[1], ie = d.useState(0),
|
|
23447
|
+
var S = O.enabledMeasure, T = O.children, G = O.text, E = O.width, P = O.fontSize, B = O.rows, N = O.onEllipsis, L = d.useState([0, 0, 0]), W = (0, s.default)(L, 2), K = (0, s.default)(W[0], 3), H = K[0], z = K[1], U = K[2], re = W[1], ae = d.useState(m), ne = (0, s.default)(ae, 2), J = ne[0], oe = ne[1], ie = d.useState(0), ce = (0, s.default)(ie, 2), me = ce[0], Q = ce[1], te = d.useRef(null), he = d.useRef(null), ve = d.useMemo(function() {
|
|
23427
23448
|
return (0, c.default)(G);
|
|
23428
|
-
}, [G]),
|
|
23449
|
+
}, [G]), Oe = d.useMemo(function() {
|
|
23429
23450
|
return p(ve);
|
|
23430
23451
|
}, [ve]), D = d.useMemo(function() {
|
|
23431
|
-
return !S || J !== C ? T(ve, !1) : T(h(ve, z), z <
|
|
23432
|
-
}, [S, J, T, ve, z,
|
|
23452
|
+
return !S || J !== C ? T(ve, !1) : T(h(ve, z), z < Oe);
|
|
23453
|
+
}, [S, J, T, ve, z, Oe]);
|
|
23433
23454
|
(0, u.default)(function() {
|
|
23434
|
-
S && E && P &&
|
|
23435
|
-
}, [S, E, P, G,
|
|
23455
|
+
S && E && P && Oe && (oe(g), re([0, Math.ceil(Oe / 2), Oe]));
|
|
23456
|
+
}, [S, E, P, G, Oe, B]), (0, u.default)(function() {
|
|
23436
23457
|
var Fe;
|
|
23437
23458
|
J === g && Q(((Fe = te.current) === null || Fe === void 0 ? void 0 : Fe.offsetHeight) || 0);
|
|
23438
23459
|
}, [J]), (0, u.default)(function() {
|
|
23439
|
-
var Fe,
|
|
23460
|
+
var Fe, Te;
|
|
23440
23461
|
if (me) {
|
|
23441
23462
|
if (J === g) {
|
|
23442
23463
|
var Re = ((Fe = he.current) === null || Fe === void 0 ? void 0 : Fe.offsetHeight) || 0, Ae = B * me;
|
|
23443
23464
|
Re <= Ae ? (oe(w), N(!1)) : oe(v);
|
|
23444
23465
|
} else if (J === v)
|
|
23445
23466
|
if (H !== U) {
|
|
23446
|
-
var
|
|
23447
|
-
H === U - 1 ?
|
|
23448
|
-
var
|
|
23449
|
-
re([
|
|
23467
|
+
var et = ((Te = he.current) === null || Te === void 0 ? void 0 : Te.offsetHeight) || 0, Ht = B * me, Jt = H, Yt = U;
|
|
23468
|
+
H === U - 1 ? Yt = H : et <= Ht ? Jt = z : Yt = z;
|
|
23469
|
+
var Pe = Math.ceil((Jt + Yt) / 2);
|
|
23470
|
+
re([Jt, Pe, Yt]);
|
|
23450
23471
|
} else
|
|
23451
23472
|
oe(C), N(!0);
|
|
23452
23473
|
}
|
|
@@ -23456,7 +23477,7 @@ var Ellipsis = {};
|
|
|
23456
23477
|
whiteSpace: "normal",
|
|
23457
23478
|
margin: 0,
|
|
23458
23479
|
padding: 0
|
|
23459
|
-
},
|
|
23480
|
+
}, pe = function(Te, Re, Ae) {
|
|
23460
23481
|
return /* @__PURE__ */ d.createElement("span", {
|
|
23461
23482
|
"aria-hidden": !0,
|
|
23462
23483
|
ref: Re,
|
|
@@ -23470,15 +23491,15 @@ var Ellipsis = {};
|
|
|
23470
23491
|
pointerEvents: "none",
|
|
23471
23492
|
fontSize: Math.floor(P / 2) * 2
|
|
23472
23493
|
}, Ae)
|
|
23473
|
-
},
|
|
23474
|
-
}, ge = function(
|
|
23475
|
-
var Ae = h(ve,
|
|
23476
|
-
return
|
|
23494
|
+
}, Te);
|
|
23495
|
+
}, ge = function(Te, Re) {
|
|
23496
|
+
var Ae = h(ve, Te);
|
|
23497
|
+
return pe(T(Ae, !0), Re, M);
|
|
23477
23498
|
};
|
|
23478
|
-
return /* @__PURE__ */ d.createElement(d.Fragment, null, D, S && J !== C && J !== w && /* @__PURE__ */ d.createElement(d.Fragment, null,
|
|
23499
|
+
return /* @__PURE__ */ d.createElement(d.Fragment, null, D, S && J !== C && J !== w && /* @__PURE__ */ d.createElement(d.Fragment, null, pe("lg", te, {
|
|
23479
23500
|
wordBreak: "keep-all",
|
|
23480
23501
|
whiteSpace: "nowrap"
|
|
23481
|
-
}), J === g ?
|
|
23502
|
+
}), J === g ? pe(T(ve, !1), he, M) : ge(z, he)));
|
|
23482
23503
|
};
|
|
23483
23504
|
process.env.NODE_ENV !== "production" && (I.displayName = "Ellipsis");
|
|
23484
23505
|
var y = I;
|
|
@@ -23507,19 +23528,19 @@ var EllipsisTooltip = {};
|
|
|
23507
23528
|
}), e.default = void 0;
|
|
23508
23529
|
var a = o(defineProperty.exports), s = o(_extends$1.exports), l = o(_typeof$3.exports), c = o(slicedToArray.exports), u = o(CheckOutlined$3.exports), d = o(CopyOutlined$3.exports), f = o(EditOutlined$3.exports), p = o(classnames.exports), h = o(copyToClipboard), m = o(require$$11), g = o(toArray$2), v = o(useLayoutEffect$1), C = o(useMergedState$1), w = o(omit$2), I = ref, y = r(React__default), x = requireConfigProvider(), O = LocaleReceiver, S = o(transButton), T = styleChecker$1, G = o(tooltip), E = o(Editable), P = o(useMergedConfig), B = o(useUpdatedEffect), N = o(Typography), L = o(Ellipsis), W = o(EllipsisTooltip), K = function(J, oe) {
|
|
23509
23530
|
var ie = {};
|
|
23510
|
-
for (var
|
|
23511
|
-
Object.prototype.hasOwnProperty.call(J,
|
|
23531
|
+
for (var ce in J)
|
|
23532
|
+
Object.prototype.hasOwnProperty.call(J, ce) && oe.indexOf(ce) < 0 && (ie[ce] = J[ce]);
|
|
23512
23533
|
if (J != null && typeof Object.getOwnPropertySymbols == "function")
|
|
23513
|
-
for (var me = 0,
|
|
23514
|
-
oe.indexOf(
|
|
23534
|
+
for (var me = 0, ce = Object.getOwnPropertySymbols(J); me < ce.length; me++)
|
|
23535
|
+
oe.indexOf(ce[me]) < 0 && Object.prototype.propertyIsEnumerable.call(J, ce[me]) && (ie[ce[me]] = J[ce[me]]);
|
|
23515
23536
|
return ie;
|
|
23516
23537
|
};
|
|
23517
23538
|
function H(J, oe) {
|
|
23518
|
-
var ie = J.mark,
|
|
23519
|
-
function D(M,
|
|
23520
|
-
!M || (
|
|
23539
|
+
var ie = J.mark, ce = J.code, me = J.underline, Q = J.delete, te = J.strong, he = J.keyboard, ve = J.italic, Oe = oe;
|
|
23540
|
+
function D(M, pe) {
|
|
23541
|
+
!M || (Oe = /* @__PURE__ */ y.createElement(pe, {}, Oe));
|
|
23521
23542
|
}
|
|
23522
|
-
return D(te, "strong"), D(me, "u"), D(Q, "del"), D(
|
|
23543
|
+
return D(te, "strong"), D(me, "u"), D(Q, "del"), D(ce, "code"), D(ie, "mark"), D(he, "kbd"), D(ve, "i"), Oe;
|
|
23523
23544
|
}
|
|
23524
23545
|
function z(J, oe, ie) {
|
|
23525
23546
|
return J === !0 || J === void 0 ? oe : J || ie && oe;
|
|
@@ -23528,81 +23549,81 @@ var EllipsisTooltip = {};
|
|
|
23528
23549
|
return J === !1 ? [!1, !1] : Array.isArray(J) ? J : [J];
|
|
23529
23550
|
}
|
|
23530
23551
|
var re = "...", ae = /* @__PURE__ */ y.forwardRef(function(J, oe) {
|
|
23531
|
-
var ie,
|
|
23532
|
-
value:
|
|
23533
|
-
}),
|
|
23552
|
+
var ie, ce, me, Q = J.prefixCls, te = J.className, he = J.style, ve = J.type, Oe = J.disabled, D = J.children, M = J.ellipsis, pe = J.editable, ge = J.copyable, Fe = J.component, Te = J.title, Re = K(J, ["prefixCls", "className", "style", "type", "disabled", "children", "ellipsis", "editable", "copyable", "component", "title"]), Ae = y.useContext(x.ConfigContext), et = Ae.getPrefixCls, Ht = Ae.direction, Jt = (0, O.useLocaleReceiver)("Text")[0], Yt = y.useRef(null), Pe = y.useRef(null), jt = et("typography", Q), it = (0, w.default)(Re, ["mark", "code", "delete", "underline", "strong", "keyboard", "italic"]), Qt = (0, P.default)(pe), xt = (0, c.default)(Qt, 2), Pt = xt[0], kt = xt[1], cn = (0, C.default)(!1, {
|
|
23553
|
+
value: kt.editing
|
|
23554
|
+
}), Ze = (0, c.default)(cn, 2), _t = Ze[0], en = Ze[1], Xt = kt.triggerType, tn = Xt === void 0 ? ["icon"] : Xt, un = function(qt) {
|
|
23534
23555
|
var rn;
|
|
23535
|
-
|
|
23556
|
+
qt && ((rn = kt.onStart) === null || rn === void 0 || rn.call(kt)), en(qt);
|
|
23536
23557
|
};
|
|
23537
23558
|
(0, B.default)(function() {
|
|
23538
23559
|
var nn;
|
|
23539
|
-
|
|
23540
|
-
}, [
|
|
23541
|
-
var gn = function(
|
|
23542
|
-
|
|
23543
|
-
},
|
|
23560
|
+
_t || (nn = Pe.current) === null || nn === void 0 || nn.focus();
|
|
23561
|
+
}, [_t]);
|
|
23562
|
+
var gn = function(qt) {
|
|
23563
|
+
qt == null || qt.preventDefault(), un(!0);
|
|
23564
|
+
}, mn = function(qt) {
|
|
23544
23565
|
var rn;
|
|
23545
|
-
(rn =
|
|
23546
|
-
},
|
|
23547
|
-
var
|
|
23548
|
-
(
|
|
23549
|
-
},
|
|
23550
|
-
|
|
23566
|
+
(rn = kt.onChange) === null || rn === void 0 || rn.call(kt, qt), un(!1);
|
|
23567
|
+
}, an = function() {
|
|
23568
|
+
var qt;
|
|
23569
|
+
(qt = kt.onCancel) === null || qt === void 0 || qt.call(kt), un(!1);
|
|
23570
|
+
}, fn = (0, P.default)(ge), _n = (0, c.default)(fn, 2), $n = _n[0], yn = _n[1], jn = y.useState(!1), On = (0, c.default)(jn, 2), dn = On[0], sn = On[1], pn = y.useRef(), In = {};
|
|
23571
|
+
yn.format && (In.format = yn.format);
|
|
23551
23572
|
var Wn = function() {
|
|
23552
|
-
window.clearTimeout(
|
|
23553
|
-
}, tr = function(
|
|
23573
|
+
window.clearTimeout(pn.current);
|
|
23574
|
+
}, tr = function(qt) {
|
|
23554
23575
|
var rn;
|
|
23555
|
-
|
|
23556
|
-
|
|
23557
|
-
}, 3e3), (rn =
|
|
23576
|
+
qt == null || qt.preventDefault(), qt == null || qt.stopPropagation(), (0, h.default)(yn.text || String(D) || "", In), sn(!0), Wn(), pn.current = window.setTimeout(function() {
|
|
23577
|
+
sn(!1);
|
|
23578
|
+
}, 3e3), (rn = yn.onCopy) === null || rn === void 0 || rn.call(yn, qt);
|
|
23558
23579
|
};
|
|
23559
23580
|
y.useEffect(function() {
|
|
23560
23581
|
return Wn;
|
|
23561
23582
|
}, []);
|
|
23562
|
-
var nr = y.useState(!1), zn = (0, c.default)(nr, 2), Gn = zn[0],
|
|
23583
|
+
var nr = y.useState(!1), zn = (0, c.default)(nr, 2), Gn = zn[0], rr = zn[1], Yn = y.useState(!1), Kn = (0, c.default)(Yn, 2), Zn = Kn[0], or = Kn[1], ar = y.useState(!1), qe = (0, c.default)(ar, 2), Le = qe[0], Tt = qe[1], Zt = y.useState(!1), ln = (0, c.default)(Zt, 2), Ln = ln[0], Hn = ln[1], _r = y.useState(!1), Vn = (0, c.default)(_r, 2), Xn = Vn[0], Wr = Vn[1], zr = y.useState(!0), Rr = (0, c.default)(zr, 2), Gr = Rr[0], Yr = Rr[1], Kr = (0, P.default)(M, {
|
|
23563
23584
|
expandable: !1
|
|
23564
|
-
}), $r = (0, c.default)(Kr, 2), Bn = $r[0], vn = $r[1], Pn = Bn && !
|
|
23565
|
-
return !Pn || vn.suffix !== void 0 || vn.onEllipsis || vn.expandable ||
|
|
23566
|
-
}, [Pn, vn,
|
|
23585
|
+
}), $r = (0, c.default)(Kr, 2), Bn = $r[0], vn = $r[1], Pn = Bn && !Le, Ar = vn.rows, qn = Ar === void 0 ? 1 : Ar, Qn = y.useMemo(function() {
|
|
23586
|
+
return !Pn || vn.suffix !== void 0 || vn.onEllipsis || vn.expandable || Pt || $n;
|
|
23587
|
+
}, [Pn, vn, Pt, $n]);
|
|
23567
23588
|
(0, v.default)(function() {
|
|
23568
|
-
Bn && !Qn && (
|
|
23589
|
+
Bn && !Qn && (rr((0, T.isStyleSupport)("webkitLineClamp")), or((0, T.isStyleSupport)("textOverflow")));
|
|
23569
23590
|
}, [Qn, Bn]);
|
|
23570
23591
|
var Mn = y.useMemo(function() {
|
|
23571
23592
|
return Qn ? !1 : qn === 1 ? Zn : Gn;
|
|
23572
|
-
}, [Qn, Zn, Gn]), Pr = Pn && (Mn ?
|
|
23593
|
+
}, [Qn, Zn, Gn]), Pr = Pn && (Mn ? Xn : Ln), Zr = Pn && qn === 1 && Mn, Jn = Pn && qn > 1 && Mn, Xr = function(qt) {
|
|
23573
23594
|
var rn;
|
|
23574
|
-
|
|
23575
|
-
}, eo = y.useState(0), Hr = (0, c.default)(eo, 2), no = Hr[0], ro = Hr[1], oo = y.useState(0), Ur = (0, c.default)(oo, 2), ao = Ur[0], io = Ur[1], so = function(
|
|
23576
|
-
var
|
|
23577
|
-
ro(
|
|
23578
|
-
}, lo = function(
|
|
23595
|
+
Tt(!0), (rn = vn.onExpand) === null || rn === void 0 || rn.call(vn, qt);
|
|
23596
|
+
}, eo = y.useState(0), Hr = (0, c.default)(eo, 2), no = Hr[0], ro = Hr[1], oo = y.useState(0), Ur = (0, c.default)(oo, 2), ao = Ur[0], io = Ur[1], so = function(qt, rn) {
|
|
23597
|
+
var bn = qt.offsetWidth, Fn;
|
|
23598
|
+
ro(bn), io(parseInt((Fn = window.getComputedStyle) === null || Fn === void 0 ? void 0 : Fn.call(window, rn).fontSize, 10) || 0);
|
|
23599
|
+
}, lo = function(qt) {
|
|
23579
23600
|
var rn;
|
|
23580
|
-
|
|
23601
|
+
Hn(qt), Ln !== qt && ((rn = vn.onEllipsis) === null || rn === void 0 || rn.call(vn, qt));
|
|
23581
23602
|
};
|
|
23582
23603
|
y.useEffect(function() {
|
|
23583
|
-
var nn =
|
|
23604
|
+
var nn = Yt.current;
|
|
23584
23605
|
if (Bn && Mn && nn) {
|
|
23585
|
-
var
|
|
23586
|
-
|
|
23606
|
+
var qt = Jn ? nn.offsetHeight < nn.scrollHeight : nn.offsetWidth < nn.scrollWidth;
|
|
23607
|
+
Xn !== qt && Wr(qt);
|
|
23587
23608
|
}
|
|
23588
23609
|
}, [Bn, Mn, D, Jn, Gr]), y.useEffect(function() {
|
|
23589
|
-
var nn =
|
|
23610
|
+
var nn = Yt.current;
|
|
23590
23611
|
if (!(typeof IntersectionObserver > "u" || !nn || !Mn || !Pn)) {
|
|
23591
|
-
var
|
|
23612
|
+
var qt = new IntersectionObserver(function() {
|
|
23592
23613
|
Yr(!!nn.offsetParent);
|
|
23593
23614
|
});
|
|
23594
|
-
return
|
|
23595
|
-
|
|
23615
|
+
return qt.observe(nn), function() {
|
|
23616
|
+
qt.disconnect();
|
|
23596
23617
|
};
|
|
23597
23618
|
}
|
|
23598
23619
|
}, [Mn, Pn]);
|
|
23599
23620
|
var Nn = {};
|
|
23600
23621
|
vn.tooltip === !0 ? Nn = {
|
|
23601
|
-
title: (ie =
|
|
23622
|
+
title: (ie = kt.text) !== null && ie !== void 0 ? ie : D
|
|
23602
23623
|
} : /* @__PURE__ */ y.isValidElement(vn.tooltip) ? Nn = {
|
|
23603
23624
|
title: vn.tooltip
|
|
23604
23625
|
} : (0, l.default)(vn.tooltip) === "object" ? Nn = (0, s.default)({
|
|
23605
|
-
title: (
|
|
23626
|
+
title: (ce = kt.text) !== null && ce !== void 0 ? ce : D
|
|
23606
23627
|
}, vn.tooltip) : Nn = {
|
|
23607
23628
|
title: vn.tooltip
|
|
23608
23629
|
};
|
|
@@ -23611,112 +23632,112 @@ var EllipsisTooltip = {};
|
|
|
23611
23632
|
return ["string", "number"].includes((0, l.default)(rn));
|
|
23612
23633
|
};
|
|
23613
23634
|
if (!(!Bn || Mn)) {
|
|
23614
|
-
if (nn(
|
|
23615
|
-
return
|
|
23635
|
+
if (nn(kt.text))
|
|
23636
|
+
return kt.text;
|
|
23616
23637
|
if (nn(D))
|
|
23617
23638
|
return D;
|
|
23618
|
-
if (nn(
|
|
23619
|
-
return
|
|
23639
|
+
if (nn(Te))
|
|
23640
|
+
return Te;
|
|
23620
23641
|
if (nn(Nn.title))
|
|
23621
23642
|
return Nn.title;
|
|
23622
23643
|
}
|
|
23623
|
-
}, [Bn, Mn,
|
|
23624
|
-
if (
|
|
23644
|
+
}, [Bn, Mn, Te, Nn.title, Pr]);
|
|
23645
|
+
if (_t)
|
|
23625
23646
|
return /* @__PURE__ */ y.createElement(E.default, {
|
|
23626
|
-
value: (me =
|
|
23627
|
-
onSave:
|
|
23628
|
-
onCancel:
|
|
23629
|
-
onEnd:
|
|
23630
|
-
prefixCls:
|
|
23647
|
+
value: (me = kt.text) !== null && me !== void 0 ? me : typeof D == "string" ? D : "",
|
|
23648
|
+
onSave: mn,
|
|
23649
|
+
onCancel: an,
|
|
23650
|
+
onEnd: kt.onEnd,
|
|
23651
|
+
prefixCls: jt,
|
|
23631
23652
|
className: te,
|
|
23632
23653
|
style: he,
|
|
23633
|
-
direction:
|
|
23654
|
+
direction: Ht,
|
|
23634
23655
|
component: Fe,
|
|
23635
|
-
maxLength:
|
|
23636
|
-
autoSize:
|
|
23637
|
-
enterIcon:
|
|
23656
|
+
maxLength: kt.maxLength,
|
|
23657
|
+
autoSize: kt.autoSize,
|
|
23658
|
+
enterIcon: kt.enterIcon
|
|
23638
23659
|
});
|
|
23639
23660
|
var co = function() {
|
|
23640
|
-
var
|
|
23641
|
-
if (!
|
|
23661
|
+
var qt = vn.expandable, rn = vn.symbol;
|
|
23662
|
+
if (!qt)
|
|
23642
23663
|
return null;
|
|
23643
|
-
var
|
|
23644
|
-
return rn ?
|
|
23664
|
+
var bn;
|
|
23665
|
+
return rn ? bn = rn : bn = Jt.expand, /* @__PURE__ */ y.createElement("a", {
|
|
23645
23666
|
key: "expand",
|
|
23646
|
-
className: "".concat(
|
|
23667
|
+
className: "".concat(jt, "-expand"),
|
|
23647
23668
|
onClick: Xr,
|
|
23648
|
-
"aria-label":
|
|
23649
|
-
},
|
|
23669
|
+
"aria-label": Jt.expand
|
|
23670
|
+
}, bn);
|
|
23650
23671
|
}, uo = function() {
|
|
23651
|
-
if (!!
|
|
23652
|
-
var
|
|
23672
|
+
if (!!Pt) {
|
|
23673
|
+
var qt = kt.icon, rn = kt.tooltip, bn = (0, g.default)(rn)[0] || Jt.edit, Fn = typeof bn == "string" ? bn : "";
|
|
23653
23674
|
return tn.includes("icon") ? /* @__PURE__ */ y.createElement(G.default, {
|
|
23654
23675
|
key: "edit",
|
|
23655
|
-
title: rn === !1 ? "" :
|
|
23676
|
+
title: rn === !1 ? "" : bn
|
|
23656
23677
|
}, /* @__PURE__ */ y.createElement(S.default, {
|
|
23657
|
-
ref:
|
|
23658
|
-
className: "".concat(
|
|
23678
|
+
ref: Pe,
|
|
23679
|
+
className: "".concat(jt, "-edit"),
|
|
23659
23680
|
onClick: gn,
|
|
23660
|
-
"aria-label":
|
|
23661
|
-
},
|
|
23681
|
+
"aria-label": Fn
|
|
23682
|
+
}, qt || /* @__PURE__ */ y.createElement(f.default, {
|
|
23662
23683
|
role: "button"
|
|
23663
23684
|
}))) : null;
|
|
23664
23685
|
}
|
|
23665
23686
|
}, fo = function() {
|
|
23666
|
-
if (
|
|
23667
|
-
var
|
|
23687
|
+
if (!!$n) {
|
|
23688
|
+
var qt = yn.tooltips, rn = yn.icon, bn = U(qt), Fn = U(rn), Un = dn ? z(bn[1], Jt.copied) : z(bn[0], Jt.copy), mo = dn ? Jt.copied : Jt.copy, go = typeof Un == "string" ? Un : mo;
|
|
23668
23689
|
return /* @__PURE__ */ y.createElement(G.default, {
|
|
23669
23690
|
key: "copy",
|
|
23670
23691
|
title: Un
|
|
23671
23692
|
}, /* @__PURE__ */ y.createElement(S.default, {
|
|
23672
|
-
className: (0, p.default)("".concat(
|
|
23693
|
+
className: (0, p.default)("".concat(jt, "-copy"), dn && "".concat(jt, "-copy-success")),
|
|
23673
23694
|
onClick: tr,
|
|
23674
23695
|
"aria-label": go
|
|
23675
|
-
},
|
|
23696
|
+
}, dn ? z(Fn[1], /* @__PURE__ */ y.createElement(u.default, null), !0) : z(Fn[0], /* @__PURE__ */ y.createElement(d.default, null), !0)));
|
|
23676
23697
|
}
|
|
23677
|
-
}, po = function(
|
|
23678
|
-
return [
|
|
23679
|
-
}, ho = function(
|
|
23680
|
-
return [
|
|
23698
|
+
}, po = function(qt) {
|
|
23699
|
+
return [qt && co(), uo(), fo()];
|
|
23700
|
+
}, ho = function(qt) {
|
|
23701
|
+
return [qt && /* @__PURE__ */ y.createElement("span", {
|
|
23681
23702
|
"aria-hidden": !0,
|
|
23682
23703
|
key: "ellipsis"
|
|
23683
|
-
}, re), vn.suffix, po(
|
|
23704
|
+
}, re), vn.suffix, po(qt)];
|
|
23684
23705
|
};
|
|
23685
23706
|
return /* @__PURE__ */ y.createElement(m.default, {
|
|
23686
23707
|
onResize: so,
|
|
23687
23708
|
disabled: !Pn || Mn
|
|
23688
23709
|
}, function(nn) {
|
|
23689
|
-
var
|
|
23710
|
+
var qt;
|
|
23690
23711
|
return /* @__PURE__ */ y.createElement(W.default, {
|
|
23691
23712
|
tooltipProps: Nn,
|
|
23692
23713
|
enabledEllipsis: Pn,
|
|
23693
23714
|
isEllipsis: Pr
|
|
23694
23715
|
}, /* @__PURE__ */ y.createElement(N.default, (0, s.default)({
|
|
23695
|
-
className: (0, p.default)((
|
|
23716
|
+
className: (0, p.default)((qt = {}, (0, a.default)(qt, "".concat(jt, "-").concat(ve), ve), (0, a.default)(qt, "".concat(jt, "-disabled"), Oe), (0, a.default)(qt, "".concat(jt, "-ellipsis"), Bn), (0, a.default)(qt, "".concat(jt, "-single-line"), Pn && qn === 1), (0, a.default)(qt, "".concat(jt, "-ellipsis-single-line"), Zr), (0, a.default)(qt, "".concat(jt, "-ellipsis-multiple-line"), Jn), qt), te),
|
|
23696
23717
|
prefixCls: Q,
|
|
23697
23718
|
style: (0, s.default)((0, s.default)({}, he), {
|
|
23698
23719
|
WebkitLineClamp: Jn ? qn : void 0
|
|
23699
23720
|
}),
|
|
23700
23721
|
component: Fe,
|
|
23701
|
-
ref: (0, I.composeRef)(nn,
|
|
23702
|
-
direction:
|
|
23722
|
+
ref: (0, I.composeRef)(nn, Yt, oe),
|
|
23723
|
+
direction: Ht,
|
|
23703
23724
|
onClick: tn.includes("text") ? gn : void 0,
|
|
23704
23725
|
"aria-label": er == null ? void 0 : er.toString(),
|
|
23705
|
-
title:
|
|
23706
|
-
},
|
|
23726
|
+
title: Te
|
|
23727
|
+
}, it), /* @__PURE__ */ y.createElement(L.default, {
|
|
23707
23728
|
enabledMeasure: Pn && !Mn,
|
|
23708
23729
|
text: D,
|
|
23709
23730
|
rows: qn,
|
|
23710
23731
|
width: no,
|
|
23711
23732
|
fontSize: ao,
|
|
23712
23733
|
onEllipsis: lo
|
|
23713
|
-
}, function(rn,
|
|
23714
|
-
var
|
|
23715
|
-
rn.length &&
|
|
23734
|
+
}, function(rn, bn) {
|
|
23735
|
+
var Fn = rn;
|
|
23736
|
+
rn.length && bn && er && (Fn = /* @__PURE__ */ y.createElement("span", {
|
|
23716
23737
|
key: "show-content",
|
|
23717
23738
|
"aria-hidden": !0
|
|
23718
|
-
},
|
|
23719
|
-
var Un = H(J, /* @__PURE__ */ y.createElement(y.Fragment, null,
|
|
23739
|
+
}, Fn));
|
|
23740
|
+
var Un = H(J, /* @__PURE__ */ y.createElement(y.Fragment, null, Fn, ho(bn)));
|
|
23720
23741
|
return Un;
|
|
23721
23742
|
})));
|
|
23722
23743
|
});
|
|
@@ -24486,7 +24507,7 @@ function filterDuplicateItems(e) {
|
|
|
24486
24507
|
});
|
|
24487
24508
|
}
|
|
24488
24509
|
const One2manyInput = (e) => {
|
|
24489
|
-
var
|
|
24510
|
+
var cn;
|
|
24490
24511
|
const {
|
|
24491
24512
|
value: r,
|
|
24492
24513
|
onChange: o,
|
|
@@ -24510,47 +24531,47 @@ const One2manyInput = (e) => {
|
|
|
24510
24531
|
t: I
|
|
24511
24532
|
} = useContext(LocaleContext), y = useRef(), [x, O] = useState$1(!1), [S, T] = useState$1(!1), [G, E] = useState$1(), [P, B] = useState$1(!1), [N, L] = useState$1(!1), [W, K] = useState$1(), [H, z] = useState$1([]), [U, re] = useState$1(!1), ae = useRef([]), [ne, J] = useState$1(), oe = useRef(), {
|
|
24512
24533
|
readOnly: ie,
|
|
24513
|
-
relation:
|
|
24534
|
+
relation: ce,
|
|
24514
24535
|
context: me,
|
|
24515
24536
|
domain: Q
|
|
24516
24537
|
} = a, te = a.type === "many2many", {
|
|
24517
24538
|
id: he
|
|
24518
|
-
} = a, ve = l.filter((
|
|
24539
|
+
} = a, ve = l.filter((Ze) => Ze.values && Ze.operation !== "pendingRemove");
|
|
24519
24540
|
useEffect(() => {
|
|
24520
|
-
l.some((
|
|
24541
|
+
l.some((Ze) => !Ze.values) && D();
|
|
24521
24542
|
}, [l]), useEffect(() => {
|
|
24522
|
-
|
|
24543
|
+
pe();
|
|
24523
24544
|
}, [C]);
|
|
24524
|
-
const
|
|
24525
|
-
var
|
|
24545
|
+
const Oe = (Ze) => {
|
|
24546
|
+
var _t, en;
|
|
24526
24547
|
o == null || o({
|
|
24527
|
-
fields: ((
|
|
24528
|
-
items: filterDuplicateItems(
|
|
24548
|
+
fields: ((_t = s.get("form")) == null ? void 0 : _t.fields) || ((en = s.get("tree")) == null ? void 0 : en.fields),
|
|
24549
|
+
items: filterDuplicateItems(Ze)
|
|
24529
24550
|
});
|
|
24530
24551
|
}, D = async () => {
|
|
24531
24552
|
await M(), d > ve.length - 1 && d !== 0 && f(0);
|
|
24532
24553
|
}, M = async () => {
|
|
24533
|
-
var
|
|
24554
|
+
var Ze;
|
|
24534
24555
|
T(!0), O(!1), E(void 0);
|
|
24535
24556
|
try {
|
|
24536
|
-
const
|
|
24557
|
+
const _t = await readObjectValues({
|
|
24537
24558
|
treeFields: s.get("tree").fields,
|
|
24538
|
-
formFields: ((
|
|
24539
|
-
model:
|
|
24559
|
+
formFields: ((Ze = s.get("form")) == null ? void 0 : Ze.fields) || {},
|
|
24560
|
+
model: ce,
|
|
24540
24561
|
items: l,
|
|
24541
24562
|
context: {
|
|
24542
24563
|
...v == null ? void 0 : v(),
|
|
24543
24564
|
...me
|
|
24544
24565
|
}
|
|
24545
24566
|
});
|
|
24546
|
-
oe.current || (oe.current =
|
|
24547
|
-
} catch (
|
|
24548
|
-
E(
|
|
24567
|
+
oe.current || (oe.current = _t.map((en) => en.id)), Oe(_t);
|
|
24568
|
+
} catch (_t) {
|
|
24569
|
+
E(_t);
|
|
24549
24570
|
} finally {
|
|
24550
24571
|
T(!1);
|
|
24551
24572
|
}
|
|
24552
24573
|
};
|
|
24553
|
-
async function
|
|
24574
|
+
async function pe() {
|
|
24554
24575
|
Q && (ae.current = transformDomainForChildWidget({
|
|
24555
24576
|
domain: await ConnectionProvider.getHandler().evalDomain({
|
|
24556
24577
|
domain: Q,
|
|
@@ -24558,6 +24579,7 @@ const One2manyInput = (e) => {
|
|
|
24558
24579
|
fields: m(),
|
|
24559
24580
|
values: g()
|
|
24560
24581
|
}),
|
|
24582
|
+
fields: m(),
|
|
24561
24583
|
context: v()
|
|
24562
24584
|
}),
|
|
24563
24585
|
widgetFieldName: he
|
|
@@ -24567,56 +24589,56 @@ const One2manyInput = (e) => {
|
|
|
24567
24589
|
})));
|
|
24568
24590
|
}
|
|
24569
24591
|
const ge = () => {
|
|
24570
|
-
const
|
|
24592
|
+
const Ze = Array.from(s.keys()), _t = Ze[(Ze.indexOf(c) + 1) % Ze.length];
|
|
24571
24593
|
c === "form" ? Ae(() => {
|
|
24572
|
-
u(
|
|
24573
|
-
}) : u(
|
|
24594
|
+
u(_t);
|
|
24595
|
+
}) : u(_t);
|
|
24574
24596
|
}, Fe = () => {
|
|
24575
24597
|
d > 0 && (c === "form" ? Ae(() => {
|
|
24576
24598
|
f(d - 1);
|
|
24577
24599
|
}) : f(d - 1));
|
|
24578
|
-
},
|
|
24579
|
-
const
|
|
24580
|
-
d <
|
|
24600
|
+
}, Te = () => {
|
|
24601
|
+
const Ze = ve.length;
|
|
24602
|
+
d < Ze - 1 && (c === "form" ? Ae(() => {
|
|
24581
24603
|
f(d + 1);
|
|
24582
24604
|
}) : f(d + 1));
|
|
24583
24605
|
}, Re = async () => {
|
|
24584
|
-
const
|
|
24585
|
-
model:
|
|
24586
|
-
ids: [
|
|
24606
|
+
const Ze = ve[d].id, _t = (await ConnectionProvider.getHandler().readObjects({
|
|
24607
|
+
model: ce,
|
|
24608
|
+
ids: [Ze],
|
|
24587
24609
|
fields: s.get("form").fields,
|
|
24588
24610
|
context: {
|
|
24589
24611
|
...v == null ? void 0 : v(),
|
|
24590
24612
|
...me
|
|
24591
24613
|
}
|
|
24592
|
-
}))[0],
|
|
24593
|
-
model:
|
|
24594
|
-
ids: [
|
|
24614
|
+
}))[0], en = (await ConnectionProvider.getHandler().readObjects({
|
|
24615
|
+
model: ce,
|
|
24616
|
+
ids: [Ze],
|
|
24595
24617
|
fields: s.get("tree").fields,
|
|
24596
24618
|
context: {
|
|
24597
24619
|
...v == null ? void 0 : v(),
|
|
24598
24620
|
...me
|
|
24599
24621
|
}
|
|
24600
|
-
}))[0],
|
|
24622
|
+
}))[0], Xt = l.map((tn) => tn.id === Ze ? {
|
|
24601
24623
|
...tn,
|
|
24602
24624
|
operation: "original",
|
|
24603
|
-
values:
|
|
24604
|
-
treeValues:
|
|
24625
|
+
values: _t,
|
|
24626
|
+
treeValues: en
|
|
24605
24627
|
} : tn);
|
|
24606
|
-
|
|
24607
|
-
}, Ae = (
|
|
24628
|
+
Oe(Xt);
|
|
24629
|
+
}, Ae = (Ze) => {
|
|
24608
24630
|
x ? showDialog$6({
|
|
24609
24631
|
lang: w,
|
|
24610
24632
|
onOk: () => {
|
|
24611
|
-
Re(),
|
|
24633
|
+
Re(), Ze(), O(!1);
|
|
24612
24634
|
}
|
|
24613
|
-
}) :
|
|
24614
|
-
},
|
|
24635
|
+
}) : Ze();
|
|
24636
|
+
}, et = () => {
|
|
24615
24637
|
if (te) {
|
|
24616
24638
|
showDialog$1({
|
|
24617
24639
|
lang: w,
|
|
24618
24640
|
onOk: () => {
|
|
24619
|
-
c === "form" ?
|
|
24641
|
+
c === "form" ? Yt() : Pe();
|
|
24620
24642
|
}
|
|
24621
24643
|
});
|
|
24622
24644
|
return;
|
|
@@ -24624,185 +24646,185 @@ const One2manyInput = (e) => {
|
|
|
24624
24646
|
showDialog$2({
|
|
24625
24647
|
lang: w,
|
|
24626
24648
|
onOk: () => {
|
|
24627
|
-
c === "form" ?
|
|
24649
|
+
c === "form" ? Yt() : Pe();
|
|
24628
24650
|
}
|
|
24629
24651
|
});
|
|
24630
|
-
},
|
|
24652
|
+
}, Ht = async () => {
|
|
24631
24653
|
const {
|
|
24632
|
-
inv_field:
|
|
24654
|
+
inv_field: Ze
|
|
24633
24655
|
} = a;
|
|
24634
|
-
let
|
|
24635
|
-
|
|
24636
|
-
[
|
|
24656
|
+
let _t;
|
|
24657
|
+
Ze && h && (_t = {
|
|
24658
|
+
[Ze]: h
|
|
24637
24659
|
}), c === "form" ? Ae(() => {
|
|
24638
24660
|
re(!0), K({
|
|
24639
|
-
defaultValues:
|
|
24661
|
+
defaultValues: _t
|
|
24640
24662
|
}), B(!0);
|
|
24641
24663
|
}) : (re(!0), K({
|
|
24642
|
-
defaultValues:
|
|
24664
|
+
defaultValues: _t
|
|
24643
24665
|
}), B(!0));
|
|
24644
|
-
},
|
|
24666
|
+
}, Jt = async () => {
|
|
24645
24667
|
c === "form" ? Ae(() => {
|
|
24646
24668
|
L(!0);
|
|
24647
24669
|
}) : L(!0);
|
|
24648
|
-
},
|
|
24670
|
+
}, Yt = async () => {
|
|
24649
24671
|
T(!0), O(!1), E(void 0);
|
|
24650
24672
|
try {
|
|
24651
24673
|
if (ve[d].id > 0) {
|
|
24652
|
-
const
|
|
24653
|
-
...
|
|
24674
|
+
const Ze = l.map((_t) => _t.id === ve[d].id ? {
|
|
24675
|
+
..._t,
|
|
24654
24676
|
operation: "pendingRemove"
|
|
24655
|
-
} :
|
|
24656
|
-
|
|
24677
|
+
} : _t);
|
|
24678
|
+
Oe(Ze);
|
|
24657
24679
|
} else
|
|
24658
|
-
|
|
24659
|
-
} catch (
|
|
24660
|
-
E(
|
|
24680
|
+
Oe(l.filter((Ze) => Ze.id !== ve[d].id));
|
|
24681
|
+
} catch (Ze) {
|
|
24682
|
+
E(Ze);
|
|
24661
24683
|
}
|
|
24662
24684
|
f(0), T(!1);
|
|
24663
|
-
},
|
|
24664
|
-
const
|
|
24685
|
+
}, Pe = async () => {
|
|
24686
|
+
const Ze = ve.filter((_t) => H.includes(_t.id));
|
|
24665
24687
|
T(!0), O(!1), E(void 0);
|
|
24666
24688
|
try {
|
|
24667
|
-
const
|
|
24668
|
-
...
|
|
24689
|
+
const _t = Ze.map((Xt) => Xt.id), en = l.filter((Xt) => !(_t.includes(Xt.id) && Xt.id < 0)).map((Xt) => _t.includes(Xt.id) ? {
|
|
24690
|
+
...Xt,
|
|
24669
24691
|
operation: "pendingRemove"
|
|
24670
|
-
} :
|
|
24671
|
-
|
|
24672
|
-
} catch (
|
|
24673
|
-
E(
|
|
24692
|
+
} : Xt);
|
|
24693
|
+
Oe(en);
|
|
24694
|
+
} catch (_t) {
|
|
24695
|
+
E(_t);
|
|
24674
24696
|
}
|
|
24675
24697
|
f(0), T(!1);
|
|
24676
|
-
},
|
|
24677
|
-
let
|
|
24678
|
-
if (
|
|
24679
|
-
|
|
24680
|
-
id:
|
|
24681
|
-
operation:
|
|
24698
|
+
}, jt = (Ze, _t, en) => {
|
|
24699
|
+
let Xt;
|
|
24700
|
+
if (Ze)
|
|
24701
|
+
Xt = l.map((tn) => tn.id === Ze ? {
|
|
24702
|
+
id: Ze,
|
|
24703
|
+
operation: Ze > 0 ? "pendingUpdate" : "pendingCreate",
|
|
24682
24704
|
values: {
|
|
24683
|
-
...
|
|
24684
|
-
id:
|
|
24705
|
+
...en,
|
|
24706
|
+
id: Ze
|
|
24685
24707
|
},
|
|
24686
24708
|
treeValues: {
|
|
24687
|
-
...
|
|
24688
|
-
id:
|
|
24709
|
+
...en,
|
|
24710
|
+
id: Ze
|
|
24689
24711
|
}
|
|
24690
24712
|
} : tn);
|
|
24691
24713
|
else {
|
|
24692
24714
|
const tn = getNextPendingId(l);
|
|
24693
|
-
|
|
24715
|
+
Xt = l.concat({
|
|
24694
24716
|
id: tn,
|
|
24695
24717
|
operation: "pendingCreate",
|
|
24696
24718
|
values: {
|
|
24697
|
-
...
|
|
24719
|
+
...en,
|
|
24698
24720
|
id: tn
|
|
24699
24721
|
},
|
|
24700
24722
|
treeValues: {
|
|
24701
|
-
...
|
|
24723
|
+
...en,
|
|
24702
24724
|
id: tn
|
|
24703
24725
|
}
|
|
24704
24726
|
});
|
|
24705
24727
|
}
|
|
24706
|
-
|
|
24707
|
-
},
|
|
24728
|
+
Oe(Xt), U || B(!1);
|
|
24729
|
+
}, it = (Ze) => {
|
|
24708
24730
|
const {
|
|
24709
|
-
id:
|
|
24710
|
-
} =
|
|
24711
|
-
K(l.find((
|
|
24712
|
-
},
|
|
24731
|
+
id: _t
|
|
24732
|
+
} = Ze;
|
|
24733
|
+
K(l.find((en) => en.id === _t)), re(!1), B(!0);
|
|
24734
|
+
}, Qt = async (Ze) => {
|
|
24713
24735
|
T(!0);
|
|
24714
|
-
let
|
|
24715
|
-
const
|
|
24736
|
+
let _t = l;
|
|
24737
|
+
const en = Ze.filter((Xt) => !l.find((tn) => tn.id === Xt));
|
|
24716
24738
|
try {
|
|
24717
|
-
for (const
|
|
24739
|
+
for (const Xt of en) {
|
|
24718
24740
|
const tn = (await ConnectionProvider.getHandler().readObjects({
|
|
24719
|
-
model:
|
|
24720
|
-
ids: [
|
|
24741
|
+
model: ce,
|
|
24742
|
+
ids: [Xt],
|
|
24721
24743
|
fields: s.get("form").fields,
|
|
24722
24744
|
context: {
|
|
24723
24745
|
...v == null ? void 0 : v(),
|
|
24724
24746
|
...me
|
|
24725
24747
|
}
|
|
24726
|
-
}))[0],
|
|
24727
|
-
model:
|
|
24728
|
-
ids: [
|
|
24748
|
+
}))[0], un = (await ConnectionProvider.getHandler().readObjects({
|
|
24749
|
+
model: ce,
|
|
24750
|
+
ids: [Xt],
|
|
24729
24751
|
fields: s.get("tree").fields,
|
|
24730
24752
|
context: {
|
|
24731
24753
|
...v == null ? void 0 : v(),
|
|
24732
24754
|
...me
|
|
24733
24755
|
}
|
|
24734
24756
|
}))[0];
|
|
24735
|
-
|
|
24736
|
-
id:
|
|
24757
|
+
_t.push({
|
|
24758
|
+
id: Xt,
|
|
24737
24759
|
operation: "pendingLink",
|
|
24738
24760
|
values: tn,
|
|
24739
|
-
treeValues:
|
|
24761
|
+
treeValues: un
|
|
24740
24762
|
});
|
|
24741
24763
|
}
|
|
24742
|
-
|
|
24743
|
-
} catch (
|
|
24744
|
-
E(
|
|
24764
|
+
Oe(_t);
|
|
24765
|
+
} catch (Xt) {
|
|
24766
|
+
E(Xt);
|
|
24745
24767
|
} finally {
|
|
24746
24768
|
T(!1);
|
|
24747
24769
|
}
|
|
24748
24770
|
};
|
|
24749
|
-
function
|
|
24750
|
-
const
|
|
24771
|
+
function xt() {
|
|
24772
|
+
const Ze = ViewObjects[c];
|
|
24751
24773
|
if (c === "graph")
|
|
24752
24774
|
return parseGraph(s.get("graph").arch).string;
|
|
24753
24775
|
{
|
|
24754
|
-
const
|
|
24755
|
-
return
|
|
24776
|
+
const _t = new Ze(s.get(c).fields);
|
|
24777
|
+
return _t.parse(s.get(c).arch), _t.string;
|
|
24756
24778
|
}
|
|
24757
24779
|
}
|
|
24758
|
-
const
|
|
24759
|
-
var
|
|
24780
|
+
const Pt = () => {
|
|
24781
|
+
var _t, en, Xt, tn;
|
|
24760
24782
|
if (c === "form")
|
|
24761
24783
|
return ve.length === 0 ? I("noCurrentEntries") : /* @__PURE__ */ jsx(Form$1, {
|
|
24762
24784
|
formView: s.get("form"),
|
|
24763
|
-
values: (
|
|
24785
|
+
values: (_t = ve[d]) == null ? void 0 : _t.values,
|
|
24764
24786
|
parentContext: {
|
|
24765
24787
|
...v == null ? void 0 : v(),
|
|
24766
24788
|
...me
|
|
24767
24789
|
},
|
|
24768
24790
|
ref: y,
|
|
24769
|
-
model:
|
|
24770
|
-
id: (
|
|
24791
|
+
model: ce,
|
|
24792
|
+
id: (en = ve[d]) == null ? void 0 : en.id,
|
|
24771
24793
|
submitMode: "values",
|
|
24772
|
-
onFieldsChange: (
|
|
24773
|
-
var
|
|
24774
|
-
const gn = (
|
|
24775
|
-
...
|
|
24776
|
-
operation:
|
|
24794
|
+
onFieldsChange: (un) => {
|
|
24795
|
+
var an;
|
|
24796
|
+
const gn = (an = ve[d]) == null ? void 0 : an.id, mn = l.map((fn) => fn.id === gn ? {
|
|
24797
|
+
...fn,
|
|
24798
|
+
operation: fn.operation === "original" ? "pendingUpdate" : fn.operation,
|
|
24777
24799
|
values: {
|
|
24778
|
-
...
|
|
24800
|
+
...un,
|
|
24779
24801
|
id: gn
|
|
24780
24802
|
},
|
|
24781
24803
|
treeValues: {
|
|
24782
|
-
...
|
|
24804
|
+
...un,
|
|
24783
24805
|
id: gn
|
|
24784
24806
|
}
|
|
24785
|
-
} :
|
|
24786
|
-
|
|
24807
|
+
} : fn);
|
|
24808
|
+
Oe(mn), O(!0);
|
|
24787
24809
|
},
|
|
24788
24810
|
readOnly: ie
|
|
24789
24811
|
});
|
|
24790
|
-
const
|
|
24791
|
-
resultsToSort: ve.map((
|
|
24812
|
+
const Ze = ne ? sortResults({
|
|
24813
|
+
resultsToSort: ve.map((un) => un.treeValues),
|
|
24792
24814
|
sorter: ne,
|
|
24793
24815
|
fields: {
|
|
24794
24816
|
...s.get("tree").fields,
|
|
24795
|
-
...((
|
|
24817
|
+
...((Xt = s.get("form")) == null ? void 0 : Xt.fields) || {}
|
|
24796
24818
|
}
|
|
24797
|
-
}) : ve.map((
|
|
24819
|
+
}) : ve.map((un) => un.treeValues);
|
|
24798
24820
|
if (c === "tree")
|
|
24799
24821
|
return /* @__PURE__ */ jsx(Tree, {
|
|
24800
24822
|
total: ve.length,
|
|
24801
24823
|
limit: ve.length,
|
|
24802
24824
|
treeView: s.get("tree"),
|
|
24803
|
-
results:
|
|
24825
|
+
results: Ze,
|
|
24804
24826
|
loading: S,
|
|
24805
|
-
onRowClicked: ((tn = s.get("form")) == null ? void 0 : tn.fields) !== void 0 ?
|
|
24827
|
+
onRowClicked: ((tn = s.get("form")) == null ? void 0 : tn.fields) !== void 0 ? it : void 0,
|
|
24806
24828
|
showPagination: !1,
|
|
24807
24829
|
rowSelection: {
|
|
24808
24830
|
selectedRowKeys: H,
|
|
@@ -24812,11 +24834,11 @@ const One2manyInput = (e) => {
|
|
|
24812
24834
|
onChangeSort: J
|
|
24813
24835
|
});
|
|
24814
24836
|
if (c === "graph") {
|
|
24815
|
-
const
|
|
24837
|
+
const un = [[`${a.inv_field}`, "=", h]];
|
|
24816
24838
|
return /* @__PURE__ */ jsx(Graph, {
|
|
24817
24839
|
view_id: s.get("graph").view_id,
|
|
24818
24840
|
model: a.relation,
|
|
24819
|
-
domain:
|
|
24841
|
+
domain: un,
|
|
24820
24842
|
context: {
|
|
24821
24843
|
...v == null ? void 0 : v(),
|
|
24822
24844
|
...me
|
|
@@ -24832,34 +24854,34 @@ const One2manyInput = (e) => {
|
|
|
24832
24854
|
type: "error",
|
|
24833
24855
|
banner: !0
|
|
24834
24856
|
});
|
|
24835
|
-
const
|
|
24857
|
+
const kt = U;
|
|
24836
24858
|
return S ? /* @__PURE__ */ jsx(Spin, {}) : /* @__PURE__ */ jsxs(Fragment, {
|
|
24837
24859
|
children: [/* @__PURE__ */ jsx(One2manyTopBar, {
|
|
24838
24860
|
mode: c,
|
|
24839
|
-
title:
|
|
24861
|
+
title: xt(),
|
|
24840
24862
|
readOnly: ie,
|
|
24841
24863
|
isMany2Many: te,
|
|
24842
24864
|
formHasChanges: x,
|
|
24843
24865
|
totalItems: ve.length,
|
|
24844
24866
|
currentItemIndex: d,
|
|
24845
|
-
onDelete:
|
|
24846
|
-
onCreateItem:
|
|
24867
|
+
onDelete: et,
|
|
24868
|
+
onCreateItem: Ht,
|
|
24847
24869
|
onToggleViewMode: ge,
|
|
24848
24870
|
onPreviousItem: Fe,
|
|
24849
|
-
onNextItem:
|
|
24850
|
-
onSearchItem:
|
|
24871
|
+
onNextItem: Te,
|
|
24872
|
+
onSearchItem: Jt,
|
|
24851
24873
|
selectedRowKeys: H,
|
|
24852
|
-
showCreateButton: ((
|
|
24874
|
+
showCreateButton: ((cn = s.get("form")) == null ? void 0 : cn.fields) !== void 0,
|
|
24853
24875
|
showToggleButton: s.size > 1
|
|
24854
|
-
}),
|
|
24876
|
+
}), Pt(), /* @__PURE__ */ jsx(FormModal, {
|
|
24855
24877
|
formView: s.get("form"),
|
|
24856
|
-
model:
|
|
24878
|
+
model: ce,
|
|
24857
24879
|
id: W == null ? void 0 : W.id,
|
|
24858
24880
|
submitMode: "values",
|
|
24859
24881
|
values: W == null ? void 0 : W.values,
|
|
24860
24882
|
defaultValues: W == null ? void 0 : W.defaultValues,
|
|
24861
24883
|
visible: P,
|
|
24862
|
-
onSubmitSucceed:
|
|
24884
|
+
onSubmitSucceed: jt,
|
|
24863
24885
|
parentContext: {
|
|
24864
24886
|
...v == null ? void 0 : v(),
|
|
24865
24887
|
...me
|
|
@@ -24868,17 +24890,17 @@ const One2manyInput = (e) => {
|
|
|
24868
24890
|
re(!1), B(!1);
|
|
24869
24891
|
},
|
|
24870
24892
|
readOnly: ie,
|
|
24871
|
-
mustClearAfterSave:
|
|
24893
|
+
mustClearAfterSave: kt
|
|
24872
24894
|
}), /* @__PURE__ */ jsx(SearchModal, {
|
|
24873
24895
|
domain: ae.current,
|
|
24874
|
-
model:
|
|
24896
|
+
model: ce,
|
|
24875
24897
|
context: {
|
|
24876
24898
|
...v == null ? void 0 : v(),
|
|
24877
24899
|
...me
|
|
24878
24900
|
},
|
|
24879
24901
|
visible: N,
|
|
24880
|
-
onSelectValues: async (
|
|
24881
|
-
L(!1),
|
|
24902
|
+
onSelectValues: async (Ze) => {
|
|
24903
|
+
L(!1), Qt(Ze);
|
|
24882
24904
|
},
|
|
24883
24905
|
onCloseModal: () => {
|
|
24884
24906
|
L(!1);
|
|
@@ -29765,7 +29787,7 @@ function FormActionBar({
|
|
|
29765
29787
|
w == null || w(!1);
|
|
29766
29788
|
}
|
|
29767
29789
|
}
|
|
29768
|
-
const
|
|
29790
|
+
const ce = c || v || y || C;
|
|
29769
29791
|
function me(Q) {
|
|
29770
29792
|
W == null || W({
|
|
29771
29793
|
actionData: Q,
|
|
@@ -29786,7 +29808,7 @@ function FormActionBar({
|
|
|
29786
29808
|
}), /* @__PURE__ */ jsx(ActionButton, {
|
|
29787
29809
|
icon: /* @__PURE__ */ jsx(SaveOutlined, {}),
|
|
29788
29810
|
tooltip: B("save"),
|
|
29789
|
-
disabled: !l ||
|
|
29811
|
+
disabled: !l || ce,
|
|
29790
29812
|
loading: c,
|
|
29791
29813
|
onClick: s
|
|
29792
29814
|
}), /* @__PURE__ */ jsx(ActionButton, {
|
|
@@ -29826,13 +29848,13 @@ function FormActionBar({
|
|
|
29826
29848
|
onChangeView: (Q) => {
|
|
29827
29849
|
E == null || E(o), S == null || S(!1), a == null || a(Q);
|
|
29828
29850
|
},
|
|
29829
|
-
disabled:
|
|
29851
|
+
disabled: ce,
|
|
29830
29852
|
formHasChanges: l
|
|
29831
29853
|
}), separator$2(), /* @__PURE__ */ jsxs(Space, {
|
|
29832
29854
|
children: [/* @__PURE__ */ jsx(ActionButton, {
|
|
29833
29855
|
icon: /* @__PURE__ */ jsx(LeftOutlined, {}),
|
|
29834
29856
|
tooltip: B("previous"),
|
|
29835
|
-
disabled:
|
|
29857
|
+
disabled: ce,
|
|
29836
29858
|
loading: !1,
|
|
29837
29859
|
onClick: () => {
|
|
29838
29860
|
re(ne);
|
|
@@ -29840,7 +29862,7 @@ function FormActionBar({
|
|
|
29840
29862
|
}), /* @__PURE__ */ jsx(ActionButton, {
|
|
29841
29863
|
icon: /* @__PURE__ */ jsx(RightOutlined, {}),
|
|
29842
29864
|
tooltip: B("next"),
|
|
29843
|
-
disabled:
|
|
29865
|
+
disabled: ce,
|
|
29844
29866
|
loading: !1,
|
|
29845
29867
|
onClick: () => {
|
|
29846
29868
|
re(ae);
|
|
@@ -29848,7 +29870,7 @@ function FormActionBar({
|
|
|
29848
29870
|
})]
|
|
29849
29871
|
}), separator$2(), /* @__PURE__ */ jsx(DropdownButton, {
|
|
29850
29872
|
icon: /* @__PURE__ */ jsx(ThunderboltOutlined, {}),
|
|
29851
|
-
disabled:
|
|
29873
|
+
disabled: ce,
|
|
29852
29874
|
tooltip: B("actions"),
|
|
29853
29875
|
items: e == null ? void 0 : e.action,
|
|
29854
29876
|
onItemClick: (Q) => {
|
|
@@ -29856,7 +29878,7 @@ function FormActionBar({
|
|
|
29856
29878
|
}
|
|
29857
29879
|
}), /* @__PURE__ */ jsx(DropdownButton, {
|
|
29858
29880
|
icon: /* @__PURE__ */ jsx(PrinterOutlined, {}),
|
|
29859
|
-
disabled:
|
|
29881
|
+
disabled: ce,
|
|
29860
29882
|
tooltip: B("reports"),
|
|
29861
29883
|
items: e == null ? void 0 : e.print,
|
|
29862
29884
|
onItemClick: (Q) => {
|
|
@@ -29870,7 +29892,7 @@ function FormActionBar({
|
|
|
29870
29892
|
}
|
|
29871
29893
|
}), /* @__PURE__ */ jsx(DropdownButton, {
|
|
29872
29894
|
icon: /* @__PURE__ */ jsx(EnterOutlined$4, {}),
|
|
29873
|
-
disabled:
|
|
29895
|
+
disabled: ce,
|
|
29874
29896
|
tooltip: B("related"),
|
|
29875
29897
|
items: e == null ? void 0 : e.relate,
|
|
29876
29898
|
onItemClick: async (Q) => {
|
|
@@ -29883,7 +29905,7 @@ function FormActionBar({
|
|
|
29883
29905
|
});
|
|
29884
29906
|
}
|
|
29885
29907
|
}), /* @__PURE__ */ jsx(AttachmentsButton, {
|
|
29886
|
-
disabled:
|
|
29908
|
+
disabled: ce,
|
|
29887
29909
|
attachments: x,
|
|
29888
29910
|
onAddNewAttachment: () => {
|
|
29889
29911
|
const Q = u, te = m;
|
|
@@ -30491,10 +30513,10 @@ function TreeActionBar(e) {
|
|
|
30491
30513
|
try {
|
|
30492
30514
|
l == null || l(!0), await ConnectionProvider.getHandler().delete({
|
|
30493
30515
|
model: f,
|
|
30494
|
-
ids: s.map((
|
|
30516
|
+
ids: s.map((ce) => ce.id)
|
|
30495
30517
|
}), h == null || h(void 0), m == null || m(void 0), (ie = p == null ? void 0 : p.current) == null || ie.refreshResults();
|
|
30496
|
-
} catch (
|
|
30497
|
-
showDialog$8(
|
|
30518
|
+
} catch (ce) {
|
|
30519
|
+
showDialog$8(ce);
|
|
30498
30520
|
} finally {
|
|
30499
30521
|
l == null || l(!1);
|
|
30500
30522
|
}
|
|
@@ -30503,16 +30525,16 @@ function TreeActionBar(e) {
|
|
|
30503
30525
|
var ie;
|
|
30504
30526
|
try {
|
|
30505
30527
|
d == null || d(!0);
|
|
30506
|
-
const
|
|
30528
|
+
const ce = s[0].id;
|
|
30507
30529
|
await ConnectionProvider.getHandler().duplicate({
|
|
30508
|
-
id:
|
|
30530
|
+
id: ce,
|
|
30509
30531
|
model: f,
|
|
30510
30532
|
context: {
|
|
30511
30533
|
...E
|
|
30512
30534
|
}
|
|
30513
30535
|
}) && ((ie = p == null ? void 0 : p.current) == null || ie.refreshResults());
|
|
30514
|
-
} catch (
|
|
30515
|
-
showDialog$8(
|
|
30536
|
+
} catch (ce) {
|
|
30537
|
+
showDialog$8(ce);
|
|
30516
30538
|
} finally {
|
|
30517
30539
|
d == null || d(!1);
|
|
30518
30540
|
}
|
|
@@ -30521,18 +30543,18 @@ function TreeActionBar(e) {
|
|
|
30521
30543
|
K == null || K({
|
|
30522
30544
|
actionData: ie,
|
|
30523
30545
|
values: {
|
|
30524
|
-
active_id: s == null ? void 0 : s.map((
|
|
30525
|
-
active_ids: s == null ? void 0 : s.map((
|
|
30546
|
+
active_id: s == null ? void 0 : s.map((ce) => ce.id)[0],
|
|
30547
|
+
active_ids: s == null ? void 0 : s.map((ce) => ce.id)
|
|
30526
30548
|
},
|
|
30527
30549
|
fields: {},
|
|
30528
30550
|
context: {
|
|
30529
30551
|
...E,
|
|
30530
|
-
active_id: s == null ? void 0 : s.map((
|
|
30531
|
-
active_ids: s == null ? void 0 : s.map((
|
|
30552
|
+
active_id: s == null ? void 0 : s.map((ce) => ce.id)[0],
|
|
30553
|
+
active_ids: s == null ? void 0 : s.map((ce) => ce.id)
|
|
30532
30554
|
},
|
|
30533
30555
|
onRefreshParentValues: () => {
|
|
30534
|
-
var
|
|
30535
|
-
(
|
|
30556
|
+
var ce;
|
|
30557
|
+
(ce = p == null ? void 0 : p.current) == null || ce.refreshResults();
|
|
30536
30558
|
}
|
|
30537
30559
|
});
|
|
30538
30560
|
}
|
|
@@ -30618,7 +30640,7 @@ function TreeActionBar(e) {
|
|
|
30618
30640
|
...ie,
|
|
30619
30641
|
datas: {
|
|
30620
30642
|
...ie.datas || {},
|
|
30621
|
-
ids: s.map((
|
|
30643
|
+
ids: s.map((ce) => ce.id)
|
|
30622
30644
|
}
|
|
30623
30645
|
});
|
|
30624
30646
|
}
|
|
@@ -30661,15 +30683,15 @@ function TreeActionBar(e) {
|
|
|
30661
30683
|
}],
|
|
30662
30684
|
onItemClick: (ie) => {
|
|
30663
30685
|
if (ie.id === "print_screen") {
|
|
30664
|
-
let
|
|
30665
|
-
|
|
30686
|
+
let ce = (s == null ? void 0 : s.map((me) => me.id)) || [];
|
|
30687
|
+
ce.length === 0 && (ce = (S == null ? void 0 : S.map((me) => me.id)) || []), J({
|
|
30666
30688
|
id: -1,
|
|
30667
30689
|
model: f,
|
|
30668
30690
|
report_name: "printscreen.list",
|
|
30669
30691
|
type: "ir.actions.report.xml",
|
|
30670
30692
|
datas: {
|
|
30671
30693
|
model: f,
|
|
30672
|
-
ids:
|
|
30694
|
+
ids: ce
|
|
30673
30695
|
}
|
|
30674
30696
|
});
|
|
30675
30697
|
return;
|
|
@@ -30848,133 +30870,133 @@ function ActionView(e, r) {
|
|
|
30848
30870
|
action_type: v,
|
|
30849
30871
|
treeExpandable: C = !1,
|
|
30850
30872
|
limit: w
|
|
30851
|
-
} = e, [I, y] = useState$1(), [x, O] = useState$1([]), [S, T] = useState$1(!0), G = m || void 0, [E, P] = useState$1(G), [B, N] = useState$1([]), [L, W] = useState$1(), [K, H] = useState$1([]), [z, U] = useState$1(), [re, ae] = useState$1(0), [ne, J] = useState$1(!1), [oe, ie] = useState$1(!1), [
|
|
30873
|
+
} = e, [I, y] = useState$1(), [x, O] = useState$1([]), [S, T] = useState$1(!0), G = m || void 0, [E, P] = useState$1(G), [B, N] = useState$1([]), [L, W] = useState$1(), [K, H] = useState$1([]), [z, U] = useState$1(), [re, ae] = useState$1(0), [ne, J] = useState$1(!1), [oe, ie] = useState$1(!1), [ce, me] = useState$1(), {
|
|
30852
30874
|
t: Q
|
|
30853
30875
|
} = useContext(LocaleContext), te = useRef(), he = useRef(), ve = useContext(TabManagerContext), {
|
|
30854
|
-
setCurrentView:
|
|
30876
|
+
setCurrentView: Oe,
|
|
30855
30877
|
setCurrentId: D,
|
|
30856
30878
|
tabs: M,
|
|
30857
|
-
activeKey:
|
|
30879
|
+
activeKey: pe,
|
|
30858
30880
|
openAction: ge
|
|
30859
30881
|
} = ve || {};
|
|
30860
|
-
useHotkeys("ctrl+g,command+g", (
|
|
30861
|
-
|
|
30862
|
-
}, [
|
|
30863
|
-
function Fe(
|
|
30864
|
-
P(
|
|
30882
|
+
useHotkeys("ctrl+g,command+g", (Pe) => {
|
|
30883
|
+
Pe.preventDefault(), et();
|
|
30884
|
+
}, [pe, M, I, L, K]);
|
|
30885
|
+
function Fe(Pe) {
|
|
30886
|
+
P(Pe), D == null || D(Pe);
|
|
30865
30887
|
}
|
|
30866
|
-
function
|
|
30867
|
-
y(
|
|
30888
|
+
function Te(Pe) {
|
|
30889
|
+
y(Pe), Oe == null || Oe(Pe);
|
|
30868
30890
|
}
|
|
30869
30891
|
useImperativeHandle(r, () => ({
|
|
30870
30892
|
canWeClose: Ae
|
|
30871
30893
|
}));
|
|
30872
30894
|
const Re = async () => {
|
|
30873
30895
|
T(!0);
|
|
30874
|
-
const
|
|
30875
|
-
for (const
|
|
30876
|
-
const [
|
|
30877
|
-
let
|
|
30896
|
+
const Pe = [];
|
|
30897
|
+
for (const it of l) {
|
|
30898
|
+
const [Qt, xt] = it;
|
|
30899
|
+
let Pt;
|
|
30878
30900
|
try {
|
|
30879
|
-
|
|
30901
|
+
xt !== "dashboard" && (Pt = await ConnectionProvider.getHandler().getView({
|
|
30880
30902
|
model: a,
|
|
30881
|
-
type:
|
|
30882
|
-
id:
|
|
30903
|
+
type: xt,
|
|
30904
|
+
id: Qt,
|
|
30883
30905
|
context: s
|
|
30884
30906
|
}));
|
|
30885
|
-
} catch (
|
|
30886
|
-
console.error(`${a} - ${
|
|
30907
|
+
} catch (kt) {
|
|
30908
|
+
console.error(`${a} - ${xt}\xA0- ${JSON.stringify(kt, null, 2)}`);
|
|
30887
30909
|
continue;
|
|
30888
30910
|
}
|
|
30889
|
-
switch (
|
|
30911
|
+
switch (xt) {
|
|
30890
30912
|
case "dashboard": {
|
|
30891
|
-
const
|
|
30892
|
-
const [,
|
|
30893
|
-
return
|
|
30913
|
+
const kt = l.find((Ze) => {
|
|
30914
|
+
const [, _t] = Ze;
|
|
30915
|
+
return _t === "form";
|
|
30894
30916
|
});
|
|
30895
|
-
let
|
|
30896
|
-
|
|
30917
|
+
let cn;
|
|
30918
|
+
kt && (cn = {
|
|
30897
30919
|
action_id: g,
|
|
30898
30920
|
action_type: v,
|
|
30899
30921
|
name: c,
|
|
30900
30922
|
res_id: s.active_id,
|
|
30901
30923
|
res_model: a,
|
|
30902
|
-
view_id:
|
|
30903
|
-
view_type:
|
|
30904
|
-
}),
|
|
30924
|
+
view_id: kt[0],
|
|
30925
|
+
view_type: kt[1]
|
|
30926
|
+
}), Pe.push({
|
|
30905
30927
|
type: "dashboard",
|
|
30906
30928
|
id: s.active_id,
|
|
30907
30929
|
model: a,
|
|
30908
30930
|
context: s,
|
|
30909
|
-
configAction:
|
|
30931
|
+
configAction: cn
|
|
30910
30932
|
});
|
|
30911
30933
|
break;
|
|
30912
30934
|
}
|
|
30913
30935
|
case "form": {
|
|
30914
|
-
|
|
30915
|
-
...
|
|
30916
|
-
type:
|
|
30936
|
+
Pe.push({
|
|
30937
|
+
...Pt,
|
|
30938
|
+
type: xt
|
|
30917
30939
|
});
|
|
30918
30940
|
break;
|
|
30919
30941
|
}
|
|
30920
30942
|
case "tree": {
|
|
30921
|
-
|
|
30922
|
-
...
|
|
30943
|
+
Pe.push({
|
|
30944
|
+
...Pt,
|
|
30923
30945
|
isExpandable: C,
|
|
30924
|
-
type:
|
|
30946
|
+
type: xt
|
|
30925
30947
|
});
|
|
30926
30948
|
break;
|
|
30927
30949
|
}
|
|
30928
30950
|
case "graph": {
|
|
30929
|
-
|
|
30930
|
-
...
|
|
30931
|
-
type:
|
|
30951
|
+
Pe.push({
|
|
30952
|
+
...Pt,
|
|
30953
|
+
type: xt
|
|
30932
30954
|
});
|
|
30933
30955
|
break;
|
|
30934
30956
|
}
|
|
30935
30957
|
}
|
|
30936
30958
|
}
|
|
30937
|
-
let
|
|
30938
|
-
!f &&
|
|
30939
|
-
Please, make sure the view ids on the fields_view_get responses are the same as the ones defined in the action`),
|
|
30959
|
+
let jt;
|
|
30960
|
+
!f && Pe.find((it) => it.type === "tree") ? jt = Pe.find((Qt) => Qt.type === "tree") : f ? jt = Pe.find((Qt) => f.id ? Qt.type === f.type && Qt.view_id === f.id : Qt.type === f.type) : jt = Pe.find((Qt) => Qt.type === "form"), jt || showDialog$8(`Error determining the first view to show.
|
|
30961
|
+
Please, make sure the view ids on the fields_view_get responses are the same as the ones defined in the action`), Te(jt), O(Pe), T(!1);
|
|
30940
30962
|
};
|
|
30941
30963
|
u({
|
|
30942
30964
|
tabKey: d,
|
|
30943
30965
|
canWeClose: Ae
|
|
30944
30966
|
}), useEffect(() => {
|
|
30945
|
-
const
|
|
30946
|
-
|
|
30967
|
+
const Pe = x.find((it) => it.type === "tree"), jt = x.find((it) => f.id ? it.type === f.type && it.view_id === f.id : it.type === f.type);
|
|
30968
|
+
Te(jt || Pe), m ? D == null || D(G) : (Fe(void 0), W(void 0)), Re();
|
|
30947
30969
|
}, [a, l, m]), useEffect(() => {
|
|
30948
|
-
|
|
30949
|
-
}, [M,
|
|
30970
|
+
pe === d && (D == null || D(E), Oe == null || Oe(I));
|
|
30971
|
+
}, [M, pe]);
|
|
30950
30972
|
async function Ae() {
|
|
30951
30973
|
return I.type === "form" ? await te.current.cancelUnsavedChanges() : !0;
|
|
30952
30974
|
}
|
|
30953
|
-
async function
|
|
30954
|
-
|
|
30975
|
+
async function et() {
|
|
30976
|
+
pe === d && (I.type === "form" && !await te.current.cancelUnsavedChanges() || J(!0));
|
|
30955
30977
|
}
|
|
30956
|
-
async function
|
|
30957
|
-
var
|
|
30978
|
+
async function Ht(Pe) {
|
|
30979
|
+
var xt;
|
|
30958
30980
|
ie(!0);
|
|
30959
|
-
const
|
|
30960
|
-
let
|
|
30961
|
-
if (
|
|
30981
|
+
const jt = K.findIndex((Pt) => Pt.id === Pe);
|
|
30982
|
+
let it;
|
|
30983
|
+
if (jt === -1) {
|
|
30962
30984
|
try {
|
|
30963
|
-
|
|
30985
|
+
it = (xt = await ConnectionProvider.getHandler().readObjects({
|
|
30964
30986
|
model: a,
|
|
30965
|
-
ids: [
|
|
30987
|
+
ids: [Pe],
|
|
30966
30988
|
context: s
|
|
30967
|
-
})) == null ? void 0 :
|
|
30989
|
+
})) == null ? void 0 : xt[0];
|
|
30968
30990
|
} catch {
|
|
30969
30991
|
}
|
|
30970
|
-
if (!
|
|
30992
|
+
if (!it) {
|
|
30971
30993
|
ie(!1), J(!1), showDialog$7(Q("idNotFound"));
|
|
30972
30994
|
return;
|
|
30973
30995
|
}
|
|
30974
30996
|
} else
|
|
30975
|
-
|
|
30997
|
+
it = K[jt];
|
|
30976
30998
|
ie(!1), J(!1);
|
|
30977
|
-
const
|
|
30999
|
+
const Qt = l.find((Pt) => Pt[1] === "form");
|
|
30978
31000
|
ge({
|
|
30979
31001
|
domain: [],
|
|
30980
31002
|
context: s,
|
|
@@ -30983,23 +31005,23 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
30983
31005
|
title: c,
|
|
30984
31006
|
target: "current",
|
|
30985
31007
|
initialView: {
|
|
30986
|
-
id:
|
|
31008
|
+
id: Qt == null ? void 0 : Qt[0],
|
|
30987
31009
|
type: "form"
|
|
30988
31010
|
},
|
|
30989
31011
|
action_id: g,
|
|
30990
31012
|
action_type: v,
|
|
30991
|
-
res_id:
|
|
31013
|
+
res_id: Pe
|
|
30992
31014
|
});
|
|
30993
31015
|
}
|
|
30994
|
-
function
|
|
30995
|
-
return x.map((
|
|
30996
|
-
switch (
|
|
31016
|
+
function Jt() {
|
|
31017
|
+
return x.map((Pe) => {
|
|
31018
|
+
switch (Pe.type) {
|
|
30997
31019
|
case "form":
|
|
30998
31020
|
return /* @__PURE__ */ jsx(FormActionView, {
|
|
30999
31021
|
formRef: te,
|
|
31000
31022
|
currentId: E,
|
|
31001
|
-
visible: I.type ===
|
|
31002
|
-
formView:
|
|
31023
|
+
visible: I.type === Pe.type && I.view_id === Pe.view_id,
|
|
31024
|
+
formView: Pe,
|
|
31003
31025
|
model: a,
|
|
31004
31026
|
context: s,
|
|
31005
31027
|
domain: o,
|
|
@@ -31008,58 +31030,58 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
31008
31030
|
results: K,
|
|
31009
31031
|
setResults: H,
|
|
31010
31032
|
setCurrentItemIndex: W
|
|
31011
|
-
}, `${
|
|
31033
|
+
}, `${Pe.type}-${Pe.view_id}`);
|
|
31012
31034
|
case "tree":
|
|
31013
31035
|
return /* @__PURE__ */ jsx(TreeActionView, {
|
|
31014
|
-
visible: I.type ===
|
|
31036
|
+
visible: I.type === Pe.type && I.view_id === Pe.view_id,
|
|
31015
31037
|
limit: w,
|
|
31016
31038
|
model: a,
|
|
31017
31039
|
context: s,
|
|
31018
31040
|
domain: o,
|
|
31019
|
-
formView: x.find((
|
|
31020
|
-
treeView:
|
|
31041
|
+
formView: x.find((jt) => jt.type === "form"),
|
|
31042
|
+
treeView: Pe,
|
|
31021
31043
|
searchTreeRef: he,
|
|
31022
|
-
searchTreeNameSearch:
|
|
31044
|
+
searchTreeNameSearch: ce,
|
|
31023
31045
|
availableViews: x,
|
|
31024
31046
|
results: K,
|
|
31025
31047
|
setCurrentItemIndex: W,
|
|
31026
31048
|
setCurrentId: Fe,
|
|
31027
|
-
setCurrentView:
|
|
31028
|
-
}, `${
|
|
31049
|
+
setCurrentView: Te
|
|
31050
|
+
}, `${Pe.type}-${Pe.view_id}`);
|
|
31029
31051
|
case "graph":
|
|
31030
31052
|
return /* @__PURE__ */ jsx(GraphActionView, {
|
|
31031
|
-
visible: I.type ===
|
|
31032
|
-
viewData:
|
|
31053
|
+
visible: I.type === Pe.type && I.view_id === Pe.view_id,
|
|
31054
|
+
viewData: Pe,
|
|
31033
31055
|
model: a,
|
|
31034
31056
|
context: s,
|
|
31035
31057
|
domain: o,
|
|
31036
|
-
treeView: x.find((
|
|
31037
|
-
formView: x.find((
|
|
31038
|
-
}, `${
|
|
31058
|
+
treeView: x.find((jt) => jt.type === "tree"),
|
|
31059
|
+
formView: x.find((jt) => jt.type === "form")
|
|
31060
|
+
}, `${Pe.type}-${Pe.view_id}`);
|
|
31039
31061
|
case "dashboard":
|
|
31040
31062
|
return /* @__PURE__ */ jsx(DashboardActionView, {
|
|
31041
|
-
dashboardData:
|
|
31042
|
-
}, `${
|
|
31063
|
+
dashboardData: Pe
|
|
31064
|
+
}, `${Pe.type}-${Pe.view_id}`);
|
|
31043
31065
|
}
|
|
31044
31066
|
});
|
|
31045
31067
|
}
|
|
31046
|
-
function
|
|
31068
|
+
function Yt() {
|
|
31047
31069
|
if (E === void 0 && I.type === "form")
|
|
31048
31070
|
te.current.clearAndReload();
|
|
31049
31071
|
else {
|
|
31050
31072
|
Fe(void 0);
|
|
31051
|
-
const
|
|
31052
|
-
|
|
31073
|
+
const Pe = x.find((jt) => jt.type === "form");
|
|
31074
|
+
Te(Pe);
|
|
31053
31075
|
}
|
|
31054
31076
|
}
|
|
31055
31077
|
return S ? /* @__PURE__ */ jsx(Spin, {}) : I ? /* @__PURE__ */ jsxs(ActionViewProvider, {
|
|
31056
31078
|
title: c,
|
|
31057
31079
|
currentView: I,
|
|
31058
|
-
setCurrentView:
|
|
31080
|
+
setCurrentView: Te,
|
|
31059
31081
|
availableViews: x,
|
|
31060
31082
|
formRef: te,
|
|
31061
31083
|
searchTreeRef: he,
|
|
31062
|
-
onNewClicked:
|
|
31084
|
+
onNewClicked: Yt,
|
|
31063
31085
|
currentId: E,
|
|
31064
31086
|
setCurrentId: Fe,
|
|
31065
31087
|
setCurrentItemIndex: W,
|
|
@@ -31074,12 +31096,12 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
31074
31096
|
selectedRowItems: B,
|
|
31075
31097
|
setSelectedRowItems: N,
|
|
31076
31098
|
setSearchTreeNameSearch: me,
|
|
31077
|
-
searchTreeNameSearch:
|
|
31078
|
-
goToResourceId:
|
|
31099
|
+
searchTreeNameSearch: ce,
|
|
31100
|
+
goToResourceId: Ht,
|
|
31079
31101
|
limit: w,
|
|
31080
|
-
children: [
|
|
31102
|
+
children: [Jt(), /* @__PURE__ */ jsx(GoToResourceModal, {
|
|
31081
31103
|
visible: ne,
|
|
31082
|
-
onIdSubmitted:
|
|
31104
|
+
onIdSubmitted: Ht,
|
|
31083
31105
|
isSearching: oe,
|
|
31084
31106
|
onCancel: () => {
|
|
31085
31107
|
J(!1);
|
|
@@ -31278,13 +31300,13 @@ function DashboardTree(e) {
|
|
|
31278
31300
|
parentContext: u = {}
|
|
31279
31301
|
} = e, [d, f] = useState$1(!1), [p, h] = useState$1(!1), [m, g] = useState$1(), [v, C] = useState$1(), [w, I] = useState$1(), [y, x] = useState$1(1), [O, S] = useState$1(0), T = useRef(DEFAULT_SEARCH_LIMIT), G = useRef([]), [E, P] = useState$1(0), [B, N] = useState$1([]), [L, W] = useState$1(void 0), [K, H] = useState$1(), [z, U] = useState$1(), [re, ae] = useState$1(), [ne, J] = useState$1(!1), oe = useRef([]), ie = (D) => {
|
|
31280
31302
|
J(!0), x(D), S((D - 1) * T.current);
|
|
31281
|
-
},
|
|
31303
|
+
}, ce = async () => {
|
|
31282
31304
|
const D = oe.current.length > 0 ? oe.current : l, M = mergeParams(G.current, D), {
|
|
31283
|
-
colors:
|
|
31305
|
+
colors: pe
|
|
31284
31306
|
} = getTree(v), {
|
|
31285
31307
|
totalItems: ge,
|
|
31286
31308
|
results: Fe,
|
|
31287
|
-
attrsEvaluated:
|
|
31309
|
+
attrsEvaluated: Te
|
|
31288
31310
|
} = await ConnectionProvider.getHandler().searchForTree({
|
|
31289
31311
|
params: M,
|
|
31290
31312
|
limit: T.current,
|
|
@@ -31292,11 +31314,11 @@ function DashboardTree(e) {
|
|
|
31292
31314
|
model: m,
|
|
31293
31315
|
fields: v.fields,
|
|
31294
31316
|
context: u,
|
|
31295
|
-
attrs:
|
|
31296
|
-
colors:
|
|
31317
|
+
attrs: pe && {
|
|
31318
|
+
colors: pe
|
|
31297
31319
|
}
|
|
31298
31320
|
}), Re = await ge;
|
|
31299
|
-
P(Re), W(getColorMap(
|
|
31321
|
+
P(Re), W(getColorMap(Te));
|
|
31300
31322
|
const Ae = sortResults({
|
|
31301
31323
|
resultsToSort: Fe,
|
|
31302
31324
|
sorter: K,
|
|
@@ -31308,7 +31330,7 @@ function DashboardTree(e) {
|
|
|
31308
31330
|
N(Ae);
|
|
31309
31331
|
}, me = async () => {
|
|
31310
31332
|
try {
|
|
31311
|
-
J(!0), await
|
|
31333
|
+
J(!0), await ce();
|
|
31312
31334
|
} catch (D) {
|
|
31313
31335
|
U(JSON.stringify(D));
|
|
31314
31336
|
} finally {
|
|
@@ -31361,7 +31383,7 @@ function DashboardTree(e) {
|
|
|
31361
31383
|
model: m,
|
|
31362
31384
|
treeView: v
|
|
31363
31385
|
});
|
|
31364
|
-
},
|
|
31386
|
+
}, Oe = () => !v || !w ? null : /* @__PURE__ */ jsxs("div", {
|
|
31365
31387
|
style: {
|
|
31366
31388
|
overflowY: "scroll"
|
|
31367
31389
|
},
|
|
@@ -31405,7 +31427,7 @@ function DashboardTree(e) {
|
|
|
31405
31427
|
style: {
|
|
31406
31428
|
padding: "2rem"
|
|
31407
31429
|
}
|
|
31408
|
-
}) :
|
|
31430
|
+
}) : Oe();
|
|
31409
31431
|
}
|
|
31410
31432
|
const DashboardForm = (e) => {
|
|
31411
31433
|
const {
|
|
@@ -31594,11 +31616,11 @@ function Dashboard(e, r) {
|
|
|
31594
31616
|
initialView: oe,
|
|
31595
31617
|
limit: ie
|
|
31596
31618
|
} = B;
|
|
31597
|
-
let
|
|
31619
|
+
let ce = {};
|
|
31598
31620
|
try {
|
|
31599
|
-
|
|
31621
|
+
ce = JSON.parse(L.replace(/'/g, '"'));
|
|
31600
31622
|
} catch {
|
|
31601
|
-
|
|
31623
|
+
ce = {
|
|
31602
31624
|
x: P * 2,
|
|
31603
31625
|
y: 0,
|
|
31604
31626
|
w: 2,
|
|
@@ -31625,26 +31647,26 @@ function Dashboard(e, r) {
|
|
|
31625
31647
|
domain: J,
|
|
31626
31648
|
view_id: re.filter((he) => he[1] === "tree")[0][0],
|
|
31627
31649
|
onRowClicked: (he) => {
|
|
31628
|
-
const ve = re.find((
|
|
31629
|
-
const [, D] =
|
|
31650
|
+
const ve = re.find((Oe) => {
|
|
31651
|
+
const [, D] = Oe;
|
|
31630
31652
|
return D === "form";
|
|
31631
31653
|
});
|
|
31632
31654
|
if (ve) {
|
|
31633
|
-
const [
|
|
31655
|
+
const [Oe, D] = ve, {
|
|
31634
31656
|
actionId: M,
|
|
31635
|
-
actionType:
|
|
31657
|
+
actionType: pe,
|
|
31636
31658
|
title: ge,
|
|
31637
31659
|
model: Fe
|
|
31638
|
-
} = B,
|
|
31660
|
+
} = B, Te = {
|
|
31639
31661
|
action_id: M,
|
|
31640
|
-
action_type:
|
|
31662
|
+
action_type: pe,
|
|
31641
31663
|
name: ge,
|
|
31642
31664
|
res_id: he.id,
|
|
31643
31665
|
res_model: Fe,
|
|
31644
|
-
view_id:
|
|
31666
|
+
view_id: Oe,
|
|
31645
31667
|
view_type: D
|
|
31646
31668
|
};
|
|
31647
|
-
g(
|
|
31669
|
+
g(Te);
|
|
31648
31670
|
}
|
|
31649
31671
|
}
|
|
31650
31672
|
});
|
|
@@ -31675,17 +31697,17 @@ function Dashboard(e, r) {
|
|
|
31675
31697
|
});
|
|
31676
31698
|
if (te) {
|
|
31677
31699
|
const [he, ve] = te, {
|
|
31678
|
-
actionId:
|
|
31700
|
+
actionId: Oe,
|
|
31679
31701
|
actionType: D,
|
|
31680
31702
|
title: M,
|
|
31681
|
-
model:
|
|
31703
|
+
model: pe
|
|
31682
31704
|
} = B;
|
|
31683
31705
|
Q = {
|
|
31684
|
-
action_id:
|
|
31706
|
+
action_id: Oe,
|
|
31685
31707
|
action_type: D,
|
|
31686
31708
|
name: M,
|
|
31687
31709
|
res_id: !1,
|
|
31688
|
-
res_model:
|
|
31710
|
+
res_model: pe,
|
|
31689
31711
|
view_id: he,
|
|
31690
31712
|
view_type: ve
|
|
31691
31713
|
};
|
|
@@ -31693,7 +31715,7 @@ function Dashboard(e, r) {
|
|
|
31693
31715
|
return /* @__PURE__ */ jsx(DashboardGridItem, {
|
|
31694
31716
|
id: W,
|
|
31695
31717
|
title: U,
|
|
31696
|
-
parms:
|
|
31718
|
+
parms: ce,
|
|
31697
31719
|
action: Q,
|
|
31698
31720
|
openAction: g,
|
|
31699
31721
|
children: me
|
|
@@ -31746,6 +31768,7 @@ const Dashboard$1 = forwardRef(Dashboard), MultiCheckbox = (e) => {
|
|
|
31746
31768
|
fields: I == null ? void 0 : I.getFields(),
|
|
31747
31769
|
values: I.getPlainValues()
|
|
31748
31770
|
}),
|
|
31771
|
+
fields: I == null ? void 0 : I.getFields(),
|
|
31749
31772
|
context: I.getContext()
|
|
31750
31773
|
});
|
|
31751
31774
|
E = [...E, ...P];
|
|
@@ -32053,16 +32076,16 @@ function RootView(e, r) {
|
|
|
32053
32076
|
ie.push([he, te]);
|
|
32054
32077
|
}
|
|
32055
32078
|
}
|
|
32056
|
-
let
|
|
32079
|
+
let ce;
|
|
32057
32080
|
if (G) {
|
|
32058
32081
|
const [me, Q] = ie.find(([te, he]) => he === G);
|
|
32059
|
-
|
|
32082
|
+
ce = {
|
|
32060
32083
|
id: me,
|
|
32061
32084
|
type: Q
|
|
32062
32085
|
};
|
|
32063
32086
|
} else {
|
|
32064
32087
|
const [me, Q] = ie[0];
|
|
32065
|
-
|
|
32088
|
+
ce = {
|
|
32066
32089
|
id: me,
|
|
32067
32090
|
type: Q
|
|
32068
32091
|
};
|
|
@@ -32077,7 +32100,7 @@ function RootView(e, r) {
|
|
|
32077
32100
|
views: ie,
|
|
32078
32101
|
title: re,
|
|
32079
32102
|
target: ae,
|
|
32080
|
-
initialView:
|
|
32103
|
+
initialView: ce,
|
|
32081
32104
|
action_type: N,
|
|
32082
32105
|
action_id: W,
|
|
32083
32106
|
values: S,
|
|
@@ -32136,6 +32159,7 @@ function RootView(e, r) {
|
|
|
32136
32159
|
...a
|
|
32137
32160
|
}
|
|
32138
32161
|
}),
|
|
32162
|
+
fields: S,
|
|
32139
32163
|
context: {
|
|
32140
32164
|
...s,
|
|
32141
32165
|
...ae
|
|
@@ -32185,10 +32209,10 @@ function RootView(e, r) {
|
|
|
32185
32209
|
view_type: U,
|
|
32186
32210
|
limit: re
|
|
32187
32211
|
} = B, ae = U === "tree", ne = [];
|
|
32188
|
-
for (const
|
|
32189
|
-
const [me, Q] =
|
|
32212
|
+
for (const ce of K) {
|
|
32213
|
+
const [me, Q] = ce;
|
|
32190
32214
|
if (me)
|
|
32191
|
-
ne.push(
|
|
32215
|
+
ne.push(ce);
|
|
32192
32216
|
else if (Q === "dashboard")
|
|
32193
32217
|
ne.push([void 0, "dashboard"]);
|
|
32194
32218
|
else {
|
|
@@ -32208,10 +32232,10 @@ function RootView(e, r) {
|
|
|
32208
32232
|
}
|
|
32209
32233
|
let J, oe;
|
|
32210
32234
|
if (E == null) {
|
|
32211
|
-
const
|
|
32212
|
-
J = void 0, oe =
|
|
32235
|
+
const ce = ne.find((me) => me[0] === void 0);
|
|
32236
|
+
J = void 0, oe = ce[1];
|
|
32213
32237
|
} else
|
|
32214
|
-
[J, oe] = ne.find((
|
|
32238
|
+
[J, oe] = ne.find((ce) => ce[0] === void 0 ? !1 : ce[0] === E);
|
|
32215
32239
|
const ie = {
|
|
32216
32240
|
id: J,
|
|
32217
32241
|
type: oe
|