@escapenavigator/types 1.10.146 → 1.10.148
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/emails/index.d.ts +23 -0
- package/dist/openapi/profiles/openapi-cancel-booking.dto.d.ts +9 -0
- package/dist/openapi/profiles/openapi-cancel-booking.dto.js +80 -0
- package/dist/openapi/profiles/openapi-create-booking.dto.d.ts +16 -0
- package/dist/openapi/profiles/openapi-create-booking.dto.js +128 -0
- package/dist/openapi/profiles/openapi-profile-booking-details.ro.d.ts +43 -0
- package/dist/openapi/profiles/openapi-profile-booking-details.ro.js +191 -0
- package/dist/openapi/profiles/openapi-profile-booking-list-item.ro.d.ts +15 -0
- package/dist/openapi/profiles/openapi-profile-booking-list-item.ro.js +87 -10
- package/dist/openapi/questrooms/openapi-questroom.ro.d.ts +21 -0
- package/dist/openapi/questrooms/openapi-questroom.ro.js +117 -0
- package/dist/openapi/shared/openapi-error.ro.d.ts +3 -0
- package/dist/openapi/shared/openapi-error.ro.js +23 -0
- package/dist/openapi/slots/openapi-day-schedule.dto.d.ts +1 -1
- package/dist/openapi/slots/openapi-day-schedule.dto.js +21 -4
- package/dist/openapi/slots/openapi-slot-tariff.ro.d.ts +6 -0
- package/dist/openapi/slots/openapi-slot-tariff.ro.js +34 -0
- package/dist/openapi/slots/openapi-week-schedule.dto.js +6 -6
- package/dist/openapi/slots/openapi-widget-slot.ro.d.ts +2 -2
- package/dist/openapi/slots/openapi-widget-slot.ro.js +39 -2
- package/dist/openapi/widget/openapi-resolve-promocode.ro.d.ts +1 -1
- package/dist/shared/source.enum.d.ts +1 -0
- package/dist/shared/source.enum.js +1 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +2 -2
package/dist/emails/index.d.ts
CHANGED
|
@@ -56,6 +56,14 @@ export type EmailDataV1 = {
|
|
|
56
56
|
tag?: string;
|
|
57
57
|
subscription?: boolean;
|
|
58
58
|
logo?: string;
|
|
59
|
+
/**
|
|
60
|
+
* Готовая локализованная причинная строка футера (как у v2). Задаётся
|
|
61
|
+
* ТОЛЬКО для писем-уведомлений в транзакционном/booking-контексте —
|
|
62
|
+
* alfa-mailer рендерит её в `footer.hbs`. Намеренно не выставляется
|
|
63
|
+
* глобально: legacy `EmailService` шлёт и sales/invoice/invite-письма,
|
|
64
|
+
* где причинная строка «это уведомление, не отвечайте» была бы неверной.
|
|
65
|
+
*/
|
|
66
|
+
footerNotice?: string;
|
|
59
67
|
sections: Array<Divider | Bitton | Paragraph | List | Reply | Image | Code | Pdf>;
|
|
60
68
|
};
|
|
61
69
|
/**
|
|
@@ -79,6 +87,13 @@ export type EmailDataV2 = EmailContentJsonV2 & {
|
|
|
79
87
|
profileTitle: string;
|
|
80
88
|
unsubscribeUrl: string;
|
|
81
89
|
legalAddress?: string;
|
|
90
|
+
/**
|
|
91
|
+
* Язык письма (`profile.language`) для локализации футера —
|
|
92
|
+
* причинной строки транзакционки и подписи/«Отписаться» у
|
|
93
|
+
* маркетинга. Резолвится в `profile-email.service` через i18n
|
|
94
|
+
* с code-fallback'ом. Если не задан — `en`.
|
|
95
|
+
*/
|
|
96
|
+
lang?: string;
|
|
82
97
|
};
|
|
83
98
|
/**
|
|
84
99
|
* Campaign-level UTM parameters injected onto every outbound `<a>`
|
|
@@ -129,5 +144,13 @@ export type SendEmailRequestParams = {
|
|
|
129
144
|
tags?: string;
|
|
130
145
|
replyMessageId?: string;
|
|
131
146
|
data: SendEmailData;
|
|
147
|
+
/**
|
|
148
|
+
* RFC 2369 / RFC 8058 one-click unsubscribe. Заполняется только для
|
|
149
|
+
* маркетинговых писем (`kind: MARKETING`) — это значение уходит в
|
|
150
|
+
* заголовок `List-Unsubscribe` (`<https-one-click>, <mailto>`), а
|
|
151
|
+
* парный `List-Unsubscribe-Post: List-Unsubscribe=One-Click` mailer
|
|
152
|
+
* добавляет сам. У транзакционки пусто — отписки там нет.
|
|
153
|
+
*/
|
|
154
|
+
listUnsubscribe?: string;
|
|
132
155
|
};
|
|
133
156
|
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { OrderCancelReasonEnum } from '../../order/enum/order-cancel-reson.enum';
|
|
2
|
+
export declare class OpenapiCancelBookingDto {
|
|
3
|
+
reason: OrderCancelReasonEnum;
|
|
4
|
+
reasonText?: string;
|
|
5
|
+
returnCertificates?: boolean;
|
|
6
|
+
fineAmount?: number;
|
|
7
|
+
allowFined?: boolean;
|
|
8
|
+
notifyClient?: boolean;
|
|
9
|
+
}
|
|
@@ -0,0 +1,80 @@
|
|
|
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
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.OpenapiCancelBookingDto = void 0;
|
|
13
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
const order_cancel_reson_enum_1 = require("../../order/enum/order-cancel-reson.enum");
|
|
16
|
+
class OpenapiCancelBookingDto {
|
|
17
|
+
}
|
|
18
|
+
exports.OpenapiCancelBookingDto = OpenapiCancelBookingDto;
|
|
19
|
+
__decorate([
|
|
20
|
+
(0, swagger_1.ApiProperty)({
|
|
21
|
+
enum: [order_cancel_reson_enum_1.OrderCancelReasonEnum.QUESTROOM, order_cancel_reson_enum_1.OrderCancelReasonEnum.CLIENT],
|
|
22
|
+
example: order_cancel_reson_enum_1.OrderCancelReasonEnum.CLIENT,
|
|
23
|
+
description: `Who initiated the cancellation. This drives whether a fine applies:
|
|
24
|
+
- \`questroom\` — cancelled by the venue (your side). The client is not at fault, so the cancellation policy is bypassed: no fine by default and the booking is fully refundable.
|
|
25
|
+
- \`client\` — cancelled by/for the client. The quest room's cancellation policy is applied: a fine may be charged depending on how close to the game time the cancellation happens.`,
|
|
26
|
+
}),
|
|
27
|
+
(0, class_validator_1.IsIn)([order_cancel_reson_enum_1.OrderCancelReasonEnum.QUESTROOM, order_cancel_reson_enum_1.OrderCancelReasonEnum.CLIENT]),
|
|
28
|
+
__metadata("design:type", String)
|
|
29
|
+
], OpenapiCancelBookingDto.prototype, "reason", void 0);
|
|
30
|
+
__decorate([
|
|
31
|
+
(0, swagger_1.ApiProperty)({
|
|
32
|
+
required: false,
|
|
33
|
+
example: 'Client requested a reschedule',
|
|
34
|
+
description: 'Optional free-text note stored with the cancellation.',
|
|
35
|
+
}),
|
|
36
|
+
(0, class_validator_1.IsOptional)(),
|
|
37
|
+
(0, class_validator_1.IsString)(),
|
|
38
|
+
__metadata("design:type", String)
|
|
39
|
+
], OpenapiCancelBookingDto.prototype, "reasonText", void 0);
|
|
40
|
+
__decorate([
|
|
41
|
+
(0, swagger_1.ApiProperty)({
|
|
42
|
+
required: false,
|
|
43
|
+
default: false,
|
|
44
|
+
description: 'Return any certificates used on this booking back to sale.',
|
|
45
|
+
}),
|
|
46
|
+
(0, class_validator_1.IsOptional)(),
|
|
47
|
+
(0, class_validator_1.IsBoolean)(),
|
|
48
|
+
__metadata("design:type", Boolean)
|
|
49
|
+
], OpenapiCancelBookingDto.prototype, "returnCertificates", void 0);
|
|
50
|
+
__decorate([
|
|
51
|
+
(0, swagger_1.ApiProperty)({
|
|
52
|
+
required: false,
|
|
53
|
+
example: 0,
|
|
54
|
+
description: 'Override the computed fine, in minor currency units. Omit to let the cancellation policy decide.',
|
|
55
|
+
}),
|
|
56
|
+
(0, class_validator_1.IsOptional)(),
|
|
57
|
+
(0, class_validator_1.IsInt)(),
|
|
58
|
+
(0, class_validator_1.Min)(0),
|
|
59
|
+
__metadata("design:type", Number)
|
|
60
|
+
], OpenapiCancelBookingDto.prototype, "fineAmount", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
(0, swagger_1.ApiProperty)({
|
|
63
|
+
required: false,
|
|
64
|
+
default: false,
|
|
65
|
+
description: 'Force the cancellation even when the policy would otherwise disallow an online cancellation (a fine is recorded). Use deliberately.',
|
|
66
|
+
}),
|
|
67
|
+
(0, class_validator_1.IsOptional)(),
|
|
68
|
+
(0, class_validator_1.IsBoolean)(),
|
|
69
|
+
__metadata("design:type", Boolean)
|
|
70
|
+
], OpenapiCancelBookingDto.prototype, "allowFined", void 0);
|
|
71
|
+
__decorate([
|
|
72
|
+
(0, swagger_1.ApiProperty)({
|
|
73
|
+
required: false,
|
|
74
|
+
default: true,
|
|
75
|
+
description: 'Send the cancellation email to the client.',
|
|
76
|
+
}),
|
|
77
|
+
(0, class_validator_1.IsOptional)(),
|
|
78
|
+
(0, class_validator_1.IsBoolean)(),
|
|
79
|
+
__metadata("design:type", Boolean)
|
|
80
|
+
], OpenapiCancelBookingDto.prototype, "notifyClient", void 0);
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Languages } from '../../shared/enum/languages.enum';
|
|
2
|
+
export declare class OpenapiBookingClientDto {
|
|
3
|
+
name: string;
|
|
4
|
+
surname?: string;
|
|
5
|
+
phone?: string;
|
|
6
|
+
email?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare class OpenapiCreateBookingDto {
|
|
9
|
+
slotId: number;
|
|
10
|
+
tariffId: number;
|
|
11
|
+
players: number;
|
|
12
|
+
children?: number;
|
|
13
|
+
comment?: string;
|
|
14
|
+
language?: Languages;
|
|
15
|
+
client: OpenapiBookingClientDto;
|
|
16
|
+
}
|
|
@@ -0,0 +1,128 @@
|
|
|
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
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.OpenapiCreateBookingDto = exports.OpenapiBookingClientDto = void 0;
|
|
13
|
+
/* eslint-disable max-classes-per-file */
|
|
14
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
15
|
+
const class_transformer_1 = require("class-transformer");
|
|
16
|
+
const class_validator_1 = require("class-validator");
|
|
17
|
+
const languages_enum_1 = require("../../shared/enum/languages.enum");
|
|
18
|
+
class OpenapiBookingClientDto {
|
|
19
|
+
}
|
|
20
|
+
exports.OpenapiBookingClientDto = OpenapiBookingClientDto;
|
|
21
|
+
__decorate([
|
|
22
|
+
(0, swagger_1.ApiProperty)({
|
|
23
|
+
example: 'John',
|
|
24
|
+
description: "Client's first name.",
|
|
25
|
+
}),
|
|
26
|
+
(0, class_validator_1.IsString)(),
|
|
27
|
+
__metadata("design:type", String)
|
|
28
|
+
], OpenapiBookingClientDto.prototype, "name", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
(0, swagger_1.ApiProperty)({
|
|
31
|
+
required: false,
|
|
32
|
+
example: 'Doe',
|
|
33
|
+
description: "Client's last name.",
|
|
34
|
+
}),
|
|
35
|
+
(0, class_validator_1.IsOptional)(),
|
|
36
|
+
(0, class_validator_1.IsString)(),
|
|
37
|
+
__metadata("design:type", String)
|
|
38
|
+
], OpenapiBookingClientDto.prototype, "surname", void 0);
|
|
39
|
+
__decorate([
|
|
40
|
+
(0, swagger_1.ApiProperty)({
|
|
41
|
+
required: false,
|
|
42
|
+
example: '+49 151 23456789',
|
|
43
|
+
description: 'Client phone number. Either `phone` or `email` must be provided. Used to match an existing client (dedup) before creating a new one.',
|
|
44
|
+
}),
|
|
45
|
+
(0, class_validator_1.IsOptional)(),
|
|
46
|
+
(0, class_validator_1.IsString)(),
|
|
47
|
+
__metadata("design:type", String)
|
|
48
|
+
], OpenapiBookingClientDto.prototype, "phone", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
(0, swagger_1.ApiProperty)({
|
|
51
|
+
required: false,
|
|
52
|
+
example: 'john.doe@example.com',
|
|
53
|
+
description: 'Client email. Either `phone` or `email` must be provided. Used to match an existing client (dedup) before creating a new one.',
|
|
54
|
+
}),
|
|
55
|
+
(0, class_validator_1.IsOptional)(),
|
|
56
|
+
(0, class_validator_1.IsEmail)(),
|
|
57
|
+
__metadata("design:type", String)
|
|
58
|
+
], OpenapiBookingClientDto.prototype, "email", void 0);
|
|
59
|
+
class OpenapiCreateBookingDto {
|
|
60
|
+
}
|
|
61
|
+
exports.OpenapiCreateBookingDto = OpenapiCreateBookingDto;
|
|
62
|
+
__decorate([
|
|
63
|
+
(0, swagger_1.ApiProperty)({
|
|
64
|
+
example: 12345,
|
|
65
|
+
description: 'Slot id to book — the numeric `eventId` returned by `GET /api/slots/week`.',
|
|
66
|
+
}),
|
|
67
|
+
(0, class_validator_1.IsInt)(),
|
|
68
|
+
__metadata("design:type", Number)
|
|
69
|
+
], OpenapiCreateBookingDto.prototype, "slotId", void 0);
|
|
70
|
+
__decorate([
|
|
71
|
+
(0, swagger_1.ApiProperty)({
|
|
72
|
+
example: 101,
|
|
73
|
+
description: 'Tariff id for the slot — the `tariffId` returned alongside the slot in `GET /api/slots/week`.',
|
|
74
|
+
}),
|
|
75
|
+
(0, class_validator_1.IsInt)(),
|
|
76
|
+
__metadata("design:type", Number)
|
|
77
|
+
], OpenapiCreateBookingDto.prototype, "tariffId", void 0);
|
|
78
|
+
__decorate([
|
|
79
|
+
(0, swagger_1.ApiProperty)({
|
|
80
|
+
example: 4,
|
|
81
|
+
minimum: 1,
|
|
82
|
+
description: 'Number of adult players. Must fit the slot capacity and the tariff price map.',
|
|
83
|
+
}),
|
|
84
|
+
(0, class_validator_1.IsInt)(),
|
|
85
|
+
(0, class_validator_1.Min)(1),
|
|
86
|
+
__metadata("design:type", Number)
|
|
87
|
+
], OpenapiCreateBookingDto.prototype, "players", void 0);
|
|
88
|
+
__decorate([
|
|
89
|
+
(0, swagger_1.ApiProperty)({
|
|
90
|
+
required: false,
|
|
91
|
+
default: 0,
|
|
92
|
+
example: 0,
|
|
93
|
+
description: 'Number of children. Defaults to 0.',
|
|
94
|
+
}),
|
|
95
|
+
(0, class_validator_1.IsOptional)(),
|
|
96
|
+
(0, class_validator_1.IsInt)(),
|
|
97
|
+
(0, class_validator_1.Min)(0),
|
|
98
|
+
__metadata("design:type", Number)
|
|
99
|
+
], OpenapiCreateBookingDto.prototype, "children", void 0);
|
|
100
|
+
__decorate([
|
|
101
|
+
(0, swagger_1.ApiProperty)({
|
|
102
|
+
required: false,
|
|
103
|
+
example: 'Birthday party, please prepare a cake.',
|
|
104
|
+
description: 'Optional free-text note stored on the booking.',
|
|
105
|
+
}),
|
|
106
|
+
(0, class_validator_1.IsOptional)(),
|
|
107
|
+
(0, class_validator_1.IsString)(),
|
|
108
|
+
__metadata("design:type", String)
|
|
109
|
+
], OpenapiCreateBookingDto.prototype, "comment", void 0);
|
|
110
|
+
__decorate([
|
|
111
|
+
(0, swagger_1.ApiProperty)({
|
|
112
|
+
required: false,
|
|
113
|
+
enum: languages_enum_1.Languages,
|
|
114
|
+
description: 'Preferred language for the booking. Falls back to the profile default if omitted or unavailable.',
|
|
115
|
+
}),
|
|
116
|
+
(0, class_validator_1.IsOptional)(),
|
|
117
|
+
(0, class_validator_1.IsString)(),
|
|
118
|
+
__metadata("design:type", String)
|
|
119
|
+
], OpenapiCreateBookingDto.prototype, "language", void 0);
|
|
120
|
+
__decorate([
|
|
121
|
+
(0, swagger_1.ApiProperty)({
|
|
122
|
+
type: OpenapiBookingClientDto,
|
|
123
|
+
description: 'Client to attach to the booking. An existing client is reused when matched by phone/email; otherwise a new one is created.',
|
|
124
|
+
}),
|
|
125
|
+
(0, class_validator_1.ValidateNested)(),
|
|
126
|
+
(0, class_transformer_1.Type)(() => OpenapiBookingClientDto),
|
|
127
|
+
__metadata("design:type", OpenapiBookingClientDto)
|
|
128
|
+
], OpenapiCreateBookingDto.prototype, "client", void 0);
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { OrderCancelReasonEnum } from '../../order/enum/order-cancel-reson.enum';
|
|
2
|
+
import { Languages } from '../../shared/enum/languages.enum';
|
|
3
|
+
import { TransactionTypeEnum } from '../../transaction/enum/transaction-type.enum';
|
|
4
|
+
import { OpenapiProfileBookingListItemRO } from './openapi-profile-booking-list-item.ro';
|
|
5
|
+
export declare class OpenapiBookingCancelationRO {
|
|
6
|
+
withFine: boolean;
|
|
7
|
+
type: OrderCancelReasonEnum | null;
|
|
8
|
+
reason: string | null;
|
|
9
|
+
}
|
|
10
|
+
export declare class OpenapiBookingUpsellingRO {
|
|
11
|
+
title: string;
|
|
12
|
+
amount: number;
|
|
13
|
+
}
|
|
14
|
+
export declare class OpenapiBookingTransactionRO {
|
|
15
|
+
amount: number;
|
|
16
|
+
type: TransactionTypeEnum;
|
|
17
|
+
paymentId: string | null;
|
|
18
|
+
method: string | null;
|
|
19
|
+
}
|
|
20
|
+
export declare class OpenapiBookingPromocodeRO {
|
|
21
|
+
code: string;
|
|
22
|
+
amount: number;
|
|
23
|
+
}
|
|
24
|
+
export declare class OpenapiBookingDiscountRO {
|
|
25
|
+
reason: string | null;
|
|
26
|
+
amount: number;
|
|
27
|
+
}
|
|
28
|
+
export declare class OpenapiBookingCertificateRO {
|
|
29
|
+
code: string | null;
|
|
30
|
+
nominal: number;
|
|
31
|
+
}
|
|
32
|
+
export declare class OpenapiProfileBookingDetailsRO extends OpenapiProfileBookingListItemRO {
|
|
33
|
+
start: string | null;
|
|
34
|
+
end: string | null;
|
|
35
|
+
language: Languages | null;
|
|
36
|
+
comment: string | null;
|
|
37
|
+
cancelation: OpenapiBookingCancelationRO | null;
|
|
38
|
+
upsellings: OpenapiBookingUpsellingRO[];
|
|
39
|
+
transactions: OpenapiBookingTransactionRO[];
|
|
40
|
+
promocodes: OpenapiBookingPromocodeRO[];
|
|
41
|
+
discounts: OpenapiBookingDiscountRO[];
|
|
42
|
+
certificates: OpenapiBookingCertificateRO[];
|
|
43
|
+
}
|
|
@@ -0,0 +1,191 @@
|
|
|
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
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.OpenapiProfileBookingDetailsRO = exports.OpenapiBookingCertificateRO = exports.OpenapiBookingDiscountRO = exports.OpenapiBookingPromocodeRO = exports.OpenapiBookingTransactionRO = exports.OpenapiBookingUpsellingRO = exports.OpenapiBookingCancelationRO = void 0;
|
|
13
|
+
/* eslint-disable max-classes-per-file */
|
|
14
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
15
|
+
const class_transformer_1 = require("class-transformer");
|
|
16
|
+
const order_cancel_reson_enum_1 = require("../../order/enum/order-cancel-reson.enum");
|
|
17
|
+
const languages_enum_1 = require("../../shared/enum/languages.enum");
|
|
18
|
+
const transaction_type_enum_1 = require("../../transaction/enum/transaction-type.enum");
|
|
19
|
+
const openapi_profile_booking_list_item_ro_1 = require("./openapi-profile-booking-list-item.ro");
|
|
20
|
+
class OpenapiBookingCancelationRO {
|
|
21
|
+
}
|
|
22
|
+
exports.OpenapiBookingCancelationRO = OpenapiBookingCancelationRO;
|
|
23
|
+
__decorate([
|
|
24
|
+
(0, class_transformer_1.Expose)(),
|
|
25
|
+
(0, swagger_1.ApiProperty)({ example: true, description: 'Whether a cancellation fine was applied.' }),
|
|
26
|
+
__metadata("design:type", Boolean)
|
|
27
|
+
], OpenapiBookingCancelationRO.prototype, "withFine", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, class_transformer_1.Expose)(),
|
|
30
|
+
(0, swagger_1.ApiProperty)({
|
|
31
|
+
enum: order_cancel_reson_enum_1.OrderCancelReasonEnum,
|
|
32
|
+
nullable: true,
|
|
33
|
+
description: 'Cancellation reason type.',
|
|
34
|
+
}),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], OpenapiBookingCancelationRO.prototype, "type", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, class_transformer_1.Expose)(),
|
|
39
|
+
(0, swagger_1.ApiProperty)({
|
|
40
|
+
example: 'Client requested reschedule',
|
|
41
|
+
nullable: true,
|
|
42
|
+
description: 'Free-text cancellation note.',
|
|
43
|
+
}),
|
|
44
|
+
__metadata("design:type", String)
|
|
45
|
+
], OpenapiBookingCancelationRO.prototype, "reason", void 0);
|
|
46
|
+
class OpenapiBookingUpsellingRO {
|
|
47
|
+
}
|
|
48
|
+
exports.OpenapiBookingUpsellingRO = OpenapiBookingUpsellingRO;
|
|
49
|
+
__decorate([
|
|
50
|
+
(0, class_transformer_1.Expose)(),
|
|
51
|
+
(0, swagger_1.ApiProperty)({ example: 'VIP Package' }),
|
|
52
|
+
__metadata("design:type", String)
|
|
53
|
+
], OpenapiBookingUpsellingRO.prototype, "title", void 0);
|
|
54
|
+
__decorate([
|
|
55
|
+
(0, class_transformer_1.Expose)(),
|
|
56
|
+
(0, swagger_1.ApiProperty)({ example: 3000, description: 'Amount in minor currency units.' }),
|
|
57
|
+
__metadata("design:type", Number)
|
|
58
|
+
], OpenapiBookingUpsellingRO.prototype, "amount", void 0);
|
|
59
|
+
class OpenapiBookingTransactionRO {
|
|
60
|
+
}
|
|
61
|
+
exports.OpenapiBookingTransactionRO = OpenapiBookingTransactionRO;
|
|
62
|
+
__decorate([
|
|
63
|
+
(0, class_transformer_1.Expose)(),
|
|
64
|
+
(0, swagger_1.ApiProperty)({ example: 5000, description: 'Amount in minor currency units.' }),
|
|
65
|
+
__metadata("design:type", Number)
|
|
66
|
+
], OpenapiBookingTransactionRO.prototype, "amount", void 0);
|
|
67
|
+
__decorate([
|
|
68
|
+
(0, class_transformer_1.Expose)(),
|
|
69
|
+
(0, swagger_1.ApiProperty)({ enum: transaction_type_enum_1.TransactionTypeEnum, description: 'Transaction type.' }),
|
|
70
|
+
__metadata("design:type", String)
|
|
71
|
+
], OpenapiBookingTransactionRO.prototype, "type", void 0);
|
|
72
|
+
__decorate([
|
|
73
|
+
(0, class_transformer_1.Expose)(),
|
|
74
|
+
(0, swagger_1.ApiProperty)({ example: 'pi_3Q...', nullable: true, description: 'External payment id.' }),
|
|
75
|
+
__metadata("design:type", String)
|
|
76
|
+
], OpenapiBookingTransactionRO.prototype, "paymentId", void 0);
|
|
77
|
+
__decorate([
|
|
78
|
+
(0, class_transformer_1.Expose)(),
|
|
79
|
+
(0, swagger_1.ApiProperty)({ example: 'Stripe', nullable: true, description: 'Cashbox / payment method.' }),
|
|
80
|
+
__metadata("design:type", String)
|
|
81
|
+
], OpenapiBookingTransactionRO.prototype, "method", void 0);
|
|
82
|
+
class OpenapiBookingPromocodeRO {
|
|
83
|
+
}
|
|
84
|
+
exports.OpenapiBookingPromocodeRO = OpenapiBookingPromocodeRO;
|
|
85
|
+
__decorate([
|
|
86
|
+
(0, class_transformer_1.Expose)(),
|
|
87
|
+
(0, swagger_1.ApiProperty)({ example: 'SPRING50' }),
|
|
88
|
+
__metadata("design:type", String)
|
|
89
|
+
], OpenapiBookingPromocodeRO.prototype, "code", void 0);
|
|
90
|
+
__decorate([
|
|
91
|
+
(0, class_transformer_1.Expose)(),
|
|
92
|
+
(0, swagger_1.ApiProperty)({ example: 1500, description: 'Discount amount in minor currency units.' }),
|
|
93
|
+
__metadata("design:type", Number)
|
|
94
|
+
], OpenapiBookingPromocodeRO.prototype, "amount", void 0);
|
|
95
|
+
class OpenapiBookingDiscountRO {
|
|
96
|
+
}
|
|
97
|
+
exports.OpenapiBookingDiscountRO = OpenapiBookingDiscountRO;
|
|
98
|
+
__decorate([
|
|
99
|
+
(0, class_transformer_1.Expose)(),
|
|
100
|
+
(0, swagger_1.ApiProperty)({ example: 'Loyalty discount', nullable: true }),
|
|
101
|
+
__metadata("design:type", String)
|
|
102
|
+
], OpenapiBookingDiscountRO.prototype, "reason", void 0);
|
|
103
|
+
__decorate([
|
|
104
|
+
(0, class_transformer_1.Expose)(),
|
|
105
|
+
(0, swagger_1.ApiProperty)({ example: 1000, description: 'Discount amount in minor currency units.' }),
|
|
106
|
+
__metadata("design:type", Number)
|
|
107
|
+
], OpenapiBookingDiscountRO.prototype, "amount", void 0);
|
|
108
|
+
class OpenapiBookingCertificateRO {
|
|
109
|
+
}
|
|
110
|
+
exports.OpenapiBookingCertificateRO = OpenapiBookingCertificateRO;
|
|
111
|
+
__decorate([
|
|
112
|
+
(0, class_transformer_1.Expose)(),
|
|
113
|
+
(0, swagger_1.ApiProperty)({ example: 'CERT123', nullable: true }),
|
|
114
|
+
__metadata("design:type", String)
|
|
115
|
+
], OpenapiBookingCertificateRO.prototype, "code", void 0);
|
|
116
|
+
__decorate([
|
|
117
|
+
(0, class_transformer_1.Expose)(),
|
|
118
|
+
(0, swagger_1.ApiProperty)({ example: 5000, description: 'Certificate nominal in minor currency units.' }),
|
|
119
|
+
__metadata("design:type", Number)
|
|
120
|
+
], OpenapiBookingCertificateRO.prototype, "nominal", void 0);
|
|
121
|
+
class OpenapiProfileBookingDetailsRO extends openapi_profile_booking_list_item_ro_1.OpenapiProfileBookingListItemRO {
|
|
122
|
+
}
|
|
123
|
+
exports.OpenapiProfileBookingDetailsRO = OpenapiProfileBookingDetailsRO;
|
|
124
|
+
__decorate([
|
|
125
|
+
(0, class_transformer_1.Expose)(),
|
|
126
|
+
(0, swagger_1.ApiProperty)({
|
|
127
|
+
example: '18:30',
|
|
128
|
+
nullable: true,
|
|
129
|
+
description: 'Game start time (HH:mm, local to the quest room).',
|
|
130
|
+
}),
|
|
131
|
+
__metadata("design:type", String)
|
|
132
|
+
], OpenapiProfileBookingDetailsRO.prototype, "start", void 0);
|
|
133
|
+
__decorate([
|
|
134
|
+
(0, class_transformer_1.Expose)(),
|
|
135
|
+
(0, swagger_1.ApiProperty)({
|
|
136
|
+
example: '20:00',
|
|
137
|
+
nullable: true,
|
|
138
|
+
description: 'Game end time (HH:mm, local to the quest room).',
|
|
139
|
+
}),
|
|
140
|
+
__metadata("design:type", String)
|
|
141
|
+
], OpenapiProfileBookingDetailsRO.prototype, "end", void 0);
|
|
142
|
+
__decorate([
|
|
143
|
+
(0, class_transformer_1.Expose)(),
|
|
144
|
+
(0, swagger_1.ApiProperty)({ enum: languages_enum_1.Languages, nullable: true, description: 'Booking language.' }),
|
|
145
|
+
__metadata("design:type", String)
|
|
146
|
+
], OpenapiProfileBookingDetailsRO.prototype, "language", void 0);
|
|
147
|
+
__decorate([
|
|
148
|
+
(0, class_transformer_1.Expose)(),
|
|
149
|
+
(0, swagger_1.ApiProperty)({ example: 'Birthday party, needs extra chairs.', nullable: true }),
|
|
150
|
+
__metadata("design:type", String)
|
|
151
|
+
], OpenapiProfileBookingDetailsRO.prototype, "comment", void 0);
|
|
152
|
+
__decorate([
|
|
153
|
+
(0, class_transformer_1.Expose)(),
|
|
154
|
+
(0, class_transformer_1.Type)(() => OpenapiBookingCancelationRO),
|
|
155
|
+
(0, swagger_1.ApiProperty)({
|
|
156
|
+
type: () => OpenapiBookingCancelationRO,
|
|
157
|
+
nullable: true,
|
|
158
|
+
description: 'Cancellation details (null when the booking is active).',
|
|
159
|
+
}),
|
|
160
|
+
__metadata("design:type", OpenapiBookingCancelationRO)
|
|
161
|
+
], OpenapiProfileBookingDetailsRO.prototype, "cancelation", void 0);
|
|
162
|
+
__decorate([
|
|
163
|
+
(0, class_transformer_1.Expose)(),
|
|
164
|
+
(0, class_transformer_1.Type)(() => OpenapiBookingUpsellingRO),
|
|
165
|
+
(0, swagger_1.ApiProperty)({ type: () => OpenapiBookingUpsellingRO, isArray: true }),
|
|
166
|
+
__metadata("design:type", Array)
|
|
167
|
+
], OpenapiProfileBookingDetailsRO.prototype, "upsellings", void 0);
|
|
168
|
+
__decorate([
|
|
169
|
+
(0, class_transformer_1.Expose)(),
|
|
170
|
+
(0, class_transformer_1.Type)(() => OpenapiBookingTransactionRO),
|
|
171
|
+
(0, swagger_1.ApiProperty)({ type: () => OpenapiBookingTransactionRO, isArray: true }),
|
|
172
|
+
__metadata("design:type", Array)
|
|
173
|
+
], OpenapiProfileBookingDetailsRO.prototype, "transactions", void 0);
|
|
174
|
+
__decorate([
|
|
175
|
+
(0, class_transformer_1.Expose)(),
|
|
176
|
+
(0, class_transformer_1.Type)(() => OpenapiBookingPromocodeRO),
|
|
177
|
+
(0, swagger_1.ApiProperty)({ type: () => OpenapiBookingPromocodeRO, isArray: true }),
|
|
178
|
+
__metadata("design:type", Array)
|
|
179
|
+
], OpenapiProfileBookingDetailsRO.prototype, "promocodes", void 0);
|
|
180
|
+
__decorate([
|
|
181
|
+
(0, class_transformer_1.Expose)(),
|
|
182
|
+
(0, class_transformer_1.Type)(() => OpenapiBookingDiscountRO),
|
|
183
|
+
(0, swagger_1.ApiProperty)({ type: () => OpenapiBookingDiscountRO, isArray: true }),
|
|
184
|
+
__metadata("design:type", Array)
|
|
185
|
+
], OpenapiProfileBookingDetailsRO.prototype, "discounts", void 0);
|
|
186
|
+
__decorate([
|
|
187
|
+
(0, class_transformer_1.Expose)(),
|
|
188
|
+
(0, class_transformer_1.Type)(() => OpenapiBookingCertificateRO),
|
|
189
|
+
(0, swagger_1.ApiProperty)({ type: () => OpenapiBookingCertificateRO, isArray: true }),
|
|
190
|
+
__metadata("design:type", Array)
|
|
191
|
+
], OpenapiProfileBookingDetailsRO.prototype, "certificates", void 0);
|
|
@@ -1,9 +1,18 @@
|
|
|
1
|
+
import { ProfileCurrencyEnum } from '../../profile/enum/profile-currency';
|
|
2
|
+
import { SourceEnum } from '../../shared/source.enum';
|
|
1
3
|
export declare class OpenapiProfileBookingQuestroomRO {
|
|
2
4
|
id: number;
|
|
3
5
|
title: string;
|
|
4
6
|
}
|
|
7
|
+
export declare class OpenapiProfileBookingClientRO {
|
|
8
|
+
name: string | null;
|
|
9
|
+
surname: string | null;
|
|
10
|
+
phone: string | null;
|
|
11
|
+
email: string | null;
|
|
12
|
+
}
|
|
5
13
|
export declare class OpenapiProfileBookingListItemRO {
|
|
6
14
|
orderId: number;
|
|
15
|
+
code: string | null;
|
|
7
16
|
questroom: OpenapiProfileBookingQuestroomRO;
|
|
8
17
|
date: string | null;
|
|
9
18
|
canceled: boolean;
|
|
@@ -11,4 +20,10 @@ export declare class OpenapiProfileBookingListItemRO {
|
|
|
11
20
|
children: number;
|
|
12
21
|
payed: number;
|
|
13
22
|
total: number;
|
|
23
|
+
toPay: number;
|
|
24
|
+
currency: ProfileCurrencyEnum;
|
|
25
|
+
source: SourceEnum;
|
|
26
|
+
confirmed: boolean;
|
|
27
|
+
createdAt: Date;
|
|
28
|
+
client: OpenapiProfileBookingClientRO | null;
|
|
14
29
|
}
|