@taiger-common/model 1.0.28 → 1.0.30

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/README.md CHANGED
@@ -21,4 +21,4 @@ git push origin main --tags
21
21
  npm publish
22
22
 
23
23
  # Concat command for powershell (please modify the commit message)
24
- git add .; git commit -m "fix: copy applications to new collection"; git push origin main; npm run build; npm version patch; git push origin main --tags; npm publish
24
+ git add .; git commit -m "fix: remove applications in students"; git push origin main; npm run build; npm version patch; git push origin main --tags; npm publish
@@ -4,6 +4,7 @@ exports.applicationSchema = void 0;
4
4
  var mongoose_1 = require("mongoose");
5
5
  exports.applicationSchema = new mongoose_1.Schema({
6
6
  programId: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Program' },
7
+ studentId: { type: mongoose_1.Schema.Types.ObjectId, ref: 'User' },
7
8
  uni_assist: {
8
9
  status: {
9
10
  type: String,
@@ -360,83 +360,10 @@ var userSchema = new mongoose_1.Schema({
360
360
  },
361
361
  lastLoginAt: Date
362
362
  }, options);
363
- var applicationSchema = new mongoose_1.Schema({
364
- programId: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Program' },
365
- uni_assist: {
366
- status: {
367
- type: String,
368
- default: 'notstarted'
369
- },
370
- vpd_file_path: {
371
- type: String,
372
- default: ''
373
- },
374
- vpd_paid_confirmation_file_path: {
375
- type: String,
376
- default: ''
377
- },
378
- vpd_paid_confirmation_file_status: {
379
- type: String,
380
- default: ''
381
- },
382
- isPaid: {
383
- type: Boolean,
384
- default: false
385
- },
386
- updatedAt: Date
387
- },
388
- portal_credentials: {
389
- application_portal_a: {
390
- account: { type: String, select: false, trim: true },
391
- password: { type: String, select: false, trim: true }
392
- },
393
- application_portal_b: {
394
- account: { type: String, select: false, trim: true },
395
- password: { type: String, select: false, trim: true }
396
- }
397
- },
398
- doc_modification_thread: [
399
- {
400
- isFinalVersion: {
401
- type: Boolean,
402
- default: false
403
- },
404
- latest_message_left_by_id: {
405
- type: String,
406
- default: ''
407
- },
408
- doc_thread_id: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Documentthread' },
409
- updatedAt: Date,
410
- createdAt: Date
411
- }
412
- ],
413
- reject_reason: {
414
- type: String,
415
- default: ''
416
- },
417
- admission_letter: {
418
- status: {
419
- type: String,
420
- default: 'notstarted'
421
- },
422
- admission_file_path: {
423
- type: String,
424
- default: ''
425
- },
426
- comments: { type: String, default: '' },
427
- updatedAt: Date
428
- },
429
- finalEnrolment: { type: Boolean, default: false },
430
- decided: { type: String, default: '-' },
431
- closed: { type: String, default: '-' },
432
- admission: { type: String, default: '-' },
433
- application_year: { type: String, default: '' }
434
- });
435
363
  var studentSchema = new mongoose_1.Schema({
436
364
  agents: [{ type: mongoose_1.Schema.Types.ObjectId, ref: 'Agent' }],
437
365
  editors: [{ type: mongoose_1.Schema.Types.ObjectId, ref: 'Editor' }],
438
366
  needEditor: { type: Boolean, default: false },
439
- applications: [applicationSchema],
440
367
  applying_program_count: {
441
368
  type: Number,
442
369
  default: 0
@@ -1,6 +1,7 @@
1
1
  import { Schema } from 'mongoose';
2
2
  export var applicationSchema = new Schema({
3
3
  programId: { type: Schema.Types.ObjectId, ref: 'Program' },
4
+ studentId: { type: Schema.Types.ObjectId, ref: 'User' },
4
5
  uni_assist: {
5
6
  status: {
6
7
  type: String,
@@ -355,83 +355,10 @@ var userSchema = new Schema({
355
355
  },
356
356
  lastLoginAt: Date
357
357
  }, options);
358
- var applicationSchema = new Schema({
359
- programId: { type: Schema.Types.ObjectId, ref: 'Program' },
360
- uni_assist: {
361
- status: {
362
- type: String,
363
- default: 'notstarted'
364
- },
365
- vpd_file_path: {
366
- type: String,
367
- default: ''
368
- },
369
- vpd_paid_confirmation_file_path: {
370
- type: String,
371
- default: ''
372
- },
373
- vpd_paid_confirmation_file_status: {
374
- type: String,
375
- default: ''
376
- },
377
- isPaid: {
378
- type: Boolean,
379
- default: false
380
- },
381
- updatedAt: Date
382
- },
383
- portal_credentials: {
384
- application_portal_a: {
385
- account: { type: String, select: false, trim: true },
386
- password: { type: String, select: false, trim: true }
387
- },
388
- application_portal_b: {
389
- account: { type: String, select: false, trim: true },
390
- password: { type: String, select: false, trim: true }
391
- }
392
- },
393
- doc_modification_thread: [
394
- {
395
- isFinalVersion: {
396
- type: Boolean,
397
- default: false
398
- },
399
- latest_message_left_by_id: {
400
- type: String,
401
- default: ''
402
- },
403
- doc_thread_id: { type: Schema.Types.ObjectId, ref: 'Documentthread' },
404
- updatedAt: Date,
405
- createdAt: Date
406
- }
407
- ],
408
- reject_reason: {
409
- type: String,
410
- default: ''
411
- },
412
- admission_letter: {
413
- status: {
414
- type: String,
415
- default: 'notstarted'
416
- },
417
- admission_file_path: {
418
- type: String,
419
- default: ''
420
- },
421
- comments: { type: String, default: '' },
422
- updatedAt: Date
423
- },
424
- finalEnrolment: { type: Boolean, default: false },
425
- decided: { type: String, default: '-' },
426
- closed: { type: String, default: '-' },
427
- admission: { type: String, default: '-' },
428
- application_year: { type: String, default: '' }
429
- });
430
358
  var studentSchema = new Schema({
431
359
  agents: [{ type: Schema.Types.ObjectId, ref: 'Agent' }],
432
360
  editors: [{ type: Schema.Types.ObjectId, ref: 'Editor' }],
433
361
  needEditor: { type: Boolean, default: false },
434
- applications: [applicationSchema],
435
362
  applying_program_count: {
436
363
  type: Number,
437
364
  default: 0
@@ -51,6 +51,7 @@ export declare const applicationSchema: Schema<any, import("mongoose").Model<any
51
51
  admission: string;
52
52
  application_year: string;
53
53
  programId?: import("mongoose").Types.ObjectId | null | undefined;
54
+ studentId?: import("mongoose").Types.ObjectId | null | undefined;
54
55
  uni_assist?: {
55
56
  status: string;
56
57
  vpd_file_path: string;
@@ -102,6 +103,7 @@ export declare const applicationSchema: Schema<any, import("mongoose").Model<any
102
103
  admission: string;
103
104
  application_year: string;
104
105
  programId?: import("mongoose").Types.ObjectId | null | undefined;
106
+ studentId?: import("mongoose").Types.ObjectId | null | undefined;
105
107
  uni_assist?: {
106
108
  status: string;
107
109
  vpd_file_path: string;
@@ -153,6 +155,7 @@ export declare const applicationSchema: Schema<any, import("mongoose").Model<any
153
155
  admission: string;
154
156
  application_year: string;
155
157
  programId?: import("mongoose").Types.ObjectId | null | undefined;
158
+ studentId?: import("mongoose").Types.ObjectId | null | undefined;
156
159
  uni_assist?: {
157
160
  status: string;
158
161
  vpd_file_path: string;
@@ -27,8 +27,8 @@ import { Schema } from 'mongoose';
27
27
  export declare const surveyInputSchema: Schema<any, import("mongoose").Model<any, any, any, any, any, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, {
28
28
  createdAt: NativeDate;
29
29
  updatedAt: NativeDate;
30
- isFinalVersion: boolean;
31
30
  studentId: import("mongoose").Types.ObjectId;
31
+ isFinalVersion: boolean;
32
32
  fileType: string;
33
33
  surveyContent: import("mongoose").Types.DocumentArray<{
34
34
  _id?: unknown;
@@ -57,8 +57,8 @@ export declare const surveyInputSchema: Schema<any, import("mongoose").Model<any
57
57
  }, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
58
58
  createdAt: NativeDate;
59
59
  updatedAt: NativeDate;
60
- isFinalVersion: boolean;
61
60
  studentId: import("mongoose").Types.ObjectId;
61
+ isFinalVersion: boolean;
62
62
  fileType: string;
63
63
  surveyContent: import("mongoose").Types.DocumentArray<{
64
64
  _id?: unknown;
@@ -87,8 +87,8 @@ export declare const surveyInputSchema: Schema<any, import("mongoose").Model<any
87
87
  }>> & import("mongoose").FlatRecord<{
88
88
  createdAt: NativeDate;
89
89
  updatedAt: NativeDate;
90
- isFinalVersion: boolean;
91
90
  studentId: import("mongoose").Types.ObjectId;
91
+ isFinalVersion: boolean;
92
92
  fileType: string;
93
93
  surveyContent: import("mongoose").Types.DocumentArray<{
94
94
  _id?: unknown;