@taiger-common/model 1.0.47 → 1.0.48
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/cjs/model/Program.js +302 -6
- package/dist/cjs/model/User.js +16 -7
- package/dist/esm/model/Program.js +297 -1
- package/dist/esm/model/User.js +9 -1
- package/dist/types/model/Program.d.ts +279 -1
- package/dist/types/model/User.d.ts +7 -0
- package/dist/umd/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,12 +1,308 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var _a;
|
|
2
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.programSchema = exports.programModule = exports.DIFFICULTY_KEYS = exports.PROGRAM_SUBJECT_KEYS = void 0;
|
|
4
|
+
exports.programSchema = exports.programModule = exports.DIFFICULTY_KEYS = exports.PROGRAM_SUBJECT_KEYS = exports.SCHOOL_TYPES = exports.SchoolType = exports.SCHOOL_TAGS = exports.DIFFICULTY = exports.SemesterType = exports.PROGRAM_SUBJECTS = void 0;
|
|
4
5
|
var mongoose_1 = require("mongoose");
|
|
5
|
-
var core_1 = require("@taiger-common/core");
|
|
6
6
|
var ObjectId = mongoose_1.Schema.Types.ObjectId;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
exports.PROGRAM_SUBJECTS = {
|
|
8
|
+
LING: {
|
|
9
|
+
label: 'Linguistics',
|
|
10
|
+
category: 'AH'
|
|
11
|
+
},
|
|
12
|
+
MUS: {
|
|
13
|
+
label: 'Music',
|
|
14
|
+
category: 'AH'
|
|
15
|
+
},
|
|
16
|
+
THEO: {
|
|
17
|
+
label: 'Theology, Divinity and Religious Studies',
|
|
18
|
+
category: 'AH'
|
|
19
|
+
},
|
|
20
|
+
ARCH: {
|
|
21
|
+
label: 'Archaeology',
|
|
22
|
+
category: 'AH'
|
|
23
|
+
},
|
|
24
|
+
'ARCH-BE': {
|
|
25
|
+
label: 'Architecture and Built Environment',
|
|
26
|
+
category: 'AH'
|
|
27
|
+
},
|
|
28
|
+
'ART-DES': {
|
|
29
|
+
label: 'Art and Design',
|
|
30
|
+
category: 'AH'
|
|
31
|
+
},
|
|
32
|
+
CLAH: {
|
|
33
|
+
label: 'Classics and Ancient History',
|
|
34
|
+
category: 'AH'
|
|
35
|
+
},
|
|
36
|
+
ELL: {
|
|
37
|
+
label: 'English Language and Literature',
|
|
38
|
+
category: 'AH'
|
|
39
|
+
},
|
|
40
|
+
HIST: {
|
|
41
|
+
label: 'History',
|
|
42
|
+
category: 'AH'
|
|
43
|
+
},
|
|
44
|
+
ARTH: {
|
|
45
|
+
label: 'Art History',
|
|
46
|
+
category: 'AH'
|
|
47
|
+
},
|
|
48
|
+
'MOD-LANG': {
|
|
49
|
+
label: 'Modern Languages',
|
|
50
|
+
category: 'AH'
|
|
51
|
+
},
|
|
52
|
+
'PERF-ART': {
|
|
53
|
+
label: 'Performing Arts',
|
|
54
|
+
category: 'AH'
|
|
55
|
+
},
|
|
56
|
+
PHIL: {
|
|
57
|
+
label: 'Philosophy',
|
|
58
|
+
category: 'AH'
|
|
59
|
+
},
|
|
60
|
+
'CHEM-ENG': {
|
|
61
|
+
label: 'Engineering - Chemical',
|
|
62
|
+
category: 'ET'
|
|
63
|
+
},
|
|
64
|
+
'CIV-STR-ENG': {
|
|
65
|
+
label: 'Engineering - Civil and Structural',
|
|
66
|
+
category: 'ET'
|
|
67
|
+
},
|
|
68
|
+
CSIS: {
|
|
69
|
+
label: 'Computer Science and Information Systems',
|
|
70
|
+
category: 'ET'
|
|
71
|
+
},
|
|
72
|
+
'DS-AI': {
|
|
73
|
+
label: 'Data Science and Artificial Intelligence',
|
|
74
|
+
category: 'ET'
|
|
75
|
+
},
|
|
76
|
+
'ELEC-ENG': {
|
|
77
|
+
label: 'Engineering - Electrical and Electronic',
|
|
78
|
+
category: 'ET'
|
|
79
|
+
},
|
|
80
|
+
'PETRO-ENG': {
|
|
81
|
+
label: 'Engineering - Petroleum',
|
|
82
|
+
category: 'ET'
|
|
83
|
+
},
|
|
84
|
+
'MECH-ENG': {
|
|
85
|
+
label: 'Engineering - Mechanical',
|
|
86
|
+
category: 'ET'
|
|
87
|
+
},
|
|
88
|
+
'MIN-MIN-ENG': {
|
|
89
|
+
label: 'Engineering - Mineral and Mining',
|
|
90
|
+
category: 'ET'
|
|
91
|
+
},
|
|
92
|
+
'AG-FOR': {
|
|
93
|
+
label: 'Agriculture and Forestry',
|
|
94
|
+
category: 'LSM'
|
|
95
|
+
},
|
|
96
|
+
'ANA-PHYS': {
|
|
97
|
+
label: 'Anatomy and Physiology',
|
|
98
|
+
category: 'LSM'
|
|
99
|
+
},
|
|
100
|
+
'BIO-SCI': {
|
|
101
|
+
label: 'Biological Sciences',
|
|
102
|
+
category: 'LSM'
|
|
103
|
+
},
|
|
104
|
+
DENT: {
|
|
105
|
+
label: 'Dentistry',
|
|
106
|
+
category: 'LSM'
|
|
107
|
+
},
|
|
108
|
+
MED: {
|
|
109
|
+
label: 'Medicine',
|
|
110
|
+
category: 'LSM'
|
|
111
|
+
},
|
|
112
|
+
NURS: {
|
|
113
|
+
label: 'Nursing',
|
|
114
|
+
category: 'LSM'
|
|
115
|
+
},
|
|
116
|
+
PHARM: {
|
|
117
|
+
label: 'Pharmacy and Pharmacology',
|
|
118
|
+
category: 'LSM'
|
|
119
|
+
},
|
|
120
|
+
PSYCH: {
|
|
121
|
+
label: 'Psychology',
|
|
122
|
+
category: 'LSM'
|
|
123
|
+
},
|
|
124
|
+
'VET-SCI': {
|
|
125
|
+
label: 'Veterinary Science',
|
|
126
|
+
category: 'LSM'
|
|
127
|
+
},
|
|
128
|
+
CHEM: {
|
|
129
|
+
label: 'Chemistry',
|
|
130
|
+
category: 'NS'
|
|
131
|
+
},
|
|
132
|
+
'EAR-MAR-SCI': {
|
|
133
|
+
label: 'Earth and Marine Sciences',
|
|
134
|
+
category: 'NS'
|
|
135
|
+
},
|
|
136
|
+
'ENV-SCI': {
|
|
137
|
+
label: 'Environmental Sciences',
|
|
138
|
+
category: 'NS'
|
|
139
|
+
},
|
|
140
|
+
GEO: {
|
|
141
|
+
label: 'Geography',
|
|
142
|
+
category: 'NS'
|
|
143
|
+
},
|
|
144
|
+
GEOL: {
|
|
145
|
+
label: 'Geology',
|
|
146
|
+
category: 'NS'
|
|
147
|
+
},
|
|
148
|
+
GEOPH: {
|
|
149
|
+
label: 'Geophysics',
|
|
150
|
+
category: 'NS'
|
|
151
|
+
},
|
|
152
|
+
'MAT-SCI': {
|
|
153
|
+
label: 'Materials Sciences',
|
|
154
|
+
category: 'NS'
|
|
155
|
+
},
|
|
156
|
+
MATH: {
|
|
157
|
+
label: 'Mathematics',
|
|
158
|
+
category: 'NS'
|
|
159
|
+
},
|
|
160
|
+
'PHYS-ASTRO': {
|
|
161
|
+
label: 'Physics and Astronomy',
|
|
162
|
+
category: 'NS'
|
|
163
|
+
},
|
|
164
|
+
'ACC-FIN': {
|
|
165
|
+
label: 'Accounting and Finance',
|
|
166
|
+
category: 'SSM'
|
|
167
|
+
},
|
|
168
|
+
ANTH: {
|
|
169
|
+
label: 'Anthropology',
|
|
170
|
+
category: 'SSM'
|
|
171
|
+
},
|
|
172
|
+
'BUS-MGMT': {
|
|
173
|
+
label: 'Business and Management Studies',
|
|
174
|
+
category: 'SSM'
|
|
175
|
+
},
|
|
176
|
+
'COMM-MEDIA': {
|
|
177
|
+
label: 'Communication and Media Studies',
|
|
178
|
+
category: 'SSM'
|
|
179
|
+
},
|
|
180
|
+
'DEV-STUD': {
|
|
181
|
+
label: 'Development Studies',
|
|
182
|
+
category: 'SSM'
|
|
183
|
+
},
|
|
184
|
+
ECON: {
|
|
185
|
+
label: 'Economics and Econometrics',
|
|
186
|
+
category: 'SSM'
|
|
187
|
+
},
|
|
188
|
+
'EDU-TRAIN': {
|
|
189
|
+
label: 'Education and Training',
|
|
190
|
+
category: 'SSM'
|
|
191
|
+
},
|
|
192
|
+
'HOSP-MGMT': {
|
|
193
|
+
label: 'Hospitality and Leisure Management',
|
|
194
|
+
category: 'SSM'
|
|
195
|
+
},
|
|
196
|
+
LAW: {
|
|
197
|
+
label: 'Law and Legal Studies',
|
|
198
|
+
category: 'SSM'
|
|
199
|
+
},
|
|
200
|
+
'LIB-INFO': {
|
|
201
|
+
label: 'Library and Information Management',
|
|
202
|
+
category: 'SSM'
|
|
203
|
+
},
|
|
204
|
+
MKT: {
|
|
205
|
+
label: 'Marketing',
|
|
206
|
+
category: 'SSM'
|
|
207
|
+
},
|
|
208
|
+
POL: {
|
|
209
|
+
label: 'Politics',
|
|
210
|
+
category: 'SSM'
|
|
211
|
+
},
|
|
212
|
+
'SOC-POL': {
|
|
213
|
+
label: 'Social Policy and Administration',
|
|
214
|
+
category: 'SSM'
|
|
215
|
+
},
|
|
216
|
+
SOC: {
|
|
217
|
+
label: 'Sociology',
|
|
218
|
+
category: 'SSM'
|
|
219
|
+
},
|
|
220
|
+
SPORT: {
|
|
221
|
+
label: 'Sports-Related Subjects',
|
|
222
|
+
category: 'SSM'
|
|
223
|
+
},
|
|
224
|
+
'STAT-OR': {
|
|
225
|
+
label: 'Statistics and Operational Research',
|
|
226
|
+
category: 'SSM'
|
|
227
|
+
}
|
|
228
|
+
};
|
|
229
|
+
var SemesterType;
|
|
230
|
+
(function (SemesterType) {
|
|
231
|
+
SemesterType["SummerSemester"] = "SS";
|
|
232
|
+
SemesterType["WinterSemester"] = "WS";
|
|
233
|
+
SemesterType["Rolling"] = "Rolling";
|
|
234
|
+
})(SemesterType = exports.SemesterType || (exports.SemesterType = {}));
|
|
235
|
+
var Category;
|
|
236
|
+
(function (Category) {
|
|
237
|
+
Category["TU9"] = "TU9";
|
|
238
|
+
Category["U15"] = "U15";
|
|
239
|
+
Category["EUROTECH"] = "EUROTECH";
|
|
240
|
+
Category["GERMAN_ELITE"] = "GERMAN_ELITE";
|
|
241
|
+
Category["TOP50"] = "TOP50";
|
|
242
|
+
Category["TIME"] = "TIME";
|
|
243
|
+
Category["TOP100"] = "TOP100";
|
|
244
|
+
Category["TOP150"] = "TOP150";
|
|
245
|
+
Category["TOP250"] = "TOP250";
|
|
246
|
+
Category["TOP500"] = "TOP500";
|
|
247
|
+
})(Category || (Category = {}));
|
|
248
|
+
exports.DIFFICULTY = {
|
|
249
|
+
EASY: 'EASY',
|
|
250
|
+
HARD: 'HARD'
|
|
251
|
+
};
|
|
252
|
+
exports.SCHOOL_TAGS = (_a = {},
|
|
253
|
+
_a[Category.U15] = {
|
|
254
|
+
label: 'U15',
|
|
255
|
+
category: 'U15'
|
|
256
|
+
},
|
|
257
|
+
_a[Category.TU9] = {
|
|
258
|
+
label: 'TU9 German Universities of Technology',
|
|
259
|
+
category: 'TU9'
|
|
260
|
+
},
|
|
261
|
+
_a[Category.EUROTECH] = {
|
|
262
|
+
label: 'EuroTech Universities Alliance',
|
|
263
|
+
category: 'EUROTECH'
|
|
264
|
+
},
|
|
265
|
+
_a[Category.GERMAN_ELITE] = {
|
|
266
|
+
label: 'German Excellence Initiative',
|
|
267
|
+
category: 'GERMAN_ELITE'
|
|
268
|
+
},
|
|
269
|
+
_a[Category.TIME] = {
|
|
270
|
+
label: 'Top International Managers in Engineering',
|
|
271
|
+
category: 'TIME'
|
|
272
|
+
},
|
|
273
|
+
_a[Category.TOP50] = {
|
|
274
|
+
label: 'QS Top 50 Universities',
|
|
275
|
+
category: 'TOP50'
|
|
276
|
+
},
|
|
277
|
+
_a[Category.TOP100] = {
|
|
278
|
+
label: 'QS Top 100 Universities',
|
|
279
|
+
category: 'TOP100'
|
|
280
|
+
},
|
|
281
|
+
_a[Category.TOP150] = {
|
|
282
|
+
label: 'QS Top 150 Universities',
|
|
283
|
+
category: 'TOP150'
|
|
284
|
+
},
|
|
285
|
+
_a[Category.TOP250] = {
|
|
286
|
+
label: 'QS Top 250 Universities',
|
|
287
|
+
category: 'TOP150'
|
|
288
|
+
},
|
|
289
|
+
_a[Category.TOP500] = {
|
|
290
|
+
label: 'QS Top 500 Universities',
|
|
291
|
+
category: 'TOP500'
|
|
292
|
+
},
|
|
293
|
+
_a);
|
|
294
|
+
var SchoolType;
|
|
295
|
+
(function (SchoolType) {
|
|
296
|
+
SchoolType["University"] = "University";
|
|
297
|
+
SchoolType["University_of_Applied_Sciences"] = "University_of_Applied_Sciences";
|
|
298
|
+
})(SchoolType = exports.SchoolType || (exports.SchoolType = {}));
|
|
299
|
+
exports.SCHOOL_TYPES = [
|
|
300
|
+
SchoolType.University,
|
|
301
|
+
SchoolType.University_of_Applied_Sciences
|
|
302
|
+
];
|
|
303
|
+
var SCHOOL_TAG_KEYS = Object.keys(exports.SCHOOL_TAGS);
|
|
304
|
+
exports.PROGRAM_SUBJECT_KEYS = Object.keys(exports.PROGRAM_SUBJECTS);
|
|
305
|
+
exports.DIFFICULTY_KEYS = Object.keys(exports.DIFFICULTY);
|
|
10
306
|
exports.programModule = {
|
|
11
307
|
isArchiv: Boolean,
|
|
12
308
|
school: {
|
|
@@ -230,7 +526,7 @@ exports.programModule = {
|
|
|
230
526
|
},
|
|
231
527
|
schoolType: {
|
|
232
528
|
type: String,
|
|
233
|
-
enum:
|
|
529
|
+
enum: exports.SCHOOL_TYPES
|
|
234
530
|
},
|
|
235
531
|
isEssayConsultantNeeded: {
|
|
236
532
|
type: Boolean,
|
package/dist/cjs/model/User.js
CHANGED
|
@@ -3,11 +3,20 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.DocumentStatusType = void 0;
|
|
6
7
|
var mongoose_1 = require("mongoose");
|
|
7
8
|
var validator_1 = __importDefault(require("validator"));
|
|
8
|
-
var core_1 = require("@taiger-common/core");
|
|
9
9
|
var users_1 = require("../constants/users");
|
|
10
10
|
var Program_1 = require("./Program");
|
|
11
|
+
// --- Interfaces for frontend/backend type reference ---
|
|
12
|
+
var DocumentStatusType;
|
|
13
|
+
(function (DocumentStatusType) {
|
|
14
|
+
DocumentStatusType["Uploaded"] = "uploaded";
|
|
15
|
+
DocumentStatusType["Missing"] = "missing";
|
|
16
|
+
DocumentStatusType["Accepted"] = "accepted";
|
|
17
|
+
DocumentStatusType["Rejected"] = "rejected";
|
|
18
|
+
DocumentStatusType["NotNeeded"] = "notneeded";
|
|
19
|
+
})(DocumentStatusType = exports.DocumentStatusType || (exports.DocumentStatusType = {}));
|
|
11
20
|
var ManagerType = {
|
|
12
21
|
Agent: 'Agent',
|
|
13
22
|
Editor: 'Editor',
|
|
@@ -119,8 +128,8 @@ var userSchema = new mongoose_1.Schema({
|
|
|
119
128
|
},
|
|
120
129
|
status: {
|
|
121
130
|
type: String,
|
|
122
|
-
enum: Object.values(
|
|
123
|
-
default:
|
|
131
|
+
enum: Object.values(DocumentStatusType),
|
|
132
|
+
default: DocumentStatusType.Missing
|
|
124
133
|
},
|
|
125
134
|
file_category: {
|
|
126
135
|
type: String,
|
|
@@ -140,8 +149,8 @@ var userSchema = new mongoose_1.Schema({
|
|
|
140
149
|
},
|
|
141
150
|
status: {
|
|
142
151
|
type: String,
|
|
143
|
-
enum: Object.values(
|
|
144
|
-
default:
|
|
152
|
+
enum: Object.values(DocumentStatusType),
|
|
153
|
+
default: DocumentStatusType.Missing
|
|
145
154
|
},
|
|
146
155
|
file_category: {
|
|
147
156
|
type: String,
|
|
@@ -391,8 +400,8 @@ var studentSchema = new mongoose_1.Schema({
|
|
|
391
400
|
},
|
|
392
401
|
status: {
|
|
393
402
|
type: String,
|
|
394
|
-
enum: Object.values(
|
|
395
|
-
default:
|
|
403
|
+
enum: Object.values(DocumentStatusType),
|
|
404
|
+
default: DocumentStatusType.Missing
|
|
396
405
|
},
|
|
397
406
|
required: {
|
|
398
407
|
type: Boolean,
|
|
@@ -1,6 +1,302 @@
|
|
|
1
|
+
var _a;
|
|
1
2
|
import { Schema } from 'mongoose';
|
|
2
|
-
import { DIFFICULTY, PROGRAM_SUBJECTS, SCHOOL_TAGS, SCHOOL_TYPES } from '@taiger-common/core';
|
|
3
3
|
var ObjectId = Schema.Types.ObjectId;
|
|
4
|
+
export var PROGRAM_SUBJECTS = {
|
|
5
|
+
LING: {
|
|
6
|
+
label: 'Linguistics',
|
|
7
|
+
category: 'AH'
|
|
8
|
+
},
|
|
9
|
+
MUS: {
|
|
10
|
+
label: 'Music',
|
|
11
|
+
category: 'AH'
|
|
12
|
+
},
|
|
13
|
+
THEO: {
|
|
14
|
+
label: 'Theology, Divinity and Religious Studies',
|
|
15
|
+
category: 'AH'
|
|
16
|
+
},
|
|
17
|
+
ARCH: {
|
|
18
|
+
label: 'Archaeology',
|
|
19
|
+
category: 'AH'
|
|
20
|
+
},
|
|
21
|
+
'ARCH-BE': {
|
|
22
|
+
label: 'Architecture and Built Environment',
|
|
23
|
+
category: 'AH'
|
|
24
|
+
},
|
|
25
|
+
'ART-DES': {
|
|
26
|
+
label: 'Art and Design',
|
|
27
|
+
category: 'AH'
|
|
28
|
+
},
|
|
29
|
+
CLAH: {
|
|
30
|
+
label: 'Classics and Ancient History',
|
|
31
|
+
category: 'AH'
|
|
32
|
+
},
|
|
33
|
+
ELL: {
|
|
34
|
+
label: 'English Language and Literature',
|
|
35
|
+
category: 'AH'
|
|
36
|
+
},
|
|
37
|
+
HIST: {
|
|
38
|
+
label: 'History',
|
|
39
|
+
category: 'AH'
|
|
40
|
+
},
|
|
41
|
+
ARTH: {
|
|
42
|
+
label: 'Art History',
|
|
43
|
+
category: 'AH'
|
|
44
|
+
},
|
|
45
|
+
'MOD-LANG': {
|
|
46
|
+
label: 'Modern Languages',
|
|
47
|
+
category: 'AH'
|
|
48
|
+
},
|
|
49
|
+
'PERF-ART': {
|
|
50
|
+
label: 'Performing Arts',
|
|
51
|
+
category: 'AH'
|
|
52
|
+
},
|
|
53
|
+
PHIL: {
|
|
54
|
+
label: 'Philosophy',
|
|
55
|
+
category: 'AH'
|
|
56
|
+
},
|
|
57
|
+
'CHEM-ENG': {
|
|
58
|
+
label: 'Engineering - Chemical',
|
|
59
|
+
category: 'ET'
|
|
60
|
+
},
|
|
61
|
+
'CIV-STR-ENG': {
|
|
62
|
+
label: 'Engineering - Civil and Structural',
|
|
63
|
+
category: 'ET'
|
|
64
|
+
},
|
|
65
|
+
CSIS: {
|
|
66
|
+
label: 'Computer Science and Information Systems',
|
|
67
|
+
category: 'ET'
|
|
68
|
+
},
|
|
69
|
+
'DS-AI': {
|
|
70
|
+
label: 'Data Science and Artificial Intelligence',
|
|
71
|
+
category: 'ET'
|
|
72
|
+
},
|
|
73
|
+
'ELEC-ENG': {
|
|
74
|
+
label: 'Engineering - Electrical and Electronic',
|
|
75
|
+
category: 'ET'
|
|
76
|
+
},
|
|
77
|
+
'PETRO-ENG': {
|
|
78
|
+
label: 'Engineering - Petroleum',
|
|
79
|
+
category: 'ET'
|
|
80
|
+
},
|
|
81
|
+
'MECH-ENG': {
|
|
82
|
+
label: 'Engineering - Mechanical',
|
|
83
|
+
category: 'ET'
|
|
84
|
+
},
|
|
85
|
+
'MIN-MIN-ENG': {
|
|
86
|
+
label: 'Engineering - Mineral and Mining',
|
|
87
|
+
category: 'ET'
|
|
88
|
+
},
|
|
89
|
+
'AG-FOR': {
|
|
90
|
+
label: 'Agriculture and Forestry',
|
|
91
|
+
category: 'LSM'
|
|
92
|
+
},
|
|
93
|
+
'ANA-PHYS': {
|
|
94
|
+
label: 'Anatomy and Physiology',
|
|
95
|
+
category: 'LSM'
|
|
96
|
+
},
|
|
97
|
+
'BIO-SCI': {
|
|
98
|
+
label: 'Biological Sciences',
|
|
99
|
+
category: 'LSM'
|
|
100
|
+
},
|
|
101
|
+
DENT: {
|
|
102
|
+
label: 'Dentistry',
|
|
103
|
+
category: 'LSM'
|
|
104
|
+
},
|
|
105
|
+
MED: {
|
|
106
|
+
label: 'Medicine',
|
|
107
|
+
category: 'LSM'
|
|
108
|
+
},
|
|
109
|
+
NURS: {
|
|
110
|
+
label: 'Nursing',
|
|
111
|
+
category: 'LSM'
|
|
112
|
+
},
|
|
113
|
+
PHARM: {
|
|
114
|
+
label: 'Pharmacy and Pharmacology',
|
|
115
|
+
category: 'LSM'
|
|
116
|
+
},
|
|
117
|
+
PSYCH: {
|
|
118
|
+
label: 'Psychology',
|
|
119
|
+
category: 'LSM'
|
|
120
|
+
},
|
|
121
|
+
'VET-SCI': {
|
|
122
|
+
label: 'Veterinary Science',
|
|
123
|
+
category: 'LSM'
|
|
124
|
+
},
|
|
125
|
+
CHEM: {
|
|
126
|
+
label: 'Chemistry',
|
|
127
|
+
category: 'NS'
|
|
128
|
+
},
|
|
129
|
+
'EAR-MAR-SCI': {
|
|
130
|
+
label: 'Earth and Marine Sciences',
|
|
131
|
+
category: 'NS'
|
|
132
|
+
},
|
|
133
|
+
'ENV-SCI': {
|
|
134
|
+
label: 'Environmental Sciences',
|
|
135
|
+
category: 'NS'
|
|
136
|
+
},
|
|
137
|
+
GEO: {
|
|
138
|
+
label: 'Geography',
|
|
139
|
+
category: 'NS'
|
|
140
|
+
},
|
|
141
|
+
GEOL: {
|
|
142
|
+
label: 'Geology',
|
|
143
|
+
category: 'NS'
|
|
144
|
+
},
|
|
145
|
+
GEOPH: {
|
|
146
|
+
label: 'Geophysics',
|
|
147
|
+
category: 'NS'
|
|
148
|
+
},
|
|
149
|
+
'MAT-SCI': {
|
|
150
|
+
label: 'Materials Sciences',
|
|
151
|
+
category: 'NS'
|
|
152
|
+
},
|
|
153
|
+
MATH: {
|
|
154
|
+
label: 'Mathematics',
|
|
155
|
+
category: 'NS'
|
|
156
|
+
},
|
|
157
|
+
'PHYS-ASTRO': {
|
|
158
|
+
label: 'Physics and Astronomy',
|
|
159
|
+
category: 'NS'
|
|
160
|
+
},
|
|
161
|
+
'ACC-FIN': {
|
|
162
|
+
label: 'Accounting and Finance',
|
|
163
|
+
category: 'SSM'
|
|
164
|
+
},
|
|
165
|
+
ANTH: {
|
|
166
|
+
label: 'Anthropology',
|
|
167
|
+
category: 'SSM'
|
|
168
|
+
},
|
|
169
|
+
'BUS-MGMT': {
|
|
170
|
+
label: 'Business and Management Studies',
|
|
171
|
+
category: 'SSM'
|
|
172
|
+
},
|
|
173
|
+
'COMM-MEDIA': {
|
|
174
|
+
label: 'Communication and Media Studies',
|
|
175
|
+
category: 'SSM'
|
|
176
|
+
},
|
|
177
|
+
'DEV-STUD': {
|
|
178
|
+
label: 'Development Studies',
|
|
179
|
+
category: 'SSM'
|
|
180
|
+
},
|
|
181
|
+
ECON: {
|
|
182
|
+
label: 'Economics and Econometrics',
|
|
183
|
+
category: 'SSM'
|
|
184
|
+
},
|
|
185
|
+
'EDU-TRAIN': {
|
|
186
|
+
label: 'Education and Training',
|
|
187
|
+
category: 'SSM'
|
|
188
|
+
},
|
|
189
|
+
'HOSP-MGMT': {
|
|
190
|
+
label: 'Hospitality and Leisure Management',
|
|
191
|
+
category: 'SSM'
|
|
192
|
+
},
|
|
193
|
+
LAW: {
|
|
194
|
+
label: 'Law and Legal Studies',
|
|
195
|
+
category: 'SSM'
|
|
196
|
+
},
|
|
197
|
+
'LIB-INFO': {
|
|
198
|
+
label: 'Library and Information Management',
|
|
199
|
+
category: 'SSM'
|
|
200
|
+
},
|
|
201
|
+
MKT: {
|
|
202
|
+
label: 'Marketing',
|
|
203
|
+
category: 'SSM'
|
|
204
|
+
},
|
|
205
|
+
POL: {
|
|
206
|
+
label: 'Politics',
|
|
207
|
+
category: 'SSM'
|
|
208
|
+
},
|
|
209
|
+
'SOC-POL': {
|
|
210
|
+
label: 'Social Policy and Administration',
|
|
211
|
+
category: 'SSM'
|
|
212
|
+
},
|
|
213
|
+
SOC: {
|
|
214
|
+
label: 'Sociology',
|
|
215
|
+
category: 'SSM'
|
|
216
|
+
},
|
|
217
|
+
SPORT: {
|
|
218
|
+
label: 'Sports-Related Subjects',
|
|
219
|
+
category: 'SSM'
|
|
220
|
+
},
|
|
221
|
+
'STAT-OR': {
|
|
222
|
+
label: 'Statistics and Operational Research',
|
|
223
|
+
category: 'SSM'
|
|
224
|
+
}
|
|
225
|
+
};
|
|
226
|
+
export var SemesterType;
|
|
227
|
+
(function (SemesterType) {
|
|
228
|
+
SemesterType["SummerSemester"] = "SS";
|
|
229
|
+
SemesterType["WinterSemester"] = "WS";
|
|
230
|
+
SemesterType["Rolling"] = "Rolling";
|
|
231
|
+
})(SemesterType || (SemesterType = {}));
|
|
232
|
+
var Category;
|
|
233
|
+
(function (Category) {
|
|
234
|
+
Category["TU9"] = "TU9";
|
|
235
|
+
Category["U15"] = "U15";
|
|
236
|
+
Category["EUROTECH"] = "EUROTECH";
|
|
237
|
+
Category["GERMAN_ELITE"] = "GERMAN_ELITE";
|
|
238
|
+
Category["TOP50"] = "TOP50";
|
|
239
|
+
Category["TIME"] = "TIME";
|
|
240
|
+
Category["TOP100"] = "TOP100";
|
|
241
|
+
Category["TOP150"] = "TOP150";
|
|
242
|
+
Category["TOP250"] = "TOP250";
|
|
243
|
+
Category["TOP500"] = "TOP500";
|
|
244
|
+
})(Category || (Category = {}));
|
|
245
|
+
export var DIFFICULTY = {
|
|
246
|
+
EASY: 'EASY',
|
|
247
|
+
HARD: 'HARD'
|
|
248
|
+
};
|
|
249
|
+
export var SCHOOL_TAGS = (_a = {},
|
|
250
|
+
_a[Category.U15] = {
|
|
251
|
+
label: 'U15',
|
|
252
|
+
category: 'U15'
|
|
253
|
+
},
|
|
254
|
+
_a[Category.TU9] = {
|
|
255
|
+
label: 'TU9 German Universities of Technology',
|
|
256
|
+
category: 'TU9'
|
|
257
|
+
},
|
|
258
|
+
_a[Category.EUROTECH] = {
|
|
259
|
+
label: 'EuroTech Universities Alliance',
|
|
260
|
+
category: 'EUROTECH'
|
|
261
|
+
},
|
|
262
|
+
_a[Category.GERMAN_ELITE] = {
|
|
263
|
+
label: 'German Excellence Initiative',
|
|
264
|
+
category: 'GERMAN_ELITE'
|
|
265
|
+
},
|
|
266
|
+
_a[Category.TIME] = {
|
|
267
|
+
label: 'Top International Managers in Engineering',
|
|
268
|
+
category: 'TIME'
|
|
269
|
+
},
|
|
270
|
+
_a[Category.TOP50] = {
|
|
271
|
+
label: 'QS Top 50 Universities',
|
|
272
|
+
category: 'TOP50'
|
|
273
|
+
},
|
|
274
|
+
_a[Category.TOP100] = {
|
|
275
|
+
label: 'QS Top 100 Universities',
|
|
276
|
+
category: 'TOP100'
|
|
277
|
+
},
|
|
278
|
+
_a[Category.TOP150] = {
|
|
279
|
+
label: 'QS Top 150 Universities',
|
|
280
|
+
category: 'TOP150'
|
|
281
|
+
},
|
|
282
|
+
_a[Category.TOP250] = {
|
|
283
|
+
label: 'QS Top 250 Universities',
|
|
284
|
+
category: 'TOP150'
|
|
285
|
+
},
|
|
286
|
+
_a[Category.TOP500] = {
|
|
287
|
+
label: 'QS Top 500 Universities',
|
|
288
|
+
category: 'TOP500'
|
|
289
|
+
},
|
|
290
|
+
_a);
|
|
291
|
+
export var SchoolType;
|
|
292
|
+
(function (SchoolType) {
|
|
293
|
+
SchoolType["University"] = "University";
|
|
294
|
+
SchoolType["University_of_Applied_Sciences"] = "University_of_Applied_Sciences";
|
|
295
|
+
})(SchoolType || (SchoolType = {}));
|
|
296
|
+
export var SCHOOL_TYPES = [
|
|
297
|
+
SchoolType.University,
|
|
298
|
+
SchoolType.University_of_Applied_Sciences
|
|
299
|
+
];
|
|
4
300
|
var SCHOOL_TAG_KEYS = Object.keys(SCHOOL_TAGS);
|
|
5
301
|
export var PROGRAM_SUBJECT_KEYS = Object.keys(PROGRAM_SUBJECTS);
|
|
6
302
|
export var DIFFICULTY_KEYS = Object.keys(DIFFICULTY);
|
package/dist/esm/model/User.js
CHANGED
|
@@ -1,8 +1,16 @@
|
|
|
1
1
|
import { Schema } from 'mongoose';
|
|
2
2
|
import validator from 'validator';
|
|
3
|
-
import { DocumentStatusType } from '@taiger-common/core';
|
|
4
3
|
import { Role } from '../constants/users';
|
|
5
4
|
import { PROGRAM_SUBJECT_KEYS } from './Program';
|
|
5
|
+
// --- Interfaces for frontend/backend type reference ---
|
|
6
|
+
export var DocumentStatusType;
|
|
7
|
+
(function (DocumentStatusType) {
|
|
8
|
+
DocumentStatusType["Uploaded"] = "uploaded";
|
|
9
|
+
DocumentStatusType["Missing"] = "missing";
|
|
10
|
+
DocumentStatusType["Accepted"] = "accepted";
|
|
11
|
+
DocumentStatusType["Rejected"] = "rejected";
|
|
12
|
+
DocumentStatusType["NotNeeded"] = "notneeded";
|
|
13
|
+
})(DocumentStatusType || (DocumentStatusType = {}));
|
|
6
14
|
var ManagerType = {
|
|
7
15
|
Agent: 'Agent',
|
|
8
16
|
Editor: 'Editor',
|