@escapenavigator/types 1.6.39 → 1.6.41

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.
@@ -32,6 +32,11 @@ __decorate([
32
32
  ], AgregatorCityRO.prototype, "photo", void 0);
33
33
  __decorate([
34
34
  (0, class_transformer_1.Expose)(),
35
+ (0, class_transformer_1.Transform)(({ value }) => {
36
+ if (typeof value === 'object')
37
+ return value.coordinates;
38
+ return value.slice(1, -1).split(',');
39
+ }),
35
40
  __metadata("design:type", Array)
36
41
  ], AgregatorCityRO.prototype, "coordinates", void 0);
37
42
  __decorate([
@@ -1,9 +1,13 @@
1
1
  import { QuestroomTypeEnum } from '../questroom/enum/questroom-type.enum';
2
2
  import { Languages } from '../shared/enum/languages.enum';
3
+ declare class Location {
4
+ address: string;
5
+ }
3
6
  export declare class AgregatorQuestroomCardRO {
4
7
  createdAt: Date;
5
8
  title: string;
6
9
  slug: string;
10
+ location: Location;
7
11
  top: boolean;
8
12
  closed: boolean;
9
13
  type: QuestroomTypeEnum;
@@ -16,7 +20,7 @@ export declare class AgregatorQuestroomCardRO {
16
20
  playersMax: number;
17
21
  difficult: number;
18
22
  fear: number;
19
- price: number;
20
- hasSchedule: boolean;
23
+ hasSchedule?: boolean;
21
24
  languages?: Languages[];
22
25
  }
26
+ export {};
@@ -10,8 +10,16 @@ var __metadata = (this && this.__metadata) || function (k, v) {
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.AgregatorQuestroomCardRO = void 0;
13
+ /* eslint-disable max-classes-per-file */
13
14
  const class_transformer_1 = require("class-transformer");
15
+ const partner_program_enum_1 = require("../profile/enum/partner-program.enum");
14
16
  const questroom_type_enum_1 = require("../questroom/enum/questroom-type.enum");
17
+ class Location {
18
+ }
19
+ __decorate([
20
+ (0, class_transformer_1.Expose)(),
21
+ __metadata("design:type", String)
22
+ ], Location.prototype, "address", void 0);
15
23
  class AgregatorQuestroomCardRO {
16
24
  }
17
25
  __decorate([
@@ -26,6 +34,11 @@ __decorate([
26
34
  (0, class_transformer_1.Expose)(),
27
35
  __metadata("design:type", String)
28
36
  ], AgregatorQuestroomCardRO.prototype, "slug", void 0);
37
+ __decorate([
38
+ (0, class_transformer_1.Expose)(),
39
+ (0, class_transformer_1.Type)(() => Location),
40
+ __metadata("design:type", Location)
41
+ ], AgregatorQuestroomCardRO.prototype, "location", void 0);
29
42
  __decorate([
30
43
  (0, class_transformer_1.Expose)(),
31
44
  __metadata("design:type", Boolean)
@@ -76,10 +89,7 @@ __decorate([
76
89
  ], AgregatorQuestroomCardRO.prototype, "fear", void 0);
77
90
  __decorate([
78
91
  (0, class_transformer_1.Expose)(),
79
- __metadata("design:type", Number)
80
- ], AgregatorQuestroomCardRO.prototype, "price", void 0);
81
- __decorate([
82
- (0, class_transformer_1.Expose)(),
92
+ (0, class_transformer_1.Transform)(({ obj }) => { var _a; return obj.templateId && ((_a = obj.profile) === null || _a === void 0 ? void 0 : _a.partnerProgram) === partner_program_enum_1.PartnerProgramEnum.ACTIVE; }),
83
93
  __metadata("design:type", Boolean)
84
94
  ], AgregatorQuestroomCardRO.prototype, "hasSchedule", void 0);
85
95
  __decorate([
@@ -30,7 +30,6 @@ declare class Location {
30
30
  }
31
31
  export declare class AgregatorQuestroomRO {
32
32
  id: number;
33
- currency: ProfileCurrencyEnum;
34
33
  createdAt: Date;
35
34
  slug: string;
36
35
  teaser: string;
@@ -56,7 +55,8 @@ export declare class AgregatorQuestroomRO {
56
55
  languages?: Languages[];
57
56
  rating: number;
58
57
  reviewsCount: number;
59
- hasSchedule: boolean;
58
+ currency?: ProfileCurrencyEnum;
59
+ hasSchedule?: boolean;
60
60
  top: boolean;
61
61
  navigatorReview?: NavigatorReviewRO;
62
62
  }
@@ -12,7 +12,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.AgregatorQuestroomRO = exports.AgregatorProfile = void 0;
13
13
  /* eslint-disable max-classes-per-file */
14
14
  const class_transformer_1 = require("class-transformer");
15
+ const currency_by_country_1 = require("../constants/currency-by-country");
16
+ const partner_program_enum_1 = require("../profile/enum/partner-program.enum");
15
17
  const profile_currency_1 = require("../profile/enum/profile-currency");
18
+ const profile_step_enum_1 = require("../profile/enum/profile-step.enum");
16
19
  const questroom_actors_enum_1 = require("../questroom/enum/questroom-actors.enum");
17
20
  const questroom_type_enum_1 = require("../questroom/enum/questroom-type.enum");
18
21
  const countries_enum_1 = require("../shared/enum/countries.enum");
@@ -29,9 +32,10 @@ __decorate([
29
32
  __decorate([
30
33
  (0, class_transformer_1.Expose)(),
31
34
  (0, class_transformer_1.Transform)(({ obj }) => {
32
- var _a;
33
- const type = (_a = obj.step) === null || _a === void 0 ? void 0 : _a.split('_')[0];
34
- return type === 'integrated' || type === 'CRM' || type === 'canceled' || type === 'closed';
35
+ var _a, _b, _c;
36
+ return ((_a = obj === null || obj === void 0 ? void 0 : obj.profile) === null || _a === void 0 ? void 0 : _a.status) === profile_step_enum_1.ProfileStatusEnum.VERIFIED ||
37
+ ((_b = obj === null || obj === void 0 ? void 0 : obj.profile) === null || _b === void 0 ? void 0 : _b.status) === profile_step_enum_1.ProfileStatusEnum.CLOSED ||
38
+ ((_c = obj === null || obj === void 0 ? void 0 : obj.profile) === null || _c === void 0 ? void 0 : _c.status) === profile_step_enum_1.ProfileStatusEnum.CANCELED;
35
39
  }),
36
40
  __metadata("design:type", Boolean)
37
41
  ], AgregatorProfile.prototype, "verified", void 0);
@@ -103,10 +107,6 @@ __decorate([
103
107
  (0, class_transformer_1.Expose)(),
104
108
  __metadata("design:type", Number)
105
109
  ], AgregatorQuestroomRO.prototype, "id", void 0);
106
- __decorate([
107
- (0, class_transformer_1.Expose)(),
108
- __metadata("design:type", String)
109
- ], AgregatorQuestroomRO.prototype, "currency", void 0);
110
110
  __decorate([
111
111
  (0, class_transformer_1.Expose)(),
112
112
  __metadata("design:type", Date)
@@ -211,11 +211,12 @@ __decorate([
211
211
  ], AgregatorQuestroomRO.prototype, "reviewsCount", void 0);
212
212
  __decorate([
213
213
  (0, class_transformer_1.Expose)(),
214
- (0, class_transformer_1.Transform)(({ obj }) => {
215
- var _a;
216
- const type = (_a = obj.profile.step) === null || _a === void 0 ? void 0 : _a.split('_')[0];
217
- return obj.hasSchedule && (type === 'integrated' || type === 'CRM') && obj.partnerProgram;
218
- }),
214
+ (0, class_transformer_1.Transform)(({ obj }) => { var _a; return currency_by_country_1.currencyByCountry[(_a = obj.profile) === null || _a === void 0 ? void 0 : _a.countery]; }),
215
+ __metadata("design:type", String)
216
+ ], AgregatorQuestroomRO.prototype, "currency", void 0);
217
+ __decorate([
218
+ (0, class_transformer_1.Expose)(),
219
+ (0, class_transformer_1.Transform)(({ obj }) => { var _a; return obj.templateId && ((_a = obj.profile) === null || _a === void 0 ? void 0 : _a.partnerProgram) === partner_program_enum_1.PartnerProgramEnum.ACTIVE; }),
219
220
  __metadata("design:type", Boolean)
220
221
  ], AgregatorQuestroomRO.prototype, "hasSchedule", void 0);
221
222
  __decorate([
@@ -1,6 +1,6 @@
1
1
  import { AgregatorCityRO } from './agregator-city.ro';
2
2
  import { AgregatorQuestroomCardRO } from './agregator-questroom-card.ro';
3
- export declare type AgregatorQuestroomsAndCitiesRO = {
3
+ export declare class AgregatorQuestroomsAndCitiesRO {
4
4
  city: AgregatorCityRO;
5
5
  questrooms: AgregatorQuestroomCardRO[];
6
- };
6
+ }
@@ -1,2 +1,28 @@
1
1
  "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
2
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.AgregatorQuestroomsAndCitiesRO = void 0;
13
+ const class_transformer_1 = require("class-transformer");
14
+ const agregator_city_ro_1 = require("./agregator-city.ro");
15
+ const agregator_questroom_card_ro_1 = require("./agregator-questroom-card.ro");
16
+ class AgregatorQuestroomsAndCitiesRO {
17
+ }
18
+ __decorate([
19
+ (0, class_transformer_1.Expose)(),
20
+ (0, class_transformer_1.Type)(() => agregator_city_ro_1.AgregatorCityRO),
21
+ __metadata("design:type", agregator_city_ro_1.AgregatorCityRO)
22
+ ], AgregatorQuestroomsAndCitiesRO.prototype, "city", void 0);
23
+ __decorate([
24
+ (0, class_transformer_1.Expose)(),
25
+ (0, class_transformer_1.Type)(() => agregator_questroom_card_ro_1.AgregatorQuestroomCardRO),
26
+ __metadata("design:type", Array)
27
+ ], AgregatorQuestroomsAndCitiesRO.prototype, "questrooms", void 0);
28
+ exports.AgregatorQuestroomsAndCitiesRO = AgregatorQuestroomsAndCitiesRO;
@@ -12,6 +12,10 @@ declare type Bitton = {
12
12
  declare type Divider = {
13
13
  type: 'divider';
14
14
  };
15
+ declare type Reply = {
16
+ type: 'reply';
17
+ text: string;
18
+ };
15
19
  declare type List = {
16
20
  type: 'list';
17
21
  title?: string;
@@ -25,7 +29,7 @@ declare type Context = {
25
29
  tag?: string;
26
30
  subscription?: boolean;
27
31
  logo?: string;
28
- sections: Array<Divider | Bitton | Paragraph | List>;
32
+ sections: Array<Divider | Bitton | Paragraph | List | Reply>;
29
33
  };
30
34
  export declare type SendEmailRequestParams = {
31
35
  from: EmailSenderEnum;
@@ -1,6 +1,7 @@
1
1
  import { EmailSenderEnum } from './enum/email.senders';
2
2
  export declare class SendEmailDto {
3
3
  text: string;
4
+ reply: string;
4
5
  to: string;
5
6
  from: EmailSenderEnum;
6
7
  subject: string;
@@ -21,6 +21,11 @@ __decorate([
21
21
  (0, class_transformer_1.Expose)(),
22
22
  __metadata("design:type", String)
23
23
  ], SendEmailDto.prototype, "text", void 0);
24
+ __decorate([
25
+ (0, class_validator_1.IsOptional)(),
26
+ (0, class_transformer_1.Expose)(),
27
+ __metadata("design:type", String)
28
+ ], SendEmailDto.prototype, "reply", void 0);
24
29
  __decorate([
25
30
  (0, class_validator_1.IsEmail)(),
26
31
  (0, class_transformer_1.Expose)(),