@snabcentr/common-lib 2.0.7 → 2.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/dist/manifest.json +1 -1
  2. package/dist/release_notes.tmp +1 -6
  3. package/dist/sc-common-lib.js +545 -455
  4. package/dist/sc-common-lib.js.map +1 -1
  5. package/dist/sc-common-lib.umd.cjs +1 -1
  6. package/dist/sc-common-lib.umd.cjs.map +1 -1
  7. package/dist/src/clients/classes/client-short-info.d.ts +5 -0
  8. package/dist/src/clients/classes/client-short-info.d.ts.map +1 -1
  9. package/dist/src/clients/classes/client.d.ts +9 -2
  10. package/dist/src/clients/classes/client.d.ts.map +1 -1
  11. package/dist/src/clients/classes/clients-list-filters.d.ts +12 -1
  12. package/dist/src/clients/classes/clients-list-filters.d.ts.map +1 -1
  13. package/dist/src/clients/interfaces/i-client-short-info.d.ts +5 -0
  14. package/dist/src/clients/interfaces/i-client-short-info.d.ts.map +1 -1
  15. package/dist/src/clients/interfaces/i-client.d.ts +9 -2
  16. package/dist/src/clients/interfaces/i-client.d.ts.map +1 -1
  17. package/dist/src/clients/interfaces/i-clients-list-filters.d.ts +5 -0
  18. package/dist/src/clients/interfaces/i-clients-list-filters.d.ts.map +1 -1
  19. package/dist/src/clients/providers/client-data-provider.d.ts +34 -0
  20. package/dist/src/clients/providers/client-data-provider.d.ts.map +1 -1
  21. package/dist/src/config/interfaces/i-catalog-config.d.ts +7 -2
  22. package/dist/src/config/interfaces/i-catalog-config.d.ts.map +1 -1
  23. package/dist/src/managers/classes/curator.d.ts +28 -0
  24. package/dist/src/managers/classes/curator.d.ts.map +1 -0
  25. package/dist/src/managers/classes/index.d.ts +1 -0
  26. package/dist/src/managers/classes/index.d.ts.map +1 -1
  27. package/dist/src/managers/classes/manager.d.ts +5 -0
  28. package/dist/src/managers/classes/manager.d.ts.map +1 -1
  29. package/dist/src/managers/interfaces/i-curator.d.ts +21 -0
  30. package/dist/src/managers/interfaces/i-curator.d.ts.map +1 -0
  31. package/dist/src/managers/interfaces/i-manager.d.ts +5 -0
  32. package/dist/src/managers/interfaces/i-manager.d.ts.map +1 -1
  33. package/dist/src/managers/interfaces/index.d.ts +1 -0
  34. package/dist/src/managers/interfaces/index.d.ts.map +1 -1
  35. package/dist/src/references/classes/curated-direction.d.ts +8 -0
  36. package/dist/src/references/classes/curated-direction.d.ts.map +1 -0
  37. package/dist/src/references/classes/index.d.ts +1 -0
  38. package/dist/src/references/classes/index.d.ts.map +1 -1
  39. package/dist/src/references/interfaces/i-curated-direction.d.ts +7 -0
  40. package/dist/src/references/interfaces/i-curated-direction.d.ts.map +1 -0
  41. package/dist/src/references/interfaces/index.d.ts +1 -0
  42. package/dist/src/references/interfaces/index.d.ts.map +1 -1
  43. package/dist/src/references/providers/reference-data-provider.d.ts +5 -0
  44. package/dist/src/references/providers/reference-data-provider.d.ts.map +1 -1
  45. package/package.json +1 -1
