@flusys/nestjs-event-manager 7.0.2 → 8.0.0-beta.1
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/adapters/event-manager.adapter.d.ts +2 -2
- package/adapters/index.d.ts +1 -1
- package/config/index.d.ts +3 -3
- package/controllers/event.controller.d.ts +3 -3
- package/controllers/index.d.ts +1 -1
- package/docs/event-manager-swagger.config.d.ts +2 -2
- package/docs/index.d.ts +1 -1
- package/dtos/calendar-query.dto.d.ts +1 -1
- package/dtos/event.dto.d.ts +1 -1
- package/dtos/index.d.ts +3 -3
- package/entities/event-with-company.entity.d.ts +1 -1
- package/entities/index.d.ts +8 -8
- package/fesm/477.js +1798 -0
- package/fesm/833.js +840 -0
- package/fesm/adapters/index.js +884 -1
- package/fesm/config/index.js +87 -3
- package/fesm/controllers/index.js +365 -1
- package/fesm/docs/index.js +155 -2
- package/fesm/dtos/index.js +720 -3
- package/fesm/entities/index.js +350 -11
- package/fesm/index.js +121 -9
- package/fesm/interfaces/index.js +16 -2
- package/fesm/modules/index.js +13 -1
- package/fesm/runtime.js +85 -0
- package/fesm/services/index.js +272 -4
- package/index.d.ts +9 -9
- package/interfaces/event-manager-module.interface.d.ts +3 -3
- package/interfaces/event.interface.d.ts +1 -1
- package/interfaces/index.d.ts +2 -2
- package/modules/event-manager.module.d.ts +2 -2
- package/modules/index.d.ts +1 -1
- package/package.json +29 -39
- package/services/event-manager-config.service.d.ts +3 -3
- package/services/event-manager-datasource.provider.d.ts +3 -3
- package/services/event-manager-helper.service.d.ts +3 -3
- package/services/event.service.d.ts +7 -7
- package/services/index.d.ts +4 -4
- package/cjs/adapters/event-manager.adapter.js +0 -65
- package/cjs/adapters/event-manager.adapter.spec.js +0 -104
- package/cjs/adapters/index.js +0 -18
- package/cjs/config/event-actions.js +0 -31
- package/cjs/config/event-manager.constants.js +0 -13
- package/cjs/config/index.js +0 -20
- package/cjs/config/message-keys.js +0 -27
- package/cjs/controllers/event.controller.js +0 -190
- package/cjs/controllers/event.controller.spec.js +0 -156
- package/cjs/controllers/index.js +0 -18
- package/cjs/docs/event-manager-swagger.config.js +0 -125
- package/cjs/docs/event-manager-swagger.config.spec.js +0 -65
- package/cjs/docs/index.js +0 -21
- package/cjs/dtos/calendar-query.dto.js +0 -212
- package/cjs/dtos/event-participant.dto.js +0 -181
- package/cjs/dtos/event.dto.js +0 -343
- package/cjs/dtos/index.js +0 -20
- package/cjs/entities/event-participant.entity.js +0 -89
- package/cjs/entities/event-with-company.entity.js +0 -56
- package/cjs/entities/event.entity.js +0 -156
- package/cjs/entities/index.js +0 -55
- package/cjs/entities/index.spec.js +0 -18
- package/cjs/index.js +0 -27
- package/cjs/interfaces/event-manager-module.interface.js +0 -4
- package/cjs/interfaces/event.interface.js +0 -4
- package/cjs/interfaces/index.js +0 -19
- package/cjs/modules/event-manager.module.js +0 -132
- package/cjs/modules/event-manager.module.spec.js +0 -146
- package/cjs/modules/index.js +0 -18
- package/cjs/services/event-manager-config.service.js +0 -76
- package/cjs/services/event-manager-config.service.spec.js +0 -111
- package/cjs/services/event-manager-datasource.provider.js +0 -84
- package/cjs/services/event-manager-datasource.provider.spec.js +0 -198
- package/cjs/services/event-manager-helper.service.js +0 -235
- package/cjs/services/event-manager-helper.service.spec.js +0 -327
- package/cjs/services/event.service.js +0 -481
- package/cjs/services/event.service.spec.js +0 -929
- package/cjs/services/index.js +0 -21
- package/fesm/adapters/event-manager.adapter.js +0 -55
- package/fesm/adapters/event-manager.adapter.spec.js +0 -100
- package/fesm/config/event-actions.js +0 -10
- package/fesm/config/event-manager.constants.js +0 -3
- package/fesm/config/message-keys.js +0 -9
- package/fesm/controllers/event.controller.js +0 -180
- package/fesm/controllers/event.controller.spec.js +0 -152
- package/fesm/docs/event-manager-swagger.config.js +0 -118
- package/fesm/docs/event-manager-swagger.config.spec.js +0 -61
- package/fesm/dtos/calendar-query.dto.js +0 -194
- package/fesm/dtos/event-participant.dto.js +0 -157
- package/fesm/dtos/event.dto.js +0 -322
- package/fesm/entities/event-participant.entity.js +0 -79
- package/fesm/entities/event-with-company.entity.js +0 -46
- package/fesm/entities/event.entity.js +0 -146
- package/fesm/entities/index.spec.js +0 -14
- package/fesm/interfaces/event-manager-module.interface.js +0 -3
- package/fesm/interfaces/event.interface.js +0 -1
- package/fesm/modules/event-manager.module.js +0 -122
- package/fesm/modules/event-manager.module.spec.js +0 -142
- package/fesm/services/event-manager-config.service.js +0 -66
- package/fesm/services/event-manager-config.service.spec.js +0 -107
- package/fesm/services/event-manager-datasource.provider.js +0 -74
- package/fesm/services/event-manager-datasource.provider.spec.js +0 -194
- package/fesm/services/event-manager-helper.service.js +0 -225
- package/fesm/services/event-manager-helper.service.spec.js +0 -323
- package/fesm/services/event.service.js +0 -471
- package/fesm/services/event.service.spec.js +0 -925
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import { eventManagerSwaggerConfig } from './event-manager-swagger.config';
|
|
2
|
-
describe('eventManagerSwaggerConfig', ()=>{
|
|
3
|
-
it('should default to company feature enabled and single-database mode when no config is given', ()=>{
|
|
4
|
-
const config = eventManagerSwaggerConfig();
|
|
5
|
-
expect(config.title).toBe('Event Manager API');
|
|
6
|
-
expect(config.path).toBe('api/docs/event-manager');
|
|
7
|
-
expect(config.bearerAuth).toBe(true);
|
|
8
|
-
expect(config.excludeSchemaProperties).toBeUndefined();
|
|
9
|
-
expect(config.description).not.toContain('Multi-Tenant Mode');
|
|
10
|
-
});
|
|
11
|
-
it('should exclude companyId schema properties when the company feature is disabled', ()=>{
|
|
12
|
-
const config = eventManagerSwaggerConfig({
|
|
13
|
-
enableCompanyFeature: false
|
|
14
|
-
});
|
|
15
|
-
expect(config.excludeSchemaProperties).toEqual([
|
|
16
|
-
{
|
|
17
|
-
schemaName: 'EventResponseDto',
|
|
18
|
-
properties: [
|
|
19
|
-
'companyId'
|
|
20
|
-
]
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
schemaName: 'CalendarEventResponseDto',
|
|
24
|
-
properties: [
|
|
25
|
-
'companyId'
|
|
26
|
-
]
|
|
27
|
-
}
|
|
28
|
-
]);
|
|
29
|
-
});
|
|
30
|
-
it('should not exclude any schema properties when the company feature is enabled', ()=>{
|
|
31
|
-
const config = eventManagerSwaggerConfig({
|
|
32
|
-
enableCompanyFeature: true
|
|
33
|
-
});
|
|
34
|
-
expect(config.excludeSchemaProperties).toBeUndefined();
|
|
35
|
-
});
|
|
36
|
-
it('should describe company-scoped events and multi-tenant support only when the company feature is enabled', ()=>{
|
|
37
|
-
const withCompany = eventManagerSwaggerConfig({
|
|
38
|
-
enableCompanyFeature: true
|
|
39
|
-
});
|
|
40
|
-
const withoutCompany = eventManagerSwaggerConfig({
|
|
41
|
-
enableCompanyFeature: false
|
|
42
|
-
});
|
|
43
|
-
expect(withCompany.description).toContain('Company-scoped events');
|
|
44
|
-
expect(withCompany.description).toContain('Company isolation');
|
|
45
|
-
expect(withCompany.description).toContain('## Multi-Tenant Support');
|
|
46
|
-
expect(withCompany.description).toContain('and multi-tenant capabilities');
|
|
47
|
-
expect(withoutCompany.description).not.toContain('Company-scoped events');
|
|
48
|
-
expect(withoutCompany.description).not.toContain('Company isolation');
|
|
49
|
-
expect(withoutCompany.description).not.toContain('## Multi-Tenant Support');
|
|
50
|
-
});
|
|
51
|
-
it('should mention multi-tenant mode in the description only for multi-tenant database mode', ()=>{
|
|
52
|
-
const multiTenant = eventManagerSwaggerConfig({
|
|
53
|
-
databaseMode: 'multi-tenant'
|
|
54
|
-
});
|
|
55
|
-
const single = eventManagerSwaggerConfig({
|
|
56
|
-
databaseMode: 'single'
|
|
57
|
-
});
|
|
58
|
-
expect(multiTenant.description).toContain('Multi-Tenant Mode');
|
|
59
|
-
expect(single.description).not.toContain('Multi-Tenant Mode');
|
|
60
|
-
});
|
|
61
|
-
});
|
|
@@ -1,194 +0,0 @@
|
|
|
1
|
-
function _define_property(obj, key, value) {
|
|
2
|
-
if (key in obj) {
|
|
3
|
-
Object.defineProperty(obj, key, {
|
|
4
|
-
value: value,
|
|
5
|
-
enumerable: true,
|
|
6
|
-
configurable: true,
|
|
7
|
-
writable: true
|
|
8
|
-
});
|
|
9
|
-
} else {
|
|
10
|
-
obj[key] = value;
|
|
11
|
-
}
|
|
12
|
-
return obj;
|
|
13
|
-
}
|
|
14
|
-
function _ts_decorate(decorators, target, key, desc) {
|
|
15
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
16
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
17
|
-
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;
|
|
18
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
19
|
-
}
|
|
20
|
-
function _ts_metadata(k, v) {
|
|
21
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
22
|
-
}
|
|
23
|
-
import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';
|
|
24
|
-
import { Expose, Type } from 'class-transformer';
|
|
25
|
-
import { IsBoolean, IsNotEmpty, IsOptional, IsString, IsUUID, Matches } from 'class-validator';
|
|
26
|
-
import { EventParticipantResponseDto } from './event-participant.dto';
|
|
27
|
-
export class CalendarQueryDto {
|
|
28
|
-
constructor(){
|
|
29
|
-
_define_property(this, "startDate", void 0);
|
|
30
|
-
_define_property(this, "endDate", void 0);
|
|
31
|
-
_define_property(this, "includeParticipants", void 0);
|
|
32
|
-
_define_property(this, "userId", void 0);
|
|
33
|
-
_define_property(this, "activeOnly", void 0);
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
_ts_decorate([
|
|
37
|
-
ApiProperty({
|
|
38
|
-
description: 'Start date for calendar range (YYYY-MM-DD)',
|
|
39
|
-
example: '2024-01-01'
|
|
40
|
-
}),
|
|
41
|
-
IsNotEmpty(),
|
|
42
|
-
IsString(),
|
|
43
|
-
Matches(/^\d{4}-\d{2}-\d{2}$/, {
|
|
44
|
-
message: 'startDate must be in YYYY-MM-DD format'
|
|
45
|
-
}),
|
|
46
|
-
_ts_metadata("design:type", String)
|
|
47
|
-
], CalendarQueryDto.prototype, "startDate", void 0);
|
|
48
|
-
_ts_decorate([
|
|
49
|
-
ApiProperty({
|
|
50
|
-
description: 'End date for calendar range (YYYY-MM-DD)',
|
|
51
|
-
example: '2024-01-31'
|
|
52
|
-
}),
|
|
53
|
-
IsNotEmpty(),
|
|
54
|
-
IsString(),
|
|
55
|
-
Matches(/^\d{4}-\d{2}-\d{2}$/, {
|
|
56
|
-
message: 'endDate must be in YYYY-MM-DD format'
|
|
57
|
-
}),
|
|
58
|
-
_ts_metadata("design:type", String)
|
|
59
|
-
], CalendarQueryDto.prototype, "endDate", void 0);
|
|
60
|
-
_ts_decorate([
|
|
61
|
-
ApiPropertyOptional({
|
|
62
|
-
description: 'Include participant details',
|
|
63
|
-
default: false
|
|
64
|
-
}),
|
|
65
|
-
IsOptional(),
|
|
66
|
-
IsBoolean(),
|
|
67
|
-
_ts_metadata("design:type", Boolean)
|
|
68
|
-
], CalendarQueryDto.prototype, "includeParticipants", void 0);
|
|
69
|
-
_ts_decorate([
|
|
70
|
-
ApiPropertyOptional({
|
|
71
|
-
description: 'Filter by specific user ID'
|
|
72
|
-
}),
|
|
73
|
-
IsOptional(),
|
|
74
|
-
IsUUID(),
|
|
75
|
-
_ts_metadata("design:type", String)
|
|
76
|
-
], CalendarQueryDto.prototype, "userId", void 0);
|
|
77
|
-
_ts_decorate([
|
|
78
|
-
ApiPropertyOptional({
|
|
79
|
-
description: 'Include only active events',
|
|
80
|
-
default: true
|
|
81
|
-
}),
|
|
82
|
-
IsOptional(),
|
|
83
|
-
IsBoolean(),
|
|
84
|
-
_ts_metadata("design:type", Boolean)
|
|
85
|
-
], CalendarQueryDto.prototype, "activeOnly", void 0);
|
|
86
|
-
export class CalendarEventResponseDto {
|
|
87
|
-
constructor(){
|
|
88
|
-
_define_property(this, "id", void 0);
|
|
89
|
-
_define_property(this, "title", void 0);
|
|
90
|
-
_define_property(this, "description", void 0);
|
|
91
|
-
_define_property(this, "eventDate", void 0);
|
|
92
|
-
_define_property(this, "startTime", void 0);
|
|
93
|
-
_define_property(this, "endTime", void 0);
|
|
94
|
-
_define_property(this, "isAllDay", void 0);
|
|
95
|
-
_define_property(this, "recurrenceType", void 0);
|
|
96
|
-
_define_property(this, "recurrenceEndDate", void 0);
|
|
97
|
-
_define_property(this, "weekDays", void 0);
|
|
98
|
-
_define_property(this, "color", void 0);
|
|
99
|
-
_define_property(this, "meetingLink", void 0);
|
|
100
|
-
_define_property(this, "isActive", void 0);
|
|
101
|
-
_define_property(this, "originalEventId", void 0);
|
|
102
|
-
_define_property(this, "isRecurrenceInstance", void 0);
|
|
103
|
-
_define_property(this, "participants", void 0);
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
_ts_decorate([
|
|
107
|
-
Expose(),
|
|
108
|
-
ApiProperty(),
|
|
109
|
-
_ts_metadata("design:type", String)
|
|
110
|
-
], CalendarEventResponseDto.prototype, "id", void 0);
|
|
111
|
-
_ts_decorate([
|
|
112
|
-
Expose(),
|
|
113
|
-
ApiProperty(),
|
|
114
|
-
_ts_metadata("design:type", String)
|
|
115
|
-
], CalendarEventResponseDto.prototype, "title", void 0);
|
|
116
|
-
_ts_decorate([
|
|
117
|
-
Expose(),
|
|
118
|
-
ApiPropertyOptional(),
|
|
119
|
-
_ts_metadata("design:type", Object)
|
|
120
|
-
], CalendarEventResponseDto.prototype, "description", void 0);
|
|
121
|
-
_ts_decorate([
|
|
122
|
-
Expose(),
|
|
123
|
-
ApiProperty(),
|
|
124
|
-
_ts_metadata("design:type", String)
|
|
125
|
-
], CalendarEventResponseDto.prototype, "eventDate", void 0);
|
|
126
|
-
_ts_decorate([
|
|
127
|
-
Expose(),
|
|
128
|
-
ApiProperty(),
|
|
129
|
-
_ts_metadata("design:type", String)
|
|
130
|
-
], CalendarEventResponseDto.prototype, "startTime", void 0);
|
|
131
|
-
_ts_decorate([
|
|
132
|
-
Expose(),
|
|
133
|
-
ApiProperty(),
|
|
134
|
-
_ts_metadata("design:type", String)
|
|
135
|
-
], CalendarEventResponseDto.prototype, "endTime", void 0);
|
|
136
|
-
_ts_decorate([
|
|
137
|
-
Expose(),
|
|
138
|
-
ApiProperty(),
|
|
139
|
-
_ts_metadata("design:type", Boolean)
|
|
140
|
-
], CalendarEventResponseDto.prototype, "isAllDay", void 0);
|
|
141
|
-
_ts_decorate([
|
|
142
|
-
Expose(),
|
|
143
|
-
ApiProperty(),
|
|
144
|
-
_ts_metadata("design:type", String)
|
|
145
|
-
], CalendarEventResponseDto.prototype, "recurrenceType", void 0);
|
|
146
|
-
_ts_decorate([
|
|
147
|
-
Expose(),
|
|
148
|
-
ApiPropertyOptional(),
|
|
149
|
-
_ts_metadata("design:type", Object)
|
|
150
|
-
], CalendarEventResponseDto.prototype, "recurrenceEndDate", void 0);
|
|
151
|
-
_ts_decorate([
|
|
152
|
-
Expose(),
|
|
153
|
-
ApiPropertyOptional({
|
|
154
|
-
type: [
|
|
155
|
-
String
|
|
156
|
-
]
|
|
157
|
-
}),
|
|
158
|
-
_ts_metadata("design:type", Object)
|
|
159
|
-
], CalendarEventResponseDto.prototype, "weekDays", void 0);
|
|
160
|
-
_ts_decorate([
|
|
161
|
-
Expose(),
|
|
162
|
-
ApiProperty(),
|
|
163
|
-
_ts_metadata("design:type", String)
|
|
164
|
-
], CalendarEventResponseDto.prototype, "color", void 0);
|
|
165
|
-
_ts_decorate([
|
|
166
|
-
Expose(),
|
|
167
|
-
ApiPropertyOptional(),
|
|
168
|
-
_ts_metadata("design:type", Object)
|
|
169
|
-
], CalendarEventResponseDto.prototype, "meetingLink", void 0);
|
|
170
|
-
_ts_decorate([
|
|
171
|
-
Expose(),
|
|
172
|
-
ApiProperty(),
|
|
173
|
-
_ts_metadata("design:type", Boolean)
|
|
174
|
-
], CalendarEventResponseDto.prototype, "isActive", void 0);
|
|
175
|
-
_ts_decorate([
|
|
176
|
-
Expose(),
|
|
177
|
-
ApiPropertyOptional(),
|
|
178
|
-
_ts_metadata("design:type", String)
|
|
179
|
-
], CalendarEventResponseDto.prototype, "originalEventId", void 0);
|
|
180
|
-
_ts_decorate([
|
|
181
|
-
Expose(),
|
|
182
|
-
ApiPropertyOptional(),
|
|
183
|
-
_ts_metadata("design:type", Boolean)
|
|
184
|
-
], CalendarEventResponseDto.prototype, "isRecurrenceInstance", void 0);
|
|
185
|
-
_ts_decorate([
|
|
186
|
-
Expose(),
|
|
187
|
-
ApiPropertyOptional({
|
|
188
|
-
type: ()=>[
|
|
189
|
-
EventParticipantResponseDto
|
|
190
|
-
]
|
|
191
|
-
}),
|
|
192
|
-
Type(()=>EventParticipantResponseDto),
|
|
193
|
-
_ts_metadata("design:type", Array)
|
|
194
|
-
], CalendarEventResponseDto.prototype, "participants", void 0);
|
|
@@ -1,157 +0,0 @@
|
|
|
1
|
-
function _define_property(obj, key, value) {
|
|
2
|
-
if (key in obj) {
|
|
3
|
-
Object.defineProperty(obj, key, {
|
|
4
|
-
value: value,
|
|
5
|
-
enumerable: true,
|
|
6
|
-
configurable: true,
|
|
7
|
-
writable: true
|
|
8
|
-
});
|
|
9
|
-
} else {
|
|
10
|
-
obj[key] = value;
|
|
11
|
-
}
|
|
12
|
-
return obj;
|
|
13
|
-
}
|
|
14
|
-
function _ts_decorate(decorators, target, key, desc) {
|
|
15
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
16
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
17
|
-
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;
|
|
18
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
19
|
-
}
|
|
20
|
-
function _ts_metadata(k, v) {
|
|
21
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
22
|
-
}
|
|
23
|
-
import { ParticipantStatus } from '@flusys/nestjs-shared/enums';
|
|
24
|
-
import { ApiProperty, ApiPropertyOptional, PartialType } from '@nestjs/swagger';
|
|
25
|
-
import { Expose } from 'class-transformer';
|
|
26
|
-
import { IsBoolean, IsEnum, IsNotEmpty, IsOptional, IsUUID } from 'class-validator';
|
|
27
|
-
export class CreateEventParticipantDto {
|
|
28
|
-
constructor(){
|
|
29
|
-
_define_property(this, "eventId", void 0);
|
|
30
|
-
_define_property(this, "userId", void 0);
|
|
31
|
-
_define_property(this, "status", void 0);
|
|
32
|
-
_define_property(this, "isOrganizer", void 0);
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
_ts_decorate([
|
|
36
|
-
ApiProperty({
|
|
37
|
-
description: 'Event ID',
|
|
38
|
-
example: 'f2e9c8d0-7a2a-11eb-9439-0242ac130002'
|
|
39
|
-
}),
|
|
40
|
-
IsNotEmpty(),
|
|
41
|
-
IsUUID(),
|
|
42
|
-
_ts_metadata("design:type", String)
|
|
43
|
-
], CreateEventParticipantDto.prototype, "eventId", void 0);
|
|
44
|
-
_ts_decorate([
|
|
45
|
-
ApiProperty({
|
|
46
|
-
description: 'User ID',
|
|
47
|
-
example: 'a1b2c3d4-e5f6-7890-abcd-ef1234567890'
|
|
48
|
-
}),
|
|
49
|
-
IsNotEmpty(),
|
|
50
|
-
IsUUID(),
|
|
51
|
-
_ts_metadata("design:type", String)
|
|
52
|
-
], CreateEventParticipantDto.prototype, "userId", void 0);
|
|
53
|
-
_ts_decorate([
|
|
54
|
-
ApiPropertyOptional({
|
|
55
|
-
description: 'Participation status',
|
|
56
|
-
enum: ParticipantStatus,
|
|
57
|
-
default: ParticipantStatus.PENDING
|
|
58
|
-
}),
|
|
59
|
-
IsOptional(),
|
|
60
|
-
IsEnum(ParticipantStatus),
|
|
61
|
-
_ts_metadata("design:type", typeof ParticipantStatus === "undefined" ? Object : ParticipantStatus)
|
|
62
|
-
], CreateEventParticipantDto.prototype, "status", void 0);
|
|
63
|
-
_ts_decorate([
|
|
64
|
-
ApiPropertyOptional({
|
|
65
|
-
description: 'Is the organizer of the event',
|
|
66
|
-
default: false
|
|
67
|
-
}),
|
|
68
|
-
IsOptional(),
|
|
69
|
-
IsBoolean(),
|
|
70
|
-
_ts_metadata("design:type", Boolean)
|
|
71
|
-
], CreateEventParticipantDto.prototype, "isOrganizer", void 0);
|
|
72
|
-
export class UpdateEventParticipantDto extends PartialType(CreateEventParticipantDto) {
|
|
73
|
-
constructor(...args){
|
|
74
|
-
super(...args), _define_property(this, "id", void 0);
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
_ts_decorate([
|
|
78
|
-
ApiProperty({
|
|
79
|
-
description: 'Event Participant ID',
|
|
80
|
-
example: 'f2e9c8d0-7a2a-11eb-9439-0242ac130002'
|
|
81
|
-
}),
|
|
82
|
-
IsUUID(),
|
|
83
|
-
IsNotEmpty(),
|
|
84
|
-
_ts_metadata("design:type", String)
|
|
85
|
-
], UpdateEventParticipantDto.prototype, "id", void 0);
|
|
86
|
-
export class EventParticipantResponseDto {
|
|
87
|
-
constructor(){
|
|
88
|
-
_define_property(this, "id", void 0);
|
|
89
|
-
_define_property(this, "eventId", void 0);
|
|
90
|
-
_define_property(this, "userId", void 0);
|
|
91
|
-
_define_property(this, "status", void 0);
|
|
92
|
-
_define_property(this, "isOrganizer", void 0);
|
|
93
|
-
_define_property(this, "createdAt", void 0);
|
|
94
|
-
_define_property(this, "updatedAt", void 0);
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
_ts_decorate([
|
|
98
|
-
Expose(),
|
|
99
|
-
ApiProperty(),
|
|
100
|
-
_ts_metadata("design:type", String)
|
|
101
|
-
], EventParticipantResponseDto.prototype, "id", void 0);
|
|
102
|
-
_ts_decorate([
|
|
103
|
-
Expose(),
|
|
104
|
-
ApiProperty(),
|
|
105
|
-
_ts_metadata("design:type", String)
|
|
106
|
-
], EventParticipantResponseDto.prototype, "eventId", void 0);
|
|
107
|
-
_ts_decorate([
|
|
108
|
-
Expose(),
|
|
109
|
-
ApiProperty(),
|
|
110
|
-
_ts_metadata("design:type", String)
|
|
111
|
-
], EventParticipantResponseDto.prototype, "userId", void 0);
|
|
112
|
-
_ts_decorate([
|
|
113
|
-
Expose(),
|
|
114
|
-
ApiProperty({
|
|
115
|
-
enum: ParticipantStatus
|
|
116
|
-
}),
|
|
117
|
-
_ts_metadata("design:type", String)
|
|
118
|
-
], EventParticipantResponseDto.prototype, "status", void 0);
|
|
119
|
-
_ts_decorate([
|
|
120
|
-
Expose(),
|
|
121
|
-
ApiProperty(),
|
|
122
|
-
_ts_metadata("design:type", Boolean)
|
|
123
|
-
], EventParticipantResponseDto.prototype, "isOrganizer", void 0);
|
|
124
|
-
_ts_decorate([
|
|
125
|
-
Expose(),
|
|
126
|
-
ApiProperty(),
|
|
127
|
-
_ts_metadata("design:type", typeof Date === "undefined" ? Object : Date)
|
|
128
|
-
], EventParticipantResponseDto.prototype, "createdAt", void 0);
|
|
129
|
-
_ts_decorate([
|
|
130
|
-
Expose(),
|
|
131
|
-
ApiProperty(),
|
|
132
|
-
_ts_metadata("design:type", typeof Date === "undefined" ? Object : Date)
|
|
133
|
-
], EventParticipantResponseDto.prototype, "updatedAt", void 0);
|
|
134
|
-
export class UpdateParticipantStatusDto {
|
|
135
|
-
constructor(){
|
|
136
|
-
_define_property(this, "id", void 0);
|
|
137
|
-
_define_property(this, "status", void 0);
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
_ts_decorate([
|
|
141
|
-
ApiProperty({
|
|
142
|
-
description: 'Event Participant ID',
|
|
143
|
-
example: 'f2e9c8d0-7a2a-11eb-9439-0242ac130002'
|
|
144
|
-
}),
|
|
145
|
-
IsUUID(),
|
|
146
|
-
IsNotEmpty(),
|
|
147
|
-
_ts_metadata("design:type", String)
|
|
148
|
-
], UpdateParticipantStatusDto.prototype, "id", void 0);
|
|
149
|
-
_ts_decorate([
|
|
150
|
-
ApiProperty({
|
|
151
|
-
description: 'New participation status',
|
|
152
|
-
enum: ParticipantStatus
|
|
153
|
-
}),
|
|
154
|
-
IsNotEmpty(),
|
|
155
|
-
IsEnum(ParticipantStatus),
|
|
156
|
-
_ts_metadata("design:type", typeof ParticipantStatus === "undefined" ? Object : ParticipantStatus)
|
|
157
|
-
], UpdateParticipantStatusDto.prototype, "status", void 0);
|