@taiger-common/model 1.0.48 → 1.0.50
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/User.js +19 -28
- package/dist/esm/model/User.js +9 -18
- package/dist/types/model/Allcourse.d.ts +2 -1
- package/dist/types/model/Application.d.ts +4 -2
- package/dist/types/model/Audit.d.ts +7 -4
- package/dist/types/model/Communication.d.ts +6 -4
- package/dist/types/model/Complaint.d.ts +3 -2
- package/dist/types/model/Documentthread.d.ts +12 -8
- package/dist/types/model/Event.d.ts +3 -2
- package/dist/types/model/Interview.d.ts +10 -5
- package/dist/types/model/InterviewSurveyResponse.d.ts +6 -3
- package/dist/types/model/Note.d.ts +2 -1
- package/dist/types/model/Permission.d.ts +2 -1
- package/dist/types/model/ResponseTime.d.ts +4 -2
- package/dist/types/model/SurveyInput.d.ts +4 -2
- package/dist/types/model/Ticket.d.ts +5 -3
- package/dist/types/model/Token.d.ts +2 -1
- package/dist/types/model/User.d.ts +1944 -4
- package/dist/umd/index.js +1 -1
- package/package.json +1 -1
package/dist/cjs/model/User.js
CHANGED
|
@@ -3,7 +3,7 @@ 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
|
+
exports.editorSchema = exports.agentSchema = exports.managerSchema = exports.externalSchema = exports.studentSchema = exports.userSchema = exports.attributeSchema = exports.options = exports.ManagerType = exports.DocumentStatusType = void 0;
|
|
7
7
|
var mongoose_1 = require("mongoose");
|
|
8
8
|
var validator_1 = __importDefault(require("validator"));
|
|
9
9
|
var users_1 = require("../constants/users");
|
|
@@ -17,14 +17,14 @@ var DocumentStatusType;
|
|
|
17
17
|
DocumentStatusType["Rejected"] = "rejected";
|
|
18
18
|
DocumentStatusType["NotNeeded"] = "notneeded";
|
|
19
19
|
})(DocumentStatusType = exports.DocumentStatusType || (exports.DocumentStatusType = {}));
|
|
20
|
-
|
|
20
|
+
exports.ManagerType = {
|
|
21
21
|
Agent: 'Agent',
|
|
22
22
|
Editor: 'Editor',
|
|
23
23
|
AgentAndEditor: 'AgentAndEditor',
|
|
24
24
|
None: 'None'
|
|
25
25
|
};
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
exports.options = { discriminatorKey: 'role', timestamps: true };
|
|
27
|
+
exports.attributeSchema = new mongoose_1.Schema({
|
|
28
28
|
value: {
|
|
29
29
|
type: Number,
|
|
30
30
|
required: true
|
|
@@ -34,7 +34,7 @@ var attributeSchema = new mongoose_1.Schema({
|
|
|
34
34
|
required: true
|
|
35
35
|
}
|
|
36
36
|
});
|
|
37
|
-
|
|
37
|
+
exports.userSchema = new mongoose_1.Schema({
|
|
38
38
|
role: {
|
|
39
39
|
type: String,
|
|
40
40
|
enum: Object.values(users_1.Role),
|
|
@@ -377,8 +377,8 @@ var userSchema = new mongoose_1.Schema({
|
|
|
377
377
|
}
|
|
378
378
|
},
|
|
379
379
|
lastLoginAt: Date
|
|
380
|
-
}, options);
|
|
381
|
-
|
|
380
|
+
}, exports.options);
|
|
381
|
+
exports.studentSchema = new mongoose_1.Schema({
|
|
382
382
|
agents: [{ type: mongoose_1.Schema.Types.ObjectId, ref: 'Agent' }],
|
|
383
383
|
editors: [{ type: mongoose_1.Schema.Types.ObjectId, ref: 'Editor' }],
|
|
384
384
|
needEditor: { type: Boolean, default: false },
|
|
@@ -388,7 +388,7 @@ var studentSchema = new mongoose_1.Schema({
|
|
|
388
388
|
},
|
|
389
389
|
attributes: [
|
|
390
390
|
{
|
|
391
|
-
type: attributeSchema,
|
|
391
|
+
type: exports.attributeSchema,
|
|
392
392
|
required: true
|
|
393
393
|
}
|
|
394
394
|
],
|
|
@@ -434,8 +434,8 @@ var studentSchema = new mongoose_1.Schema({
|
|
|
434
434
|
createdAt: Date
|
|
435
435
|
}
|
|
436
436
|
]
|
|
437
|
-
}, options);
|
|
438
|
-
|
|
437
|
+
}, exports.options);
|
|
438
|
+
exports.externalSchema = new mongoose_1.Schema({
|
|
439
439
|
attribute: {
|
|
440
440
|
can_update_program_list: {
|
|
441
441
|
type: Boolean,
|
|
@@ -450,14 +450,14 @@ var externalSchema = new mongoose_1.Schema({
|
|
|
450
450
|
default: false
|
|
451
451
|
}
|
|
452
452
|
}
|
|
453
|
-
}, options);
|
|
454
|
-
|
|
453
|
+
}, exports.options);
|
|
454
|
+
exports.managerSchema = new mongoose_1.Schema({
|
|
455
455
|
agents: [{ type: mongoose_1.Schema.Types.ObjectId, ref: 'Agent' }],
|
|
456
456
|
editors: [{ type: mongoose_1.Schema.Types.ObjectId, ref: 'Editor' }],
|
|
457
457
|
manager_type: {
|
|
458
458
|
type: String,
|
|
459
|
-
enum: Object.values(ManagerType),
|
|
460
|
-
default: ManagerType.None
|
|
459
|
+
enum: Object.values(exports.ManagerType),
|
|
460
|
+
default: exports.ManagerType.None
|
|
461
461
|
},
|
|
462
462
|
manager_notification: {
|
|
463
463
|
isRead_new_base_docs_uploaded: [
|
|
@@ -495,7 +495,7 @@ var managerSchema = new mongoose_1.Schema({
|
|
|
495
495
|
default: false
|
|
496
496
|
}
|
|
497
497
|
}
|
|
498
|
-
}, options);
|
|
498
|
+
}, exports.options);
|
|
499
499
|
var officehours = {
|
|
500
500
|
Monday: {
|
|
501
501
|
active: { type: Boolean, default: false },
|
|
@@ -526,7 +526,7 @@ var officehours = {
|
|
|
526
526
|
time_slots: [{ type: Object }]
|
|
527
527
|
}
|
|
528
528
|
};
|
|
529
|
-
|
|
529
|
+
exports.agentSchema = new mongoose_1.Schema({
|
|
530
530
|
timezone: { type: String, default: '' },
|
|
531
531
|
officehours: officehours,
|
|
532
532
|
selfIntroduction: {
|
|
@@ -563,8 +563,8 @@ var agentSchema = new mongoose_1.Schema({
|
|
|
563
563
|
default: false
|
|
564
564
|
}
|
|
565
565
|
}
|
|
566
|
-
}, options);
|
|
567
|
-
|
|
566
|
+
}, exports.options);
|
|
567
|
+
exports.editorSchema = new mongoose_1.Schema({
|
|
568
568
|
timezone: { type: String, default: '' },
|
|
569
569
|
officehours: officehours,
|
|
570
570
|
editor_notification: {
|
|
@@ -607,13 +607,4 @@ var editorSchema = new mongoose_1.Schema({
|
|
|
607
607
|
default: false
|
|
608
608
|
}
|
|
609
609
|
}
|
|
610
|
-
}, options);
|
|
611
|
-
module.exports = {
|
|
612
|
-
attributeSchema: attributeSchema,
|
|
613
|
-
userSchema: userSchema,
|
|
614
|
-
studentSchema: studentSchema,
|
|
615
|
-
agentSchema: agentSchema,
|
|
616
|
-
externalSchema: externalSchema,
|
|
617
|
-
editorSchema: editorSchema,
|
|
618
|
-
managerSchema: managerSchema
|
|
619
|
-
};
|
|
610
|
+
}, exports.options);
|
package/dist/esm/model/User.js
CHANGED
|
@@ -11,14 +11,14 @@ export var DocumentStatusType;
|
|
|
11
11
|
DocumentStatusType["Rejected"] = "rejected";
|
|
12
12
|
DocumentStatusType["NotNeeded"] = "notneeded";
|
|
13
13
|
})(DocumentStatusType || (DocumentStatusType = {}));
|
|
14
|
-
var ManagerType = {
|
|
14
|
+
export var ManagerType = {
|
|
15
15
|
Agent: 'Agent',
|
|
16
16
|
Editor: 'Editor',
|
|
17
17
|
AgentAndEditor: 'AgentAndEditor',
|
|
18
18
|
None: 'None'
|
|
19
19
|
};
|
|
20
|
-
var options = { discriminatorKey: 'role', timestamps: true };
|
|
21
|
-
var attributeSchema = new Schema({
|
|
20
|
+
export var options = { discriminatorKey: 'role', timestamps: true };
|
|
21
|
+
export var attributeSchema = new Schema({
|
|
22
22
|
value: {
|
|
23
23
|
type: Number,
|
|
24
24
|
required: true
|
|
@@ -28,7 +28,7 @@ var attributeSchema = new Schema({
|
|
|
28
28
|
required: true
|
|
29
29
|
}
|
|
30
30
|
});
|
|
31
|
-
var userSchema = new Schema({
|
|
31
|
+
export var userSchema = new Schema({
|
|
32
32
|
role: {
|
|
33
33
|
type: String,
|
|
34
34
|
enum: Object.values(Role),
|
|
@@ -372,7 +372,7 @@ var userSchema = new Schema({
|
|
|
372
372
|
},
|
|
373
373
|
lastLoginAt: Date
|
|
374
374
|
}, options);
|
|
375
|
-
var studentSchema = new Schema({
|
|
375
|
+
export var studentSchema = new Schema({
|
|
376
376
|
agents: [{ type: Schema.Types.ObjectId, ref: 'Agent' }],
|
|
377
377
|
editors: [{ type: Schema.Types.ObjectId, ref: 'Editor' }],
|
|
378
378
|
needEditor: { type: Boolean, default: false },
|
|
@@ -429,7 +429,7 @@ var studentSchema = new Schema({
|
|
|
429
429
|
}
|
|
430
430
|
]
|
|
431
431
|
}, options);
|
|
432
|
-
var externalSchema = new Schema({
|
|
432
|
+
export var externalSchema = new Schema({
|
|
433
433
|
attribute: {
|
|
434
434
|
can_update_program_list: {
|
|
435
435
|
type: Boolean,
|
|
@@ -445,7 +445,7 @@ var externalSchema = new Schema({
|
|
|
445
445
|
}
|
|
446
446
|
}
|
|
447
447
|
}, options);
|
|
448
|
-
var managerSchema = new Schema({
|
|
448
|
+
export var managerSchema = new Schema({
|
|
449
449
|
agents: [{ type: Schema.Types.ObjectId, ref: 'Agent' }],
|
|
450
450
|
editors: [{ type: Schema.Types.ObjectId, ref: 'Editor' }],
|
|
451
451
|
manager_type: {
|
|
@@ -520,7 +520,7 @@ var officehours = {
|
|
|
520
520
|
time_slots: [{ type: Object }]
|
|
521
521
|
}
|
|
522
522
|
};
|
|
523
|
-
var agentSchema = new Schema({
|
|
523
|
+
export var agentSchema = new Schema({
|
|
524
524
|
timezone: { type: String, default: '' },
|
|
525
525
|
officehours: officehours,
|
|
526
526
|
selfIntroduction: {
|
|
@@ -558,7 +558,7 @@ var agentSchema = new Schema({
|
|
|
558
558
|
}
|
|
559
559
|
}
|
|
560
560
|
}, options);
|
|
561
|
-
var editorSchema = new Schema({
|
|
561
|
+
export var editorSchema = new Schema({
|
|
562
562
|
timezone: { type: String, default: '' },
|
|
563
563
|
officehours: officehours,
|
|
564
564
|
editor_notification: {
|
|
@@ -602,12 +602,3 @@ var editorSchema = new Schema({
|
|
|
602
602
|
}
|
|
603
603
|
}
|
|
604
604
|
}, options);
|
|
605
|
-
module.exports = {
|
|
606
|
-
attributeSchema: attributeSchema,
|
|
607
|
-
userSchema: userSchema,
|
|
608
|
-
studentSchema: studentSchema,
|
|
609
|
-
agentSchema: agentSchema,
|
|
610
|
-
externalSchema: externalSchema,
|
|
611
|
-
editorSchema: editorSchema,
|
|
612
|
-
managerSchema: managerSchema
|
|
613
|
-
};
|
|
@@ -24,8 +24,9 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
27
28
|
export interface IAllCourse {
|
|
28
|
-
updatedBy: Schema.Types.ObjectId;
|
|
29
|
+
updatedBy: IUser | Schema.Types.ObjectId | string;
|
|
29
30
|
all_course_chinese: string;
|
|
30
31
|
all_course_english: string;
|
|
31
32
|
description: string;
|
|
@@ -24,6 +24,8 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IProgram } from './Program';
|
|
28
|
+
import { IStudent } from './User';
|
|
27
29
|
export interface IApplicationUniAssist {
|
|
28
30
|
status?: string;
|
|
29
31
|
vpd_file_path?: string;
|
|
@@ -56,8 +58,8 @@ export interface IApplicationAdmissionLetter {
|
|
|
56
58
|
updatedAt?: Date;
|
|
57
59
|
}
|
|
58
60
|
export interface IApplication {
|
|
59
|
-
programId?: Schema.Types.ObjectId;
|
|
60
|
-
studentId?: Schema.Types.ObjectId;
|
|
61
|
+
programId?: IProgram | Schema.Types.ObjectId | string;
|
|
62
|
+
studentId?: IStudent | Schema.Types.ObjectId | string;
|
|
61
63
|
uni_assist?: IApplicationUniAssist;
|
|
62
64
|
portal_credentials?: IApplicationPortalCredentials;
|
|
63
65
|
doc_modification_thread?: IApplicationDocModificationThreadItem[];
|
|
@@ -24,11 +24,14 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
28
|
+
import { IDocumentthread } from './Documentthread';
|
|
29
|
+
import { IInterview } from './Interview';
|
|
27
30
|
export interface IAudit {
|
|
28
|
-
performedBy?: Schema.Types.ObjectId;
|
|
29
|
-
targetUserId?: Schema.Types.ObjectId;
|
|
30
|
-
targetDocumentThreadId?: Schema.Types.ObjectId;
|
|
31
|
-
interviewThreadId?: Schema.Types.ObjectId;
|
|
31
|
+
performedBy?: IUser | Schema.Types.ObjectId | string;
|
|
32
|
+
targetUserId?: IUser | Schema.Types.ObjectId | string;
|
|
33
|
+
targetDocumentThreadId?: IDocumentthread | Schema.Types.ObjectId | string;
|
|
34
|
+
interviewThreadId?: IInterview | Schema.Types.ObjectId | string;
|
|
32
35
|
action?: string;
|
|
33
36
|
field?: string;
|
|
34
37
|
changes?: {
|
|
@@ -24,21 +24,23 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
28
|
+
import { IStudent } from './User';
|
|
27
29
|
export interface ICommunicationFile {
|
|
28
30
|
name: string;
|
|
29
31
|
path: string;
|
|
30
32
|
}
|
|
31
33
|
export interface ICommunication {
|
|
32
|
-
student_id?: Schema.Types.ObjectId;
|
|
33
|
-
user_id?: Schema.Types.ObjectId;
|
|
34
|
+
student_id?: IStudent | Schema.Types.ObjectId | string;
|
|
35
|
+
user_id?: IUser | Schema.Types.ObjectId | string;
|
|
34
36
|
message?: string;
|
|
35
|
-
readBy?: Schema.Types.ObjectId[];
|
|
37
|
+
readBy?: IUser[] | Schema.Types.ObjectId[] | string[];
|
|
36
38
|
timeStampReadBy?: Schema.Types.Mixed;
|
|
37
39
|
files?: ICommunicationFile[];
|
|
38
40
|
createdAt?: Date;
|
|
39
41
|
ignore_message?: boolean;
|
|
40
42
|
ignoredMessageUpdatedAt?: Date;
|
|
41
|
-
ignoredMessageBy?: Schema.Types.ObjectId;
|
|
43
|
+
ignoredMessageBy?: IUser | Schema.Types.ObjectId | string;
|
|
42
44
|
}
|
|
43
45
|
export declare const communicationsSchema: Schema<ICommunication, import("mongoose").Model<ICommunication, any, any, any, import("mongoose").Document<unknown, any, ICommunication> & ICommunication & {
|
|
44
46
|
_id: import("mongoose").Types.ObjectId;
|
|
@@ -24,19 +24,20 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
27
28
|
export interface IComplaintMessageFile {
|
|
28
29
|
name: string;
|
|
29
30
|
path: string;
|
|
30
31
|
}
|
|
31
32
|
export interface IComplaintMessage {
|
|
32
|
-
user_id?: Schema.Types.ObjectId;
|
|
33
|
+
user_id?: IUser | Schema.Types.ObjectId | string;
|
|
33
34
|
message?: string;
|
|
34
35
|
createdAt?: Date;
|
|
35
36
|
file?: IComplaintMessageFile[];
|
|
36
37
|
ignore_message?: boolean;
|
|
37
38
|
}
|
|
38
39
|
export interface IComplaint {
|
|
39
|
-
requester_id: Schema.Types.ObjectId;
|
|
40
|
+
requester_id: IUser | Schema.Types.ObjectId | string;
|
|
40
41
|
status?: string;
|
|
41
42
|
title?: string;
|
|
42
43
|
category?: string;
|
|
@@ -24,31 +24,35 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
28
|
+
import { IStudent } from './User';
|
|
29
|
+
import { IProgram } from './Program';
|
|
30
|
+
import { IApplication } from './Application';
|
|
27
31
|
export interface IDocumentthreadMessageFile {
|
|
28
32
|
name: string;
|
|
29
33
|
path: string;
|
|
30
34
|
}
|
|
31
35
|
export interface IDocumentthreadMessage {
|
|
32
|
-
user_id?: Schema.Types.ObjectId;
|
|
36
|
+
user_id?: IUser | Schema.Types.ObjectId | string;
|
|
33
37
|
message?: string;
|
|
34
38
|
createdAt?: Date;
|
|
35
39
|
file?: IDocumentthreadMessageFile[];
|
|
36
40
|
ignore_message?: boolean;
|
|
37
41
|
}
|
|
38
42
|
export interface IDocumentthread {
|
|
39
|
-
student_id: Schema.Types.ObjectId;
|
|
40
|
-
program_id?: Schema.Types.ObjectId;
|
|
41
|
-
application_id?: Schema.Types.ObjectId;
|
|
42
|
-
outsourced_user_id?: Schema.Types.ObjectId[];
|
|
43
|
-
pin_by_user_id?: Schema.Types.ObjectId[];
|
|
44
|
-
flag_by_user_id?: Schema.Types.ObjectId[];
|
|
43
|
+
student_id: IStudent | Schema.Types.ObjectId | string;
|
|
44
|
+
program_id?: IProgram | Schema.Types.ObjectId | string;
|
|
45
|
+
application_id?: IApplication | Schema.Types.ObjectId | string;
|
|
46
|
+
outsourced_user_id?: IUser[] | Schema.Types.ObjectId[] | string[];
|
|
47
|
+
pin_by_user_id?: IUser[] | Schema.Types.ObjectId[] | string[];
|
|
48
|
+
flag_by_user_id?: IUser[] | Schema.Types.ObjectId[] | string[];
|
|
45
49
|
file_type: string;
|
|
46
50
|
isFinalVersion?: boolean;
|
|
47
51
|
isOriginAuthorDeclarationConfirmedByStudent?: boolean;
|
|
48
52
|
isOriginAuthorDeclarationConfirmedByStudentTimestamp?: Date;
|
|
49
53
|
messages?: IDocumentthreadMessage[];
|
|
50
54
|
isEssayConsultantNeeded?: boolean;
|
|
51
|
-
essayConsultantIds?: Schema.Types.ObjectId[];
|
|
55
|
+
essayConsultantIds?: IUser[] | Schema.Types.ObjectId[] | string[];
|
|
52
56
|
updatedAt?: Date;
|
|
53
57
|
}
|
|
54
58
|
export declare const documentThreadsSchema: Schema<IDocumentthread, import("mongoose").Model<IDocumentthread, any, any, any, import("mongoose").Document<unknown, any, IDocumentthread> & IDocumentthread & {
|
|
@@ -24,9 +24,10 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
27
28
|
export interface IEvent {
|
|
28
|
-
requester_id?: Schema.Types.ObjectId[];
|
|
29
|
-
receiver_id?: Schema.Types.ObjectId[];
|
|
29
|
+
requester_id?: IUser[] | Schema.Types.ObjectId[] | string[];
|
|
30
|
+
receiver_id?: IUser[] | Schema.Types.ObjectId[] | string[];
|
|
30
31
|
isConfirmedRequester?: boolean;
|
|
31
32
|
isConfirmedReceiver?: boolean;
|
|
32
33
|
meetingLink?: string;
|
|
@@ -24,12 +24,17 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
28
|
+
import { IStudent } from './User';
|
|
29
|
+
import { IProgram } from './Program';
|
|
30
|
+
import { IDocumentthread } from './Documentthread';
|
|
31
|
+
import { IEvent } from './Event';
|
|
27
32
|
export interface IInterview {
|
|
28
|
-
student_id?: Schema.Types.ObjectId;
|
|
29
|
-
trainer_id?: Schema.Types.ObjectId[];
|
|
30
|
-
thread_id?: Schema.Types.ObjectId;
|
|
31
|
-
program_id?: Schema.Types.ObjectId;
|
|
32
|
-
event_id?: Schema.Types.ObjectId;
|
|
33
|
+
student_id?: IStudent | Schema.Types.ObjectId | string;
|
|
34
|
+
trainer_id?: IUser[] | Schema.Types.ObjectId[] | string[];
|
|
35
|
+
thread_id?: IDocumentthread | Schema.Types.ObjectId | string;
|
|
36
|
+
program_id?: IProgram | Schema.Types.ObjectId | string;
|
|
37
|
+
event_id?: IEvent | Schema.Types.ObjectId | string;
|
|
33
38
|
interview_description?: string;
|
|
34
39
|
interviewer?: string;
|
|
35
40
|
interview_duration?: string;
|
|
@@ -24,14 +24,17 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IStudent } from './User';
|
|
28
|
+
import { IProgram } from './Program';
|
|
29
|
+
import { IInterview } from './Interview';
|
|
27
30
|
export interface IInterviewSurveyResponseResponse {
|
|
28
31
|
questionId?: string;
|
|
29
32
|
answer?: number;
|
|
30
33
|
}
|
|
31
34
|
export interface IInterviewSurveyResponse {
|
|
32
|
-
student_id?: Schema.Types.ObjectId;
|
|
33
|
-
interview_id?: Schema.Types.ObjectId;
|
|
34
|
-
program_id?: Schema.Types.ObjectId;
|
|
35
|
+
student_id?: IStudent | Schema.Types.ObjectId | string;
|
|
36
|
+
interview_id?: IInterview | Schema.Types.ObjectId | string;
|
|
37
|
+
program_id?: IProgram | Schema.Types.ObjectId | string;
|
|
35
38
|
responses?: IInterviewSurveyResponseResponse[];
|
|
36
39
|
isFinal?: boolean;
|
|
37
40
|
interviewQuestions?: string;
|
|
@@ -24,8 +24,9 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IStudent } from './User';
|
|
27
28
|
export interface INote {
|
|
28
|
-
student_id?: Schema.Types.ObjectId;
|
|
29
|
+
student_id?: IStudent | Schema.Types.ObjectId | string;
|
|
29
30
|
notes?: string;
|
|
30
31
|
updatedAt?: Date;
|
|
31
32
|
}
|
|
@@ -24,8 +24,9 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
27
28
|
export interface IPermission {
|
|
28
|
-
user_id?: Schema.Types.ObjectId;
|
|
29
|
+
user_id?: IUser | Schema.Types.ObjectId | string;
|
|
29
30
|
taigerAiQuota?: number;
|
|
30
31
|
canAssignEditors?: boolean;
|
|
31
32
|
canUseTaiGerAI?: boolean;
|
|
@@ -24,9 +24,11 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IDocumentthread } from './Documentthread';
|
|
28
|
+
import { IStudent } from './User';
|
|
27
29
|
export interface IResponseTime {
|
|
28
|
-
thread_id?: Schema.Types.ObjectId;
|
|
29
|
-
student_id?: Schema.Types.ObjectId;
|
|
30
|
+
thread_id?: IDocumentthread | Schema.Types.ObjectId | string;
|
|
31
|
+
student_id?: IStudent | Schema.Types.ObjectId | string;
|
|
30
32
|
interval_type: string;
|
|
31
33
|
intervalAvg: number;
|
|
32
34
|
updatedAt?: Date;
|
|
@@ -24,6 +24,8 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IStudent } from './User';
|
|
28
|
+
import { IProgram } from './Program';
|
|
27
29
|
export interface ISurveyInputSurveyContent {
|
|
28
30
|
questionId?: string;
|
|
29
31
|
question?: string;
|
|
@@ -32,8 +34,8 @@ export interface ISurveyInputSurveyContent {
|
|
|
32
34
|
contentType?: string;
|
|
33
35
|
}
|
|
34
36
|
export interface ISurveyInput {
|
|
35
|
-
studentId: Schema.Types.ObjectId;
|
|
36
|
-
programId?: Schema.Types.ObjectId;
|
|
37
|
+
studentId: IStudent | Schema.Types.ObjectId | string;
|
|
38
|
+
programId?: IProgram | Schema.Types.ObjectId | string;
|
|
37
39
|
fileType: string;
|
|
38
40
|
isFinalVersion?: boolean;
|
|
39
41
|
surveyContent?: ISurveyInputSurveyContent[];
|
|
@@ -24,10 +24,12 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
28
|
+
import { IProgram } from './Program';
|
|
27
29
|
export interface ITicket {
|
|
28
|
-
requester_id: Schema.Types.ObjectId;
|
|
29
|
-
resolver_id?: Schema.Types.ObjectId;
|
|
30
|
-
program_id?: Schema.Types.ObjectId;
|
|
30
|
+
requester_id: IUser | Schema.Types.ObjectId | string;
|
|
31
|
+
resolver_id?: IUser | Schema.Types.ObjectId | string;
|
|
32
|
+
program_id?: IProgram | Schema.Types.ObjectId | string;
|
|
31
33
|
status?: string;
|
|
32
34
|
type?: string;
|
|
33
35
|
description?: string;
|
|
@@ -24,8 +24,9 @@
|
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
26
26
|
import { Schema } from 'mongoose';
|
|
27
|
+
import { IUser } from './User';
|
|
27
28
|
export interface IToken {
|
|
28
|
-
userId: Schema.Types.ObjectId;
|
|
29
|
+
userId: IUser | Schema.Types.ObjectId | string;
|
|
29
30
|
value: string;
|
|
30
31
|
createdAt?: Date;
|
|
31
32
|
}
|