@escapenavigator/types 2.0.38 → 2.0.39

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,9 +1,15 @@
1
1
  export declare class QueryClientDto {
2
2
  parentId?: number;
3
3
  lastGame?: [string, string];
4
+ /**
5
+ * Recurring birthday window as `MM-DD` (year is ignored).
6
+ * Legacy `yyyy-mm-dd` values from saved segments are accepted and
7
+ * reduced to month+day on the backend.
8
+ */
4
9
  birthday?: [string, string];
5
10
  gamesCount?: string[];
6
11
  visitsCount?: 'exactly_1' | 'exactly_2' | 'more_2' | 'more_3' | 'more_4' | 'not_visited';
12
+ /** Calendar month 1–12; matches birthday in that month of any year. */
7
13
  selectedMonth?: string | number;
8
14
  blockedClient?: 'blocked' | 'not_blocked';
9
15
  alowedToAds?: 'allowed' | 'not_allowed';
@@ -49,6 +49,8 @@ export declare class OpenapiQuestroomRO {
49
49
  fear: number;
50
50
  difficult: number;
51
51
  photo: string;
52
+ photos: string[];
53
+ legend: string;
52
54
  time: number;
53
55
  ticketSystem: boolean;
54
56
  /**
@@ -29,14 +29,15 @@ const questroom_type_enum_1 = require("../../questroom/enum/questroom-type.enum"
29
29
  const languages_enum_1 = require("../../shared/enum/languages.enum");
30
30
  const openapi_slot_tariff_ro_1 = require("../slots/openapi-slot-tariff.ro");
31
31
  const transformQuestroom = ({ value, language, }) => {
32
- var _a, _b, _c, _d;
32
+ var _a, _b;
33
33
  if (!value)
34
34
  return value;
35
35
  const { locales, location } = value, questroom = __rest(value, ["locales", "location"]);
36
- const _e = location || {}, { locales: locationLocales } = _e, locationRest = __rest(_e, ["locales"]);
37
- return Object.assign(Object.assign({}, questroom), { title: ((_a = locales === null || locales === void 0 ? void 0 : locales.find((l) => l.language === language)) === null || _a === void 0 ? void 0 : _a.title) || questroom.title, importantInfo: ((_b = locales === null || locales === void 0 ? void 0 : locales.find((l) => l.language === language)) === null || _b === void 0 ? void 0 : _b.importantInfo) || questroom.importantInfo, location: location
38
- ? Object.assign(Object.assign({}, locationRest), { howToFind: ((_c = locationLocales === null || locationLocales === void 0 ? void 0 : locationLocales.find((l) => l.language === language)) === null || _c === void 0 ? void 0 : _c.howToFind) ||
39
- locationRest.howToFind, prepareText: ((_d = locationLocales === null || locationLocales === void 0 ? void 0 : locationLocales.find((l) => l.language === language)) === null || _d === void 0 ? void 0 : _d.prepareText) ||
36
+ const _c = location || {}, { locales: locationLocales } = _c, locationRest = __rest(_c, ["locales"]);
37
+ const locale = locales === null || locales === void 0 ? void 0 : locales.find((l) => l.language === language);
38
+ return Object.assign(Object.assign({}, questroom), { title: (locale === null || locale === void 0 ? void 0 : locale.title) || questroom.title, legend: (locale === null || locale === void 0 ? void 0 : locale.legend) || questroom.legend, importantInfo: (locale === null || locale === void 0 ? void 0 : locale.importantInfo) || questroom.importantInfo, photos: questroom.photos || [], location: location
39
+ ? Object.assign(Object.assign({}, locationRest), { howToFind: ((_a = locationLocales === null || locationLocales === void 0 ? void 0 : locationLocales.find((l) => l.language === language)) === null || _a === void 0 ? void 0 : _a.howToFind) ||
40
+ locationRest.howToFind, prepareText: ((_b = locationLocales === null || locationLocales === void 0 ? void 0 : locationLocales.find((l) => l.language === language)) === null || _b === void 0 ? void 0 : _b.prepareText) ||
40
41
  locationRest.prepareText }) : location });
41
42
  };
42
43
  exports.transformQuestroom = transformQuestroom;
@@ -159,6 +160,14 @@ __decorate([
159
160
  (0, class_transformer_1.Expose)(),
160
161
  __metadata("design:type", String)
161
162
  ], OpenapiQuestroomRO.prototype, "photo", void 0);
163
+ __decorate([
164
+ (0, class_transformer_1.Expose)(),
165
+ __metadata("design:type", Array)
166
+ ], OpenapiQuestroomRO.prototype, "photos", void 0);
167
+ __decorate([
168
+ (0, class_transformer_1.Expose)(),
169
+ __metadata("design:type", String)
170
+ ], OpenapiQuestroomRO.prototype, "legend", void 0);
162
171
  __decorate([
163
172
  (0, class_transformer_1.Expose)(),
164
173
  __metadata("design:type", Number)
@@ -3,6 +3,22 @@ import { PromocodeCertificateModeEnum } from './emun/promocode-certificate-mode.
3
3
  import { PromocodeKindEnum } from './emun/promocode-kind.enum';
4
4
  import { PromocodeTypeEnum } from './emun/promocode-type.enum';
5
5
  import { PromocodeNominalRule } from './promocode-nominal-rule';
6
+ /** Клиент, которому выдан автоматический промокод (список / карточка). */
7
+ export declare class PromocodeIssuedClientRO {
8
+ id: number;
9
+ name: string;
10
+ surname: string;
11
+ patronymic: string;
12
+ }
13
+ /**
14
+ * Бронь-источник автоматического промокода: `issuedOrderId` для
15
+ * cross-sale/retargeting, `orderId` для refund. У birthday брони нет.
16
+ */
17
+ export declare class PromocodeIssuedOrderRO {
18
+ id: number;
19
+ code: string;
20
+ groupId?: number;
21
+ }
6
22
  export declare class PromocodeRO extends RO {
7
23
  code: string;
8
24
  description: string;
@@ -32,6 +48,8 @@ export declare class PromocodeRO extends RO {
32
48
  orderId: number;
33
49
  issuedOrderId?: number;
34
50
  clientId?: number;
51
+ client?: PromocodeIssuedClientRO;
52
+ issuedOrder?: PromocodeIssuedOrderRO;
35
53
  certificateNominalRules: PromocodeNominalRule[];
36
54
  certificateMode: PromocodeCertificateModeEnum | null;
37
55
  kind: PromocodeKindEnum;
@@ -9,12 +9,52 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.PromocodeRO = void 0;
12
+ exports.PromocodeRO = exports.PromocodeIssuedOrderRO = exports.PromocodeIssuedClientRO = void 0;
13
+ /* eslint-disable max-classes-per-file */
13
14
  const class_transformer_1 = require("class-transformer");
14
15
  const ro_class_1 = require("../shared/ro-class");
15
16
  const promocode_certificate_mode_enum_1 = require("./emun/promocode-certificate-mode.enum");
16
17
  const promocode_kind_enum_1 = require("./emun/promocode-kind.enum");
17
18
  const promocode_type_enum_1 = require("./emun/promocode-type.enum");
19
+ /** Клиент, которому выдан автоматический промокод (список / карточка). */
20
+ class PromocodeIssuedClientRO {
21
+ }
22
+ exports.PromocodeIssuedClientRO = PromocodeIssuedClientRO;
23
+ __decorate([
24
+ (0, class_transformer_1.Expose)(),
25
+ __metadata("design:type", Number)
26
+ ], PromocodeIssuedClientRO.prototype, "id", void 0);
27
+ __decorate([
28
+ (0, class_transformer_1.Expose)(),
29
+ __metadata("design:type", String)
30
+ ], PromocodeIssuedClientRO.prototype, "name", void 0);
31
+ __decorate([
32
+ (0, class_transformer_1.Expose)(),
33
+ __metadata("design:type", String)
34
+ ], PromocodeIssuedClientRO.prototype, "surname", void 0);
35
+ __decorate([
36
+ (0, class_transformer_1.Expose)(),
37
+ __metadata("design:type", String)
38
+ ], PromocodeIssuedClientRO.prototype, "patronymic", void 0);
39
+ /**
40
+ * Бронь-источник автоматического промокода: `issuedOrderId` для
41
+ * cross-sale/retargeting, `orderId` для refund. У birthday брони нет.
42
+ */
43
+ class PromocodeIssuedOrderRO {
44
+ }
45
+ exports.PromocodeIssuedOrderRO = PromocodeIssuedOrderRO;
46
+ __decorate([
47
+ (0, class_transformer_1.Expose)(),
48
+ __metadata("design:type", Number)
49
+ ], PromocodeIssuedOrderRO.prototype, "id", void 0);
50
+ __decorate([
51
+ (0, class_transformer_1.Expose)(),
52
+ __metadata("design:type", String)
53
+ ], PromocodeIssuedOrderRO.prototype, "code", void 0);
54
+ __decorate([
55
+ (0, class_transformer_1.Expose)(),
56
+ __metadata("design:type", Number)
57
+ ], PromocodeIssuedOrderRO.prototype, "groupId", void 0);
18
58
  class PromocodeRO extends ro_class_1.RO {
19
59
  }
20
60
  exports.PromocodeRO = PromocodeRO;
@@ -130,6 +170,16 @@ __decorate([
130
170
  (0, class_transformer_1.Expose)(),
131
171
  __metadata("design:type", Number)
132
172
  ], PromocodeRO.prototype, "clientId", void 0);
173
+ __decorate([
174
+ (0, class_transformer_1.Expose)(),
175
+ (0, class_transformer_1.Type)(() => PromocodeIssuedClientRO),
176
+ __metadata("design:type", PromocodeIssuedClientRO)
177
+ ], PromocodeRO.prototype, "client", void 0);
178
+ __decorate([
179
+ (0, class_transformer_1.Expose)(),
180
+ (0, class_transformer_1.Type)(() => PromocodeIssuedOrderRO),
181
+ __metadata("design:type", PromocodeIssuedOrderRO)
182
+ ], PromocodeRO.prototype, "issuedOrder", void 0);
133
183
  __decorate([
134
184
  (0, class_transformer_1.Expose)(),
135
185
  __metadata("design:type", Array)
@@ -70,6 +70,11 @@ export type QuestroomAiContext = {
70
70
  min?: number;
71
71
  max?: number;
72
72
  currency?: string;
73
+ basis?: 'per_group';
74
+ byPlayers?: Record<number, {
75
+ min: number;
76
+ max: number;
77
+ }>;
73
78
  };
74
79
  languages?: Languages[];
75
80
  payment?: {
@@ -105,6 +110,10 @@ export type QuestroomAiIndexItem = {
105
110
  priceMin?: number;
106
111
  priceMax?: number;
107
112
  currency?: string;
113
+ priceByPlayers?: Record<number, {
114
+ min: number;
115
+ max: number;
116
+ }>;
108
117
  tags: TagsEnum[];
109
118
  languages: Languages[];
110
119
  fear: QuestroomAiScale;