@gisce/react-ooui 1.2.0-rc.22 → 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/helpers/formHelper.d.ts +2 -1
- package/dist/helpers/formHelper.d.ts.map +1 -1
- package/dist/react-ooui.es.js +1161 -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/widgets/views/Form.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/helpers/formHelper.ts +21 -2
- 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: [],
|
|
@@ -17787,18 +17803,18 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17787
17803
|
setLimit: S,
|
|
17788
17804
|
searchParams: T = [],
|
|
17789
17805
|
setSearchValues: G
|
|
17790
|
-
} = 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),
|
|
17791
|
-
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]);
|
|
17792
17808
|
}, []), te = useCallback(() => I || ne, [I, ne]), he = useCallback(async () => {
|
|
17793
|
-
const
|
|
17809
|
+
const Te = await ConnectionProvider.getHandler().nameSearch({
|
|
17794
17810
|
model: r,
|
|
17795
17811
|
payload: u,
|
|
17796
|
-
limit:
|
|
17812
|
+
limit: ce.current,
|
|
17797
17813
|
attrs: y,
|
|
17798
17814
|
context: f
|
|
17799
17815
|
});
|
|
17800
|
-
if (ae(
|
|
17801
|
-
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({
|
|
17802
17818
|
model: r,
|
|
17803
17819
|
ids: Re,
|
|
17804
17820
|
arch: h == null ? void 0 : h.arch,
|
|
@@ -17807,14 +17823,14 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17807
17823
|
attrs: Ae && {
|
|
17808
17824
|
colors: Ae
|
|
17809
17825
|
}
|
|
17810
|
-
}),
|
|
17811
|
-
me.current = [...
|
|
17812
|
-
const
|
|
17813
|
-
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,
|
|
17814
17830
|
sorter: g,
|
|
17815
17831
|
fields: { ...h.fields, ...m.fields }
|
|
17816
17832
|
}) : [...me.current];
|
|
17817
|
-
Q(
|
|
17833
|
+
Q(Yt), Jt.length > 0 ? C == null || C(0) : C == null || C(void 0);
|
|
17818
17834
|
} else
|
|
17819
17835
|
Q([]), C == null || C(void 0);
|
|
17820
17836
|
d.current = !0;
|
|
@@ -17831,31 +17847,31 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17831
17847
|
C,
|
|
17832
17848
|
p
|
|
17833
17849
|
]), ve = useCallback(
|
|
17834
|
-
async (
|
|
17835
|
-
const { params: Re, newOffset: Ae } =
|
|
17836
|
-
params:
|
|
17837
|
-
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,
|
|
17838
17854
|
offset: Ae || z,
|
|
17839
17855
|
model: r,
|
|
17840
17856
|
fields: h.field_parent ? { ...h.fields, [h.field_parent]: {} } : h.fields,
|
|
17841
17857
|
context: f,
|
|
17842
|
-
attrs:
|
|
17858
|
+
attrs: Ht && { colors: Ht }
|
|
17843
17859
|
});
|
|
17844
|
-
ie(getColorMap(
|
|
17845
|
-
const
|
|
17846
|
-
resultsToSort:
|
|
17860
|
+
ie(getColorMap(Pe)), me.current = [...Yt];
|
|
17861
|
+
const jt = g !== void 0 ? sortResults({
|
|
17862
|
+
resultsToSort: Yt,
|
|
17847
17863
|
sorter: g,
|
|
17848
17864
|
fields: { ...h.fields, ...m.fields }
|
|
17849
17865
|
}) : [...me.current];
|
|
17850
|
-
if (Q(
|
|
17851
|
-
const
|
|
17852
|
-
(
|
|
17866
|
+
if (Q(jt), I && jt.length > 0) {
|
|
17867
|
+
const Qt = jt.findIndex(
|
|
17868
|
+
(xt) => x === xt.id
|
|
17853
17869
|
);
|
|
17854
|
-
|
|
17870
|
+
Qt === -1 ? C == null || C(0) : C == null || C(Qt);
|
|
17855
17871
|
} else
|
|
17856
17872
|
C == null || C(void 0);
|
|
17857
|
-
const
|
|
17858
|
-
ae(
|
|
17873
|
+
const it = await Jt;
|
|
17874
|
+
ae(it), p == null || p(it);
|
|
17859
17875
|
},
|
|
17860
17876
|
[
|
|
17861
17877
|
C,
|
|
@@ -17873,10 +17889,10 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17873
17889
|
z,
|
|
17874
17890
|
T
|
|
17875
17891
|
]
|
|
17876
|
-
),
|
|
17877
|
-
async (
|
|
17892
|
+
), Oe = useCallback(
|
|
17893
|
+
async (Te) => {
|
|
17878
17894
|
try {
|
|
17879
|
-
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);
|
|
17880
17896
|
} catch (Re) {
|
|
17881
17897
|
W(Re.message);
|
|
17882
17898
|
} finally {
|
|
@@ -17905,22 +17921,22 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17905
17921
|
h
|
|
17906
17922
|
]
|
|
17907
17923
|
), D = useCallback(
|
|
17908
|
-
(
|
|
17909
|
-
v == null || v(
|
|
17910
|
-
const Re =
|
|
17924
|
+
(Te) => {
|
|
17925
|
+
v == null || v(Te);
|
|
17926
|
+
const Re = Te !== void 0 ? sortResults({
|
|
17911
17927
|
resultsToSort: te(),
|
|
17912
|
-
sorter:
|
|
17928
|
+
sorter: Te,
|
|
17913
17929
|
fields: { ...h.fields, ...m.fields }
|
|
17914
17930
|
}) : [...me.current];
|
|
17915
17931
|
Q(Re);
|
|
17916
17932
|
},
|
|
17917
17933
|
[v, te, h, m, Q]
|
|
17918
17934
|
), M = useCallback(
|
|
17919
|
-
(
|
|
17920
|
-
const { params: Re, searchValues: Ae, limit:
|
|
17921
|
-
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({
|
|
17922
17938
|
params: Re,
|
|
17923
|
-
newOffset:
|
|
17939
|
+
newOffset: Ht
|
|
17924
17940
|
}));
|
|
17925
17941
|
},
|
|
17926
17942
|
[
|
|
@@ -17934,11 +17950,11 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17934
17950
|
H,
|
|
17935
17951
|
S,
|
|
17936
17952
|
U,
|
|
17937
|
-
|
|
17953
|
+
Oe
|
|
17938
17954
|
]
|
|
17939
|
-
),
|
|
17940
|
-
(
|
|
17941
|
-
P(!0), H(
|
|
17955
|
+
), pe = useCallback(
|
|
17956
|
+
(Te) => {
|
|
17957
|
+
P(!0), H(Te), U((Te - 1) * O);
|
|
17942
17958
|
},
|
|
17943
17959
|
[P, O, U, H]
|
|
17944
17960
|
), ge = useCallback(() => {
|
|
@@ -17953,8 +17969,8 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17953
17969
|
S,
|
|
17954
17970
|
O
|
|
17955
17971
|
]), Fe = useCallback(
|
|
17956
|
-
async (
|
|
17957
|
-
const Re =
|
|
17972
|
+
async (Te) => {
|
|
17973
|
+
const Re = Te[(h == null ? void 0 : h.field_parent) || "child_id"], Ae = await ConnectionProvider.getHandler().readObjects({
|
|
17958
17974
|
model: r,
|
|
17959
17975
|
ids: Re,
|
|
17960
17976
|
fields: h.field_parent ? { ...h.fields, [h.field_parent]: {} } : h.fields,
|
|
@@ -17967,7 +17983,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17967
17983
|
return {
|
|
17968
17984
|
submit: M,
|
|
17969
17985
|
clear: ge,
|
|
17970
|
-
fetchResults:
|
|
17986
|
+
fetchResults: Oe,
|
|
17971
17987
|
tableRefreshing: E,
|
|
17972
17988
|
searchFilterLoading: B,
|
|
17973
17989
|
searchError: L,
|
|
@@ -17975,7 +17991,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
17975
17991
|
offset: z,
|
|
17976
17992
|
limit: O,
|
|
17977
17993
|
getResults: te,
|
|
17978
|
-
requestPageChange:
|
|
17994
|
+
requestPageChange: pe,
|
|
17979
17995
|
changeSort: D,
|
|
17980
17996
|
fetchChildrenForRecord: Fe,
|
|
17981
17997
|
colorsForResults: oe,
|
|
@@ -18008,7 +18024,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18008
18024
|
setSearchTreeNameSearch: G,
|
|
18009
18025
|
goToResourceId: E,
|
|
18010
18026
|
limit: P
|
|
18011
|
-
} = 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);
|
|
18012
18028
|
useEffect(() => {
|
|
18013
18029
|
m && m.length > 0 && !g && (v == null || v(0), p == null || p(m[0].id));
|
|
18014
18030
|
}, [m]), useEffect(() => {
|
|
@@ -18016,9 +18032,9 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18016
18032
|
}, [P]), useEffect(() => {
|
|
18017
18033
|
l.length === 1 ? D(l[0]) : l.length > 1 && D(l.filter((Re) => Re.view_id !== o.view_id)[0]);
|
|
18018
18034
|
}, [l]), useEffect(() => {
|
|
18019
|
-
(
|
|
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]);
|
|
18020
18036
|
}, [o]);
|
|
18021
|
-
const
|
|
18037
|
+
const Te = () => {
|
|
18022
18038
|
var Re;
|
|
18023
18039
|
(Re = c.current) == null || Re.submitForm();
|
|
18024
18040
|
};
|
|
@@ -18034,7 +18050,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18034
18050
|
setFormHasChanges: W,
|
|
18035
18051
|
formRef: c,
|
|
18036
18052
|
searchTreeRef: u,
|
|
18037
|
-
onFormSave:
|
|
18053
|
+
onFormSave: Te,
|
|
18038
18054
|
onNewClicked: d,
|
|
18039
18055
|
currentId: f,
|
|
18040
18056
|
setCurrentId: p,
|
|
@@ -18056,7 +18072,7 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18056
18072
|
duplicatingItem: oe,
|
|
18057
18073
|
setDuplicatingItem: ie,
|
|
18058
18074
|
setSearchParams: me,
|
|
18059
|
-
searchParams:
|
|
18075
|
+
searchParams: ce,
|
|
18060
18076
|
searchVisible: Q,
|
|
18061
18077
|
setSearchVisible: te,
|
|
18062
18078
|
sorter: w,
|
|
@@ -18067,11 +18083,11 @@ const DEFAULT_SEARCH_LIMIT$1 = 80, useSearch = (e) => {
|
|
|
18067
18083
|
setSearchTreeNameSearch: G,
|
|
18068
18084
|
setGraphIsLoading: ve,
|
|
18069
18085
|
graphIsLoading: he,
|
|
18070
|
-
previousView:
|
|
18086
|
+
previousView: Oe,
|
|
18071
18087
|
setPreviousView: D,
|
|
18072
18088
|
goToResourceId: E,
|
|
18073
18089
|
searchValues: M,
|
|
18074
|
-
setSearchValues:
|
|
18090
|
+
setSearchValues: pe,
|
|
18075
18091
|
limit: ge,
|
|
18076
18092
|
setLimit: Fe
|
|
18077
18093
|
},
|
|
@@ -18408,189 +18424,190 @@ function Form(e, r) {
|
|
|
18408
18424
|
forcedValues: T = {}
|
|
18409
18425
|
} = e, {
|
|
18410
18426
|
lang: G
|
|
18411
|
-
} = 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),
|
|
18412
|
-
activeId: D
|
|
18413
|
-
|
|
18414
|
-
|
|
18415
|
-
|
|
18416
|
-
|
|
18417
|
-
|
|
18418
|
-
|
|
18419
|
-
|
|
18420
|
-
|
|
18421
|
-
|
|
18422
|
-
|
|
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 || {};
|
|
18423
18440
|
useImperativeHandle(r, () => ({
|
|
18424
18441
|
submitForm: sn,
|
|
18425
18442
|
getFields: Qt,
|
|
18426
|
-
getValues:
|
|
18427
|
-
getPlainValues:
|
|
18428
|
-
getContext:
|
|
18429
|
-
fetchValues:
|
|
18430
|
-
cancelUnsavedChanges:
|
|
18443
|
+
getValues: xt,
|
|
18444
|
+
getPlainValues: Pt,
|
|
18445
|
+
getContext: cn,
|
|
18446
|
+
fetchValues: an,
|
|
18447
|
+
cancelUnsavedChanges: _n,
|
|
18431
18448
|
clearAndReload: () => {
|
|
18432
|
-
|
|
18449
|
+
ce.current = void 0, W(void 0), mn();
|
|
18433
18450
|
}
|
|
18434
18451
|
})), useEffect(() => {
|
|
18435
18452
|
if (N(void 0), !(!o && !v)) {
|
|
18436
18453
|
if (!x) {
|
|
18437
|
-
|
|
18454
|
+
ce.current = void 0, W(void 0);
|
|
18438
18455
|
return;
|
|
18439
18456
|
}
|
|
18440
|
-
(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();
|
|
18441
18458
|
}
|
|
18442
18459
|
}, [a, o, g, v, x]), useEffect(() => {
|
|
18443
|
-
oe && (
|
|
18460
|
+
oe && (In({
|
|
18444
18461
|
elementHasLostFocus: !0
|
|
18445
18462
|
}), ie(!1));
|
|
18446
18463
|
}, [oe]);
|
|
18447
|
-
const
|
|
18448
|
-
|
|
18449
|
-
},
|
|
18450
|
-
|
|
18451
|
-
},
|
|
18452
|
-
|
|
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);
|
|
18453
18470
|
};
|
|
18454
|
-
function
|
|
18455
|
-
return a ||
|
|
18471
|
+
function it() {
|
|
18472
|
+
return a || ce.current;
|
|
18456
18473
|
}
|
|
18457
18474
|
function Qt() {
|
|
18458
18475
|
return U;
|
|
18459
18476
|
}
|
|
18460
|
-
function
|
|
18461
|
-
const
|
|
18462
|
-
...
|
|
18463
|
-
...
|
|
18477
|
+
function xt() {
|
|
18478
|
+
const qe = {
|
|
18479
|
+
...Xt(U),
|
|
18480
|
+
...Ze()
|
|
18464
18481
|
};
|
|
18465
|
-
for (const
|
|
18466
|
-
Le
|
|
18467
|
-
return
|
|
18482
|
+
for (const Le in qe)
|
|
18483
|
+
qe[Le] === void 0 && delete qe[Le];
|
|
18484
|
+
return qe;
|
|
18468
18485
|
}
|
|
18469
|
-
function
|
|
18470
|
-
const
|
|
18486
|
+
function Pt() {
|
|
18487
|
+
const qe = xt(), Le = Qt();
|
|
18471
18488
|
let Tt = {};
|
|
18472
|
-
return Object.keys(
|
|
18473
|
-
const ln =
|
|
18474
|
-
|
|
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;
|
|
18475
18492
|
}), Tt;
|
|
18476
18493
|
}
|
|
18477
|
-
function
|
|
18478
|
-
const
|
|
18479
|
-
...
|
|
18494
|
+
function kt() {
|
|
18495
|
+
const qe = {
|
|
18496
|
+
...Xt(U)
|
|
18480
18497
|
};
|
|
18481
|
-
for (const
|
|
18482
|
-
Le
|
|
18483
|
-
return
|
|
18498
|
+
for (const Le in qe)
|
|
18499
|
+
qe[Le] === void 0 && delete qe[Le];
|
|
18500
|
+
return qe;
|
|
18484
18501
|
}
|
|
18485
|
-
function
|
|
18502
|
+
function cn() {
|
|
18486
18503
|
return {
|
|
18487
18504
|
...I,
|
|
18488
18505
|
...L == null ? void 0 : L.context
|
|
18489
18506
|
};
|
|
18490
18507
|
}
|
|
18491
|
-
function
|
|
18508
|
+
function Ze() {
|
|
18492
18509
|
return {
|
|
18493
|
-
id:
|
|
18494
|
-
active_id:
|
|
18495
|
-
active_ids: [
|
|
18510
|
+
id: it(),
|
|
18511
|
+
active_id: it(),
|
|
18512
|
+
active_ids: [it()],
|
|
18496
18513
|
parent_id: D,
|
|
18497
|
-
...
|
|
18514
|
+
...Jt
|
|
18498
18515
|
};
|
|
18499
18516
|
}
|
|
18500
|
-
const
|
|
18501
|
-
const
|
|
18517
|
+
const _t = async (qe) => {
|
|
18518
|
+
const Le = it() ? L == null ? void 0 : L.context : {};
|
|
18502
18519
|
return await ConnectionProvider.getHandler().defaultGet({
|
|
18503
18520
|
model: o,
|
|
18504
|
-
fields:
|
|
18521
|
+
fields: qe,
|
|
18505
18522
|
context: {
|
|
18506
18523
|
...I,
|
|
18507
|
-
...
|
|
18524
|
+
...Le
|
|
18508
18525
|
},
|
|
18509
18526
|
extraValues: S
|
|
18510
18527
|
});
|
|
18511
|
-
},
|
|
18528
|
+
}, en = () => Object.keys(getTouchedValues({
|
|
18512
18529
|
source: me.current,
|
|
18513
|
-
target:
|
|
18530
|
+
target: Xt(U),
|
|
18514
18531
|
fields: U
|
|
18515
|
-
})).length !== 0,
|
|
18516
|
-
const
|
|
18517
|
-
return processValues(
|
|
18518
|
-
},
|
|
18532
|
+
})).length !== 0, Xt = (qe) => {
|
|
18533
|
+
const Le = K.getFieldsValue(!0);
|
|
18534
|
+
return processValues(Le, qe);
|
|
18535
|
+
}, tn = (qe, Le) => {
|
|
18519
18536
|
yn({
|
|
18520
18537
|
values: {
|
|
18521
18538
|
...processValues(K.getFieldsValue(!0), U),
|
|
18522
|
-
[
|
|
18539
|
+
[qe]: Le
|
|
18523
18540
|
},
|
|
18524
18541
|
fields: U,
|
|
18525
18542
|
reset: !1
|
|
18526
18543
|
});
|
|
18527
|
-
},
|
|
18528
|
-
async function
|
|
18544
|
+
}, un = (qe) => K.getFieldsValue(!0)[qe];
|
|
18545
|
+
async function gn() {
|
|
18529
18546
|
try {
|
|
18530
18547
|
return await K.validateFields(), !1;
|
|
18531
18548
|
} catch {
|
|
18532
18549
|
return !0;
|
|
18533
18550
|
}
|
|
18534
18551
|
}
|
|
18535
|
-
const
|
|
18536
|
-
N(void 0),
|
|
18537
|
-
let
|
|
18552
|
+
const mn = async () => {
|
|
18553
|
+
N(void 0), Re == null || Re(!0);
|
|
18554
|
+
let qe;
|
|
18538
18555
|
try {
|
|
18539
|
-
v ?
|
|
18556
|
+
v ? qe = {
|
|
18540
18557
|
arch: v.arch,
|
|
18541
18558
|
fields: v.fields
|
|
18542
|
-
} :
|
|
18559
|
+
} : qe = await $n();
|
|
18543
18560
|
const {
|
|
18544
|
-
fields:
|
|
18561
|
+
fields: Le,
|
|
18545
18562
|
arch: Tt
|
|
18546
|
-
} =
|
|
18547
|
-
re(
|
|
18548
|
-
fields:
|
|
18563
|
+
} = qe;
|
|
18564
|
+
re(Le), z(Tt), await an({
|
|
18565
|
+
fields: Le,
|
|
18549
18566
|
arch: Tt
|
|
18550
18567
|
});
|
|
18551
|
-
} catch (
|
|
18552
|
-
N(
|
|
18568
|
+
} catch (Le) {
|
|
18569
|
+
N(Le != null && Le.message ? Le.message + Le.stack : Le), Re == null || Re(!1);
|
|
18553
18570
|
}
|
|
18554
|
-
},
|
|
18555
|
-
let
|
|
18556
|
-
|
|
18557
|
-
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,
|
|
18558
18575
|
defaultGetCalled: ln
|
|
18559
|
-
} = await
|
|
18576
|
+
} = await jn({
|
|
18560
18577
|
fields: Tt,
|
|
18561
|
-
arch:
|
|
18562
|
-
}), y && (
|
|
18578
|
+
arch: Zt
|
|
18579
|
+
}), y && (Le = {
|
|
18563
18580
|
...getValuesForDomain(y),
|
|
18564
|
-
...
|
|
18565
|
-
}), me.current = processValues(
|
|
18566
|
-
values:
|
|
18581
|
+
...Le
|
|
18582
|
+
}), me.current = processValues(Le, Tt), yn({
|
|
18583
|
+
values: Le,
|
|
18567
18584
|
fields: Tt,
|
|
18568
18585
|
reset: !0,
|
|
18569
18586
|
isDefaultGet: ln
|
|
18570
|
-
}),
|
|
18587
|
+
}), pn({
|
|
18571
18588
|
fields: Tt,
|
|
18572
|
-
arch:
|
|
18573
|
-
values:
|
|
18574
|
-
}),
|
|
18589
|
+
arch: Zt,
|
|
18590
|
+
values: Le
|
|
18591
|
+
}), Re == null || Re(!1), Fe == null || Fe(!1), ln && ie(!0);
|
|
18575
18592
|
};
|
|
18576
|
-
function fn(
|
|
18577
|
-
me.current[
|
|
18593
|
+
function fn(qe, Le) {
|
|
18594
|
+
me.current[qe] = Le, Fe == null || Fe(en());
|
|
18578
18595
|
}
|
|
18579
|
-
const
|
|
18580
|
-
|
|
18596
|
+
const _n = async () => new Promise(async (qe) => {
|
|
18597
|
+
en() ? showDialog$6({
|
|
18581
18598
|
lang: G,
|
|
18582
18599
|
onOk: () => {
|
|
18583
|
-
|
|
18600
|
+
Pe == null || Pe(), qe(!0);
|
|
18584
18601
|
},
|
|
18585
18602
|
onCancel: () => {
|
|
18586
|
-
|
|
18603
|
+
qe(!1);
|
|
18587
18604
|
}
|
|
18588
|
-
}) : (
|
|
18589
|
-
}),
|
|
18605
|
+
}) : (Pe == null || Pe(), qe(!0));
|
|
18606
|
+
}), $n = async () => {
|
|
18590
18607
|
if (u) {
|
|
18591
|
-
const
|
|
18608
|
+
const qe = await ConnectionProvider.getHandler().getActionStringForModel(o);
|
|
18592
18609
|
return (await ConnectionProvider.getHandler().getViewsForAction({
|
|
18593
|
-
action:
|
|
18610
|
+
action: qe,
|
|
18594
18611
|
context: I
|
|
18595
18612
|
})).views.get("form");
|
|
18596
18613
|
}
|
|
@@ -18600,61 +18617,61 @@ function Form(e, r) {
|
|
|
18600
18617
|
context: I
|
|
18601
18618
|
});
|
|
18602
18619
|
}, yn = ({
|
|
18603
|
-
values:
|
|
18604
|
-
fields:
|
|
18620
|
+
values: qe,
|
|
18621
|
+
fields: Le,
|
|
18605
18622
|
reset: Tt,
|
|
18606
|
-
isDefaultGet:
|
|
18623
|
+
isDefaultGet: Zt = !1
|
|
18607
18624
|
}) => {
|
|
18608
18625
|
const Ln = {
|
|
18609
18626
|
...Tt ? {} : K.getFieldsValue(!0),
|
|
18610
|
-
...
|
|
18611
|
-
},
|
|
18612
|
-
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;
|
|
18613
18630
|
return {
|
|
18614
|
-
name:
|
|
18631
|
+
name: Vn,
|
|
18615
18632
|
touched: !1,
|
|
18616
18633
|
value: Xn
|
|
18617
18634
|
};
|
|
18618
18635
|
});
|
|
18619
|
-
|
|
18620
|
-
},
|
|
18621
|
-
fields:
|
|
18622
|
-
arch:
|
|
18636
|
+
Zt || (Q.current = Hn), K.setFields(_r);
|
|
18637
|
+
}, jn = async ({
|
|
18638
|
+
fields: qe,
|
|
18639
|
+
arch: Le
|
|
18623
18640
|
}) => {
|
|
18624
|
-
let Tt = {},
|
|
18625
|
-
if (
|
|
18641
|
+
let Tt = {}, Zt = !1;
|
|
18642
|
+
if (it()) {
|
|
18626
18643
|
Tt = (await ConnectionProvider.getHandler().readObjects({
|
|
18627
18644
|
model: o,
|
|
18628
|
-
ids: [
|
|
18629
|
-
fields:
|
|
18645
|
+
ids: [it()],
|
|
18646
|
+
fields: qe,
|
|
18630
18647
|
context: I
|
|
18631
18648
|
}))[0];
|
|
18632
18649
|
const ln = await ConnectionProvider.getHandler().search({
|
|
18633
|
-
params: [["res_model", "=", o], ["res_id", "=",
|
|
18650
|
+
params: [["res_model", "=", o], ["res_id", "=", it()]],
|
|
18634
18651
|
fields: ["id", "name"],
|
|
18635
|
-
context:
|
|
18652
|
+
context: cn(),
|
|
18636
18653
|
model: "ir.attachment"
|
|
18637
18654
|
});
|
|
18638
|
-
|
|
18655
|
+
Ae == null || Ae(ln);
|
|
18639
18656
|
} else
|
|
18640
|
-
|
|
18657
|
+
Ae == null || Ae([]), Tt = await _t(qe), Zt = !0;
|
|
18641
18658
|
return {
|
|
18642
18659
|
values: Tt,
|
|
18643
|
-
defaultGetCalled:
|
|
18660
|
+
defaultGetCalled: Zt
|
|
18644
18661
|
};
|
|
18645
|
-
},
|
|
18662
|
+
}, On = async (qe) => {
|
|
18646
18663
|
const {
|
|
18647
|
-
callOnSubmitSucceed:
|
|
18648
|
-
} =
|
|
18649
|
-
if (
|
|
18664
|
+
callOnSubmitSucceed: Le = !0
|
|
18665
|
+
} = qe || {};
|
|
18666
|
+
if (it()) {
|
|
18650
18667
|
const Tt = getTouchedValues({
|
|
18651
18668
|
source: me.current,
|
|
18652
|
-
target:
|
|
18669
|
+
target: Xt(U),
|
|
18653
18670
|
fields: U
|
|
18654
18671
|
});
|
|
18655
18672
|
await ConnectionProvider.getHandler().update({
|
|
18656
18673
|
model: o,
|
|
18657
|
-
id:
|
|
18674
|
+
id: it(),
|
|
18658
18675
|
values: {
|
|
18659
18676
|
...Tt,
|
|
18660
18677
|
...T
|
|
@@ -18664,9 +18681,9 @@ function Form(e, r) {
|
|
|
18664
18681
|
...I,
|
|
18665
18682
|
...L == null ? void 0 : L.context
|
|
18666
18683
|
}
|
|
18667
|
-
}), me.current =
|
|
18684
|
+
}), me.current = Xt(U);
|
|
18668
18685
|
} else {
|
|
18669
|
-
const Tt =
|
|
18686
|
+
const Tt = Xt(U), Zt = await ConnectionProvider.getHandler().create({
|
|
18670
18687
|
model: o,
|
|
18671
18688
|
values: {
|
|
18672
18689
|
...Tt,
|
|
@@ -18678,113 +18695,114 @@ function Form(e, r) {
|
|
|
18678
18695
|
...L == null ? void 0 : L.context
|
|
18679
18696
|
}
|
|
18680
18697
|
});
|
|
18681
|
-
|
|
18698
|
+
ce.current = Zt, me.current = Tt;
|
|
18682
18699
|
}
|
|
18683
|
-
C && await C([
|
|
18684
|
-
},
|
|
18700
|
+
C && await C([it()]), !w && Le && (Yt == null || Yt(it(), xt(), kt()));
|
|
18701
|
+
}, dn = async (qe) => {
|
|
18685
18702
|
const {
|
|
18686
|
-
callOnSubmitSucceed:
|
|
18687
|
-
} =
|
|
18688
|
-
!w &&
|
|
18689
|
-
}, sn = async (
|
|
18690
|
-
let
|
|
18703
|
+
callOnSubmitSucceed: Le = !0
|
|
18704
|
+
} = qe || {};
|
|
18705
|
+
!w && Le && (Yt == null || Yt(it(), xt(), kt()));
|
|
18706
|
+
}, sn = async (qe) => {
|
|
18707
|
+
let Le = !1;
|
|
18691
18708
|
const {
|
|
18692
18709
|
callOnSubmitSucceed: Tt = !0
|
|
18693
|
-
} =
|
|
18694
|
-
if (he.current = !0, N(void 0), !
|
|
18695
|
-
return he.current = !1,
|
|
18696
|
-
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())
|
|
18697
18714
|
return he.current = !1, showDialog$5(G), !1;
|
|
18698
|
-
P(!0),
|
|
18715
|
+
P(!0), ge == null || ge(!0);
|
|
18699
18716
|
try {
|
|
18700
|
-
m === "api" ? await
|
|
18717
|
+
m === "api" ? await On(qe) : await dn(qe), h && (ce.current = void 0, yn({
|
|
18701
18718
|
values: {},
|
|
18702
18719
|
fields: U,
|
|
18703
18720
|
reset: !0
|
|
18704
|
-
})), await
|
|
18705
|
-
} catch (
|
|
18706
|
-
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);
|
|
18707
18724
|
} finally {
|
|
18708
|
-
he.current = !1,
|
|
18725
|
+
he.current = !1, ge == null || ge(!1), P(!1);
|
|
18709
18726
|
}
|
|
18710
|
-
return
|
|
18711
|
-
},
|
|
18712
|
-
fields:
|
|
18713
|
-
arch:
|
|
18727
|
+
return Le;
|
|
18728
|
+
}, pn = ({
|
|
18729
|
+
fields: qe,
|
|
18730
|
+
arch: Le,
|
|
18714
18731
|
values: Tt
|
|
18715
18732
|
}) => {
|
|
18716
18733
|
var ln;
|
|
18717
|
-
const
|
|
18718
|
-
|
|
18734
|
+
const Zt = new Form$4(qe);
|
|
18735
|
+
Zt.parse(Le, {
|
|
18719
18736
|
readOnly: p,
|
|
18720
18737
|
values: {
|
|
18721
18738
|
...Tt,
|
|
18722
|
-
...
|
|
18739
|
+
...Ze()
|
|
18723
18740
|
}
|
|
18724
|
-
}), W(
|
|
18725
|
-
},
|
|
18726
|
-
elementHasLostFocus:
|
|
18741
|
+
}), W(Zt), ae && Zt.string && ((ln = ae.setTitle) == null || ln.call(ae, Zt.string));
|
|
18742
|
+
}, In = async ({
|
|
18743
|
+
elementHasLostFocus: qe = !1
|
|
18727
18744
|
}) => {
|
|
18728
18745
|
if (he.current)
|
|
18729
18746
|
return;
|
|
18730
|
-
const
|
|
18747
|
+
const Le = getTouchedValues({
|
|
18731
18748
|
source: Q.current,
|
|
18732
|
-
target:
|
|
18749
|
+
target: Xt(U),
|
|
18733
18750
|
fields: U
|
|
18734
|
-
}), Tt = Object.keys(
|
|
18751
|
+
}), Tt = Object.keys(Le);
|
|
18735
18752
|
if (Tt.length !== 0) {
|
|
18736
18753
|
if (checkFieldsType({
|
|
18737
18754
|
changedFields: Tt,
|
|
18738
18755
|
fields: U,
|
|
18739
18756
|
types: ["text", "codeeditor", "email", "url", "char", "float", "float_time", "integer", "many2one"]
|
|
18740
|
-
}) &&
|
|
18757
|
+
}) && qe !== !0)
|
|
18741
18758
|
return;
|
|
18742
18759
|
{
|
|
18743
|
-
const
|
|
18744
|
-
Q.current =
|
|
18760
|
+
const Zt = processValues(K.getFieldsValue(!0), U);
|
|
18761
|
+
Q.current = Zt, d == null || d(Zt), Fe == null || Fe(!0), tr(Tt);
|
|
18745
18762
|
}
|
|
18746
18763
|
}
|
|
18747
|
-
},
|
|
18764
|
+
}, Wn = debounce_1(In, 100), tr = async (qe) => {
|
|
18748
18765
|
try {
|
|
18749
|
-
for (let
|
|
18750
|
-
const Tt = Le
|
|
18751
|
-
await
|
|
18766
|
+
for (let Le = 0; Le < qe.length; Le += 1) {
|
|
18767
|
+
const Tt = qe[Le];
|
|
18768
|
+
await nr(Tt);
|
|
18752
18769
|
}
|
|
18753
|
-
} catch (
|
|
18754
|
-
showDialog$8(
|
|
18770
|
+
} catch (Le) {
|
|
18771
|
+
showDialog$8(Le);
|
|
18755
18772
|
}
|
|
18756
|
-
},
|
|
18757
|
-
const
|
|
18758
|
-
if (!
|
|
18759
|
-
|
|
18773
|
+
}, nr = async (qe) => {
|
|
18774
|
+
const Le = L == null ? void 0 : L.onChangeFields[qe];
|
|
18775
|
+
if (!Le) {
|
|
18776
|
+
pn({
|
|
18760
18777
|
fields: U,
|
|
18761
18778
|
arch: H,
|
|
18762
|
-
values:
|
|
18779
|
+
values: Xt(U)
|
|
18763
18780
|
});
|
|
18764
18781
|
return;
|
|
18765
18782
|
}
|
|
18766
18783
|
const Tt = getOnChangePayload({
|
|
18767
18784
|
values: {
|
|
18768
|
-
...
|
|
18785
|
+
...Xt(U),
|
|
18769
18786
|
context: {
|
|
18770
18787
|
...I,
|
|
18771
18788
|
...L == null ? void 0 : L.context
|
|
18772
18789
|
}
|
|
18773
18790
|
},
|
|
18774
|
-
|
|
18775
|
-
|
|
18791
|
+
parentValues: M == null ? void 0 : M(),
|
|
18792
|
+
onChangeFieldActionArgs: Le.args
|
|
18793
|
+
}), Zt = await ConnectionProvider.getHandler().executeOnChange({
|
|
18776
18794
|
model: o,
|
|
18777
|
-
action:
|
|
18778
|
-
ids:
|
|
18795
|
+
action: Le.method,
|
|
18796
|
+
ids: it() ? [it()] : [],
|
|
18779
18797
|
payload: Tt,
|
|
18780
18798
|
fields: U
|
|
18781
18799
|
});
|
|
18782
|
-
if (
|
|
18800
|
+
if (Zt.value) {
|
|
18783
18801
|
const ln = {
|
|
18784
|
-
...
|
|
18785
|
-
...
|
|
18802
|
+
...Xt(U),
|
|
18803
|
+
...Zt.value
|
|
18786
18804
|
};
|
|
18787
|
-
|
|
18805
|
+
pn({
|
|
18788
18806
|
fields: U,
|
|
18789
18807
|
arch: H,
|
|
18790
18808
|
values: ln
|
|
@@ -18794,161 +18812,161 @@ function Form(e, r) {
|
|
|
18794
18812
|
reset: !1
|
|
18795
18813
|
});
|
|
18796
18814
|
}
|
|
18797
|
-
if (
|
|
18815
|
+
if (Zt.warning && Zt.warning.title && Zt.warning.message && !te.current) {
|
|
18798
18816
|
const {
|
|
18799
18817
|
title: ln,
|
|
18800
18818
|
message: Ln
|
|
18801
|
-
} =
|
|
18819
|
+
} = Zt.warning;
|
|
18802
18820
|
te.current = !0, showDialog$4(ln, Ln, () => {
|
|
18803
18821
|
te.current = !1;
|
|
18804
18822
|
});
|
|
18805
18823
|
}
|
|
18806
|
-
if (
|
|
18824
|
+
if (Zt.domain && Object.keys(Zt.domain).length > 0) {
|
|
18807
18825
|
const ln = mergeFieldsDomain({
|
|
18808
|
-
fieldsDomain:
|
|
18826
|
+
fieldsDomain: Zt.domain,
|
|
18809
18827
|
fields: U
|
|
18810
18828
|
});
|
|
18811
|
-
|
|
18829
|
+
pn({
|
|
18812
18830
|
fields: ln,
|
|
18813
18831
|
arch: H,
|
|
18814
|
-
values:
|
|
18832
|
+
values: Xt(ln)
|
|
18815
18833
|
}), re(ln);
|
|
18816
18834
|
}
|
|
18817
18835
|
};
|
|
18818
|
-
async function
|
|
18819
|
-
action:
|
|
18820
|
-
context:
|
|
18836
|
+
async function zn({
|
|
18837
|
+
action: qe,
|
|
18838
|
+
context: Le
|
|
18821
18839
|
}) {
|
|
18822
18840
|
const Tt = await ConnectionProvider.getHandler().execute({
|
|
18823
18841
|
model: o,
|
|
18824
|
-
action:
|
|
18825
|
-
payload: [
|
|
18842
|
+
action: qe,
|
|
18843
|
+
payload: [it()],
|
|
18826
18844
|
context: {
|
|
18827
|
-
...
|
|
18845
|
+
...Le,
|
|
18828
18846
|
...L == null ? void 0 : L.context,
|
|
18829
18847
|
...I
|
|
18830
18848
|
}
|
|
18831
18849
|
});
|
|
18832
18850
|
if (typeof Tt == "object" && Tt !== null && Object.keys(Tt).length === 0 && w)
|
|
18833
|
-
|
|
18851
|
+
Yt == null || Yt(it(), xt(), kt());
|
|
18834
18852
|
else if (Tt.type && Tt.type === "ir.actions.act_window_close")
|
|
18835
|
-
|
|
18853
|
+
Yt == null || Yt(it(), xt(), kt());
|
|
18836
18854
|
else if (Tt.type) {
|
|
18837
|
-
let
|
|
18838
|
-
Tt.context && (
|
|
18855
|
+
let Zt = {};
|
|
18856
|
+
Tt.context && (Zt = parseContext({
|
|
18839
18857
|
context: Tt.context,
|
|
18840
18858
|
fields: U,
|
|
18841
|
-
values:
|
|
18859
|
+
values: xt()
|
|
18842
18860
|
})), await Yn({
|
|
18843
18861
|
actionData: Tt,
|
|
18844
18862
|
context: {
|
|
18845
|
-
...
|
|
18846
|
-
...
|
|
18863
|
+
...Le,
|
|
18864
|
+
...Zt
|
|
18847
18865
|
}
|
|
18848
18866
|
});
|
|
18849
18867
|
} else
|
|
18850
|
-
await
|
|
18868
|
+
await an();
|
|
18851
18869
|
}
|
|
18852
|
-
async function
|
|
18853
|
-
action:
|
|
18870
|
+
async function Gn({
|
|
18871
|
+
action: qe
|
|
18854
18872
|
}) {
|
|
18855
|
-
const
|
|
18873
|
+
const Le = await ConnectionProvider.getHandler().executeWorkflow({
|
|
18856
18874
|
model: o,
|
|
18857
|
-
action:
|
|
18858
|
-
payload:
|
|
18875
|
+
action: qe,
|
|
18876
|
+
payload: it()
|
|
18859
18877
|
});
|
|
18860
|
-
|
|
18878
|
+
Le.type && Le.type === "ir.actions.act_window_close" ? Yt == null || Yt(it(), xt(), kt()) : await an();
|
|
18861
18879
|
}
|
|
18862
|
-
async function
|
|
18863
|
-
action:
|
|
18864
|
-
context:
|
|
18880
|
+
async function rr({
|
|
18881
|
+
action: qe,
|
|
18882
|
+
context: Le
|
|
18865
18883
|
}) {
|
|
18866
18884
|
const Tt = (await ConnectionProvider.getHandler().readObjects({
|
|
18867
18885
|
model: "ir.actions.actions",
|
|
18868
|
-
ids: [parseInt(
|
|
18886
|
+
ids: [parseInt(qe)],
|
|
18869
18887
|
context: I
|
|
18870
18888
|
}))[0];
|
|
18871
18889
|
await Yn({
|
|
18872
18890
|
actionData: Tt,
|
|
18873
|
-
context:
|
|
18891
|
+
context: Le
|
|
18874
18892
|
});
|
|
18875
18893
|
}
|
|
18876
18894
|
async function Yn({
|
|
18877
|
-
actionData:
|
|
18878
|
-
context:
|
|
18895
|
+
actionData: qe,
|
|
18896
|
+
context: Le
|
|
18879
18897
|
}) {
|
|
18880
18898
|
const {
|
|
18881
18899
|
closeParent: Tt
|
|
18882
|
-
} = await (
|
|
18883
|
-
actionData:
|
|
18900
|
+
} = await (Ht == null ? void 0 : Ht({
|
|
18901
|
+
actionData: qe,
|
|
18884
18902
|
fields: U,
|
|
18885
|
-
values:
|
|
18903
|
+
values: xt(),
|
|
18886
18904
|
context: {
|
|
18887
18905
|
...I,
|
|
18888
18906
|
...L == null ? void 0 : L.context,
|
|
18889
|
-
...
|
|
18907
|
+
...Le
|
|
18890
18908
|
},
|
|
18891
18909
|
onRefreshParentValues: () => {
|
|
18892
|
-
|
|
18910
|
+
an();
|
|
18893
18911
|
}
|
|
18894
18912
|
})) || {};
|
|
18895
|
-
!O && Tt && (
|
|
18913
|
+
!O && Tt && (Yt == null || Yt(it(), xt(), kt()));
|
|
18896
18914
|
}
|
|
18897
|
-
function
|
|
18898
|
-
|
|
18915
|
+
function Kn() {
|
|
18916
|
+
In({
|
|
18899
18917
|
elementHasLostFocus: !0
|
|
18900
18918
|
});
|
|
18901
18919
|
}
|
|
18902
|
-
async function
|
|
18903
|
-
type:
|
|
18904
|
-
action:
|
|
18920
|
+
async function Zn({
|
|
18921
|
+
type: qe,
|
|
18922
|
+
action: Le,
|
|
18905
18923
|
context: Tt
|
|
18906
18924
|
}) {
|
|
18907
|
-
if (
|
|
18908
|
-
|
|
18925
|
+
if (qe === "cancel") {
|
|
18926
|
+
Pe == null || Pe();
|
|
18909
18927
|
return;
|
|
18910
18928
|
}
|
|
18911
|
-
if (await
|
|
18929
|
+
if (await gn()) {
|
|
18912
18930
|
showDialog$5(G);
|
|
18913
18931
|
return;
|
|
18914
18932
|
}
|
|
18915
18933
|
try {
|
|
18916
18934
|
await sn({
|
|
18917
18935
|
callOnSubmitSucceed: !1
|
|
18918
|
-
}),
|
|
18919
|
-
action:
|
|
18936
|
+
}), qe === "object" ? await zn({
|
|
18937
|
+
action: Le,
|
|
18920
18938
|
context: Tt
|
|
18921
|
-
}) :
|
|
18922
|
-
action:
|
|
18923
|
-
}) :
|
|
18924
|
-
action:
|
|
18939
|
+
}) : qe === "workflow" ? await Gn({
|
|
18940
|
+
action: Le
|
|
18941
|
+
}) : qe === "action" && await rr({
|
|
18942
|
+
action: Le,
|
|
18925
18943
|
context: Tt
|
|
18926
18944
|
});
|
|
18927
|
-
} catch (
|
|
18928
|
-
showDialog$8(
|
|
18945
|
+
} catch (Zt) {
|
|
18946
|
+
showDialog$8(Zt);
|
|
18929
18947
|
}
|
|
18930
18948
|
}
|
|
18931
|
-
const
|
|
18949
|
+
const or = () => !L && !B ? /* @__PURE__ */ jsx(Spin, {}) : !o && !v || !x ? null : /* @__PURE__ */ jsx(Fragment, {
|
|
18932
18950
|
children: /* @__PURE__ */ jsx(FormProvider$2, {
|
|
18933
|
-
getValues:
|
|
18934
|
-
getPlainValues:
|
|
18951
|
+
getValues: xt,
|
|
18952
|
+
getPlainValues: Pt,
|
|
18935
18953
|
getFields: Qt,
|
|
18936
18954
|
domain: y,
|
|
18937
18955
|
activeId: a,
|
|
18938
18956
|
activeModel: o,
|
|
18939
|
-
setFieldValue:
|
|
18940
|
-
getFieldValue:
|
|
18941
|
-
executeButtonAction:
|
|
18942
|
-
getContext:
|
|
18957
|
+
setFieldValue: tn,
|
|
18958
|
+
getFieldValue: un,
|
|
18959
|
+
executeButtonAction: Zn,
|
|
18960
|
+
getContext: cn,
|
|
18943
18961
|
setOriginalValue: fn,
|
|
18944
18962
|
submitForm: sn,
|
|
18945
|
-
fetchValues:
|
|
18946
|
-
formHasChanges:
|
|
18947
|
-
elementHasLostFocus:
|
|
18963
|
+
fetchValues: an,
|
|
18964
|
+
formHasChanges: en,
|
|
18965
|
+
elementHasLostFocus: Kn,
|
|
18948
18966
|
children: /* @__PURE__ */ jsx(Form$3, {
|
|
18949
18967
|
form: K,
|
|
18950
18968
|
onFieldsChange: () => {
|
|
18951
|
-
|
|
18969
|
+
Wn({
|
|
18952
18970
|
elementHasLostFocus: !1
|
|
18953
18971
|
});
|
|
18954
18972
|
},
|
|
@@ -18959,7 +18977,7 @@ function Form(e, r) {
|
|
|
18959
18977
|
})
|
|
18960
18978
|
})
|
|
18961
18979
|
})
|
|
18962
|
-
}),
|
|
18980
|
+
}), ar = () => /* @__PURE__ */ jsxs(Fragment, {
|
|
18963
18981
|
children: [/* @__PURE__ */ jsx(Divider, {}), /* @__PURE__ */ jsx(Row, {
|
|
18964
18982
|
justify: "end",
|
|
18965
18983
|
children: /* @__PURE__ */ jsxs(Space, {
|
|
@@ -18967,7 +18985,7 @@ function Form(e, r) {
|
|
|
18967
18985
|
icon: /* @__PURE__ */ jsx(CloseOutlined$4, {}),
|
|
18968
18986
|
disabled: E,
|
|
18969
18987
|
onClick: async () => {
|
|
18970
|
-
await
|
|
18988
|
+
await _n();
|
|
18971
18989
|
},
|
|
18972
18990
|
children: "Cancel"
|
|
18973
18991
|
}), /* @__PURE__ */ jsx(Button$1, {
|
|
@@ -18985,21 +19003,21 @@ function Form(e, r) {
|
|
|
18985
19003
|
});
|
|
18986
19004
|
return x ? /* @__PURE__ */ jsx(Measure, {
|
|
18987
19005
|
bounds: !0,
|
|
18988
|
-
onResize: (
|
|
18989
|
-
var
|
|
18990
|
-
J((
|
|
19006
|
+
onResize: (qe) => {
|
|
19007
|
+
var Le;
|
|
19008
|
+
J((Le = qe.bounds) == null ? void 0 : Le.width);
|
|
18991
19009
|
},
|
|
18992
19010
|
children: ({
|
|
18993
|
-
measureRef:
|
|
19011
|
+
measureRef: qe
|
|
18994
19012
|
}) => /* @__PURE__ */ jsxs("div", {
|
|
18995
19013
|
className: "pb-2",
|
|
18996
|
-
ref:
|
|
19014
|
+
ref: qe,
|
|
18997
19015
|
children: [B && /* @__PURE__ */ jsx(Alert, {
|
|
18998
19016
|
className: "mt-10 mb-20",
|
|
18999
19017
|
message: JSON.stringify(B),
|
|
19000
19018
|
type: "error",
|
|
19001
19019
|
banner: !0
|
|
19002
|
-
}),
|
|
19020
|
+
}), or(), c && ar()]
|
|
19003
19021
|
})
|
|
19004
19022
|
}) : null;
|
|
19005
19023
|
}
|
|
@@ -19931,7 +19949,7 @@ function Tree(e) {
|
|
|
19931
19949
|
return null;
|
|
19932
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;
|
|
19933
19951
|
return U.forEach((J) => {
|
|
19934
|
-
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);
|
|
19935
19953
|
re.push(`${J.label}: ${Math.round(oe * 100) / 100}`);
|
|
19936
19954
|
}), /* @__PURE__ */ jsx("div", {
|
|
19937
19955
|
className: "p-1 pb-0 pl-2 mt-2 bg-gray-50",
|
|
@@ -20000,39 +20018,39 @@ function SearchTree(e, r) {
|
|
|
20000
20018
|
selectedRowItems: J = void 0,
|
|
20001
20019
|
setSelectedRowItems: oe = void 0,
|
|
20002
20020
|
searchParams: ie = [],
|
|
20003
|
-
setSearchParams:
|
|
20021
|
+
setSearchParams: ce = void 0,
|
|
20004
20022
|
searchVisible: me = !0,
|
|
20005
20023
|
setSearchVisible: Q = void 0,
|
|
20006
20024
|
sorter: te = void 0,
|
|
20007
20025
|
setSorter: he = void 0,
|
|
20008
20026
|
setTotalItems: ve = void 0,
|
|
20009
|
-
setSearchTreeNameSearch:
|
|
20027
|
+
setSearchTreeNameSearch: Oe = void 0,
|
|
20010
20028
|
setTreeIsLoading: D = void 0,
|
|
20011
20029
|
searchValues: M = {},
|
|
20012
|
-
setSearchValues:
|
|
20030
|
+
setSearchValues: pe = void 0,
|
|
20013
20031
|
limit: ge = DEFAULT_SEARCH_LIMIT$1,
|
|
20014
20032
|
setLimit: Fe = void 0
|
|
20015
20033
|
} = (p ? z : {}) || {}, {
|
|
20016
|
-
submit:
|
|
20034
|
+
submit: Te,
|
|
20017
20035
|
clear: Re,
|
|
20018
20036
|
fetchResults: Ae,
|
|
20019
|
-
tableRefreshing:
|
|
20020
|
-
searchFilterLoading:
|
|
20021
|
-
searchError:
|
|
20022
|
-
page:
|
|
20023
|
-
offset:
|
|
20024
|
-
getResults:
|
|
20025
|
-
requestPageChange:
|
|
20026
|
-
changeSort:
|
|
20027
|
-
fetchChildrenForRecord:
|
|
20028
|
-
colorsForResults:
|
|
20029
|
-
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
|
|
20030
20048
|
} = useSearch({
|
|
20031
20049
|
model: y,
|
|
20032
|
-
setSearchTreeNameSearch:
|
|
20050
|
+
setSearchTreeNameSearch: Oe,
|
|
20033
20051
|
setSelectedRowItems: oe,
|
|
20034
|
-
setSearchParams:
|
|
20035
|
-
setSearchValues:
|
|
20052
|
+
setSearchParams: ce,
|
|
20053
|
+
setSearchValues: pe,
|
|
20036
20054
|
searchParams: ie,
|
|
20037
20055
|
setSearchVisible: Q,
|
|
20038
20056
|
setTreeIsLoading: D,
|
|
@@ -20060,40 +20078,40 @@ function SearchTree(e, r) {
|
|
|
20060
20078
|
getDomain: () => d
|
|
20061
20079
|
})), useEffect(() => {
|
|
20062
20080
|
!C || f && (I.current = !1, Ae());
|
|
20063
|
-
}, [
|
|
20064
|
-
const
|
|
20081
|
+
}, [Yt, Pe, C, f, c]);
|
|
20082
|
+
const cn = async () => {
|
|
20065
20083
|
w(!1), v(!0), P(void 0), D == null || D(!0);
|
|
20066
20084
|
try {
|
|
20067
|
-
await
|
|
20068
|
-
} catch (
|
|
20069
|
-
P(
|
|
20085
|
+
await Ze(), w(!0);
|
|
20086
|
+
} catch (an) {
|
|
20087
|
+
P(an);
|
|
20070
20088
|
} finally {
|
|
20071
20089
|
v(!1), D == null || D(!1);
|
|
20072
20090
|
}
|
|
20073
|
-
},
|
|
20091
|
+
}, Ze = async () => {
|
|
20074
20092
|
x(o);
|
|
20075
|
-
let
|
|
20076
|
-
a || (
|
|
20093
|
+
let an = a;
|
|
20094
|
+
a || (an = await ConnectionProvider.getHandler().getView({
|
|
20077
20095
|
model: o,
|
|
20078
20096
|
type: "form",
|
|
20079
20097
|
context: h
|
|
20080
20098
|
}));
|
|
20081
|
-
let
|
|
20082
|
-
s || (
|
|
20099
|
+
let fn = s;
|
|
20100
|
+
s || (fn = await ConnectionProvider.getHandler().getView({
|
|
20083
20101
|
model: o,
|
|
20084
20102
|
type: "tree",
|
|
20085
20103
|
context: h
|
|
20086
|
-
})), G(
|
|
20104
|
+
})), G(an), S(fn);
|
|
20087
20105
|
};
|
|
20088
20106
|
useEffect(() => {
|
|
20089
|
-
|
|
20107
|
+
cn();
|
|
20090
20108
|
}, [o]);
|
|
20091
|
-
const
|
|
20092
|
-
Fe == null || Fe(
|
|
20093
|
-
},
|
|
20109
|
+
const _t = (an) => {
|
|
20110
|
+
Fe == null || Fe(an);
|
|
20111
|
+
}, en = async (an) => {
|
|
20094
20112
|
const {
|
|
20095
|
-
id:
|
|
20096
|
-
} =
|
|
20113
|
+
id: fn
|
|
20114
|
+
} = an;
|
|
20097
20115
|
L.current || (L.current = await ConnectionProvider.getHandler().treeButOpen({
|
|
20098
20116
|
id: O.view_id,
|
|
20099
20117
|
model: y,
|
|
@@ -20104,35 +20122,35 @@ function SearchTree(e, r) {
|
|
|
20104
20122
|
actionData: _n,
|
|
20105
20123
|
fields: O.fields,
|
|
20106
20124
|
values: {
|
|
20107
|
-
active_id:
|
|
20108
|
-
...
|
|
20125
|
+
active_id: fn,
|
|
20126
|
+
...an
|
|
20109
20127
|
},
|
|
20110
20128
|
context: h
|
|
20111
20129
|
}));
|
|
20112
|
-
},
|
|
20130
|
+
}, Xt = async (an) => {
|
|
20113
20131
|
const {
|
|
20114
|
-
id:
|
|
20115
|
-
} =
|
|
20132
|
+
id: fn
|
|
20133
|
+
} = an;
|
|
20116
20134
|
if (O != null && O.isExpandable) {
|
|
20117
20135
|
try {
|
|
20118
|
-
await
|
|
20136
|
+
await en(an);
|
|
20119
20137
|
} catch (_n) {
|
|
20120
20138
|
showDialog$8(_n);
|
|
20121
20139
|
}
|
|
20122
20140
|
return;
|
|
20123
20141
|
}
|
|
20124
20142
|
l({
|
|
20125
|
-
id:
|
|
20143
|
+
id: fn,
|
|
20126
20144
|
model: y,
|
|
20127
20145
|
formView: T,
|
|
20128
20146
|
treeView: O
|
|
20129
20147
|
});
|
|
20130
20148
|
};
|
|
20131
|
-
function tn(
|
|
20132
|
-
const
|
|
20133
|
-
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);
|
|
20134
20152
|
}
|
|
20135
|
-
function
|
|
20153
|
+
function un() {
|
|
20136
20154
|
return O != null && O.isExpandable ? W - 160 : W - (B + 210);
|
|
20137
20155
|
}
|
|
20138
20156
|
const gn = () => !O || !T ? null : /* @__PURE__ */ jsxs(Fragment, {
|
|
@@ -20144,38 +20162,38 @@ function SearchTree(e, r) {
|
|
|
20144
20162
|
searchFields: mergeSearchFields([T.search_fields, O.search_fields]),
|
|
20145
20163
|
onClear: Re,
|
|
20146
20164
|
limit: ge,
|
|
20147
|
-
offset:
|
|
20148
|
-
isSearching:
|
|
20149
|
-
onSubmit:
|
|
20150
|
-
onLimitChange:
|
|
20165
|
+
offset: Pe,
|
|
20166
|
+
isSearching: Ht,
|
|
20167
|
+
onSubmit: Te,
|
|
20168
|
+
onLimitChange: _t,
|
|
20151
20169
|
setSearchFilterHeight: N,
|
|
20152
|
-
searchError:
|
|
20170
|
+
searchError: Jt,
|
|
20153
20171
|
searchVisible: me,
|
|
20154
20172
|
searchValues: M
|
|
20155
20173
|
}), /* @__PURE__ */ jsx(Tree, {
|
|
20156
|
-
total:
|
|
20174
|
+
total: kt,
|
|
20157
20175
|
limit: ge,
|
|
20158
|
-
page:
|
|
20176
|
+
page: Yt,
|
|
20159
20177
|
treeView: O,
|
|
20160
|
-
results:
|
|
20161
|
-
onRequestPageChange:
|
|
20162
|
-
loading:
|
|
20163
|
-
onRowClicked:
|
|
20164
|
-
scrollY: u ||
|
|
20165
|
-
colorsForResults:
|
|
20178
|
+
results: jt(),
|
|
20179
|
+
onRequestPageChange: it,
|
|
20180
|
+
loading: et,
|
|
20181
|
+
onRowClicked: Xt,
|
|
20182
|
+
scrollY: u || un(),
|
|
20183
|
+
colorsForResults: Pt,
|
|
20166
20184
|
rowSelection: {
|
|
20167
|
-
selectedRowKeys: J == null ? void 0 : J.map((
|
|
20185
|
+
selectedRowKeys: J == null ? void 0 : J.map((an) => an.id),
|
|
20168
20186
|
onChange: tn
|
|
20169
20187
|
},
|
|
20170
20188
|
sorter: te,
|
|
20171
|
-
onChangeSort:
|
|
20172
|
-
onFetchChildrenForRecord: O.isExpandable ?
|
|
20189
|
+
onChangeSort: Qt,
|
|
20190
|
+
onFetchChildrenForRecord: O.isExpandable ? xt : void 0,
|
|
20173
20191
|
childField: O.field_parent
|
|
20174
20192
|
})]
|
|
20175
|
-
}),
|
|
20176
|
-
return
|
|
20193
|
+
}), mn = E || Jt;
|
|
20194
|
+
return mn ? /* @__PURE__ */ jsx(Alert, {
|
|
20177
20195
|
className: "mt-10",
|
|
20178
|
-
message:
|
|
20196
|
+
message: mn,
|
|
20179
20197
|
type: "error",
|
|
20180
20198
|
banner: !0
|
|
20181
20199
|
}) : /* @__PURE__ */ jsx("div", {
|
|
@@ -20361,7 +20379,7 @@ const SearchTree$1 = forwardRef(SearchTree), SearchModal = (e) => {
|
|
|
20361
20379
|
}
|
|
20362
20380
|
}
|
|
20363
20381
|
}, oe = async (te) => {
|
|
20364
|
-
if (await
|
|
20382
|
+
if (await ce(), K.current && K.current.length > 0) {
|
|
20365
20383
|
const he = await ConnectionProvider.getHandler().searchAllIds({
|
|
20366
20384
|
params: K.current,
|
|
20367
20385
|
model: l,
|
|
@@ -20394,7 +20412,7 @@ const SearchTree$1 = forwardRef(SearchTree), SearchModal = (e) => {
|
|
|
20394
20412
|
w(!1);
|
|
20395
20413
|
}
|
|
20396
20414
|
};
|
|
20397
|
-
async function
|
|
20415
|
+
async function ce() {
|
|
20398
20416
|
f && (K.current = await ConnectionProvider.getHandler().evalDomain({
|
|
20399
20417
|
domain: f,
|
|
20400
20418
|
values: transformPlainMany2Ones({
|
|
@@ -22286,7 +22304,7 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22286
22304
|
function H() {
|
|
22287
22305
|
d && K(g());
|
|
22288
22306
|
}
|
|
22289
|
-
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();
|
|
22290
22308
|
useLayoutEffect$2(function() {
|
|
22291
22309
|
re === "alignPre" && ie(0);
|
|
22292
22310
|
}, [re]);
|
|
@@ -22294,31 +22312,31 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22294
22312
|
return m || g;
|
|
22295
22313
|
}
|
|
22296
22314
|
function Q() {
|
|
22297
|
-
var
|
|
22298
|
-
(
|
|
22315
|
+
var pe;
|
|
22316
|
+
(pe = S.current) === null || pe === void 0 || pe.forceAlign();
|
|
22299
22317
|
}
|
|
22300
|
-
function te(
|
|
22318
|
+
function te(pe, ge) {
|
|
22301
22319
|
var Fe = v(ge);
|
|
22302
|
-
P !== Fe && B(Fe), ie(function(
|
|
22303
|
-
return
|
|
22304
|
-
}), 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));
|
|
22305
22323
|
}
|
|
22306
22324
|
useLayoutEffect$2(function() {
|
|
22307
22325
|
re === "align" && (oe < 3 ? Q() : ae(function() {
|
|
22308
|
-
var
|
|
22309
|
-
(
|
|
22326
|
+
var pe;
|
|
22327
|
+
(pe = ce.current) === null || pe === void 0 || pe.call(ce);
|
|
22310
22328
|
}));
|
|
22311
22329
|
}, [oe]);
|
|
22312
22330
|
var he = _objectSpread2$g({}, getMotion(e));
|
|
22313
|
-
["onAppearEnd", "onEnterEnd", "onLeaveEnd"].forEach(function(
|
|
22314
|
-
var ge = he[
|
|
22315
|
-
he[
|
|
22316
|
-
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);
|
|
22317
22335
|
};
|
|
22318
22336
|
});
|
|
22319
22337
|
function ve() {
|
|
22320
|
-
return new Promise(function(
|
|
22321
|
-
|
|
22338
|
+
return new Promise(function(pe) {
|
|
22339
|
+
ce.current = pe;
|
|
22322
22340
|
});
|
|
22323
22341
|
}
|
|
22324
22342
|
React$n.useEffect(function() {
|
|
@@ -22331,7 +22349,7 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22331
22349
|
}
|
|
22332
22350
|
};
|
|
22333
22351
|
});
|
|
22334
|
-
var
|
|
22352
|
+
var Oe = _objectSpread2$g(_objectSpread2$g({}, W), {}, {
|
|
22335
22353
|
zIndex: u,
|
|
22336
22354
|
opacity: re === "motion" || re === "stable" || !o ? void 0 : 0,
|
|
22337
22355
|
pointerEvents: !o && re !== "stable" ? "none" : void 0
|
|
@@ -22350,8 +22368,8 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22350
22368
|
onEnterPrepare: ve,
|
|
22351
22369
|
removeOnLeave: f,
|
|
22352
22370
|
forceRender: p,
|
|
22353
|
-
children: function(
|
|
22354
|
-
var Fe =
|
|
22371
|
+
children: function(pe, ge) {
|
|
22372
|
+
var Fe = pe.className, Te = pe.style, Re = classNames(a, s, P, Fe);
|
|
22355
22373
|
return /* @__PURE__ */ jsx(RcAlign, {
|
|
22356
22374
|
target: me(),
|
|
22357
22375
|
ref: S,
|
|
@@ -22367,7 +22385,7 @@ var PopupInner = /* @__PURE__ */ React$n.forwardRef(function(e, r) {
|
|
|
22367
22385
|
onMouseDownCapture: y,
|
|
22368
22386
|
onTouchStartCapture: x,
|
|
22369
22387
|
onClick: O,
|
|
22370
|
-
style: _objectSpread2$g(_objectSpread2$g({},
|
|
22388
|
+
style: _objectSpread2$g(_objectSpread2$g({}, Te), Oe),
|
|
22371
22389
|
children: M
|
|
22372
22390
|
})
|
|
22373
22391
|
}, "popup");
|
|
@@ -23179,72 +23197,72 @@ placements$1.default = _default$1;
|
|
|
23179
23197
|
}
|
|
23180
23198
|
var O = /* @__PURE__ */ f.forwardRef(function(T, G) {
|
|
23181
23199
|
var E, P = f.useContext(p.ConfigContext), B = P.getPopupContainer, N = P.getPrefixCls, L = P.direction;
|
|
23182
|
-
process.env.NODE_ENV !== "production" && [["visible", "open"], ["defaultVisible", "defaultOpen"], ["onVisibleChange", "onOpenChange"], ["afterVisibleChange", "afterOpenChange"]].forEach(function(
|
|
23183
|
-
var
|
|
23184
|
-
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."));
|
|
23185
23203
|
});
|
|
23186
23204
|
var W = (0, d.default)(!1, {
|
|
23187
23205
|
value: T.open !== void 0 ? T.open : T.visible,
|
|
23188
23206
|
defaultValue: T.defaultOpen !== void 0 ? T.defaultOpen : T.defaultVisible
|
|
23189
23207
|
}), K = (0, s.default)(W, 2), H = K[0], z = K[1], U = function() {
|
|
23190
|
-
var
|
|
23191
|
-
return !
|
|
23192
|
-
}, re = function(
|
|
23193
|
-
var
|
|
23194
|
-
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));
|
|
23195
23213
|
}, ae = function() {
|
|
23196
|
-
var
|
|
23197
|
-
return
|
|
23198
|
-
arrowPointAtCenter:
|
|
23199
|
-
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
|
|
23200
23218
|
});
|
|
23201
|
-
}, ne = function(
|
|
23202
|
-
var
|
|
23203
|
-
var
|
|
23204
|
-
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]);
|
|
23205
23223
|
});
|
|
23206
|
-
if (!!
|
|
23207
|
-
var
|
|
23224
|
+
if (!!cn) {
|
|
23225
|
+
var Ze = xt.getBoundingClientRect(), _t = {
|
|
23208
23226
|
top: "50%",
|
|
23209
23227
|
left: "50%"
|
|
23210
23228
|
};
|
|
23211
|
-
/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);
|
|
23212
23230
|
}
|
|
23213
23231
|
}, J = function() {
|
|
23214
|
-
var
|
|
23215
|
-
return
|
|
23216
|
-
}, oe = T.getPopupContainer, ie = T.placement,
|
|
23217
|
-
!("open" in T) && !("visible" in T) && U() && (
|
|
23218
|
-
var
|
|
23219
|
-
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), {
|
|
23220
23238
|
background: ge
|
|
23221
|
-
}),
|
|
23239
|
+
}), it = {
|
|
23222
23240
|
"--antd-arrow-background-color": ge
|
|
23223
23241
|
}), /* @__PURE__ */ f.createElement(u.default, (0, l.default)({}, ve, {
|
|
23224
|
-
placement:
|
|
23242
|
+
placement: ce,
|
|
23225
23243
|
mouseEnterDelay: Q,
|
|
23226
23244
|
mouseLeaveDelay: he,
|
|
23227
23245
|
prefixCls: Re,
|
|
23228
|
-
overlayClassName:
|
|
23246
|
+
overlayClassName: Pe,
|
|
23229
23247
|
getTooltipContainer: oe || M || B,
|
|
23230
23248
|
ref: G,
|
|
23231
23249
|
builtinPlacements: ae(),
|
|
23232
23250
|
overlay: J(),
|
|
23233
|
-
visible:
|
|
23251
|
+
visible: et,
|
|
23234
23252
|
onVisibleChange: re,
|
|
23235
23253
|
onPopupAlign: ne,
|
|
23236
|
-
overlayInnerStyle:
|
|
23254
|
+
overlayInnerStyle: jt,
|
|
23237
23255
|
arrowContent: /* @__PURE__ */ f.createElement("span", {
|
|
23238
23256
|
className: "".concat(Re, "-arrow-content"),
|
|
23239
|
-
style:
|
|
23257
|
+
style: it
|
|
23240
23258
|
}),
|
|
23241
23259
|
motion: {
|
|
23242
23260
|
motionName: (0, m.getTransitionName)(Ae, "zoom-big-fast", T.transitionName),
|
|
23243
23261
|
motionDeadline: 1e3
|
|
23244
23262
|
}
|
|
23245
|
-
}),
|
|
23246
|
-
className:
|
|
23247
|
-
}) :
|
|
23263
|
+
}), et ? (0, v.cloneElement)(Ht, {
|
|
23264
|
+
className: Yt
|
|
23265
|
+
}) : Ht);
|
|
23248
23266
|
});
|
|
23249
23267
|
process.env.NODE_ENV !== "production" && (O.displayName = "Tooltip");
|
|
23250
23268
|
var S = O;
|
|
@@ -23294,10 +23312,10 @@ EnterOutlined$2.default = _default;
|
|
|
23294
23312
|
ne(G);
|
|
23295
23313
|
}, [G]), d.useEffect(function() {
|
|
23296
23314
|
if (K.current && K.current.resizableTextArea) {
|
|
23297
|
-
var
|
|
23298
|
-
|
|
23299
|
-
var D =
|
|
23300
|
-
|
|
23315
|
+
var Oe = K.current.resizableTextArea.textArea;
|
|
23316
|
+
Oe.focus();
|
|
23317
|
+
var D = Oe.value.length;
|
|
23318
|
+
Oe.setSelectionRange(D, D);
|
|
23301
23319
|
}
|
|
23302
23320
|
}, []);
|
|
23303
23321
|
var J = function(D) {
|
|
@@ -23307,14 +23325,14 @@ EnterOutlined$2.default = _default;
|
|
|
23307
23325
|
H.current = !0;
|
|
23308
23326
|
}, ie = function() {
|
|
23309
23327
|
H.current = !1;
|
|
23310
|
-
},
|
|
23328
|
+
}, ce = function(D) {
|
|
23311
23329
|
var M = D.keyCode;
|
|
23312
23330
|
H.current || (z.current = M);
|
|
23313
23331
|
}, me = function() {
|
|
23314
23332
|
E(ae.trim());
|
|
23315
23333
|
}, Q = function(D) {
|
|
23316
|
-
var M = D.keyCode,
|
|
23317
|
-
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());
|
|
23318
23336
|
}, te = function() {
|
|
23319
23337
|
me();
|
|
23320
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);
|
|
@@ -23326,7 +23344,7 @@ EnterOutlined$2.default = _default;
|
|
|
23326
23344
|
maxLength: O,
|
|
23327
23345
|
value: ae,
|
|
23328
23346
|
onChange: J,
|
|
23329
|
-
onKeyDown:
|
|
23347
|
+
onKeyDown: ce,
|
|
23330
23348
|
onKeyUp: Q,
|
|
23331
23349
|
onCompositionStart: oe,
|
|
23332
23350
|
onCompositionEnd: ie,
|
|
@@ -23426,30 +23444,30 @@ var Ellipsis = {};
|
|
|
23426
23444
|
return x;
|
|
23427
23445
|
}
|
|
23428
23446
|
var m = 0, g = 1, v = 2, C = 3, w = 4, I = function(O) {
|
|
23429
|
-
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() {
|
|
23430
23448
|
return (0, c.default)(G);
|
|
23431
|
-
}, [G]),
|
|
23449
|
+
}, [G]), Oe = d.useMemo(function() {
|
|
23432
23450
|
return p(ve);
|
|
23433
23451
|
}, [ve]), D = d.useMemo(function() {
|
|
23434
|
-
return !S || J !== C ? T(ve, !1) : T(h(ve, z), z <
|
|
23435
|
-
}, [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]);
|
|
23436
23454
|
(0, u.default)(function() {
|
|
23437
|
-
S && E && P &&
|
|
23438
|
-
}, [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() {
|
|
23439
23457
|
var Fe;
|
|
23440
23458
|
J === g && Q(((Fe = te.current) === null || Fe === void 0 ? void 0 : Fe.offsetHeight) || 0);
|
|
23441
23459
|
}, [J]), (0, u.default)(function() {
|
|
23442
|
-
var Fe,
|
|
23460
|
+
var Fe, Te;
|
|
23443
23461
|
if (me) {
|
|
23444
23462
|
if (J === g) {
|
|
23445
23463
|
var Re = ((Fe = he.current) === null || Fe === void 0 ? void 0 : Fe.offsetHeight) || 0, Ae = B * me;
|
|
23446
23464
|
Re <= Ae ? (oe(w), N(!1)) : oe(v);
|
|
23447
23465
|
} else if (J === v)
|
|
23448
23466
|
if (H !== U) {
|
|
23449
|
-
var
|
|
23450
|
-
H === U - 1 ?
|
|
23451
|
-
var
|
|
23452
|
-
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]);
|
|
23453
23471
|
} else
|
|
23454
23472
|
oe(C), N(!0);
|
|
23455
23473
|
}
|
|
@@ -23459,7 +23477,7 @@ var Ellipsis = {};
|
|
|
23459
23477
|
whiteSpace: "normal",
|
|
23460
23478
|
margin: 0,
|
|
23461
23479
|
padding: 0
|
|
23462
|
-
},
|
|
23480
|
+
}, pe = function(Te, Re, Ae) {
|
|
23463
23481
|
return /* @__PURE__ */ d.createElement("span", {
|
|
23464
23482
|
"aria-hidden": !0,
|
|
23465
23483
|
ref: Re,
|
|
@@ -23473,15 +23491,15 @@ var Ellipsis = {};
|
|
|
23473
23491
|
pointerEvents: "none",
|
|
23474
23492
|
fontSize: Math.floor(P / 2) * 2
|
|
23475
23493
|
}, Ae)
|
|
23476
|
-
},
|
|
23477
|
-
}, ge = function(
|
|
23478
|
-
var Ae = h(ve,
|
|
23479
|
-
return
|
|
23494
|
+
}, Te);
|
|
23495
|
+
}, ge = function(Te, Re) {
|
|
23496
|
+
var Ae = h(ve, Te);
|
|
23497
|
+
return pe(T(Ae, !0), Re, M);
|
|
23480
23498
|
};
|
|
23481
|
-
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, {
|
|
23482
23500
|
wordBreak: "keep-all",
|
|
23483
23501
|
whiteSpace: "nowrap"
|
|
23484
|
-
}), J === g ?
|
|
23502
|
+
}), J === g ? pe(T(ve, !1), he, M) : ge(z, he)));
|
|
23485
23503
|
};
|
|
23486
23504
|
process.env.NODE_ENV !== "production" && (I.displayName = "Ellipsis");
|
|
23487
23505
|
var y = I;
|
|
@@ -23510,19 +23528,19 @@ var EllipsisTooltip = {};
|
|
|
23510
23528
|
}), e.default = void 0;
|
|
23511
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) {
|
|
23512
23530
|
var ie = {};
|
|
23513
|
-
for (var
|
|
23514
|
-
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]);
|
|
23515
23533
|
if (J != null && typeof Object.getOwnPropertySymbols == "function")
|
|
23516
|
-
for (var me = 0,
|
|
23517
|
-
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]]);
|
|
23518
23536
|
return ie;
|
|
23519
23537
|
};
|
|
23520
23538
|
function H(J, oe) {
|
|
23521
|
-
var ie = J.mark,
|
|
23522
|
-
function D(M,
|
|
23523
|
-
!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));
|
|
23524
23542
|
}
|
|
23525
|
-
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;
|
|
23526
23544
|
}
|
|
23527
23545
|
function z(J, oe, ie) {
|
|
23528
23546
|
return J === !0 || J === void 0 ? oe : J || ie && oe;
|
|
@@ -23531,81 +23549,81 @@ var EllipsisTooltip = {};
|
|
|
23531
23549
|
return J === !1 ? [!1, !1] : Array.isArray(J) ? J : [J];
|
|
23532
23550
|
}
|
|
23533
23551
|
var re = "...", ae = /* @__PURE__ */ y.forwardRef(function(J, oe) {
|
|
23534
|
-
var ie,
|
|
23535
|
-
value:
|
|
23536
|
-
}),
|
|
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) {
|
|
23537
23555
|
var rn;
|
|
23538
|
-
|
|
23556
|
+
qt && ((rn = kt.onStart) === null || rn === void 0 || rn.call(kt)), en(qt);
|
|
23539
23557
|
};
|
|
23540
23558
|
(0, B.default)(function() {
|
|
23541
23559
|
var nn;
|
|
23542
|
-
|
|
23543
|
-
}, [
|
|
23544
|
-
var gn = function(
|
|
23545
|
-
|
|
23546
|
-
},
|
|
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) {
|
|
23547
23565
|
var rn;
|
|
23548
|
-
(rn =
|
|
23549
|
-
},
|
|
23550
|
-
var
|
|
23551
|
-
(
|
|
23552
|
-
},
|
|
23553
|
-
|
|
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);
|
|
23554
23572
|
var Wn = function() {
|
|
23555
|
-
window.clearTimeout(
|
|
23556
|
-
}, tr = function(
|
|
23573
|
+
window.clearTimeout(pn.current);
|
|
23574
|
+
}, tr = function(qt) {
|
|
23557
23575
|
var rn;
|
|
23558
|
-
|
|
23559
|
-
|
|
23560
|
-
}, 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);
|
|
23561
23579
|
};
|
|
23562
23580
|
y.useEffect(function() {
|
|
23563
23581
|
return Wn;
|
|
23564
23582
|
}, []);
|
|
23565
|
-
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, {
|
|
23566
23584
|
expandable: !1
|
|
23567
|
-
}), $r = (0, c.default)(Kr, 2), Bn = $r[0], vn = $r[1], Pn = Bn && !
|
|
23568
|
-
return !Pn || vn.suffix !== void 0 || vn.onEllipsis || vn.expandable ||
|
|
23569
|
-
}, [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]);
|
|
23570
23588
|
(0, v.default)(function() {
|
|
23571
|
-
Bn && !Qn && (
|
|
23589
|
+
Bn && !Qn && (rr((0, T.isStyleSupport)("webkitLineClamp")), or((0, T.isStyleSupport)("textOverflow")));
|
|
23572
23590
|
}, [Qn, Bn]);
|
|
23573
23591
|
var Mn = y.useMemo(function() {
|
|
23574
23592
|
return Qn ? !1 : qn === 1 ? Zn : Gn;
|
|
23575
|
-
}, [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) {
|
|
23576
23594
|
var rn;
|
|
23577
|
-
|
|
23578
|
-
}, 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(
|
|
23579
|
-
var
|
|
23580
|
-
ro(
|
|
23581
|
-
}, 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) {
|
|
23582
23600
|
var rn;
|
|
23583
|
-
|
|
23601
|
+
Hn(qt), Ln !== qt && ((rn = vn.onEllipsis) === null || rn === void 0 || rn.call(vn, qt));
|
|
23584
23602
|
};
|
|
23585
23603
|
y.useEffect(function() {
|
|
23586
|
-
var nn =
|
|
23604
|
+
var nn = Yt.current;
|
|
23587
23605
|
if (Bn && Mn && nn) {
|
|
23588
|
-
var
|
|
23589
|
-
|
|
23606
|
+
var qt = Jn ? nn.offsetHeight < nn.scrollHeight : nn.offsetWidth < nn.scrollWidth;
|
|
23607
|
+
Xn !== qt && Wr(qt);
|
|
23590
23608
|
}
|
|
23591
23609
|
}, [Bn, Mn, D, Jn, Gr]), y.useEffect(function() {
|
|
23592
|
-
var nn =
|
|
23610
|
+
var nn = Yt.current;
|
|
23593
23611
|
if (!(typeof IntersectionObserver > "u" || !nn || !Mn || !Pn)) {
|
|
23594
|
-
var
|
|
23612
|
+
var qt = new IntersectionObserver(function() {
|
|
23595
23613
|
Yr(!!nn.offsetParent);
|
|
23596
23614
|
});
|
|
23597
|
-
return
|
|
23598
|
-
|
|
23615
|
+
return qt.observe(nn), function() {
|
|
23616
|
+
qt.disconnect();
|
|
23599
23617
|
};
|
|
23600
23618
|
}
|
|
23601
23619
|
}, [Mn, Pn]);
|
|
23602
23620
|
var Nn = {};
|
|
23603
23621
|
vn.tooltip === !0 ? Nn = {
|
|
23604
|
-
title: (ie =
|
|
23622
|
+
title: (ie = kt.text) !== null && ie !== void 0 ? ie : D
|
|
23605
23623
|
} : /* @__PURE__ */ y.isValidElement(vn.tooltip) ? Nn = {
|
|
23606
23624
|
title: vn.tooltip
|
|
23607
23625
|
} : (0, l.default)(vn.tooltip) === "object" ? Nn = (0, s.default)({
|
|
23608
|
-
title: (
|
|
23626
|
+
title: (ce = kt.text) !== null && ce !== void 0 ? ce : D
|
|
23609
23627
|
}, vn.tooltip) : Nn = {
|
|
23610
23628
|
title: vn.tooltip
|
|
23611
23629
|
};
|
|
@@ -23614,112 +23632,112 @@ var EllipsisTooltip = {};
|
|
|
23614
23632
|
return ["string", "number"].includes((0, l.default)(rn));
|
|
23615
23633
|
};
|
|
23616
23634
|
if (!(!Bn || Mn)) {
|
|
23617
|
-
if (nn(
|
|
23618
|
-
return
|
|
23635
|
+
if (nn(kt.text))
|
|
23636
|
+
return kt.text;
|
|
23619
23637
|
if (nn(D))
|
|
23620
23638
|
return D;
|
|
23621
|
-
if (nn(
|
|
23622
|
-
return
|
|
23639
|
+
if (nn(Te))
|
|
23640
|
+
return Te;
|
|
23623
23641
|
if (nn(Nn.title))
|
|
23624
23642
|
return Nn.title;
|
|
23625
23643
|
}
|
|
23626
|
-
}, [Bn, Mn,
|
|
23627
|
-
if (
|
|
23644
|
+
}, [Bn, Mn, Te, Nn.title, Pr]);
|
|
23645
|
+
if (_t)
|
|
23628
23646
|
return /* @__PURE__ */ y.createElement(E.default, {
|
|
23629
|
-
value: (me =
|
|
23630
|
-
onSave:
|
|
23631
|
-
onCancel:
|
|
23632
|
-
onEnd:
|
|
23633
|
-
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,
|
|
23634
23652
|
className: te,
|
|
23635
23653
|
style: he,
|
|
23636
|
-
direction:
|
|
23654
|
+
direction: Ht,
|
|
23637
23655
|
component: Fe,
|
|
23638
|
-
maxLength:
|
|
23639
|
-
autoSize:
|
|
23640
|
-
enterIcon:
|
|
23656
|
+
maxLength: kt.maxLength,
|
|
23657
|
+
autoSize: kt.autoSize,
|
|
23658
|
+
enterIcon: kt.enterIcon
|
|
23641
23659
|
});
|
|
23642
23660
|
var co = function() {
|
|
23643
|
-
var
|
|
23644
|
-
if (!
|
|
23661
|
+
var qt = vn.expandable, rn = vn.symbol;
|
|
23662
|
+
if (!qt)
|
|
23645
23663
|
return null;
|
|
23646
|
-
var
|
|
23647
|
-
return rn ?
|
|
23664
|
+
var bn;
|
|
23665
|
+
return rn ? bn = rn : bn = Jt.expand, /* @__PURE__ */ y.createElement("a", {
|
|
23648
23666
|
key: "expand",
|
|
23649
|
-
className: "".concat(
|
|
23667
|
+
className: "".concat(jt, "-expand"),
|
|
23650
23668
|
onClick: Xr,
|
|
23651
|
-
"aria-label":
|
|
23652
|
-
},
|
|
23669
|
+
"aria-label": Jt.expand
|
|
23670
|
+
}, bn);
|
|
23653
23671
|
}, uo = function() {
|
|
23654
|
-
if (!!
|
|
23655
|
-
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 : "";
|
|
23656
23674
|
return tn.includes("icon") ? /* @__PURE__ */ y.createElement(G.default, {
|
|
23657
23675
|
key: "edit",
|
|
23658
|
-
title: rn === !1 ? "" :
|
|
23676
|
+
title: rn === !1 ? "" : bn
|
|
23659
23677
|
}, /* @__PURE__ */ y.createElement(S.default, {
|
|
23660
|
-
ref:
|
|
23661
|
-
className: "".concat(
|
|
23678
|
+
ref: Pe,
|
|
23679
|
+
className: "".concat(jt, "-edit"),
|
|
23662
23680
|
onClick: gn,
|
|
23663
|
-
"aria-label":
|
|
23664
|
-
},
|
|
23681
|
+
"aria-label": Fn
|
|
23682
|
+
}, qt || /* @__PURE__ */ y.createElement(f.default, {
|
|
23665
23683
|
role: "button"
|
|
23666
23684
|
}))) : null;
|
|
23667
23685
|
}
|
|
23668
23686
|
}, fo = function() {
|
|
23669
|
-
if (
|
|
23670
|
-
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;
|
|
23671
23689
|
return /* @__PURE__ */ y.createElement(G.default, {
|
|
23672
23690
|
key: "copy",
|
|
23673
23691
|
title: Un
|
|
23674
23692
|
}, /* @__PURE__ */ y.createElement(S.default, {
|
|
23675
|
-
className: (0, p.default)("".concat(
|
|
23693
|
+
className: (0, p.default)("".concat(jt, "-copy"), dn && "".concat(jt, "-copy-success")),
|
|
23676
23694
|
onClick: tr,
|
|
23677
23695
|
"aria-label": go
|
|
23678
|
-
},
|
|
23696
|
+
}, dn ? z(Fn[1], /* @__PURE__ */ y.createElement(u.default, null), !0) : z(Fn[0], /* @__PURE__ */ y.createElement(d.default, null), !0)));
|
|
23679
23697
|
}
|
|
23680
|
-
}, po = function(
|
|
23681
|
-
return [
|
|
23682
|
-
}, ho = function(
|
|
23683
|
-
return [
|
|
23698
|
+
}, po = function(qt) {
|
|
23699
|
+
return [qt && co(), uo(), fo()];
|
|
23700
|
+
}, ho = function(qt) {
|
|
23701
|
+
return [qt && /* @__PURE__ */ y.createElement("span", {
|
|
23684
23702
|
"aria-hidden": !0,
|
|
23685
23703
|
key: "ellipsis"
|
|
23686
|
-
}, re), vn.suffix, po(
|
|
23704
|
+
}, re), vn.suffix, po(qt)];
|
|
23687
23705
|
};
|
|
23688
23706
|
return /* @__PURE__ */ y.createElement(m.default, {
|
|
23689
23707
|
onResize: so,
|
|
23690
23708
|
disabled: !Pn || Mn
|
|
23691
23709
|
}, function(nn) {
|
|
23692
|
-
var
|
|
23710
|
+
var qt;
|
|
23693
23711
|
return /* @__PURE__ */ y.createElement(W.default, {
|
|
23694
23712
|
tooltipProps: Nn,
|
|
23695
23713
|
enabledEllipsis: Pn,
|
|
23696
23714
|
isEllipsis: Pr
|
|
23697
23715
|
}, /* @__PURE__ */ y.createElement(N.default, (0, s.default)({
|
|
23698
|
-
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),
|
|
23699
23717
|
prefixCls: Q,
|
|
23700
23718
|
style: (0, s.default)((0, s.default)({}, he), {
|
|
23701
23719
|
WebkitLineClamp: Jn ? qn : void 0
|
|
23702
23720
|
}),
|
|
23703
23721
|
component: Fe,
|
|
23704
|
-
ref: (0, I.composeRef)(nn,
|
|
23705
|
-
direction:
|
|
23722
|
+
ref: (0, I.composeRef)(nn, Yt, oe),
|
|
23723
|
+
direction: Ht,
|
|
23706
23724
|
onClick: tn.includes("text") ? gn : void 0,
|
|
23707
23725
|
"aria-label": er == null ? void 0 : er.toString(),
|
|
23708
|
-
title:
|
|
23709
|
-
},
|
|
23726
|
+
title: Te
|
|
23727
|
+
}, it), /* @__PURE__ */ y.createElement(L.default, {
|
|
23710
23728
|
enabledMeasure: Pn && !Mn,
|
|
23711
23729
|
text: D,
|
|
23712
23730
|
rows: qn,
|
|
23713
23731
|
width: no,
|
|
23714
23732
|
fontSize: ao,
|
|
23715
23733
|
onEllipsis: lo
|
|
23716
|
-
}, function(rn,
|
|
23717
|
-
var
|
|
23718
|
-
rn.length &&
|
|
23734
|
+
}, function(rn, bn) {
|
|
23735
|
+
var Fn = rn;
|
|
23736
|
+
rn.length && bn && er && (Fn = /* @__PURE__ */ y.createElement("span", {
|
|
23719
23737
|
key: "show-content",
|
|
23720
23738
|
"aria-hidden": !0
|
|
23721
|
-
},
|
|
23722
|
-
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)));
|
|
23723
23741
|
return Un;
|
|
23724
23742
|
})));
|
|
23725
23743
|
});
|
|
@@ -24489,7 +24507,7 @@ function filterDuplicateItems(e) {
|
|
|
24489
24507
|
});
|
|
24490
24508
|
}
|
|
24491
24509
|
const One2manyInput = (e) => {
|
|
24492
|
-
var
|
|
24510
|
+
var cn;
|
|
24493
24511
|
const {
|
|
24494
24512
|
value: r,
|
|
24495
24513
|
onChange: o,
|
|
@@ -24513,47 +24531,47 @@ const One2manyInput = (e) => {
|
|
|
24513
24531
|
t: I
|
|
24514
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(), {
|
|
24515
24533
|
readOnly: ie,
|
|
24516
|
-
relation:
|
|
24534
|
+
relation: ce,
|
|
24517
24535
|
context: me,
|
|
24518
24536
|
domain: Q
|
|
24519
24537
|
} = a, te = a.type === "many2many", {
|
|
24520
24538
|
id: he
|
|
24521
|
-
} = a, ve = l.filter((
|
|
24539
|
+
} = a, ve = l.filter((Ze) => Ze.values && Ze.operation !== "pendingRemove");
|
|
24522
24540
|
useEffect(() => {
|
|
24523
|
-
l.some((
|
|
24541
|
+
l.some((Ze) => !Ze.values) && D();
|
|
24524
24542
|
}, [l]), useEffect(() => {
|
|
24525
|
-
|
|
24543
|
+
pe();
|
|
24526
24544
|
}, [C]);
|
|
24527
|
-
const
|
|
24528
|
-
var
|
|
24545
|
+
const Oe = (Ze) => {
|
|
24546
|
+
var _t, en;
|
|
24529
24547
|
o == null || o({
|
|
24530
|
-
fields: ((
|
|
24531
|
-
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)
|
|
24532
24550
|
});
|
|
24533
24551
|
}, D = async () => {
|
|
24534
24552
|
await M(), d > ve.length - 1 && d !== 0 && f(0);
|
|
24535
24553
|
}, M = async () => {
|
|
24536
|
-
var
|
|
24554
|
+
var Ze;
|
|
24537
24555
|
T(!0), O(!1), E(void 0);
|
|
24538
24556
|
try {
|
|
24539
|
-
const
|
|
24557
|
+
const _t = await readObjectValues({
|
|
24540
24558
|
treeFields: s.get("tree").fields,
|
|
24541
|
-
formFields: ((
|
|
24542
|
-
model:
|
|
24559
|
+
formFields: ((Ze = s.get("form")) == null ? void 0 : Ze.fields) || {},
|
|
24560
|
+
model: ce,
|
|
24543
24561
|
items: l,
|
|
24544
24562
|
context: {
|
|
24545
24563
|
...v == null ? void 0 : v(),
|
|
24546
24564
|
...me
|
|
24547
24565
|
}
|
|
24548
24566
|
});
|
|
24549
|
-
oe.current || (oe.current =
|
|
24550
|
-
} catch (
|
|
24551
|
-
E(
|
|
24567
|
+
oe.current || (oe.current = _t.map((en) => en.id)), Oe(_t);
|
|
24568
|
+
} catch (_t) {
|
|
24569
|
+
E(_t);
|
|
24552
24570
|
} finally {
|
|
24553
24571
|
T(!1);
|
|
24554
24572
|
}
|
|
24555
24573
|
};
|
|
24556
|
-
async function
|
|
24574
|
+
async function pe() {
|
|
24557
24575
|
Q && (ae.current = transformDomainForChildWidget({
|
|
24558
24576
|
domain: await ConnectionProvider.getHandler().evalDomain({
|
|
24559
24577
|
domain: Q,
|
|
@@ -24571,56 +24589,56 @@ const One2manyInput = (e) => {
|
|
|
24571
24589
|
})));
|
|
24572
24590
|
}
|
|
24573
24591
|
const ge = () => {
|
|
24574
|
-
const
|
|
24592
|
+
const Ze = Array.from(s.keys()), _t = Ze[(Ze.indexOf(c) + 1) % Ze.length];
|
|
24575
24593
|
c === "form" ? Ae(() => {
|
|
24576
|
-
u(
|
|
24577
|
-
}) : u(
|
|
24594
|
+
u(_t);
|
|
24595
|
+
}) : u(_t);
|
|
24578
24596
|
}, Fe = () => {
|
|
24579
24597
|
d > 0 && (c === "form" ? Ae(() => {
|
|
24580
24598
|
f(d - 1);
|
|
24581
24599
|
}) : f(d - 1));
|
|
24582
|
-
},
|
|
24583
|
-
const
|
|
24584
|
-
d <
|
|
24600
|
+
}, Te = () => {
|
|
24601
|
+
const Ze = ve.length;
|
|
24602
|
+
d < Ze - 1 && (c === "form" ? Ae(() => {
|
|
24585
24603
|
f(d + 1);
|
|
24586
24604
|
}) : f(d + 1));
|
|
24587
24605
|
}, Re = async () => {
|
|
24588
|
-
const
|
|
24589
|
-
model:
|
|
24590
|
-
ids: [
|
|
24606
|
+
const Ze = ve[d].id, _t = (await ConnectionProvider.getHandler().readObjects({
|
|
24607
|
+
model: ce,
|
|
24608
|
+
ids: [Ze],
|
|
24591
24609
|
fields: s.get("form").fields,
|
|
24592
24610
|
context: {
|
|
24593
24611
|
...v == null ? void 0 : v(),
|
|
24594
24612
|
...me
|
|
24595
24613
|
}
|
|
24596
|
-
}))[0],
|
|
24597
|
-
model:
|
|
24598
|
-
ids: [
|
|
24614
|
+
}))[0], en = (await ConnectionProvider.getHandler().readObjects({
|
|
24615
|
+
model: ce,
|
|
24616
|
+
ids: [Ze],
|
|
24599
24617
|
fields: s.get("tree").fields,
|
|
24600
24618
|
context: {
|
|
24601
24619
|
...v == null ? void 0 : v(),
|
|
24602
24620
|
...me
|
|
24603
24621
|
}
|
|
24604
|
-
}))[0],
|
|
24622
|
+
}))[0], Xt = l.map((tn) => tn.id === Ze ? {
|
|
24605
24623
|
...tn,
|
|
24606
24624
|
operation: "original",
|
|
24607
|
-
values:
|
|
24608
|
-
treeValues:
|
|
24625
|
+
values: _t,
|
|
24626
|
+
treeValues: en
|
|
24609
24627
|
} : tn);
|
|
24610
|
-
|
|
24611
|
-
}, Ae = (
|
|
24628
|
+
Oe(Xt);
|
|
24629
|
+
}, Ae = (Ze) => {
|
|
24612
24630
|
x ? showDialog$6({
|
|
24613
24631
|
lang: w,
|
|
24614
24632
|
onOk: () => {
|
|
24615
|
-
Re(),
|
|
24633
|
+
Re(), Ze(), O(!1);
|
|
24616
24634
|
}
|
|
24617
|
-
}) :
|
|
24618
|
-
},
|
|
24635
|
+
}) : Ze();
|
|
24636
|
+
}, et = () => {
|
|
24619
24637
|
if (te) {
|
|
24620
24638
|
showDialog$1({
|
|
24621
24639
|
lang: w,
|
|
24622
24640
|
onOk: () => {
|
|
24623
|
-
c === "form" ?
|
|
24641
|
+
c === "form" ? Yt() : Pe();
|
|
24624
24642
|
}
|
|
24625
24643
|
});
|
|
24626
24644
|
return;
|
|
@@ -24628,185 +24646,185 @@ const One2manyInput = (e) => {
|
|
|
24628
24646
|
showDialog$2({
|
|
24629
24647
|
lang: w,
|
|
24630
24648
|
onOk: () => {
|
|
24631
|
-
c === "form" ?
|
|
24649
|
+
c === "form" ? Yt() : Pe();
|
|
24632
24650
|
}
|
|
24633
24651
|
});
|
|
24634
|
-
},
|
|
24652
|
+
}, Ht = async () => {
|
|
24635
24653
|
const {
|
|
24636
|
-
inv_field:
|
|
24654
|
+
inv_field: Ze
|
|
24637
24655
|
} = a;
|
|
24638
|
-
let
|
|
24639
|
-
|
|
24640
|
-
[
|
|
24656
|
+
let _t;
|
|
24657
|
+
Ze && h && (_t = {
|
|
24658
|
+
[Ze]: h
|
|
24641
24659
|
}), c === "form" ? Ae(() => {
|
|
24642
24660
|
re(!0), K({
|
|
24643
|
-
defaultValues:
|
|
24661
|
+
defaultValues: _t
|
|
24644
24662
|
}), B(!0);
|
|
24645
24663
|
}) : (re(!0), K({
|
|
24646
|
-
defaultValues:
|
|
24664
|
+
defaultValues: _t
|
|
24647
24665
|
}), B(!0));
|
|
24648
|
-
},
|
|
24666
|
+
}, Jt = async () => {
|
|
24649
24667
|
c === "form" ? Ae(() => {
|
|
24650
24668
|
L(!0);
|
|
24651
24669
|
}) : L(!0);
|
|
24652
|
-
},
|
|
24670
|
+
}, Yt = async () => {
|
|
24653
24671
|
T(!0), O(!1), E(void 0);
|
|
24654
24672
|
try {
|
|
24655
24673
|
if (ve[d].id > 0) {
|
|
24656
|
-
const
|
|
24657
|
-
...
|
|
24674
|
+
const Ze = l.map((_t) => _t.id === ve[d].id ? {
|
|
24675
|
+
..._t,
|
|
24658
24676
|
operation: "pendingRemove"
|
|
24659
|
-
} :
|
|
24660
|
-
|
|
24677
|
+
} : _t);
|
|
24678
|
+
Oe(Ze);
|
|
24661
24679
|
} else
|
|
24662
|
-
|
|
24663
|
-
} catch (
|
|
24664
|
-
E(
|
|
24680
|
+
Oe(l.filter((Ze) => Ze.id !== ve[d].id));
|
|
24681
|
+
} catch (Ze) {
|
|
24682
|
+
E(Ze);
|
|
24665
24683
|
}
|
|
24666
24684
|
f(0), T(!1);
|
|
24667
|
-
},
|
|
24668
|
-
const
|
|
24685
|
+
}, Pe = async () => {
|
|
24686
|
+
const Ze = ve.filter((_t) => H.includes(_t.id));
|
|
24669
24687
|
T(!0), O(!1), E(void 0);
|
|
24670
24688
|
try {
|
|
24671
|
-
const
|
|
24672
|
-
...
|
|
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,
|
|
24673
24691
|
operation: "pendingRemove"
|
|
24674
|
-
} :
|
|
24675
|
-
|
|
24676
|
-
} catch (
|
|
24677
|
-
E(
|
|
24692
|
+
} : Xt);
|
|
24693
|
+
Oe(en);
|
|
24694
|
+
} catch (_t) {
|
|
24695
|
+
E(_t);
|
|
24678
24696
|
}
|
|
24679
24697
|
f(0), T(!1);
|
|
24680
|
-
},
|
|
24681
|
-
let
|
|
24682
|
-
if (
|
|
24683
|
-
|
|
24684
|
-
id:
|
|
24685
|
-
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",
|
|
24686
24704
|
values: {
|
|
24687
|
-
...
|
|
24688
|
-
id:
|
|
24705
|
+
...en,
|
|
24706
|
+
id: Ze
|
|
24689
24707
|
},
|
|
24690
24708
|
treeValues: {
|
|
24691
|
-
...
|
|
24692
|
-
id:
|
|
24709
|
+
...en,
|
|
24710
|
+
id: Ze
|
|
24693
24711
|
}
|
|
24694
24712
|
} : tn);
|
|
24695
24713
|
else {
|
|
24696
24714
|
const tn = getNextPendingId(l);
|
|
24697
|
-
|
|
24715
|
+
Xt = l.concat({
|
|
24698
24716
|
id: tn,
|
|
24699
24717
|
operation: "pendingCreate",
|
|
24700
24718
|
values: {
|
|
24701
|
-
...
|
|
24719
|
+
...en,
|
|
24702
24720
|
id: tn
|
|
24703
24721
|
},
|
|
24704
24722
|
treeValues: {
|
|
24705
|
-
...
|
|
24723
|
+
...en,
|
|
24706
24724
|
id: tn
|
|
24707
24725
|
}
|
|
24708
24726
|
});
|
|
24709
24727
|
}
|
|
24710
|
-
|
|
24711
|
-
},
|
|
24728
|
+
Oe(Xt), U || B(!1);
|
|
24729
|
+
}, it = (Ze) => {
|
|
24712
24730
|
const {
|
|
24713
|
-
id:
|
|
24714
|
-
} =
|
|
24715
|
-
K(l.find((
|
|
24716
|
-
},
|
|
24731
|
+
id: _t
|
|
24732
|
+
} = Ze;
|
|
24733
|
+
K(l.find((en) => en.id === _t)), re(!1), B(!0);
|
|
24734
|
+
}, Qt = async (Ze) => {
|
|
24717
24735
|
T(!0);
|
|
24718
|
-
let
|
|
24719
|
-
const
|
|
24736
|
+
let _t = l;
|
|
24737
|
+
const en = Ze.filter((Xt) => !l.find((tn) => tn.id === Xt));
|
|
24720
24738
|
try {
|
|
24721
|
-
for (const
|
|
24739
|
+
for (const Xt of en) {
|
|
24722
24740
|
const tn = (await ConnectionProvider.getHandler().readObjects({
|
|
24723
|
-
model:
|
|
24724
|
-
ids: [
|
|
24741
|
+
model: ce,
|
|
24742
|
+
ids: [Xt],
|
|
24725
24743
|
fields: s.get("form").fields,
|
|
24726
24744
|
context: {
|
|
24727
24745
|
...v == null ? void 0 : v(),
|
|
24728
24746
|
...me
|
|
24729
24747
|
}
|
|
24730
|
-
}))[0],
|
|
24731
|
-
model:
|
|
24732
|
-
ids: [
|
|
24748
|
+
}))[0], un = (await ConnectionProvider.getHandler().readObjects({
|
|
24749
|
+
model: ce,
|
|
24750
|
+
ids: [Xt],
|
|
24733
24751
|
fields: s.get("tree").fields,
|
|
24734
24752
|
context: {
|
|
24735
24753
|
...v == null ? void 0 : v(),
|
|
24736
24754
|
...me
|
|
24737
24755
|
}
|
|
24738
24756
|
}))[0];
|
|
24739
|
-
|
|
24740
|
-
id:
|
|
24757
|
+
_t.push({
|
|
24758
|
+
id: Xt,
|
|
24741
24759
|
operation: "pendingLink",
|
|
24742
24760
|
values: tn,
|
|
24743
|
-
treeValues:
|
|
24761
|
+
treeValues: un
|
|
24744
24762
|
});
|
|
24745
24763
|
}
|
|
24746
|
-
|
|
24747
|
-
} catch (
|
|
24748
|
-
E(
|
|
24764
|
+
Oe(_t);
|
|
24765
|
+
} catch (Xt) {
|
|
24766
|
+
E(Xt);
|
|
24749
24767
|
} finally {
|
|
24750
24768
|
T(!1);
|
|
24751
24769
|
}
|
|
24752
24770
|
};
|
|
24753
|
-
function
|
|
24754
|
-
const
|
|
24771
|
+
function xt() {
|
|
24772
|
+
const Ze = ViewObjects[c];
|
|
24755
24773
|
if (c === "graph")
|
|
24756
24774
|
return parseGraph(s.get("graph").arch).string;
|
|
24757
24775
|
{
|
|
24758
|
-
const
|
|
24759
|
-
return
|
|
24776
|
+
const _t = new Ze(s.get(c).fields);
|
|
24777
|
+
return _t.parse(s.get(c).arch), _t.string;
|
|
24760
24778
|
}
|
|
24761
24779
|
}
|
|
24762
|
-
const
|
|
24763
|
-
var
|
|
24780
|
+
const Pt = () => {
|
|
24781
|
+
var _t, en, Xt, tn;
|
|
24764
24782
|
if (c === "form")
|
|
24765
24783
|
return ve.length === 0 ? I("noCurrentEntries") : /* @__PURE__ */ jsx(Form$1, {
|
|
24766
24784
|
formView: s.get("form"),
|
|
24767
|
-
values: (
|
|
24785
|
+
values: (_t = ve[d]) == null ? void 0 : _t.values,
|
|
24768
24786
|
parentContext: {
|
|
24769
24787
|
...v == null ? void 0 : v(),
|
|
24770
24788
|
...me
|
|
24771
24789
|
},
|
|
24772
24790
|
ref: y,
|
|
24773
|
-
model:
|
|
24774
|
-
id: (
|
|
24791
|
+
model: ce,
|
|
24792
|
+
id: (en = ve[d]) == null ? void 0 : en.id,
|
|
24775
24793
|
submitMode: "values",
|
|
24776
|
-
onFieldsChange: (
|
|
24777
|
-
var
|
|
24778
|
-
const gn = (
|
|
24779
|
-
...
|
|
24780
|
-
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,
|
|
24781
24799
|
values: {
|
|
24782
|
-
...
|
|
24800
|
+
...un,
|
|
24783
24801
|
id: gn
|
|
24784
24802
|
},
|
|
24785
24803
|
treeValues: {
|
|
24786
|
-
...
|
|
24804
|
+
...un,
|
|
24787
24805
|
id: gn
|
|
24788
24806
|
}
|
|
24789
|
-
} :
|
|
24790
|
-
|
|
24807
|
+
} : fn);
|
|
24808
|
+
Oe(mn), O(!0);
|
|
24791
24809
|
},
|
|
24792
24810
|
readOnly: ie
|
|
24793
24811
|
});
|
|
24794
|
-
const
|
|
24795
|
-
resultsToSort: ve.map((
|
|
24812
|
+
const Ze = ne ? sortResults({
|
|
24813
|
+
resultsToSort: ve.map((un) => un.treeValues),
|
|
24796
24814
|
sorter: ne,
|
|
24797
24815
|
fields: {
|
|
24798
24816
|
...s.get("tree").fields,
|
|
24799
|
-
...((
|
|
24817
|
+
...((Xt = s.get("form")) == null ? void 0 : Xt.fields) || {}
|
|
24800
24818
|
}
|
|
24801
|
-
}) : ve.map((
|
|
24819
|
+
}) : ve.map((un) => un.treeValues);
|
|
24802
24820
|
if (c === "tree")
|
|
24803
24821
|
return /* @__PURE__ */ jsx(Tree, {
|
|
24804
24822
|
total: ve.length,
|
|
24805
24823
|
limit: ve.length,
|
|
24806
24824
|
treeView: s.get("tree"),
|
|
24807
|
-
results:
|
|
24825
|
+
results: Ze,
|
|
24808
24826
|
loading: S,
|
|
24809
|
-
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,
|
|
24810
24828
|
showPagination: !1,
|
|
24811
24829
|
rowSelection: {
|
|
24812
24830
|
selectedRowKeys: H,
|
|
@@ -24816,11 +24834,11 @@ const One2manyInput = (e) => {
|
|
|
24816
24834
|
onChangeSort: J
|
|
24817
24835
|
});
|
|
24818
24836
|
if (c === "graph") {
|
|
24819
|
-
const
|
|
24837
|
+
const un = [[`${a.inv_field}`, "=", h]];
|
|
24820
24838
|
return /* @__PURE__ */ jsx(Graph, {
|
|
24821
24839
|
view_id: s.get("graph").view_id,
|
|
24822
24840
|
model: a.relation,
|
|
24823
|
-
domain:
|
|
24841
|
+
domain: un,
|
|
24824
24842
|
context: {
|
|
24825
24843
|
...v == null ? void 0 : v(),
|
|
24826
24844
|
...me
|
|
@@ -24836,34 +24854,34 @@ const One2manyInput = (e) => {
|
|
|
24836
24854
|
type: "error",
|
|
24837
24855
|
banner: !0
|
|
24838
24856
|
});
|
|
24839
|
-
const
|
|
24857
|
+
const kt = U;
|
|
24840
24858
|
return S ? /* @__PURE__ */ jsx(Spin, {}) : /* @__PURE__ */ jsxs(Fragment, {
|
|
24841
24859
|
children: [/* @__PURE__ */ jsx(One2manyTopBar, {
|
|
24842
24860
|
mode: c,
|
|
24843
|
-
title:
|
|
24861
|
+
title: xt(),
|
|
24844
24862
|
readOnly: ie,
|
|
24845
24863
|
isMany2Many: te,
|
|
24846
24864
|
formHasChanges: x,
|
|
24847
24865
|
totalItems: ve.length,
|
|
24848
24866
|
currentItemIndex: d,
|
|
24849
|
-
onDelete:
|
|
24850
|
-
onCreateItem:
|
|
24867
|
+
onDelete: et,
|
|
24868
|
+
onCreateItem: Ht,
|
|
24851
24869
|
onToggleViewMode: ge,
|
|
24852
24870
|
onPreviousItem: Fe,
|
|
24853
|
-
onNextItem:
|
|
24854
|
-
onSearchItem:
|
|
24871
|
+
onNextItem: Te,
|
|
24872
|
+
onSearchItem: Jt,
|
|
24855
24873
|
selectedRowKeys: H,
|
|
24856
|
-
showCreateButton: ((
|
|
24874
|
+
showCreateButton: ((cn = s.get("form")) == null ? void 0 : cn.fields) !== void 0,
|
|
24857
24875
|
showToggleButton: s.size > 1
|
|
24858
|
-
}),
|
|
24876
|
+
}), Pt(), /* @__PURE__ */ jsx(FormModal, {
|
|
24859
24877
|
formView: s.get("form"),
|
|
24860
|
-
model:
|
|
24878
|
+
model: ce,
|
|
24861
24879
|
id: W == null ? void 0 : W.id,
|
|
24862
24880
|
submitMode: "values",
|
|
24863
24881
|
values: W == null ? void 0 : W.values,
|
|
24864
24882
|
defaultValues: W == null ? void 0 : W.defaultValues,
|
|
24865
24883
|
visible: P,
|
|
24866
|
-
onSubmitSucceed:
|
|
24884
|
+
onSubmitSucceed: jt,
|
|
24867
24885
|
parentContext: {
|
|
24868
24886
|
...v == null ? void 0 : v(),
|
|
24869
24887
|
...me
|
|
@@ -24872,17 +24890,17 @@ const One2manyInput = (e) => {
|
|
|
24872
24890
|
re(!1), B(!1);
|
|
24873
24891
|
},
|
|
24874
24892
|
readOnly: ie,
|
|
24875
|
-
mustClearAfterSave:
|
|
24893
|
+
mustClearAfterSave: kt
|
|
24876
24894
|
}), /* @__PURE__ */ jsx(SearchModal, {
|
|
24877
24895
|
domain: ae.current,
|
|
24878
|
-
model:
|
|
24896
|
+
model: ce,
|
|
24879
24897
|
context: {
|
|
24880
24898
|
...v == null ? void 0 : v(),
|
|
24881
24899
|
...me
|
|
24882
24900
|
},
|
|
24883
24901
|
visible: N,
|
|
24884
|
-
onSelectValues: async (
|
|
24885
|
-
L(!1),
|
|
24902
|
+
onSelectValues: async (Ze) => {
|
|
24903
|
+
L(!1), Qt(Ze);
|
|
24886
24904
|
},
|
|
24887
24905
|
onCloseModal: () => {
|
|
24888
24906
|
L(!1);
|
|
@@ -29769,7 +29787,7 @@ function FormActionBar({
|
|
|
29769
29787
|
w == null || w(!1);
|
|
29770
29788
|
}
|
|
29771
29789
|
}
|
|
29772
|
-
const
|
|
29790
|
+
const ce = c || v || y || C;
|
|
29773
29791
|
function me(Q) {
|
|
29774
29792
|
W == null || W({
|
|
29775
29793
|
actionData: Q,
|
|
@@ -29790,7 +29808,7 @@ function FormActionBar({
|
|
|
29790
29808
|
}), /* @__PURE__ */ jsx(ActionButton, {
|
|
29791
29809
|
icon: /* @__PURE__ */ jsx(SaveOutlined, {}),
|
|
29792
29810
|
tooltip: B("save"),
|
|
29793
|
-
disabled: !l ||
|
|
29811
|
+
disabled: !l || ce,
|
|
29794
29812
|
loading: c,
|
|
29795
29813
|
onClick: s
|
|
29796
29814
|
}), /* @__PURE__ */ jsx(ActionButton, {
|
|
@@ -29830,13 +29848,13 @@ function FormActionBar({
|
|
|
29830
29848
|
onChangeView: (Q) => {
|
|
29831
29849
|
E == null || E(o), S == null || S(!1), a == null || a(Q);
|
|
29832
29850
|
},
|
|
29833
|
-
disabled:
|
|
29851
|
+
disabled: ce,
|
|
29834
29852
|
formHasChanges: l
|
|
29835
29853
|
}), separator$2(), /* @__PURE__ */ jsxs(Space, {
|
|
29836
29854
|
children: [/* @__PURE__ */ jsx(ActionButton, {
|
|
29837
29855
|
icon: /* @__PURE__ */ jsx(LeftOutlined, {}),
|
|
29838
29856
|
tooltip: B("previous"),
|
|
29839
|
-
disabled:
|
|
29857
|
+
disabled: ce,
|
|
29840
29858
|
loading: !1,
|
|
29841
29859
|
onClick: () => {
|
|
29842
29860
|
re(ne);
|
|
@@ -29844,7 +29862,7 @@ function FormActionBar({
|
|
|
29844
29862
|
}), /* @__PURE__ */ jsx(ActionButton, {
|
|
29845
29863
|
icon: /* @__PURE__ */ jsx(RightOutlined, {}),
|
|
29846
29864
|
tooltip: B("next"),
|
|
29847
|
-
disabled:
|
|
29865
|
+
disabled: ce,
|
|
29848
29866
|
loading: !1,
|
|
29849
29867
|
onClick: () => {
|
|
29850
29868
|
re(ae);
|
|
@@ -29852,7 +29870,7 @@ function FormActionBar({
|
|
|
29852
29870
|
})]
|
|
29853
29871
|
}), separator$2(), /* @__PURE__ */ jsx(DropdownButton, {
|
|
29854
29872
|
icon: /* @__PURE__ */ jsx(ThunderboltOutlined, {}),
|
|
29855
|
-
disabled:
|
|
29873
|
+
disabled: ce,
|
|
29856
29874
|
tooltip: B("actions"),
|
|
29857
29875
|
items: e == null ? void 0 : e.action,
|
|
29858
29876
|
onItemClick: (Q) => {
|
|
@@ -29860,7 +29878,7 @@ function FormActionBar({
|
|
|
29860
29878
|
}
|
|
29861
29879
|
}), /* @__PURE__ */ jsx(DropdownButton, {
|
|
29862
29880
|
icon: /* @__PURE__ */ jsx(PrinterOutlined, {}),
|
|
29863
|
-
disabled:
|
|
29881
|
+
disabled: ce,
|
|
29864
29882
|
tooltip: B("reports"),
|
|
29865
29883
|
items: e == null ? void 0 : e.print,
|
|
29866
29884
|
onItemClick: (Q) => {
|
|
@@ -29874,7 +29892,7 @@ function FormActionBar({
|
|
|
29874
29892
|
}
|
|
29875
29893
|
}), /* @__PURE__ */ jsx(DropdownButton, {
|
|
29876
29894
|
icon: /* @__PURE__ */ jsx(EnterOutlined$4, {}),
|
|
29877
|
-
disabled:
|
|
29895
|
+
disabled: ce,
|
|
29878
29896
|
tooltip: B("related"),
|
|
29879
29897
|
items: e == null ? void 0 : e.relate,
|
|
29880
29898
|
onItemClick: async (Q) => {
|
|
@@ -29887,7 +29905,7 @@ function FormActionBar({
|
|
|
29887
29905
|
});
|
|
29888
29906
|
}
|
|
29889
29907
|
}), /* @__PURE__ */ jsx(AttachmentsButton, {
|
|
29890
|
-
disabled:
|
|
29908
|
+
disabled: ce,
|
|
29891
29909
|
attachments: x,
|
|
29892
29910
|
onAddNewAttachment: () => {
|
|
29893
29911
|
const Q = u, te = m;
|
|
@@ -30495,10 +30513,10 @@ function TreeActionBar(e) {
|
|
|
30495
30513
|
try {
|
|
30496
30514
|
l == null || l(!0), await ConnectionProvider.getHandler().delete({
|
|
30497
30515
|
model: f,
|
|
30498
|
-
ids: s.map((
|
|
30516
|
+
ids: s.map((ce) => ce.id)
|
|
30499
30517
|
}), h == null || h(void 0), m == null || m(void 0), (ie = p == null ? void 0 : p.current) == null || ie.refreshResults();
|
|
30500
|
-
} catch (
|
|
30501
|
-
showDialog$8(
|
|
30518
|
+
} catch (ce) {
|
|
30519
|
+
showDialog$8(ce);
|
|
30502
30520
|
} finally {
|
|
30503
30521
|
l == null || l(!1);
|
|
30504
30522
|
}
|
|
@@ -30507,16 +30525,16 @@ function TreeActionBar(e) {
|
|
|
30507
30525
|
var ie;
|
|
30508
30526
|
try {
|
|
30509
30527
|
d == null || d(!0);
|
|
30510
|
-
const
|
|
30528
|
+
const ce = s[0].id;
|
|
30511
30529
|
await ConnectionProvider.getHandler().duplicate({
|
|
30512
|
-
id:
|
|
30530
|
+
id: ce,
|
|
30513
30531
|
model: f,
|
|
30514
30532
|
context: {
|
|
30515
30533
|
...E
|
|
30516
30534
|
}
|
|
30517
30535
|
}) && ((ie = p == null ? void 0 : p.current) == null || ie.refreshResults());
|
|
30518
|
-
} catch (
|
|
30519
|
-
showDialog$8(
|
|
30536
|
+
} catch (ce) {
|
|
30537
|
+
showDialog$8(ce);
|
|
30520
30538
|
} finally {
|
|
30521
30539
|
d == null || d(!1);
|
|
30522
30540
|
}
|
|
@@ -30525,18 +30543,18 @@ function TreeActionBar(e) {
|
|
|
30525
30543
|
K == null || K({
|
|
30526
30544
|
actionData: ie,
|
|
30527
30545
|
values: {
|
|
30528
|
-
active_id: s == null ? void 0 : s.map((
|
|
30529
|
-
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)
|
|
30530
30548
|
},
|
|
30531
30549
|
fields: {},
|
|
30532
30550
|
context: {
|
|
30533
30551
|
...E,
|
|
30534
|
-
active_id: s == null ? void 0 : s.map((
|
|
30535
|
-
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)
|
|
30536
30554
|
},
|
|
30537
30555
|
onRefreshParentValues: () => {
|
|
30538
|
-
var
|
|
30539
|
-
(
|
|
30556
|
+
var ce;
|
|
30557
|
+
(ce = p == null ? void 0 : p.current) == null || ce.refreshResults();
|
|
30540
30558
|
}
|
|
30541
30559
|
});
|
|
30542
30560
|
}
|
|
@@ -30622,7 +30640,7 @@ function TreeActionBar(e) {
|
|
|
30622
30640
|
...ie,
|
|
30623
30641
|
datas: {
|
|
30624
30642
|
...ie.datas || {},
|
|
30625
|
-
ids: s.map((
|
|
30643
|
+
ids: s.map((ce) => ce.id)
|
|
30626
30644
|
}
|
|
30627
30645
|
});
|
|
30628
30646
|
}
|
|
@@ -30665,15 +30683,15 @@ function TreeActionBar(e) {
|
|
|
30665
30683
|
}],
|
|
30666
30684
|
onItemClick: (ie) => {
|
|
30667
30685
|
if (ie.id === "print_screen") {
|
|
30668
|
-
let
|
|
30669
|
-
|
|
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({
|
|
30670
30688
|
id: -1,
|
|
30671
30689
|
model: f,
|
|
30672
30690
|
report_name: "printscreen.list",
|
|
30673
30691
|
type: "ir.actions.report.xml",
|
|
30674
30692
|
datas: {
|
|
30675
30693
|
model: f,
|
|
30676
|
-
ids:
|
|
30694
|
+
ids: ce
|
|
30677
30695
|
}
|
|
30678
30696
|
});
|
|
30679
30697
|
return;
|
|
@@ -30852,133 +30870,133 @@ function ActionView(e, r) {
|
|
|
30852
30870
|
action_type: v,
|
|
30853
30871
|
treeExpandable: C = !1,
|
|
30854
30872
|
limit: w
|
|
30855
|
-
} = 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(), {
|
|
30856
30874
|
t: Q
|
|
30857
30875
|
} = useContext(LocaleContext), te = useRef(), he = useRef(), ve = useContext(TabManagerContext), {
|
|
30858
|
-
setCurrentView:
|
|
30876
|
+
setCurrentView: Oe,
|
|
30859
30877
|
setCurrentId: D,
|
|
30860
30878
|
tabs: M,
|
|
30861
|
-
activeKey:
|
|
30879
|
+
activeKey: pe,
|
|
30862
30880
|
openAction: ge
|
|
30863
30881
|
} = ve || {};
|
|
30864
|
-
useHotkeys("ctrl+g,command+g", (
|
|
30865
|
-
|
|
30866
|
-
}, [
|
|
30867
|
-
function Fe(
|
|
30868
|
-
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);
|
|
30869
30887
|
}
|
|
30870
|
-
function
|
|
30871
|
-
y(
|
|
30888
|
+
function Te(Pe) {
|
|
30889
|
+
y(Pe), Oe == null || Oe(Pe);
|
|
30872
30890
|
}
|
|
30873
30891
|
useImperativeHandle(r, () => ({
|
|
30874
30892
|
canWeClose: Ae
|
|
30875
30893
|
}));
|
|
30876
30894
|
const Re = async () => {
|
|
30877
30895
|
T(!0);
|
|
30878
|
-
const
|
|
30879
|
-
for (const
|
|
30880
|
-
const [
|
|
30881
|
-
let
|
|
30896
|
+
const Pe = [];
|
|
30897
|
+
for (const it of l) {
|
|
30898
|
+
const [Qt, xt] = it;
|
|
30899
|
+
let Pt;
|
|
30882
30900
|
try {
|
|
30883
|
-
|
|
30901
|
+
xt !== "dashboard" && (Pt = await ConnectionProvider.getHandler().getView({
|
|
30884
30902
|
model: a,
|
|
30885
|
-
type:
|
|
30886
|
-
id:
|
|
30903
|
+
type: xt,
|
|
30904
|
+
id: Qt,
|
|
30887
30905
|
context: s
|
|
30888
30906
|
}));
|
|
30889
|
-
} catch (
|
|
30890
|
-
console.error(`${a} - ${
|
|
30907
|
+
} catch (kt) {
|
|
30908
|
+
console.error(`${a} - ${xt}\xA0- ${JSON.stringify(kt, null, 2)}`);
|
|
30891
30909
|
continue;
|
|
30892
30910
|
}
|
|
30893
|
-
switch (
|
|
30911
|
+
switch (xt) {
|
|
30894
30912
|
case "dashboard": {
|
|
30895
|
-
const
|
|
30896
|
-
const [,
|
|
30897
|
-
return
|
|
30913
|
+
const kt = l.find((Ze) => {
|
|
30914
|
+
const [, _t] = Ze;
|
|
30915
|
+
return _t === "form";
|
|
30898
30916
|
});
|
|
30899
|
-
let
|
|
30900
|
-
|
|
30917
|
+
let cn;
|
|
30918
|
+
kt && (cn = {
|
|
30901
30919
|
action_id: g,
|
|
30902
30920
|
action_type: v,
|
|
30903
30921
|
name: c,
|
|
30904
30922
|
res_id: s.active_id,
|
|
30905
30923
|
res_model: a,
|
|
30906
|
-
view_id:
|
|
30907
|
-
view_type:
|
|
30908
|
-
}),
|
|
30924
|
+
view_id: kt[0],
|
|
30925
|
+
view_type: kt[1]
|
|
30926
|
+
}), Pe.push({
|
|
30909
30927
|
type: "dashboard",
|
|
30910
30928
|
id: s.active_id,
|
|
30911
30929
|
model: a,
|
|
30912
30930
|
context: s,
|
|
30913
|
-
configAction:
|
|
30931
|
+
configAction: cn
|
|
30914
30932
|
});
|
|
30915
30933
|
break;
|
|
30916
30934
|
}
|
|
30917
30935
|
case "form": {
|
|
30918
|
-
|
|
30919
|
-
...
|
|
30920
|
-
type:
|
|
30936
|
+
Pe.push({
|
|
30937
|
+
...Pt,
|
|
30938
|
+
type: xt
|
|
30921
30939
|
});
|
|
30922
30940
|
break;
|
|
30923
30941
|
}
|
|
30924
30942
|
case "tree": {
|
|
30925
|
-
|
|
30926
|
-
...
|
|
30943
|
+
Pe.push({
|
|
30944
|
+
...Pt,
|
|
30927
30945
|
isExpandable: C,
|
|
30928
|
-
type:
|
|
30946
|
+
type: xt
|
|
30929
30947
|
});
|
|
30930
30948
|
break;
|
|
30931
30949
|
}
|
|
30932
30950
|
case "graph": {
|
|
30933
|
-
|
|
30934
|
-
...
|
|
30935
|
-
type:
|
|
30951
|
+
Pe.push({
|
|
30952
|
+
...Pt,
|
|
30953
|
+
type: xt
|
|
30936
30954
|
});
|
|
30937
30955
|
break;
|
|
30938
30956
|
}
|
|
30939
30957
|
}
|
|
30940
30958
|
}
|
|
30941
|
-
let
|
|
30942
|
-
!f &&
|
|
30943
|
-
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);
|
|
30944
30962
|
};
|
|
30945
30963
|
u({
|
|
30946
30964
|
tabKey: d,
|
|
30947
30965
|
canWeClose: Ae
|
|
30948
30966
|
}), useEffect(() => {
|
|
30949
|
-
const
|
|
30950
|
-
|
|
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();
|
|
30951
30969
|
}, [a, l, m]), useEffect(() => {
|
|
30952
|
-
|
|
30953
|
-
}, [M,
|
|
30970
|
+
pe === d && (D == null || D(E), Oe == null || Oe(I));
|
|
30971
|
+
}, [M, pe]);
|
|
30954
30972
|
async function Ae() {
|
|
30955
30973
|
return I.type === "form" ? await te.current.cancelUnsavedChanges() : !0;
|
|
30956
30974
|
}
|
|
30957
|
-
async function
|
|
30958
|
-
|
|
30975
|
+
async function et() {
|
|
30976
|
+
pe === d && (I.type === "form" && !await te.current.cancelUnsavedChanges() || J(!0));
|
|
30959
30977
|
}
|
|
30960
|
-
async function
|
|
30961
|
-
var
|
|
30978
|
+
async function Ht(Pe) {
|
|
30979
|
+
var xt;
|
|
30962
30980
|
ie(!0);
|
|
30963
|
-
const
|
|
30964
|
-
let
|
|
30965
|
-
if (
|
|
30981
|
+
const jt = K.findIndex((Pt) => Pt.id === Pe);
|
|
30982
|
+
let it;
|
|
30983
|
+
if (jt === -1) {
|
|
30966
30984
|
try {
|
|
30967
|
-
|
|
30985
|
+
it = (xt = await ConnectionProvider.getHandler().readObjects({
|
|
30968
30986
|
model: a,
|
|
30969
|
-
ids: [
|
|
30987
|
+
ids: [Pe],
|
|
30970
30988
|
context: s
|
|
30971
|
-
})) == null ? void 0 :
|
|
30989
|
+
})) == null ? void 0 : xt[0];
|
|
30972
30990
|
} catch {
|
|
30973
30991
|
}
|
|
30974
|
-
if (!
|
|
30992
|
+
if (!it) {
|
|
30975
30993
|
ie(!1), J(!1), showDialog$7(Q("idNotFound"));
|
|
30976
30994
|
return;
|
|
30977
30995
|
}
|
|
30978
30996
|
} else
|
|
30979
|
-
|
|
30997
|
+
it = K[jt];
|
|
30980
30998
|
ie(!1), J(!1);
|
|
30981
|
-
const
|
|
30999
|
+
const Qt = l.find((Pt) => Pt[1] === "form");
|
|
30982
31000
|
ge({
|
|
30983
31001
|
domain: [],
|
|
30984
31002
|
context: s,
|
|
@@ -30987,23 +31005,23 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
30987
31005
|
title: c,
|
|
30988
31006
|
target: "current",
|
|
30989
31007
|
initialView: {
|
|
30990
|
-
id:
|
|
31008
|
+
id: Qt == null ? void 0 : Qt[0],
|
|
30991
31009
|
type: "form"
|
|
30992
31010
|
},
|
|
30993
31011
|
action_id: g,
|
|
30994
31012
|
action_type: v,
|
|
30995
|
-
res_id:
|
|
31013
|
+
res_id: Pe
|
|
30996
31014
|
});
|
|
30997
31015
|
}
|
|
30998
|
-
function
|
|
30999
|
-
return x.map((
|
|
31000
|
-
switch (
|
|
31016
|
+
function Jt() {
|
|
31017
|
+
return x.map((Pe) => {
|
|
31018
|
+
switch (Pe.type) {
|
|
31001
31019
|
case "form":
|
|
31002
31020
|
return /* @__PURE__ */ jsx(FormActionView, {
|
|
31003
31021
|
formRef: te,
|
|
31004
31022
|
currentId: E,
|
|
31005
|
-
visible: I.type ===
|
|
31006
|
-
formView:
|
|
31023
|
+
visible: I.type === Pe.type && I.view_id === Pe.view_id,
|
|
31024
|
+
formView: Pe,
|
|
31007
31025
|
model: a,
|
|
31008
31026
|
context: s,
|
|
31009
31027
|
domain: o,
|
|
@@ -31012,58 +31030,58 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
31012
31030
|
results: K,
|
|
31013
31031
|
setResults: H,
|
|
31014
31032
|
setCurrentItemIndex: W
|
|
31015
|
-
}, `${
|
|
31033
|
+
}, `${Pe.type}-${Pe.view_id}`);
|
|
31016
31034
|
case "tree":
|
|
31017
31035
|
return /* @__PURE__ */ jsx(TreeActionView, {
|
|
31018
|
-
visible: I.type ===
|
|
31036
|
+
visible: I.type === Pe.type && I.view_id === Pe.view_id,
|
|
31019
31037
|
limit: w,
|
|
31020
31038
|
model: a,
|
|
31021
31039
|
context: s,
|
|
31022
31040
|
domain: o,
|
|
31023
|
-
formView: x.find((
|
|
31024
|
-
treeView:
|
|
31041
|
+
formView: x.find((jt) => jt.type === "form"),
|
|
31042
|
+
treeView: Pe,
|
|
31025
31043
|
searchTreeRef: he,
|
|
31026
|
-
searchTreeNameSearch:
|
|
31044
|
+
searchTreeNameSearch: ce,
|
|
31027
31045
|
availableViews: x,
|
|
31028
31046
|
results: K,
|
|
31029
31047
|
setCurrentItemIndex: W,
|
|
31030
31048
|
setCurrentId: Fe,
|
|
31031
|
-
setCurrentView:
|
|
31032
|
-
}, `${
|
|
31049
|
+
setCurrentView: Te
|
|
31050
|
+
}, `${Pe.type}-${Pe.view_id}`);
|
|
31033
31051
|
case "graph":
|
|
31034
31052
|
return /* @__PURE__ */ jsx(GraphActionView, {
|
|
31035
|
-
visible: I.type ===
|
|
31036
|
-
viewData:
|
|
31053
|
+
visible: I.type === Pe.type && I.view_id === Pe.view_id,
|
|
31054
|
+
viewData: Pe,
|
|
31037
31055
|
model: a,
|
|
31038
31056
|
context: s,
|
|
31039
31057
|
domain: o,
|
|
31040
|
-
treeView: x.find((
|
|
31041
|
-
formView: x.find((
|
|
31042
|
-
}, `${
|
|
31058
|
+
treeView: x.find((jt) => jt.type === "tree"),
|
|
31059
|
+
formView: x.find((jt) => jt.type === "form")
|
|
31060
|
+
}, `${Pe.type}-${Pe.view_id}`);
|
|
31043
31061
|
case "dashboard":
|
|
31044
31062
|
return /* @__PURE__ */ jsx(DashboardActionView, {
|
|
31045
|
-
dashboardData:
|
|
31046
|
-
}, `${
|
|
31063
|
+
dashboardData: Pe
|
|
31064
|
+
}, `${Pe.type}-${Pe.view_id}`);
|
|
31047
31065
|
}
|
|
31048
31066
|
});
|
|
31049
31067
|
}
|
|
31050
|
-
function
|
|
31068
|
+
function Yt() {
|
|
31051
31069
|
if (E === void 0 && I.type === "form")
|
|
31052
31070
|
te.current.clearAndReload();
|
|
31053
31071
|
else {
|
|
31054
31072
|
Fe(void 0);
|
|
31055
|
-
const
|
|
31056
|
-
|
|
31073
|
+
const Pe = x.find((jt) => jt.type === "form");
|
|
31074
|
+
Te(Pe);
|
|
31057
31075
|
}
|
|
31058
31076
|
}
|
|
31059
31077
|
return S ? /* @__PURE__ */ jsx(Spin, {}) : I ? /* @__PURE__ */ jsxs(ActionViewProvider, {
|
|
31060
31078
|
title: c,
|
|
31061
31079
|
currentView: I,
|
|
31062
|
-
setCurrentView:
|
|
31080
|
+
setCurrentView: Te,
|
|
31063
31081
|
availableViews: x,
|
|
31064
31082
|
formRef: te,
|
|
31065
31083
|
searchTreeRef: he,
|
|
31066
|
-
onNewClicked:
|
|
31084
|
+
onNewClicked: Yt,
|
|
31067
31085
|
currentId: E,
|
|
31068
31086
|
setCurrentId: Fe,
|
|
31069
31087
|
setCurrentItemIndex: W,
|
|
@@ -31078,12 +31096,12 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
31078
31096
|
selectedRowItems: B,
|
|
31079
31097
|
setSelectedRowItems: N,
|
|
31080
31098
|
setSearchTreeNameSearch: me,
|
|
31081
|
-
searchTreeNameSearch:
|
|
31082
|
-
goToResourceId:
|
|
31099
|
+
searchTreeNameSearch: ce,
|
|
31100
|
+
goToResourceId: Ht,
|
|
31083
31101
|
limit: w,
|
|
31084
|
-
children: [
|
|
31102
|
+
children: [Jt(), /* @__PURE__ */ jsx(GoToResourceModal, {
|
|
31085
31103
|
visible: ne,
|
|
31086
|
-
onIdSubmitted:
|
|
31104
|
+
onIdSubmitted: Ht,
|
|
31087
31105
|
isSearching: oe,
|
|
31088
31106
|
onCancel: () => {
|
|
31089
31107
|
J(!1);
|
|
@@ -31282,13 +31300,13 @@ function DashboardTree(e) {
|
|
|
31282
31300
|
parentContext: u = {}
|
|
31283
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) => {
|
|
31284
31302
|
J(!0), x(D), S((D - 1) * T.current);
|
|
31285
|
-
},
|
|
31303
|
+
}, ce = async () => {
|
|
31286
31304
|
const D = oe.current.length > 0 ? oe.current : l, M = mergeParams(G.current, D), {
|
|
31287
|
-
colors:
|
|
31305
|
+
colors: pe
|
|
31288
31306
|
} = getTree(v), {
|
|
31289
31307
|
totalItems: ge,
|
|
31290
31308
|
results: Fe,
|
|
31291
|
-
attrsEvaluated:
|
|
31309
|
+
attrsEvaluated: Te
|
|
31292
31310
|
} = await ConnectionProvider.getHandler().searchForTree({
|
|
31293
31311
|
params: M,
|
|
31294
31312
|
limit: T.current,
|
|
@@ -31296,11 +31314,11 @@ function DashboardTree(e) {
|
|
|
31296
31314
|
model: m,
|
|
31297
31315
|
fields: v.fields,
|
|
31298
31316
|
context: u,
|
|
31299
|
-
attrs:
|
|
31300
|
-
colors:
|
|
31317
|
+
attrs: pe && {
|
|
31318
|
+
colors: pe
|
|
31301
31319
|
}
|
|
31302
31320
|
}), Re = await ge;
|
|
31303
|
-
P(Re), W(getColorMap(
|
|
31321
|
+
P(Re), W(getColorMap(Te));
|
|
31304
31322
|
const Ae = sortResults({
|
|
31305
31323
|
resultsToSort: Fe,
|
|
31306
31324
|
sorter: K,
|
|
@@ -31312,7 +31330,7 @@ function DashboardTree(e) {
|
|
|
31312
31330
|
N(Ae);
|
|
31313
31331
|
}, me = async () => {
|
|
31314
31332
|
try {
|
|
31315
|
-
J(!0), await
|
|
31333
|
+
J(!0), await ce();
|
|
31316
31334
|
} catch (D) {
|
|
31317
31335
|
U(JSON.stringify(D));
|
|
31318
31336
|
} finally {
|
|
@@ -31365,7 +31383,7 @@ function DashboardTree(e) {
|
|
|
31365
31383
|
model: m,
|
|
31366
31384
|
treeView: v
|
|
31367
31385
|
});
|
|
31368
|
-
},
|
|
31386
|
+
}, Oe = () => !v || !w ? null : /* @__PURE__ */ jsxs("div", {
|
|
31369
31387
|
style: {
|
|
31370
31388
|
overflowY: "scroll"
|
|
31371
31389
|
},
|
|
@@ -31409,7 +31427,7 @@ function DashboardTree(e) {
|
|
|
31409
31427
|
style: {
|
|
31410
31428
|
padding: "2rem"
|
|
31411
31429
|
}
|
|
31412
|
-
}) :
|
|
31430
|
+
}) : Oe();
|
|
31413
31431
|
}
|
|
31414
31432
|
const DashboardForm = (e) => {
|
|
31415
31433
|
const {
|
|
@@ -31598,11 +31616,11 @@ function Dashboard(e, r) {
|
|
|
31598
31616
|
initialView: oe,
|
|
31599
31617
|
limit: ie
|
|
31600
31618
|
} = B;
|
|
31601
|
-
let
|
|
31619
|
+
let ce = {};
|
|
31602
31620
|
try {
|
|
31603
|
-
|
|
31621
|
+
ce = JSON.parse(L.replace(/'/g, '"'));
|
|
31604
31622
|
} catch {
|
|
31605
|
-
|
|
31623
|
+
ce = {
|
|
31606
31624
|
x: P * 2,
|
|
31607
31625
|
y: 0,
|
|
31608
31626
|
w: 2,
|
|
@@ -31629,26 +31647,26 @@ function Dashboard(e, r) {
|
|
|
31629
31647
|
domain: J,
|
|
31630
31648
|
view_id: re.filter((he) => he[1] === "tree")[0][0],
|
|
31631
31649
|
onRowClicked: (he) => {
|
|
31632
|
-
const ve = re.find((
|
|
31633
|
-
const [, D] =
|
|
31650
|
+
const ve = re.find((Oe) => {
|
|
31651
|
+
const [, D] = Oe;
|
|
31634
31652
|
return D === "form";
|
|
31635
31653
|
});
|
|
31636
31654
|
if (ve) {
|
|
31637
|
-
const [
|
|
31655
|
+
const [Oe, D] = ve, {
|
|
31638
31656
|
actionId: M,
|
|
31639
|
-
actionType:
|
|
31657
|
+
actionType: pe,
|
|
31640
31658
|
title: ge,
|
|
31641
31659
|
model: Fe
|
|
31642
|
-
} = B,
|
|
31660
|
+
} = B, Te = {
|
|
31643
31661
|
action_id: M,
|
|
31644
|
-
action_type:
|
|
31662
|
+
action_type: pe,
|
|
31645
31663
|
name: ge,
|
|
31646
31664
|
res_id: he.id,
|
|
31647
31665
|
res_model: Fe,
|
|
31648
|
-
view_id:
|
|
31666
|
+
view_id: Oe,
|
|
31649
31667
|
view_type: D
|
|
31650
31668
|
};
|
|
31651
|
-
g(
|
|
31669
|
+
g(Te);
|
|
31652
31670
|
}
|
|
31653
31671
|
}
|
|
31654
31672
|
});
|
|
@@ -31679,17 +31697,17 @@ function Dashboard(e, r) {
|
|
|
31679
31697
|
});
|
|
31680
31698
|
if (te) {
|
|
31681
31699
|
const [he, ve] = te, {
|
|
31682
|
-
actionId:
|
|
31700
|
+
actionId: Oe,
|
|
31683
31701
|
actionType: D,
|
|
31684
31702
|
title: M,
|
|
31685
|
-
model:
|
|
31703
|
+
model: pe
|
|
31686
31704
|
} = B;
|
|
31687
31705
|
Q = {
|
|
31688
|
-
action_id:
|
|
31706
|
+
action_id: Oe,
|
|
31689
31707
|
action_type: D,
|
|
31690
31708
|
name: M,
|
|
31691
31709
|
res_id: !1,
|
|
31692
|
-
res_model:
|
|
31710
|
+
res_model: pe,
|
|
31693
31711
|
view_id: he,
|
|
31694
31712
|
view_type: ve
|
|
31695
31713
|
};
|
|
@@ -31697,7 +31715,7 @@ function Dashboard(e, r) {
|
|
|
31697
31715
|
return /* @__PURE__ */ jsx(DashboardGridItem, {
|
|
31698
31716
|
id: W,
|
|
31699
31717
|
title: U,
|
|
31700
|
-
parms:
|
|
31718
|
+
parms: ce,
|
|
31701
31719
|
action: Q,
|
|
31702
31720
|
openAction: g,
|
|
31703
31721
|
children: me
|
|
@@ -32058,16 +32076,16 @@ function RootView(e, r) {
|
|
|
32058
32076
|
ie.push([he, te]);
|
|
32059
32077
|
}
|
|
32060
32078
|
}
|
|
32061
|
-
let
|
|
32079
|
+
let ce;
|
|
32062
32080
|
if (G) {
|
|
32063
32081
|
const [me, Q] = ie.find(([te, he]) => he === G);
|
|
32064
|
-
|
|
32082
|
+
ce = {
|
|
32065
32083
|
id: me,
|
|
32066
32084
|
type: Q
|
|
32067
32085
|
};
|
|
32068
32086
|
} else {
|
|
32069
32087
|
const [me, Q] = ie[0];
|
|
32070
|
-
|
|
32088
|
+
ce = {
|
|
32071
32089
|
id: me,
|
|
32072
32090
|
type: Q
|
|
32073
32091
|
};
|
|
@@ -32082,7 +32100,7 @@ function RootView(e, r) {
|
|
|
32082
32100
|
views: ie,
|
|
32083
32101
|
title: re,
|
|
32084
32102
|
target: ae,
|
|
32085
|
-
initialView:
|
|
32103
|
+
initialView: ce,
|
|
32086
32104
|
action_type: N,
|
|
32087
32105
|
action_id: W,
|
|
32088
32106
|
values: S,
|
|
@@ -32191,10 +32209,10 @@ function RootView(e, r) {
|
|
|
32191
32209
|
view_type: U,
|
|
32192
32210
|
limit: re
|
|
32193
32211
|
} = B, ae = U === "tree", ne = [];
|
|
32194
|
-
for (const
|
|
32195
|
-
const [me, Q] =
|
|
32212
|
+
for (const ce of K) {
|
|
32213
|
+
const [me, Q] = ce;
|
|
32196
32214
|
if (me)
|
|
32197
|
-
ne.push(
|
|
32215
|
+
ne.push(ce);
|
|
32198
32216
|
else if (Q === "dashboard")
|
|
32199
32217
|
ne.push([void 0, "dashboard"]);
|
|
32200
32218
|
else {
|
|
@@ -32214,10 +32232,10 @@ function RootView(e, r) {
|
|
|
32214
32232
|
}
|
|
32215
32233
|
let J, oe;
|
|
32216
32234
|
if (E == null) {
|
|
32217
|
-
const
|
|
32218
|
-
J = void 0, oe =
|
|
32235
|
+
const ce = ne.find((me) => me[0] === void 0);
|
|
32236
|
+
J = void 0, oe = ce[1];
|
|
32219
32237
|
} else
|
|
32220
|
-
[J, oe] = ne.find((
|
|
32238
|
+
[J, oe] = ne.find((ce) => ce[0] === void 0 ? !1 : ce[0] === E);
|
|
32221
32239
|
const ie = {
|
|
32222
32240
|
id: J,
|
|
32223
32241
|
type: oe
|