gemcap-be-common 1.4.90 → 1.4.92

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.
@@ -36,19 +36,17 @@ export interface IBorrowerNote {
36
36
  text: string;
37
37
  attachments: IBorrowerNoteAttachment[];
38
38
  createdBy: string;
39
- updatedBy: string;
40
- deletedBy?: string;
41
- deletedAt?: Date;
39
+ updatedBy?: string;
42
40
  }
43
41
  export interface IBorrowerNoteDoc extends IBorrowerNote, Document {
44
42
  _id: mongoose.Types.ObjectId;
45
43
  createdAt: Date;
46
44
  updatedAt: Date;
47
45
  }
48
- export interface IBorrowerNoteCreate extends Omit<IBorrowerNote, '_id' | 'borrowerId' | 'attachments'> {
46
+ export interface IBorrowerNoteCreate extends Omit<IBorrowerNote, '_id' | 'borrowerId' | 'attachments' | 'updatedBy'> {
49
47
  borrowerId: string;
50
48
  }
51
- export interface IBorrowerNoteUpdate extends Omit<IBorrowerNote, '_id' | 'borrowerId' | 'attachments'> {
49
+ export interface IBorrowerNoteUpdate extends Omit<IBorrowerNote, '_id' | 'borrowerId' | 'attachments' | 'createdBy'> {
52
50
  borrowerId: string;
53
51
  removedAttachments: string[];
54
52
  }
@@ -29,12 +29,6 @@ const BorrowerNoteAttachmentSchema = new mongoose_1.default.Schema({
29
29
  },
30
30
  });
31
31
  exports.BorrowerNoteSchema = new mongoose_1.default.Schema({
32
- deletedBy: {
33
- type: String,
34
- },
35
- deletedAt: {
36
- type: Date,
37
- },
38
32
  borrowerId: {
39
33
  type: mongoose_1.default.Schema.Types.ObjectId,
40
34
  ref: _models_1.MODEL_NAMES.borrowers,
@@ -55,6 +49,9 @@ exports.BorrowerNoteSchema = new mongoose_1.default.Schema({
55
49
  type: String,
56
50
  required: true,
57
51
  },
52
+ updatedBy: {
53
+ type: String,
54
+ },
58
55
  attachments: [BorrowerNoteAttachmentSchema],
59
56
  }, {
60
57
  timestamps: true,
@@ -16,9 +16,7 @@ export interface IBorrowerNote {
16
16
  text: string,
17
17
  attachments: IBorrowerNoteAttachment[],
18
18
  createdBy: string,
19
- updatedBy: string,
20
- deletedBy?: string,
21
- deletedAt?: Date,
19
+ updatedBy?: string,
22
20
  }
23
21
 
24
22
  export interface IBorrowerNoteDoc extends IBorrowerNote, Document {
@@ -27,11 +25,11 @@ export interface IBorrowerNoteDoc extends IBorrowerNote, Document {
27
25
  updatedAt: Date;
28
26
  }
29
27
 
30
- export interface IBorrowerNoteCreate extends Omit<IBorrowerNote, '_id' | 'borrowerId' | 'attachments'> {
28
+ export interface IBorrowerNoteCreate extends Omit<IBorrowerNote, '_id' | 'borrowerId' | 'attachments' | 'updatedBy'> {
31
29
  borrowerId: string;
32
30
  }
33
31
 
34
- export interface IBorrowerNoteUpdate extends Omit<IBorrowerNote, '_id' | 'borrowerId' | 'attachments'> {
32
+ export interface IBorrowerNoteUpdate extends Omit<IBorrowerNote, '_id' | 'borrowerId' | 'attachments' | 'createdBy'> {
35
33
  borrowerId: string;
36
34
  removedAttachments: string[];
37
35
  }
@@ -74,12 +72,6 @@ const BorrowerNoteAttachmentSchema = new mongoose.Schema<IBorrowerNoteAttachment
74
72
  });
75
73
 
76
74
  export const BorrowerNoteSchema = new mongoose.Schema<IBorrowerNoteDoc>({
77
- deletedBy: {
78
- type: String,
79
- },
80
- deletedAt: {
81
- type: Date,
82
- },
83
75
  borrowerId: {
84
76
  type: mongoose.Schema.Types.ObjectId,
85
77
  ref: MODEL_NAMES.borrowers,
@@ -100,6 +92,9 @@ export const BorrowerNoteSchema = new mongoose.Schema<IBorrowerNoteDoc>({
100
92
  type: String,
101
93
  required: true,
102
94
  },
95
+ updatedBy: {
96
+ type: String,
97
+ },
103
98
  attachments: [BorrowerNoteAttachmentSchema],
104
99
  }, {
105
100
  timestamps: true,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gemcap-be-common",
3
- "version": "1.4.90",
3
+ "version": "1.4.92",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {