@snabcentr/common-lib 1.76.3 → 1.77.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.
@@ -1,13 +1,13 @@
1
- var br = Object.defineProperty;
2
- var ar = (n, r, e) => r in n ? br(n, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[r] = e;
3
- var t = (n, r, e) => ar(n, typeof r != "symbol" ? r + "" : r, e);
4
- import { jwtDecode as nr } from "jwt-decode";
5
- import { merge as fe, isUndefined as Sr, isNil as A, isEmpty as K, noop as w, mapValues as or, isArray as V, every as Ir, split as kr, toUpper as Lr, constant as xr, isString as C, cloneDeep as _r, toLower as dr, isFunction as Ne, map as Pe, forEach as Or, isDate as xe, omitBy as cr, isObject as lr } from "lodash-es";
6
- import { objectToCamel as Ue, objectToSnake as Ee } from "ts-case-convert";
7
- import { isAfter as Je, parseISO as v, startOfToday as _e, format as x, addSeconds as qr, addBusinessDays as Nr, endOfTomorrow as Ur, startOfTomorrow as jr, endOfYesterday as Gr, startOfYesterday as Fr, endOfToday as Mr, endOfDay as Br, startOfDay as Hr } from "date-fns";
8
- import { defineStore as ee } from "pinia";
9
- import { ref as y, markRaw as zr, computed as R } from "vue";
10
- import Wr from "axios";
1
+ var Tr = Object.defineProperty;
2
+ var br = (n, r, e) => r in n ? Tr(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 ir } from "jwt-decode";
5
+ import { merge as ne, isString as v, isNil as A, isEmpty as K, noop as w, mapValues as nr, isArray as V, every as ar, split as Sr, toUpper as Ir, constant as kr, cloneDeep as Lr, toLower as xr, isFunction as qe, map as Ce, forEach as _r, isDate as Le, omitBy as or, isObject as cr } from "lodash-es";
6
+ import { objectToCamel as Ne, objectToSnake as We } from "ts-case-convert";
7
+ import { parseISO as C, isAfter as Ee, startOfToday as xe, format as x, addSeconds as dr, addBusinessDays as Or, endOfTomorrow as qr, startOfTomorrow as Nr, endOfYesterday as Ur, startOfYesterday as jr, endOfToday as Gr, endOfDay as Fr, startOfDay as Mr } from "date-fns";
8
+ import { defineStore as j } from "pinia";
9
+ import { ref as y, markRaw as Br, computed as R } from "vue";
10
+ import Hr from "axios";
11
11
  class q {
12
12
  /**
13
13
  * Инициализирует экземпляр класса {@link JwtPayload}.
@@ -99,7 +99,7 @@ class q {
99
99
  * @inheritDoc
100
100
  */
101
101
  t(this, "email", "");
102
- fe(this, r);
102
+ ne(this, r);
103
103
  }
104
104
  /**
105
105
  * Возвращает данные полезной нагрузки для указанного JWT-токена.
@@ -107,11 +107,11 @@ class q {
107
107
  * @param jwtToken JWT-ключ доступа.
108
108
  */
109
109
  static getJwtPayload(r) {
110
- const e = nr(r), s = new q(Ue(e));
110
+ const e = ir(r), s = new q(Ne(e));
111
111
  return s.resourceAccess = e.resource_access, s;
112
112
  }
113
113
  }
114
- class Ut extends q {
114
+ class Nt extends q {
115
115
  /**
116
116
  * Инициализирует экземпляр класса {@link DetailedJwtPayload}.
117
117
  *
@@ -143,7 +143,7 @@ class Ut extends q {
143
143
  * @inheritDoc
144
144
  */
145
145
  t(this, "address");
146
- fe(this, e);
146
+ ne(this, e);
147
147
  }
148
148
  /**
149
149
  * Возвращает данные полезной нагрузки для указанного JWT-токена.
@@ -151,46 +151,240 @@ class Ut extends q {
151
151
  * @param jwtToken JWT-ключ доступа.
152
152
  */
153
153
  static getJwtPayload(e) {
154
- return new q(Ue(nr(e)));
154
+ return new q(Ne(ir(e)));
155
155
  }
156
156
  }
