bonuspluscomponents 0.0.137 → 0.0.138
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/AppContext/Context/AppContext.d.ts.map +1 -1
- package/dist/AppContext/Context/LoadingContext.d.ts +1 -1
- package/dist/AppContext/Context/LoadingContext.d.ts.map +1 -1
- package/dist/bonuspluscomponents.cjs.js +4 -4
- package/dist/bonuspluscomponents.es.js +20 -18
- package/dist/bonuspluscomponents.umd.js +4 -4
- package/package.json +1 -1
|
@@ -721,13 +721,15 @@ let Hi = td({
|
|
|
721
721
|
Hi = zm(Hi);
|
|
722
722
|
const Ps = Hi, ch = {
|
|
723
723
|
isLoading: !1,
|
|
724
|
-
setIsLoading(e) {
|
|
724
|
+
setIsLoading(e, t) {
|
|
725
725
|
}
|
|
726
726
|
}, cr = _o(ch), uh = () => {
|
|
727
|
-
const [e, t] = ke(
|
|
727
|
+
const [e, t] = ke([]), n = (r, o) => {
|
|
728
|
+
t(o ? (i) => i.filter((s) => s.id !== r) : (i) => [...i, { id: r }]);
|
|
729
|
+
};
|
|
728
730
|
return {
|
|
729
|
-
isLoading: e,
|
|
730
|
-
setIsLoading:
|
|
731
|
+
isLoading: e.length !== 0,
|
|
732
|
+
setIsLoading: n
|
|
731
733
|
};
|
|
732
734
|
}, Y$ = ({ children: e }) => {
|
|
733
735
|
const t = uh();
|
|
@@ -777,27 +779,27 @@ const Ps = Hi, ch = {
|
|
|
777
779
|
(async () => {
|
|
778
780
|
if (!l || !i || e === null)
|
|
779
781
|
return;
|
|
780
|
-
t(!0);
|
|
782
|
+
t("GetCabinetSettings", !0);
|
|
781
783
|
const R = await m().post("/externalCustomerCabinet/cabinetInfo", {});
|
|
782
|
-
P(R.data), R.data.isReg && n("registration"), t(!1);
|
|
784
|
+
P(R.data), R.data.isReg && n("registration"), t("GetCabinetSettings", !1);
|
|
783
785
|
})();
|
|
784
786
|
}, [i, l]), ot(() => {
|
|
785
787
|
(async () => {
|
|
786
788
|
if (!l || !i || e === null || !E || E != null && E.isReg)
|
|
787
789
|
return;
|
|
788
|
-
t(!0);
|
|
790
|
+
t("GetCustomerInfo", !0);
|
|
789
791
|
const R = await m().post("/externalCustomerCabinet/customer/info", {
|
|
790
792
|
VKUserId: r
|
|
791
793
|
});
|
|
792
|
-
d({ ...R.data.customer, eCardCustomerLink: R.data.eCardCustomerLink }), t(!1);
|
|
794
|
+
d({ ...R.data.customer, eCardCustomerLink: R.data.eCardCustomerLink }), t("GetCustomerInfo", !1);
|
|
793
795
|
})();
|
|
794
796
|
}, [i, E]), ot(() => {
|
|
795
797
|
(async () => {
|
|
796
798
|
if (!l)
|
|
797
799
|
return;
|
|
798
|
-
t(!0);
|
|
800
|
+
t("GetCabinetUISettings", !0);
|
|
799
801
|
const R = await m().post("/externalCustomerCabinet/settings", {});
|
|
800
|
-
C(R.data.settings), t(!1);
|
|
802
|
+
C(R.data.settings), t("GetCabinetUISettings", !1);
|
|
801
803
|
})();
|
|
802
804
|
}, [l]), {
|
|
803
805
|
cabinetType: e,
|
|
@@ -9295,12 +9297,12 @@ const ii = ({ children: e }) => /* @__PURE__ */ f.jsx("div", { className: "cloud
|
|
|
9295
9297
|
}), s = async () => {
|
|
9296
9298
|
if (!n)
|
|
9297
9299
|
throw ErrorEvent;
|
|
9298
|
-
o(!0);
|
|
9300
|
+
o("GetPurchaseHistory", !0);
|
|
9299
9301
|
const c = await i({
|
|
9300
9302
|
phone: n,
|
|
9301
9303
|
cabinetType: r
|
|
9302
9304
|
});
|
|
9303
|
-
t(c.activities), o(!1);
|
|
9305
|
+
t(c.activities), o("GetPurchaseHistory", !1);
|
|
9304
9306
|
};
|
|
9305
9307
|
return ot(() => {
|
|
9306
9308
|
s();
|
|
@@ -10229,9 +10231,9 @@ const vl = ({ validationsProp: e }) => {
|
|
|
10229
10231
|
method: "get",
|
|
10230
10232
|
initLoading: !0
|
|
10231
10233
|
}), c = async () => {
|
|
10232
|
-
n(!0);
|
|
10234
|
+
n("GetAppeals", !0);
|
|
10233
10235
|
const h = await l({ phone: e });
|
|
10234
|
-
o(h.tickets), n(!1);
|
|
10236
|
+
o(h.tickets), n("GetAppeals", !1);
|
|
10235
10237
|
};
|
|
10236
10238
|
ot(() => {
|
|
10237
10239
|
c();
|
|
@@ -11355,9 +11357,9 @@ const Kf = (e) => /* @__PURE__ */ f.jsx("div", { style: { padding: "5px", backgr
|
|
|
11355
11357
|
url: "/externalCustomerCabinet/form/info",
|
|
11356
11358
|
method: "post"
|
|
11357
11359
|
}), p = async () => {
|
|
11358
|
-
s(!0);
|
|
11360
|
+
s("GetFormInfo", !0);
|
|
11359
11361
|
const v = await d();
|
|
11360
|
-
u(v.controls), s(!1);
|
|
11362
|
+
u(v.controls), s("GetFormInfo", !1);
|
|
11361
11363
|
};
|
|
11362
11364
|
ot(() => {
|
|
11363
11365
|
n && p();
|
|
@@ -29608,12 +29610,12 @@ const M$ = ({ dates: e, readonly: t, onChange: n, title: r }) => {
|
|
|
29608
29610
|
};
|
|
29609
29611
|
ot(() => {
|
|
29610
29612
|
r || (async () => {
|
|
29611
|
-
u(!0);
|
|
29613
|
+
u("GetControls", !0);
|
|
29612
29614
|
const F = await o().post("/externalCustomerCabinet/form/registration", {});
|
|
29613
29615
|
e == null || e(F.data.controls), m(F.data.controls), E(F.data.controls.filter((W) => {
|
|
29614
29616
|
var q;
|
|
29615
29617
|
return ((q = W.validation) == null ? void 0 : q.readOnly) && !!W.text;
|
|
29616
|
-
})), u(!1);
|
|
29618
|
+
})), u("GetControls", !1);
|
|
29617
29619
|
})();
|
|
29618
29620
|
}, []);
|
|
29619
29621
|
const $ = () => {
|