@@ -1,14 +1,14 @@
1
- var Ar = Object.defineProperty;
2
- var Dr = (n, r, e) => r in n ? Ar(n, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[r] = e;
3
- var t = (n, r, e) => Dr(n, typeof r != "symbol" ? r + "" : r, e);
4
- import { jwtDecode as tr } from "jwt-decode";
5
- import { merge as Ue, isUndefined as Tr, isNil as D, isEmpty as Y, noop as f, mapValues as sr, isArray as Q, every as $r, split as br, toUpper as Sr, constant as ar, isString as y, cloneDeep as Ir, toLower as xr, isFunction as de, map as he, forEach as Lr, isDate as ke, omitBy as ir, isObject as nr } from "lodash-es";
6
- import { objectToCamel as Fe, objectToSnake as Ee } from "ts-case-convert";
7
- import { isAfter as ze, parseISO as w, startOfToday as _e, format as q, addSeconds as kr, addBusinessDays as _r, endOfTomorrow as Or, startOfTomorrow as qr, endOfYesterday as Nr, startOfYesterday as Ur, endOfToday as dr, endOfDay as Fr, startOfDay as Mr } from "date-fns";
1
+ var $r = Object.defineProperty;
2
+ var br = (n, r, e) => r in n ? $r(n, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[r] = e;
3
+ var t = (n, r, e) => br(n, typeof r != "symbol" ? r + "" : r, e);
4
+ import { jwtDecode as sr } from "jwt-decode";
5
+ import { merge as Ne, isUndefined as Sr, isNil as A, isEmpty as Y, noop as w, mapValues as ir, isArray as Q, every as ar, split as Ir, toUpper as xr, constant as Lr, isString as C, cloneDeep as kr, toLower as _r, isFunction as Ue, map as he, forEach as Or, isDate as ke, omitBy as nr, isObject as or } from "lodash-es";
6
+ import { objectToCamel as Fe, objectToSnake as ze } from "ts-case-convert";
7
+ import { isAfter as We, parseISO as v, startOfToday as _e, format as d, addSeconds as dr, addBusinessDays as qr, endOfTomorrow as Nr, startOfTomorrow as Ur, endOfYesterday as Fr, startOfYesterday as Mr, endOfToday as jr, endOfDay as Gr, startOfDay as Hr } from "date-fns";
8
8
  import { defineStore as te } from "pinia";
9
- import { ref as m, markRaw as jr, computed as P } from "vue";
10
- import Gr from "axios";
11
- class U {
9
+ import { ref as y, markRaw as Br, computed as R } from "vue";
10
+ import Er from "axios";
11
+ class N {
12
12
  /**
13
13
  * Инициализирует экземпляр класса {@link JwtPayload}.
14
14
  *
@@ -99,7 +99,7 @@ class U {
99
99
  * @inheritDoc
100
100
  */
101
101
  t(this, "email", "");
102
- Ue(this, r);
102
+ Ne(this, r);
103
103
  }
104
104
  /**
105
105
  * Возвращает данные полезной нагрузки для указанного JWT-токена.
@@ -107,11 +107,11 @@ class U {
107
107
  * @param jwtToken JWT-ключ доступа.
108
108
  */
109
109
  static getJwtPayload(r) {
110
- const e = tr(r), s = new U(Fe(e));
110
+ const e = sr(r), s = new N(Fe(e));
111
111
  return s.resourceAccess = e.resource_access, s;
112
112
  }
113
113
  }
114
- class Nt extends U {
114
+ class Ut extends N {
115
115
  /**
116
116
  * Инициализирует экземпляр класса {@link DetailedJwtPayload}.
117
117
  *
@@ -143,7 +143,7 @@ class Nt extends U {
143
143
  * @inheritDoc
144
144
  */
145
145
  t(this, "address");
146
- Ue(this, e);
146
+ Ne(this, e);
147
147
  }
148
148
  /**
149
149
  * Возвращает данные полезной нагрузки для указанного JWT-токена.
@@ -151,7 +151,7 @@ class Nt extends U {
151
151
  * @param jwtToken JWT-ключ доступа.
152
152
  */
153
153
  static getJwtPayload(e) {
154
- return new U(Fe(tr(e)));
154
+ return new N(Fe(sr(e)));
155
155
  }
156
156
  }
157
157
  const J = class J {
@@ -168,7 +168,7 @@ const J = class J {
168
168
  */
169
169
  // eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
170
170
  static getConfig() {
171
- if (Tr(J.config))
171
+ if (Sr(J.config))
172
172
  throw new Error("Config is undefined. Please set config by AppConfigProvider.init().");
173
173
  return J.config;
174
174
  }
@@ -210,8 +210,8 @@ class ye {
210
210
  if (e)
211
211
  try {
212
212
  const s = JSON.parse(e);
213
- if (!s.availableFor || ze(w(s.availableFor) || _e(), /* @__PURE__ */ new Date())) {
214
- if (D(s.data) || Y(s.data))
213
+ if (!s.availableFor || We(v(s.availableFor) || _e(), /* @__PURE__ */ new Date())) {
214
+ if (A(s.data) || Y(s.data))
215
215
  throw new Error("Data is empty");
216
216
  return s.data;
217
217
  }
@@ -233,7 +233,7 @@ class ye {
233
233
  static saveActualDataToStorage(r, e, s) {
234
234
  if (this.isLocalStorageAvailable())
235
235
  try {
236
- if (D(e) || Y(e))
236
+ if (A(e) || Y(e))
237
237
  throw new Error("Data is empty");
238
238
  const i = JSON.stringify({
239
239
  availableFor: s,
@@ -284,7 +284,7 @@ class ye {
284
284
  const i = localStorage.getItem(s);
285
285
  if (i) {
286
286
  const o = JSON.parse(i);
287
- o.availableFor && !ze(w(o.availableFor) || _e(), /* @__PURE__ */ new Date()) && r.push(s);
287
+ o.availableFor && !We(v(o.availableFor) || _e(), /* @__PURE__ */ new Date()) && r.push(s);
288
288
  }
289
289
  } catch {
290
290
  r.push(s);
@@ -300,16 +300,16 @@ class ye {
300
300
  }
301
301
  }
302
302
  }
303
- function We(n) {
303
+ function Je(n) {
304
304
  try {
305
- const r = U.getJwtPayload(n);
305
+ const r = N.getJwtPayload(n);
306
306
  return new Date(r.exp * 1e3);
307
307
  } catch {
308
308
  return;
309
309
  }
310
310
  }
311
311
  const B = te("__auth_state_private", () => {
312
- const n = m(
312
+ const n = y(
313
313
  (() => {
314
314
  var u;
315
315
  const o = ye.getActualDataFromStorage(
@@ -321,12 +321,12 @@ const B = te("__auth_state_private", () => {
321
321
  const c = (u = T.getConfig().devMode) == null ? void 0 : u.initAuthBearerToken;
322
322
  return c ? Promise.resolve(c) : void 0;
323
323
  })()
324
- ), r = m(void 0), e = m(void 0), s = jr(/* @__PURE__ */ new Map());
324
+ ), r = y(void 0), e = y(void 0), s = Br(/* @__PURE__ */ new Map());
325
325
  function i() {
326
- e.value = void 0, D(n.value) || n.value.then((o) => {
327
- const c = U.getJwtPayload(o);
328
- e.value = c.exp * 1e3 > Date.now() ? sr(c.resourceAccess, (u) => (u == null ? void 0 : u.roles) ?? []) : void 0;
329
- }).catch(f);
326
+ e.value = void 0, A(n.value) || n.value.then((o) => {
327
+ const c = N.getJwtPayload(o);
328
+ e.value = c.exp * 1e3 > Date.now() ? ir(c.resourceAccess, (u) => (u == null ? void 0 : u.roles) ?? []) : void 0;
329
+ }).catch(w);
330
330
  }
331
331
  return {
332
332
  /**
@@ -351,13 +351,13 @@ const B = te("__auth_state_private", () => {
351
351
  recalculateUserPermissions: i
352
352
  };
353
353
  }), be = te("__auth_state", () => {
354
- const n = P(() => {
354
+ const n = R(() => {
355
355
  const o = B();
356
- if (D(o.jwtToken) && !D(o.jwtTokenUpdater)) {
356
+ if (A(o.jwtToken) && !A(o.jwtTokenUpdater)) {
357
357
  const c = o.jwtTokenUpdater();
358
358
  o.jwtToken = c, c.then((u) => {
359
- o.jwtToken = Promise.resolve(u), ye.saveActualDataToStorage("sc.token", u, We(u)), o.recalculateUserPermissions();
360
- }).catch(f);
359
+ o.jwtToken = Promise.resolve(u), ye.saveActualDataToStorage("sc.token", u, Je(u)), o.recalculateUserPermissions();
360
+ }).catch(w);
361
361
  }
362
362
  return o.jwtToken;
363
363
  });
@@ -366,7 +366,7 @@ const B = te("__auth_state_private", () => {
366
366
  }
367
367
  function e(o) {
368
368
  const c = B();
369
- c.jwtToken = Promise.resolve(o), ye.saveActualDataToStorage("sc.token", o, We(o)), c.recalculateUserPermissions();
369
+ c.jwtToken = Promise.resolve(o), ye.saveActualDataToStorage("sc.token", o, Je(o)), c.recalculateUserPermissions();
370
370
  }
371
371
  function s() {
372
372
  const o = B();
@@ -374,23 +374,23 @@ const B = te("__auth_state_private", () => {
374
374
  }
375
375
  function i(o) {
376
376
  const c = B();
377
- !D(c.jwtToken) && D(c.userPermissions) && c.jwtToken.then((v) => {
378
- const R = U.getJwtPayload(v);
379
- c.userPermissions = R.exp * 1e3 > Date.now() ? sr(R.resourceAccess, (S) => (S == null ? void 0 : S.roles) ?? []) : void 0;
380
- }).catch(f);
377
+ !A(c.jwtToken) && A(c.userPermissions) && c.jwtToken.then((f) => {
378
+ const m = N.getJwtPayload(f);
379
+ c.userPermissions = m.exp * 1e3 > Date.now() ? ir(m.resourceAccess, (S) => (S == null ? void 0 : S.roles) ?? []) : void 0;
380
+ }).catch(w);
381
381
  const u = Q(o) ? o.join(" && ") : o;
382
382
  if (c.userPermissionsComputedRefs.has(u))
383
383
  return c.userPermissionsComputedRefs.get(u);
384
- const p = P(() => {
385
- const v = (R) => {
384
+ const p = R(() => {
385
+ const f = (m) => {
386
386
  var H;
387
- const S = br(R, ".");
387
+ const S = Ir(m, ".");
388
388
  if (S.length < 2)
389
389
  return !1;
390
390
  const [_, O] = S, G = (H = B().userPermissions) == null ? void 0 : H[_];
391
391
  return Q(G) && G.includes(O);
392
392
  };
393
- return Q(o) ? $r(o, (R) => v(R)) : v(o);
393
+ return Q(o) ? ar(o, (m) => f(m)) : f(o);
394
394
  });
395
395
  return c.userPermissionsComputedRefs.set(u, p), p;
396
396
  }
@@ -439,13 +439,13 @@ class j {
439
439
  * @inheritDoc
440
440
  */
441
441
  t(this, "guid");
442
- this.id = r == null ? void 0 : r.id, D(this.id) && (D(e) ? typeof (r == null ? void 0 : r.id) == "number" ? this.id = -1 : typeof (r == null ? void 0 : r.id) == "string" && (this.id = "") : this.id = e), this.guid = (r == null ? void 0 : r.guid) ?? "";
442
+ this.id = r == null ? void 0 : r.id, A(this.id) && (A(e) ? typeof (r == null ? void 0 : r.id) == "number" ? this.id = -1 : typeof (r == null ? void 0 : r.id) == "string" && (this.id = "") : this.id = e), this.guid = (r == null ? void 0 : r.guid) ?? "";
443
443
  }
444
444
  /**
445
445
  * Возвращает признак, что это новая запись.
446
446
  */
447
447
  isNewRec() {
448
- return typeof this.id == "number" ? this.id === -1 : typeof this.id == "string" ? this.id === "" : D(this.id);
448
+ return typeof this.id == "number" ? this.id === -1 : typeof this.id == "string" ? this.id === "" : A(this.id);
449
449
  }
450
450
  }
451
451
  class b extends j {
@@ -478,7 +478,7 @@ class oe extends b {
478
478
  this.code = (e == null ? void 0 : e.code) ?? "";
479
479
  }
480
480
  }
481
- class or extends oe {
481
+ class cr extends oe {
482
482
  /**
483
483
  * Инициализирует экземпляр класса {@link CatalogableItem}.
484
484
  *
@@ -497,7 +497,7 @@ class or extends oe {
497
497
  this.slug = (e == null ? void 0 : e.slug) ?? "";
498
498
  }
499
499
  }
500
- class Oe extends or {
500
+ class Oe extends cr {
501
501
  /**
502
502
  * Инициализирует экземпляр класса {@link PrimaryCatalogableItem}.
503
503
  *
@@ -536,11 +536,11 @@ class ge extends Oe {
536
536
  * Список коэффициентов пересчёта из валют в рубли в формате ключ значение.
537
537
  */
538
538
  t(this, "currencyRates");
539
- this.isHidden = (e == null ? void 0 : e.isHidden) ?? !1, this.parentCategoryId = e == null ? void 0 : e.parentCategoryId, this.properties = e == null ? void 0 : e.properties, this.type = "category", this.currencyRates = e != null && e.currencyRates ? Object.fromEntries(Object.entries(e.currencyRates).map(([s, i]) => [Sr(s), i])) : void 0;
539
+ this.isHidden = (e == null ? void 0 : e.isHidden) ?? !1, this.parentCategoryId = e == null ? void 0 : e.parentCategoryId, this.properties = e == null ? void 0 : e.properties, this.type = "category", this.currencyRates = e != null && e.currencyRates ? Object.fromEntries(Object.entries(e.currencyRates).map(([s, i]) => [xr(s), i])) : void 0;
540
540
  }
541
541
  }
542
- var cr = /* @__PURE__ */ ((n) => (n.K0 = "k0", n.K1 = "k1", n.K2 = "k2", n.K3 = "k3", n.K4 = "k4", n.Retail = "retail", n))(cr || {});
543
- class C extends b {
542
+ var lr = /* @__PURE__ */ ((n) => (n.K0 = "k0", n.K1 = "k1", n.K2 = "k2", n.K3 = "k3", n.K4 = "k4", n.Retail = "retail", n))(lr || {});
543
+ class P extends b {
544
544
  /**
545
545
  * Инициализирует экземпляр класса {@link Reference}.
546
546
  *
@@ -559,12 +559,12 @@ class C extends b {
559
559
  this.description = e == null ? void 0 : e.description, this.slug = e == null ? void 0 : e.slug;
560
560
  }
561
561
  }
562
- class Re extends C {
562
+ class Re extends P {
563
563
  /**
564
564
  * Возвращает значение справочника коэффициента розничной цены.
565
565
  */
566
566
  static getRetailPriceCoefficient() {
567
- return { id: -2, slug: cr.Retail, name: "Розн. цена", guid: "", isNewRec: ar(!0) };
567
+ return { id: -2, slug: lr.Retail, name: "Розн. цена", guid: "", isNewRec: Lr(!0) };
568
568
  }
569
569
  }
570
570
  class Me {
@@ -597,7 +597,7 @@ class Me {
597
597
  this.coefficient = new Re(r == null ? void 0 : r.coefficient), this.value = (r == null ? void 0 : r.value) ?? 0, this.cost = (r == null ? void 0 : r.cost) ?? 0, this.percent = (r == null ? void 0 : r.percent) ?? 0, this.readOnly = (r == null ? void 0 : r.readOnly) ?? !0;
598
598
  }
599
599
  }
600
- class lr {
600
+ class ur {
601
601
  /**
602
602
  * Инициализирует экземпляр класса {@link GeoCoordinates}.
603
603
  *
@@ -615,9 +615,9 @@ class lr {
615
615
  this.lat = (r == null ? void 0 : r.lat) ?? 0, this.long = (r == null ? void 0 : r.long) ?? 0;
616
616
  }
617
617
  }
618
- class X extends C {
618
+ class X extends P {
619
619
  }
620
- class Ae extends C {
620
+ class De extends P {
621
621
  /**
622
622
  * Инициализирует экземпляр класса {@link Warehouse}.
623
623
  *
@@ -646,10 +646,10 @@ class Ae extends C {
646
646
  * Координаты склада.
647
647
  */
648
648
  t(this, "coordinates");
649
- this.address = (e == null ? void 0 : e.address) ?? "", this.isMain = (e == null ? void 0 : e.isMain) ?? !1, this.deliveryTypes = ((s = e == null ? void 0 : e.deliveryTypes) == null ? void 0 : s.map((i) => new X(i))) ?? [], this.regions = (e == null ? void 0 : e.regions) ?? [], this.coordinates = new lr(e == null ? void 0 : e.coordinates);
649
+ this.address = (e == null ? void 0 : e.address) ?? "", this.isMain = (e == null ? void 0 : e.isMain) ?? !1, this.deliveryTypes = ((s = e == null ? void 0 : e.deliveryTypes) == null ? void 0 : s.map((i) => new X(i))) ?? [], this.regions = (e == null ? void 0 : e.regions) ?? [], this.coordinates = new ur(e == null ? void 0 : e.coordinates);
650
650
  }
651
651
  }
652
- class Hr {
652
+ class zr {
653
653
  /**
654
654
  * Инициализирует экземпляр класса {@link StockCount}.
655
655
  *
@@ -664,10 +664,10 @@ class Hr {
664
664
  * Количество остатков товара на складе.
665
665
  */
666
666
  t(this, "count");
667
- this.warehouse = new Ae(r == null ? void 0 : r.warehouse), this.count = (r == null ? void 0 : r.count) ?? 0;
667
+ this.warehouse = new De(r == null ? void 0 : r.warehouse), this.count = (r == null ? void 0 : r.count) ?? 0;
668
668
  }
669
669
  }
670
- class Br extends or {
670
+ class Wr extends cr {
671
671
  /**
672
672
  * Инициализирует экземпляр класса {@link HiddenCatalogableItem}.
673
673
  *
@@ -682,7 +682,7 @@ class Br extends or {
682
682
  this.isHidden = (e == null ? void 0 : e.isHidden) ?? !1;
683
683
  }
684
684
  }
685
- class Er {
685
+ class Jr {
686
686
  /**
687
687
  * Инициализирует экземпляр класса {@link Image}.
688
688
  *
@@ -705,7 +705,7 @@ class Er {
705
705
  this.image = `${e ?? ""}${r.image}`, this.preview = `${e ?? ""}${r.preview}`, this.isDefault = r.isDefault;
706
706
  }
707
707
  }
708
- class I extends Br {
708
+ class I extends Wr {
709
709
  /**
710
710
  * Инициализирует экземпляр класса {@link Product}.
711
711
  *
@@ -790,9 +790,9 @@ class I extends Br {
790
790
  * Список коэффициентов цен на продукт.
791
791
  */
792
792
  t(this, "priceCoefficients");
793
- this.supplierSku = e == null ? void 0 : e.supplierSku, this.unit = (e == null ? void 0 : e.unit) ?? "", this.pack = e == null ? void 0 : e.pack, this.minCount = e == null ? void 0 : e.minCount, this.quantityUnit = e == null ? void 0 : e.quantityUnit, this.currency = (e == null ? void 0 : e.currency) ?? "", this.cost = (e == null ? void 0 : e.cost) ?? 0, this.costRub = (e == null ? void 0 : e.costRub) ?? 0, this.costDate = y(e == null ? void 0 : e.costDate) ? w(e.costDate) : e == null ? void 0 : e.costDate, this.onOrder = (e == null ? void 0 : e.onOrder) ?? !1, this.stockCount = ((i = e == null ? void 0 : e.stockCount) == null ? void 0 : i.map((p) => new Hr(p))) ?? [], this.currencySignature = (e == null ? void 0 : e.currencySignature) ?? "", this.type = "product";
793
+ this.supplierSku = e == null ? void 0 : e.supplierSku, this.unit = (e == null ? void 0 : e.unit) ?? "", this.pack = e == null ? void 0 : e.pack, this.minCount = e == null ? void 0 : e.minCount, this.quantityUnit = e == null ? void 0 : e.quantityUnit, this.currency = (e == null ? void 0 : e.currency) ?? "", this.cost = (e == null ? void 0 : e.cost) ?? 0, this.costRub = (e == null ? void 0 : e.costRub) ?? 0, this.costDate = C(e == null ? void 0 : e.costDate) ? v(e.costDate) : e == null ? void 0 : e.costDate, this.onOrder = (e == null ? void 0 : e.onOrder) ?? !1, this.stockCount = ((i = e == null ? void 0 : e.stockCount) == null ? void 0 : i.map((p) => new zr(p))) ?? [], this.currencySignature = (e == null ? void 0 : e.currencySignature) ?? "", this.type = "product";
794
794
  const s = (e == null ? void 0 : e.category) ?? ((o = e == null ? void 0 : e.categories) == null ? void 0 : o.find((p) => p.isPrimary));
795
- s && (this.category = new Oe({ ...s, isPrimary: !0 }), this.categories = [this.category]), e != null && e.categories && (this.categories = e.categories.map((p) => new Oe(p))), this.images = ((c = e == null ? void 0 : e.images) == null ? void 0 : c.map((p) => new Er(p, T.getConfig().http.mediaUrl))) ?? [], this.properties = (e == null ? void 0 : e.properties) ?? {}, this.retailCost = e == null ? void 0 : e.retailCost, this.retailCostRub = e == null ? void 0 : e.retailCostRub, this.priceCoefficients = ((u = e == null ? void 0 : e.priceCoefficients) == null ? void 0 : u.map((p) => new Me(p))) ?? [], e && "codeNumber" in e && !e.code && (this.code = e == null ? void 0 : e.codeNumber);
795
+ s && (this.category = new Oe({ ...s, isPrimary: !0 }), this.categories = [this.category]), e != null && e.categories && (this.categories = e.categories.map((p) => new Oe(p))), this.images = ((c = e == null ? void 0 : e.images) == null ? void 0 : c.map((p) => new Jr(p, T.getConfig().http.mediaUrl))) ?? [], this.properties = (e == null ? void 0 : e.properties) ?? {}, this.retailCost = e == null ? void 0 : e.retailCost, this.retailCostRub = e == null ? void 0 : e.retailCostRub, this.priceCoefficients = ((u = e == null ? void 0 : e.priceCoefficients) == null ? void 0 : u.map((p) => new Me(p))) ?? [], e && "codeNumber" in e && !e.code && (this.code = e == null ? void 0 : e.codeNumber);
796
796
  }
797
797
  /**
798
798
  * Возвращает признак, что это измеряемый товар.
@@ -815,7 +815,7 @@ class I extends Br {
815
815
  return this.retailCostRub ?? this.costRub;
816
816
  }
817
817
  }
818
- class zr extends j {
818
+ class Vr extends j {
819
819
  /**
820
820
  * Инициализирует экземпляр класса {@link CartItemBase}.
821
821
  *
@@ -867,10 +867,10 @@ class zr extends j {
867
867
  * Признак того, что позиция является дополнительной продажей.
868
868
  */
869
869
  t(this, "isAdditionalSale");
870
- this.product = new I(e == null ? void 0 : e.product), this.quantity = e.quantity ?? 0, this.marker = e.marker, this.category = e.category ?? new ge(), this.height = e.height, this.length = e.length, this.width = e.width, this.configurator = e.configurator, this.configuratorParams = e.configuratorParams && Ir(e.configuratorParams), this.isAdditionalSale = e.isAdditionalSale;
870
+ this.product = new I(e == null ? void 0 : e.product), this.quantity = e.quantity ?? 0, this.marker = e.marker, this.category = e.category ?? new ge(), this.height = e.height, this.length = e.length, this.width = e.width, this.configurator = e.configurator, this.configuratorParams = e.configuratorParams && kr(e.configuratorParams), this.isAdditionalSale = e.isAdditionalSale;
871
871
  }
872
872
  }
873
- class Wr extends zr {
873
+ class Kr extends Vr {
874
874
  /**
875
875
  * Инициализирует экземпляр класса {@link CartItem}.
876
876
  *
@@ -939,7 +939,7 @@ class fe {
939
939
  * Список итоговых сумм по направлениям продаж.
940
940
  */
941
941
  t(this, "directionsSum");
942
- this.items = r.items.map((e) => new Wr(e)), this.resultSum = r.resultSum, this.directionsSum = r.directionsSum;
942
+ this.items = r.items.map((e) => new Kr(e)), this.resultSum = r.resultSum, this.directionsSum = r.directionsSum;
943
943
  }
944
944
  }
945
945
  class je {
@@ -981,7 +981,7 @@ const a = class a {
981
981
  * @param validationFieldResultData Список полей, для которых необходимо установить данные об ошибках валидации в случае ошибок в запросах.
982
982
  * @param disableNotifications Признак необходимости отключить уведомления об ошибках.
983
983
  */
984
- t(this, "errorResponseHandler", f);
984
+ t(this, "errorResponseHandler", w);
985
985
  /**
986
986
  * Список идентификаторов обработчиков запросов для возможности отключить те или иные обработчики.
987
987
  */
@@ -1000,7 +1000,7 @@ const a = class a {
1000
1000
  // eslint-disable-next-line class-methods-use-this
1001
1001
  t(this, "authRequestInterceptor", async (r) => {
1002
1002
  let e;
1003
- return D(be().jwtToken) || (e = await be().jwtToken), e && r.headers.set("Authorization", `Bearer ${e}`), r;
1003
+ return A(be().jwtToken) || (e = await be().jwtToken), e && r.headers.set("Authorization", `Bearer ${e}`), r;
1004
1004
  });
1005
1005
  /**
1006
1006
  * Перехватчик запроса для преобразования данных запроса.
@@ -1008,7 +1008,7 @@ const a = class a {
1008
1008
  * @param request Данные запроса.
1009
1009
  */
1010
1010
  // eslint-disable-next-line class-methods-use-this
1011
- t(this, "dataConverterRequestInterceptor", (r) => (r.method && (r.method === "get" && r.params && (r.params = Ee(r.params)), ["put", "patch", "post"].includes(xr(r.method)) && r.data && (r.data = Ee(r.data))), r));
1011
+ t(this, "dataConverterRequestInterceptor", (r) => (r.method && (r.method === "get" && r.params && (r.params = ze(r.params)), ["put", "patch", "post"].includes(_r(r.method)) && r.data && (r.data = ze(r.data))), r));
1012
1012
  /**
1013
1013
  * Перехватчик ошибок ответов на запрос.
1014
1014
  *
@@ -1027,9 +1027,9 @@ const a = class a {
1027
1027
  // eslint-disable-next-line class-methods-use-this
1028
1028
  t(this, "dataConverterResponseInterceptor", (r) => (r.data && (r.data = Fe(r.data)), r));
1029
1029
  const r = T.getConfig().version;
1030
- this.errorResponseHandler = a.defaultErrorsResponseHandler, this.httpClient = Gr.create({
1030
+ this.errorResponseHandler = a.defaultErrorsResponseHandler, this.httpClient = Er.create({
1031
1031
  headers: {
1032
- "APP-VERSION": `${r.name} (${r.version}, ${q(r.date, T.getConfig().dateFormats.uiDate)})`,
1032
+ "APP-VERSION": `${r.name} (${r.version}, ${d(r.date, T.getConfig().dateFormats.uiDate)})`,
1033
1033
  Accept: "application/json",
1034
1034
  "Content-Type": "application/json"
1035
1035
  }
@@ -1067,7 +1067,7 @@ const a = class a {
1067
1067
  */
1068
1068
  static convertHttpErrorResponse(r) {
1069
1069
  var e, s;
1070
- if (!D(r.request) || !D(r.response)) {
1070
+ if (!A(r.request) || !A(r.response)) {
1071
1071
  const i = r == null ? void 0 : r.response;
1072
1072
  return Promise.reject({
1073
1073
  status: (i == null ? void 0 : i.status) ?? 0,
@@ -1163,9 +1163,9 @@ t(a, "instances", {}), /**
1163
1163
  * @param validationFieldResultData Список полей, для которых необходимо установить данные об ошибках валидации в случае ошибок в запросах.
1164
1164
  * @param disableNotifications Признак необходимости отключить уведомления об ошибках.
1165
1165
  */
1166
- t(a, "defaultErrorsResponseHandler", f);
1166
+ t(a, "defaultErrorsResponseHandler", w);
1167
1167
  let h = a;
1168
- class Ut extends h {
1168
+ class Ft extends h {
1169
1169
  /**
1170
1170
  * Возвращает содержимое корзины указанного клиента.
1171
1171
  *
@@ -1279,7 +1279,7 @@ class Ut extends h {
1279
1279
  return this.get(`internal/clients/${r.id}/cart/add-products-from-csv/example`, {}, (e) => new Blob([e.data], { type: "text/csv" }));
1280
1280
  }
1281
1281
  }
1282
- var Jr = /* @__PURE__ */ ((n) => (n.m2Cost = "m2Cost", n.percent = "percent", n.value = "value", n))(Jr || {}), Ge = /* @__PURE__ */ ((n) => (n.Discount = "discount", n.PriceTemplate = "price_template", n.ClientPrice = "client_price", n.Product = "product", n))(Ge || {}), Vr = /* @__PURE__ */ ((n) => (n.Unknown = "unknown", n.Bool = "bool", n.Integer = "integer", n.Float = "float", n.String = "string", n.Range = "range", n.Json = "json", n.Object = "object", n))(Vr || {});
1282
+ var Qr = /* @__PURE__ */ ((n) => (n.m2Cost = "m2Cost", n.percent = "percent", n.value = "value", n))(Qr || {}), Ge = /* @__PURE__ */ ((n) => (n.Discount = "discount", n.PriceTemplate = "price_template", n.ClientPrice = "client_price", n.Product = "product", n))(Ge || {}), Yr = /* @__PURE__ */ ((n) => (n.Unknown = "unknown", n.Bool = "bool", n.Integer = "integer", n.Float = "float", n.String = "string", n.Range = "range", n.Json = "json", n.Object = "object", n))(Yr || {});
1283
1283
  class z extends ge {
1284
1284
  /**
1285
1285
  * Инициализирует экземпляр класса {@link Category}.
@@ -1300,7 +1300,7 @@ class z extends ge {
1300
1300
  this.categories = (s = e == null ? void 0 : e.categories) == null ? void 0 : s.map((o) => new z(o)), this.products = (i = e == null ? void 0 : e.products) == null ? void 0 : i.map((o) => new I(o));
1301
1301
  }
1302
1302
  }
1303
- class ur extends b {
1303
+ class pr extends b {
1304
1304
  /**
1305
1305
  * Инициализирует экземпляр класса {@link UpdatableNamedIdentity}.
1306
1306
  *
@@ -1312,10 +1312,10 @@ class ur extends b {
1312
1312
  * Дата и время последнего изменения.
1313
1313
  */
1314
1314
  t(this, "updatedAt");
1315
- this.updatedAt = y(e == null ? void 0 : e.updatedAt) ? w(e.updatedAt) : e == null ? void 0 : e.updatedAt;
1315
+ this.updatedAt = C(e == null ? void 0 : e.updatedAt) ? v(e.updatedAt) : e == null ? void 0 : e.updatedAt;
1316
1316
  }
1317
1317
  }
1318
- class Kr extends ur {
1318
+ class Xr extends pr {
1319
1319
  /**
1320
1320
  * Инициализирует экземпляр класса {@link UpdatableNamedIdentity}.
1321
1321
  *
@@ -1327,10 +1327,10 @@ class Kr extends ur {
1327
1327
  * Дата и время последнего удаления.
1328
1328
  */
1329
1329
  t(this, "deletedAt");
1330
- this.deletedAt = y(e == null ? void 0 : e.deletedAt) ? w(e.deletedAt) : e == null ? void 0 : e.deletedAt;
1330
+ this.deletedAt = C(e == null ? void 0 : e.deletedAt) ? v(e.deletedAt) : e == null ? void 0 : e.deletedAt;
1331
1331
  }
1332
1332
  }
1333
- class d extends b {
1333
+ class U extends b {
1334
1334
  /**
1335
1335
  * Инициализирует экземпляр класса {@link UserShortInfo}.
1336
1336
  *
@@ -1345,7 +1345,7 @@ class d extends b {
1345
1345
  this.type = e == null ? void 0 : e.type;
1346
1346
  }
1347
1347
  }
1348
- class Qr extends b {
1348
+ class Zr extends b {
1349
1349
  /**
1350
1350
  * Инициализирует экземпляр класса {@link DiscountShortInfo}.
1351
1351
  *
@@ -1381,10 +1381,10 @@ class Qr extends b {
1381
1381
  * Дата и время удаления.
1382
1382
  */
1383
1383
  t(this, "deletedAt");
1384
- this.costCoefficient = (e == null ? void 0 : e.costCoefficient) ?? 0, this.isLowPriceAllowed = (e == null ? void 0 : e.isLowPriceAllowed) ?? !1, this.publishedAt = y(e == null ? void 0 : e.publishedAt) ? w(e.publishedAt) : e == null ? void 0 : e.publishedAt, this.description = (e == null ? void 0 : e.description) ?? void 0, this.percent = (e == null ? void 0 : e.percent) ?? 0, this.owner = new d(e == null ? void 0 : e.owner), this.deletedAt = y(e == null ? void 0 : e.deletedAt) ? w(e.deletedAt) : e == null ? void 0 : e.deletedAt;
1384
+ this.costCoefficient = (e == null ? void 0 : e.costCoefficient) ?? 0, this.isLowPriceAllowed = (e == null ? void 0 : e.isLowPriceAllowed) ?? !1, this.publishedAt = C(e == null ? void 0 : e.publishedAt) ? v(e.publishedAt) : e == null ? void 0 : e.publishedAt, this.description = (e == null ? void 0 : e.description) ?? void 0, this.percent = (e == null ? void 0 : e.percent) ?? 0, this.owner = new U(e == null ? void 0 : e.owner), this.deletedAt = C(e == null ? void 0 : e.deletedAt) ? v(e.deletedAt) : e == null ? void 0 : e.deletedAt;
1385
1385
  }
1386
1386
  }
1387
- class W extends ur {
1387
+ class W extends pr {
1388
1388
  /**
1389
1389
  * Инициализирует экземпляр класса {@link PriceTemplate}.
1390
1390
  *
@@ -1400,7 +1400,7 @@ class W extends ur {
1400
1400
  * Дата и время создания шаблона.
1401
1401
  */
1402
1402
  t(this, "createdAt");
1403
- this.description = (e == null ? void 0 : e.description) ?? "", this.createdAt = y(e == null ? void 0 : e.createdAt) ? w(e.createdAt) : (e == null ? void 0 : e.createdAt) ?? /* @__PURE__ */ new Date();
1403
+ this.description = (e == null ? void 0 : e.description) ?? "", this.createdAt = C(e == null ? void 0 : e.createdAt) ? v(e.createdAt) : (e == null ? void 0 : e.createdAt) ?? /* @__PURE__ */ new Date();
1404
1404
  }
1405
1405
  }
1406
1406
  class Z extends I {
@@ -1439,10 +1439,10 @@ class Z extends I {
1439
1439
  * Признак того, что указанный продукт входит в список избранных продуктов клиента.
1440
1440
  */
1441
1441
  t(this, "isFavorite");
1442
- this.costCoefficient = (e == null ? void 0 : e.costCoefficient) ?? 0, this.costSource = (e == null ? void 0 : e.costSource) ?? Ge.Product, this.discount = e != null && e.discount ? new Qr(e.discount) : void 0, this.priceTemplate = e != null && e.priceTemplate ? new W(e.priceTemplate) : void 0, this.isPreviouslyOrdered = e == null ? void 0 : e.isPreviouslyOrdered, this.isRequired = e == null ? void 0 : e.isRequired, this.isFavorite = e == null ? void 0 : e.isFavorite;
1442
+ this.costCoefficient = (e == null ? void 0 : e.costCoefficient) ?? 0, this.costSource = (e == null ? void 0 : e.costSource) ?? Ge.Product, this.discount = e != null && e.discount ? new Zr(e.discount) : void 0, this.priceTemplate = e != null && e.priceTemplate ? new W(e.priceTemplate) : void 0, this.isPreviouslyOrdered = e == null ? void 0 : e.isPreviouslyOrdered, this.isRequired = e == null ? void 0 : e.isRequired, this.isFavorite = e == null ? void 0 : e.isFavorite;
1443
1443
  }
1444
1444
  }
1445
- class Yr {
1445
+ class hr {
1446
1446
  /**
1447
1447
  * Инициализирует экземпляр класса {@link ContactLinks}.
1448
1448
  *
@@ -1460,7 +1460,7 @@ class Yr {
1460
1460
  this.phone = /^\d+$/.test(r.phone ?? "") ? `+${r.phone}` : r.phone, this.email = r.email;
1461
1461
  }
1462
1462
  }
1463
- class x extends C {
1463
+ class x extends P {
1464
1464
  }
1465
1465
  class ce extends b {
1466
1466
  /**
@@ -1490,10 +1490,12 @@ class ce extends b {
1490
1490
  * @inheritDoc
1491
1491
  */
1492
1492
  t(this, "isRegionalDirector");
1493
- this.salesDirection = e != null && e.salesDirection ? new x(e.salesDirection) : new x(), this.photo = e == null ? void 0 : e.photo, this.contacts = e != null && e.contacts ? new Yr(e.contacts) : void 0, this.isDefault = (e == null ? void 0 : e.isDefault) ?? !1, this.isRegionalDirector = (e == null ? void 0 : e.isRegionalDirector) ?? !1;
1493
+ this.salesDirection = e != null && e.salesDirection ? new x(e.salesDirection) : new x(), this.photo = e == null ? void 0 : e.photo, this.contacts = e != null && e.contacts ? new hr(e.contacts) : void 0, this.isDefault = (e == null ? void 0 : e.isDefault) ?? !1, this.isRegionalDirector = (e == null ? void 0 : e.isRegionalDirector) ?? !1;
1494
1494
  }
1495
1495
  }
1496
- class Xr extends b {
1496
+ class He extends P {
1497
+ }
1498
+ class et extends b {
1497
1499
  /**
1498
1500
  * Инициализирует экземпляр класса {@link IUserPricingRole}.
1499
1501
  *
@@ -1516,13 +1518,14 @@ class Xr extends b {
1516
1518
  this.description = e.description, this.canChangeLowCost = e.canChangeLowCost, this.parentRoleId = e.parentRoleId;
1517
1519
  }
1518
1520
  }
1519
- class De extends ce {
1521
+ class Ae extends ce {
1520
1522
  /**
1521
1523
  * Инициализирует экземпляр класса {@link Manager}.
1522
1524
  *
1523
1525
  * @param data Данные для первоначальной инициализации.
1524
1526
  */
1525
1527
  constructor(e) {
1528
+ var s;
1526
1529
  super(e);
1527
1530
  /**
1528
1531
  * Признак активности учетной записи менеджера.
@@ -1548,10 +1551,14 @@ class De extends ce {
1548
1551
  * Данные роли ценообразования менеджера.
1549
1552
  */
1550
1553
  t(this, "pricingRole");
1551
- this.isActive = (e == null ? void 0 : e.isActive) ?? !1, this.isSupervisor = (e == null ? void 0 : e.isSupervisor) ?? !1, this.canDoReclamations = (e == null ? void 0 : e.canDoReclamations) ?? !1, this.createdAt = e == null ? void 0 : e.createdAt, this.supervisorId = e == null ? void 0 : e.supervisorId, this.pricingRole = e != null && e.pricingRole ? new Xr(e.pricingRole) : void 0;
1554
+ /**
1555
+ * Список направлений кураторства.
1556
+ */
1557
+ t(this, "curatedDirections");
1558
+ this.isActive = (e == null ? void 0 : e.isActive) ?? !1, this.isSupervisor = (e == null ? void 0 : e.isSupervisor) ?? !1, this.canDoReclamations = (e == null ? void 0 : e.canDoReclamations) ?? !1, this.createdAt = e == null ? void 0 : e.createdAt, this.supervisorId = e == null ? void 0 : e.supervisorId, this.pricingRole = e != null && e.pricingRole ? new et(e.pricingRole) : void 0, this.curatedDirections = ((s = e == null ? void 0 : e.curatedDirections) == null ? void 0 : s.map((i) => new He(i))) ?? [];
1552
1559
  }
1553
1560
  }
1554
- class Zr extends ge {
1561
+ class rt extends ge {
1555
1562
  /**
1556
1563
  * Инициализирует экземпляр класса {@link BaseClientCategory}.
1557
1564
  *
@@ -1579,10 +1586,10 @@ class Zr extends ge {
1579
1586
  * Данные о менеджере за которым закреплена категория.
1580
1587
  */
1581
1588
  t(this, "manager");
1582
- this.isDisabled = (e == null ? void 0 : e.isDisabled) ?? !1, this.isRequired = (e == null ? void 0 : e.isRequired) ?? !1, this.isFavorite = (e == null ? void 0 : e.isFavorite) ?? !1, this.hidingComment = e == null ? void 0 : e.hidingComment, this.manager = e != null && e.manager ? new De(e.manager) : void 0;
1589
+ this.isDisabled = (e == null ? void 0 : e.isDisabled) ?? !1, this.isRequired = (e == null ? void 0 : e.isRequired) ?? !1, this.isFavorite = (e == null ? void 0 : e.isFavorite) ?? !1, this.hidingComment = e == null ? void 0 : e.hidingComment, this.manager = e != null && e.manager ? new Ae(e.manager) : void 0;
1583
1590
  }
1584
1591
  }
1585
- class we extends Zr {
1592
+ class we extends rt {
1586
1593
  /**
1587
1594
  * Инициализирует экземпляр класса {@link ClientCategory}.
1588
1595
  *
@@ -1602,7 +1609,7 @@ class we extends Zr {
1602
1609
  this.categories = (s = e == null ? void 0 : e.categories) == null ? void 0 : s.map((o) => new we(o)), this.products = (i = e == null ? void 0 : e.products) == null ? void 0 : i.map((o) => new Z(o));
1603
1610
  }
1604
1611
  }
1605
- class pr {
1612
+ class gr {
1606
1613
  /**
1607
1614
  * Инициализирует экземпляр класса {@link PriceTemplateICatalogableItem}.
1608
1615
  *
@@ -1620,7 +1627,7 @@ class pr {
1620
1627
  this.priceCoefficient = (r == null ? void 0 : r.priceCoefficient) && new Re(r.priceCoefficient), this.increasePercent = r == null ? void 0 : r.increasePercent;
1621
1628
  }
1622
1629
  }
1623
- class Se extends pr {
1630
+ class Se extends gr {
1624
1631
  /**
1625
1632
  * Инициализирует экземпляр класса {@link PriceTemplateProduct}.
1626
1633
  *
@@ -1635,9 +1642,32 @@ class Se extends pr {
1635
1642
  this.productCategory = new ge(e == null ? void 0 : e.productCategory);
1636
1643
  }
1637
1644
  }
1638
- class ee extends C {
1645
+ class mr extends b {
1646
+ /**
1647
+ * Инициализирует экземпляр класса {@link Curator}.
1648
+ *
1649
+ * @param data Данные для первоначальной инициализации.
1650
+ */
1651
+ constructor(e) {
1652
+ super(e);
1653
+ /**
1654
+ * @inheritDoc
1655
+ */
1656
+ t(this, "photo");
1657
+ /**
1658
+ * @inheritDoc
1659
+ */
1660
+ t(this, "contacts");
1661
+ /**
1662
+ * @inheritDoc
1663
+ */
1664
+ t(this, "curatedDirection");
1665
+ this.photo = e.photo, this.contacts = new hr(e.contacts), this.curatedDirection = new He(e.curatedDirection);
1666
+ }
1639
1667
  }
1640
- class le extends C {
1668
+ class ee extends P {
1669
+ }
1670
+ class le extends P {
1641
1671
  /**
1642
1672
  * Инициализирует экземпляр класса {@link Region}.
1643
1673
  *
@@ -1652,7 +1682,7 @@ class le extends C {
1652
1682
  e && (this.country = new ee(e.country));
1653
1683
  }
1654
1684
  }
1655
- class He extends C {
1685
+ class Be extends P {
1656
1686
  /**
1657
1687
  * Инициализирует экземпляр класса {@link CityWithRegionAndCountry}.
1658
1688
  *
@@ -1667,7 +1697,7 @@ class He extends C {
1667
1697
  e && (this.region = new le(e.region));
1668
1698
  }
1669
1699
  }
1670
- class hr extends b {
1700
+ class fr extends b {
1671
1701
  /**
1672
1702
  * Инициализирует экземпляр класса {@link UserCommonInfo}.
1673
1703
  *
@@ -1703,10 +1733,10 @@ class hr extends b {
1703
1733
  * Признак активности учетной записи пользователя.
1704
1734
  */
1705
1735
  t(this, "isActive");
1706
- this.phone = /^\d+$/.test((e == null ? void 0 : e.phone) ?? "") ? `+${e == null ? void 0 : e.phone}` : (e == null ? void 0 : e.phone) ?? "", this.email = (e == null ? void 0 : e.email) ?? "", this.getNews = (e == null ? void 0 : e.getNews) ?? !1, this.salesDirection = e != null && e.salesDirection ? new x(e.salesDirection) : void 0, this.createdAt = y(e == null ? void 0 : e.createdAt) ? w(e.createdAt) : e == null ? void 0 : e.createdAt, this.lastLoginAt = y(e == null ? void 0 : e.lastLoginAt) ? w(e.lastLoginAt) : e == null ? void 0 : e.lastLoginAt, this.isActive = (e == null ? void 0 : e.isActive) ?? !1;
1736
+ this.phone = /^\d+$/.test((e == null ? void 0 : e.phone) ?? "") ? `+${e == null ? void 0 : e.phone}` : (e == null ? void 0 : e.phone) ?? "", this.email = (e == null ? void 0 : e.email) ?? "", this.getNews = (e == null ? void 0 : e.getNews) ?? !1, this.salesDirection = e != null && e.salesDirection ? new x(e.salesDirection) : void 0, this.createdAt = C(e == null ? void 0 : e.createdAt) ? v(e.createdAt) : e == null ? void 0 : e.createdAt, this.lastLoginAt = C(e == null ? void 0 : e.lastLoginAt) ? v(e.lastLoginAt) : e == null ? void 0 : e.lastLoginAt, this.isActive = (e == null ? void 0 : e.isActive) ?? !1;
1707
1737
  }
1708
1738
  }
1709
- class me extends hr {
1739
+ class me extends fr {
1710
1740
  /**
1711
1741
  * Инициализирует экземпляр класса {@link Client}.
1712
1742
  *
@@ -1714,7 +1744,7 @@ class me extends hr {
1714
1744
  */
1715
1745
  // eslint-disable-next-line sonarjs/cognitive-complexity
1716
1746
  constructor(e) {
1717
- var s;
1747
+ var s, i;
1718
1748
  super(e);
1719
1749
  /**
1720
1750
  * Направление продаж.
@@ -1748,7 +1778,11 @@ class me extends hr {
1748
1778
  * Список менеджеров клиента.
1749
1779
  */
1750
1780
  t(this, "managers");
1751
- this.salesDirection = new x(e == null ? void 0 : e.salesDirection), this.debt = (e == null ? void 0 : e.debt) ?? 0, this.alternativeName = (e == null ? void 0 : e.alternativeName) ?? "", this.city = new He(e == null ? void 0 : e.city), this.comment = e == null ? void 0 : e.comment, this.isPhoneApproved = (e == null ? void 0 : e.isPhoneApproved) ?? !1, this.isEmailApproved = (e == null ? void 0 : e.isEmailApproved) ?? !1, this.managers = ((s = e == null ? void 0 : e.managers) == null ? void 0 : s.map((i) => new ce(i))) ?? [];
1781
+ /**
1782
+ * @inheritDoc
1783
+ */
1784
+ t(this, "curators");
1785
+ this.salesDirection = new x(e == null ? void 0 : e.salesDirection), this.debt = (e == null ? void 0 : e.debt) ?? 0, this.alternativeName = (e == null ? void 0 : e.alternativeName) ?? "", this.city = new Be(e == null ? void 0 : e.city), this.comment = e == null ? void 0 : e.comment, this.isPhoneApproved = (e == null ? void 0 : e.isPhoneApproved) ?? !1, this.isEmailApproved = (e == null ? void 0 : e.isEmailApproved) ?? !1, this.managers = ((s = e == null ? void 0 : e.managers) == null ? void 0 : s.map((o) => new ce(o))) ?? [], this.curators = ((i = e == null ? void 0 : e.curators) == null ? void 0 : i.map((o) => new mr(o))) ?? [];
1752
1786
  }
1753
1787
  }
1754
1788
  class se extends j {
@@ -1775,10 +1809,10 @@ class se extends j {
1775
1809
  * Данные шаблона прайс-листа.
1776
1810
  */
1777
1811
  t(this, "priceTemplate");
1778
- this.createdAt = y(e == null ? void 0 : e.createdAt) ? w(e.createdAt) : (e == null ? void 0 : e.createdAt) ?? /* @__PURE__ */ new Date(), this.deletedAt = y(e == null ? void 0 : e.deletedAt) ? w(e.deletedAt) : e == null ? void 0 : e.deletedAt, this.client = new me(e == null ? void 0 : e.client), this.priceTemplate = new W(e == null ? void 0 : e.priceTemplate);
1812
+ this.createdAt = C(e == null ? void 0 : e.createdAt) ? v(e.createdAt) : (e == null ? void 0 : e.createdAt) ?? /* @__PURE__ */ new Date(), this.deletedAt = C(e == null ? void 0 : e.deletedAt) ? v(e.deletedAt) : e == null ? void 0 : e.deletedAt, this.client = new me(e == null ? void 0 : e.client), this.priceTemplate = new W(e == null ? void 0 : e.priceTemplate);
1779
1813
  }
1780
1814
  }
1781
- class ae extends pr {
1815
+ class ae extends gr {
1782
1816
  /**
1783
1817
  * Инициализирует экземпляр класса {@link PriceTemplateProduct}.
1784
1818
  *
@@ -1793,7 +1827,7 @@ class ae extends pr {
1793
1827
  this.product = new I(e == null ? void 0 : e.product);
1794
1828
  }
1795
1829
  }
1796
- class gr extends C {
1830
+ class yr extends P {
1797
1831
  }
1798
1832
  class ie extends b {
1799
1833
  /**
@@ -1815,7 +1849,7 @@ class ie extends b {
1815
1849
  * Дополнительные метаданные свойства.
1816
1850
  */
1817
1851
  t(this, "metadata");
1818
- this.type = new gr(e == null ? void 0 : e.type), this.description = (e == null ? void 0 : e.description) ?? "", this.metadata = e == null ? void 0 : e.metadata;
1852
+ this.type = new yr(e == null ? void 0 : e.type), this.description = (e == null ? void 0 : e.description) ?? "", this.metadata = e == null ? void 0 : e.metadata;
1819
1853
  }
1820
1854
  }
1821
1855
  class E {
@@ -1852,10 +1886,10 @@ class k {
1852
1886
  * Окончание периода.
1853
1887
  */
1854
1888
  t(this, "to");
1855
- this.from = y(r == null ? void 0 : r.from) ? w(r.from) : (r == null ? void 0 : r.from) ?? null, this.to = y(r == null ? void 0 : r.to) ? w(r.to) : (r == null ? void 0 : r.to) ?? null;
1889
+ this.from = C(r == null ? void 0 : r.from) ? v(r.from) : (r == null ? void 0 : r.from) ?? null, this.to = C(r == null ? void 0 : r.to) ? v(r.to) : (r == null ? void 0 : r.to) ?? null;
1856
1890
  }
1857
1891
  }
1858
- class dt {
1892
+ class Mt {
1859
1893
  /**
1860
1894
  * Инициализирует экземпляр класса {@link TemplatesListFilters}.
1861
1895
  *
@@ -1915,7 +1949,7 @@ class dt {
1915
1949
  return Object.keys(this).forEach((c) => {
1916
1950
  const u = this[c];
1917
1951
  // eslint-disable-next-line prettier/prettier
1918
- D(u) || y(u) && u.trim().length === 0 || de(u.isNewRec) && u.isNewRec() || (r[c] = u);
1952
+ A(u) || C(u) && u.trim().length === 0 || Ue(u.isNewRec) && u.isNewRec() || (r[c] = u);
1919
1953
  }), !((e = r == null ? void 0 : r.createdAt) != null && e.from) && !((s = r == null ? void 0 : r.createdAt) != null && s.to) && delete r.createdAt, !((i = r == null ? void 0 : r.updatedAt) != null && i.from) && !((o = r == null ? void 0 : r.updatedAt) != null && o.to) && delete r.updatedAt, r;
1920
1954
  }
1921
1955
  }
@@ -1954,7 +1988,7 @@ class ne extends b {
1954
1988
  this.description = e == null ? void 0 : e.description, this.canChangeLowCost = (e == null ? void 0 : e.canChangeLowCost) ?? !1, this.parentRoleId = e == null ? void 0 : e.parentRoleId;
1955
1989
  }
1956
1990
  }
1957
- class Je {
1991
+ class Ve {
1958
1992
  /**
1959
1993
  * Инициализирует экземпляр класса {@link PricingRoleCategoryRule}.
1960
1994
  *
@@ -1976,7 +2010,7 @@ class Je {
1976
2010
  this.role = new ne(r == null ? void 0 : r.role), this.category = new ge(r == null ? void 0 : r.category), this.minCoefficient = new Re(r == null ? void 0 : r.minCoefficient);
1977
2011
  }
1978
2012
  }
1979
- class et {
2013
+ class tt {
1980
2014
  /**
1981
2015
  * Инициализирует экземпляр класса {@link DeviceTypeResolutionConfig}.
1982
2016
  *
@@ -1998,7 +2032,7 @@ class et {
1998
2032
  this.phone = (r == null ? void 0 : r.phone) ?? 360, this.tablet = (r == null ? void 0 : r.tablet) ?? 600, this.laptop = (r == null ? void 0 : r.laptop) ?? 1024;
1999
2033
  }
2000
2034
  }
2001
- class rt {
2035
+ class st {
2002
2036
  /**
2003
2037
  * Инициализирует экземпляр класса {@link HttpParamsConfig}.
2004
2038
  *
@@ -2028,7 +2062,7 @@ class rt {
2028
2062
  this.portalApiUrl = (r == null ? void 0 : r.portalApiUrl) ?? "", this.priceHistoryApiUrl = (r == null ? void 0 : r.priceHistoryApiUrl) ?? "", this.recommendationsApiUrl = (r == null ? void 0 : r.recommendationsApiUrl) ?? "", this.mediaUrl = (r == null ? void 0 : r.mediaUrl) ?? "", this.responseDataCacheTimeout = (r == null ? void 0 : r.responseDataCacheTimeout) ?? 3 * 60 * 60;
2029
2063
  }
2030
2064
  }
2031
- class tt {
2065
+ class it {
2032
2066
  /**
2033
2067
  * Инициализирует экземпляр класса {@link SentryConfig}.
2034
2068
  *
@@ -2073,7 +2107,7 @@ class tt {
2073
2107
  }, this.additionalParams = (r == null ? void 0 : r.additionalParams) ?? {};
2074
2108
  }
2075
2109
  }
2076
- class st {
2110
+ class nt {
2077
2111
  /**
2078
2112
  * Инициализирует экземпляр класса {@link VersionConfig}.
2079
2113
  *
@@ -2092,10 +2126,10 @@ class st {
2092
2126
  * Текущая версия приложения.
2093
2127
  */
2094
2128
  t(this, "version");
2095
- this.date = y(r == null ? void 0 : r.date) ? w(r.date) : (r == null ? void 0 : r.date) ?? /* @__PURE__ */ new Date(), this.name = (r == null ? void 0 : r.name) ?? "", this.version = (r == null ? void 0 : r.version) ?? "0.0.0";
2129
+ this.date = C(r == null ? void 0 : r.date) ? v(r.date) : (r == null ? void 0 : r.date) ?? /* @__PURE__ */ new Date(), this.name = (r == null ? void 0 : r.name) ?? "", this.version = (r == null ? void 0 : r.version) ?? "0.0.0";
2096
2130
  }
2097
2131
  }
2098
- class it {
2132
+ class ot {
2099
2133
  /**
2100
2134
  * Инициализирует экземпляр класса {@link WebSocketConfig}.
2101
2135
  *
@@ -2134,7 +2168,7 @@ class it {
2134
2168
  this.broadcaster = r.broadcaster ?? "reverb", this.key = r.key ?? "", this.wsHost = r.wsHost ?? "", this.wsPort = r.wsPort ?? 8080, this.wssPort = r.wssPort ?? 8080, this.forceTLS = r.forceTLS ?? !1, this.enabledTransports = r.enabledTransports ?? ["wss"];
2135
2169
  }
2136
2170
  }
2137
- class Ft {
2171
+ class jt {
2138
2172
  /**
2139
2173
  * Инициализирует экземпляр класса {@link AppBaseConfig}.
2140
2174
  *
@@ -2182,17 +2216,17 @@ class Ft {
2182
2216
  */
2183
2217
  t(this, "dateFormats");
2184
2218
  var e, s, i;
2185
- this.environment = (r == null ? void 0 : r.environment) ?? "production", this.devMode = (r == null ? void 0 : r.devMode) ?? {}, this.http = new rt(r == null ? void 0 : r.http), this.deviceTypeByResolution = new et(r == null ? void 0 : r.deviceTypeByResolution), this.sentry = new tt({
2219
+ this.environment = (r == null ? void 0 : r.environment) ?? "production", this.devMode = (r == null ? void 0 : r.devMode) ?? {}, this.http = new st(r == null ? void 0 : r.http), this.deviceTypeByResolution = new tt(r == null ? void 0 : r.deviceTypeByResolution), this.sentry = new it({
2186
2220
  environment: this.environment,
2187
2221
  ...r == null ? void 0 : r.sentry
2188
- }), this.tableDefaultHeightCoefficient = (r == null ? void 0 : r.tableDefaultHeightCoefficient) ?? 0.7, this.urls = r == null ? void 0 : r.urls, this.version = new st(r == null ? void 0 : r.version), this.websocket = r != null && r.websocket ? new it(r.websocket) : void 0, this.dateFormats = {
2222
+ }), this.tableDefaultHeightCoefficient = (r == null ? void 0 : r.tableDefaultHeightCoefficient) ?? 0.7, this.urls = r == null ? void 0 : r.urls, this.version = new nt(r == null ? void 0 : r.version), this.websocket = r != null && r.websocket ? new ot(r.websocket) : void 0, this.dateFormats = {
2189
2223
  api: ((e = r == null ? void 0 : r.dateFormats) == null ? void 0 : e.api) ?? "yyyy-MM-dd HH:mm:ss",
2190
2224
  uiDate: ((s = r == null ? void 0 : r.dateFormats) == null ? void 0 : s.uiDate) ?? "dd.MM.yyyy",
2191
2225
  uiDateWithTime: ((i = r == null ? void 0 : r.dateFormats) == null ? void 0 : i.uiDateWithTime) ?? "dd.MM.yyyy HH:mm"
2192
2226
  };
2193
2227
  }
2194
2228
  }
2195
- class Mt extends h {
2229
+ class Gt extends h {
2196
2230
  /**
2197
2231
  * Возвращает данные о результатах поиска категорий и товаров.
2198
2232
  *
@@ -2223,7 +2257,7 @@ class Mt extends h {
2223
2257
  return s && (c += `&category_id=${s}`), i && (c += `&client_id=${i}`), c;
2224
2258
  }
2225
2259
  }
2226
- class jt extends h {
2260
+ class Ht extends h {
2227
2261
  /**
2228
2262
  * Импортирует цены клиента из CSV файла.
2229
2263
  *
@@ -2422,7 +2456,7 @@ class jt extends h {
2422
2456
  return this.post(`/internal/clients/${r}/price/commercial-offer/send`, e);
2423
2457
  }
2424
2458
  }
2425
- class Gt extends h {
2459
+ class Bt extends h {
2426
2460
  /**
2427
2461
  * Возвращает список шаблонов прайс-листа привязанных к клиенту.
2428
2462
  *
@@ -2461,8 +2495,8 @@ class Gt extends h {
2461
2495
  return this.post(
2462
2496
  `/internal/clients/${r}/price/templates/${e}`,
2463
2497
  s && {
2464
- startAt: s.startAt && q(s.startAt, i),
2465
- endAt: s.endAt && q(s.endAt, i)
2498
+ startAt: s.startAt && d(s.startAt, i),
2499
+ endAt: s.endAt && d(s.endAt, i)
2466
2500
  },
2467
2501
  (o) => new se(o.data),
2468
2502
  {},
@@ -2495,8 +2529,8 @@ class Gt extends h {
2495
2529
  return this.patch(
2496
2530
  `/internal/clients/${r}/price/templates/${e}/${s}`,
2497
2531
  i && {
2498
- startAt: i.startAt && q(i.startAt, o),
2499
- endAt: i.endAt && q(i.endAt, o)
2532
+ startAt: i.startAt && d(i.startAt, o),
2533
+ endAt: i.endAt && d(i.endAt, o)
2500
2534
  },
2501
2535
  (c) => new se(c.data)
2502
2536
  );
@@ -2514,7 +2548,7 @@ class Gt extends h {
2514
2548
  return this.delete(`/internal/clients/${r}/price/templates/${e}/${s}`);
2515
2549
  }
2516
2550
  }
2517
- class Ht extends h {
2551
+ class Et extends h {
2518
2552
  /**
2519
2553
  * Возвращает список данных о корневых категориях.
2520
2554
  *
@@ -2587,7 +2621,7 @@ class Ht extends h {
2587
2621
  getCategoryProductsCoefficients(r) {
2588
2622
  return this.get(`/internal/catalog/categories/${r}/products/coefficients`, {}, (e) => {
2589
2623
  const { data: s } = e;
2590
- return Lr(s, (i) => i.map((o) => new Me(o))), s;
2624
+ return Or(s, (i) => i.map((o) => new Me(o))), s;
2591
2625
  });
2592
2626
  }
2593
2627
  /**
@@ -2606,7 +2640,7 @@ class Ht extends h {
2606
2640
  });
2607
2641
  }
2608
2642
  }
2609
- class Bt extends h {
2643
+ class zt extends h {
2610
2644
  /**
2611
2645
  * Возвращает данные об указанном продукте.
2612
2646
  *
@@ -2656,7 +2690,7 @@ class Bt extends h {
2656
2690
  });
2657
2691
  }
2658
2692
  }
2659
- class Et extends h {
2693
+ class Wt extends h {
2660
2694
  /**
2661
2695
  * Возвращает список данных о корневых категориях указанного клиента.
2662
2696
  *
@@ -2718,7 +2752,7 @@ class Et extends h {
2718
2752
  );
2719
2753
  }
2720
2754
  }
2721
- class zt extends h {
2755
+ class Jt extends h {
2722
2756
  /**
2723
2757
  * Возвращает данные об указанном продукте для указанного клиента.
2724
2758
  *
@@ -2739,8 +2773,8 @@ class zt extends h {
2739
2773
  );
2740
2774
  }
2741
2775
  }
2742
- var Be = /* @__PURE__ */ ((n) => (n.BeginWith = "bw", n.Contains = "cn", n.Custom = "custom", n.EndsWith = "ew", n.Equals = "eq", n.GreaterOrEqual = "ge", n.GreaterThan = "gt", n.InList = "in", n.LessOrEqual = "le", n.LessThan = "lt", n.NotBeginWith = "bn", n.NotContains = "nc", n.NotEndsWith = "en", n.NotEqual = "ne", n.NotInList = "ni", n.NotNull = "nn", n.Null = "nu", n))(Be || {});
2743
- class Ve {
2776
+ var Ee = /* @__PURE__ */ ((n) => (n.BeginWith = "bw", n.Contains = "cn", n.Custom = "custom", n.EndsWith = "ew", n.Equals = "eq", n.GreaterOrEqual = "ge", n.GreaterThan = "gt", n.InList = "in", n.LessOrEqual = "le", n.LessThan = "lt", n.NotBeginWith = "bn", n.NotContains = "nc", n.NotEndsWith = "en", n.NotEqual = "ne", n.NotInList = "ni", n.NotNull = "nn", n.Null = "nu", n))(Ee || {});
2777
+ class Ke {
2744
2778
  /**
2745
2779
  * Инициализирует экземпляр класса {@link FilterItem}.
2746
2780
  *
@@ -2759,7 +2793,7 @@ class Ve {
2759
2793
  * Значение с которым сравнивается поле.
2760
2794
  */
2761
2795
  t(this, "value");
2762
- this.field = (r == null ? void 0 : r.field) ?? "", this.op = (r == null ? void 0 : r.op) ?? Be.Equals, this.value = (r == null ? void 0 : r.value) ?? "";
2796
+ this.field = (r == null ? void 0 : r.field) ?? "", this.op = (r == null ? void 0 : r.op) ?? Ee.Equals, this.value = (r == null ? void 0 : r.value) ?? "";
2763
2797
  }
2764
2798
  /**
2765
2799
  * Преобразует фильтр в примитивное представление для API.
@@ -2771,7 +2805,7 @@ class Ve {
2771
2805
  field: this.field,
2772
2806
  op: this.op
2773
2807
  };
2774
- return r.value = ke(this.value) ? q(this.value, T.getConfig().dateFormats.api) : this.value, r;
2808
+ return r.value = ke(this.value) ? d(this.value, T.getConfig().dateFormats.api) : this.value, r;
2775
2809
  }
2776
2810
  }
2777
2811
  class ue {
@@ -2794,7 +2828,7 @@ class ue {
2794
2828
  */
2795
2829
  t(this, "groups");
2796
2830
  var e, s;
2797
- this.groupOp = (r == null ? void 0 : r.groupOp) ?? "and", this.filters = ((e = r == null ? void 0 : r.filters) == null ? void 0 : e.map((i) => new Ve(i))) ?? [], this.groups = ((s = r == null ? void 0 : r.groups) == null ? void 0 : s.map((i) => new ue(i))) ?? [];
2831
+ this.groupOp = (r == null ? void 0 : r.groupOp) ?? "and", this.filters = ((e = r == null ? void 0 : r.filters) == null ? void 0 : e.map((i) => new Ke(i))) ?? [], this.groups = ((s = r == null ? void 0 : r.groups) == null ? void 0 : s.map((i) => new ue(i))) ?? [];
2798
2832
  }
2799
2833
  /**
2800
2834
  * Преобразует группу фильтров в примитивное представление для API.
@@ -2804,7 +2838,7 @@ class ue {
2804
2838
  toPrimitive() {
2805
2839
  return {
2806
2840
  groupOp: this.groupOp,
2807
- filters: this.filters.map((r) => r instanceof Ve && de(r.toPrimitive) ? r.toPrimitive() : r),
2841
+ filters: this.filters.map((r) => r instanceof Ke && Ue(r.toPrimitive) ? r.toPrimitive() : r),
2808
2842
  groups: this.groups.map((r) => r instanceof ue ? r.toPrimitive() : r)
2809
2843
  };
2810
2844
  }
@@ -2829,7 +2863,7 @@ class Te extends h {
2829
2863
  return e && (p.filters = JSON.stringify((e instanceof ue ? e : new ue(e)).toPrimitive())), Y(s) || (p.sort = Q(s) ? s : [s]), o && (p = { ...p, ...o }), this.get(r, p, c, u);
2830
2864
  }
2831
2865
  }
2832
- class Wt extends Te {
2866
+ class Vt extends Te {
2833
2867
  /**
2834
2868
  * Возвращает список шаблонов прайс-листа.
2835
2869
  *
@@ -3033,7 +3067,7 @@ class Wt extends Te {
3033
3067
  );
3034
3068
  }
3035
3069
  }
3036
- class Jt extends h {
3070
+ class Kt extends h {
3037
3071
  /**
3038
3072
  * Возвращает список ролей ценообразования.
3039
3073
  *
@@ -3094,7 +3128,7 @@ class Jt extends h {
3094
3128
  return this.get(
3095
3129
  `/internal/price/roles/rules/categories/${r}`,
3096
3130
  {},
3097
- (e) => e.data.map((s) => new Je(s))
3131
+ (e) => e.data.map((s) => new Ve(s))
3098
3132
  );
3099
3133
  }
3100
3134
  /**
@@ -3109,11 +3143,11 @@ class Jt extends h {
3109
3143
  return this.patch(
3110
3144
  `/internal/price/roles/rules/categories/${r}`,
3111
3145
  e,
3112
- (s) => s.data.map((i) => new Je(i))
3146
+ (s) => s.data.map((i) => new Ve(i))
3113
3147
  );
3114
3148
  }
3115
3149
  }
3116
- class Vt extends Te {
3150
+ class Qt extends Te {
3117
3151
  /**
3118
3152
  * Возвращает пагинированный список свойств.
3119
3153
  *
@@ -3485,7 +3519,7 @@ class Vt extends Te {
3485
3519
  return this.post(`/internal/catalog/categories/${r}/image`, { image: e });
3486
3520
  }
3487
3521
  }
3488
- function Ke(n, r, e) {
3522
+ function Qe(n, r, e) {
3489
3523
  let s;
3490
3524
  return n.some((i) => {
3491
3525
  if (i.type === e && i.id === r)
@@ -3494,35 +3528,35 @@ function Ke(n, r, e) {
3494
3528
  return !1;
3495
3529
  const o = i;
3496
3530
  if (o.products && o.products.length > 0) {
3497
- const c = Ke(o.products, r, e);
3531
+ const c = Qe(o.products, r, e);
3498
3532
  if (c)
3499
3533
  return s = c, !0;
3500
3534
  }
3501
3535
  if (o.categories && o.categories.length > 0) {
3502
- const c = Ke(o.categories, r, e);
3536
+ const c = Qe(o.categories, r, e);
3503
3537
  if (c)
3504
3538
  return s = c, !0;
3505
3539
  }
3506
3540
  return !1;
3507
3541
  }), s;
3508
3542
  }
3509
- function Qe(n) {
3543
+ function Ye(n) {
3510
3544
  const r = [];
3511
3545
  return n.forEach((e) => {
3512
3546
  if (r.push(e), e.type === "category") {
3513
3547
  const s = e;
3514
- s.products && s.products.length > 0 && r.push(...Qe(s.products)), s.categories && s.categories.length > 0 && r.push(...Qe(s.categories));
3548
+ s.products && s.products.length > 0 && r.push(...Ye(s.products)), s.categories && s.categories.length > 0 && r.push(...Ye(s.categories));
3515
3549
  }
3516
3550
  }), r;
3517
3551
  }
3518
- var nt = /* @__PURE__ */ ((n) => (n.LastOrder = "last_order", n.Contacts = "contacts", n.PartnerGroups = "partner_groups", n.PreferredDeliveryType = "preferred_delivery_type", n.SalesDirection = "sales_direction", n.Managers = "managers", n))(nt || {}), N = /* @__PURE__ */ ((n) => (n.Person = "individual", n.Ic = "entrepreneur", n.UlR = "legal", n.UlNr = "non_resident_legal", n))(N || {});
3519
- class ot extends C {
3552
+ var ct = /* @__PURE__ */ ((n) => (n.LastOrder = "last_order", n.Contacts = "contacts", n.PartnerGroups = "partner_groups", n.PreferredDeliveryType = "preferred_delivery_type", n.SalesDirection = "sales_direction", n.Managers = "managers", n))(ct || {}), q = /* @__PURE__ */ ((n) => (n.Person = "individual", n.Ic = "entrepreneur", n.UlR = "legal", n.UlNr = "non_resident_legal", n))(q || {});
3553
+ class lt extends P {
3520
3554
  }
3521
- class mr extends C {
3555
+ class wr extends P {
3522
3556
  }
3523
- class Kt extends C {
3557
+ class Yt extends P {
3524
3558
  }
3525
- class ct extends C {
3559
+ class ut extends P {
3526
3560
  }
3527
3561
  class Ce extends b {
3528
3562
  /**
@@ -3543,7 +3577,7 @@ class Ce extends b {
3543
3577
  e && (this.signature = e.signature ?? "", this.symbol = e.symbol ?? "");
3544
3578
  }
3545
3579
  }
3546
- class F extends C {
3580
+ class F extends P {
3547
3581
  /**
3548
3582
  * Возвращает сгенерированную запись-описание физического лица.
3549
3583
  */
@@ -3551,26 +3585,26 @@ class F extends C {
3551
3585
  return new F({
3552
3586
  id: 1,
3553
3587
  guid: "",
3554
- slug: N.Person,
3588
+ slug: q.Person,
3555
3589
  name: ""
3556
3590
  });
3557
3591
  }
3558
3592
  }
3559
- class lt extends C {
3593
+ class pt extends P {
3560
3594
  }
3561
- class ut extends C {
3595
+ class ht extends P {
3562
3596
  }
3563
- class re extends C {
3597
+ class re extends P {
3564
3598
  }
3565
- class pt extends C {
3599
+ class gt extends P {
3566
3600
  }
3567
- class ht extends C {
3601
+ class mt extends P {
3568
3602
  }
3569
- class fr extends C {
3603
+ class Cr extends P {
3570
3604
  }
3571
- class yr extends C {
3605
+ class vr extends P {
3572
3606
  }
3573
- class qe extends j {
3607
+ class de extends j {
3574
3608
  /**
3575
3609
  * Инициализирует экземпляр класса {@link BankAccount}.
3576
3610
  *
@@ -3601,7 +3635,7 @@ class qe extends j {
3601
3635
  e && (this.bankName = e.bankName ?? "", this.bic = e.bic ?? "", this.accountNumber = e.accountNumber ?? "", this.correspondentAccount = e.correspondentAccount ?? "", this.currency = new Ce(e.currency));
3602
3636
  }
3603
3637
  }
3604
- class Ne extends b {
3638
+ class qe extends b {
3605
3639
  /**
3606
3640
  * Инициализирует экземпляр класса {@link Contact}.
3607
3641
  *
@@ -3620,7 +3654,7 @@ class Ne extends b {
3620
3654
  this.email = e == null ? void 0 : e.email, this.phone = /^\d+$/.test((e == null ? void 0 : e.phone) ?? "") ? `+${e == null ? void 0 : e.phone}` : e == null ? void 0 : e.phone;
3621
3655
  }
3622
3656
  }
3623
- class M extends Ne {
3657
+ class M extends qe {
3624
3658
  /**
3625
3659
  * Инициализирует экземпляр класса {@link ContactPerson}.
3626
3660
  *
@@ -3652,10 +3686,10 @@ class M extends Ne {
3652
3686
  * Дата и время последнего удаления.
3653
3687
  */
3654
3688
  t(this, "deletedAt");
3655
- this.isPrimary = (e == null ? void 0 : e.isPrimary) ?? !1, this.position = e == null ? void 0 : e.position, this.notDisturb = (e == null ? void 0 : e.notDisturb) ?? !1, this.comment = e == null ? void 0 : e.comment, this.updatedAt = e == null ? void 0 : e.updatedAt, this.deletedAt = y(e == null ? void 0 : e.deletedAt) ? w(e.deletedAt) : e == null ? void 0 : e.deletedAt;
3689
+ this.isPrimary = (e == null ? void 0 : e.isPrimary) ?? !1, this.position = e == null ? void 0 : e.position, this.notDisturb = (e == null ? void 0 : e.notDisturb) ?? !1, this.comment = e == null ? void 0 : e.comment, this.updatedAt = e == null ? void 0 : e.updatedAt, this.deletedAt = C(e == null ? void 0 : e.deletedAt) ? v(e.deletedAt) : e == null ? void 0 : e.deletedAt;
3656
3690
  }
3657
3691
  }
3658
- class wr extends b {
3692
+ class Pr extends b {
3659
3693
  /**
3660
3694
  * Инициализирует экземпляр класса {@link ContragentBase}.
3661
3695
  *
@@ -3713,7 +3747,7 @@ class wr extends b {
3713
3747
  */
3714
3748
  t(this, "updater");
3715
3749
  if (e) {
3716
- if (this.opf = new F(e.opf), this.salesDirection = new x(e.salesDirection), this.comment = e.comment, this.alternativeName = e.alternativeName, this.createdAt = y(e == null ? void 0 : e.createdAt) ? w(e.createdAt) : e.createdAt, this.creator = e.creator ? new d(e.creator) : void 0, this.updatedAt = y(e == null ? void 0 : e.updatedAt) ? w(e.updatedAt) : e.updatedAt, this.updater = e.updater ? new d(e.updater) : void 0, e.partnerGroup && (this.partnerGroup = new re(e.partnerGroup)), e.manager && (this.manager = new ce(e.manager)), e.contacts) {
3750
+ if (this.opf = new F(e.opf), this.salesDirection = new x(e.salesDirection), this.comment = e.comment, this.alternativeName = e.alternativeName, this.createdAt = C(e == null ? void 0 : e.createdAt) ? v(e.createdAt) : e.createdAt, this.creator = e.creator ? new U(e.creator) : void 0, this.updatedAt = C(e == null ? void 0 : e.updatedAt) ? v(e.updatedAt) : e.updatedAt, this.updater = e.updater ? new U(e.updater) : void 0, e.partnerGroup && (this.partnerGroup = new re(e.partnerGroup)), e.manager && (this.manager = new ce(e.manager)), e.contacts) {
3717
3751
  const s = [];
3718
3752
  e.contacts.forEach((i) => {
3719
3753
  s.push(new M(i));
@@ -3722,13 +3756,13 @@ class wr extends b {
3722
3756
  if (e.bankAccounts) {
3723
3757
  const s = [];
3724
3758
  e.bankAccounts.forEach((i) => {
3725
- s.push(new qe(i));
3759
+ s.push(new de(i));
3726
3760
  }), this.bankAccounts = s;
3727
3761
  }
3728
3762
  }
3729
3763
  }
3730
3764
  }
3731
- class gt extends wr {
3765
+ class ft extends Pr {
3732
3766
  /**
3733
3767
  * Инициализирует экземпляр класса {@link ContragentPerson}.
3734
3768
  *
@@ -3738,7 +3772,7 @@ class gt extends wr {
3738
3772
  super(r);
3739
3773
  }
3740
3774
  }
3741
- class Cr extends wr {
3775
+ class Rr extends Pr {
3742
3776
  /**
3743
3777
  * Инициализирует экземпляр класса {@link ContragentIc}.
3744
3778
  *
@@ -3781,7 +3815,7 @@ class Cr extends wr {
3781
3815
  e && (this.inn = e.inn ?? "", this.okpo = e.okpo ?? "", this.directorName = e.directorName ?? "", this.directorPosition = e.directorPosition ?? "", this.directorActsOn = e.directorActsOn ?? "", this.legalAddress = e.legalAddress ?? "", this.postalAddress = e.postalAddress ?? "", this.actualAddress = e.actualAddress ?? "");
3782
3816
  }
3783
3817
  }
3784
- class vr extends Cr {
3818
+ class Dr extends Rr {
3785
3819
  /**
3786
3820
  * Инициализирует экземпляр класса {@link ContragentUlR}.
3787
3821
  *
@@ -3796,7 +3830,7 @@ class vr extends Cr {
3796
3830
  e && (this.kpp = e.kpp ?? "");
3797
3831
  }
3798
3832
  }
3799
- class mt extends vr {
3833
+ class yt extends Dr {
3800
3834
  /**
3801
3835
  * Инициализирует экземпляр класса {@link ContragentUlNr}.
3802
3836
  *
@@ -3827,14 +3861,14 @@ class ve {
3827
3861
  */
3828
3862
  static createInstance(r) {
3829
3863
  switch (r.opf.slug) {
3830
- case N.Ic:
3831
- return new Cr(r);
3832
- case N.UlR:
3833
- return new vr(r);
3834
- case N.UlNr:
3835
- return new mt(r);
3864
+ case q.Ic:
3865
+ return new Rr(r);
3866
+ case q.UlR:
3867
+ return new Dr(r);
3868
+ case q.UlNr:
3869
+ return new yt(r);
3836
3870
  default:
3837
- return new gt(r);
3871
+ return new ft(r);
3838
3872
  }
3839
3873
  }
3840
3874
  }
@@ -3853,7 +3887,7 @@ class Ie extends j {
3853
3887
  this.isPrimary = e.isPrimary;
3854
3888
  }
3855
3889
  }
3856
- class ft extends M {
3890
+ class wt extends M {
3857
3891
  /**
3858
3892
  * Инициализирует экземпляр класса {@link ContactPersonRelated}.
3859
3893
  *
@@ -3881,7 +3915,7 @@ class ft extends M {
3881
3915
  e.relations && (e.relations.addresses && (this.relations.addresses = e.relations.addresses.map((s) => new Ie(s))), e.relations.clients && (this.relations.clients = e.relations.clients.map((s) => new Ie(s))), e.relations.contragents && (this.relations.contragents = e.relations.contragents.map((s) => new Ie(s))));
3882
3916
  }
3883
3917
  }
3884
- class Pe extends Kr {
3918
+ class Pe extends Xr {
3885
3919
  /**
3886
3920
  * Инициализирует экземпляр класса {@link DeliveryAddress}.
3887
3921
  *
@@ -3918,10 +3952,10 @@ class Pe extends Kr {
3918
3952
  * Признак того, что указанный адрес является адресом транспортной компании.
3919
3953
  */
3920
3954
  t(this, "isTransportCompanyAddress");
3921
- this.address = (e == null ? void 0 : e.address) ?? "", this.coordinates = new lr(e == null ? void 0 : e.coordinates), this.contacts = ((s = e == null ? void 0 : e.contacts) == null ? void 0 : s.map((i) => new M(i))) ?? [], this.comment = e == null ? void 0 : e.comment, this.operatingHours = e == null ? void 0 : e.operatingHours, this.isOneTime = e == null ? void 0 : e.isOneTime, this.isTransportCompanyAddress = e == null ? void 0 : e.isTransportCompanyAddress;
3955
+ this.address = (e == null ? void 0 : e.address) ?? "", this.coordinates = new ur(e == null ? void 0 : e.coordinates), this.contacts = ((s = e == null ? void 0 : e.contacts) == null ? void 0 : s.map((i) => new M(i))) ?? [], this.comment = e == null ? void 0 : e.comment, this.operatingHours = e == null ? void 0 : e.operatingHours, this.isOneTime = e == null ? void 0 : e.isOneTime, this.isTransportCompanyAddress = e == null ? void 0 : e.isTransportCompanyAddress;
3922
3956
  }
3923
3957
  }
3924
- class Ye extends me {
3958
+ class Xe extends me {
3925
3959
  /**
3926
3960
  * Инициализирует экземпляр класса {@link Client}.
3927
3961
  *
@@ -3979,10 +4013,10 @@ class Ye extends me {
3979
4013
  * @inheritDoc
3980
4014
  */
3981
4015
  t(this, "extraData");
3982
- this.contragents = ((s = e == null ? void 0 : e.contragents) == null ? void 0 : s.map((u) => ve.createInstance(u))) ?? [], this.partnerGroups = ((i = e == null ? void 0 : e.partnerGroups) == null ? void 0 : i.map((u) => new re(u))) ?? [], this.contacts = ((o = e == null ? void 0 : e.contacts) == null ? void 0 : o.map((u) => new M(u))) ?? [], this.deliveryAddresses = ((c = e == null ? void 0 : e.deliveryAddresses) == null ? void 0 : c.map((u) => new Pe(u))) ?? [], this.channelPrimaryInterest = new mr(e == null ? void 0 : e.channelPrimaryInterest), this.sourcePrimaryInterest = new yr(e == null ? void 0 : e.sourcePrimaryInterest), this.preferredDeliveryType = new X(e == null ? void 0 : e.preferredDeliveryType), this.primaryDemand = e == null ? void 0 : e.primaryDemand, this.isExcludedFromMsCallsToClients = (e == null ? void 0 : e.isExcludedFromMsCallsToClients) ?? !1, this.reasonExcludedFromMsCallsToClients = e == null ? void 0 : e.reasonExcludedFromMsCallsToClients, this.preferredWarehouse = e != null && e.preferredWarehouse ? new Ae(e.preferredWarehouse) : void 0, this.extraData = (e == null ? void 0 : e.extraData) ?? {};
4016
+ this.contragents = ((s = e == null ? void 0 : e.contragents) == null ? void 0 : s.map((u) => ve.createInstance(u))) ?? [], this.partnerGroups = ((i = e == null ? void 0 : e.partnerGroups) == null ? void 0 : i.map((u) => new re(u))) ?? [], this.contacts = ((o = e == null ? void 0 : e.contacts) == null ? void 0 : o.map((u) => new M(u))) ?? [], this.deliveryAddresses = ((c = e == null ? void 0 : e.deliveryAddresses) == null ? void 0 : c.map((u) => new Pe(u))) ?? [], this.channelPrimaryInterest = new wr(e == null ? void 0 : e.channelPrimaryInterest), this.sourcePrimaryInterest = new vr(e == null ? void 0 : e.sourcePrimaryInterest), this.preferredDeliveryType = new X(e == null ? void 0 : e.preferredDeliveryType), this.primaryDemand = e == null ? void 0 : e.primaryDemand, this.isExcludedFromMsCallsToClients = (e == null ? void 0 : e.isExcludedFromMsCallsToClients) ?? !1, this.reasonExcludedFromMsCallsToClients = e == null ? void 0 : e.reasonExcludedFromMsCallsToClients, this.preferredWarehouse = e != null && e.preferredWarehouse ? new De(e.preferredWarehouse) : void 0, this.extraData = (e == null ? void 0 : e.extraData) ?? {};
3983
4017
  }
3984
4018
  }
3985
- class Qt {
4019
+ class Xt {
3986
4020
  /**
3987
4021
  * Инициализирует экземпляр класса {@link ClientsListFilters}.
3988
4022
  *
@@ -4045,6 +4079,10 @@ class Qt {
4045
4079
  * @inheritDoc
4046
4080
  */
4047
4081
  t(this, "managers");
4082
+ /**
4083
+ * @inheritDoc
4084
+ */
4085
+ t(this, "curators");
4048
4086
  /**
4049
4087
  * @inheritDoc
4050
4088
  */
@@ -4081,11 +4119,11 @@ class Qt {
4081
4119
  * @inheritDoc
4082
4120
  */
4083
4121
  t(this, "isExcludedFromMsCallsToClients");
4084
- var e, s, i, o, c, u;
4085
- this.id = r == null ? void 0 : r.id, this.name = r == null ? void 0 : r.name, this.alternativeName = r == null ? void 0 : r.alternativeName, this.searchTerm = r == null ? void 0 : r.searchTerm, this.cities = (e = r == null ? void 0 : r.cities) == null ? void 0 : e.map((p) => new He(p)), this.region = new le(r == null ? void 0 : r.region), this.country = new ee(r == null ? void 0 : r.country), this.phone = r == null ? void 0 : r.phone, this.email = r == null ? void 0 : r.email, this.isActive = r && Object.prototype.hasOwnProperty.call(r, "isActive") ? r == null ? void 0 : r.isActive : !0, this.createdAt = new k(r == null ? void 0 : r.createdAt), this.lastLoginDate = new k(r == null ? void 0 : r.lastLoginDate), this.lastLoginDateHasOrder = (r == null ? void 0 : r.lastLoginDateHasOrder) ?? void 0, this.managers = r != null && r.managers && r.managers.length > 0 ? r.managers.map((p) => new De(p)) : [], this.salesDirections = (s = r == null ? void 0 : r.salesDirections) == null ? void 0 : s.map((p) => new x(p)), this.contragentInn = r == null ? void 0 : r.contragentInn, this.contragentType = new F(r == null ? void 0 : r.contragentType), this.preferredDeliveryType = new X(r == null ? void 0 : r.preferredDeliveryType), this.partnerGroups = (i = r == null ? void 0 : r.partnerGroups) == null ? void 0 : i.map((p) => new re(p)), this.contact = new Ne(r == null ? void 0 : r.contact), this.lastOrder = {
4086
- createdAt: new k((o = r == null ? void 0 : r.lastOrder) == null ? void 0 : o.createdAt),
4087
- creator: (c = r == null ? void 0 : r.lastOrder) == null ? void 0 : c.creator,
4088
- isApproved: (u = r == null ? void 0 : r.lastOrder) == null ? void 0 : u.isApproved
4122
+ var e, s, i, o, c, u, p, f;
4123
+ this.id = r == null ? void 0 : r.id, this.name = r == null ? void 0 : r.name, this.alternativeName = r == null ? void 0 : r.alternativeName, this.searchTerm = r == null ? void 0 : r.searchTerm, this.cities = (e = r == null ? void 0 : r.cities) == null ? void 0 : e.map((m) => new Be(m)), this.region = new le(r == null ? void 0 : r.region), this.country = new ee(r == null ? void 0 : r.country), this.phone = r == null ? void 0 : r.phone, this.email = r == null ? void 0 : r.email, this.isActive = r && Object.prototype.hasOwnProperty.call(r, "isActive") ? r == null ? void 0 : r.isActive : !0, this.createdAt = new k(r == null ? void 0 : r.createdAt), this.lastLoginDate = new k(r == null ? void 0 : r.lastLoginDate), this.lastLoginDateHasOrder = (r == null ? void 0 : r.lastLoginDateHasOrder) ?? void 0, this.managers = ((s = r == null ? void 0 : r.managers) == null ? void 0 : s.map((m) => new Ae(m))) ?? [], this.curators = ((i = r == null ? void 0 : r.curators) == null ? void 0 : i.map((m) => new mr(m))) ?? [], this.salesDirections = (o = r == null ? void 0 : r.salesDirections) == null ? void 0 : o.map((m) => new x(m)), this.contragentInn = r == null ? void 0 : r.contragentInn, this.contragentType = new F(r == null ? void 0 : r.contragentType), this.preferredDeliveryType = new X(r == null ? void 0 : r.preferredDeliveryType), this.partnerGroups = (c = r == null ? void 0 : r.partnerGroups) == null ? void 0 : c.map((m) => new re(m)), this.contact = new qe(r == null ? void 0 : r.contact), this.lastOrder = {
4124
+ createdAt: new k((u = r == null ? void 0 : r.lastOrder) == null ? void 0 : u.createdAt),
4125
+ creator: (p = r == null ? void 0 : r.lastOrder) == null ? void 0 : p.creator,
4126
+ isApproved: (f = r == null ? void 0 : r.lastOrder) == null ? void 0 : f.isApproved
4089
4127
  }, this.isExcludedFromMsCallsToClients = r == null ? void 0 : r.isExcludedFromMsCallsToClients;
4090
4128
  }
4091
4129
  /**
@@ -4116,6 +4154,9 @@ class Qt {
4116
4154
  case "managers":
4117
4155
  this.managers = [];
4118
4156
  break;
4157
+ case "curators":
4158
+ this.curators = [];
4159
+ break;
4119
4160
  case "salesDirections":
4120
4161
  this.salesDirections = [];
4121
4162
  break;
@@ -4129,7 +4170,7 @@ class Qt {
4129
4170
  this.partnerGroups = [];
4130
4171
  break;
4131
4172
  case "contact":
4132
- this.contact = new Ne();
4173
+ this.contact = new qe();
4133
4174
  break;
4134
4175
  default:
4135
4176
  this[r] = void 0;
@@ -4147,11 +4188,11 @@ class Qt {
4147
4188
  return Object.keys(this).forEach((c) => {
4148
4189
  const u = this[c];
4149
4190
  // eslint-disable-next-line prettier/prettier
4150
- D(u) || y(u) && u.trim().length === 0 || de(u.isNewRec) && u.isNewRec() || (r[c] = u);
4191
+ A(u) || C(u) && u.trim().length === 0 || Ue(u.isNewRec) && u.isNewRec() || (r[c] = u);
4151
4192
  }), !((e = r == null ? void 0 : r.createdAt) != null && e.from) && !((s = r == null ? void 0 : r.createdAt) != null && s.to) && delete r.createdAt, !((i = r == null ? void 0 : r.lastLoginDate) != null && i.from) && !((o = r == null ? void 0 : r.lastLoginDate) != null && o.to) && delete r.lastLoginDate, r;
4152
4193
  }
4153
4194
  }
4154
- class Pr extends j {
4195
+ class Ar extends j {
4155
4196
  /**
4156
4197
  * Инициализирует экземпляр класса {@link OrderShortInfo}.
4157
4198
  *
@@ -4171,10 +4212,10 @@ class Pr extends j {
4171
4212
  * Признак того, что заказ подтвержден в 1С.
4172
4213
  */
4173
4214
  t(this, "isApproved1c");
4174
- this.createdAt = y(e == null ? void 0 : e.createdAt) ? w(e.createdAt) : (e == null ? void 0 : e.createdAt) ?? /* @__PURE__ */ new Date(), this.creator = new d(e == null ? void 0 : e.creator), this.isApproved1c = (e == null ? void 0 : e.isApproved1c) ?? !1;
4215
+ this.createdAt = C(e == null ? void 0 : e.createdAt) ? v(e.createdAt) : (e == null ? void 0 : e.createdAt) ?? /* @__PURE__ */ new Date(), this.creator = new U(e == null ? void 0 : e.creator), this.isApproved1c = (e == null ? void 0 : e.isApproved1c) ?? !1;
4175
4216
  }
4176
4217
  }
4177
- class yt extends b {
4218
+ class Ct extends b {
4178
4219
  /**
4179
4220
  * Инициализирует экземпляр класса {@link ClientAdditionalData}.
4180
4221
  *
@@ -4207,10 +4248,10 @@ class yt extends b {
4207
4248
  * Список менеджеров.
4208
4249
  */
4209
4250
  t(this, "managers");
4210
- (s = e.contacts) != null && s.length && (this.contacts = e.contacts.map((o) => new M(o))), e.lastOrder && (this.lastOrder = new Pr(e.lastOrder)), (i = e.partnerGroups) != null && i.length && (this.partnerGroups = e.partnerGroups.map((o) => new re(o))), e.preferredDeliveryType && (this.preferredDeliveryType = new X(e.preferredDeliveryType)), e.salesDirection && (this.salesDirection = new x(e.salesDirection)), e.managers && (this.managers = e.managers.map((o) => new ce(o)));
4251
+ (s = e.contacts) != null && s.length && (this.contacts = e.contacts.map((o) => new M(o))), e.lastOrder && (this.lastOrder = new Ar(e.lastOrder)), (i = e.partnerGroups) != null && i.length && (this.partnerGroups = e.partnerGroups.map((o) => new re(o))), e.preferredDeliveryType && (this.preferredDeliveryType = new X(e.preferredDeliveryType)), e.salesDirection && (this.salesDirection = new x(e.salesDirection)), e.managers && (this.managers = e.managers.map((o) => new ce(o)));
4211
4252
  }
4212
4253
  }
4213
- class wt {
4254
+ class vt {
4214
4255
  /**
4215
4256
  * Инициализирует экземпляр класса {@link DataTablePaginationRequestParams}.
4216
4257
  *
@@ -4228,7 +4269,7 @@ class wt {
4228
4269
  this.page = (r == null ? void 0 : r.page) ?? 1, this.pageSize = (r == null ? void 0 : r.pageSize) ?? 50;
4229
4270
  }
4230
4271
  }
4231
- class Yt extends wt {
4272
+ class Zt extends vt {
4232
4273
  /**
4233
4274
  * Инициализирует экземпляр класса {@link DataTablePagination}.
4234
4275
  *
@@ -4259,7 +4300,7 @@ class Yt extends wt {
4259
4300
  this.itemCount = (e == null ? void 0 : e.itemCount) ?? 0, this.pageCount = (e == null ? void 0 : e.pageCount) ?? 1, this.pageSlot = (e == null ? void 0 : e.pageSlot) ?? 5, this.pageSizes = (e == null ? void 0 : e.pageSizes) ?? [25, 50, 100], this.showSizePicker = (e == null ? void 0 : e.showSizePicker) ?? !0;
4260
4301
  }
4261
4302
  }
4262
- class Xt {
4303
+ class es {
4263
4304
  /**
4264
4305
  * Инициализирует экземпляр класса {@link ISortRequestParams}.
4265
4306
  *
@@ -4307,11 +4348,11 @@ class L extends Te {
4307
4348
  * @param contragent Данные о контрагенте клиента.
4308
4349
  */
4309
4350
  static transformContragentClientDataToRequest(r) {
4310
- var c, u, p, v, R, S, _, O;
4351
+ var c, u, p, f, m, S, _, O;
4311
4352
  let e;
4312
4353
  const s = r, i = r, o = r;
4313
4354
  switch (r.opf.slug) {
4314
- case N.Ic:
4355
+ case q.Ic:
4315
4356
  e = {
4316
4357
  opf: s.opf.slug,
4317
4358
  name: s.name,
@@ -4329,13 +4370,13 @@ class L extends Te {
4329
4370
  actual_address: s.actualAddress
4330
4371
  };
4331
4372
  break;
4332
- case N.UlR:
4373
+ case q.UlR:
4333
4374
  e = {
4334
4375
  opf: i.opf.slug,
4335
4376
  name: i.name,
4336
4377
  alternative_name: i.alternativeName,
4337
4378
  partner_group_id: (p = i.partnerGroup) == null ? void 0 : p.id,
4338
- manager_id: (v = i.manager) == null ? void 0 : v.id,
4379
+ manager_id: (f = i.manager) == null ? void 0 : f.id,
4339
4380
  comment: i.comment,
4340
4381
  inn: i.inn,
4341
4382
  kpp: i.kpp,
@@ -4348,12 +4389,12 @@ class L extends Te {
4348
4389
  actual_address: i.actualAddress
4349
4390
  };
4350
4391
  break;
4351
- case N.UlNr:
4392
+ case q.UlNr:
4352
4393
  e = {
4353
4394
  opf: o.opf.slug,
4354
4395
  name: o.name,
4355
4396
  alternative_name: o.alternativeName,
4356
- partner_group_id: (R = o.partnerGroup) == null ? void 0 : R.id,
4397
+ partner_group_id: (m = o.partnerGroup) == null ? void 0 : m.id,
4357
4398
  manager_id: (S = o.manager) == null ? void 0 : S.id,
4358
4399
  comment: o.comment,
4359
4400
  director_name: o.directorName,
@@ -4422,7 +4463,7 @@ class L extends Te {
4422
4463
  * @see /doc/api/internal#/Клиенты/api_internal_client_get_full_info
4423
4464
  */
4424
4465
  getClient(r) {
4425
- return this.get(`/internal/clients/${r}`, {}, (e) => new Ye(e.data));
4466
+ return this.get(`/internal/clients/${r}`, {}, (e) => new Xe(e.data));
4426
4467
  }
4427
4468
  /**
4428
4469
  * Возвращает данные о клиентах, удовлетворяющих указанным параметрам поиска.
@@ -4450,7 +4491,7 @@ class L extends Te {
4450
4491
  return this.getClientsList({
4451
4492
  groupOp: "and",
4452
4493
  groups: [],
4453
- filters: [{ field: "phone", op: Be.Contains, value: r }]
4494
+ filters: [{ field: "phone", op: Ee.Contains, value: r }]
4454
4495
  });
4455
4496
  }
4456
4497
  /**
@@ -4464,7 +4505,7 @@ class L extends Te {
4464
4505
  const s = r.map((i) => i.id);
4465
4506
  return this.post("/internal/clients/additional-data", { clients: s, requested_data_types: e }, (i) => {
4466
4507
  let o = [];
4467
- return (i == null ? void 0 : i.data.length) > 0 && (o = i.data.map((c) => new yt(c))), o;
4508
+ return (i == null ? void 0 : i.data.length) > 0 && (o = i.data.map((c) => new Ct(c))), o;
4468
4509
  });
4469
4510
  }
4470
4511
  /**
@@ -4476,7 +4517,7 @@ class L extends Te {
4476
4517
  getAllClientContacts(r) {
4477
4518
  return this.get(`/internal/clients/${r}/contacts/all`, {}, (e) => {
4478
4519
  let s = [];
4479
- return (e == null ? void 0 : e.data.length) > 0 && (s = e.data.map((i) => new ft(i))), s;
4520
+ return (e == null ? void 0 : e.data.length) > 0 && (s = e.data.map((i) => new wt(i))), s;
4480
4521
  });
4481
4522
  }
4482
4523
  /**
@@ -4487,7 +4528,7 @@ class L extends Te {
4487
4528
  * @see /doc/api/internal#/Клиенты/api_internal_client_create
4488
4529
  */
4489
4530
  createClientCommonData(r, e = {}) {
4490
- return this.post("/internal/clients", L.transformClientDataToRequest(r), (s) => new Ye(s.data), e);
4531
+ return this.post("/internal/clients", L.transformClientDataToRequest(r), (s) => new Xe(s.data), e);
4491
4532
  }
4492
4533
  /**
4493
4534
  * Обновляет данные указанного клиента.
@@ -4575,6 +4616,47 @@ class L extends Te {
4575
4616
  const s = e.map((i) => this.patch(`/internal/clients/${r}/managers/${i.id}/detach`));
4576
4617
  await Promise.all(s);
4577
4618
  }
4619
+ /**
4620
+ * Закрепляет клиента за указанным куратором.
4621
+ *
4622
+ * @param clientId Идентификатор клиента, которого необходимо закрепить за куратором.
4623
+ * @param curatorId Идентификатор куратора, за которого необходимо закрепить клиента.
4624
+ * @param curatedDirection Направление кураторства.
4625
+ *
4626
+ * @see /doc/api/internal#/Клиенты/api_internal_client_curator_attach
4627
+ */
4628
+ attachToCurator(r, e, s) {
4629
+ return this.patch(`/internal/clients/${r}/curators/${e}/attach`, { curated_direction_id: s.id });
4630
+ }
4631
+ /**
4632
+ * Открепляет клиента от указанного куратора.
4633
+ *
4634
+ * @param clientId Идентификатор клиента, которого необходимо открепить от куратора.
4635
+ * @param curatorId Идентификатор куратора, от которого необходимо открепить клиента.
4636
+ * @param curatedDirection Направление кураторства.
4637
+ *
4638
+ * @see /doc/api/internal#/Клиенты/api_internal_client_curator_detach
4639
+ */
4640
+ detachFromCurator(r, e, s) {
4641
+ return this.patch(`/internal/clients/${r}/curators/${e}/detach`, { curated_direction_id: s.id });
4642
+ }
4643
+ /**
4644
+ * Устанавливает кураторов для указанного клиента.
4645
+ * При этом все ранее установленные кураторы будут удалены.
4646
+ *
4647
+ * @param clientId Идентификатор клиента, для которого необходимо установить кураторов.
4648
+ * @param curators Список данных о кураторах.
4649
+ *
4650
+ * @see /doc/api/internal#/Клиенты/api_internal_client_curator_update_list
4651
+ */
4652
+ setCurators(r, e) {
4653
+ return this.patch(`/internal/clients/${r}/curators`, {
4654
+ curators: e.map((s) => ({
4655
+ curator_id: s.curatorId,
4656
+ curated_direction_id: s.curatedDirection.id
4657
+ }))
4658
+ });
4659
+ }
4578
4660
  /**
4579
4661
  * Создаёт нового контрагента клиента.
4580
4662
  *
@@ -4672,7 +4754,7 @@ class L extends Te {
4672
4754
  return this.post(
4673
4755
  `/internal/clients/${r}/contragents/${e}/bank-accounts`,
4674
4756
  L.transformClientContragentBankAccountToRequest(s),
4675
- (o) => new qe(o.data),
4757
+ (o) => new de(o.data),
4676
4758
  i
4677
4759
  );
4678
4760
  }
@@ -4689,7 +4771,7 @@ class L extends Te {
4689
4771
  return this.patch(
4690
4772
  `/internal/clients/${r}/contragents/${e}/bank-accounts/${s.id}`,
4691
4773
  L.transformClientContragentBankAccountToRequest(s),
4692
- (o) => new qe(o.data),
4774
+ (o) => new de(o.data),
4693
4775
  i
4694
4776
  );
4695
4777
  }
@@ -4943,7 +5025,7 @@ const V = class V extends h {
4943
5025
  */
4944
5026
  cacheResponse(e, s) {
4945
5027
  V.responseDataCache.set(e, {
4946
- validTo: kr(/* @__PURE__ */ new Date(), this.responseDataCacheTimeout),
5028
+ validTo: dr(/* @__PURE__ */ new Date(), this.responseDataCacheTimeout),
4947
5029
  val: s
4948
5030
  });
4949
5031
  }
@@ -4960,8 +5042,8 @@ const V = class V extends h {
4960
5042
  getTypedDataArrayRequester(e, s, i = !1, o = {}) {
4961
5043
  const c = s + (Y(o) ? "" : ` >>> ${JSON.stringify(o)}`), u = i ? V.getCachedResponse(c) : void 0;
4962
5044
  return u ? Promise.resolve(u) : this.get(s, o).then((p) => {
4963
- const v = p.map((R) => je.instanceInitializer(e, R));
4964
- return i && v && this.cacheResponse(s, v), v;
5045
+ const f = p.map((m) => je.instanceInitializer(e, m));
5046
+ return i && f && this.cacheResponse(s, f), f;
4965
5047
  });
4966
5048
  }
4967
5049
  };
@@ -4970,7 +5052,7 @@ const V = class V extends h {
4970
5052
  */
4971
5053
  t(V, "responseDataCache", /* @__PURE__ */ new Map());
4972
5054
  let pe = V;
4973
- class Zt extends h {
5055
+ class rs extends h {
4974
5056
  /**
4975
5057
  * Выполняет проверку занят ли указанный номер телефона.
4976
5058
  *
@@ -4984,7 +5066,7 @@ class Zt extends h {
4984
5066
  });
4985
5067
  }
4986
5068
  }
4987
- class es extends h {
5069
+ class ts extends h {
4988
5070
  /**
4989
5071
  * Возвращает настройки указанного конфигуратора для указанной категории.
4990
5072
  *
@@ -5055,18 +5137,18 @@ class es extends h {
5055
5137
  return this.delete(`internal/catalog/categories/${r.id}/configurators/${(s = r.properties) == null ? void 0 : s.configurator}/template/${e}`);
5056
5138
  }
5057
5139
  }
5058
- class rs {
5140
+ class ss {
5059
5141
  /**
5060
5142
  * Возвращает диапазон дат по умолчанию.
5061
5143
  */
5062
5144
  static defaultDateRanges() {
5063
- const r = _r(/* @__PURE__ */ new Date(), 1);
5145
+ const r = qr(/* @__PURE__ */ new Date(), 1);
5064
5146
  return {
5065
5147
  // 'Следующий рабочий день' - это значение по-умолчанию
5066
- nextWorkingDay: { label: "Следующий рабочий день", from: Mr(r), to: Fr(r) },
5067
- today: { label: "Сегодня", from: _e(), to: dr() },
5068
- yesterday: { label: "Вчера", from: Ur(), to: Nr() },
5069
- tomorrow: { label: "Завтра", from: qr(), to: Or() }
5148
+ nextWorkingDay: { label: "Следующий рабочий день", from: Hr(r), to: Gr(r) },
5149
+ today: { label: "Сегодня", from: _e(), to: jr() },
5150
+ yesterday: { label: "Вчера", from: Mr(), to: Fr() },
5151
+ tomorrow: { label: "Завтра", from: Ur(), to: Nr() }
5070
5152
  };
5071
5153
  }
5072
5154
  }
@@ -5110,13 +5192,13 @@ const K = class K {
5110
5192
  * Список единиц измерения линейной величины.
5111
5193
  */
5112
5194
  t(K, "linearValues", ["пог.м.", "м.", "м2"]);
5113
- let Xe = K;
5114
- class ts {
5195
+ let Ze = K;
5196
+ class is {
5115
5197
  /**
5116
5198
  * Генерирует и возвращает данные-заглушку неопределённого менеджера.
5117
5199
  */
5118
5200
  static generateUndefinedManagerInstance() {
5119
- return new De({ id: 0, name: "- Не назначен -", isActive: !0, guid: "-undefined-" });
5201
+ return new Ae({ id: 0, name: "- Не назначен -", isActive: !0, guid: "-undefined-" });
5120
5202
  }
5121
5203
  /**
5122
5204
  * Выполняет проверку, является ли указанная запись записью-заглушкой с данными о неопределённом менеджере.
@@ -5127,7 +5209,7 @@ class ts {
5127
5209
  return r.id === 0 && r.guid === "-undefined-";
5128
5210
  }
5129
5211
  }
5130
- class Ct extends pe {
5212
+ class Pt extends pe {
5131
5213
  /**
5132
5214
  * Возвращает {@link Promise} для получения справочника списка менеджеров.
5133
5215
  */
@@ -5135,18 +5217,18 @@ class Ct extends pe {
5135
5217
  const r = "/internal/managers", e = pe.getCachedResponse(r);
5136
5218
  if (e)
5137
5219
  return e;
5138
- const i = (await this.get(r)).data.map((o) => je.instanceInitializer(De, o));
5220
+ const i = (await this.get(r)).data.map((o) => je.instanceInitializer(Ae, o));
5139
5221
  return this.cacheResponse(r, i), i;
5140
5222
  }
5141
5223
  }
5142
- class Rr extends Pr {
5224
+ class Tr extends Ar {
5143
5225
  /**
5144
5226
  * Инициализирует экземпляр класса {@link OrderInfo}.
5145
5227
  *
5146
5228
  * @param data Данные для первоначальной инициализации.
5147
5229
  */
5148
5230
  constructor(e) {
5149
- var s, i, o, c, u, p, v, R;
5231
+ var s, i, o, c, u, p, f, m;
5150
5232
  super(e);
5151
5233
  /**
5152
5234
  * Краткие данные о клиенте.
@@ -5194,13 +5276,13 @@ class Rr extends Pr {
5194
5276
  onlinePaymentLink: (o = e == null ? void 0 : e.payment) == null ? void 0 : o.onlinePaymentLink
5195
5277
  }, this.delivery = {
5196
5278
  type: ((c = e == null ? void 0 : e.delivery) == null ? void 0 : c.type) ?? -1,
5197
- date: y((u = e == null ? void 0 : e.delivery) == null ? void 0 : u.date) ? w(e.delivery.date) : ((p = e == null ? void 0 : e.delivery) == null ? void 0 : p.date) ?? /* @__PURE__ */ new Date(),
5198
- address: (v = e == null ? void 0 : e.delivery) != null && v.address ? new Pe(e.delivery.address) : void 0,
5199
- warehouse: (R = e == null ? void 0 : e.delivery) != null && R.warehouse ? new Ae(e.delivery.warehouse) : void 0
5200
- }, this.attachedUser = new d(e == null ? void 0 : e.attachedUser), this.status = (e == null ? void 0 : e.status) ?? 0, this.salesDirection = new x(e == null ? void 0 : e.salesDirection), this.pendingAt = y(e == null ? void 0 : e.pendingAt) ? w(e.pendingAt) : e == null ? void 0 : e.pendingAt, this.processedAt = y(e == null ? void 0 : e.processedAt) ? w(e.processedAt) : e == null ? void 0 : e.processedAt, this.isOnOrder = (e == null ? void 0 : e.isOnOrder) ?? !1, this.isNotInStock = (e == null ? void 0 : e.isNotInStock) ?? !1;
5279
+ date: C((u = e == null ? void 0 : e.delivery) == null ? void 0 : u.date) ? v(e.delivery.date) : ((p = e == null ? void 0 : e.delivery) == null ? void 0 : p.date) ?? /* @__PURE__ */ new Date(),
5280
+ address: (f = e == null ? void 0 : e.delivery) != null && f.address ? new Pe(e.delivery.address) : void 0,
5281
+ warehouse: (m = e == null ? void 0 : e.delivery) != null && m.warehouse ? new De(e.delivery.warehouse) : void 0
5282
+ }, this.attachedUser = new U(e == null ? void 0 : e.attachedUser), this.status = (e == null ? void 0 : e.status) ?? 0, this.salesDirection = new x(e == null ? void 0 : e.salesDirection), this.pendingAt = C(e == null ? void 0 : e.pendingAt) ? v(e.pendingAt) : e == null ? void 0 : e.pendingAt, this.processedAt = C(e == null ? void 0 : e.processedAt) ? v(e.processedAt) : e == null ? void 0 : e.processedAt, this.isOnOrder = (e == null ? void 0 : e.isOnOrder) ?? !1, this.isNotInStock = (e == null ? void 0 : e.isNotInStock) ?? !1;
5201
5283
  }
5202
5284
  }
5203
- class vt extends j {
5285
+ class Rt extends j {
5204
5286
  /**
5205
5287
  * Инициализирует экземпляр класса {@link OrderProduct}.
5206
5288
  *
@@ -5283,7 +5365,7 @@ class vt extends j {
5283
5365
  this.product = new Z(e.product), this.quantity = e.quantity, this.currency = e.currency, this.costOne = e.costOne, this.costOneRub = e.costOneRub, this.cost = e.cost, this.costRub = e.costRub, this.marker = e.marker, this.height = e.height, this.length = e.length, this.width = e.width, this.logicGroupId = e.logicGroupId, this.salesDirection = e.salesDirection, this.specificationImgUrl = e.specificationImgUrl, this.configurator = e.configurator, this.configuratorParams = e.configuratorParams, this.sawing = e.sawing;
5284
5366
  }
5285
5367
  }
5286
- class Pt extends Rr {
5368
+ class Dt extends Tr {
5287
5369
  /**
5288
5370
  * Инициализирует экземпляр класса {@link Order}.
5289
5371
  *
@@ -5323,10 +5405,10 @@ class Pt extends Rr {
5323
5405
  * Признак, что разрешена передача заказа в работу без оплаты.
5324
5406
  */
5325
5407
  t(this, "isAllowProcessingWithoutPayment");
5326
- this.products = (e.products ?? []).map((s) => new vt(s)), this.invoices = e.invoices ?? [], this.comment = e.comment, this.image = e.image, this.contragent = e.contragent ? ve.createInstance(e.contragent) : void 0, this.barcode = e.barcode, this.orderSource = e.orderSource ? new C(e.orderSource) : void 0, this.isAllowProcessingWithoutPayment = e.isAllowProcessingWithoutPayment;
5408
+ this.products = (e.products ?? []).map((s) => new Rt(s)), this.invoices = e.invoices ?? [], this.comment = e.comment, this.image = e.image, this.contragent = e.contragent ? ve.createInstance(e.contragent) : void 0, this.barcode = e.barcode, this.orderSource = e.orderSource ? new P(e.orderSource) : void 0, this.isAllowProcessingWithoutPayment = e.isAllowProcessingWithoutPayment;
5327
5409
  }
5328
5410
  }
5329
- class ss extends Te {
5411
+ class ns extends Te {
5330
5412
  /**
5331
5413
  * Возвращает данные о заказах, удовлетворяющих указанным параметрам поиска.
5332
5414
  *
@@ -5339,7 +5421,7 @@ class ss extends Te {
5339
5421
  getOrders(r, e, s) {
5340
5422
  return this.getPaginated("/internal/orders", r, e ? [e] : void 0, s, {}, (i) => {
5341
5423
  const o = { ...i.data };
5342
- return o.data = o.data.map((c) => new Rr(c)), o;
5424
+ return o.data = o.data.map((c) => new Tr(c)), o;
5343
5425
  });
5344
5426
  }
5345
5427
  /**
@@ -5357,7 +5439,7 @@ class ss extends Te {
5357
5439
  * @param orderId Идентификатор заказа для которого необходимо вернуть данные.
5358
5440
  */
5359
5441
  getOrder(r) {
5360
- return this.get(`/internal/orders/${r}`, {}, (e) => new Pt(e.data));
5442
+ return this.get(`/internal/orders/${r}`, {}, (e) => new Dt(e.data));
5361
5443
  }
5362
5444
  }
5363
5445
  class xe {
@@ -5392,7 +5474,7 @@ class xe {
5392
5474
  }
5393
5475
  const Le = (n) => {
5394
5476
  var r, e, s, i, o;
5395
- return n ? ir(
5477
+ return n ? nr(
5396
5478
  {
5397
5479
  cities: (r = n.cities) == null ? void 0 : r.map((c) => c.id),
5398
5480
  clients: (e = n.clients) == null ? void 0 : e.map((c) => c.id),
@@ -5401,13 +5483,13 @@ const Le = (n) => {
5401
5483
  salesDirections: (o = n.salesDirections) == null ? void 0 : o.map((c) => c.id),
5402
5484
  hideNotActive: n.hideNotActive
5403
5485
  },
5404
- (c) => D(c) || (Q(c) || nr(c)) && Y(c)
5486
+ (c) => A(c) || (Q(c) || or(c)) && Y(c)
5405
5487
  ) : {};
5406
- }, Ze = (n) => {
5488
+ }, er = (n) => {
5407
5489
  const r = {};
5408
5490
  return n.from && (n.from.coefficient || n.from.value) && (r.from = {}, n.from.coefficient && (r.from.priceCoefficientId = n.from.coefficient.id), n.from.value && (r.from.increasePercent = n.from.value)), n.to && (n.to.coefficient || n.to.value) && (r.to = {}, n.to.coefficient && (r.to.priceCoefficientId = n.to.coefficient.id), n.to.value && (r.to.increasePercent = n.to.value)), r;
5409
5491
  };
5410
- class is extends h {
5492
+ class os extends h {
5411
5493
  /**
5412
5494
  * Возвращает список клиентских цен на продукты в указанном диапазоне цены.
5413
5495
  *
@@ -5421,7 +5503,7 @@ class is extends h {
5421
5503
  return this.get(
5422
5504
  `/internal/price/products/${r}/analyze`,
5423
5505
  {
5424
- ...Ze(e),
5506
+ ...er(e),
5425
5507
  filters: Le(s)
5426
5508
  },
5427
5509
  (i) => i.data.map((o) => new xe(o))
@@ -5440,7 +5522,7 @@ class is extends h {
5440
5522
  return this.get(
5441
5523
  `/internal/price/categories/${r}/analyze`,
5442
5524
  {
5443
- ...Ze(e),
5525
+ ...er(e),
5444
5526
  filters: Le(s)
5445
5527
  },
5446
5528
  (i) => i.data.map((o) => new xe(o))
@@ -5468,7 +5550,7 @@ class is extends h {
5468
5550
  );
5469
5551
  }
5470
5552
  }
5471
- class Rt {
5553
+ class At {
5472
5554
  /**
5473
5555
  * Инициализирует экземпляр класса {@link PriceHistoryItem}.
5474
5556
  *
@@ -5515,10 +5597,10 @@ class Rt {
5515
5597
  * @inheritDoc
5516
5598
  */
5517
5599
  t(this, "currency");
5518
- this.cost = r.cost ?? 0, this.isLowCost = r.isLowCost ?? !1, this.isRetail = r.isRetail ?? !1, this.costDate = y(r.costDate) ? w(r.costDate) : r.costDate ?? /* @__PURE__ */ new Date(), this.discountName = r.discountName, this.priceTemplateName = r.priceTemplateName, this.product = r.product ? new oe(r.product) : void 0, this.client = r.client ? new d(r.client) : void 0, this.executor = r.executor ? new d(r.executor) : void 0, this.currency = r.currency ? new Ce(r.currency) : void 0;
5600
+ this.cost = r.cost ?? 0, this.isLowCost = r.isLowCost ?? !1, this.isRetail = r.isRetail ?? !1, this.costDate = C(r.costDate) ? v(r.costDate) : r.costDate ?? /* @__PURE__ */ new Date(), this.discountName = r.discountName, this.priceTemplateName = r.priceTemplateName, this.product = r.product ? new oe(r.product) : void 0, this.client = r.client ? new U(r.client) : void 0, this.executor = r.executor ? new U(r.executor) : void 0, this.currency = r.currency ? new Ce(r.currency) : void 0;
5519
5601
  }
5520
5602
  }
5521
- class At extends oe {
5603
+ class Tt extends oe {
5522
5604
  /**
5523
5605
  * Инициализирует экземпляр класса {@link ProductPriceHistory}.
5524
5606
  *
@@ -5530,10 +5612,10 @@ class At extends oe {
5530
5612
  * @inheritDoc
5531
5613
  */
5532
5614
  t(this, "history");
5533
- this.history = he(e.history, (s) => new Rt(s));
5615
+ this.history = he(e.history, (s) => new At(s));
5534
5616
  }
5535
5617
  }
5536
- class ns extends h {
5618
+ class cs extends h {
5537
5619
  /**
5538
5620
  * Инициализирует экземпляр класса {@link UserAuthDataProvider}.
5539
5621
  */
@@ -5549,19 +5631,19 @@ class ns extends h {
5549
5631
  */
5550
5632
  getProductPriceHistory(r) {
5551
5633
  var i, o, c, u;
5552
- const e = T.getConfig().dateFormats.api, s = ir(
5553
- Ue(r, {
5634
+ const e = T.getConfig().dateFormats.api, s = nr(
5635
+ Ne(r, {
5554
5636
  costDate: {
5555
- from: ke((i = r.costDate) == null ? void 0 : i.from) ? q(r.costDate.from, e) : (o = r.costDate) == null ? void 0 : o.from,
5556
- to: ke((c = r.costDate) == null ? void 0 : c.to) ? q(r.costDate.to, e) : (u = r.costDate) == null ? void 0 : u.to
5637
+ from: ke((i = r.costDate) == null ? void 0 : i.from) ? d(r.costDate.from, e) : (o = r.costDate) == null ? void 0 : o.from,
5638
+ to: ke((c = r.costDate) == null ? void 0 : c.to) ? d(r.costDate.to, e) : (u = r.costDate) == null ? void 0 : u.to
5557
5639
  }
5558
5640
  }),
5559
- (p) => D(p) || (Q(p) || nr(p)) && Y(p)
5641
+ (p) => A(p) || (Q(p) || or(p)) && Y(p)
5560
5642
  );
5561
- return this.get("/internal/history", s, (p) => he(p.data, (v) => new At(v)));
5643
+ return this.get("/internal/history", s, (p) => he(p.data, (f) => new Tt(f)));
5562
5644
  }
5563
5645
  }
5564
- class er {
5646
+ class rr {
5565
5647
  /**
5566
5648
  * Инициализирует экземпляр класса {@link RecommendationsList}.
5567
5649
  *
@@ -5579,7 +5661,7 @@ class er {
5579
5661
  r != null && r.products && (this.products = r.products.map((e) => new oe(e))), r != null && r.productCategories && (this.productCategories = r.productCategories.map((e) => new oe(e)));
5580
5662
  }
5581
5663
  }
5582
- class os extends h {
5664
+ class ls extends h {
5583
5665
  /**
5584
5666
  * Инициализирует экземпляр класса {@link UserAuthDataProvider}.
5585
5667
  */
@@ -5593,7 +5675,7 @@ class os extends h {
5593
5675
  * @see /docs/api#/operations/api_internal_recommendations_product_category_get
5594
5676
  */
5595
5677
  getProductCategoryRecommendations(r) {
5596
- return this.get(`/internal/recommendations/categories/${r.id}`, {}, (e) => new er(e.data));
5678
+ return this.get(`/internal/recommendations/categories/${r.id}`, {}, (e) => new rr(e.data));
5597
5679
  }
5598
5680
  /**
5599
5681
  * Возвращает данные о рекомендациях указанного продукта.
@@ -5602,7 +5684,7 @@ class os extends h {
5602
5684
  * @see /docs/api#/operations/api_internal_recommendations_product_get
5603
5685
  */
5604
5686
  getProductRecommendations(r) {
5605
- return this.get(`/internal/recommendations/products/${r.id}`, {}, (e) => new er(e.data));
5687
+ return this.get(`/internal/recommendations/products/${r.id}`, {}, (e) => new rr(e.data));
5606
5688
  }
5607
5689
  /**
5608
5690
  * Выполняет сохранение данных о рекомендуемых категориях продуктов.
@@ -5640,20 +5722,26 @@ class $ extends pe {
5640
5722
  * и использовать в случае аналогичных запросов.
5641
5723
  */
5642
5724
  getReference(r, e = !1) {
5643
- return this.getTypedDataArrayRequester(ot, `/internal/references/${r}`, e);
5725
+ return this.getTypedDataArrayRequester(lt, `/internal/references/${r}`, e);
5644
5726
  }
5645
5727
  /**
5646
5728
  * Возвращает {@link Promise} для получения справочника данных о канале
5647
5729
  * первичного интереса.
5648
5730
  */
5649
5731
  getChannelPrimaryInterest() {
5650
- return this.getTypedDataArrayRequester(mr, "/internal/references/channel-primary-interest", !0);
5732
+ return this.getTypedDataArrayRequester(wr, "/internal/references/channel-primary-interest", !0);
5651
5733
  }
5652
5734
  /**
5653
5735
  * Возвращает {@link Promise} для получения справочника должностей контактных лиц.
5654
5736
  */
5655
5737
  getContactPositions() {
5656
- return this.getTypedDataArrayRequester(ct, "/internal/references/contact-position", !0);
5738
+ return this.getTypedDataArrayRequester(ut, "/internal/references/contact-position", !0);
5739
+ }
5740
+ /**
5741
+ * Возвращает {@link Promise} для получения справочника списка направлений кураторства.
5742
+ */
5743
+ getCuratedDirection() {
5744
+ return this.getTypedDataArrayRequester(He, "/internal/references/curated-direction", !0);
5657
5745
  }
5658
5746
  /**
5659
5747
  * Возвращает {@link Promise} для получения справочника списка валют.
@@ -5678,25 +5766,25 @@ class $ extends pe {
5678
5766
  * Возвращает {@link Promise} для получения справочника данных статусов оплаты заказов.
5679
5767
  */
5680
5768
  getOrderPaymentStatuses() {
5681
- return this.getTypedDataArrayRequester(lt, "/public/references/order-payment-status", !0);
5769
+ return this.getTypedDataArrayRequester(pt, "/public/references/order-payment-status", !0);
5682
5770
  }
5683
5771
  /**
5684
5772
  * Возвращает {@link Promise} для получения справочника данных статусов заказов.
5685
5773
  */
5686
5774
  getOrderStatuses() {
5687
- return this.getTypedDataArrayRequester(ut, "/public/references/order-status", !0);
5775
+ return this.getTypedDataArrayRequester(ht, "/public/references/order-status", !0);
5688
5776
  }
5689
5777
  /**
5690
5778
  * Возвращает {@link Promise} для получения справочника данных типов оплаты заказов.
5691
5779
  */
5692
5780
  getPaymentTypes() {
5693
- return this.getTypedDataArrayRequester(pt, "/public/references/payment-type", !0);
5781
+ return this.getTypedDataArrayRequester(gt, "/public/references/payment-type", !0);
5694
5782
  }
5695
5783
  /**
5696
5784
  * Возвращает {@link Promise} для получения справочника типов ресурсов.
5697
5785
  */
5698
5786
  getResourceTypes() {
5699
- return this.getTypedDataArrayRequester(fr, "/internal/references/resource-type", !0);
5787
+ return this.getTypedDataArrayRequester(Cr, "/internal/references/resource-type", !0);
5700
5788
  }
5701
5789
  /**
5702
5790
  * Возвращает {@link Promise} для получения справочника данных направлений продаж.
@@ -5708,7 +5796,7 @@ class $ extends pe {
5708
5796
  * Возвращает {@link Promise} для получения справочника данных об источнике первичного интереса.
5709
5797
  */
5710
5798
  getSourcePrimaryInterest() {
5711
- return this.getTypedDataArrayRequester(yr, "/internal/references/source-primary-interest", !0);
5799
+ return this.getTypedDataArrayRequester(vr, "/internal/references/source-primary-interest", !0);
5712
5800
  }
5713
5801
  /**
5714
5802
  * Выполняет поиск данных о городах по терму в названии.
@@ -5716,7 +5804,7 @@ class $ extends pe {
5716
5804
  * @param term Терм поиска.
5717
5805
  */
5718
5806
  searchCity(r) {
5719
- return this.getTypedDataArrayRequester(He, `/internal/references/city-with-region-and-country/search?term=${r}`);
5807
+ return this.getTypedDataArrayRequester(Be, `/internal/references/city-with-region-and-country/search?term=${r}`);
5720
5808
  }
5721
5809
  /**
5722
5810
  * Выполняет поиск данных о регионах по терму в названии.
@@ -5744,13 +5832,13 @@ class $ extends pe {
5744
5832
  * Возвращает {@link Promise} для получения справочника складов.
5745
5833
  */
5746
5834
  getWarehouses() {
5747
- return this.getTypedDataArrayRequester(Ae, "/public/references/warehouse", !0);
5835
+ return this.getTypedDataArrayRequester(De, "/public/references/warehouse", !0);
5748
5836
  }
5749
5837
  /**
5750
5838
  * Возвращает {@link Promise} для получения справочника типов свойств.
5751
5839
  */
5752
5840
  getPropertyTypes() {
5753
- return this.getTypedDataArrayRequester(gr, "/internal/references/property-type", !0);
5841
+ return this.getTypedDataArrayRequester(yr, "/internal/references/property-type", !0);
5754
5842
  }
5755
5843
  /**
5756
5844
  * Возвращает {@link Promise} для получения справочника коэффициентов цен.
@@ -5762,11 +5850,11 @@ class $ extends pe {
5762
5850
  * Возвращает {@link Promise} для получения справочника типов файлов продуктов/категорий.
5763
5851
  */
5764
5852
  getProductFileType() {
5765
- return this.getTypedDataArrayRequester(ht, "/public/references/product-file-type", !0);
5853
+ return this.getTypedDataArrayRequester(mt, "/public/references/product-file-type", !0);
5766
5854
  }
5767
5855
  }
5768
- const A = te("__references_private", () => {
5769
- const n = m({}), r = m(void 0), e = m(void 0), s = m(void 0), i = m(void 0), o = m(void 0), c = m(void 0), u = m(void 0), p = m(void 0), v = m(void 0), R = m(void 0), S = m(void 0), _ = m(void 0), O = m(void 0), G = m(void 0), H = m(void 0), $e = m(void 0), l = m(void 0);
5856
+ const D = te("__references_private", () => {
5857
+ const n = y({}), r = y(void 0), e = y(void 0), s = y(void 0), i = y(void 0), o = y(void 0), c = y(void 0), u = y(void 0), p = y(void 0), f = y(void 0), m = y(void 0), S = y(void 0), _ = y(void 0), O = y(void 0), G = y(void 0), H = y(void 0), $e = y(void 0), l = y(void 0);
5770
5858
  return {
5771
5859
  /**
5772
5860
  * Список загружаемых/загруженных на данный момент значений.
@@ -5807,11 +5895,11 @@ const A = te("__references_private", () => {
5807
5895
  /**
5808
5896
  * Справочник типов оплаты заказов.
5809
5897
  */
5810
- paymentTypeReference: v,
5898
+ paymentTypeReference: f,
5811
5899
  /**
5812
5900
  * Справочник групп партнеров.
5813
5901
  */
5814
- partnerGroupReference: R,
5902
+ partnerGroupReference: m,
5815
5903
  /**
5816
5904
  * Справочник типов файлов продукктов/категорий.
5817
5905
  */
@@ -5841,92 +5929,92 @@ const A = te("__references_private", () => {
5841
5929
  */
5842
5930
  priceCoefficientsReference: l
5843
5931
  };
5844
- }), cs = te("references", () => {
5845
- const n = P(() => {
5846
- const l = A();
5932
+ }), us = te("references", () => {
5933
+ const n = R(() => {
5934
+ const l = D();
5847
5935
  return !l.channelPrimaryInterestReference && !l.dataLoaderList.channelPrimaryInterestReference && (l.dataLoaderList.channelPrimaryInterestReference = !0, h.getInstance($).getChannelPrimaryInterest().then((g) => {
5848
5936
  l.channelPrimaryInterestReference = g;
5849
- }).catch(f)), l.channelPrimaryInterestReference;
5850
- }), r = P(() => {
5851
- const l = A();
5937
+ }).catch(w)), l.channelPrimaryInterestReference;
5938
+ }), r = R(() => {
5939
+ const l = D();
5852
5940
  return !l.contactPositionsReference && !l.dataLoaderList.contactPositionsReference && (l.dataLoaderList.contactPositionsReference = !0, h.getInstance($).getContactPositions().then((g) => {
5853
5941
  l.contactPositionsReference = g;
5854
- }).catch(f)), l.contactPositionsReference;
5855
- }), e = P(() => {
5856
- const l = A();
5942
+ }).catch(w)), l.contactPositionsReference;
5943
+ }), e = R(() => {
5944
+ const l = D();
5857
5945
  return !l.currencyReference && !l.dataLoaderList.currencyReference && (l.dataLoaderList.currencyReference = !0, h.getInstance($).getCurrency().then((g) => {
5858
5946
  l.currencyReference = g;
5859
- }).catch(f)), l.currencyReference;
5860
- }), s = P(() => {
5861
- const l = A();
5947
+ }).catch(w)), l.currencyReference;
5948
+ }), s = R(() => {
5949
+ const l = D();
5862
5950
  return !l.opfReference && !l.dataLoaderList.opfReference && (l.dataLoaderList.opfReference = !0, h.getInstance($).getOpf().then((g) => {
5863
5951
  l.opfReference = g;
5864
- }).catch(f)), l.opfReference;
5865
- }), i = P(() => {
5866
- const l = A();
5952
+ }).catch(w)), l.opfReference;
5953
+ }), i = R(() => {
5954
+ const l = D();
5867
5955
  return !l.orderPaymentStatusReference && !l.dataLoaderList.orderPaymentStatusReference && (l.dataLoaderList.orderPaymentStatusReference = !0, h.getInstance($).getOrderPaymentStatuses().then((g) => {
5868
5956
  l.orderPaymentStatusReference = g;
5869
- }).catch(f)), l.orderPaymentStatusReference;
5870
- }), o = P(() => {
5871
- const l = A();
5957
+ }).catch(w)), l.orderPaymentStatusReference;
5958
+ }), o = R(() => {
5959
+ const l = D();
5872
5960
  return !l.orderStatusReference && !l.dataLoaderList.orderStatusReference && (l.dataLoaderList.orderStatusReference = !0, h.getInstance($).getOrderStatuses().then((g) => {
5873
5961
  l.orderStatusReference = g;
5874
- }).catch(f)), l.orderStatusReference;
5875
- }), c = P(() => {
5876
- const l = A();
5962
+ }).catch(w)), l.orderStatusReference;
5963
+ }), c = R(() => {
5964
+ const l = D();
5877
5965
  return !l.paymentTypeReference && !l.dataLoaderList.paymentTypeReference && (l.dataLoaderList.paymentTypeReference = !0, h.getInstance($).getPaymentTypes().then((g) => {
5878
5966
  l.paymentTypeReference = g;
5879
- }).catch(f)), l.paymentTypeReference;
5880
- }), u = P(() => {
5881
- const l = A();
5967
+ }).catch(w)), l.paymentTypeReference;
5968
+ }), u = R(() => {
5969
+ const l = D();
5882
5970
  return !l.partnerGroupReference && !l.dataLoaderList.partnerGroupReference && (l.dataLoaderList.partnerGroupReference = !0, h.getInstance($).getPartnerGroup().then((g) => {
5883
5971
  l.partnerGroupReference = g;
5884
- }).catch(f)), l.partnerGroupReference;
5885
- }), p = P(() => {
5886
- const l = A();
5972
+ }).catch(w)), l.partnerGroupReference;
5973
+ }), p = R(() => {
5974
+ const l = D();
5887
5975
  return !l.productFileTypeReference && !l.dataLoaderList.productFileTypeReference && (l.dataLoaderList.productFileTypeReference = !0, h.getInstance($).getProductFileType().then((g) => {
5888
5976
  l.productFileTypeReference = g;
5889
- }).catch(f)), l.productFileTypeReference;
5890
- }), v = P(() => {
5891
- const l = A();
5977
+ }).catch(w)), l.productFileTypeReference;
5978
+ }), f = R(() => {
5979
+ const l = D();
5892
5980
  return !l.resourceTypesReference && !l.dataLoaderList.resourceTypesReference && (l.dataLoaderList.resourceTypesReference = !0, h.getInstance($).getResourceTypes().then((g) => {
5893
5981
  l.resourceTypesReference = g;
5894
- }).catch(f)), l.resourceTypesReference;
5895
- }), R = P(() => {
5896
- const l = A();
5982
+ }).catch(w)), l.resourceTypesReference;
5983
+ }), m = R(() => {
5984
+ const l = D();
5897
5985
  return !l.salesDirectionsReference && !l.dataLoaderList.salesDirectionsReference && (l.dataLoaderList.salesDirectionsReference = !0, h.getInstance($).getSalesDirections().then((g) => {
5898
5986
  l.salesDirectionsReference = g;
5899
- }).catch(f)), l.salesDirectionsReference;
5900
- }), S = P(() => {
5901
- const l = A();
5987
+ }).catch(w)), l.salesDirectionsReference;
5988
+ }), S = R(() => {
5989
+ const l = D();
5902
5990
  return !l.sourcePrimaryInterestReference && !l.dataLoaderList.sourcePrimaryInterestReference && (l.dataLoaderList.sourcePrimaryInterestReference = !0, h.getInstance($).getSourcePrimaryInterest().then((g) => {
5903
5991
  l.sourcePrimaryInterestReference = g;
5904
- }).catch(f)), l.sourcePrimaryInterestReference;
5905
- }), _ = P(() => {
5906
- const l = A();
5992
+ }).catch(w)), l.sourcePrimaryInterestReference;
5993
+ }), _ = R(() => {
5994
+ const l = D();
5907
5995
  return !l.deliveryTypeReference && !l.dataLoaderList.deliveryTypeReference && (l.dataLoaderList.deliveryTypeReference = !0, h.getInstance($).getDeliveryTypes().then((g) => {
5908
5996
  l.deliveryTypeReference = g;
5909
- }).catch(f)), l.deliveryTypeReference;
5910
- }), O = P(() => {
5911
- const l = A();
5912
- return !l.managersList && !l.dataLoaderList.managersList && (l.dataLoaderList.managersList = !0, h.getInstance(Ct).getManagers().then((g) => {
5997
+ }).catch(w)), l.deliveryTypeReference;
5998
+ }), O = R(() => {
5999
+ const l = D();
6000
+ return !l.managersList && !l.dataLoaderList.managersList && (l.dataLoaderList.managersList = !0, h.getInstance(Pt).getManagers().then((g) => {
5913
6001
  l.managersList = g;
5914
- }).catch(f)), l.managersList;
5915
- }), G = P(() => {
5916
- const l = A();
6002
+ }).catch(w)), l.managersList;
6003
+ }), G = R(() => {
6004
+ const l = D();
5917
6005
  return !l.warehousesReference && !l.dataLoaderList.warehousesReference && (l.dataLoaderList.warehousesReference = !0, h.getInstance($).getWarehouses().then((g) => {
5918
6006
  l.warehousesReference = g;
5919
- }).catch(f)), l.warehousesReference;
5920
- }), H = P(() => {
5921
- const l = A();
6007
+ }).catch(w)), l.warehousesReference;
6008
+ }), H = R(() => {
6009
+ const l = D();
5922
6010
  return !l.propertyTypesReference && !l.dataLoaderList.propertyTypesReference && (l.dataLoaderList.propertyTypesReference = !0, h.getInstance($).getPropertyTypes().then((g) => {
5923
6011
  l.propertyTypesReference = g;
5924
- }).catch(f)), l.propertyTypesReference;
5925
- }), $e = P(() => {
5926
- const l = A();
6012
+ }).catch(w)), l.propertyTypesReference;
6013
+ }), $e = R(() => {
6014
+ const l = D();
5927
6015
  return !l.priceCoefficientsReference && !l.dataLoaderList.priceCoefficientsReference && (l.dataLoaderList.priceCoefficientsReference = !0, h.getInstance($).getPriceCoefficients().then((g) => {
5928
6016
  l.priceCoefficientsReference = g;
5929
- }).catch(f)), l.priceCoefficientsReference;
6017
+ }).catch(w)), l.priceCoefficientsReference;
5930
6018
  });
5931
6019
  return {
5932
6020
  /**
@@ -5968,11 +6056,11 @@ const A = te("__references_private", () => {
5968
6056
  /**
5969
6057
  * Справочник типов ресурсов.
5970
6058
  */
5971
- resourceTypesReference: v,
6059
+ resourceTypesReference: f,
5972
6060
  /**
5973
6061
  * Справочник направлений продаж.
5974
6062
  */
5975
- salesDirectionsReference: R,
6063
+ salesDirectionsReference: m,
5976
6064
  /**
5977
6065
  * Справочник каналов первичного интереса.
5978
6066
  */
@@ -5999,7 +6087,7 @@ const A = te("__references_private", () => {
5999
6087
  priceCoefficientsReference: $e
6000
6088
  };
6001
6089
  });
6002
- class Dt {
6090
+ class $t {
6003
6091
  /**
6004
6092
  * Инициализирует экземпляр класса {@link MetaTagItem}.
6005
6093
  *
@@ -6017,7 +6105,7 @@ class Dt {
6017
6105
  this.name = r.name, this.content = r.content;
6018
6106
  }
6019
6107
  }
6020
- class rr {
6108
+ class tr {
6021
6109
  /**
6022
6110
  * Инициализирует экземпляр класса {@link Seo}.
6023
6111
  *
@@ -6053,10 +6141,10 @@ class rr {
6053
6141
  */
6054
6142
  t(this, "meta");
6055
6143
  var e;
6056
- this.resourceType = new fr(r == null ? void 0 : r.resourceType), this.resourceId = (r == null ? void 0 : r.resourceId) ?? "", this.h1 = r == null ? void 0 : r.h1, this.title = r == null ? void 0 : r.title, this.description = r == null ? void 0 : r.description, this.keywords = r == null ? void 0 : r.keywords, this.meta = ((e = r == null ? void 0 : r.meta) == null ? void 0 : e.map((s) => new Dt(s))) ?? [];
6144
+ this.resourceType = new Cr(r == null ? void 0 : r.resourceType), this.resourceId = (r == null ? void 0 : r.resourceId) ?? "", this.h1 = r == null ? void 0 : r.h1, this.title = r == null ? void 0 : r.title, this.description = r == null ? void 0 : r.description, this.keywords = r == null ? void 0 : r.keywords, this.meta = ((e = r == null ? void 0 : r.meta) == null ? void 0 : e.map((s) => new $t(s))) ?? [];
6057
6145
  }
6058
6146
  }
6059
- class ls extends h {
6147
+ class ps extends h {
6060
6148
  /**
6061
6149
  * Возвращает {@link Promise} для получения данных о SEO-параметрах указанного ресурса.
6062
6150
  *
@@ -6064,7 +6152,7 @@ class ls extends h {
6064
6152
  * @param resourceId Идентификатор ресурса для которого необходимо получить SEO-данные.
6065
6153
  */
6066
6154
  getResourceSeoData(r, e) {
6067
- return this.get(`/internal/seo/${r.slug}/${e}`, {}, (s) => new rr(s.data));
6155
+ return this.get(`/internal/seo/${r.slug}/${e}`, {}, (s) => new tr(s.data));
6068
6156
  }
6069
6157
  /**
6070
6158
  * Выполняет сохранение данных о SEO-параметрах для указанного ресурса.
@@ -6075,7 +6163,7 @@ class ls extends h {
6075
6163
  * в случае ошибок в запросах.
6076
6164
  */
6077
6165
  saveResourceSeoData(r, e = {}) {
6078
- return this.post(`/internal/seo/${r.resourceType.slug}/${r.resourceId}`, r, (s) => new rr(s.data), e);
6166
+ return this.post(`/internal/seo/${r.resourceType.slug}/${r.resourceId}`, r, (s) => new tr(s.data), e);
6079
6167
  }
6080
6168
  /**
6081
6169
  * Возвращает {@link Promise} для удаления данных о SEO-параметрах указанного ресурса.
@@ -6087,7 +6175,7 @@ class ls extends h {
6087
6175
  return this.delete(`/internal/seo/${r.slug}/${e}`);
6088
6176
  }
6089
6177
  }
6090
- class us extends h {
6178
+ class hs extends h {
6091
6179
  /**
6092
6180
  * Возвращает подсказки по адресам.
6093
6181
  *
@@ -6134,8 +6222,8 @@ class us extends h {
6134
6222
  });
6135
6223
  }
6136
6224
  }
6137
- var Tt = /* @__PURE__ */ ((n) => (n.Admin = "admin", n.Manager = "manager", n.Operator = "operator", n.Client = "client", n.Guest = "guest", n))(Tt || {});
6138
- class $t extends hr {
6225
+ var bt = /* @__PURE__ */ ((n) => (n.Admin = "admin", n.Manager = "manager", n.Operator = "operator", n.Client = "client", n.Guest = "guest", n))(bt || {});
6226
+ class St extends fr {
6139
6227
  /**
6140
6228
  * Инициализирует экземпляр класса {@link User}.
6141
6229
  *
@@ -6158,7 +6246,7 @@ class $t extends hr {
6158
6246
  this.type = e == null ? void 0 : e.type, this.canDoReclamations = (e == null ? void 0 : e.canDoReclamations) ?? !1, this.photo = e == null ? void 0 : e.photo;
6159
6247
  }
6160
6248
  }
6161
- class ps extends h {
6249
+ class gs extends h {
6162
6250
  /**
6163
6251
  * Инициализирует экземпляр класса {@link UserAuthDataProvider}.
6164
6252
  */
@@ -6174,17 +6262,17 @@ class ps extends h {
6174
6262
  return this.get("internal/users/current-tokens").then((r) => r.accessToken);
6175
6263
  }
6176
6264
  }
6177
- class bt extends h {
6265
+ class at extends h {
6178
6266
  /**
6179
6267
  * Возвращает данные о текущем пользователе.
6180
6268
  */
6181
6269
  // eslint-disable-next-line class-methods-use-this
6182
6270
  getCurrentUser() {
6183
- return this.get("/internal/users/info", {}, (r) => new $t(r.data));
6271
+ return this.get("/internal/users/info", {}, (r) => new St(r.data));
6184
6272
  }
6185
6273
  }
6186
- const St = te("__user_state_private", () => {
6187
- const n = m({}), r = m(void 0);
6274
+ const It = te("__user_state_private", () => {
6275
+ const n = y({}), r = y(void 0);
6188
6276
  return {
6189
6277
  /**
6190
6278
  * Список загружаемых/загруженных на данный момент значений.
@@ -6195,20 +6283,20 @@ const St = te("__user_state_private", () => {
6195
6283
  */
6196
6284
  currentUser: r
6197
6285
  };
6198
- }), hs = te("user_state", () => ({
6286
+ }), ms = te("user_state", () => ({
6199
6287
  /**
6200
6288
  * Данные о текущем пользователе.
6201
6289
  */
6202
- currentUser: P(() => {
6203
- const r = St();
6204
- return !r.currentUser && !r.dataLoaderList.currentUser && (r.dataLoaderList.currentUser = !0, h.getInstance(bt).getCurrentUser().then((e) => {
6290
+ currentUser: R(() => {
6291
+ const r = It();
6292
+ return !r.currentUser && !r.dataLoaderList.currentUser && (r.dataLoaderList.currentUser = !0, h.getInstance(at).getCurrentUser().then((e) => {
6205
6293
  r.currentUser = e;
6206
- }).catch(f).finally(() => {
6294
+ }).catch(w).finally(() => {
6207
6295
  r.dataLoaderList.currentUser = !1;
6208
6296
  })), r.currentUser;
6209
6297
  })
6210
6298
  }));
6211
- class gs {
6299
+ class fs {
6212
6300
  /**
6213
6301
  * Инициализирует экземпляр класса {@link FieldValidationResultData}.
6214
6302
  *
@@ -6232,150 +6320,152 @@ class gs {
6232
6320
  }
6233
6321
  }
6234
6322
  export {
6235
- ot as AnyReference,
6236
- Ft as AppBaseConfig,
6323
+ lt as AnyReference,
6324
+ jt as AppBaseConfig,
6237
6325
  T as AppConfigProvider,
6238
- qe as BankAccount,
6326
+ de as BankAccount,
6239
6327
  Te as BasePaginationProvider,
6240
- Jr as CalculationTypeEnum,
6328
+ Qr as CalculationTypeEnum,
6241
6329
  fe as Cart,
6242
- Wr as CartItem,
6243
- zr as CartItemBase,
6244
- Ut as CartProvider,
6245
- Mt as CatalogProvider,
6246
- or as CatalogableItem,
6330
+ Kr as CartItem,
6331
+ Vr as CartItemBase,
6332
+ Ft as CartProvider,
6333
+ Gt as CatalogProvider,
6334
+ cr as CatalogableItem,
6247
6335
  z as Category,
6248
- Je as CategoryPricingRule,
6249
- mr as ChannelPrimaryInterest,
6250
- Kt as City,
6251
- He as CityWithRegionAndCountry,
6252
- Ye as Client,
6253
- yt as ClientAdditionalData,
6336
+ Ve as CategoryPricingRule,
6337
+ wr as ChannelPrimaryInterest,
6338
+ Yt as City,
6339
+ Be as CityWithRegionAndCountry,
6340
+ Xe as Client,
6341
+ Ct as ClientAdditionalData,
6254
6342
  we as ClientCategory,
6255
6343
  L as ClientDataProvider,
6256
- jt as ClientPriceProvider,
6257
- Gt as ClientPriceTemplateProvider,
6344
+ Ht as ClientPriceProvider,
6345
+ Bt as ClientPriceTemplateProvider,
6258
6346
  Z as ClientProduct,
6259
- Et as ClientProductCategoryDataProvider,
6260
- zt as ClientProductDataProvider,
6347
+ Wt as ClientProductCategoryDataProvider,
6348
+ Jt as ClientProductDataProvider,
6261
6349
  me as ClientShortInfo,
6262
- nt as ClientsAdditionalDataRequestTypeEnum,
6263
- Qt as ClientsListFilters,
6350
+ ct as ClientsAdditionalDataRequestTypeEnum,
6351
+ Xt as ClientsListFilters,
6264
6352
  oe as CodedIdentity,
6265
- es as ConfiguratorProvider,
6266
- Ne as Contact,
6267
- Yr as ContactLinks,
6353
+ ts as ConfiguratorProvider,
6354
+ qe as Contact,
6355
+ hr as ContactLinks,
6268
6356
  M as ContactPerson,
6269
- ft as ContactPersonRelated,
6270
- ct as ContactPosition,
6357
+ wt as ContactPersonRelated,
6358
+ ut as ContactPosition,
6271
6359
  Ie as ContactRelation,
6272
- wr as ContragentBase,
6360
+ Pr as ContragentBase,
6273
6361
  ve as ContragentFactory,
6274
- Cr as ContragentIc,
6275
- gt as ContragentPerson,
6276
- mt as ContragentUlNr,
6277
- vr as ContragentUlR,
6362
+ Rr as ContragentIc,
6363
+ ft as ContragentPerson,
6364
+ yt as ContragentUlNr,
6365
+ Dr as ContragentUlR,
6278
6366
  Ge as CostSourceEnum,
6279
6367
  ee as Country,
6368
+ He as CuratedDirection,
6369
+ mr as Curator,
6280
6370
  Ce as Currency,
6281
- us as DataSuggestionProvider,
6282
- Yt as DataTablePagination,
6283
- wt as DataTablePaginationRequestParams,
6284
- Xt as DataTableSortRequestParams,
6285
- rs as DateTimeProvider,
6286
- Kr as DeletableNamedIdentity,
6371
+ hs as DataSuggestionProvider,
6372
+ Zt as DataTablePagination,
6373
+ vt as DataTablePaginationRequestParams,
6374
+ es as DataTableSortRequestParams,
6375
+ ss as DateTimeProvider,
6376
+ Xr as DeletableNamedIdentity,
6287
6377
  Pe as DeliveryAddress,
6288
6378
  X as DeliveryType,
6289
- Nt as DetailedJwtPayload,
6290
- et as DeviceTypeResolutionConfig,
6291
- Qr as DiscountShortInfo,
6292
- gs as FieldValidationResultData,
6379
+ Ut as DetailedJwtPayload,
6380
+ tt as DeviceTypeResolutionConfig,
6381
+ Zr as DiscountShortInfo,
6382
+ fs as FieldValidationResultData,
6293
6383
  ue as FilterGroup,
6294
- Ve as FilterItem,
6295
- Be as FilterOpEnum,
6296
- lr as GeoCoordinates,
6297
- Br as HiddenCatalogableItem,
6384
+ Ke as FilterItem,
6385
+ Ee as FilterOpEnum,
6386
+ ur as GeoCoordinates,
6387
+ Wr as HiddenCatalogableItem,
6298
6388
  pe as HttpCachedRequester,
6299
- rt as HttpParamsConfig,
6389
+ st as HttpParamsConfig,
6300
6390
  h as HttpRequester,
6301
6391
  j as Identity,
6302
- Er as Image,
6303
- U as JwtPayload,
6304
- De as Manager,
6392
+ Jr as Image,
6393
+ N as JwtPayload,
6394
+ Ae as Manager,
6305
6395
  ce as ManagerCommon,
6306
- ts as ManagerDataFactory,
6307
- Ct as ManagerDataProvider,
6308
- Dt as MetaTagItem,
6396
+ is as ManagerDataFactory,
6397
+ Pt as ManagerDataProvider,
6398
+ $t as MetaTagItem,
6309
6399
  b as NamedIdentity,
6310
6400
  F as Opf,
6311
- N as OpfEnum,
6312
- Pt as Order,
6313
- Rr as OrderInfo,
6314
- lt as OrderPaymentStatus,
6315
- vt as OrderProduct,
6316
- Pr as OrderShortInfo,
6317
- ut as OrderStatus,
6318
- ss as OrdersDataProvider,
6401
+ q as OpfEnum,
6402
+ Dt as Order,
6403
+ Tr as OrderInfo,
6404
+ pt as OrderPaymentStatus,
6405
+ Rt as OrderProduct,
6406
+ Ar as OrderShortInfo,
6407
+ ht as OrderStatus,
6408
+ ns as OrdersDataProvider,
6319
6409
  re as PartnerGroup,
6320
- pt as PaymentType,
6410
+ gt as PaymentType,
6321
6411
  ye as PreferencesStorageProvider,
6322
6412
  xe as PriceAnalyze,
6323
- is as PriceAnalyzeProvider,
6413
+ os as PriceAnalyzeProvider,
6324
6414
  Re as PriceCoefficient,
6325
- cr as PriceCoefficientEnum,
6326
- ns as PriceHistoryDataProvider,
6327
- Rt as PriceHistoryItem,
6415
+ lr as PriceCoefficientEnum,
6416
+ cs as PriceHistoryDataProvider,
6417
+ At as PriceHistoryItem,
6328
6418
  W as PriceTemplate,
6329
6419
  Se as PriceTemplateCategory,
6330
6420
  se as PriceTemplateClient,
6331
- pr as PriceTemplateICatalogableItem,
6421
+ gr as PriceTemplateICatalogableItem,
6332
6422
  ae as PriceTemplateProduct,
6333
- Wt as PriceTemplateProvider,
6423
+ Vt as PriceTemplateProvider,
6334
6424
  ne as PricingRole,
6335
- Jt as PricingRoleProvider,
6425
+ Kt as PricingRoleProvider,
6336
6426
  Oe as PrimaryCatalogableItem,
6337
6427
  I as Product,
6338
- Ht as ProductCategoryDataProvider,
6339
- Bt as ProductDataProvider,
6340
- ht as ProductFileType,
6428
+ Et as ProductCategoryDataProvider,
6429
+ zt as ProductDataProvider,
6430
+ mt as ProductFileType,
6341
6431
  Me as ProductPriceCoefficient,
6342
- At as ProductPriceHistory,
6343
- Vt as PropertiesProvider,
6432
+ Tt as ProductPriceHistory,
6433
+ Qt as PropertiesProvider,
6344
6434
  ie as Property,
6345
- gr as PropertyType,
6346
- Vr as PropertyTypeEnum,
6435
+ yr as PropertyType,
6436
+ Yr as PropertyTypeEnum,
6347
6437
  E as PropertyValue,
6348
- os as RecommendationsDataProvider,
6349
- er as RecommendationsList,
6350
- C as Reference,
6438
+ ls as RecommendationsDataProvider,
6439
+ rr as RecommendationsList,
6440
+ P as Reference,
6351
6441
  $ as ReferenceDataProvider,
6352
6442
  le as Region,
6353
- fr as ResourceType,
6443
+ Cr as ResourceType,
6354
6444
  x as SalesDirection,
6355
- tt as SentryConfig,
6356
- rr as Seo,
6357
- ls as SeoDataProvider,
6358
- yr as SourcePrimaryInterest,
6359
- Hr as StockCount,
6360
- dt as TemplatesListFilters,
6445
+ it as SentryConfig,
6446
+ tr as Seo,
6447
+ ps as SeoDataProvider,
6448
+ vr as SourcePrimaryInterest,
6449
+ zr as StockCount,
6450
+ Mt as TemplatesListFilters,
6361
6451
  je as TypedInstanceFactory,
6362
- Xe as UnitsHelper,
6363
- Zt as UnknownClientDataProvider,
6364
- ur as UpdatableNamedIdentity,
6365
- $t as User,
6366
- ps as UserAuthDataProvider,
6367
- hr as UserCommonInfo,
6368
- bt as UserDataProvider,
6369
- Xr as UserPricingRole,
6370
- d as UserShortInfo,
6371
- Tt as UserTypeEnum,
6372
- st as VersionConfig,
6373
- Ae as Warehouse,
6374
- it as WebSocketConfig,
6375
- Ke as findCatalogItemByIdRecursive,
6376
- Qe as flattenCatalogItems,
6452
+ Ze as UnitsHelper,
6453
+ rs as UnknownClientDataProvider,
6454
+ pr as UpdatableNamedIdentity,
6455
+ St as User,
6456
+ gs as UserAuthDataProvider,
6457
+ fr as UserCommonInfo,
6458
+ at as UserDataProvider,
6459
+ et as UserPricingRole,
6460
+ U as UserShortInfo,
6461
+ bt as UserTypeEnum,
6462
+ nt as VersionConfig,
6463
+ De as Warehouse,
6464
+ ot as WebSocketConfig,
6465
+ Qe as findCatalogItemByIdRecursive,
6466
+ Ye as flattenCatalogItems,
6377
6467
  be as useAuthStateStore,
6378
- cs as useReferencesStore,
6379
- hs as useUserStateStore
6468
+ us as useReferencesStore,
6469
+ ms as useUserStateStore
6380
6470
  };
6381
6471
  //# sourceMappingURL=sc-common-lib.js.map