157
- const W = class W {
157
+ class zr {
158
158
  /**
159
- * Инициализирует и возвращает конфигурацию приложения.
159
+ * Инициализирует экземпляр класса {@link DeviceTypeResolutionConfig}.
160
160
  *
161
- * @param config Данные для первоначальной инициализации.
161
+ * @param data Данные для первоначальной инициализации.
162
162
  */
163
- static init(r) {
164
- W.config = r;
163
+ constructor(r) {
164
+ /**
165
+ * Максимальное разрешение для распознания мобильного телефона.
166
+ */
167
+ t(this, "phone");
168
+ /**
169
+ * Минимальное разрешение для распознания планшета.
170
+ */
171
+ t(this, "tablet");
172
+ /**
173
+ * Минимальное разрешение для распознания компьютера.
174
+ */
175
+ t(this, "laptop");
176
+ 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;
165
177
  }
178
+ }
179
+ class Wr {
166
180
  /**
167
- * Возвращает текущую конфигурацию приложения.
181
+ * Инициализирует экземпляр класса {@link HttpParamsConfig}.
182
+ *
183
+ * @param data Данные для первоначальной инициализации.
168
184
  */
169
- // eslint-disable-next-line @typescript-eslint/no-unnecessary-type-parameters
170
- static getConfig() {
171
- if (Sr(W.config))
172
- throw new Error("Config is undefined. Please set config by AppConfigProvider.init().");
173
- return W.config;
185
+ constructor(r) {
186
+ /**
187
+ * @inheritDoc
188
+ */
189
+ t(this, "portalApiUrl");
190
+ /**
191
+ * @inheritDoc
192
+ */
193
+ t(this, "mediaUrl");
194
+ /**
195
+ * @inheritDoc
196
+ */
197
+ t(this, "responseDataCacheTimeout");
198
+ this.portalApiUrl = (r == null ? void 0 : r.portalApiUrl) ?? "", this.mediaUrl = (r == null ? void 0 : r.mediaUrl) ?? "", this.responseDataCacheTimeout = (r == null ? void 0 : r.responseDataCacheTimeout) ?? 3 * 60 * 60;
174
199
  }
200
+ }
201
+ class Er {
175
202
  /**
176
- * Выполняет загрузку конфигурации по указанному пути.
203
+ * Инициализирует экземпляр класса {@link SentryConfig}.
177
204
  *
178
- * @param path Путь к конфигурации.
205
+ * @param data Данные для первоначальной инициализации.
179
206
  */
180
- static loadRemoteConfig(r = "/config.json") {
181
- const e = fetch(r).then((s) => s.ok ? s.json() : (console.error(new Error(`Ошибка загрузки ${r}: ${s.statusText}`)), new Promise((i) => {
182
- i({});
183
- })));
184
- return e.catch((s) => {
185
- console.error(s);
186
- }), e;
207
+ constructor(r) {
208
+ /**
209
+ * DSN подключения к Sentry.
210
+ */
211
+ t(this, "dsn");
212
+ /**
213
+ * Тип окружения.
214
+ */
215
+ t(this, "environment");
216
+ /**
217
+ * Список игнорируемых ошибок.
218
+ */
219
+ t(this, "ignoreErrors");
220
+ /**
221
+ * Настройки трассировкии событий.
222
+ */
223
+ t(this, "trace");
224
+ /**
225
+ * Настройки записей сеансов.
226
+ */
227
+ t(this, "replay");
228
+ /**
229
+ * Дополнительные параметры.
230
+ */
231
+ t(this, "additionalParams");
232
+ var e, s, i, o;
233
+ this.dsn = (r == null ? void 0 : r.dsn) ?? "", this.environment = (r == null ? void 0 : r.environment) ?? "production", this.ignoreErrors = (r == null ? void 0 : r.ignoreErrors) ?? [
234
+ /Network\s{1,3}Error/,
235
+ /Request\s{1,3}aborted/,
236
+ /Request\s{1,3}failed\s{1,3}with\s{1,3}status\s{1,3}code\s{1,3}(401|403|404|422)/
237
+ ], this.trace = {
238
+ allowedTargets: ((e = r == null ? void 0 : r.trace) == null ? void 0 : e.allowedTargets) ?? [/^\//],
239
+ sampleRate: ((s = r == null ? void 0 : r.trace) == null ? void 0 : s.sampleRate) ?? 0
240
+ }, this.replay = {
241
+ replaysOnErrorSampleRate: ((i = r == null ? void 0 : r.replay) == null ? void 0 : i.replaysOnErrorSampleRate) ?? 0,
242
+ replaysSessionSampleRate: ((o = r == null ? void 0 : r.replay) == null ? void 0 : o.replaysSessionSampleRate) ?? 0
243
+ }, this.additionalParams = (r == null ? void 0 : r.additionalParams) ?? {};
187
244
  }
188
- };
189
- /**
190
- * Конфигурация приложения.
191
- */
192
- t(W, "config");
193
- let T = W;
245
+ }
246
+ class Jr {
247
+ /**
248
+ * Инициализирует экземпляр класса {@link VersionConfig}.
249
+ *
250
+ * @param data Данные для первоначальной инициализации.
251
+ */
252
+ constructor(r) {
253
+ /**
254
+ * Дата релиза текущей версии приложения.
255
+ */
256
+ t(this, "date");
257
+ /**
258
+ * Название релиза.
259
+ */
260
+ t(this, "name");
261
+ /**
262
+ * Текущая версия приложения.
263
+ */
264
+ t(this, "version");
265
+ this.date = v(r == null ? void 0 : r.date) ? C(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";
266
+ }
267
+ }
268
+ class Vr {
269
+ /**
270
+ * Инициализирует экземпляр класса {@link WebSocketConfig}.
271
+ *
272
+ * @param data Данные для первоначальной инициализации.
273
+ */
274
+ constructor(r) {
275
+ /**
276
+ * @inheritDoc
277
+ */
278
+ // eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
279
+ t(this, "broadcaster");
280
+ /**
281
+ * @inheritDoc
282
+ */
283
+ t(this, "key");
284
+ /**
285
+ * @inheritDoc
286
+ */
287
+ t(this, "wsHost");
288
+ /**
289
+ * @inheritDoc
290
+ */
291
+ t(this, "wsPort");
292
+ /**
293
+ * @inheritDoc
294
+ */
295
+ t(this, "wssPort");
296
+ /**
297
+ * @inheritDoc
298
+ */
299
+ t(this, "forceTLS");
300
+ /**
301
+ * @inheritDoc
302
+ */
303
+ t(this, "enabledTransports");
304
+ 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"];
305
+ }
306
+ }
307
+ class Kr {
308
+ /**
309
+ * Инициализирует экземпляр класса {@link AppBaseConfig}.
310
+ *
311
+ * @param data Данные для первоначальной инициализации.
312
+ */
313
+ constructor(r) {
314
+ /**
315
+ * @inheritDoc
316
+ */
317
+ t(this, "environment");
318
+ /**
319
+ * @inheritDoc
320
+ */
321
+ t(this, "devMode");
322
+ /**
323
+ * @inheritDoc
324
+ */
325
+ t(this, "http");
326
+ /**
327
+ * @inheritDoc
328
+ */
329
+ t(this, "deviceTypeByResolution");
330
+ /**
331
+ * @inheritDoc
332
+ */
333
+ t(this, "sentry");
334
+ /**
335
+ * @inheritDoc
336
+ */
337
+ t(this, "tableDefaultHeightCoefficient");
338
+ /**
339
+ * @inheritDoc
340
+ */
341
+ t(this, "urls");
342
+ /**
343
+ * @inheritDoc
344
+ */
345
+ t(this, "version");
346
+ /**
347
+ * Конфигурация web-сокета.
348
+ */
349
+ t(this, "websocket");
350
+ /**
351
+ * @inheritDoc
352
+ */
353
+ t(this, "dateFormats");
354
+ var e, s, i;
355
+ this.environment = (r == null ? void 0 : r.environment) ?? "production", this.devMode = (r == null ? void 0 : r.devMode) ?? {}, this.http = new Wr(r == null ? void 0 : r.http), this.deviceTypeByResolution = new zr(r == null ? void 0 : r.deviceTypeByResolution), this.sentry = new Er({
356
+ environment: this.environment,
357
+ ...r == null ? void 0 : r.sentry
358
+ }), this.tableDefaultHeightCoefficient = (r == null ? void 0 : r.tableDefaultHeightCoefficient) ?? 0.7, this.urls = r == null ? void 0 : r.urls, this.version = new Jr(r == null ? void 0 : r.version), this.websocket = r != null && r.websocket ? new Vr(r.websocket) : void 0, this.dateFormats = {
359
+ api: ((e = r == null ? void 0 : r.dateFormats) == null ? void 0 : e.api) ?? "yyyy-MM-dd HH:mm:ss",
360
+ uiDate: ((s = r == null ? void 0 : r.dateFormats) == null ? void 0 : s.uiDate) ?? "dd.MM.yyyy",
361
+ uiDateWithTime: ((i = r == null ? void 0 : r.dateFormats) == null ? void 0 : i.uiDateWithTime) ?? "dd.MM.yyyy HH:mm"
362
+ };
363
+ }
364
+ }
365
+ const b = j("common.config", () => {
366
+ const n = y(new Kr());
367
+ return {
368
+ /**
369
+ * Конфигурационные данные приложения.
370
+ */
371
+ config: n,
372
+ /**
373
+ * Получает конфигурацию приложения.
374
+ *
375
+ * @returns Конфигурация приложения.
376
+ */
377
+ getConfig: () => n.value,
378
+ /**
379
+ * Устанавливает конфигурацию приложения.
380
+ *
381
+ * @param appConfig Конфигурация приложения.
382
+ */
383
+ setConfig: (s) => {
384
+ n.value = ne(n.value, s);
385
+ }
386
+ };
387
+ });
194
388
  class me {
195
389
  /**
196
390
  * Возвращает актуальные и не просроченные данные из хранилища.
@@ -210,7 +404,7 @@ class me {
210
404
  if (e)
211
405
  try {
212
406
  const s = JSON.parse(e);
213
- if (!s.availableFor || Je(v(s.availableFor) || _e(), /* @__PURE__ */ new Date())) {
407
+ if (!s.availableFor || Ee(C(s.availableFor) || xe(), /* @__PURE__ */ new Date())) {
214
408
  if (A(s.data) || K(s.data))
215
409
  throw new Error("Data is empty");
216
410
  return s.data;
@@ -284,7 +478,7 @@ class me {
284
478
  const i = localStorage.getItem(s);
285
479
  if (i) {
286
480
  const o = JSON.parse(i);
287
- o.availableFor && !Je(v(o.availableFor) || _e(), /* @__PURE__ */ new Date()) && r.push(s);
481
+ o.availableFor && !Ee(C(o.availableFor) || xe(), /* @__PURE__ */ new Date()) && r.push(s);
288
482
  }
289
483
  } catch {
290
484
  r.push(s);
@@ -300,7 +494,7 @@ class me {
300
494
  }
301
495
  }
302
496
  }
303
- function Ve(n) {
497
+ function Je(n) {
304
498
  try {
305
499
  const r = q.getJwtPayload(n);
306
500
  return new Date(r.exp * 1e3);
@@ -308,7 +502,7 @@ function Ve(n) {
308
502
  return;
309
503
  }
310
504
  }
311
- const M = ee("__auth_state_private", () => {
505
+ const B = j("common.auth_state_private", () => {
312
506
  const n = y(
313
507
  (() => {
314
508
  var u;
@@ -318,14 +512,14 @@ const M = ee("__auth_state_private", () => {
318
512
  );
319
513
  if (o)
320
514
  return Promise.resolve(o);
321
- const c = (u = T.getConfig().devMode) == null ? void 0 : u.initAuthBearerToken;
515
+ const c = (u = b().config.devMode) == null ? void 0 : u.initAuthBearerToken;
322
516
  return c ? Promise.resolve(c) : void 0;
323
517
  })()
324
- ), r = y(void 0), e = y(void 0), s = zr(/* @__PURE__ */ new Map());
518
+ ), r = y(void 0), e = y(void 0), s = Br(/* @__PURE__ */ new Map());
325
519
  function i() {
326
520
  e.value = void 0, A(n.value) || n.value.then((o) => {
327
521
  const c = q.getJwtPayload(o);
328
- e.value = c.exp * 1e3 > Date.now() ? or(c.resourceAccess, (u) => (u == null ? void 0 : u.roles) ?? []) : void 0;
522
+ e.value = c.exp * 1e3 > Date.now() ? nr(c.resourceAccess, (u) => (u == null ? void 0 : u.roles) ?? []) : void 0;
329
523
  }).catch(w);
330
524
  }
331
525
  return {
@@ -350,47 +544,47 @@ const M = ee("__auth_state_private", () => {
350
544
  */
351
545
  recalculateUserPermissions: i
352
546
  };
353
- }), be = ee("__auth_state", () => {
547
+ }), Te = j("common.auth_state", () => {
354
548
  const n = R(() => {
355
- const o = M();
549
+ const o = B();
356
550
  if (A(o.jwtToken) && !A(o.jwtTokenUpdater)) {
357
551
  const c = o.jwtTokenUpdater();
358
552
  o.jwtToken = c, c.then((u) => {
359
- o.jwtToken = Promise.resolve(u), me.saveActualDataToStorage("sc.token", u, Ve(u)), o.recalculateUserPermissions();
553
+ o.jwtToken = Promise.resolve(u), me.saveActualDataToStorage("sc.token", u, Je(u)), o.recalculateUserPermissions();
360
554
  }).catch(w);
361
555
  }
362
556
  return o.jwtToken;
363
557
  });
364
558
  function r(o) {
365
- M().jwtTokenUpdater = o;
559
+ B().jwtTokenUpdater = o;
366
560
  }
367
561
  function e(o) {
368
- const c = M();
369
- c.jwtToken = Promise.resolve(o), me.saveActualDataToStorage("sc.token", o, Ve(o)), c.recalculateUserPermissions();
562
+ const c = B();
563
+ c.jwtToken = Promise.resolve(o), me.saveActualDataToStorage("sc.token", o, Je(o)), c.recalculateUserPermissions();
370
564
  }
371
565
  function s() {
372
- const o = M();
566
+ const o = B();
373
567
  o.jwtToken = void 0, o.userPermissions = void 0, me.saveActualDataToStorage("sc.token", void 0);
374
568
  }
375
569
  function i(o) {
376
- const c = M();
570
+ const c = B();
377
571
  !A(c.jwtToken) && A(c.userPermissions) && c.jwtToken.then((f) => {
378
572
  const g = q.getJwtPayload(f);
379
- c.userPermissions = g.exp * 1e3 > Date.now() ? or(g.resourceAccess, (a) => (a == null ? void 0 : a.roles) ?? []) : void 0;
573
+ c.userPermissions = g.exp * 1e3 > Date.now() ? nr(g.resourceAccess, (a) => (a == null ? void 0 : a.roles) ?? []) : void 0;
380
574
  }).catch(w);
381
575
  const u = V(o) ? o.join(" && ") : o;
382
576
  if (c.userPermissionsComputedRefs.has(u))
383
577
  return c.userPermissionsComputedRefs.get(u);
384
578
  const h = R(() => {
385
579
  const f = (g) => {
386
- var F;
387
- const a = kr(g, ".");
580
+ var M;
581
+ const a = Sr(g, ".");
388
582
  if (a.length < 2)
389
583
  return !1;
390
- const [re, te] = a, G = (F = M().userPermissions) == null ? void 0 : F[re];
391
- return V(G) && G.includes(te);
584
+ const [ee, re] = a, F = (M = B().userPermissions) == null ? void 0 : M[ee];
585
+ return V(F) && F.includes(re);
392
586
  };
393
- return V(o) ? Ir(o, (g) => f(g)) : f(o);
587
+ return V(o) ? ar(o, (g) => f(g)) : f(o);
394
588
  });
395
589
  return c.userPermissionsComputedRefs.set(u, h), h;
396
590
  }
@@ -423,7 +617,7 @@ const M = ee("__auth_state_private", () => {
423
617
  hasUserPermission: i
424
618
  };
425
619
  });
426
- class j {
620
+ class G {
427
621
  /**
428
622
  * Инициализирует экземпляр класса {@link Identity}.
429
623
  *
@@ -448,7 +642,7 @@ class j {
448
642
  return typeof this.id == "number" ? this.id === -1 : typeof this.id == "string" ? this.id === "" : A(this.id);
449
643
  }
450
644
  }
451
- class b extends j {
645
+ class T extends G {
452
646
  /**
453
647
  * Инициализирует экземпляр класса {@link NamedIdentity}.
454
648
  *
@@ -463,7 +657,7 @@ class b extends j {
463
657
  this.name = (e == null ? void 0 : e.name) ?? "";
464
658
  }
465
659
  }
466
- class oe extends b {
660
+ class oe extends T {
467
661
  /**
468
662
  * Инициализирует экземпляр класса {@link NamedIdentity}.
469
663
  *
@@ -478,7 +672,7 @@ class oe extends b {
478
672
  this.code = (e == null ? void 0 : e.code) ?? "";
479
673
  }
480
674
  }
481
- class ur extends oe {
675
+ class lr extends oe {
482
676
  /**
483
677
  * Инициализирует экземпляр класса {@link CatalogableItem}.
484
678
  *
@@ -497,7 +691,7 @@ class ur extends oe {
497
691
  this.slug = (e == null ? void 0 : e.slug) ?? "";
498
692
  }
499
693
  }
500
- class de extends ur {
694
+ class _e extends lr {
501
695
  /**
502
696
  * Инициализирует экземпляр класса {@link PrimaryCatalogableItem}.
503
697
  *
@@ -512,7 +706,7 @@ class de extends ur {
512
706
  this.isPrimary = (e == null ? void 0 : e.isPrimary) ?? !1;
513
707
  }
514
708
  }
515
- class pe extends de {
709
+ class pe extends _e {
516
710
  /**
517
711
  * Инициализирует экземпляр класса {@link BaseCategory}.
518
712
  *
@@ -536,11 +730,11 @@ class pe extends de {
536
730
  * Список коэффициентов пересчёта из валют в рубли в формате ключ значение.
537
731
  */
538
732
  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]) => [Lr(s), i])) : void 0;
733
+ 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]) => [Ir(s), i])) : void 0;
540
734
  }
541
735
  }
542
- var pr = /* @__PURE__ */ ((n) => (n.K0 = "k0", n.K1 = "k1", n.K2 = "k2", n.K3 = "k3", n.K4 = "k4", n.Retail = "retail", n))(pr || {});
543
- class P extends b {
736
+ var ur = /* @__PURE__ */ ((n) => (n.K0 = "k0", n.K1 = "k1", n.K2 = "k2", n.K3 = "k3", n.K4 = "k4", n.Retail = "retail", n))(ur || {});
737
+ class P extends T {
544
738
  /**
545
739
  * Инициализирует экземпляр класса {@link Reference}.
546
740
  *
@@ -559,15 +753,15 @@ class P extends b {
559
753
  this.description = e == null ? void 0 : e.description, this.slug = e == null ? void 0 : e.slug;
560
754
  }
561
755
  }
562
- class Re extends P {
756
+ class Pe extends P {
563
757
  /**
564
758
  * Возвращает значение справочника коэффициента розничной цены.
565
759
  */
566
760
  static getRetailPriceCoefficient() {
567
- return { id: -2, slug: pr.Retail, name: "Розн. цена", guid: "", isNewRec: xr(!0) };
761
+ return { id: -2, slug: ur.Retail, name: "Розн. цена", guid: "", isNewRec: kr(!0) };
568
762
  }
569
763
  }
570
- class je {
764
+ class Ue {
571
765
  /**
572
766
  * Инициализирует экземпляр класса {@link ProductPriceCoefficient}.
573
767
  *
@@ -594,10 +788,10 @@ class je {
594
788
  * Признак того, что указанный коэффициент доступен текущему пользователю только для просмотра.
595
789
  */
596
790
  t(this, "readOnly");
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;
791
+ this.coefficient = new Pe(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
792
  }
599
793
  }
600
- class hr {
794
+ class pr {
601
795
  /**
602
796
  * Инициализирует экземпляр класса {@link GeoCoordinates}.
603
797
  *
@@ -617,7 +811,7 @@ class hr {
617
811
  }
618
812
  class Q extends P {
619
813
  }
620
- class De extends P {
814
+ class Re extends P {
621
815
  /**
622
816
  * Инициализирует экземпляр класса {@link Warehouse}.
623
817
  *
@@ -646,10 +840,10 @@ class De extends P {
646
840
  * Координаты склада.
647
841
  */
648
842
  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 Q(i))) ?? [], this.regions = (e == null ? void 0 : e.regions) ?? [], this.coordinates = new hr(e == null ? void 0 : e.coordinates);
843
+ 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 Q(i))) ?? [], this.regions = (e == null ? void 0 : e.regions) ?? [], this.coordinates = new pr(e == null ? void 0 : e.coordinates);
650
844
  }
651
845
  }
652
- class Er {
846
+ class Qr {
653
847
  /**
654
848
  * Инициализирует экземпляр класса {@link StockCount}.
655
849
  *
@@ -664,10 +858,10 @@ class Er {
664
858
  * Количество остатков товара на складе.
665
859
  */
666
860
  t(this, "count");
667
- this.warehouse = new De(r == null ? void 0 : r.warehouse), this.count = (r == null ? void 0 : r.count) ?? 0;
861
+ this.warehouse = new Re(r == null ? void 0 : r.warehouse), this.count = (r == null ? void 0 : r.count) ?? 0;
668
862
  }
669
863
  }
670
- class Jr extends ur {
864
+ class Yr extends lr {
671
865
  /**
672
866
  * Инициализирует экземпляр класса {@link HiddenCatalogableItem}.
673
867
  *
@@ -682,7 +876,7 @@ class Jr extends ur {
682
876
  this.isHidden = (e == null ? void 0 : e.isHidden) ?? !1;
683
877
  }
684
878
  }
685
- class Vr {
879
+ class Xr {
686
880
  /**
687
881
  * Инициализирует экземпляр класса {@link Image}.
688
882
  *
@@ -705,7 +899,7 @@ class Vr {
705
899
  this.image = `${e ?? ""}${r.image}`, this.preview = `${e ?? ""}${r.preview}`, this.isDefault = r.isDefault;
706
900
  }
707
901
  }
708
- class I extends Jr {
902
+ class I extends Yr {
709
903
  /**
710
904
  * Инициализирует экземпляр класса {@link Product}.
711
905
  *
@@ -790,17 +984,17 @@ class I extends Jr {
790
984
  * Список коэффициентов цен на продукт.
791
985
  */
792
986
  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 = 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((h) => new Er(h))) ?? [], this.currencySignature = (e == null ? void 0 : e.currencySignature) ?? "", this.type = "product";
987
+ 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 = v(e == null ? void 0 : e.costDate) ? C(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((h) => new Qr(h))) ?? [], this.currencySignature = (e == null ? void 0 : e.currencySignature) ?? "", this.type = "product";
794
988
  const s = (e == null ? void 0 : e.category) ?? ((o = e == null ? void 0 : e.categories) == null ? void 0 : o.find((h) => h.isPrimary));
795
- s && (this.category = new de({ ...s, isPrimary: !0 }), this.categories = [this.category]), e != null && e.categories && (this.categories = e.categories.map((h) => new de(h))), this.images = ((c = e == null ? void 0 : e.images) == null ? void 0 : c.map((h) => new Vr(h, 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((h) => new je(h))) ?? [], e && "codeNumber" in e && !e.code && (this.code = e == null ? void 0 : e.codeNumber);
989
+ s && (this.category = new _e({ ...s, isPrimary: !0 }), this.categories = [this.category]), e != null && e.categories && (this.categories = e.categories.map((h) => new _e(h))), this.images = ((c = e == null ? void 0 : e.images) == null ? void 0 : c.map((h) => new Xr(h, b().config.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((h) => new Ue(h))) ?? [], e && "codeNumber" in e && !e.code && (this.code = e == null ? void 0 : e.codeNumber);
796
990
  }
797
991
  /**
798
992
  * Возвращает признак, что это измеряемый товар.
799
993
  */
800
994
  getIsMeasurable() {
801
- var s;
802
- const e = (s = T.getConfig().catalog) == null ? void 0 : s.products.units;
803
- return [...(e == null ? void 0 : e.linear) ?? ["пог.м.", "м."], ...(e == null ? void 0 : e.square) ?? ["м2"]].includes(this.unit);
995
+ var i;
996
+ const s = (i = b().getConfig().catalog) == null ? void 0 : i.products.units;
997
+ return [...(s == null ? void 0 : s.linear) ?? ["пог.м.", "м."], ...(s == null ? void 0 : s.square) ?? ["м2"]].includes(this.unit);
804
998
  }
805
999
  /**
806
1000
  * Возвращает розничную цену.
@@ -815,7 +1009,7 @@ class I extends Jr {
815
1009
  return this.retailCostRub ?? this.costRub;
816
1010
  }
817
1011
  }
818
- class Kr extends j {
1012
+ class Zr extends G {
819
1013
  /**
820
1014
  * Инициализирует экземпляр класса {@link CartItemBase}.
821
1015
  *
@@ -867,10 +1061,10 @@ class Kr extends j {
867
1061
  * Признак того, что позиция является дополнительной продажей.
868
1062
  */
869
1063
  t(this, "dopProdaga");
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 pe(), this.height = e.height, this.length = e.length, this.width = e.width, this.configurator = e.configurator, this.configuratorParams = e.configuratorParams && _r(e.configuratorParams), this.dopProdaga = e.dopProdaga;
1064
+ this.product = new I(e == null ? void 0 : e.product), this.quantity = e.quantity ?? 0, this.marker = e.marker, this.category = e.category ?? new pe(), this.height = e.height, this.length = e.length, this.width = e.width, this.configurator = e.configurator, this.configuratorParams = e.configuratorParams && Lr(e.configuratorParams), this.dopProdaga = e.dopProdaga;
871
1065
  }
872
1066
  }
873
- class Qr extends Kr {
1067
+ class et extends Zr {
874
1068
  /**
875
1069
  * Инициализирует экземпляр класса {@link CartItem}.
876
1070
  *
@@ -939,10 +1133,10 @@ class ge {
939
1133
  * Список итоговых сумм по направлениям продаж.
940
1134
  */
941
1135
  t(this, "directionsSum");
942
- this.items = r.items.map((e) => new Qr(e)), this.resultSum = r.resultSum, this.directionsSum = r.directionsSum;
1136
+ this.items = r.items.map((e) => new et(e)), this.resultSum = r.resultSum, this.directionsSum = r.directionsSum;
943
1137
  }
944
1138
  }
945
- class Ge {
1139
+ class je {
946
1140
  /**
947
1141
  * Инициализирует экземпляр указанного класса.
948
1142
  *
@@ -973,7 +1167,7 @@ const S = class S {
973
1167
  /**
974
1168
  * Базовый URL путь для выполнения запросов.
975
1169
  */
976
- t(this, "baseUrl", `${T.getConfig().http.portalApiUrl}/api`);
1170
+ t(this, "baseUrl", `${b().config.http.portalApiUrl}/api`);
977
1171
  /**
978
1172
  * Обработчик ошибок выполнения запросов текущего экземпляра класса.
979
1173
  *
@@ -1000,7 +1194,7 @@ const S = class S {
1000
1194
  // eslint-disable-next-line class-methods-use-this
1001
1195
  t(this, "authRequestInterceptor", async (r) => {
1002
1196
  let e;
1003
- return A(be().jwtToken) || (e = await be().jwtToken), e && r.headers.set("Authorization", `Bearer ${e}`), r;
1197
+ return A(Te().jwtToken) || (e = await Te().jwtToken), e && r.headers.set("Authorization", `Bearer ${e}`), r;
1004
1198
  });
1005
1199
  /**
1006
1200
  * Перехватчик запроса для преобразования данных запроса.
@@ -1008,7 +1202,7 @@ const S = class S {
1008
1202
  * @param request Данные запроса.
1009
1203
  */
1010
1204
  // 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(dr(r.method)) && r.data && (r.data = Ee(r.data))), r));
1205
+ t(this, "dataConverterRequestInterceptor", (r) => (r.method && (r.method === "get" && r.params && (r.params = We(r.params)), ["put", "patch", "post"].includes(xr(r.method)) && r.data && (r.data = We(r.data))), r));
1012
1206
  /**
1013
1207
  * Перехватчик ошибок ответов на запрос.
1014
1208
  *
@@ -1017,7 +1211,7 @@ const S = class S {
1017
1211
  t(this, "authErrorsResponseInterceptors", (r) => {
1018
1212
  var s;
1019
1213
  const e = r.rawError ? (s = r.rawError) == null ? void 0 : s.config : void 0;
1020
- return r.status === 401 ? !e || e.__isRetryRequest ? Promise.reject(r) : (be().invalidateJwtToken(), e.__isRetryRequest = !0, this.httpClient(e)) : Promise.reject(r);
1214
+ return r.status === 401 ? !e || e.__isRetryRequest ? Promise.reject(r) : (Te().invalidateJwtToken(), e.__isRetryRequest = !0, this.httpClient(e)) : Promise.reject(r);
1021
1215
  });
1022
1216
  /**
1023
1217
  * Перехватчик ответа для преобразования данных ответа на запрос.
@@ -1025,11 +1219,11 @@ const S = class S {
1025
1219
  * @param response Данные ответа на запрос.
1026
1220
  */
1027
1221
  // eslint-disable-next-line class-methods-use-this
1028
- t(this, "dataConverterResponseInterceptor", (r) => (r.data && (r.data = Ue(r.data)), r));
1029
- const r = T.getConfig().version;
1030
- this.errorResponseHandler = S.defaultErrorsResponseHandler, this.httpClient = Wr.create({
1222
+ t(this, "dataConverterResponseInterceptor", (r) => (r.data && (r.data = Ne(r.data)), r));
1223
+ const r = b().config.version;
1224
+ this.errorResponseHandler = S.defaultErrorsResponseHandler, this.httpClient = Hr.create({
1031
1225
  headers: {
1032
- "APP-VERSION": `${r.name} (${r.version}, ${x(r.date, T.getConfig().dateFormats.uiDate)})`,
1226
+ "APP-VERSION": `${r.name} (${r.version}, ${x(r.date, b().config.dateFormats.uiDate)})`,
1033
1227
  Accept: "application/json",
1034
1228
  "Content-Type": "application/json"
1035
1229
  }
@@ -1058,7 +1252,7 @@ const S = class S {
1058
1252
  * @param type Тип данных, которыми оперирует метод.
1059
1253
  */
1060
1254
  static getInstance(r) {
1061
- return Object.prototype.hasOwnProperty.call(S.instances, r.name) || (S.instances[r.name] = Ge.simpleInstanceInitializer(r)), S.instances[r.name];
1255
+ return Object.prototype.hasOwnProperty.call(S.instances, r.name) || (S.instances[r.name] = je.simpleInstanceInitializer(r)), S.instances[r.name];
1062
1256
  }
1063
1257
  /**
1064
1258
  * Конвертирует данные ошибки HTTP запроса в более упрощённую и часто используемую форму.
@@ -1165,7 +1359,7 @@ t(S, "instances", {}), /**
1165
1359
  */
1166
1360
  t(S, "defaultErrorsResponseHandler", w);
1167
1361
  let p = S;
1168
- class jt extends p {
1362
+ class Ut extends p {
1169
1363
  /**
1170
1364
  * Возвращает содержимое корзины указанного клиента.
1171
1365
  *
@@ -1279,8 +1473,8 @@ class jt extends p {
1279
1473
  return this.get(`internal/clients/${r.id}/cart/add-products-from-csv/example`, {}, (e) => new Blob([e.data], { type: "text/csv" }));
1280
1474
  }
1281
1475
  }
1282
- var Yr = /* @__PURE__ */ ((n) => (n.m2Cost = "m2Cost", n.percent = "percent", n.value = "value", n))(Yr || {}), Fe = /* @__PURE__ */ ((n) => (n.Discount = "discount", n.PriceTemplate = "price_template", n.ClientPrice = "client_price", n.Product = "product", n))(Fe || {}), Xr = /* @__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))(Xr || {});
1283
- class H extends pe {
1476
+ var rt = /* @__PURE__ */ ((n) => (n.m2Cost = "m2Cost", n.percent = "percent", n.value = "value", n))(rt || {}), Ge = /* @__PURE__ */ ((n) => (n.Discount = "discount", n.PriceTemplate = "price_template", n.ClientPrice = "client_price", n.Product = "product", n))(Ge || {}), tt = /* @__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))(tt || {});
1477
+ class z extends pe {
1284
1478
  /**
1285
1479
  * Инициализирует экземпляр класса {@link Category}.
1286
1480
  *
@@ -1297,10 +1491,10 @@ class H extends pe {
1297
1491
  * Список продуктов категории.
1298
1492
  */
1299
1493
  t(this, "products");
1300
- this.categories = (s = e == null ? void 0 : e.categories) == null ? void 0 : s.map((o) => new H(o)), this.products = (i = e == null ? void 0 : e.products) == null ? void 0 : i.map((o) => new I(o));
1494
+ 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
1495
  }
1302
1496
  }
1303
- class gr extends b {
1497
+ class hr extends T {
1304
1498
  /**
1305
1499
  * Инициализирует экземпляр класса {@link UpdatableNamedIdentity}.
1306
1500
  *
@@ -1312,10 +1506,10 @@ class gr extends b {
1312
1506
  * Дата и время последнего изменения.
1313
1507
  */
1314
1508
  t(this, "updatedAt");
1315
- this.updatedAt = C(e == null ? void 0 : e.updatedAt) ? v(e.updatedAt) : e == null ? void 0 : e.updatedAt;
1509
+ this.updatedAt = v(e == null ? void 0 : e.updatedAt) ? C(e.updatedAt) : e == null ? void 0 : e.updatedAt;
1316
1510
  }
1317
1511
  }
1318
- class Zr extends gr {
1512
+ class st extends hr {
1319
1513
  /**
1320
1514
  * Инициализирует экземпляр класса {@link UpdatableNamedIdentity}.
1321
1515
  *
@@ -1327,10 +1521,10 @@ class Zr extends gr {
1327
1521
  * Дата и время последнего удаления.
1328
1522
  */
1329
1523
  t(this, "deletedAt");
1330
- this.deletedAt = C(e == null ? void 0 : e.deletedAt) ? v(e.deletedAt) : e == null ? void 0 : e.deletedAt;
1524
+ this.deletedAt = v(e == null ? void 0 : e.deletedAt) ? C(e.deletedAt) : e == null ? void 0 : e.deletedAt;
1331
1525
  }
1332
1526
  }
1333
- class d extends b {
1527
+ class d extends T {
1334
1528
  /**
1335
1529
  * Инициализирует экземпляр класса {@link UserShortInfo}.
1336
1530
  *
@@ -1345,7 +1539,7 @@ class d extends b {
1345
1539
  this.type = e == null ? void 0 : e.type;
1346
1540
  }
1347
1541
  }
1348
- class et extends b {
1542
+ class it extends T {
1349
1543
  /**
1350
1544
  * Инициализирует экземпляр класса {@link DiscountShortInfo}.
1351
1545
  *
@@ -1381,10 +1575,10 @@ class et extends b {
1381
1575
  * Дата и время удаления.
1382
1576
  */
1383
1577
  t(this, "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 d(e == null ? void 0 : e.owner), this.deletedAt = C(e == null ? void 0 : e.deletedAt) ? v(e.deletedAt) : e == null ? void 0 : e.deletedAt;
1578
+ this.costCoefficient = (e == null ? void 0 : e.costCoefficient) ?? 0, this.isLowPriceAllowed = (e == null ? void 0 : e.isLowPriceAllowed) ?? !1, this.publishedAt = v(e == null ? void 0 : e.publishedAt) ? C(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 = v(e == null ? void 0 : e.deletedAt) ? C(e.deletedAt) : e == null ? void 0 : e.deletedAt;
1385
1579
  }
1386
1580
  }
1387
- class z extends gr {
1581
+ class W extends hr {
1388
1582
  /**
1389
1583
  * Инициализирует экземпляр класса {@link PriceTemplate}.
1390
1584
  *
@@ -1400,7 +1594,7 @@ class z extends gr {
1400
1594
  * Дата и время создания шаблона.
1401
1595
  */
1402
1596
  t(this, "createdAt");
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();
1597
+ this.description = (e == null ? void 0 : e.description) ?? "", this.createdAt = v(e == null ? void 0 : e.createdAt) ? C(e.createdAt) : (e == null ? void 0 : e.createdAt) ?? /* @__PURE__ */ new Date();
1404
1598
  }
1405
1599
  }
1406
1600
  class Y extends I {
@@ -1439,10 +1633,10 @@ class Y extends I {
1439
1633
  * Признак того, что указанный продукт входит в список избранных продуктов клиента.
1440
1634
  */
1441
1635
  t(this, "isFavorite");
1442
- this.costCoefficient = (e == null ? void 0 : e.costCoefficient) ?? 0, this.costSource = (e == null ? void 0 : e.costSource) ?? Fe.Product, this.discount = e != null && e.discount ? new et(e.discount) : void 0, this.priceTemplate = e != null && e.priceTemplate ? new z(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;
1636
+ 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 it(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
1637
  }
1444
1638
  }
1445
- class mr {
1639
+ class gr {
1446
1640
  /**
1447
1641
  * Инициализирует экземпляр класса {@link ContactLinks}.
1448
1642
  *
@@ -1462,7 +1656,7 @@ class mr {
1462
1656
  }
1463
1657
  class O extends P {
1464
1658
  }
1465
- class Me extends b {
1659
+ class Fe extends T {
1466
1660
  /**
1467
1661
  * Инициализирует экземпляр класса {@link ManagerCommon}.
1468
1662
  *
@@ -1490,12 +1684,12 @@ class Me extends b {
1490
1684
  * @inheritDoc
1491
1685
  */
1492
1686
  t(this, "isRegionalDirector");
1493
- this.salesDirection = e != null && e.salesDirection ? new O(e.salesDirection) : new O(), this.photo = e == null ? void 0 : e.photo, this.contacts = e != null && e.contacts ? new mr(e.contacts) : void 0, this.isDefault = (e == null ? void 0 : e.isDefault) ?? !1, this.isRegionalDirector = (e == null ? void 0 : e.isRegionalDirector) ?? !1;
1687
+ this.salesDirection = e != null && e.salesDirection ? new O(e.salesDirection) : new O(), this.photo = e == null ? void 0 : e.photo, this.contacts = e != null && e.contacts ? new gr(e.contacts) : void 0, this.isDefault = (e == null ? void 0 : e.isDefault) ?? !1, this.isRegionalDirector = (e == null ? void 0 : e.isRegionalDirector) ?? !1;
1494
1688
  }
1495
1689
  }
1496
- class Be extends P {
1690
+ class Me extends P {
1497
1691
  }
1498
- class rt extends b {
1692
+ class nt extends T {
1499
1693
  /**
1500
1694
  * Инициализирует экземпляр класса {@link IUserPricingRole}.
1501
1695
  *
@@ -1518,7 +1712,7 @@ class rt extends b {
1518
1712
  this.description = e.description, this.canChangeLowCost = e.canChangeLowCost, this.parentRoleId = e.parentRoleId;
1519
1713
  }
1520
1714
  }
1521
- class Ae extends Me {
1715
+ class De extends Fe {
1522
1716
  /**
1523
1717
  * Инициализирует экземпляр класса {@link Manager}.
1524
1718
  *
@@ -1555,10 +1749,10 @@ class Ae extends Me {
1555
1749
  * Список направлений кураторства.
1556
1750
  */
1557
1751
  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 rt(e.pricingRole) : void 0, this.curatedDirections = ((s = e == null ? void 0 : e.curatedDirections) == null ? void 0 : s.map((i) => new Be(i))) ?? [];
1752
+ 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 nt(e.pricingRole) : void 0, this.curatedDirections = ((s = e == null ? void 0 : e.curatedDirections) == null ? void 0 : s.map((i) => new Me(i))) ?? [];
1559
1753
  }
1560
1754
  }
1561
- class tt extends pe {
1755
+ class ot extends pe {
1562
1756
  /**
1563
1757
  * Инициализирует экземпляр класса {@link BaseClientCategory}.
1564
1758
  *
@@ -1586,10 +1780,10 @@ class tt extends pe {
1586
1780
  * Данные о менеджере за которым закреплена категория.
1587
1781
  */
1588
1782
  t(this, "manager");
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;
1783
+ 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;
1590
1784
  }
1591
1785
  }
1592
- class ye extends tt {
1786
+ class fe extends ot {
1593
1787
  /**
1594
1788
  * Инициализирует экземпляр класса {@link ClientCategory}.
1595
1789
  *
@@ -1606,10 +1800,10 @@ class ye extends tt {
1606
1800
  * Список продуктов категории.
1607
1801
  */
1608
1802
  t(this, "products");
1609
- this.categories = (s = e == null ? void 0 : e.categories) == null ? void 0 : s.map((o) => new ye(o)), this.products = (i = e == null ? void 0 : e.products) == null ? void 0 : i.map((o) => new Y(o));
1803
+ this.categories = (s = e == null ? void 0 : e.categories) == null ? void 0 : s.map((o) => new fe(o)), this.products = (i = e == null ? void 0 : e.products) == null ? void 0 : i.map((o) => new Y(o));
1610
1804
  }
1611
1805
  }
1612
- class fr {
1806
+ class mr {
1613
1807
  /**
1614
1808
  * Инициализирует экземпляр класса {@link PriceTemplateICatalogableItem}.
1615
1809
  *
@@ -1624,10 +1818,10 @@ class fr {
1624
1818
  * Процент, который прибавляется к значению выбранного коэффициента.
1625
1819
  */
1626
1820
  t(this, "increasePercent");
1627
- this.priceCoefficient = (r == null ? void 0 : r.priceCoefficient) && new Re(r.priceCoefficient), this.increasePercent = r == null ? void 0 : r.increasePercent;
1821
+ this.priceCoefficient = (r == null ? void 0 : r.priceCoefficient) && new Pe(r.priceCoefficient), this.increasePercent = r == null ? void 0 : r.increasePercent;
1628
1822
  }
1629
1823
  }
1630
- class ae extends fr {
1824
+ class be extends mr {
1631
1825
  /**
1632
1826
  * Инициализирует экземпляр класса {@link PriceTemplateProduct}.
1633
1827
  *
@@ -1642,7 +1836,7 @@ class ae extends fr {
1642
1836
  this.productCategory = new pe(e == null ? void 0 : e.productCategory);
1643
1837
  }
1644
1838
  }
1645
- class He extends b {
1839
+ class Be extends T {
1646
1840
  /**
1647
1841
  * Инициализирует экземпляр класса {@link Curator}.
1648
1842
  *
@@ -1662,7 +1856,7 @@ class He extends b {
1662
1856
  * @inheritDoc
1663
1857
  */
1664
1858
  t(this, "curatedDirection");
1665
- this.photo = e.photo, this.contacts = new mr(e.contacts), this.curatedDirection = new Be(e.curatedDirection);
1859
+ this.photo = e.photo, this.contacts = new gr(e.contacts), this.curatedDirection = new Me(e.curatedDirection);
1666
1860
  }
1667
1861
  }
1668
1862
  class X extends P {
@@ -1682,7 +1876,7 @@ class ce extends P {
1682
1876
  e && (this.country = new X(e.country));
1683
1877
  }
1684
1878
  }
1685
- class ze extends P {
1879
+ class He extends P {
1686
1880
  /**
1687
1881
  * Инициализирует экземпляр класса {@link CityWithRegionAndCountry}.
1688
1882
  *
@@ -1697,7 +1891,7 @@ class ze extends P {
1697
1891
  e && (this.region = new ce(e.region));
1698
1892
  }
1699
1893
  }
1700
- class yr extends b {
1894
+ class fr extends T {
1701
1895
  /**
1702
1896
  * Инициализирует экземпляр класса {@link UserCommonInfo}.
1703
1897
  *
@@ -1733,10 +1927,10 @@ class yr extends b {
1733
1927
  * Признак активности учетной записи пользователя.
1734
1928
  */
1735
1929
  t(this, "isActive");
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 O(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;
1930
+ 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 O(e.salesDirection) : void 0, this.createdAt = v(e == null ? void 0 : e.createdAt) ? C(e.createdAt) : e == null ? void 0 : e.createdAt, this.lastLoginAt = v(e == null ? void 0 : e.lastLoginAt) ? C(e.lastLoginAt) : e == null ? void 0 : e.lastLoginAt, this.isActive = (e == null ? void 0 : e.isActive) ?? !1;
1737
1931
  }
1738
1932
  }
1739
- class he extends yr {
1933
+ class he extends fr {
1740
1934
  /**
1741
1935
  * Инициализирует экземпляр класса {@link Client}.
1742
1936
  *
@@ -1782,10 +1976,10 @@ class he extends yr {
1782
1976
  * @inheritDoc
1783
1977
  */
1784
1978
  t(this, "curators");
1785
- this.salesDirection = new O(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 ze(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 Me(o))) ?? [], this.curators = ((i = e == null ? void 0 : e.curators) == null ? void 0 : i.map((o) => new He(o))) ?? void 0;
1979
+ this.salesDirection = new O(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((o) => new Fe(o))) ?? [], this.curators = ((i = e == null ? void 0 : e.curators) == null ? void 0 : i.map((o) => new Be(o))) ?? void 0;
1786
1980
  }
1787
1981
  }
1788
- class se extends j {
1982
+ class te extends G {
1789
1983
  /**
1790
1984
  * Инициализирует новый экземпляр класса.
1791
1985
  *
@@ -1809,10 +2003,10 @@ class se extends j {
1809
2003
  * Данные шаблона прайс-листа.
1810
2004
  */
1811
2005
  t(this, "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 he(e == null ? void 0 : e.client), this.priceTemplate = new z(e == null ? void 0 : e.priceTemplate);
2006
+ this.createdAt = v(e == null ? void 0 : e.createdAt) ? C(e.createdAt) : (e == null ? void 0 : e.createdAt) ?? /* @__PURE__ */ new Date(), this.deletedAt = v(e == null ? void 0 : e.deletedAt) ? C(e.deletedAt) : e == null ? void 0 : e.deletedAt, this.client = new he(e == null ? void 0 : e.client), this.priceTemplate = new W(e == null ? void 0 : e.priceTemplate);
1813
2007
  }
1814
2008
  }
1815
- class Se extends fr {
2009
+ class ae extends mr {
1816
2010
  /**
1817
2011
  * Инициализирует экземпляр класса {@link PriceTemplateProduct}.
1818
2012
  *
@@ -1827,9 +2021,9 @@ class Se extends fr {
1827
2021
  this.product = new I(e == null ? void 0 : e.product);
1828
2022
  }
1829
2023
  }
1830
- class wr extends P {
2024
+ class yr extends P {
1831
2025
  }
1832
- class ie extends b {
2026
+ class se extends T {
1833
2027
  /**
1834
2028
  * Инициализирует экземпляр класса {@link Property}.
1835
2029
  *
@@ -1849,10 +2043,10 @@ class ie extends b {
1849
2043
  * Дополнительные метаданные свойства.
1850
2044
  */
1851
2045
  t(this, "metadata");
1852
- this.type = new wr(e == null ? void 0 : e.type), this.description = (e == null ? void 0 : e.description) ?? "", this.metadata = e == null ? void 0 : e.metadata;
2046
+ 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;
1853
2047
  }
1854
2048
  }
1855
- class B {
2049
+ class H {
1856
2050
  /**
1857
2051
  * Инициализирует экземпляр класса {@link PropertyValue}.
1858
2052
  *
@@ -1868,7 +2062,7 @@ class B {
1868
2062
  * Может быть строкой, числом, boolean, диапазоном или JSON объектом.
1869
2063
  */
1870
2064
  t(this, "value");
1871
- this.property = new ie(r == null ? void 0 : r.property), this.value = (r == null ? void 0 : r.value) ?? "";
2065
+ this.property = new se(r == null ? void 0 : r.property), this.value = (r == null ? void 0 : r.value) ?? "";
1872
2066
  }
1873
2067
  }
1874
2068
  class L {
@@ -1886,10 +2080,10 @@ class L {
1886
2080
  * Окончание периода.
1887
2081
  */
1888
2082
  t(this, "to");
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;
2083
+ this.from = v(r == null ? void 0 : r.from) ? C(r.from) : (r == null ? void 0 : r.from) ?? null, this.to = v(r == null ? void 0 : r.to) ? C(r.to) : (r == null ? void 0 : r.to) ?? null;
1890
2084
  }
1891
2085
  }
1892
- class Gt {
2086
+ class jt {
1893
2087
  /**
1894
2088
  * Инициализирует экземпляр класса {@link TemplatesListFilters}.
1895
2089
  *
@@ -1949,11 +2143,11 @@ class Gt {
1949
2143
  return Object.keys(this).forEach((c) => {
1950
2144
  const u = this[c];
1951
2145
  // eslint-disable-next-line prettier/prettier
1952
- A(u) || C(u) && u.trim().length === 0 || Ne(u.isNewRec) && u.isNewRec() || (r[c] = u);
2146
+ A(u) || v(u) && u.trim().length === 0 || qe(u.isNewRec) && u.isNewRec() || (r[c] = u);
1953
2147
  }), !((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;
1954
2148
  }
1955
2149
  }
1956
- class ne extends b {
2150
+ class ie extends T {
1957
2151
  /**
1958
2152
  * Инициализирует экземпляр класса {@link PricingRole}.
1959
2153
  *
@@ -1988,7 +2182,7 @@ class ne extends b {
1988
2182
  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;
1989
2183
  }
1990
2184
  }
1991
- class Ke {
2185
+ class Ve {
1992
2186
  /**
1993
2187
  * Инициализирует экземпляр класса {@link PricingRoleCategoryRule}.
1994
2188
  *
@@ -2007,218 +2201,10 @@ class Ke {
2007
2201
  * Минимальный коэффициент цены.
2008
2202
  */
2009
2203
  t(this, "minCoefficient");
2010
- this.role = new ne(r == null ? void 0 : r.role), this.category = new pe(r == null ? void 0 : r.category), this.minCoefficient = new Re(r == null ? void 0 : r.minCoefficient);
2011
- }
2012
- }
2013
- class st {
2014
- /**
2015
- * Инициализирует экземпляр класса {@link DeviceTypeResolutionConfig}.
2016
- *
2017
- * @param data Данные для первоначальной инициализации.
2018
- */
2019
- constructor(r) {
2020
- /**
2021
- * Максимальное разрешение для распознания мобильного телефона.
2022
- */
2023
- t(this, "phone");
2024
- /**
2025
- * Минимальное разрешение для распознания планшета.
2026
- */
2027
- t(this, "tablet");
2028
- /**
2029
- * Минимальное разрешение для распознания компьютера.
2030
- */
2031
- t(this, "laptop");
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;
2033
- }
2034
- }
2035
- class it {
2036
- /**
2037
- * Инициализирует экземпляр класса {@link HttpParamsConfig}.
2038
- *
2039
- * @param data Данные для первоначальной инициализации.
2040
- */
2041
- constructor(r) {
2042
- /**
2043
- * @inheritDoc
2044
- */
2045
- t(this, "portalApiUrl");
2046
- /**
2047
- * @inheritDoc
2048
- */
2049
- t(this, "mediaUrl");
2050
- /**
2051
- * @inheritDoc
2052
- */
2053
- t(this, "responseDataCacheTimeout");
2054
- this.portalApiUrl = (r == null ? void 0 : r.portalApiUrl) ?? "", this.mediaUrl = (r == null ? void 0 : r.mediaUrl) ?? "", this.responseDataCacheTimeout = (r == null ? void 0 : r.responseDataCacheTimeout) ?? 3 * 60 * 60;
2055
- }
2056
- }
2057
- class nt {
2058
- /**
2059
- * Инициализирует экземпляр класса {@link SentryConfig}.
2060
- *
2061
- * @param data Данные для первоначальной инициализации.
2062
- */
2063
- constructor(r) {
2064
- /**
2065
- * DSN подключения к Sentry.
2066
- */
2067
- t(this, "dsn");
2068
- /**
2069
- * Тип окружения.
2070
- */
2071
- t(this, "environment");
2072
- /**
2073
- * Список игнорируемых ошибок.
2074
- */
2075
- t(this, "ignoreErrors");
2076
- /**
2077
- * Настройки трассировкии событий.
2078
- */
2079
- t(this, "trace");
2080
- /**
2081
- * Настройки записей сеансов.
2082
- */
2083
- t(this, "replay");
2084
- /**
2085
- * Дополнительные параметры.
2086
- */
2087
- t(this, "additionalParams");
2088
- var e, s, i, o;
2089
- this.dsn = (r == null ? void 0 : r.dsn) ?? "", this.environment = (r == null ? void 0 : r.environment) ?? "production", this.ignoreErrors = (r == null ? void 0 : r.ignoreErrors) ?? [
2090
- /Network\s{1,3}Error/,
2091
- /Request\s{1,3}aborted/,
2092
- /Request\s{1,3}failed\s{1,3}with\s{1,3}status\s{1,3}code\s{1,3}(401|403|404|422)/
2093
- ], this.trace = {
2094
- allowedTargets: ((e = r == null ? void 0 : r.trace) == null ? void 0 : e.allowedTargets) ?? [/^\//],
2095
- sampleRate: ((s = r == null ? void 0 : r.trace) == null ? void 0 : s.sampleRate) ?? 0
2096
- }, this.replay = {
2097
- replaysOnErrorSampleRate: ((i = r == null ? void 0 : r.replay) == null ? void 0 : i.replaysOnErrorSampleRate) ?? 0,
2098
- replaysSessionSampleRate: ((o = r == null ? void 0 : r.replay) == null ? void 0 : o.replaysSessionSampleRate) ?? 0
2099
- }, this.additionalParams = (r == null ? void 0 : r.additionalParams) ?? {};
2100
- }
2101
- }
2102
- class ot {
2103
- /**
2104
- * Инициализирует экземпляр класса {@link VersionConfig}.
2105
- *
2106
- * @param data Данные для первоначальной инициализации.
2107
- */
2108
- constructor(r) {
2109
- /**
2110
- * Дата релиза текущей версии приложения.
2111
- */
2112
- t(this, "date");
2113
- /**
2114
- * Название релиза.
2115
- */
2116
- t(this, "name");
2117
- /**
2118
- * Текущая версия приложения.
2119
- */
2120
- t(this, "version");
2121
- 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";
2122
- }
2123
- }
2124
- class ct {
2125
- /**
2126
- * Инициализирует экземпляр класса {@link WebSocketConfig}.
2127
- *
2128
- * @param data Данные для первоначальной инициализации.
2129
- */
2130
- constructor(r) {
2131
- /**
2132
- * @inheritDoc
2133
- */
2134
- // eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
2135
- t(this, "broadcaster");
2136
- /**
2137
- * @inheritDoc
2138
- */
2139
- t(this, "key");
2140
- /**
2141
- * @inheritDoc
2142
- */
2143
- t(this, "wsHost");
2144
- /**
2145
- * @inheritDoc
2146
- */
2147
- t(this, "wsPort");
2148
- /**
2149
- * @inheritDoc
2150
- */
2151
- t(this, "wssPort");
2152
- /**
2153
- * @inheritDoc
2154
- */
2155
- t(this, "forceTLS");
2156
- /**
2157
- * @inheritDoc
2158
- */
2159
- t(this, "enabledTransports");
2160
- 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"];
2204
+ this.role = new ie(r == null ? void 0 : r.role), this.category = new pe(r == null ? void 0 : r.category), this.minCoefficient = new Pe(r == null ? void 0 : r.minCoefficient);
2161
2205
  }
2162
2206
  }
2163
- class Ft {
2164
- /**
2165
- * Инициализирует экземпляр класса {@link AppBaseConfig}.
2166
- *
2167
- * @param data Данные для первоначальной инициализации.
2168
- */
2169
- constructor(r) {
2170
- /**
2171
- * @inheritDoc
2172
- */
2173
- t(this, "environment");
2174
- /**
2175
- * @inheritDoc
2176
- */
2177
- t(this, "devMode");
2178
- /**
2179
- * @inheritDoc
2180
- */
2181
- t(this, "http");
2182
- /**
2183
- * @inheritDoc
2184
- */
2185
- t(this, "deviceTypeByResolution");
2186
- /**
2187
- * @inheritDoc
2188
- */
2189
- t(this, "sentry");
2190
- /**
2191
- * @inheritDoc
2192
- */
2193
- t(this, "tableDefaultHeightCoefficient");
2194
- /**
2195
- * @inheritDoc
2196
- */
2197
- t(this, "urls");
2198
- /**
2199
- * @inheritDoc
2200
- */
2201
- t(this, "version");
2202
- /**
2203
- * Конфигурация web-сокета.
2204
- */
2205
- t(this, "websocket");
2206
- /**
2207
- * @inheritDoc
2208
- */
2209
- t(this, "dateFormats");
2210
- var e, s, i;
2211
- this.environment = (r == null ? void 0 : r.environment) ?? "production", this.devMode = (r == null ? void 0 : r.devMode) ?? {}, this.http = new it(r == null ? void 0 : r.http), this.deviceTypeByResolution = new st(r == null ? void 0 : r.deviceTypeByResolution), this.sentry = new nt({
2212
- environment: this.environment,
2213
- ...r == null ? void 0 : r.sentry
2214
- }), this.tableDefaultHeightCoefficient = (r == null ? void 0 : r.tableDefaultHeightCoefficient) ?? 0.7, this.urls = r == null ? void 0 : r.urls, this.version = new ot(r == null ? void 0 : r.version), this.websocket = r != null && r.websocket ? new ct(r.websocket) : void 0, this.dateFormats = {
2215
- api: ((e = r == null ? void 0 : r.dateFormats) == null ? void 0 : e.api) ?? "yyyy-MM-dd HH:mm:ss",
2216
- uiDate: ((s = r == null ? void 0 : r.dateFormats) == null ? void 0 : s.uiDate) ?? "dd.MM.yyyy",
2217
- uiDateWithTime: ((i = r == null ? void 0 : r.dateFormats) == null ? void 0 : i.uiDateWithTime) ?? "dd.MM.yyyy HH:mm"
2218
- };
2219
- }
2220
- }
2221
- class Mt extends p {
2207
+ class Gt extends p {
2222
2208
  /**
2223
2209
  * Возвращает данные о результатах поиска категорий и товаров.
2224
2210
  *
@@ -2245,11 +2231,11 @@ class Mt extends p {
2245
2231
  */
2246
2232
  // eslint-disable-next-line class-methods-use-this
2247
2233
  getPriceExportLink(r = "csv", e = !1, s = void 0, i = void 0) {
2248
- let c = `${T.getConfig().http.portalApiUrl}/api/internal/price/export?format=${r}&show_hidden=${e}`;
2234
+ let c = `${b().config.http.portalApiUrl}/api/internal/price/export?format=${r}&show_hidden=${e}`;
2249
2235
  return s && (c += `&category_id=${s}`), i && (c += `&client_id=${i}`), c;
2250
2236
  }
2251
2237
  }
2252
- class Bt extends p {
2238
+ class Ft extends p {
2253
2239
  /**
2254
2240
  * Импортирует цены клиента из CSV файла.
2255
2241
  *
@@ -2448,7 +2434,7 @@ class Bt extends p {
2448
2434
  return this.post(`/internal/clients/${r}/price/commercial-offer/send`, e);
2449
2435
  }
2450
2436
  }
2451
- class Ht extends p {
2437
+ class Mt extends p {
2452
2438
  /**
2453
2439
  * Возвращает список шаблонов прайс-листа привязанных к клиенту.
2454
2440
  *
@@ -2460,7 +2446,7 @@ class Ht extends p {
2460
2446
  return this.get(
2461
2447
  `/internal/clients/${r}/price/templates`,
2462
2448
  {},
2463
- (e) => e.data.map((s) => new se(s))
2449
+ (e) => e.data.map((s) => new te(s))
2464
2450
  );
2465
2451
  }
2466
2452
  /**
@@ -2471,7 +2457,7 @@ class Ht extends p {
2471
2457
  * @see /doc/api/internal#/operations/api_internal_client_price_template_get_active
2472
2458
  */
2473
2459
  getActiveTemplate(r) {
2474
- return this.get(`/internal/clients/${r}/price/templates/active`, {}, (e) => new se(e.data), !0);
2460
+ return this.get(`/internal/clients/${r}/price/templates/active`, {}, (e) => new te(e.data), !0);
2475
2461
  }
2476
2462
  /**
2477
2463
  * Добавляет связь между клиентом и шаблоном прайс-листа.
@@ -2483,14 +2469,14 @@ class Ht extends p {
2483
2469
  * @see /doc/api/internal#/operations/api_internal_client_price_template_attach
2484
2470
  */
2485
2471
  attachTemplate(r, e, s) {
2486
- const i = T.getConfig().dateFormats.api;
2472
+ const i = b().config.dateFormats.api;
2487
2473
  return this.post(
2488
2474
  `/internal/clients/${r}/price/templates/${e}`,
2489
2475
  s && {
2490
2476
  startAt: s.startAt && x(s.startAt, i),
2491
2477
  endAt: s.endAt && x(s.endAt, i)
2492
2478
  },
2493
- (o) => new se(o.data),
2479
+ (o) => new te(o.data),
2494
2480
  {},
2495
2481
  !0
2496
2482
  );
@@ -2517,14 +2503,14 @@ class Ht extends p {
2517
2503
  * @see /doc/api/internal#/operations/api_internal_client_price_template_change
2518
2504
  */
2519
2505
  changeTemplate(r, e, s, i) {
2520
- const o = T.getConfig().dateFormats.api;
2506
+ const o = b().config.dateFormats.api;
2521
2507
  return this.patch(
2522
2508
  `/internal/clients/${r}/price/templates/${e}/${s}`,
2523
2509
  i && {
2524
2510
  startAt: i.startAt && x(i.startAt, o),
2525
2511
  endAt: i.endAt && x(i.endAt, o)
2526
2512
  },
2527
- (c) => new se(c.data)
2513
+ (c) => new te(c.data)
2528
2514
  );
2529
2515
  }
2530
2516
  /**
@@ -2540,7 +2526,7 @@ class Ht extends p {
2540
2526
  return this.delete(`/internal/clients/${r}/price/templates/${e}/${s}`);
2541
2527
  }
2542
2528
  }
2543
- class zt extends p {
2529
+ class Bt extends p {
2544
2530
  /**
2545
2531
  * Возвращает список данных о корневых категориях.
2546
2532
  *
@@ -2554,7 +2540,7 @@ class zt extends p {
2554
2540
  {
2555
2541
  showHidden: r
2556
2542
  },
2557
- (e) => e.data.map((s) => new H(s))
2543
+ (e) => e.data.map((s) => new z(s))
2558
2544
  );
2559
2545
  }
2560
2546
  /**
@@ -2573,7 +2559,7 @@ class zt extends p {
2573
2559
  showHidden: e,
2574
2560
  withNestedCategories: s
2575
2561
  },
2576
- (i) => new H(i.data)
2562
+ (i) => new z(i.data)
2577
2563
  );
2578
2564
  }
2579
2565
  /**
@@ -2582,7 +2568,7 @@ class zt extends p {
2582
2568
  * @param categoryID Идентификатор категории продуктов.
2583
2569
  */
2584
2570
  getPublicCategoryData(r) {
2585
- return this.get(`/public/catalog/categories/${r}`, {}, (e) => new H(e.data));
2571
+ return this.get(`/public/catalog/categories/${r}`, {}, (e) => new z(e.data));
2586
2572
  }
2587
2573
  /**
2588
2574
  * Возвращает список продуктов категории.
@@ -2600,7 +2586,7 @@ class zt extends p {
2600
2586
  showHidden: s,
2601
2587
  withPriceCoefficients: e
2602
2588
  },
2603
- (i) => Pe(i.data, (o) => new I(o))
2589
+ (i) => Ce(i.data, (o) => new I(o))
2604
2590
  );
2605
2591
  }
2606
2592
  /**
@@ -2613,7 +2599,7 @@ class zt extends p {
2613
2599
  getCategoryProductsCoefficients(r) {
2614
2600
  return this.get(`/internal/catalog/categories/${r}/products/coefficients`, {}, (e) => {
2615
2601
  const { data: s } = e;
2616
- return Or(s, (i) => i.map((o) => new je(o))), s;
2602
+ return _r(s, (i) => i.map((o) => new Ue(o))), s;
2617
2603
  });
2618
2604
  }
2619
2605
  /**
@@ -2625,14 +2611,14 @@ class zt extends p {
2625
2611
  publicSimpleSearch(r, e = 10) {
2626
2612
  return new Promise((s, i) => {
2627
2613
  this.get(`/public/catalog/search/simple?limit=${e}&term=${r}`).then((o) => {
2628
- s(o.categories.map((c) => new H(c)));
2614
+ s(o.categories.map((c) => new z(c)));
2629
2615
  }).catch((o) => {
2630
2616
  i(o);
2631
2617
  });
2632
2618
  });
2633
2619
  }
2634
2620
  }
2635
- class Wt extends p {
2621
+ class Ht extends p {
2636
2622
  /**
2637
2623
  * Возвращает данные об указанном продукте.
2638
2624
  *
@@ -2663,7 +2649,7 @@ class Wt extends p {
2663
2649
  return this.get(
2664
2650
  `/internal/catalog/products/${r}/coefficients`,
2665
2651
  {},
2666
- (e) => Pe(e.data, (s) => new je(s))
2652
+ (e) => Ce(e.data, (s) => new Ue(s))
2667
2653
  );
2668
2654
  }
2669
2655
  /**
@@ -2682,7 +2668,7 @@ class Wt extends p {
2682
2668
  });
2683
2669
  }
2684
2670
  }
2685
- class Et extends p {
2671
+ class zt extends p {
2686
2672
  /**
2687
2673
  * Возвращает список данных о корневых категориях указанного клиента.
2688
2674
  *
@@ -2698,7 +2684,7 @@ class Et extends p {
2698
2684
  clientId: r,
2699
2685
  showHidden: e
2700
2686
  },
2701
- (s) => s.data.map((i) => new ye(i))
2687
+ (s) => s.data.map((i) => new fe(i))
2702
2688
  );
2703
2689
  }
2704
2690
  /**
@@ -2719,7 +2705,7 @@ class Et extends p {
2719
2705
  showHidden: s,
2720
2706
  withNestedCategories: i
2721
2707
  },
2722
- (o) => new ye(o.data)
2708
+ (o) => new fe(o.data)
2723
2709
  );
2724
2710
  }
2725
2711
  /**
@@ -2740,11 +2726,11 @@ class Et extends p {
2740
2726
  showHidden: i,
2741
2727
  withPriceCoefficients: s
2742
2728
  },
2743
- (o) => Pe(o.data, (c) => new Y(c))
2729
+ (o) => Ce(o.data, (c) => new Y(c))
2744
2730
  );
2745
2731
  }
2746
2732
  }
2747
- class Jt extends p {
2733
+ class Wt extends p {
2748
2734
  /**
2749
2735
  * Возвращает данные об указанном продукте для указанного клиента.
2750
2736
  *
@@ -2765,8 +2751,8 @@ class Jt extends p {
2765
2751
  );
2766
2752
  }
2767
2753
  }
2768
- var We = /* @__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))(We || {});
2769
- class Qe {
2754
+ var ze = /* @__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))(ze || {});
2755
+ class Ke {
2770
2756
  /**
2771
2757
  * Инициализирует экземпляр класса {@link FilterItem}.
2772
2758
  *
@@ -2785,7 +2771,7 @@ class Qe {
2785
2771
  * Значение с которым сравнивается поле.
2786
2772
  */
2787
2773
  t(this, "value");
2788
- this.field = (r == null ? void 0 : r.field) ?? "", this.op = (r == null ? void 0 : r.op) ?? We.Equals, this.value = (r == null ? void 0 : r.value) ?? "";
2774
+ this.field = (r == null ? void 0 : r.field) ?? "", this.op = (r == null ? void 0 : r.op) ?? ze.Equals, this.value = (r == null ? void 0 : r.value) ?? "";
2789
2775
  }
2790
2776
  /**
2791
2777
  * Преобразует фильтр в примитивное представление для API.
@@ -2797,7 +2783,7 @@ class Qe {
2797
2783
  field: this.field,
2798
2784
  op: this.op
2799
2785
  };
2800
- return r.value = xe(this.value) ? x(this.value, T.getConfig().dateFormats.api) : this.value, r;
2786
+ return r.value = Le(this.value) ? x(this.value, b().config.dateFormats.api) : this.value, r;
2801
2787
  }
2802
2788
  }
2803
2789
  class le {
@@ -2820,7 +2806,7 @@ class le {
2820
2806
  */
2821
2807
  t(this, "groups");
2822
2808
  var e, s;
2823
- 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 Qe(i))) ?? [], this.groups = ((s = r == null ? void 0 : r.groups) == null ? void 0 : s.map((i) => new le(i))) ?? [];
2809
+ 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 le(i))) ?? [];
2824
2810
  }
2825
2811
  /**
2826
2812
  * Преобразует группу фильтров в примитивное представление для API.
@@ -2830,12 +2816,12 @@ class le {
2830
2816
  toPrimitive() {
2831
2817
  return {
2832
2818
  groupOp: this.groupOp,
2833
- filters: this.filters.map((r) => r instanceof Qe && Ne(r.toPrimitive) ? r.toPrimitive() : r),
2819
+ filters: this.filters.map((r) => r instanceof Ke && qe(r.toPrimitive) ? r.toPrimitive() : r),
2834
2820
  groups: this.groups.map((r) => r instanceof le ? r.toPrimitive() : r)
2835
2821
  };
2836
2822
  }
2837
2823
  }
2838
- class $e extends p {
2824
+ class Ae extends p {
2839
2825
  /**
2840
2826
  * Получает пагинированный список данных.
2841
2827
  *
@@ -2855,7 +2841,7 @@ class $e extends p {
2855
2841
  return e && (h.filters = JSON.stringify((e instanceof le ? e : new le(e)).toPrimitive())), K(s) || (h.sort = V(s) ? s : [s]), o && (h = { ...h, ...o }), this.get(r, h, c, u);
2856
2842
  }
2857
2843
  }
2858
- class Vt extends $e {
2844
+ class Et extends Ae {
2859
2845
  /**
2860
2846
  * Возвращает список шаблонов прайс-листа.
2861
2847
  *
@@ -2868,7 +2854,7 @@ class Vt extends $e {
2868
2854
  getTemplateList(r, e, s) {
2869
2855
  return this.getPaginated("/internal/price/templates", r, e, s, {}, (i) => {
2870
2856
  const o = { ...i.data };
2871
- return o.data = o.data.map((c) => new z(c)), o;
2857
+ return o.data = o.data.map((c) => new W(c)), o;
2872
2858
  });
2873
2859
  }
2874
2860
  /**
@@ -2881,7 +2867,7 @@ class Vt extends $e {
2881
2867
  * @see /doc/api/internal#/operations/api_internal_catalog_price_template_create
2882
2868
  */
2883
2869
  createTemplate(r, e = {}) {
2884
- return this.post("/internal/price/templates", r, (s) => new z(s.data), e);
2870
+ return this.post("/internal/price/templates", r, (s) => new W(s.data), e);
2885
2871
  }
2886
2872
  /**
2887
2873
  * Возвращает данные о шаблоне прайс-листа.
@@ -2891,7 +2877,7 @@ class Vt extends $e {
2891
2877
  * @see /doc/api/internal#/operations/api_internal_catalog_price_template_get
2892
2878
  */
2893
2879
  getTemplate(r) {
2894
- return this.get(`/internal/price/templates/${r}`, {}, (e) => new z(e.data));
2880
+ return this.get(`/internal/price/templates/${r}`, {}, (e) => new W(e.data));
2895
2881
  }
2896
2882
  /**
2897
2883
  * Изменяет данные о шаблоне прайс-листа.
@@ -2904,7 +2890,7 @@ class Vt extends $e {
2904
2890
  * @see /doc/api/internal#/operations/api_internal_catalog_price_template_update
2905
2891
  */
2906
2892
  updateTemplate(r, e, s = {}) {
2907
- return this.patch(`/internal/price/templates/${r}`, e, (i) => new z(i.data), s);
2893
+ return this.patch(`/internal/price/templates/${r}`, e, (i) => new W(i.data), s);
2908
2894
  }
2909
2895
  /**
2910
2896
  * Удаляет данные о шаблоне прайс-листа.
@@ -2927,7 +2913,7 @@ class Vt extends $e {
2927
2913
  return this.get(
2928
2914
  `/internal/price/templates/${r}/products`,
2929
2915
  {},
2930
- (e) => e.data.map((s) => new Se(s))
2916
+ (e) => e.data.map((s) => new ae(s))
2931
2917
  );
2932
2918
  }
2933
2919
  /**
@@ -2939,7 +2925,7 @@ class Vt extends $e {
2939
2925
  * @see /doc/api/internal#/operations/api_internal_catalog_price_template_product_get
2940
2926
  */
2941
2927
  getProductTemplatePrice(r, e) {
2942
- return this.get(`/internal/price/templates/${r}/products/${e}`, {}, (s) => new Se(s.data));
2928
+ return this.get(`/internal/price/templates/${r}/products/${e}`, {}, (s) => new ae(s.data));
2943
2929
  }
2944
2930
  /**
2945
2931
  * Сохраняет цену на продукт в шаблоне прайс-листа.
@@ -2958,7 +2944,7 @@ class Vt extends $e {
2958
2944
  price_coefficient_id: (i = s.coefficient) == null ? void 0 : i.id,
2959
2945
  increase_percent: s.value
2960
2946
  },
2961
- (o) => new Se(o.data)
2947
+ (o) => new ae(o.data)
2962
2948
  );
2963
2949
  }
2964
2950
  /**
@@ -2983,7 +2969,7 @@ class Vt extends $e {
2983
2969
  return this.get(
2984
2970
  `/internal/price/templates/${r}/categories`,
2985
2971
  {},
2986
- (e) => e.data.map((s) => new ae(s))
2972
+ (e) => e.data.map((s) => new be(s))
2987
2973
  );
2988
2974
  }
2989
2975
  /**
@@ -2998,7 +2984,7 @@ class Vt extends $e {
2998
2984
  return this.get(
2999
2985
  `/internal/price/templates/${r}/categories/${e}`,
3000
2986
  {},
3001
- (s) => new ae(s.data)
2987
+ (s) => new be(s.data)
3002
2988
  );
3003
2989
  }
3004
2990
  /**
@@ -3024,7 +3010,7 @@ class Vt extends $e {
3024
3010
  },
3025
3011
  params: i ? { recursively: !0 } : {}
3026
3012
  },
3027
- (c) => new ae(c.data)
3013
+ (c) => new be(c.data)
3028
3014
  );
3029
3015
  }
3030
3016
  /**
@@ -3055,18 +3041,18 @@ class Vt extends $e {
3055
3041
  return this.get(
3056
3042
  `/internal/price/templates/${r}/clients`,
3057
3043
  {},
3058
- (e) => e.data.map((s) => new se(s))
3044
+ (e) => e.data.map((s) => new te(s))
3059
3045
  );
3060
3046
  }
3061
3047
  }
3062
- class Kt extends p {
3048
+ class Jt extends p {
3063
3049
  /**
3064
3050
  * Возвращает список ролей ценообразования.
3065
3051
  *
3066
3052
  * @see /doc/api/internal#/operations/api_internal_catalog_price_roles_get_list
3067
3053
  */
3068
3054
  getRoles() {
3069
- return this.get("/internal/price/roles", {}, (r) => r.data.map((e) => new ne(e)));
3055
+ return this.get("/internal/price/roles", {}, (r) => r.data.map((e) => new ie(e)));
3070
3056
  }
3071
3057
  /**
3072
3058
  * Добавляет новую роль ценообразования.
@@ -3076,7 +3062,7 @@ class Kt extends p {
3076
3062
  * @see /doc/api/internal#/operations/api_internal_catalog_price_roles_create
3077
3063
  */
3078
3064
  createRole(r) {
3079
- return this.post("/internal/price/roles", r, (e) => new ne(e.data));
3065
+ return this.post("/internal/price/roles", r, (e) => new ie(e.data));
3080
3066
  }
3081
3067
  /**
3082
3068
  * Возвращает данные роли ценообразования.
@@ -3086,7 +3072,7 @@ class Kt extends p {
3086
3072
  * @see /doc/api/internal#/operations/api_internal_catalog_price_roles_get
3087
3073
  */
3088
3074
  getRole(r) {
3089
- return this.get(`/internal/price/roles/${r}`, {}, (e) => new ne(e.data));
3075
+ return this.get(`/internal/price/roles/${r}`, {}, (e) => new ie(e.data));
3090
3076
  }
3091
3077
  /**
3092
3078
  * Обновляет данные роли ценообразования.
@@ -3097,7 +3083,7 @@ class Kt extends p {
3097
3083
  * @see /doc/api/internal#/operations/api_internal_catalog_price_roles_update
3098
3084
  */
3099
3085
  updateRole(r, e) {
3100
- return this.patch(`/internal/price/roles/${r}`, e, (s) => new ne(s.data));
3086
+ return this.patch(`/internal/price/roles/${r}`, e, (s) => new ie(s.data));
3101
3087
  }
3102
3088
  /**
3103
3089
  * Удаляет роль ценообразования.
@@ -3120,7 +3106,7 @@ class Kt extends p {
3120
3106
  return this.get(
3121
3107
  `/internal/price/roles/rules/categories/${r}`,
3122
3108
  {},
3123
- (e) => e.data.map((s) => new Ke(s))
3109
+ (e) => e.data.map((s) => new Ve(s))
3124
3110
  );
3125
3111
  }
3126
3112
  /**
@@ -3135,11 +3121,11 @@ class Kt extends p {
3135
3121
  return this.patch(
3136
3122
  `/internal/price/roles/rules/categories/${r}`,
3137
3123
  e,
3138
- (s) => s.data.map((i) => new Ke(i))
3124
+ (s) => s.data.map((i) => new Ve(i))
3139
3125
  );
3140
3126
  }
3141
3127
  }
3142
- class Qt extends $e {
3128
+ class Vt extends Ae {
3143
3129
  /**
3144
3130
  * Возвращает пагинированный список свойств.
3145
3131
  *
@@ -3152,7 +3138,7 @@ class Qt extends $e {
3152
3138
  getProperties(r, e, s) {
3153
3139
  return this.getPaginated("/internal/catalog/properties", r, e, s, {}, (i) => {
3154
3140
  const o = { ...i.data };
3155
- return o.data = o.data.map((c) => new ie(c)), o;
3141
+ return o.data = o.data.map((c) => new se(c)), o;
3156
3142
  });
3157
3143
  }
3158
3144
  /**
@@ -3169,7 +3155,7 @@ class Qt extends $e {
3169
3155
  ...s,
3170
3156
  type: e
3171
3157
  },
3172
- (i) => new ie(i.data)
3158
+ (i) => new se(i.data)
3173
3159
  );
3174
3160
  }
3175
3161
  /**
@@ -3179,7 +3165,7 @@ class Qt extends $e {
3179
3165
  * @see /doc/api/internal#/operations/api_internal_catalog_properties_get
3180
3166
  */
3181
3167
  getProperty(r) {
3182
- return this.get(`/internal/catalog/properties/${r}`, {}, (e) => new ie(e.data));
3168
+ return this.get(`/internal/catalog/properties/${r}`, {}, (e) => new se(e.data));
3183
3169
  }
3184
3170
  /**
3185
3171
  * Обновляет существующее свойство.
@@ -3196,7 +3182,7 @@ class Qt extends $e {
3196
3182
  ...i,
3197
3183
  type: s
3198
3184
  },
3199
- (o) => new ie(o.data)
3185
+ (o) => new se(o.data)
3200
3186
  );
3201
3187
  }
3202
3188
  /**
@@ -3215,7 +3201,7 @@ class Qt extends $e {
3215
3201
  * @see /doc/api/internal#/operations/api_internal_catalog_product_properties_get_list
3216
3202
  */
3217
3203
  getProductProperties(r) {
3218
- return this.get(`/internal/catalog/products/${r}/properties`, {}, (e) => e.data.map((s) => new B(s)));
3204
+ return this.get(`/internal/catalog/products/${r}/properties`, {}, (e) => e.data.map((s) => new H(s)));
3219
3205
  }
3220
3206
  /**
3221
3207
  * Возвращает значение свойства продукта.
@@ -3225,7 +3211,7 @@ class Qt extends $e {
3225
3211
  * @see /doc/api/internal#/operations/api_internal_catalog_product_properties_get
3226
3212
  */
3227
3213
  getProductProperty(r, e) {
3228
- return this.get(`/internal/catalog/products/${r}/properties/${e}`, {}, (s) => new B(s.data));
3214
+ return this.get(`/internal/catalog/products/${r}/properties/${e}`, {}, (s) => new H(s.data));
3229
3215
  }
3230
3216
  /**
3231
3217
  * Обновляет значение свойства продукта.
@@ -3236,7 +3222,7 @@ class Qt extends $e {
3236
3222
  * @see /doc/api/internal#/operations/api_internal_catalog_product_properties_update
3237
3223
  */
3238
3224
  updateProductProperty(r, e, s) {
3239
- return this.patch(`/internal/catalog/products/${r}/properties/${e}`, { value: s }, (i) => new B(i.data));
3225
+ return this.patch(`/internal/catalog/products/${r}/properties/${e}`, { value: s }, (i) => new H(i.data));
3240
3226
  }
3241
3227
  /**
3242
3228
  * Удаляет значение свойства продукта.
@@ -3361,7 +3347,7 @@ class Qt extends $e {
3361
3347
  * @see /doc/api/internal#/operations/api_internal_catalog_category_properties_get_list
3362
3348
  */
3363
3349
  getCategoryProperties(r) {
3364
- return this.get(`/internal/catalog/categories/${r}/properties`, {}, (e) => e.data.map((s) => new B(s)));
3350
+ return this.get(`/internal/catalog/categories/${r}/properties`, {}, (e) => e.data.map((s) => new H(s)));
3365
3351
  }
3366
3352
  /**
3367
3353
  * Возвращает значение свойства категории.
@@ -3371,7 +3357,7 @@ class Qt extends $e {
3371
3357
  * @see /doc/api/internal#/operations/api_internal_catalog_category_properties_get
3372
3358
  */
3373
3359
  getCategoryProperty(r, e) {
3374
- return this.get(`/internal/catalog/categories/${r}/properties/${e}`, {}, (s) => new B(s.data));
3360
+ return this.get(`/internal/catalog/categories/${r}/properties/${e}`, {}, (s) => new H(s.data));
3375
3361
  }
3376
3362
  /**
3377
3363
  * Обновляет значение свойства категории.
@@ -3382,7 +3368,7 @@ class Qt extends $e {
3382
3368
  * @see /doc/api/internal#/operations/api_internal_catalog_category_properties_update
3383
3369
  */
3384
3370
  updateCategoryProperty(r, e, s) {
3385
- return this.patch(`/internal/catalog/categories/${r}/properties/${e}`, { value: s }, (i) => new B(i.data));
3371
+ return this.patch(`/internal/catalog/categories/${r}/properties/${e}`, { value: s }, (i) => new H(i.data));
3386
3372
  }
3387
3373
  /**
3388
3374
  * Удаляет значение свойства категории.
@@ -3511,7 +3497,7 @@ class Qt extends $e {
3511
3497
  return this.post(`/internal/catalog/categories/${r}/image`, { image: e });
3512
3498
  }
3513
3499
  }
3514
- function Ye(n, r, e) {
3500
+ function Qe(n, r, e) {
3515
3501
  let s;
3516
3502
  return n.some((i) => {
3517
3503
  if (i.type === e && i.id === r)
@@ -3520,37 +3506,37 @@ function Ye(n, r, e) {
3520
3506
  return !1;
3521
3507
  const o = i;
3522
3508
  if (o.products && o.products.length > 0) {
3523
- const c = Ye(o.products, r, e);
3509
+ const c = Qe(o.products, r, e);
3524
3510
  if (c)
3525
3511
  return s = c, !0;
3526
3512
  }
3527
3513
  if (o.categories && o.categories.length > 0) {
3528
- const c = Ye(o.categories, r, e);
3514
+ const c = Qe(o.categories, r, e);
3529
3515
  if (c)
3530
3516
  return s = c, !0;
3531
3517
  }
3532
3518
  return !1;
3533
3519
  }), s;
3534
3520
  }
3535
- function Xe(n) {
3521
+ function Ye(n) {
3536
3522
  const r = [];
3537
3523
  return n.forEach((e) => {
3538
3524
  if (r.push(e), e.type === "category") {
3539
3525
  const s = e;
3540
- s.products && s.products.length > 0 && r.push(...Xe(s.products)), s.categories && s.categories.length > 0 && r.push(...Xe(s.categories));
3526
+ s.products && s.products.length > 0 && r.push(...Ye(s.products)), s.categories && s.categories.length > 0 && r.push(...Ye(s.categories));
3541
3527
  }
3542
3528
  }), r;
3543
3529
  }
3544
- var lt = /* @__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.Curators = "curators", n))(lt || {}), _ = /* @__PURE__ */ ((n) => (n.Person = "individual", n.Ic = "entrepreneur", n.UlR = "legal", n.UlNr = "non_resident_legal", n))(_ || {});
3545
- class ut extends P {
3530
+ 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.Curators = "curators", n))(ct || {}), _ = /* @__PURE__ */ ((n) => (n.Person = "individual", n.Ic = "entrepreneur", n.UlR = "legal", n.UlNr = "non_resident_legal", n))(_ || {});
3531
+ class lt extends P {
3546
3532
  }
3547
- class Cr extends P {
3533
+ class wr extends P {
3548
3534
  }
3549
- class Yt extends P {
3535
+ class Kt extends P {
3550
3536
  }
3551
- class pt extends P {
3537
+ class ut extends P {
3552
3538
  }
3553
- class we extends b {
3539
+ class ye extends T {
3554
3540
  /**
3555
3541
  * Инициализирует экземпляр класса {@link Currency}.
3556
3542
  *
@@ -3582,21 +3568,21 @@ class N extends P {
3582
3568
  });
3583
3569
  }
3584
3570
  }
3585
- class ht extends P {
3571
+ class pt extends P {
3586
3572
  }
3587
- class gt extends P {
3573
+ class ht extends P {
3588
3574
  }
3589
3575
  class Z extends P {
3590
3576
  }
3591
- class mt extends P {
3577
+ class gt extends P {
3592
3578
  }
3593
- class ft extends P {
3579
+ class mt extends P {
3594
3580
  }
3595
3581
  class vr extends P {
3596
3582
  }
3597
- class Pr extends P {
3583
+ class Cr extends P {
3598
3584
  }
3599
- class Oe extends j {
3585
+ class de extends G {
3600
3586
  /**
3601
3587
  * Инициализирует экземпляр класса {@link BankAccount}.
3602
3588
  *
@@ -3623,11 +3609,11 @@ class Oe extends j {
3623
3609
  /**
3624
3610
  * Данные о валюте.
3625
3611
  */
3626
- t(this, "currency", new we());
3627
- e && (this.bankName = e.bankName ?? "", this.bic = e.bic ?? "", this.accountNumber = e.accountNumber ?? "", this.correspondentAccount = e.correspondentAccount ?? "", this.currency = new we(e.currency));
3612
+ t(this, "currency", new ye());
3613
+ e && (this.bankName = e.bankName ?? "", this.bic = e.bic ?? "", this.accountNumber = e.accountNumber ?? "", this.correspondentAccount = e.correspondentAccount ?? "", this.currency = new ye(e.currency));
3628
3614
  }
3629
3615
  }
3630
- class qe extends b {
3616
+ class Oe extends T {
3631
3617
  /**
3632
3618
  * Инициализирует экземпляр класса {@link Contact}.
3633
3619
  *
@@ -3646,7 +3632,7 @@ class qe extends b {
3646
3632
  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;
3647
3633
  }
3648
3634
  }
3649
- class U extends qe {
3635
+ class U extends Oe {
3650
3636
  /**
3651
3637
  * Инициализирует экземпляр класса {@link ContactPerson}.
3652
3638
  *
@@ -3678,10 +3664,10 @@ class U extends qe {
3678
3664
  * Дата и время последнего удаления.
3679
3665
  */
3680
3666
  t(this, "deletedAt");
3681
- 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;
3667
+ 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 = v(e == null ? void 0 : e.deletedAt) ? C(e.deletedAt) : e == null ? void 0 : e.deletedAt;
3682
3668
  }
3683
3669
  }
3684
- class Rr extends b {
3670
+ class Pr extends T {
3685
3671
  /**
3686
3672
  * Инициализирует экземпляр класса {@link ContragentBase}.
3687
3673
  *
@@ -3731,7 +3717,7 @@ class Rr extends b {
3731
3717
  */
3732
3718
  t(this, "updater");
3733
3719
  if (e) {
3734
- if (this.opf = new N(e.opf), 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 d(e.creator) : void 0, this.updatedAt = C(e == null ? void 0 : e.updatedAt) ? v(e.updatedAt) : e.updatedAt, this.updater = e.updater ? new d(e.updater) : void 0, e.partnerGroup && (this.partnerGroup = new Z(e.partnerGroup)), e.contacts) {
3720
+ if (this.opf = new N(e.opf), this.comment = e.comment, this.alternativeName = e.alternativeName, this.createdAt = v(e == null ? void 0 : e.createdAt) ? C(e.createdAt) : e.createdAt, this.creator = e.creator ? new d(e.creator) : void 0, this.updatedAt = v(e == null ? void 0 : e.updatedAt) ? C(e.updatedAt) : e.updatedAt, this.updater = e.updater ? new d(e.updater) : void 0, e.partnerGroup && (this.partnerGroup = new Z(e.partnerGroup)), e.contacts) {
3735
3721
  const s = [];
3736
3722
  e.contacts.forEach((i) => {
3737
3723
  s.push(new U(i));
@@ -3740,13 +3726,13 @@ class Rr extends b {
3740
3726
  if (e.bankAccounts) {
3741
3727
  const s = [];
3742
3728
  e.bankAccounts.forEach((i) => {
3743
- s.push(new Oe(i));
3729
+ s.push(new de(i));
3744
3730
  }), this.bankAccounts = s;
3745
3731
  }
3746
3732
  }
3747
3733
  }
3748
3734
  }
3749
- class yt extends Rr {
3735
+ class ft extends Pr {
3750
3736
  /**
3751
3737
  * Инициализирует экземпляр класса {@link ContragentPerson}.
3752
3738
  *
@@ -3756,7 +3742,7 @@ class yt extends Rr {
3756
3742
  super(r);
3757
3743
  }
3758
3744
  }
3759
- class Dr extends Rr {
3745
+ class Rr extends Pr {
3760
3746
  /**
3761
3747
  * Инициализирует экземпляр класса {@link ContragentIc}.
3762
3748
  *
@@ -3799,7 +3785,7 @@ class Dr extends Rr {
3799
3785
  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 ?? "");
3800
3786
  }
3801
3787
  }
3802
- class Ar extends Dr {
3788
+ class Dr extends Rr {
3803
3789
  /**
3804
3790
  * Инициализирует экземпляр класса {@link ContragentUlR}.
3805
3791
  *
@@ -3814,7 +3800,7 @@ class Ar extends Dr {
3814
3800
  e && (this.kpp = e.kpp ?? "");
3815
3801
  }
3816
3802
  }
3817
- class wt extends Ar {
3803
+ class yt extends Dr {
3818
3804
  /**
3819
3805
  * Инициализирует экземпляр класса {@link ContragentUlNr}.
3820
3806
  *
@@ -3837,7 +3823,7 @@ class wt extends Ar {
3837
3823
  e && (this.registrationCountry = new X(e.registrationCountry), this.registrationNumber = e.registrationNumber ?? "", this.taxNumber = e.taxNumber ?? "");
3838
3824
  }
3839
3825
  }
3840
- class Ce {
3826
+ class we {
3841
3827
  /**
3842
3828
  * Инициализирует и возвращает экземпляр класса с данными о контрагенте.
3843
3829
  *
@@ -3846,17 +3832,17 @@ class Ce {
3846
3832
  static createInstance(r) {
3847
3833
  switch (r.opf.slug) {
3848
3834
  case _.Ic:
3849
- return new Dr(r);
3835
+ return new Rr(r);
3850
3836
  case _.UlR:
3851
- return new Ar(r);
3837
+ return new Dr(r);
3852
3838
  case _.UlNr:
3853
- return new wt(r);
3854
- default:
3855
3839
  return new yt(r);
3840
+ default:
3841
+ return new ft(r);
3856
3842
  }
3857
3843
  }
3858
3844
  }
3859
- class Ie extends j {
3845
+ class Se extends G {
3860
3846
  /**
3861
3847
  * Инициализирует экземпляр класса {@link ContactRelation}.
3862
3848
  *
@@ -3871,7 +3857,7 @@ class Ie extends j {
3871
3857
  this.isPrimary = e.isPrimary;
3872
3858
  }
3873
3859
  }
3874
- class Ct extends U {
3860
+ class wt extends U {
3875
3861
  /**
3876
3862
  * Инициализирует экземпляр класса {@link ContactPersonRelated}.
3877
3863
  *
@@ -3896,10 +3882,10 @@ class Ct extends U {
3896
3882
  */
3897
3883
  addresses: []
3898
3884
  });
3899
- 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))));
3885
+ e.relations && (e.relations.addresses && (this.relations.addresses = e.relations.addresses.map((s) => new Se(s))), e.relations.clients && (this.relations.clients = e.relations.clients.map((s) => new Se(s))), e.relations.contragents && (this.relations.contragents = e.relations.contragents.map((s) => new Se(s))));
3900
3886
  }
3901
3887
  }
3902
- class ve extends Zr {
3888
+ class ve extends st {
3903
3889
  /**
3904
3890
  * Инициализирует экземпляр класса {@link DeliveryAddress}.
3905
3891
  *
@@ -3936,10 +3922,10 @@ class ve extends Zr {
3936
3922
  * Признак того, что указанный адрес является адресом транспортной компании.
3937
3923
  */
3938
3924
  t(this, "isTransportCompanyAddress");
3939
- this.address = (e == null ? void 0 : e.address) ?? "", this.coordinates = new hr(e == null ? void 0 : e.coordinates), this.contacts = ((s = e == null ? void 0 : e.contacts) == null ? void 0 : s.map((i) => new U(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;
3925
+ this.address = (e == null ? void 0 : e.address) ?? "", this.coordinates = new pr(e == null ? void 0 : e.coordinates), this.contacts = ((s = e == null ? void 0 : e.contacts) == null ? void 0 : s.map((i) => new U(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;
3940
3926
  }
3941
3927
  }
3942
- class Ze extends he {
3928
+ class Xe extends he {
3943
3929
  /**
3944
3930
  * Инициализирует экземпляр класса {@link Client}.
3945
3931
  *
@@ -3989,10 +3975,10 @@ class Ze extends he {
3989
3975
  * @inheritDoc
3990
3976
  */
3991
3977
  t(this, "extraData");
3992
- this.contragents = ((s = e == null ? void 0 : e.contragents) == null ? void 0 : s.map((u) => Ce.createInstance(u))) ?? [], this.partnerGroups = ((i = e == null ? void 0 : e.partnerGroups) == null ? void 0 : i.map((u) => new Z(u))) ?? [], this.contacts = ((o = e == null ? void 0 : e.contacts) == null ? void 0 : o.map((u) => new U(u))) ?? [], this.deliveryAddresses = ((c = e == null ? void 0 : e.deliveryAddresses) == null ? void 0 : c.map((u) => new ve(u))) ?? [], this.channelPrimaryInterest = new Cr(e == null ? void 0 : e.channelPrimaryInterest), this.sourcePrimaryInterest = new Pr(e == null ? void 0 : e.sourcePrimaryInterest), this.preferredDeliveryType = new Q(e == null ? void 0 : e.preferredDeliveryType), this.primaryDemand = e == null ? void 0 : e.primaryDemand, this.preferredWarehouse = e != null && e.preferredWarehouse ? new De(e.preferredWarehouse) : void 0, this.extraData = (e == null ? void 0 : e.extraData) ?? {};
3978
+ this.contragents = ((s = e == null ? void 0 : e.contragents) == null ? void 0 : s.map((u) => we.createInstance(u))) ?? [], this.partnerGroups = ((i = e == null ? void 0 : e.partnerGroups) == null ? void 0 : i.map((u) => new Z(u))) ?? [], this.contacts = ((o = e == null ? void 0 : e.contacts) == null ? void 0 : o.map((u) => new U(u))) ?? [], this.deliveryAddresses = ((c = e == null ? void 0 : e.deliveryAddresses) == null ? void 0 : c.map((u) => new ve(u))) ?? [], this.channelPrimaryInterest = new wr(e == null ? void 0 : e.channelPrimaryInterest), this.sourcePrimaryInterest = new Cr(e == null ? void 0 : e.sourcePrimaryInterest), this.preferredDeliveryType = new Q(e == null ? void 0 : e.preferredDeliveryType), this.primaryDemand = e == null ? void 0 : e.primaryDemand, this.preferredWarehouse = e != null && e.preferredWarehouse ? new Re(e.preferredWarehouse) : void 0, this.extraData = (e == null ? void 0 : e.extraData) ?? {};
3993
3979
  }
3994
3980
  }
3995
- class Xt {
3981
+ class Qt {
3996
3982
  /**
3997
3983
  * Инициализирует экземпляр класса {@link ClientsListFilters}.
3998
3984
  *
@@ -4092,7 +4078,7 @@ class Xt {
4092
4078
  */
4093
4079
  t(this, "lastOrder");
4094
4080
  var e, s, i, o, c, u, h, f;
4095
- 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((g) => new ze(g)), this.region = new ce(r == null ? void 0 : r.region), this.country = new X(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 L(r == null ? void 0 : r.createdAt), this.lastLoginDate = new L(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((g) => new Ae(g))) ?? [], this.curators = ((i = r == null ? void 0 : r.curators) == null ? void 0 : i.map((g) => new He(g))) ?? [], this.salesDirections = (o = r == null ? void 0 : r.salesDirections) == null ? void 0 : o.map((g) => new O(g)), this.contragentInn = r == null ? void 0 : r.contragentInn, this.contragentType = new N(r == null ? void 0 : r.contragentType), this.preferredDeliveryType = new Q(r == null ? void 0 : r.preferredDeliveryType), this.partnerGroups = (c = r == null ? void 0 : r.partnerGroups) == null ? void 0 : c.map((g) => new Z(g)), this.contact = new qe(r == null ? void 0 : r.contact), this.lastOrder = {
4081
+ 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((g) => new He(g)), this.region = new ce(r == null ? void 0 : r.region), this.country = new X(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 L(r == null ? void 0 : r.createdAt), this.lastLoginDate = new L(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((g) => new De(g))) ?? [], this.curators = ((i = r == null ? void 0 : r.curators) == null ? void 0 : i.map((g) => new Be(g))) ?? [], this.salesDirections = (o = r == null ? void 0 : r.salesDirections) == null ? void 0 : o.map((g) => new O(g)), this.contragentInn = r == null ? void 0 : r.contragentInn, this.contragentType = new N(r == null ? void 0 : r.contragentType), this.preferredDeliveryType = new Q(r == null ? void 0 : r.preferredDeliveryType), this.partnerGroups = (c = r == null ? void 0 : r.partnerGroups) == null ? void 0 : c.map((g) => new Z(g)), this.contact = new Oe(r == null ? void 0 : r.contact), this.lastOrder = {
4096
4082
  createdAt: new L((u = r == null ? void 0 : r.lastOrder) == null ? void 0 : u.createdAt),
4097
4083
  creator: (h = r == null ? void 0 : r.lastOrder) == null ? void 0 : h.creator,
4098
4084
  isApproved: (f = r == null ? void 0 : r.lastOrder) == null ? void 0 : f.isApproved
@@ -4142,7 +4128,7 @@ class Xt {
4142
4128
  this.partnerGroups = [];
4143
4129
  break;
4144
4130
  case "contact":
4145
- this.contact = new qe();
4131
+ this.contact = new Oe();
4146
4132
  break;
4147
4133
  default:
4148
4134
  this[r] = void 0;
@@ -4160,11 +4146,11 @@ class Xt {
4160
4146
  return Object.keys(this).forEach((c) => {
4161
4147
  const u = this[c];
4162
4148
  // eslint-disable-next-line prettier/prettier
4163
- A(u) || C(u) && u.trim().length === 0 || Ne(u.isNewRec) && u.isNewRec() || (r[c] = u);
4149
+ A(u) || v(u) && u.trim().length === 0 || qe(u.isNewRec) && u.isNewRec() || (r[c] = u);
4164
4150
  }), !((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;
4165
4151
  }
4166
4152
  }
4167
- class $r extends j {
4153
+ class Ar extends G {
4168
4154
  /**
4169
4155
  * Инициализирует экземпляр класса {@link OrderShortInfo}.
4170
4156
  *
@@ -4184,10 +4170,10 @@ class $r extends j {
4184
4170
  * Признак того, что заказ подтвержден в 1С.
4185
4171
  */
4186
4172
  t(this, "isApproved1c");
4187
- this.createdAt = C(e == null ? void 0 : e.createdAt) ? v(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;
4173
+ this.createdAt = v(e == null ? void 0 : e.createdAt) ? C(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;
4188
4174
  }
4189
4175
  }
4190
- class vt extends b {
4176
+ class vt extends T {
4191
4177
  /**
4192
4178
  * Инициализирует экземпляр класса {@link ClientAdditionalData}.
4193
4179
  *
@@ -4224,10 +4210,10 @@ class vt extends b {
4224
4210
  * @inheritDoc
4225
4211
  */
4226
4212
  t(this, "curators");
4227
- this.contacts = ((s = e.contacts) == null ? void 0 : s.map((u) => new U(u))) ?? void 0, this.lastOrder = e.lastOrder ? new $r(e.lastOrder) : void 0, this.partnerGroups = ((i = e.partnerGroups) == null ? void 0 : i.map((u) => new Z(u))) ?? void 0, this.preferredDeliveryType = e.preferredDeliveryType ? new Q(e.preferredDeliveryType) : void 0, this.salesDirection = e.salesDirection ? new O(e.salesDirection) : void 0, this.managers = ((o = e.managers) == null ? void 0 : o.map((u) => new Me(u))) ?? void 0, this.curators = ((c = e.curators) == null ? void 0 : c.map((u) => new He(u))) ?? void 0;
4213
+ this.contacts = ((s = e.contacts) == null ? void 0 : s.map((u) => new U(u))) ?? void 0, this.lastOrder = e.lastOrder ? new Ar(e.lastOrder) : void 0, this.partnerGroups = ((i = e.partnerGroups) == null ? void 0 : i.map((u) => new Z(u))) ?? void 0, this.preferredDeliveryType = e.preferredDeliveryType ? new Q(e.preferredDeliveryType) : void 0, this.salesDirection = e.salesDirection ? new O(e.salesDirection) : void 0, this.managers = ((o = e.managers) == null ? void 0 : o.map((u) => new Fe(u))) ?? void 0, this.curators = ((c = e.curators) == null ? void 0 : c.map((u) => new Be(u))) ?? void 0;
4228
4214
  }
4229
4215
  }
4230
- class Pt {
4216
+ class Ct {
4231
4217
  /**
4232
4218
  * Инициализирует экземпляр класса {@link DataTablePaginationRequestParams}.
4233
4219
  *
@@ -4245,7 +4231,7 @@ class Pt {
4245
4231
  this.page = (r == null ? void 0 : r.page) ?? 1, this.pageSize = (r == null ? void 0 : r.pageSize) ?? 50;
4246
4232
  }
4247
4233
  }
4248
- class Zt extends Pt {
4234
+ class Yt extends Ct {
4249
4235
  /**
4250
4236
  * Инициализирует экземпляр класса {@link DataTablePagination}.
4251
4237
  *
@@ -4276,7 +4262,7 @@ class Zt extends Pt {
4276
4262
  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;
4277
4263
  }
4278
4264
  }
4279
- class es {
4265
+ class Xt {
4280
4266
  /**
4281
4267
  * Инициализирует экземпляр класса {@link ISortRequestParams}.
4282
4268
  *
@@ -4294,7 +4280,7 @@ class es {
4294
4280
  this.field = (r == null ? void 0 : r.field) ?? "", this.direction = (r == null ? void 0 : r.direction) ?? "asc";
4295
4281
  }
4296
4282
  }
4297
- class k extends $e {
4283
+ class k extends Ae {
4298
4284
  /**
4299
4285
  * Преобразует данные о клиенте в данные требуемые для запроса.
4300
4286
  *
@@ -4433,7 +4419,7 @@ class k extends $e {
4433
4419
  * @see /doc/api/internal#/Клиенты/api_internal_client_get_full_info
4434
4420
  */
4435
4421
  getClient(r) {
4436
- return this.get(`/internal/clients/${r}`, {}, (e) => new Ze(e.data));
4422
+ return this.get(`/internal/clients/${r}`, {}, (e) => new Xe(e.data));
4437
4423
  }
4438
4424
  /**
4439
4425
  * Возвращает данные о клиентах, удовлетворяющих указанным параметрам поиска.
@@ -4461,7 +4447,7 @@ class k extends $e {
4461
4447
  return this.getClientsList({
4462
4448
  groupOp: "and",
4463
4449
  groups: [],
4464
- filters: [{ field: "phone", op: We.Contains, value: r }]
4450
+ filters: [{ field: "phone", op: ze.Contains, value: r }]
4465
4451
  });
4466
4452
  }
4467
4453
  /**
@@ -4487,7 +4473,7 @@ class k extends $e {
4487
4473
  getAllClientContacts(r) {
4488
4474
  return this.get(`/internal/clients/${r}/contacts/all`, {}, (e) => {
4489
4475
  let s = [];
4490
- return (e == null ? void 0 : e.data.length) > 0 && (s = e.data.map((i) => new Ct(i))), s;
4476
+ return (e == null ? void 0 : e.data.length) > 0 && (s = e.data.map((i) => new wt(i))), s;
4491
4477
  });
4492
4478
  }
4493
4479
  /**
@@ -4498,7 +4484,7 @@ class k extends $e {
4498
4484
  * @see /doc/api/internal#/Клиенты/api_internal_client_create
4499
4485
  */
4500
4486
  createClientCommonData(r, e = {}) {
4501
- return this.post("/internal/clients", k.transformClientDataToRequest(r), (s) => new Ze(s.data), e);
4487
+ return this.post("/internal/clients", k.transformClientDataToRequest(r), (s) => new Xe(s.data), e);
4502
4488
  }
4503
4489
  /**
4504
4490
  * Обновляет данные указанного клиента.
@@ -4638,7 +4624,7 @@ class k extends $e {
4638
4624
  return this.post(
4639
4625
  `/internal/clients/${r}/contragents`,
4640
4626
  k.transformContragentClientDataToRequest(e),
4641
- (i) => Ce.createInstance(i.data),
4627
+ (i) => we.createInstance(i.data),
4642
4628
  s
4643
4629
  );
4644
4630
  }
@@ -4654,7 +4640,7 @@ class k extends $e {
4654
4640
  return this.patch(
4655
4641
  `/internal/clients/${r}/contragents/${e.id}`,
4656
4642
  k.transformContragentClientDataToRequest(e),
4657
- (i) => Ce.createInstance(i.data),
4643
+ (i) => we.createInstance(i.data),
4658
4644
  s
4659
4645
  );
4660
4646
  }
@@ -4723,7 +4709,7 @@ class k extends $e {
4723
4709
  return this.post(
4724
4710
  `/internal/clients/${r}/contragents/${e}/bank-accounts`,
4725
4711
  k.transformClientContragentBankAccountToRequest(s),
4726
- (o) => new Oe(o.data),
4712
+ (o) => new de(o.data),
4727
4713
  i
4728
4714
  );
4729
4715
  }
@@ -4740,7 +4726,7 @@ class k extends $e {
4740
4726
  return this.patch(
4741
4727
  `/internal/clients/${r}/contragents/${e}/bank-accounts/${s.id}`,
4742
4728
  k.transformClientContragentBankAccountToRequest(s),
4743
- (o) => new Oe(o.data),
4729
+ (o) => new de(o.data),
4744
4730
  i
4745
4731
  );
4746
4732
  }
@@ -4972,7 +4958,7 @@ const E = class E extends p {
4972
4958
  * Время кэширования данных ответов на запросы (секунд).
4973
4959
  */
4974
4960
  t(this, "responseDataCacheTimeout");
4975
- this.responseDataCacheTimeout = T.getConfig().http.responseDataCacheTimeout;
4961
+ this.responseDataCacheTimeout = b().config.http.responseDataCacheTimeout;
4976
4962
  }
4977
4963
  /**
4978
4964
  * Возвращает кэшированные данные.
@@ -4994,7 +4980,7 @@ const E = class E extends p {
4994
4980
  */
4995
4981
  cacheResponse(e, s) {
4996
4982
  E.responseDataCache.set(e, {
4997
- validTo: qr(/* @__PURE__ */ new Date(), this.responseDataCacheTimeout),
4983
+ validTo: dr(/* @__PURE__ */ new Date(), this.responseDataCacheTimeout),
4998
4984
  val: s
4999
4985
  });
5000
4986
  }
@@ -5011,7 +4997,7 @@ const E = class E extends p {
5011
4997
  getTypedDataArrayRequester(e, s, i = !1, o = {}) {
5012
4998
  const c = s + (K(o) ? "" : ` >>> ${JSON.stringify(o)}`), u = i ? E.getCachedResponse(c) : void 0;
5013
4999
  return u ? Promise.resolve(u) : this.get(s, o).then((h) => {
5014
- const f = h.map((g) => Ge.instanceInitializer(e, g));
5000
+ const f = h.map((g) => je.instanceInitializer(e, g));
5015
5001
  return i && f && this.cacheResponse(s, f), f;
5016
5002
  });
5017
5003
  }
@@ -5021,7 +5007,7 @@ const E = class E extends p {
5021
5007
  */
5022
5008
  t(E, "responseDataCache", /* @__PURE__ */ new Map());
5023
5009
  let ue = E;
5024
- class rs extends p {
5010
+ class Zt extends p {
5025
5011
  /**
5026
5012
  * Выполняет проверку занят ли указанный номер телефона.
5027
5013
  *
@@ -5035,7 +5021,15 @@ class rs extends p {
5035
5021
  });
5036
5022
  }
5037
5023
  }
5038
- class ts extends p {
5024
+ function es(n = "/config.json") {
5025
+ const r = fetch(n).then((e) => e.ok ? e.json() : (console.error(new Error(`Ошибка загрузки ${n}: ${e.statusText}`)), new Promise((s) => {
5026
+ s({});
5027
+ })));
5028
+ return r.catch((e) => {
5029
+ console.error(e);
5030
+ }), r;
5031
+ }
5032
+ class rs extends p {
5039
5033
  /**
5040
5034
  * Возвращает настройки указанного конфигуратора для указанной категории.
5041
5035
  *
@@ -5110,18 +5104,18 @@ class ts extends p {
5110
5104
  return this.delete(`internal/catalog/categories/${r.id}/configurators/${(i = r.properties) == null ? void 0 : i.configurator}/template/${s}?client_id=${e}`);
5111
5105
  }
5112
5106
  }
5113
- class ss {
5107
+ class ts {
5114
5108
  /**
5115
5109
  * Возвращает диапазон дат по умолчанию.
5116
5110
  */
5117
5111
  static defaultDateRanges() {
5118
- const r = Nr(/* @__PURE__ */ new Date(), 1);
5112
+ const r = Or(/* @__PURE__ */ new Date(), 1);
5119
5113
  return {
5120
5114
  // 'Следующий рабочий день' - это значение по-умолчанию
5121
- nextWorkingDay: { label: "Следующий рабочий день", from: Hr(r), to: Br(r) },
5122
- today: { label: "Сегодня", from: _e(), to: Mr() },
5123
- yesterday: { label: "Вчера", from: Fr(), to: Gr() },
5124
- tomorrow: { label: "Завтра", from: jr(), to: Ur() }
5115
+ nextWorkingDay: { label: "Следующий рабочий день", from: Mr(r), to: Fr(r) },
5116
+ today: { label: "Сегодня", from: xe(), to: Gr() },
5117
+ yesterday: { label: "Вчера", from: jr(), to: Ur() },
5118
+ tomorrow: { label: "Завтра", from: Nr(), to: qr() }
5125
5119
  };
5126
5120
  }
5127
5121
  }
@@ -5165,13 +5159,13 @@ const J = class J {
5165
5159
  * Список единиц измерения линейной величины.
5166
5160
  */
5167
5161
  t(J, "linearValues", ["пог.м.", "м.", "м2"]);
5168
- let er = J;
5169
- class is {
5162
+ let Ze = J;
5163
+ class ss {
5170
5164
  /**
5171
5165
  * Генерирует и возвращает данные-заглушку неопределённого менеджера.
5172
5166
  */
5173
5167
  static generateUndefinedManagerInstance() {
5174
- return new Ae({ id: 0, name: "- Не назначен -", isActive: !0, guid: "-undefined-" });
5168
+ return new De({ id: 0, name: "- Не назначен -", isActive: !0, guid: "-undefined-" });
5175
5169
  }
5176
5170
  /**
5177
5171
  * Выполняет проверку, является ли указанная запись записью-заглушкой с данными о неопределённом менеджере.
@@ -5182,7 +5176,7 @@ class is {
5182
5176
  return r.id === 0 && r.guid === "-undefined-";
5183
5177
  }
5184
5178
  }
5185
- class Rt extends ue {
5179
+ class Pt extends ue {
5186
5180
  /**
5187
5181
  * Возвращает {@link Promise} для получения справочника списка менеджеров.
5188
5182
  */
@@ -5190,11 +5184,11 @@ class Rt extends ue {
5190
5184
  const r = "/internal/managers", e = ue.getCachedResponse(r);
5191
5185
  if (e)
5192
5186
  return e;
5193
- const i = (await this.get(r)).data.map((o) => Ge.instanceInitializer(Ae, o));
5187
+ const i = (await this.get(r)).data.map((o) => je.instanceInitializer(De, o));
5194
5188
  return this.cacheResponse(r, i), i;
5195
5189
  }
5196
5190
  }
5197
- class Tr extends $r {
5191
+ class $r extends Ar {
5198
5192
  /**
5199
5193
  * Инициализирует экземпляр класса {@link OrderInfo}.
5200
5194
  *
@@ -5253,13 +5247,13 @@ class Tr extends $r {
5253
5247
  onlinePaymentLink: (o = e == null ? void 0 : e.payment) == null ? void 0 : o.onlinePaymentLink
5254
5248
  }, this.delivery = {
5255
5249
  type: ((c = e == null ? void 0 : e.delivery) == null ? void 0 : c.type) ?? -1,
5256
- date: C((u = e == null ? void 0 : e.delivery) == null ? void 0 : u.date) ? v(e.delivery.date) : ((h = e == null ? void 0 : e.delivery) == null ? void 0 : h.date) ?? /* @__PURE__ */ new Date(),
5250
+ date: v((u = e == null ? void 0 : e.delivery) == null ? void 0 : u.date) ? C(e.delivery.date) : ((h = e == null ? void 0 : e.delivery) == null ? void 0 : h.date) ?? /* @__PURE__ */ new Date(),
5257
5251
  address: (f = e == null ? void 0 : e.delivery) != null && f.address ? new ve(e.delivery.address) : void 0,
5258
- warehouse: (g = e == null ? void 0 : e.delivery) != null && g.warehouse ? new De(e.delivery.warehouse) : void 0
5259
- }, this.attachedUser = new d(e == null ? void 0 : e.attachedUser), this.status = (e == null ? void 0 : e.status) ?? 0, this.salesDirection = new O(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, this.sum = (e == null ? void 0 : e.sum) ?? 0;
5252
+ warehouse: (g = e == null ? void 0 : e.delivery) != null && g.warehouse ? new Re(e.delivery.warehouse) : void 0
5253
+ }, this.attachedUser = new d(e == null ? void 0 : e.attachedUser), this.status = (e == null ? void 0 : e.status) ?? 0, this.salesDirection = new O(e == null ? void 0 : e.salesDirection), this.pendingAt = v(e == null ? void 0 : e.pendingAt) ? C(e.pendingAt) : e == null ? void 0 : e.pendingAt, this.processedAt = v(e == null ? void 0 : e.processedAt) ? C(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, this.sum = (e == null ? void 0 : e.sum) ?? 0;
5260
5254
  }
5261
5255
  }
5262
- class Dt extends j {
5256
+ class Rt extends G {
5263
5257
  /**
5264
5258
  * Инициализирует экземпляр класса {@link OrderProduct}.
5265
5259
  *
@@ -5346,7 +5340,7 @@ class Dt extends j {
5346
5340
  this.product = new Y(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, this.creatorUser = e.creatorUser && new d(e.creatorUser);
5347
5341
  }
5348
5342
  }
5349
- class rr extends Tr {
5343
+ class er extends $r {
5350
5344
  /**
5351
5345
  * Инициализирует экземпляр класса {@link Order}.
5352
5346
  *
@@ -5386,10 +5380,10 @@ class rr extends Tr {
5386
5380
  * Признак, что разрешена передача заказа в работу без оплаты.
5387
5381
  */
5388
5382
  t(this, "isAllowProcessingWithoutPayment");
5389
- this.products = (e.products ?? []).map((s) => new Dt(s)), this.invoices = e.invoices ?? [], this.comment = e.comment, this.image = e.image, this.contragent = e.contragent ? Ce.createInstance(e.contragent) : void 0, this.barcode = e.barcode, this.orderSource = e.orderSource ? new P(e.orderSource) : void 0, this.isAllowProcessingWithoutPayment = e.isAllowProcessingWithoutPayment;
5383
+ 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 ? we.createInstance(e.contragent) : void 0, this.barcode = e.barcode, this.orderSource = e.orderSource ? new P(e.orderSource) : void 0, this.isAllowProcessingWithoutPayment = e.isAllowProcessingWithoutPayment;
5390
5384
  }
5391
5385
  }
5392
- class ns extends $e {
5386
+ class is extends Ae {
5393
5387
  /**
5394
5388
  * Возвращает данные о заказах, удовлетворяющих указанным параметрам поиска.
5395
5389
  *
@@ -5402,7 +5396,7 @@ class ns extends $e {
5402
5396
  getOrders(r, e, s) {
5403
5397
  return this.getPaginated("/internal/orders", r, e ? [e] : void 0, s, {}, (i) => {
5404
5398
  const o = { ...i.data };
5405
- return o.data = o.data.map((c) => new Tr(c)), o;
5399
+ return o.data = o.data.map((c) => new $r(c)), o;
5406
5400
  });
5407
5401
  }
5408
5402
  /**
@@ -5420,7 +5414,7 @@ class ns extends $e {
5420
5414
  * @param orderId Идентификатор заказа для которого необходимо вернуть данные.
5421
5415
  */
5422
5416
  getOrder(r) {
5423
- return this.get(`/internal/orders/${r}`, {}, (e) => new rr(e.data));
5417
+ return this.get(`/internal/orders/${r}`, {}, (e) => new er(e.data));
5424
5418
  }
5425
5419
  /**
5426
5420
  * Добавляет продукт в заказ и возвращает обновлённые данные заказа.
@@ -5448,12 +5442,12 @@ class ns extends $e {
5448
5442
  dopProdaga: e.dopProdaga,
5449
5443
  ...e.configuratorParams
5450
5444
  },
5451
- (i) => new rr(i.data),
5445
+ (i) => new er(i.data),
5452
5446
  s
5453
5447
  );
5454
5448
  }
5455
5449
  }
5456
- class ke {
5450
+ class Ie {
5457
5451
  /**
5458
5452
  * Инициализирует экземпляр класса {@link PriceAnalyze}.
5459
5453
  *
@@ -5480,12 +5474,12 @@ class ke {
5480
5474
  * Источник клиентской цены.
5481
5475
  */
5482
5476
  t(this, "source");
5483
- this.client = new he(r == null ? void 0 : r.client), this.product = new I(r == null ? void 0 : r.product), this.cost = (r == null ? void 0 : r.cost) ?? 0, this.costCoefficient = (r == null ? void 0 : r.costCoefficient) ?? 0, this.source = (r == null ? void 0 : r.source) ?? Fe.Product;
5477
+ this.client = new he(r == null ? void 0 : r.client), this.product = new I(r == null ? void 0 : r.product), this.cost = (r == null ? void 0 : r.cost) ?? 0, this.costCoefficient = (r == null ? void 0 : r.costCoefficient) ?? 0, this.source = (r == null ? void 0 : r.source) ?? Ge.Product;
5484
5478
  }
5485
5479
  }
5486
- const Le = (n) => {
5480
+ const ke = (n) => {
5487
5481
  var r, e, s, i, o;
5488
- return n ? cr(
5482
+ return n ? or(
5489
5483
  {
5490
5484
  cities: (r = n.cities) == null ? void 0 : r.map((c) => c.id),
5491
5485
  clients: (e = n.clients) == null ? void 0 : e.map((c) => c.id),
@@ -5494,13 +5488,13 @@ const Le = (n) => {
5494
5488
  salesDirections: (o = n.salesDirections) == null ? void 0 : o.map((c) => c.id),
5495
5489
  hideNotActive: n.hideNotActive
5496
5490
  },
5497
- (c) => A(c) || (V(c) || lr(c)) && K(c)
5491
+ (c) => A(c) || (V(c) || cr(c)) && K(c)
5498
5492
  ) : {};
5499
- }, tr = (n) => {
5493
+ }, rr = (n) => {
5500
5494
  const r = {};
5501
5495
  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;
5502
5496
  };
5503
- class os extends p {
5497
+ class ns extends p {
5504
5498
  /**
5505
5499
  * Возвращает список клиентских цен на продукты в указанном диапазоне цены.
5506
5500
  *
@@ -5514,10 +5508,10 @@ class os extends p {
5514
5508
  return this.get(
5515
5509
  `/internal/price/products/${r}/analyze`,
5516
5510
  {
5517
- ...tr(e),
5518
- filters: Le(s)
5511
+ ...rr(e),
5512
+ filters: ke(s)
5519
5513
  },
5520
- (i) => i.data.map((o) => new ke(o))
5514
+ (i) => i.data.map((o) => new Ie(o))
5521
5515
  );
5522
5516
  }
5523
5517
  /**
@@ -5533,10 +5527,10 @@ class os extends p {
5533
5527
  return this.get(
5534
5528
  `/internal/price/categories/${r}/analyze`,
5535
5529
  {
5536
- ...tr(e),
5537
- filters: Le(s)
5530
+ ...rr(e),
5531
+ filters: ke(s)
5538
5532
  },
5539
- (i) => i.data.map((o) => new ke(o))
5533
+ (i) => i.data.map((o) => new Ie(o))
5540
5534
  );
5541
5535
  }
5542
5536
  /**
@@ -5555,13 +5549,13 @@ class os extends p {
5555
5549
  `/internal/price/categories/${r}/analyze/square`,
5556
5550
  {
5557
5551
  ...e,
5558
- filters: Le(s)
5552
+ filters: ke(s)
5559
5553
  },
5560
- (i) => i.data.map((o) => new ke(o))
5554
+ (i) => i.data.map((o) => new Ie(o))
5561
5555
  );
5562
5556
  }
5563
5557
  }
5564
- class At {
5558
+ class Dt {
5565
5559
  /**
5566
5560
  * Инициализирует экземпляр класса {@link PriceHistoryItem}.
5567
5561
  *
@@ -5608,10 +5602,10 @@ class At {
5608
5602
  * @inheritDoc
5609
5603
  */
5610
5604
  t(this, "currency");
5611
- 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 d(r.client) : void 0, this.executor = r.executor ? new d(r.executor) : void 0, this.currency = r.currency ? new we(r.currency) : void 0;
5605
+ this.cost = r.cost ?? 0, this.isLowCost = r.isLowCost ?? !1, this.isRetail = r.isRetail ?? !1, this.costDate = v(r.costDate) ? C(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 ye(r.currency) : void 0;
5612
5606
  }
5613
5607
  }
5614
- class $t extends oe {
5608
+ class At extends oe {
5615
5609
  /**
5616
5610
  * Инициализирует экземпляр класса {@link ProductPriceHistory}.
5617
5611
  *
@@ -5623,10 +5617,10 @@ class $t extends oe {
5623
5617
  * @inheritDoc
5624
5618
  */
5625
5619
  t(this, "history");
5626
- this.history = Pe(e.history, (s) => new At(s));
5620
+ this.history = Ce(e.history, (s) => new Dt(s));
5627
5621
  }
5628
5622
  }
5629
- class cs extends p {
5623
+ class os extends p {
5630
5624
  /**
5631
5625
  * Возвращает данные об истории изменения цен.
5632
5626
  *
@@ -5636,21 +5630,21 @@ class cs extends p {
5636
5630
  */
5637
5631
  getProductPriceHistory(r) {
5638
5632
  var o, c, u, h, f;
5639
- const e = T.getConfig().dateFormats.api, s = cr(
5640
- fe(r, {
5633
+ const e = b().config.dateFormats.api, s = or(
5634
+ ne(r, {
5641
5635
  costDate: {
5642
- from: xe((o = r.costDate) == null ? void 0 : o.from) ? x(r.costDate.from, e) : (c = r.costDate) == null ? void 0 : c.from,
5643
- to: xe((u = r.costDate) == null ? void 0 : u.to) ? x(r.costDate.to, e) : (h = r.costDate) == null ? void 0 : h.to
5636
+ from: Le((o = r.costDate) == null ? void 0 : o.from) ? x(r.costDate.from, e) : (c = r.costDate) == null ? void 0 : c.from,
5637
+ to: Le((u = r.costDate) == null ? void 0 : u.to) ? x(r.costDate.to, e) : (h = r.costDate) == null ? void 0 : h.to
5644
5638
  }
5645
5639
  }),
5646
- (g) => A(g) || (V(g) || lr(g)) && K(g)
5640
+ (g) => A(g) || (V(g) || cr(g)) && K(g)
5647
5641
  ), i = ((f = r.product) == null ? void 0 : f[0]) ?? 0;
5648
5642
  return delete s.product, this.get(`/internal/price/products/${i}/history`, s).then((g) => [
5649
- new $t(fe(g[0], { history: g }))
5643
+ new At(ne(g[0], { history: g }))
5650
5644
  ]);
5651
5645
  }
5652
5646
  }
5653
- class sr {
5647
+ class tr {
5654
5648
  /**
5655
5649
  * Инициализирует экземпляр класса {@link RecommendationsList}.
5656
5650
  *
@@ -5668,7 +5662,7 @@ class sr {
5668
5662
  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)));
5669
5663
  }
5670
5664
  }
5671
- class ls extends p {
5665
+ class cs extends p {
5672
5666
  /**
5673
5667
  * Возвращает данные о рекомендациях указанной категории продуктов.
5674
5668
  *
@@ -5676,7 +5670,7 @@ class ls extends p {
5676
5670
  * @see /docs/api#/operations/api_internal_recommendations_product_category_get
5677
5671
  */
5678
5672
  getProductCategoryRecommendations(r) {
5679
- return this.get(`/internal/catalog/recommendations/categories/${r.id}`, {}, (e) => new sr(e.data));
5673
+ return this.get(`/internal/catalog/recommendations/categories/${r.id}`, {}, (e) => new tr(e.data));
5680
5674
  }
5681
5675
  /**
5682
5676
  * Возвращает данные о рекомендациях указанного продукта.
@@ -5685,7 +5679,7 @@ class ls extends p {
5685
5679
  * @see /docs/api#/operations/api_internal_recommendations_product_get
5686
5680
  */
5687
5681
  getProductRecommendations(r) {
5688
- return this.get(`/internal/catalog/recommendations/products/${r.id}`, {}, (e) => new sr(e.data));
5682
+ return this.get(`/internal/catalog/recommendations/products/${r.id}`, {}, (e) => new tr(e.data));
5689
5683
  }
5690
5684
  /**
5691
5685
  * Выполняет сохранение данных о рекомендуемых категориях продуктов.
@@ -5723,32 +5717,32 @@ class $ extends ue {
5723
5717
  * и использовать в случае аналогичных запросов.
5724
5718
  */
5725
5719
  getReference(r, e = !1) {
5726
- return this.getTypedDataArrayRequester(ut, `/internal/references/${r}`, e);
5720
+ return this.getTypedDataArrayRequester(lt, `/internal/references/${r}`, e);
5727
5721
  }
5728
5722
  /**
5729
5723
  * Возвращает {@link Promise} для получения справочника данных о канале
5730
5724
  * первичного интереса.
5731
5725
  */
5732
5726
  getChannelPrimaryInterest() {
5733
- return this.getTypedDataArrayRequester(Cr, "/internal/references/channel-primary-interest", !0);
5727
+ return this.getTypedDataArrayRequester(wr, "/internal/references/channel-primary-interest", !0);
5734
5728
  }
5735
5729
  /**
5736
5730
  * Возвращает {@link Promise} для получения справочника должностей контактных лиц.
5737
5731
  */
5738
5732
  getContactPositions() {
5739
- return this.getTypedDataArrayRequester(pt, "/internal/references/contact-position", !0);
5733
+ return this.getTypedDataArrayRequester(ut, "/internal/references/contact-position", !0);
5740
5734
  }
5741
5735
  /**
5742
5736
  * Возвращает {@link Promise} для получения справочника списка направлений кураторства.
5743
5737
  */
5744
5738
  getCuratedDirection() {
5745
- return this.getTypedDataArrayRequester(Be, "/internal/references/curated-direction", !0);
5739
+ return this.getTypedDataArrayRequester(Me, "/internal/references/curated-direction", !0);
5746
5740
  }
5747
5741
  /**
5748
5742
  * Возвращает {@link Promise} для получения справочника списка валют.
5749
5743
  */
5750
5744
  getCurrency() {
5751
- return this.getTypedDataArrayRequester(we, "/public/references/currency", !0);
5745
+ return this.getTypedDataArrayRequester(ye, "/public/references/currency", !0);
5752
5746
  }
5753
5747
  /**
5754
5748
  * Возвращает {@link Promise} для получения справочника данных
@@ -5767,19 +5761,19 @@ class $ extends ue {
5767
5761
  * Возвращает {@link Promise} для получения справочника данных статусов оплаты заказов.
5768
5762
  */
5769
5763
  getOrderPaymentStatuses() {
5770
- return this.getTypedDataArrayRequester(ht, "/public/references/order-payment-status", !0);
5764
+ return this.getTypedDataArrayRequester(pt, "/public/references/order-payment-status", !0);
5771
5765
  }
5772
5766
  /**
5773
5767
  * Возвращает {@link Promise} для получения справочника данных статусов заказов.
5774
5768
  */
5775
5769
  getOrderStatuses() {
5776
- return this.getTypedDataArrayRequester(gt, "/public/references/order-status", !0);
5770
+ return this.getTypedDataArrayRequester(ht, "/public/references/order-status", !0);
5777
5771
  }
5778
5772
  /**
5779
5773
  * Возвращает {@link Promise} для получения справочника данных типов оплаты заказов.
5780
5774
  */
5781
5775
  getPaymentTypes() {
5782
- return this.getTypedDataArrayRequester(mt, "/public/references/payment-type", !0);
5776
+ return this.getTypedDataArrayRequester(gt, "/public/references/payment-type", !0);
5783
5777
  }
5784
5778
  /**
5785
5779
  * Возвращает {@link Promise} для получения справочника типов ресурсов.
@@ -5797,7 +5791,7 @@ class $ extends ue {
5797
5791
  * Возвращает {@link Promise} для получения справочника данных об источнике первичного интереса.
5798
5792
  */
5799
5793
  getSourcePrimaryInterest() {
5800
- return this.getTypedDataArrayRequester(Pr, "/internal/references/source-primary-interest", !0);
5794
+ return this.getTypedDataArrayRequester(Cr, "/internal/references/source-primary-interest", !0);
5801
5795
  }
5802
5796
  /**
5803
5797
  * Выполняет поиск данных о городах по терму в названии.
@@ -5805,7 +5799,7 @@ class $ extends ue {
5805
5799
  * @param term Терм поиска.
5806
5800
  */
5807
5801
  searchCity(r) {
5808
- return this.getTypedDataArrayRequester(ze, `/internal/references/city-with-region-and-country/search?term=${r}`);
5802
+ return this.getTypedDataArrayRequester(He, `/internal/references/city-with-region-and-country/search?term=${r}`);
5809
5803
  }
5810
5804
  /**
5811
5805
  * Выполняет поиск данных о регионах по терму в названии.
@@ -5833,29 +5827,29 @@ class $ extends ue {
5833
5827
  * Возвращает {@link Promise} для получения справочника складов.
5834
5828
  */
5835
5829
  getWarehouses() {
5836
- return this.getTypedDataArrayRequester(De, "/public/references/warehouse", !0);
5830
+ return this.getTypedDataArrayRequester(Re, "/public/references/warehouse", !0);
5837
5831
  }
5838
5832
  /**
5839
5833
  * Возвращает {@link Promise} для получения справочника типов свойств.
5840
5834
  */
5841
5835
  getPropertyTypes() {
5842
- return this.getTypedDataArrayRequester(wr, "/internal/references/property-type", !0);
5836
+ return this.getTypedDataArrayRequester(yr, "/internal/references/property-type", !0);
5843
5837
  }
5844
5838
  /**
5845
5839
  * Возвращает {@link Promise} для получения справочника коэффициентов цен.
5846
5840
  */
5847
5841
  getPriceCoefficients() {
5848
- return this.getTypedDataArrayRequester(Re, "/internal/references/price-coefficient", !0);
5842
+ return this.getTypedDataArrayRequester(Pe, "/internal/references/price-coefficient", !0);
5849
5843
  }
5850
5844
  /**
5851
5845
  * Возвращает {@link Promise} для получения справочника типов файлов продуктов/категорий.
5852
5846
  */
5853
5847
  getProductFileType() {
5854
- return this.getTypedDataArrayRequester(ft, "/public/references/product-file-type", !0);
5848
+ return this.getTypedDataArrayRequester(mt, "/public/references/product-file-type", !0);
5855
5849
  }
5856
5850
  }
5857
- const D = ee("__references_private", () => {
5858
- 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), h = y(void 0), f = y(void 0), g = y(void 0), a = y(void 0), re = y(void 0), te = y(void 0), G = y(void 0), F = y(void 0), Te = y(void 0), l = y(void 0);
5851
+ const D = j("common.references_private", () => {
5852
+ 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), h = y(void 0), f = y(void 0), g = y(void 0), a = y(void 0), ee = y(void 0), re = y(void 0), F = y(void 0), M = y(void 0), $e = y(void 0), l = y(void 0);
5859
5853
  return {
5860
5854
  /**
5861
5855
  * Список загружаемых/загруженных на данный момент значений.
@@ -5908,29 +5902,29 @@ const D = ee("__references_private", () => {
5908
5902
  /**
5909
5903
  * Справочник типов ресурсов.
5910
5904
  */
5911
- resourceTypesReference: re,
5905
+ resourceTypesReference: ee,
5912
5906
  /**
5913
5907
  * Справочник направлений продаж.
5914
5908
  */
5915
- salesDirectionsReference: te,
5909
+ salesDirectionsReference: re,
5916
5910
  /**
5917
5911
  * Справочник источников первичного интереса.
5918
5912
  */
5919
- sourcePrimaryInterestReference: G,
5913
+ sourcePrimaryInterestReference: F,
5920
5914
  /**
5921
5915
  * Справочник складов.
5922
5916
  */
5923
- warehousesReference: F,
5917
+ warehousesReference: M,
5924
5918
  /**
5925
5919
  * Справочник типов свойств.
5926
5920
  */
5927
- propertyTypesReference: Te,
5921
+ propertyTypesReference: $e,
5928
5922
  /**
5929
5923
  * Справочник коэффициентов цен.
5930
5924
  */
5931
5925
  priceCoefficientsReference: l
5932
5926
  };
5933
- }), us = ee("references", () => {
5927
+ }), ls = j("common.references", () => {
5934
5928
  const n = R(() => {
5935
5929
  const l = D();
5936
5930
  return !l.channelPrimaryInterestReference && !l.dataLoaderList.channelPrimaryInterestReference && (l.dataLoaderList.channelPrimaryInterestReference = !0, p.getInstance($).getChannelPrimaryInterest().then((m) => {
@@ -5991,27 +5985,27 @@ const D = ee("__references_private", () => {
5991
5985
  return !l.sourcePrimaryInterestReference && !l.dataLoaderList.sourcePrimaryInterestReference && (l.dataLoaderList.sourcePrimaryInterestReference = !0, p.getInstance($).getSourcePrimaryInterest().then((m) => {
5992
5986
  l.sourcePrimaryInterestReference = m;
5993
5987
  }).catch(w)), l.sourcePrimaryInterestReference;
5994
- }), re = R(() => {
5988
+ }), ee = R(() => {
5995
5989
  const l = D();
5996
5990
  return !l.deliveryTypeReference && !l.dataLoaderList.deliveryTypeReference && (l.dataLoaderList.deliveryTypeReference = !0, p.getInstance($).getDeliveryTypes().then((m) => {
5997
5991
  l.deliveryTypeReference = m;
5998
5992
  }).catch(w)), l.deliveryTypeReference;
5999
- }), te = R(() => {
5993
+ }), re = R(() => {
6000
5994
  const l = D();
6001
- return !l.managersList && !l.dataLoaderList.managersList && (l.dataLoaderList.managersList = !0, p.getInstance(Rt).getManagers().then((m) => {
5995
+ return !l.managersList && !l.dataLoaderList.managersList && (l.dataLoaderList.managersList = !0, p.getInstance(Pt).getManagers().then((m) => {
6002
5996
  l.managersList = m;
6003
5997
  }).catch(w)), l.managersList;
6004
- }), G = R(() => {
5998
+ }), F = R(() => {
6005
5999
  const l = D();
6006
6000
  return !l.warehousesReference && !l.dataLoaderList.warehousesReference && (l.dataLoaderList.warehousesReference = !0, p.getInstance($).getWarehouses().then((m) => {
6007
6001
  l.warehousesReference = m;
6008
6002
  }).catch(w)), l.warehousesReference;
6009
- }), F = R(() => {
6003
+ }), M = R(() => {
6010
6004
  const l = D();
6011
6005
  return !l.propertyTypesReference && !l.dataLoaderList.propertyTypesReference && (l.dataLoaderList.propertyTypesReference = !0, p.getInstance($).getPropertyTypes().then((m) => {
6012
6006
  l.propertyTypesReference = m;
6013
6007
  }).catch(w)), l.propertyTypesReference;
6014
- }), Te = R(() => {
6008
+ }), $e = R(() => {
6015
6009
  const l = D();
6016
6010
  return !l.priceCoefficientsReference && !l.dataLoaderList.priceCoefficientsReference && (l.dataLoaderList.priceCoefficientsReference = !0, p.getInstance($).getPriceCoefficients().then((m) => {
6017
6011
  l.priceCoefficientsReference = m;
@@ -6069,26 +6063,26 @@ const D = ee("__references_private", () => {
6069
6063
  /**
6070
6064
  * Справочник типов доставки.
6071
6065
  */
6072
- deliveryTypeReference: re,
6066
+ deliveryTypeReference: ee,
6073
6067
  /**
6074
6068
  * Список менеджеров.
6075
6069
  */
6076
- managersList: te,
6070
+ managersList: re,
6077
6071
  /**
6078
6072
  * Справочник складов.
6079
6073
  */
6080
- warehousesReference: G,
6074
+ warehousesReference: F,
6081
6075
  /**
6082
6076
  * Справочник типов свойств.
6083
6077
  */
6084
- propertyTypesReference: F,
6078
+ propertyTypesReference: M,
6085
6079
  /**
6086
6080
  * Справочник коэффициентов цен.
6087
6081
  */
6088
- priceCoefficientsReference: Te
6082
+ priceCoefficientsReference: $e
6089
6083
  };
6090
6084
  });
6091
- class Tt {
6085
+ class $t {
6092
6086
  /**
6093
6087
  * Инициализирует экземпляр класса {@link MetaTagItem}.
6094
6088
  *
@@ -6106,7 +6100,7 @@ class Tt {
6106
6100
  this.name = r.name, this.content = r.content;
6107
6101
  }
6108
6102
  }
6109
- class ir {
6103
+ class sr {
6110
6104
  /**
6111
6105
  * Инициализирует экземпляр класса {@link Seo}.
6112
6106
  *
@@ -6142,10 +6136,10 @@ class ir {
6142
6136
  */
6143
6137
  t(this, "meta");
6144
6138
  var e;
6145
- this.resourceType = new vr(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 Tt(s))) ?? [];
6139
+ this.resourceType = new vr(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))) ?? [];
6146
6140
  }
6147
6141
  }
6148
- class ps extends p {
6142
+ class us extends p {
6149
6143
  /**
6150
6144
  * Возвращает {@link Promise} для получения данных о SEO-параметрах указанного ресурса.
6151
6145
  *
@@ -6153,7 +6147,7 @@ class ps extends p {
6153
6147
  * @param resourceId Идентификатор ресурса для которого необходимо получить SEO-данные.
6154
6148
  */
6155
6149
  getResourceSeoData(r, e) {
6156
- return this.get(`/internal/seo/${r.slug}/${e}`, {}, (s) => new ir(s.data));
6150
+ return this.get(`/internal/seo/${r.slug}/${e}`, {}, (s) => new sr(s.data));
6157
6151
  }
6158
6152
  /**
6159
6153
  * Выполняет сохранение данных о SEO-параметрах для указанного ресурса.
@@ -6164,7 +6158,7 @@ class ps extends p {
6164
6158
  * в случае ошибок в запросах.
6165
6159
  */
6166
6160
  saveResourceSeoData(r, e = {}) {
6167
- return this.post(`/internal/seo/${r.resourceType.slug}/${r.resourceId}`, r, (s) => new ir(s.data), e);
6161
+ return this.post(`/internal/seo/${r.resourceType.slug}/${r.resourceId}`, r, (s) => new sr(s.data), e);
6168
6162
  }
6169
6163
  /**
6170
6164
  * Возвращает {@link Promise} для удаления данных о SEO-параметрах указанного ресурса.
@@ -6176,7 +6170,7 @@ class ps extends p {
6176
6170
  return this.delete(`/internal/seo/${r.slug}/${e}`);
6177
6171
  }
6178
6172
  }
6179
- class hs extends p {
6173
+ class ps extends p {
6180
6174
  /**
6181
6175
  * Возвращает подсказки по адресам.
6182
6176
  *
@@ -6223,8 +6217,8 @@ class hs extends p {
6223
6217
  });
6224
6218
  }
6225
6219
  }
6226
- var bt = /* @__PURE__ */ ((n) => (n.Admin = "admin", n.Manager = "manager", n.Operator = "operator", n.Client = "client", n.Guest = "guest", n))(bt || {});
6227
- class at extends yr {
6220
+ var Tt = /* @__PURE__ */ ((n) => (n.Admin = "admin", n.Manager = "manager", n.Operator = "operator", n.Client = "client", n.Guest = "guest", n))(Tt || {});
6221
+ class bt extends fr {
6228
6222
  /**
6229
6223
  * Инициализирует экземпляр класса {@link User}.
6230
6224
  *
@@ -6247,12 +6241,12 @@ class at extends yr {
6247
6241
  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;
6248
6242
  }
6249
6243
  }
6250
- class gs extends p {
6244
+ class hs extends p {
6251
6245
  /**
6252
6246
  * Инициализирует экземпляр класса {@link UserAuthDataProvider}.
6253
6247
  */
6254
6248
  constructor() {
6255
- super(), this.baseUrl = `${T.getConfig().http.portalApiUrl}/api`, this.interceptorIds.request.authRequestInterceptor && this.httpClient.interceptors.request.eject(this.interceptorIds.request.authRequestInterceptor);
6249
+ super(), this.baseUrl = `${b().config.http.portalApiUrl}/api`, this.interceptorIds.request.authRequestInterceptor && this.httpClient.interceptors.request.eject(this.interceptorIds.request.authRequestInterceptor);
6256
6250
  }
6257
6251
  /**
6258
6252
  * Функция для получения обновленных токенов доступа.
@@ -6263,16 +6257,16 @@ class gs extends p {
6263
6257
  return this.get("internal/users/current-tokens").then((r) => r.accessToken);
6264
6258
  }
6265
6259
  }
6266
- class St extends p {
6260
+ class at extends p {
6267
6261
  /**
6268
6262
  * Возвращает данные о текущем пользователе.
6269
6263
  */
6270
6264
  // eslint-disable-next-line class-methods-use-this
6271
6265
  getCurrentUser() {
6272
- return this.get("/internal/users/info", {}, (r) => new at(r.data), !0);
6266
+ return this.get("/internal/users/info", {}, (r) => new bt(r.data), !0);
6273
6267
  }
6274
6268
  }
6275
- const It = ee("__user_state_private", () => {
6269
+ const St = j("common.user_state_private", () => {
6276
6270
  const n = y({}), r = y(void 0);
6277
6271
  return {
6278
6272
  /**
@@ -6284,20 +6278,20 @@ const It = ee("__user_state_private", () => {
6284
6278
  */
6285
6279
  currentUser: r
6286
6280
  };
6287
- }), ms = ee("user_state", () => ({
6281
+ }), gs = j("common.user_state", () => ({
6288
6282
  /**
6289
6283
  * Данные о текущем пользователе.
6290
6284
  */
6291
6285
  currentUser: R(() => {
6292
- const r = It();
6293
- return !r.currentUser && !r.dataLoaderList.currentUser && (r.dataLoaderList.currentUser = !0, p.getInstance(St).getCurrentUser().then((e) => {
6286
+ const r = St();
6287
+ return !r.currentUser && !r.dataLoaderList.currentUser && (r.dataLoaderList.currentUser = !0, p.getInstance(at).getCurrentUser().then((e) => {
6294
6288
  r.currentUser = e;
6295
6289
  }).catch(w).finally(() => {
6296
6290
  r.dataLoaderList.currentUser = !1;
6297
6291
  })), r.currentUser;
6298
6292
  })
6299
6293
  }));
6300
- class fs {
6294
+ class ms {
6301
6295
  /**
6302
6296
  * Инициализирует экземпляр класса {@link FieldValidationResultData}.
6303
6297
  *
@@ -6321,152 +6315,152 @@ class fs {
6321
6315
  }
6322
6316
  }
6323
6317
  export {
6324
- ut as AnyReference,
6325
- Ft as AppBaseConfig,
6326
- T as AppConfigProvider,
6327
- Oe as BankAccount,
6328
- $e as BasePaginationProvider,
6329
- Yr as CalculationTypeEnum,
6318
+ lt as AnyReference,
6319
+ Kr as AppBaseConfig,
6320
+ de as BankAccount,
6321
+ Ae as BasePaginationProvider,
6322
+ rt as CalculationTypeEnum,
6330
6323
  ge as Cart,
6331
- Qr as CartItem,
6332
- Kr as CartItemBase,
6333
- jt as CartProvider,
6334
- Mt as CatalogProvider,
6335
- ur as CatalogableItem,
6336
- H as Category,
6337
- Ke as CategoryPricingRule,
6338
- Cr as ChannelPrimaryInterest,
6339
- Yt as City,
6340
- ze as CityWithRegionAndCountry,
6341
- Ze as Client,
6324
+ et as CartItem,
6325
+ Zr as CartItemBase,
6326
+ Ut as CartProvider,
6327
+ Gt as CatalogProvider,
6328
+ lr as CatalogableItem,
6329
+ z as Category,
6330
+ Ve as CategoryPricingRule,
6331
+ wr as ChannelPrimaryInterest,
6332
+ Kt as City,
6333
+ He as CityWithRegionAndCountry,
6334
+ Xe as Client,
6342
6335
  vt as ClientAdditionalData,
6343
- ye as ClientCategory,
6336
+ fe as ClientCategory,
6344
6337
  k as ClientDataProvider,
6345
- Bt as ClientPriceProvider,
6346
- Ht as ClientPriceTemplateProvider,
6338
+ Ft as ClientPriceProvider,
6339
+ Mt as ClientPriceTemplateProvider,
6347
6340
  Y as ClientProduct,
6348
- Et as ClientProductCategoryDataProvider,
6349
- Jt as ClientProductDataProvider,
6341
+ zt as ClientProductCategoryDataProvider,
6342
+ Wt as ClientProductDataProvider,
6350
6343
  he as ClientShortInfo,
6351
- lt as ClientsAdditionalDataRequestTypeEnum,
6352
- Xt as ClientsListFilters,
6344
+ ct as ClientsAdditionalDataRequestTypeEnum,
6345
+ Qt as ClientsListFilters,
6353
6346
  oe as CodedIdentity,
6354
- ts as ConfiguratorProvider,
6355
- qe as Contact,
6356
- mr as ContactLinks,
6347
+ rs as ConfiguratorProvider,
6348
+ Oe as Contact,
6349
+ gr as ContactLinks,
6357
6350
  U as ContactPerson,
6358
- Ct as ContactPersonRelated,
6359
- pt as ContactPosition,
6360
- Ie as ContactRelation,
6361
- Rr as ContragentBase,
6362
- Ce as ContragentFactory,
6363
- Dr as ContragentIc,
6364
- yt as ContragentPerson,
6365
- wt as ContragentUlNr,
6366
- Ar as ContragentUlR,
6367
- Fe as CostSourceEnum,
6351
+ wt as ContactPersonRelated,
6352
+ ut as ContactPosition,
6353
+ Se as ContactRelation,
6354
+ Pr as ContragentBase,
6355
+ we as ContragentFactory,
6356
+ Rr as ContragentIc,
6357
+ ft as ContragentPerson,
6358
+ yt as ContragentUlNr,
6359
+ Dr as ContragentUlR,
6360
+ Ge as CostSourceEnum,
6368
6361
  X as Country,
6369
- Be as CuratedDirection,
6370
- He as Curator,
6371
- we as Currency,
6372
- hs as DataSuggestionProvider,
6373
- Zt as DataTablePagination,
6374
- Pt as DataTablePaginationRequestParams,
6375
- es as DataTableSortRequestParams,
6376
- ss as DateTimeProvider,
6377
- Zr as DeletableNamedIdentity,
6362
+ Me as CuratedDirection,
6363
+ Be as Curator,
6364
+ ye as Currency,
6365
+ ps as DataSuggestionProvider,
6366
+ Yt as DataTablePagination,
6367
+ Ct as DataTablePaginationRequestParams,
6368
+ Xt as DataTableSortRequestParams,
6369
+ ts as DateTimeProvider,
6370
+ st as DeletableNamedIdentity,
6378
6371
  ve as DeliveryAddress,
6379
6372
  Q as DeliveryType,
6380
- Ut as DetailedJwtPayload,
6381
- st as DeviceTypeResolutionConfig,
6382
- et as DiscountShortInfo,
6383
- fs as FieldValidationResultData,
6373
+ Nt as DetailedJwtPayload,
6374
+ zr as DeviceTypeResolutionConfig,
6375
+ it as DiscountShortInfo,
6376
+ ms as FieldValidationResultData,
6384
6377
  le as FilterGroup,
6385
- Qe as FilterItem,
6386
- We as FilterOpEnum,
6387
- hr as GeoCoordinates,
6388
- Jr as HiddenCatalogableItem,
6378
+ Ke as FilterItem,
6379
+ ze as FilterOpEnum,
6380
+ pr as GeoCoordinates,
6381
+ Yr as HiddenCatalogableItem,
6389
6382
  ue as HttpCachedRequester,
6390
- it as HttpParamsConfig,
6383
+ Wr as HttpParamsConfig,
6391
6384
  p as HttpRequester,
6392
- j as Identity,
6393
- Vr as Image,
6385
+ G as Identity,
6386
+ Xr as Image,
6394
6387
  q as JwtPayload,
6395
- Ae as Manager,
6396
- Me as ManagerCommon,
6397
- is as ManagerDataFactory,
6398
- Rt as ManagerDataProvider,
6399
- Tt as MetaTagItem,
6400
- b as NamedIdentity,
6388
+ De as Manager,
6389
+ Fe as ManagerCommon,
6390
+ ss as ManagerDataFactory,
6391
+ Pt as ManagerDataProvider,
6392
+ $t as MetaTagItem,
6393
+ T as NamedIdentity,
6401
6394
  N as Opf,
6402
6395
  _ as OpfEnum,
6403
- rr as Order,
6404
- Tr as OrderInfo,
6405
- ht as OrderPaymentStatus,
6406
- Dt as OrderProduct,
6407
- $r as OrderShortInfo,
6408
- gt as OrderStatus,
6409
- ns as OrdersDataProvider,
6396
+ er as Order,
6397
+ $r as OrderInfo,
6398
+ pt as OrderPaymentStatus,
6399
+ Rt as OrderProduct,
6400
+ Ar as OrderShortInfo,
6401
+ ht as OrderStatus,
6402
+ is as OrdersDataProvider,
6410
6403
  Z as PartnerGroup,
6411
- mt as PaymentType,
6404
+ gt as PaymentType,
6412
6405
  me as PreferencesStorageProvider,
6413
- ke as PriceAnalyze,
6414
- os as PriceAnalyzeProvider,
6415
- Re as PriceCoefficient,
6416
- pr as PriceCoefficientEnum,
6417
- cs as PriceHistoryDataProvider,
6418
- At as PriceHistoryItem,
6419
- z as PriceTemplate,
6420
- ae as PriceTemplateCategory,
6421
- se as PriceTemplateClient,
6422
- fr as PriceTemplateICatalogableItem,
6423
- Se as PriceTemplateProduct,
6424
- Vt as PriceTemplateProvider,
6425
- ne as PricingRole,
6426
- Kt as PricingRoleProvider,
6427
- de as PrimaryCatalogableItem,
6406
+ Ie as PriceAnalyze,
6407
+ ns as PriceAnalyzeProvider,
6408
+ Pe as PriceCoefficient,
6409
+ ur as PriceCoefficientEnum,
6410
+ os as PriceHistoryDataProvider,
6411
+ Dt as PriceHistoryItem,
6412
+ W as PriceTemplate,
6413
+ be as PriceTemplateCategory,
6414
+ te as PriceTemplateClient,
6415
+ mr as PriceTemplateICatalogableItem,
6416
+ ae as PriceTemplateProduct,
6417
+ Et as PriceTemplateProvider,
6418
+ ie as PricingRole,
6419
+ Jt as PricingRoleProvider,
6420
+ _e as PrimaryCatalogableItem,
6428
6421
  I as Product,
6429
- zt as ProductCategoryDataProvider,
6430
- Wt as ProductDataProvider,
6431
- ft as ProductFileType,
6432
- je as ProductPriceCoefficient,
6433
- $t as ProductPriceHistory,
6434
- Qt as PropertiesProvider,
6435
- ie as Property,
6436
- wr as PropertyType,
6437
- Xr as PropertyTypeEnum,
6438
- B as PropertyValue,
6439
- ls as RecommendationsDataProvider,
6440
- sr as RecommendationsList,
6422
+ Bt as ProductCategoryDataProvider,
6423
+ Ht as ProductDataProvider,
6424
+ mt as ProductFileType,
6425
+ Ue as ProductPriceCoefficient,
6426
+ At as ProductPriceHistory,
6427
+ Vt as PropertiesProvider,
6428
+ se as Property,
6429
+ yr as PropertyType,
6430
+ tt as PropertyTypeEnum,
6431
+ H as PropertyValue,
6432
+ cs as RecommendationsDataProvider,
6433
+ tr as RecommendationsList,
6441
6434
  P as Reference,
6442
6435
  $ as ReferenceDataProvider,
6443
6436
  ce as Region,
6444
6437
  vr as ResourceType,
6445
6438
  O as SalesDirection,
6446
- nt as SentryConfig,
6447
- ir as Seo,
6448
- ps as SeoDataProvider,
6449
- Pr as SourcePrimaryInterest,
6450
- Er as StockCount,
6451
- Gt as TemplatesListFilters,
6452
- Ge as TypedInstanceFactory,
6453
- er as UnitsHelper,
6454
- rs as UnknownClientDataProvider,
6455
- gr as UpdatableNamedIdentity,
6456
- at as User,
6457
- gs as UserAuthDataProvider,
6458
- yr as UserCommonInfo,
6459
- St as UserDataProvider,
6460
- rt as UserPricingRole,
6439
+ Er as SentryConfig,
6440
+ sr as Seo,
6441
+ us as SeoDataProvider,
6442
+ Cr as SourcePrimaryInterest,
6443
+ Qr as StockCount,
6444
+ jt as TemplatesListFilters,
6445
+ je as TypedInstanceFactory,
6446
+ Ze as UnitsHelper,
6447
+ Zt as UnknownClientDataProvider,
6448
+ hr as UpdatableNamedIdentity,
6449
+ bt as User,
6450
+ hs as UserAuthDataProvider,
6451
+ fr as UserCommonInfo,
6452
+ at as UserDataProvider,
6453
+ nt as UserPricingRole,
6461
6454
  d as UserShortInfo,
6462
- bt as UserTypeEnum,
6463
- ot as VersionConfig,
6464
- De as Warehouse,
6465
- ct as WebSocketConfig,
6466
- Ye as findCatalogItemByIdRecursive,
6467
- Xe as flattenCatalogItems,
6468
- be as useAuthStateStore,
6469
- us as useReferencesStore,
6470
- ms as useUserStateStore
6455
+ Tt as UserTypeEnum,
6456
+ Jr as VersionConfig,
6457
+ Re as Warehouse,
6458
+ Vr as WebSocketConfig,
6459
+ Qe as findCatalogItemByIdRecursive,
6460
+ Ye as flattenCatalogItems,
6461
+ es as loadRemoteConfig,
6462
+ Te as useAuthStateStore,
6463
+ ls as useReferencesStore,
6464
+ gs as useUserStateStore
6471
6465
  };
6472
6466
  //# sourceMappingURL=sc-common-lib.js.map