@intelact/gnosa 0.1.0 → 0.1.2
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/lib/book/book.dto.d.ts +199 -0
- package/lib/book/book.dto.js +463 -0
- package/lib/book/book.dto.js.map +1 -0
- package/lib/book/book.model.d.ts +90 -0
- package/lib/book/book.model.js +262 -0
- package/lib/book/book.model.js.map +1 -0
- package/lib/discover/discover.dto.d.ts +38 -0
- package/lib/discover/discover.dto.js +99 -0
- package/lib/discover/discover.dto.js.map +1 -0
- package/lib/discover/discover.model.d.ts +30 -0
- package/lib/discover/discover.model.js +81 -0
- package/lib/discover/discover.model.js.map +1 -0
- package/lib/event/event.dto.d.ts +128 -0
- package/lib/event/event.dto.js +328 -0
- package/lib/event/event.dto.js.map +1 -0
- package/lib/event/event.enum.d.ts +16 -0
- package/lib/event/event.enum.js +22 -0
- package/lib/event/event.enum.js.map +1 -0
- package/lib/event/event.model.d.ts +78 -0
- package/lib/event/event.model.js +216 -0
- package/lib/event/event.model.js.map +1 -0
- package/lib/foundation/history.dto.d.ts +27 -0
- package/lib/foundation/history.dto.js +102 -0
- package/lib/foundation/history.dto.js.map +1 -0
- package/lib/foundation/history.model.d.ts +30 -0
- package/lib/foundation/history.model.js +82 -0
- package/lib/foundation/history.model.js.map +1 -0
- package/lib/foundation/partner.dto.d.ts +22 -0
- package/lib/foundation/partner.dto.js +92 -0
- package/lib/foundation/partner.dto.js.map +1 -0
- package/lib/foundation/partner.model.d.ts +30 -0
- package/lib/foundation/partner.model.js +82 -0
- package/lib/foundation/partner.model.js.map +1 -0
- package/lib/foundation/person.dto.d.ts +31 -0
- package/lib/foundation/person.dto.js +106 -0
- package/lib/foundation/person.dto.js.map +1 -0
- package/lib/foundation/person.model.d.ts +28 -0
- package/lib/foundation/person.model.js +80 -0
- package/lib/foundation/person.model.js.map +1 -0
- package/lib/general/language.dto.d.ts +7 -0
- package/lib/general/language.dto.js +26 -0
- package/lib/general/language.dto.js.map +1 -0
- package/lib/general/sort.dto.d.ts +7 -0
- package/lib/general/sort.dto.js +30 -0
- package/lib/general/sort.dto.js.map +1 -0
- package/lib/general/translations.d.ts +6 -0
- package/lib/general/translations.js +3 -0
- package/lib/general/translations.js.map +1 -0
- package/lib/index.d.ts +20 -0
- package/lib/index.js +20 -0
- package/lib/index.js.map +1 -1
- package/lib/magazine/magazine.dto.d.ts +132 -0
- package/lib/magazine/magazine.dto.js +314 -0
- package/lib/magazine/magazine.dto.js.map +1 -0
- package/lib/magazine/magazine.model.d.ts +88 -0
- package/lib/magazine/magazine.model.js +232 -0
- package/lib/magazine/magazine.model.js.map +1 -0
- package/lib/order/order.dto.d.ts +96 -0
- package/lib/order/order.dto.js +299 -0
- package/lib/order/order.dto.js.map +1 -0
- package/lib/order/order.enum.d.ts +10 -2
- package/lib/order/order.enum.js +12 -3
- package/lib/order/order.enum.js.map +1 -1
- package/lib/order/order.model.d.ts +168 -0
- package/lib/order/order.model.js +427 -0
- package/lib/order/order.model.js.map +1 -0
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/lib/utils/transformers.helper.d.ts +13 -0
- package/lib/utils/transformers.helper.js +33 -0
- package/lib/utils/transformers.helper.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,216 @@
|
|
|
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.Event = exports.EventTranslation = exports.EventSpeaker = exports.EventSpeakerTranslation = void 0;
|
|
13
|
+
const class_transformer_1 = require("class-transformer");
|
|
14
|
+
const event_enum_1 = require("./event.enum");
|
|
15
|
+
class EventSpeakerTranslation {
|
|
16
|
+
description;
|
|
17
|
+
constructor(props) {
|
|
18
|
+
Object.assign(this, props);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
exports.EventSpeakerTranslation = EventSpeakerTranslation;
|
|
22
|
+
__decorate([
|
|
23
|
+
(0, class_transformer_1.Expose)(),
|
|
24
|
+
__metadata("design:type", String)
|
|
25
|
+
], EventSpeakerTranslation.prototype, "description", void 0);
|
|
26
|
+
/**
|
|
27
|
+
* A speaker or artist of an event.
|
|
28
|
+
*/
|
|
29
|
+
class EventSpeaker {
|
|
30
|
+
/**
|
|
31
|
+
* Sent back when the event is saved, so the speaker keeps its image (the editor).
|
|
32
|
+
*/
|
|
33
|
+
slug;
|
|
34
|
+
name;
|
|
35
|
+
imageUrl;
|
|
36
|
+
/**
|
|
37
|
+
* The short description in the app language (the public page).
|
|
38
|
+
*/
|
|
39
|
+
description;
|
|
40
|
+
/**
|
|
41
|
+
* The short description in every language (the editor).
|
|
42
|
+
*/
|
|
43
|
+
translations;
|
|
44
|
+
constructor(props) {
|
|
45
|
+
Object.assign(this, props);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
exports.EventSpeaker = EventSpeaker;
|
|
49
|
+
__decorate([
|
|
50
|
+
(0, class_transformer_1.Expose)(),
|
|
51
|
+
__metadata("design:type", String)
|
|
52
|
+
], EventSpeaker.prototype, "slug", void 0);
|
|
53
|
+
__decorate([
|
|
54
|
+
(0, class_transformer_1.Expose)(),
|
|
55
|
+
__metadata("design:type", String)
|
|
56
|
+
], EventSpeaker.prototype, "name", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
(0, class_transformer_1.Expose)(),
|
|
59
|
+
__metadata("design:type", String)
|
|
60
|
+
], EventSpeaker.prototype, "imageUrl", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
(0, class_transformer_1.Expose)(),
|
|
63
|
+
__metadata("design:type", String)
|
|
64
|
+
], EventSpeaker.prototype, "description", void 0);
|
|
65
|
+
__decorate([
|
|
66
|
+
(0, class_transformer_1.Expose)(),
|
|
67
|
+
__metadata("design:type", Object)
|
|
68
|
+
], EventSpeaker.prototype, "translations", void 0);
|
|
69
|
+
class EventTranslation {
|
|
70
|
+
title;
|
|
71
|
+
shortDescription;
|
|
72
|
+
description;
|
|
73
|
+
locationName;
|
|
74
|
+
locationAddress;
|
|
75
|
+
seoTitle;
|
|
76
|
+
seoDescription;
|
|
77
|
+
constructor(props) {
|
|
78
|
+
Object.assign(this, props);
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
exports.EventTranslation = EventTranslation;
|
|
82
|
+
__decorate([
|
|
83
|
+
(0, class_transformer_1.Expose)(),
|
|
84
|
+
__metadata("design:type", String)
|
|
85
|
+
], EventTranslation.prototype, "title", void 0);
|
|
86
|
+
__decorate([
|
|
87
|
+
(0, class_transformer_1.Expose)(),
|
|
88
|
+
__metadata("design:type", String)
|
|
89
|
+
], EventTranslation.prototype, "shortDescription", void 0);
|
|
90
|
+
__decorate([
|
|
91
|
+
(0, class_transformer_1.Expose)(),
|
|
92
|
+
__metadata("design:type", String)
|
|
93
|
+
], EventTranslation.prototype, "description", void 0);
|
|
94
|
+
__decorate([
|
|
95
|
+
(0, class_transformer_1.Expose)(),
|
|
96
|
+
__metadata("design:type", String)
|
|
97
|
+
], EventTranslation.prototype, "locationName", void 0);
|
|
98
|
+
__decorate([
|
|
99
|
+
(0, class_transformer_1.Expose)(),
|
|
100
|
+
__metadata("design:type", String)
|
|
101
|
+
], EventTranslation.prototype, "locationAddress", void 0);
|
|
102
|
+
__decorate([
|
|
103
|
+
(0, class_transformer_1.Expose)(),
|
|
104
|
+
__metadata("design:type", String)
|
|
105
|
+
], EventTranslation.prototype, "seoTitle", void 0);
|
|
106
|
+
__decorate([
|
|
107
|
+
(0, class_transformer_1.Expose)(),
|
|
108
|
+
__metadata("design:type", String)
|
|
109
|
+
], EventTranslation.prototype, "seoDescription", void 0);
|
|
110
|
+
/**
|
|
111
|
+
* A Gnosa event. Lists carry the fields a row or a card shows with the title and location in the
|
|
112
|
+
* app language, the public page adds the descriptions and the speakers, and the editor carries every
|
|
113
|
+
* field with the localized ones in all three languages.
|
|
114
|
+
*/
|
|
115
|
+
class Event {
|
|
116
|
+
slug;
|
|
117
|
+
status;
|
|
118
|
+
imageUrl;
|
|
119
|
+
/**
|
|
120
|
+
* In UTC.
|
|
121
|
+
*/
|
|
122
|
+
startDate;
|
|
123
|
+
/**
|
|
124
|
+
* The IANA time zone the event takes place in.
|
|
125
|
+
*/
|
|
126
|
+
timezone;
|
|
127
|
+
/**
|
|
128
|
+
* The languages the event is held in.
|
|
129
|
+
*/
|
|
130
|
+
languages;
|
|
131
|
+
/**
|
|
132
|
+
* The localized fields in the app language (lists and the public page).
|
|
133
|
+
*/
|
|
134
|
+
title;
|
|
135
|
+
locationName;
|
|
136
|
+
locationAddress;
|
|
137
|
+
shortDescription;
|
|
138
|
+
description;
|
|
139
|
+
seoTitle;
|
|
140
|
+
seoDescription;
|
|
141
|
+
/**
|
|
142
|
+
* The speakers or artists in their order (the public page and the editor).
|
|
143
|
+
*/
|
|
144
|
+
speakers;
|
|
145
|
+
/**
|
|
146
|
+
* The localized fields in every language (the editor).
|
|
147
|
+
*/
|
|
148
|
+
translations;
|
|
149
|
+
constructor(props) {
|
|
150
|
+
Object.assign(this, props);
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
exports.Event = Event;
|
|
154
|
+
__decorate([
|
|
155
|
+
(0, class_transformer_1.Expose)(),
|
|
156
|
+
__metadata("design:type", String)
|
|
157
|
+
], Event.prototype, "slug", void 0);
|
|
158
|
+
__decorate([
|
|
159
|
+
(0, class_transformer_1.Expose)(),
|
|
160
|
+
__metadata("design:type", String)
|
|
161
|
+
], Event.prototype, "status", void 0);
|
|
162
|
+
__decorate([
|
|
163
|
+
(0, class_transformer_1.Expose)(),
|
|
164
|
+
__metadata("design:type", String)
|
|
165
|
+
], Event.prototype, "imageUrl", void 0);
|
|
166
|
+
__decorate([
|
|
167
|
+
(0, class_transformer_1.Expose)(),
|
|
168
|
+
(0, class_transformer_1.Type)(() => Date),
|
|
169
|
+
__metadata("design:type", Date)
|
|
170
|
+
], Event.prototype, "startDate", void 0);
|
|
171
|
+
__decorate([
|
|
172
|
+
(0, class_transformer_1.Expose)(),
|
|
173
|
+
__metadata("design:type", String)
|
|
174
|
+
], Event.prototype, "timezone", void 0);
|
|
175
|
+
__decorate([
|
|
176
|
+
(0, class_transformer_1.Expose)(),
|
|
177
|
+
__metadata("design:type", Array)
|
|
178
|
+
], Event.prototype, "languages", void 0);
|
|
179
|
+
__decorate([
|
|
180
|
+
(0, class_transformer_1.Expose)(),
|
|
181
|
+
__metadata("design:type", String)
|
|
182
|
+
], Event.prototype, "title", void 0);
|
|
183
|
+
__decorate([
|
|
184
|
+
(0, class_transformer_1.Expose)(),
|
|
185
|
+
__metadata("design:type", String)
|
|
186
|
+
], Event.prototype, "locationName", void 0);
|
|
187
|
+
__decorate([
|
|
188
|
+
(0, class_transformer_1.Expose)(),
|
|
189
|
+
__metadata("design:type", String)
|
|
190
|
+
], Event.prototype, "locationAddress", void 0);
|
|
191
|
+
__decorate([
|
|
192
|
+
(0, class_transformer_1.Expose)(),
|
|
193
|
+
__metadata("design:type", String)
|
|
194
|
+
], Event.prototype, "shortDescription", void 0);
|
|
195
|
+
__decorate([
|
|
196
|
+
(0, class_transformer_1.Expose)(),
|
|
197
|
+
__metadata("design:type", String)
|
|
198
|
+
], Event.prototype, "description", void 0);
|
|
199
|
+
__decorate([
|
|
200
|
+
(0, class_transformer_1.Expose)(),
|
|
201
|
+
__metadata("design:type", String)
|
|
202
|
+
], Event.prototype, "seoTitle", void 0);
|
|
203
|
+
__decorate([
|
|
204
|
+
(0, class_transformer_1.Expose)(),
|
|
205
|
+
__metadata("design:type", String)
|
|
206
|
+
], Event.prototype, "seoDescription", void 0);
|
|
207
|
+
__decorate([
|
|
208
|
+
(0, class_transformer_1.Expose)(),
|
|
209
|
+
(0, class_transformer_1.Type)(() => EventSpeaker),
|
|
210
|
+
__metadata("design:type", Array)
|
|
211
|
+
], Event.prototype, "speakers", void 0);
|
|
212
|
+
__decorate([
|
|
213
|
+
(0, class_transformer_1.Expose)(),
|
|
214
|
+
__metadata("design:type", Object)
|
|
215
|
+
], Event.prototype, "translations", void 0);
|
|
216
|
+
//# sourceMappingURL=event.model.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"event.model.js","sourceRoot":"","sources":["../../src/event/event.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,yDAAiD;AAIjD,6CAA2C;AAE3C,MAAa,uBAAuB;IAEnC,WAAW,CAAS;IAEpB,YAAY,KAAwC;QACnD,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;CACD;AAPD,0DAOC;AALA;IADC,IAAA,0BAAM,GAAE;;4DACW;AAOrB;;GAEG;AACH,MAAa,YAAY;IACxB;;OAEG;IAEH,IAAI,CAAU;IAGd,IAAI,CAAS;IAGb,QAAQ,CAAS;IAEjB;;OAEG;IAEH,WAAW,CAAU;IAErB;;OAEG;IAEH,YAAY,CAAyC;IAErD,YAAY,KAA6B;QACxC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;CACD;AA5BD,oCA4BC;AAvBA;IADC,IAAA,0BAAM,GAAE;;0CACK;AAGd;IADC,IAAA,0BAAM,GAAE;;0CACI;AAGb;IADC,IAAA,0BAAM,GAAE;;8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;IADC,IAAA,0BAAM,GAAE;;uCACQ;AAOjB;IAFC,IAAA,0BAAM,GAAE;IACR,IAAA,wBAAI,EAAC,GAAG,EAAE,CAAC,IAAI,CAAC;8BACN,IAAI;wCAAC;AAMhB;IADC,IAAA,0BAAM,GAAE;;uCACQ;AAMjB;IADC,IAAA,0BAAM,GAAE;;wCACa;AAMtB;IADC,IAAA,0BAAM,GAAE;;oCACM;AAGf;IADC,IAAA,0BAAM,GAAE;;2CACa;AAGtB;IADC,IAAA,0BAAM,GAAE;;8CACgB;AAGzB;IADC,IAAA,0BAAM,GAAE;;+CACiB;AAG1B;IADC,IAAA,0BAAM,GAAE;;0CACY;AAGrB;IADC,IAAA,0BAAM,GAAE;;uCACS;AAGlB;IADC,IAAA,0BAAM,GAAE;;6CACe;AAOxB;IAFC,IAAA,0BAAM,GAAE;IACR,IAAA,wBAAI,EAAC,GAAG,EAAE,CAAC,YAAY,CAAC;;uCACC;AAM1B;IADC,IAAA,0BAAM,GAAE;;2CACqC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
export declare class HistoryTranslationDto {
|
|
2
|
+
title: string;
|
|
3
|
+
description: string;
|
|
4
|
+
constructor(props?: Partial<HistoryTranslationDto>);
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* A history entry is never a draft, so the title and description are required in all three
|
|
8
|
+
* languages.
|
|
9
|
+
*/
|
|
10
|
+
export declare class HistoryTranslationsDto {
|
|
11
|
+
sq: HistoryTranslationDto;
|
|
12
|
+
en: HistoryTranslationDto;
|
|
13
|
+
mk: HistoryTranslationDto;
|
|
14
|
+
constructor(props?: Partial<HistoryTranslationsDto>);
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* The fields of a history entry, sent as a multipart form together with the image `file`, which is
|
|
18
|
+
* required when the entry is created.
|
|
19
|
+
*/
|
|
20
|
+
export declare class HistoryDto {
|
|
21
|
+
/**
|
|
22
|
+
* In UTC, as an ISO 8601 date.
|
|
23
|
+
*/
|
|
24
|
+
date: Date;
|
|
25
|
+
translations: HistoryTranslationsDto;
|
|
26
|
+
constructor(props?: Partial<HistoryDto>);
|
|
27
|
+
}
|
|
@@ -0,0 +1,102 @@
|
|
|
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.HistoryDto = exports.HistoryTranslationsDto = exports.HistoryTranslationDto = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
const common_1 = require("@intelact/common");
|
|
15
|
+
const class_transformer_1 = require("class-transformer");
|
|
16
|
+
const transformers_helper_1 = require("../utils/transformers.helper");
|
|
17
|
+
/**
|
|
18
|
+
* A missing date is asked for, and only a date that was given is called invalid.
|
|
19
|
+
*/
|
|
20
|
+
const dateMessage = (args) => args.value === undefined || args.value === null || args.value === ''
|
|
21
|
+
? 'gnosa.validation.date.required'
|
|
22
|
+
: 'gnosa.validation.date.invalid';
|
|
23
|
+
class HistoryTranslationDto {
|
|
24
|
+
title;
|
|
25
|
+
description;
|
|
26
|
+
constructor(props) {
|
|
27
|
+
Object.assign(this, props);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
exports.HistoryTranslationDto = HistoryTranslationDto;
|
|
31
|
+
__decorate([
|
|
32
|
+
(0, class_validator_1.IsNotEmpty)({ message: 'gnosa.validation.title.required' }),
|
|
33
|
+
(0, class_validator_1.IsString)({ message: 'gnosa.validation.title.required' }),
|
|
34
|
+
(0, class_validator_1.MaxLength)(255, { message: 'gnosa.validation.title.invalid' }),
|
|
35
|
+
(0, common_1.Trim)(),
|
|
36
|
+
__metadata("design:type", String)
|
|
37
|
+
], HistoryTranslationDto.prototype, "title", void 0);
|
|
38
|
+
__decorate([
|
|
39
|
+
(0, class_validator_1.IsNotEmpty)({ message: 'gnosa.validation.description.required' }),
|
|
40
|
+
(0, class_validator_1.IsString)({ message: 'gnosa.validation.description.required' }),
|
|
41
|
+
(0, class_validator_1.MaxLength)(10000, { message: 'gnosa.validation.description.invalid' }),
|
|
42
|
+
(0, common_1.Trim)(),
|
|
43
|
+
__metadata("design:type", String)
|
|
44
|
+
], HistoryTranslationDto.prototype, "description", void 0);
|
|
45
|
+
/**
|
|
46
|
+
* A history entry is never a draft, so the title and description are required in all three
|
|
47
|
+
* languages.
|
|
48
|
+
*/
|
|
49
|
+
class HistoryTranslationsDto {
|
|
50
|
+
sq;
|
|
51
|
+
en;
|
|
52
|
+
mk;
|
|
53
|
+
constructor(props) {
|
|
54
|
+
Object.assign(this, props);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
exports.HistoryTranslationsDto = HistoryTranslationsDto;
|
|
58
|
+
__decorate([
|
|
59
|
+
(0, class_validator_1.IsDefined)({ message: 'gnosa.validation.translations.sq' }),
|
|
60
|
+
(0, class_validator_1.ValidateNested)({ message: 'gnosa.validation.translations.sq' }),
|
|
61
|
+
(0, class_transformer_1.Type)(() => HistoryTranslationDto),
|
|
62
|
+
__metadata("design:type", HistoryTranslationDto)
|
|
63
|
+
], HistoryTranslationsDto.prototype, "sq", void 0);
|
|
64
|
+
__decorate([
|
|
65
|
+
(0, class_validator_1.IsDefined)({ message: 'gnosa.validation.translations.en' }),
|
|
66
|
+
(0, class_validator_1.ValidateNested)({ message: 'gnosa.validation.translations.en' }),
|
|
67
|
+
(0, class_transformer_1.Type)(() => HistoryTranslationDto),
|
|
68
|
+
__metadata("design:type", HistoryTranslationDto)
|
|
69
|
+
], HistoryTranslationsDto.prototype, "en", void 0);
|
|
70
|
+
__decorate([
|
|
71
|
+
(0, class_validator_1.IsDefined)({ message: 'gnosa.validation.translations.mk' }),
|
|
72
|
+
(0, class_validator_1.ValidateNested)({ message: 'gnosa.validation.translations.mk' }),
|
|
73
|
+
(0, class_transformer_1.Type)(() => HistoryTranslationDto),
|
|
74
|
+
__metadata("design:type", HistoryTranslationDto)
|
|
75
|
+
], HistoryTranslationsDto.prototype, "mk", void 0);
|
|
76
|
+
/**
|
|
77
|
+
* The fields of a history entry, sent as a multipart form together with the image `file`, which is
|
|
78
|
+
* required when the entry is created.
|
|
79
|
+
*/
|
|
80
|
+
class HistoryDto {
|
|
81
|
+
/**
|
|
82
|
+
* In UTC, as an ISO 8601 date.
|
|
83
|
+
*/
|
|
84
|
+
date;
|
|
85
|
+
translations;
|
|
86
|
+
constructor(props) {
|
|
87
|
+
Object.assign(this, props);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
exports.HistoryDto = HistoryDto;
|
|
91
|
+
__decorate([
|
|
92
|
+
(0, class_validator_1.IsDate)({ message: dateMessage }),
|
|
93
|
+
(0, transformers_helper_1.ToUtcDate)(),
|
|
94
|
+
__metadata("design:type", Date)
|
|
95
|
+
], HistoryDto.prototype, "date", void 0);
|
|
96
|
+
__decorate([
|
|
97
|
+
(0, class_validator_1.IsDefined)({ message: 'gnosa.validation.translations.required' }),
|
|
98
|
+
(0, class_validator_1.ValidateNested)({ message: 'gnosa.validation.translations.required' }),
|
|
99
|
+
(0, class_transformer_1.Type)(() => HistoryTranslationsDto),
|
|
100
|
+
__metadata("design:type", HistoryTranslationsDto)
|
|
101
|
+
], HistoryDto.prototype, "translations", void 0);
|
|
102
|
+
//# sourceMapp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B;gDAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Translations } from '../general/translations';
|
|
2
|
+
export declare class HistoryTranslation {
|
|
3
|
+
title: string;
|
|
4
|
+
description: string;
|
|
5
|
+
constructor(props?: Partial<HistoryTranslation>);
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* An entry of the foundation's history timeline.
|
|
9
|
+
*/
|
|
10
|
+
export declare class History {
|
|
11
|
+
slug: string;
|
|
12
|
+
imageUrl: string;
|
|
13
|
+
/**
|
|
14
|
+
* In UTC.
|
|
15
|
+
*/
|
|
16
|
+
date: Date;
|
|
17
|
+
/**
|
|
18
|
+
* The title in the app language (lists and the public page).
|
|
19
|
+
*/
|
|
20
|
+
title?: string;
|
|
21
|
+
/**
|
|
22
|
+
* The description in the app language (lists and the public page).
|
|
23
|
+
*/
|
|
24
|
+
description?: string;
|
|
25
|
+
/**
|
|
26
|
+
* The title and description in every language (the editor).
|
|
27
|
+
*/
|
|
28
|
+
translations?: Translations<HistoryTranslation>;
|
|
29
|
+
constructor(props?: Partial<History>);
|
|
30
|
+
}
|
|
@@ -0,0 +1,82 @@
|
|
|
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.History = exports.HistoryTranslation = void 0;
|
|
13
|
+
const class_transformer_1 = require("class-transformer");
|
|
14
|
+
class HistoryTranslation {
|
|
15
|
+
title;
|
|
16
|
+
description;
|
|
17
|
+
constructor(props) {
|
|
18
|
+
Object.assign(this, props);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
exports.HistoryTranslation = HistoryTranslation;
|
|
22
|
+
__decorate([
|
|
23
|
+
(0, class_transformer_1.Expose)(),
|
|
24
|
+
__metadata("design:type", String)
|
|
25
|
+
], HistoryTranslation.prototype, "title", void 0);
|
|
26
|
+
__decorate([
|
|
27
|
+
(0, class_transformer_1.Expose)(),
|
|
28
|
+
__metadata("design:type", String)
|
|
29
|
+
], HistoryTranslation.prototype, "description", void 0);
|
|
30
|
+
/**
|
|
31
|
+
* An entry of the foundation's history timeline.
|
|
32
|
+
*/
|
|
33
|
+
class History {
|
|
34
|
+
slug;
|
|
35
|
+
imageUrl;
|
|
36
|
+
/**
|
|
37
|
+
* In UTC.
|
|
38
|
+
*/
|
|
39
|
+
date;
|
|
40
|
+
/**
|
|
41
|
+
* The title in the app language (lists and the public page).
|
|
42
|
+
*/
|
|
43
|
+
title;
|
|
44
|
+
/**
|
|
45
|
+
* The description in the app language (lists and the public page).
|
|
46
|
+
*/
|
|
47
|
+
description;
|
|
48
|
+
/**
|
|
49
|
+
* The title and description in every language (the editor).
|
|
50
|
+
*/
|
|
51
|
+
translations;
|
|
52
|
+
constructor(props) {
|
|
53
|
+
Object.assign(this, props);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
exports.History = History;
|
|
57
|
+
__decorate([
|
|
58
|
+
(0, class_transformer_1.Expose)(),
|
|
59
|
+
__metadata("design:type", String)
|
|
60
|
+
], History.prototype, "slug", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
(0, class_transformer_1.Expose)(),
|
|
63
|
+
__metadata("design:type", String)
|
|
64
|
+
], History.prototype, "imageUrl", void 0);
|
|
65
|
+
__decorate([
|
|
66
|
+
(0, class_transformer_1.Expose)(),
|
|
67
|
+
(0, class_transformer_1.Type)(() => Date),
|
|
68
|
+
__metadata("design:type", Date)
|
|
69
|
+
], History.prototype, "date", void 0);
|
|
70
|
+
__decorate([
|
|
71
|
+
(0, class_transformer_1.Expose)(),
|
|
72
|
+
__metadata("design:type", String)
|
|
73
|
+
], History.prototype, "title", void 0);
|
|
74
|
+
__decorate([
|
|
75
|
+
(0, class_transformer_1.Expose)(),
|
|
76
|
+
__metadata("design:type", String)
|
|
77
|
+
], History.prototype, "description", void 0);
|
|
78
|
+
__decorate([
|
|
79
|
+
(0, class_transformer_1.Expose)(),
|
|
80
|
+
__metadata("design:type", Object)
|
|
81
|
+
], History.prototype, "translations", void 0);
|
|
82
|
+
//# sourceMappingURL=history.model.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"history.model.js","sourceRoot":"","sources":["../../src/foundation/history.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,yDAAiD;AAIjD,MAAa,kBAAkB;IAE9B,KAAK,CAAS;IAGd,WAAW,CAAS;IAEpB,YAAY,KAAmC;QAC9C,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;CACD;AAVD,gDAUC;AARA;IADC,IAAA,0BAAM,GAAE;;iDACK;AAGd;IADC,IAAA,0BAAM,GAAE;;uDACW;AAOrB;;GAEG;AACH,MAAa,OAAO;IAEnB,IAAI,CAAS;IAGb,QAAQ,CAAS;IAEjB;;OAEG;IAGH,IAAI,CAAO;IAEX;;OAEG;IAEH,KAAK,CAAU;IAEf;;OAEG;IAEH,WAAW,CAAU;IAErB;;OAEG;IAEH,YAAY,CAAoC;IAEhD,YAAY,KAAwB;QACnC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;CACD;AAnCD,0BAmCC;AAjCA;IADC,IAAA,0BAAM,GAAE;;qCACI;AAGb;IADC,IAAA,0BAAM,GAAE;;yCACQ;AAOjB;IAFC,IAAA,0BAAM,GAAE;IACR,IAAA,wBAAI,EAAC,GAAG,EAAE,CAAC,IAAI,CAAC;8BACX,IAAI;qCAAC;AAMX;IADC,IAAA,0BAAM,GAAE;;sCACM;AAMf;IADC,IAAA,0BAAM,GAAE;;4CACY;AAMrB;IADC,IAAA,0BAAM,GAAE;;6CACuC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export declare class PartnerTranslationDto {
|
|
2
|
+
description: string;
|
|
3
|
+
constructor(props?: Partial<PartnerTranslationDto>);
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* A partner is never a draft, so the description is required in all three languages.
|
|
7
|
+
*/
|
|
8
|
+
export declare class PartnerTranslationsDto {
|
|
9
|
+
sq: PartnerTranslationDto;
|
|
10
|
+
en: PartnerTranslationDto;
|
|
11
|
+
mk: PartnerTranslationDto;
|
|
12
|
+
constructor(props?: Partial<PartnerTranslationsDto>);
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* The fields of a partner, sent as a multipart form together with the `logo` file.
|
|
16
|
+
*/
|
|
17
|
+
export declare class PartnerDto {
|
|
18
|
+
name: string;
|
|
19
|
+
externalUrl: string;
|
|
20
|
+
translations: PartnerTranslationsDto;
|
|
21
|
+
constructor(props?: Partial<PartnerDto>);
|
|
22
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
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.PartnerDto = exports.PartnerTranslationsDto = exports.PartnerTranslationDto = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
const common_1 = require("@intelact/common");
|
|
15
|
+
const class_transformer_1 = require("class-transformer");
|
|
16
|
+
class PartnerTranslationDto {
|
|
17
|
+
description;
|
|
18
|
+
constructor(props) {
|
|
19
|
+
Object.assign(this, props);
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
exports.PartnerTranslationDto = PartnerTranslationDto;
|
|
23
|
+
__decorate([
|
|
24
|
+
(0, class_validator_1.IsNotEmpty)({ message: 'gnosa.validation.description.required' }),
|
|
25
|
+
(0, class_validator_1.IsString)({ message: 'gnosa.validation.description.required' }),
|
|
26
|
+
(0, class_validator_1.MaxLength)(10000, { message: 'gnosa.validation.description.invalid' }),
|
|
27
|
+
(0, common_1.Trim)(),
|
|
28
|
+
__metadata("design:type", String)
|
|
29
|
+
], PartnerTranslationDto.prototype, "description", void 0);
|
|
30
|
+
/**
|
|
31
|
+
* A partner is never a draft, so the description is required in all three languages.
|
|
32
|
+
*/
|
|
33
|
+
class PartnerTranslationsDto {
|
|
34
|
+
sq;
|
|
35
|
+
en;
|
|
36
|
+
mk;
|
|
37
|
+
constructor(props) {
|
|
38
|
+
Object.assign(this, props);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
exports.PartnerTranslationsDto = PartnerTranslationsDto;
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, class_validator_1.IsDefined)({ message: 'gnosa.validation.translations.sq' }),
|
|
44
|
+
(0, class_validator_1.ValidateNested)({ message: 'gnosa.validation.translations.sq' }),
|
|
45
|
+
(0, class_transformer_1.Type)(() => PartnerTranslationDto),
|
|
46
|
+
__metadata("design:type", PartnerTranslationDto)
|
|
47
|
+
], PartnerTranslationsDto.prototype, "sq", void 0);
|
|
48
|
+
__decorate([
|
|
49
|
+
(0, class_validator_1.IsDefined)({ message: 'gnosa.validation.translations.en' }),
|
|
50
|
+
(0, class_validator_1.ValidateNested)({ message: 'gnosa.validation.translations.en' }),
|
|
51
|
+
(0, class_transformer_1.Type)(() => PartnerTranslationDto),
|
|
52
|
+
__metadata("design:type", PartnerTranslationDto)
|
|
53
|
+
], PartnerTranslationsDto.prototype, "en", void 0);
|
|
54
|
+
__decorate([
|
|
55
|
+
(0, class_validator_1.IsDefined)({ message: 'gnosa.validation.translations.mk' }),
|
|
56
|
+
(0, class_validator_1.ValidateNested)({ message: 'gnosa.validation.translations.mk' }),
|
|
57
|
+
(0, class_transformer_1.Type)(() => PartnerTranslationDto),
|
|
58
|
+
__metadata("design:type", PartnerTranslationDto)
|
|
59
|
+
], PartnerTranslationsDto.prototype, "mk", void 0);
|
|
60
|
+
/**
|
|
61
|
+
* The fields of a partner, sent as a multipart form together with the `logo` file.
|
|
62
|
+
*/
|
|
63
|
+
class PartnerDto {
|
|
64
|
+
name;
|
|
65
|
+
externalUrl;
|
|
66
|
+
translations;
|
|
67
|
+
constructor(props) {
|
|
68
|
+
Object.assign(this, props);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
exports.PartnerDto = PartnerDto;
|
|
72
|
+
__decorate([
|
|
73
|
+
(0, class_validator_1.IsNotEmpty)({ message: 'gnosa.validation.name.required' }),
|
|
74
|
+
(0, class_validator_1.IsString)({ message: 'gnosa.validation.name.required' }),
|
|
75
|
+
(0, class_validator_1.MaxLength)(255, { message: 'gnosa.validation.name.invalid' }),
|
|
76
|
+
(0, common_1.Trim)(),
|
|
77
|
+
__metadata("design:type", String)
|
|
78
|
+
], PartnerDto.prototype, "name", void 0);
|
|
79
|
+
__decorate([
|
|
80
|
+
(0, class_validator_1.IsNotEmpty)({ message: 'gnosa.validation.url.invalid' }),
|
|
81
|
+
(0, class_validator_1.IsUrl)({ protocols: ['http', 'https'], require_protocol: true }, { message: 'gnosa.validation.url.invalid' }),
|
|
82
|
+
(0, class_validator_1.MaxLength)(1024, { message: 'gnosa.validation.url.invalid' }),
|
|
83
|
+
(0, common_1.Trim)(),
|
|
84
|
+
__metadata("design:type", String)
|
|
85
|
+
], PartnerDto.prototype, "externalUrl", void 0);
|
|
86
|
+
__decorate([
|
|
87
|
+
(0, class_validator_1.IsDefined)({ message: 'gnosa.validation.translations.required' }),
|
|
88
|
+
(0, class_validator_1.ValidateNested)({ message: 'gnosa.validation.translations.required' }),
|
|
89
|
+
(0, class_transformer_1.Type)(() => PartnerTranslationsDto),
|
|
90
|
+
__metadata("design:type", PartnerTranslationsDto)
|
|
91
|
+
], PartnerDto.prototype, "translations", void 0);
|
|
92
|
+
//# sourceMappingURL=partner.dto.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"partner.dto.js","sourceRoot":"","sources":["../../src/foundation/partner.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAoG;AACpG,6CAAwC;AACxC,yDAAyC;AAEzC,MAAa,qBAAqB;IAKjC,WAAW,CAAS;IAEpB,YAAY,KAAsC;QACjD,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;CACD;AAVD,sDAUC;AALA;IAJC,IAAA,4BAAU,EAAC,EAAE,OAAO,EAAE,uCAAuC,EAAE,CAAC;IAChE,IAAA,0BAAQ,EAAC,EAAE,OAAO,EAAE,uCAAuC,EAAE,CAAC;IAC9D,IAAA,2BAAS,EAAC,KAAK,EAAE,EAAE,OAAO,EAAE,sCAAsC,EAAE,CAAC;IACrE,IAAA,aAAI,GAAE;;0DACa;AAOrB;;GAEG;AACH,MAAa,sBAAsB;IAIlC,EAA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;IAC5D,IAAA,aAAI,GAAE;;wCACM;AAMb;IAJC,IAAA,4BAAU,EAAC,EAAE,OAAO,EAAE,8BAA8B,EAAE,CAAC;IACvD,IAAA,uBAAK,EAAC,EAAE,SAAS,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,gBAAgB,EAAE,IAAI,EAAE,EAAE,EAAE,OAAO,EAAE,8BAA8B,EAAE,CAAC;IAC5G,IAAA,2BAAS,EAAC,IAAI,EAAE,EAAE,OAAO,EAAE,8BAA8B,EAAE,CAAC;IAC5D,IAAA,aAAI,GAAE;;+CACa;AAKpB;IAHC,IAAA,2BAAS,EAAC,EAAE,OAAO,EAAE,wCAAwC,EAAE,CAAC;IAChE,IAAA,gCAAc,EAAC,EAAE,OAAO,EAAE,wCAAwC,EAAE,CAAC;IACrE,IAAA,wBAAI,EAAC,GAAG,EAAE,CAAC,sBAAsB,CAAC;8BACrB,sBAAsB;gDAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Translations } from '../general/translations';
|
|
2
|
+
export declare class PartnerTranslation {
|
|
3
|
+
description: string;
|
|
4
|
+
constructor(props?: Partial<PartnerTranslation>);
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* A partner institution of the foundation.
|
|
8
|
+
*/
|
|
9
|
+
export declare class Partner {
|
|
10
|
+
slug: string;
|
|
11
|
+
logoUrl: string;
|
|
12
|
+
name: string;
|
|
13
|
+
/**
|
|
14
|
+
* The partner's website.
|
|
15
|
+
*/
|
|
16
|
+
externalUrl: string;
|
|
17
|
+
/**
|
|
18
|
+
* Position in the partners list.
|
|
19
|
+
*/
|
|
20
|
+
sort: number;
|
|
21
|
+
/**
|
|
22
|
+
* The description in the app language (lists and the public page).
|
|
23
|
+
*/
|
|
24
|
+
description?: string;
|
|
25
|
+
/**
|
|
26
|
+
* The description in every language (the editor).
|
|
27
|
+
*/
|
|
28
|
+
translations?: Translations<PartnerTranslation>;
|
|
29
|
+
constructor(props?: Partial<Partner>);
|
|
30
|
+
}
|