@driveup/schema 0.3.33 → 0.3.35
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/catalog/addon/addon.entity.d.ts +1 -1
- package/lib/catalog/addon/addon.entity.js +1 -1
- package/lib/catalog/addon/addon.entity.js.map +1 -1
- package/lib/catalog/product/product.entity.js +0 -3
- package/lib/catalog/product/product.entity.js.map +1 -1
- package/lib/profile/agent/agent.entity.d.ts +4 -3
- package/lib/profile/agent/agent.entity.js +10 -6
- package/lib/profile/agent/agent.entity.js.map +1 -1
- package/lib/profile/agent/asset.entity.js +1 -5
- package/lib/profile/agent/asset.entity.js.map +1 -1
- package/lib/profile/agent/payout.entity.d.ts +9 -1
- package/lib/profile/agent/payout.entity.js +23 -0
- package/lib/profile/agent/payout.entity.js.map +1 -1
- package/lib/profile/agent/promotion.entity.d.ts +12 -3
- package/lib/profile/agent/promotion.entity.js +26 -3
- package/lib/profile/agent/promotion.entity.js.map +1 -1
- package/lib/profile/company/company.entity.d.ts +9 -8
- package/lib/profile/company/company.entity.js +24 -18
- package/lib/profile/company/company.entity.js.map +1 -1
- package/lib/profile/company/course/course.entity.d.ts +12 -4
- package/lib/profile/company/course/course.entity.js +27 -4
- package/lib/profile/company/course/course.entity.js.map +1 -1
- package/lib/profile/company/course/lesson.entity.d.ts +5 -0
- package/lib/profile/company/course/lesson.entity.js +5 -0
- package/lib/profile/company/course/lesson.entity.js.map +1 -1
- package/lib/profile/company/course/schedule.entity.js.map +1 -1
- package/lib/profile/company/finances/billing/bill.entity.d.ts +10 -3
- package/lib/profile/company/finances/billing/bill.entity.js +27 -4
- package/lib/profile/company/finances/billing/bill.entity.js.map +1 -1
- package/lib/profile/company/finances/billing/transaction.entity.js.map +1 -1
- package/lib/profile/company/finances/expense/category.entity.d.ts +9 -0
- package/lib/profile/company/finances/expense/category.entity.js +23 -0
- package/lib/profile/company/finances/expense/category.entity.js.map +1 -1
- package/lib/profile/company/finances/expense/expense.entity.d.ts +9 -1
- package/lib/profile/company/finances/expense/expense.entity.js +23 -0
- package/lib/profile/company/finances/expense/expense.entity.js.map +1 -1
- package/lib/profile/company/finances/handover/handover.entity.d.ts +9 -0
- package/lib/profile/company/finances/handover/handover.entity.js +23 -0
- package/lib/profile/company/finances/handover/handover.entity.js.map +1 -1
- package/lib/profile/company/finances/invoice/invoice.entity.d.ts +11 -3
- package/lib/profile/company/finances/invoice/invoice.entity.js +25 -2
- package/lib/profile/company/finances/invoice/invoice.entity.js.map +1 -1
- package/lib/profile/company/finances/payment/method.entity.d.ts +11 -3
- package/lib/profile/company/finances/payment/method.entity.js +25 -2
- package/lib/profile/company/finances/payment/method.entity.js.map +1 -1
- package/lib/profile/company/instructor/instructor.entity.d.ts +6 -5
- package/lib/profile/company/instructor/instructor.entity.js +10 -6
- package/lib/profile/company/instructor/instructor.entity.js.map +1 -1
- package/lib/profile/company/instructor/task.entity.d.ts +14 -0
- package/lib/profile/company/instructor/task.entity.js +28 -1
- package/lib/profile/company/instructor/task.entity.js.map +1 -1
- package/lib/profile/company/medical/product.entity.d.ts +9 -0
- package/lib/profile/company/medical/product.entity.js +27 -0
- package/lib/profile/company/medical/product.entity.js.map +1 -1
- package/lib/profile/company/product/addon.entity.d.ts +10 -1
- package/lib/profile/company/product/addon.entity.js +26 -0
- package/lib/profile/company/product/addon.entity.js.map +1 -1
- package/lib/profile/company/product/product.entity.d.ts +14 -5
- package/lib/profile/company/product/product.entity.js +34 -11
- package/lib/profile/company/product/product.entity.js.map +1 -1
- package/lib/profile/company/product/vehicle.entity.d.ts +10 -1
- package/lib/profile/company/product/vehicle.entity.js +27 -0
- package/lib/profile/company/product/vehicle.entity.js.map +1 -1
- package/lib/profile/instructor/instructor.entity.d.ts +4 -3
- package/lib/profile/instructor/instructor.entity.js +10 -6
- package/lib/profile/instructor/instructor.entity.js.map +1 -1
- package/lib/profile/student/program/licence/licence.entity.d.ts +10 -1
- package/lib/profile/student/program/licence/licence.entity.js +26 -0
- package/lib/profile/student/program/licence/licence.entity.js.map +1 -1
- package/lib/profile/student/program/medical/certificate.entity.d.ts +10 -1
- package/lib/profile/student/program/medical/certificate.entity.js +26 -0
- package/lib/profile/student/program/medical/certificate.entity.js.map +1 -1
- package/lib/profile/student/program/medical/examination.entity.d.ts +11 -2
- package/lib/profile/student/program/medical/examination.entity.js +29 -3
- package/lib/profile/student/program/medical/examination.entity.js.map +1 -1
- package/lib/profile/student/program/program.entity.d.ts +13 -5
- package/lib/profile/student/program/program.entity.js +27 -4
- package/lib/profile/student/program/program.entity.js.map +1 -1
- package/lib/profile/student/program/training/appointment.entity.d.ts +10 -5
- package/lib/profile/student/program/training/appointment.entity.js +13 -7
- package/lib/profile/student/program/training/appointment.entity.js.map +1 -1
- package/lib/profile/student/program/training/exam.entity.d.ts +0 -5
- package/lib/profile/student/program/training/exam.entity.js +2 -9
- package/lib/profile/student/program/training/exam.entity.js.map +1 -1
- package/lib/profile/student/program/training/lesson.entity.js.map +1 -1
- package/lib/profile/student/program/training/topic.entity.js +4 -2
- package/lib/profile/student/program/training/topic.entity.js.map +1 -1
- package/lib/profile/student/program/training/training.entity.d.ts +20 -4
- package/lib/profile/student/program/training/training.entity.js +58 -17
- package/lib/profile/student/program/training/training.entity.js.map +1 -1
- package/lib/profile/student/program/training/transaction.entity.d.ts +6 -6
- package/lib/profile/student/program/training/transaction.entity.js +8 -8
- package/lib/profile/student/program/training/transaction.entity.js.map +1 -1
- package/lib/profile/student/student.entity.d.ts +8 -7
- package/lib/profile/student/student.entity.js +18 -14
- package/lib/profile/student/student.entity.js.map +1 -1
- package/lib/public/learning-hub.entity.js +0 -1
- package/lib/public/learning-hub.entity.js.map +1 -1
- package/lib/system/event/log.entity.d.ts +31 -17
- package/lib/system/event/log.entity.js +104 -58
- package/lib/system/event/log.entity.js.map +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/lib/user/user.entity.d.ts +5 -2
- package/lib/user/user.entity.js +11 -5
- package/lib/user/user.entity.js.map +1 -1
- package/package.json +3 -3
- package/lib/profile/company/course/appointment.entity.d.ts +0 -271
- package/lib/profile/company/course/appointment.entity.js +0 -736
- package/lib/profile/company/course/appointment.entity.js.map +0 -1
- package/lib/profile/company/instructor/calendar-state.entity.d.ts +0 -67
- package/lib/profile/company/instructor/calendar-state.entity.js +0 -75
- package/lib/profile/company/instructor/calendar-state.entity.js.map +0 -1
- package/lib/profile/student/program/training/training-balance.view.d.ts +0 -4
- package/lib/profile/student/program/training/training-balance.view.entity.d.ts +0 -5
- package/lib/profile/student/program/training/training-balance.view.entity.js +0 -52
- package/lib/profile/student/program/training/training-balance.view.entity.js.map +0 -1
- package/lib/profile/student/program/training/training-balance.view.js +0 -47
- package/lib/profile/student/program/training/training-balance.view.js.map +0 -1
- package/lib/profile/student/program/training/training-cost.view.d.ts +0 -4
- package/lib/profile/student/program/training/training-cost.view.js +0 -45
- package/lib/profile/student/program/training/training-cost.view.js.map +0 -1
- package/lib/profile/student/program/training/training-sessions.view.d.ts +0 -8
- package/lib/profile/student/program/training/training-sessions.view.js +0 -50
- package/lib/profile/student/program/training/training-sessions.view.js.map +0 -1
- package/lib/public/faq.d.ts +0 -25
- package/lib/public/faq.js +0 -60
- package/lib/public/faq.js.map +0 -1
- package/lib/public/feature-item.d.ts +0 -54
- package/lib/public/feature-item.js +0 -78
- package/lib/public/feature-item.js.map +0 -1
- package/lib/public/feature.d.ts +0 -46
- package/lib/public/feature.js +0 -76
- package/lib/public/feature.js.map +0 -1
- package/lib/public/learning-hub.d.ts +0 -30
- package/lib/public/learning-hub.js +0 -77
- package/lib/public/learning-hub.js.map +0 -1
- package/lib/public/testimonial.d.ts +0 -40
- package/lib/public/testimonial.js +0 -85
- package/lib/public/testimonial.js.map +0 -1
|
@@ -43,12 +43,12 @@ export declare class StudentTrainingTransactionEntity extends TrackableEntity<Tr
|
|
|
43
43
|
*/
|
|
44
44
|
description: string;
|
|
45
45
|
/**
|
|
46
|
-
* Reference to
|
|
46
|
+
* Reference to this transaction's cancellation item
|
|
47
47
|
* When an approved transaction is canceled, a new cancellation transaction is created,
|
|
48
48
|
* and this field points to that cancellation transaction.
|
|
49
49
|
* The original approved transaction's status remains Approved.
|
|
50
50
|
*/
|
|
51
|
-
|
|
51
|
+
cancellationItemId: number;
|
|
52
52
|
/**
|
|
53
53
|
* Bank account information used for this transaction
|
|
54
54
|
*/
|
|
@@ -94,16 +94,16 @@ export declare class StudentTrainingTransactionEntity extends TrackableEntity<Tr
|
|
|
94
94
|
toSummary(): Transaction;
|
|
95
95
|
getTraining(): Promise<StudentTrainingEntity>;
|
|
96
96
|
/**
|
|
97
|
-
* Retrieves the
|
|
98
|
-
* @returns The related transaction entity or undefined if no reference exists
|
|
97
|
+
* Retrieves the cancellation item for this transaction (if registered)
|
|
98
|
+
* @returns The related cancellation transaction entity or undefined if no reference exists
|
|
99
99
|
*/
|
|
100
|
-
|
|
100
|
+
getCancellationItem(): Promise<StudentTrainingTransactionEntity>;
|
|
101
101
|
/**
|
|
102
102
|
* Retrieves the original transaction that was canceled by this cancellation transaction
|
|
103
103
|
* Only applicable if this is a cancellation transaction
|
|
104
104
|
* @returns The original transaction entity that was canceled
|
|
105
105
|
*/
|
|
106
|
-
|
|
106
|
+
getOriginalTransaction(): Promise<StudentTrainingTransactionEntity>;
|
|
107
107
|
getRegisteredBy(): Promise<CompanyInstructorEntity>;
|
|
108
108
|
getApprovedBy(): Promise<CompanyInstructorEntity>;
|
|
109
109
|
getCanceledBy(): Promise<CompanyInstructorEntity>;
|
|
@@ -59,14 +59,14 @@ let StudentTrainingTransactionEntity = StudentTrainingTransactionEntity_1 = clas
|
|
|
59
59
|
return await this.training;
|
|
60
60
|
}
|
|
61
61
|
/**
|
|
62
|
-
* Retrieves the
|
|
63
|
-
* @returns The related transaction entity or undefined if no reference exists
|
|
62
|
+
* Retrieves the cancellation item for this transaction (if registered)
|
|
63
|
+
* @returns The related cancellation transaction entity or undefined if no reference exists
|
|
64
64
|
*/
|
|
65
|
-
async
|
|
66
|
-
if (!this.
|
|
65
|
+
async getCancellationItem() {
|
|
66
|
+
if (!this.cancellationItemId)
|
|
67
67
|
return;
|
|
68
68
|
return await StudentTrainingTransactionEntity_1.findOneBy({
|
|
69
|
-
id: this.
|
|
69
|
+
id: this.cancellationItemId
|
|
70
70
|
});
|
|
71
71
|
}
|
|
72
72
|
/**
|
|
@@ -74,9 +74,9 @@ let StudentTrainingTransactionEntity = StudentTrainingTransactionEntity_1 = clas
|
|
|
74
74
|
* Only applicable if this is a cancellation transaction
|
|
75
75
|
* @returns The original transaction entity that was canceled
|
|
76
76
|
*/
|
|
77
|
-
async
|
|
77
|
+
async getOriginalTransaction() {
|
|
78
78
|
return await StudentTrainingTransactionEntity_1.findOneBy({
|
|
79
|
-
|
|
79
|
+
cancellationItemId: this.id
|
|
80
80
|
});
|
|
81
81
|
}
|
|
82
82
|
async getRegisteredBy() {
|
|
@@ -193,7 +193,7 @@ __decorate([
|
|
|
193
193
|
default: null
|
|
194
194
|
}),
|
|
195
195
|
__metadata("design:type", Number)
|
|
196
|
-
], StudentTrainingTransactionEntity.prototype, "
|
|
196
|
+
], StudentTrainingTransactionEntity.prototype, "cancellationItemId", void 0);
|
|
197
197
|
__decorate([
|
|
198
198
|
(0, typeorm_1.Column)({
|
|
199
199
|
type: 'simple-json',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transaction.entity.js","sourceRoot":"","sources":["../../../../../src/profile/student/program/training/transaction.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,4CAAwD;AACxD,4CAAsG;AACtG,qCAA0E;AAE1E,qFAAwF;AACxF,qFAAwF;AACxF,uEAA+D;AAC/D,2DAA8D;AAC9D,uDAA0D;AAE1D;;;;GAIG;AAEI,IAAM,gCAAgC,wCAAtC,MAAM,gCAAiC,SAAQ,2BAA4B;IA6IjF;;;OAGG;IACH,YAAY,KAAiD;QAC5D,KAAK,EAAE,CAAC;QACR,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;IAED;;;OAGG;IACH,OAAO;QACN,OAAO,IAAI,oBAAW,CAAC;YACtB,EAAE,EAAE,IAAI,CAAC,EAAE;YACX,IAAI,EAAE,IAAI,CAAC,IAAW,EAAE,wDAAwD;YAChF,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,IAAI,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,oBAAW,CAAC,UAAU,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,IAAI;SACxE,CAAC,CAAC;IACJ,CAAC;IAED;;;OAGG;IACH,SAAS;QACR,OAAO,IAAI,CAAC,OAAO,EAAE,CAAC;IACvB,CAAC;IAED,KAAK,CAAC,WAAW;QAChB,OAAO,MAAM,IAAI,CAAC,QAAQ,CAAC;IAC5B,CAAC;IAED;;;OAGG;IACH,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"transaction.entity.js","sourceRoot":"","sources":["../../../../../src/profile/student/program/training/transaction.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,4CAAwD;AACxD,4CAAsG;AACtG,qCAA0E;AAE1E,qFAAwF;AACxF,qFAAwF;AACxF,uEAA+D;AAC/D,2DAA8D;AAC9D,uDAA0D;AAE1D;;;;GAIG;AAEI,IAAM,gCAAgC,wCAAtC,MAAM,gCAAiC,SAAQ,2BAA4B;IA6IjF;;;OAGG;IACH,YAAY,KAAiD;QAC5D,KAAK,EAAE,CAAC;QACR,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;IAED;;;OAGG;IACH,OAAO;QACN,OAAO,IAAI,oBAAW,CAAC;YACtB,EAAE,EAAE,IAAI,CAAC,EAAE;YACX,IAAI,EAAE,IAAI,CAAC,I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 +1,12 @@
|
|
|
1
1
|
import { Activity, Student } from '@driveup/common';
|
|
2
2
|
import { AccountStatus, Language, Person, Preference, PreferenceScope, ProductType, ProgramType } from '@driveup/shared';
|
|
3
|
+
import { UserEntity } from '../../user/user.entity';
|
|
4
|
+
import { TrackableEntity } from '../../utils/trackable';
|
|
5
|
+
import { CompanyEntity } from '../company/company.entity';
|
|
6
|
+
import { StudentLicenceEntity } from './program/licence/licence.entity';
|
|
3
7
|
import { StudentMedicalCertificateEntity } from './program/medical/certificate.entity';
|
|
4
8
|
import { StudentMedicalExaminationEntity } from './program/medical/examination.entity';
|
|
5
|
-
import { StudentLicenceEntity } from './program/licence/licence.entity';
|
|
6
|
-
import { CompanyEntity } from '../company/company.entity';
|
|
7
9
|
import { StudentProgramEntity } from './program/program.entity';
|
|
8
|
-
import { UserEntity } from '../../user/user.entity';
|
|
9
|
-
import { TrackableEntity } from '../../utils/trackable';
|
|
10
10
|
export declare class StudentEntity extends TrackableEntity<Student> {
|
|
11
11
|
/**
|
|
12
12
|
* Reference to the user account associated with this student profile
|
|
@@ -106,10 +106,11 @@ export declare class StudentEntity extends TrackableEntity<Student> {
|
|
|
106
106
|
/**
|
|
107
107
|
* Log student event
|
|
108
108
|
* @param event Event type
|
|
109
|
-
* @param
|
|
110
|
-
* @param
|
|
109
|
+
* @param metadata Content render data
|
|
110
|
+
* @param author Log author of the event
|
|
111
|
+
* @param systemLog Whether to create an additional system log entry
|
|
111
112
|
*/
|
|
112
|
-
log(event: string, metadata?: any,
|
|
113
|
+
log(event: string, metadata?: any, author?: Person, systemLog?: boolean): Promise<void>;
|
|
113
114
|
/**
|
|
114
115
|
* Retrieves notification preferences as typed Preference instances
|
|
115
116
|
* @returns Array of Preference objects or undefined if not set
|
|
@@ -14,16 +14,16 @@ exports.StudentEntity = void 0;
|
|
|
14
14
|
const common_1 = require("@driveup/common");
|
|
15
15
|
const shared_1 = require("@driveup/shared");
|
|
16
16
|
const typeorm_1 = require("typeorm");
|
|
17
|
-
const transaction_entity_1 = require("./program/training/transaction.entity");
|
|
18
|
-
const certificate_entity_1 = require("./program/medical/certificate.entity");
|
|
19
|
-
const examination_entity_1 = require("./program/medical/examination.entity");
|
|
20
|
-
const training_entity_1 = require("./program/training/training.entity");
|
|
21
|
-
const licence_entity_1 = require("./program/licence/licence.entity");
|
|
22
17
|
const log_entity_1 = require("../../system/event/log.entity");
|
|
23
|
-
const activity_helper_1 = require("../../utils/activity.helper");
|
|
24
|
-
const program_entity_1 = require("./program/program.entity");
|
|
25
18
|
const user_entity_1 = require("../../user/user.entity");
|
|
19
|
+
const activity_helper_1 = require("../../utils/activity.helper");
|
|
26
20
|
const trackable_1 = require("../../utils/trackable");
|
|
21
|
+
const licence_entity_1 = require("./program/licence/licence.entity");
|
|
22
|
+
const certificate_entity_1 = require("./program/medical/certificate.entity");
|
|
23
|
+
const examination_entity_1 = require("./program/medical/examination.entity");
|
|
24
|
+
const program_entity_1 = require("./program/program.entity");
|
|
25
|
+
const training_entity_1 = require("./program/training/training.entity");
|
|
26
|
+
const transaction_entity_1 = require("./program/training/transaction.entity");
|
|
27
27
|
let StudentEntity = StudentEntity_1 = class StudentEntity extends trackable_1.TrackableEntity {
|
|
28
28
|
/**
|
|
29
29
|
* Creates an instance of StudentEntity
|
|
@@ -115,7 +115,7 @@ let StudentEntity = StudentEntity_1 = class StudentEntity extends trackable_1.Tr
|
|
|
115
115
|
.andWhere('sp.studentId = :studentId', { studentId: this.id })
|
|
116
116
|
.andWhere('tr.type = :paymentType', { paymentType: shared_1.TransactionType.Payment })
|
|
117
117
|
.andWhere('tr.status != :canceledStatus', { canceledStatus: shared_1.StatusType.Canceled })
|
|
118
|
-
.andWhere('tr.
|
|
118
|
+
.andWhere('tr.cancellationItemId is null')
|
|
119
119
|
.select('SUM(COALESCE(tr.amount, 0))', 'total')
|
|
120
120
|
.getRawOne();
|
|
121
121
|
return Number(result?.total ?? 0);
|
|
@@ -134,19 +134,23 @@ let StudentEntity = StudentEntity_1 = class StudentEntity extends trackable_1.Tr
|
|
|
134
134
|
/**
|
|
135
135
|
* Log student event
|
|
136
136
|
* @param event Event type
|
|
137
|
-
* @param
|
|
138
|
-
* @param
|
|
137
|
+
* @param metadata Content render data
|
|
138
|
+
* @param author Log author of the event
|
|
139
|
+
* @param systemLog Whether to create an additional system log entry
|
|
139
140
|
*/
|
|
140
|
-
async log(event, metadata,
|
|
141
|
+
async log(event, metadata, author, systemLog) {
|
|
141
142
|
if (!this.id)
|
|
142
143
|
return;
|
|
144
|
+
author = author || await this.toPerson();
|
|
145
|
+
const systemContent = systemLog ? log_entity_1.LogEntity.toSystemContent(event, metadata) : null;
|
|
143
146
|
await log_entity_1.LogEntity.from({
|
|
144
|
-
|
|
147
|
+
feature: shared_1.Feature.Account,
|
|
145
148
|
profile: { type: shared_1.ProfileType.Student, id: this.id },
|
|
149
|
+
author: author,
|
|
146
150
|
event: event,
|
|
147
|
-
entityId:
|
|
151
|
+
entityId: this.id,
|
|
148
152
|
content: log_entity_1.LogEntity.toStudentContent(event, this.language, metadata)
|
|
149
|
-
});
|
|
153
|
+
}, systemContent);
|
|
150
154
|
}
|
|
151
155
|
/**
|
|
152
156
|
* Retrieves notification preferences as typed Preference instances
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"student.entity.js","sourceRoot":"","sources":["../../../src/profile/student/student.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,4CAAoD;AACpD,4CAA0L;AAC1L,qCAAyE;AAEzE,
|
|
1
|
+
{"version":3,"file":"student.entity.js","sourceRoot":"","sources":["../../../src/profile/student/student.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,4CAAoD;AACpD,4CAA0L;AAC1L,qCAAyE;AAEzE,8DAA0D;AAC1D,wDAAoD;AACpD,iEAAyD;AACzD,qDAAwD;AAExD,qEAAwE;AACxE,6EAAuF;AACvF,6EAAuF;AACvF,6DAAgE;AAChE,wEAA2E;AAC3E,8EAAyF;AAGlF,IAAM,a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b,CAAC;;kDACwB;AAQ1B;IADC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,wBAAU,EAAE,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,eAAe,CAAC;;2CAChC;AAQ1B;IADC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,oDAA+B,EAAE,WAAW,CAAC,EAAE,CAAC,WAAW,CAAC,OAAO,CAAC;;0DACrB;AAQhE;IADC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,oDAA+B,EAAE,WAAW,CAAC,EAAE,CAAC,WAAW,CAAC,OAAO,CAAC;;0DACrB;AAShE;IADC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,qCAAoB,EAAE,OAAO,CAAC,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC;;+CACxB;AAQ1C;IADC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,qCAAoB,EAAE,OAAO,CAAC,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC;;+CACxB;wBA5F9B,aAAa;IADzB,IAAA,gBAAM,EAAC,UAAU,CAAC;;GACN,aAAa,CAoQzB"}
|
|
@@ -12,7 +12,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
12
12
|
exports.PublicLearningHubItemEntity = void 0;
|
|
13
13
|
const shared_1 = require("@driveup/shared");
|
|
14
14
|
const typeorm_1 = require("typeorm");
|
|
15
|
-
// TODO: come up with better name (publicLearningResource?)
|
|
16
15
|
let PublicLearningHubItemEntity = class PublicLearningHubItemEntity extends typeorm_1.BaseEntity {
|
|
17
16
|
/************************* Methods *************************/
|
|
18
17
|
constructor(props) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"learning-hub.entity.js","sourceRoot":"","sources":["../../src/public/learning-hub.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,4CAAwD;AACxD,qCAA6E;
|
|
1
|
+
{"version":3,"file":"learning-hub.entity.js","sourceRoot":"","sources":["../../src/public/learning-hub.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,4CAAwD;AACxD,qCAA6E;AAGtE,IAAM,2BAA2B,GAAjC,MAAM,2BAA4B,SAAQ,oBAAU;IA+D1D,6DAA6D;IAE7D,YAAY,KAA4C;QACvD,KAAK,EAAE,CAAC;QACR,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;CACD,CAAA;AArEY,kEAA2B;AAMvC;IADC,IAAA,gCAAsB,GAAE;;uDACd;AAWX;IANC,IAAA,gBAAM,EAAC;QACP,IAAI,EAAE,MAAM;QACZ,IAAI,EAAE,iBAAQ;QACd,OAAO,EAAE,iBAAQ,CAAC,EAAE;QACpB,QAAQ,EAAE,KAAK;KACf,CAAC;;6DACiB;AAQnB;IANC,IAAA,gBAAM,EAAC;QACP,IAAI,EAAE,MAAM;QACZ,IAAI,EAAE,oBAAW;QACjB,OAAO,EAAE,oBAAW,CAAC,OAAO;QAC5B,QAAQ,EAAE,KAAK;KACf,CAAC;;4DACmB;AASrB;IAJC,IAAA,gBAAM,EAAC;QACP,QAAQ,EAAE,IAAI;QACd,OAAO,EAAE,IAAI;KACb,CAAC;;0DACY;AASd;IAJC,IAAA,gBAAM,EAAC;QACP,QAAQ,EAAE,IAAI;QACd,OAAO,EAAE,IAAI;KACb,CAAC;;gEACkB;AASpB;IAJC,IAAA,gBAAM,EAAC;QACP,QAAQ,EAAE,KAAK;QACf,OAAO,EAAE,CAAC;KACV,CAAC;;yDACW;AASb;IAJC,IAAA,gBAAM,EAAC;QACP,QAAQ,EAAE,IAAI;QACd,OAAO,EAAE,IAAI;KACb,CAAC;;6DACe;sCA7DL,2BAA2B;IADvC,IAAA,gBAAM,EAAC,wBAAwB,CAAC;;GACpB,2BAA2B,CAqEvC"}
|
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { Log } from '@driveup/common';
|
|
2
|
+
import { Feature, Person, SelectedProfile } from '@driveup/shared';
|
|
3
3
|
import { BaseEntity } from 'typeorm';
|
|
4
4
|
/**
|
|
5
|
-
* Represents a
|
|
5
|
+
* Represents a profile log entry for tracking events and activities.
|
|
6
6
|
* Logs record important actions and changes across different entity types
|
|
7
7
|
* (users, companies, agents, etc.) and can be localized for display.
|
|
8
|
-
*
|
|
9
|
-
* @extends TrackableEntity
|
|
10
8
|
*/
|
|
11
9
|
export declare class LogEntity extends BaseEntity {
|
|
12
10
|
/**
|
|
@@ -20,18 +18,24 @@ export declare class LogEntity extends BaseEntity {
|
|
|
20
18
|
* @example 'user.identity.nameChanged'
|
|
21
19
|
*/
|
|
22
20
|
event: string;
|
|
21
|
+
/**
|
|
22
|
+
* The feature associated with the log entry.
|
|
23
|
+
* This helps to identify the context of the log entry.
|
|
24
|
+
* @type {Feature}
|
|
25
|
+
*/
|
|
26
|
+
feature: Feature;
|
|
23
27
|
/**
|
|
24
28
|
* The type of event that is being logged.
|
|
25
29
|
* This can be used to categorize the log entry.
|
|
26
|
-
* @type {
|
|
30
|
+
* @type {ProfileType}
|
|
27
31
|
*/
|
|
28
|
-
|
|
32
|
+
profile: SelectedProfile;
|
|
29
33
|
/**
|
|
30
34
|
* The profile selected when the log was created.
|
|
31
35
|
* This helps to identify the context of the log entry.
|
|
32
36
|
* @type {SelectedProfile}
|
|
33
37
|
*/
|
|
34
|
-
|
|
38
|
+
author: Person;
|
|
35
39
|
/**
|
|
36
40
|
* The id of the entity associated with the log entry.
|
|
37
41
|
* In relation with logType, can be userId, trainingId, productId, etc.
|
|
@@ -60,18 +64,12 @@ export declare class LogEntity extends BaseEntity {
|
|
|
60
64
|
* @returns Log model with type, event, content, and creation date
|
|
61
65
|
*/
|
|
62
66
|
toModel(): Log;
|
|
63
|
-
/**
|
|
64
|
-
* Converts the entity to a Log model instance
|
|
65
|
-
* @returns Log model with type, event, content, and creation date
|
|
66
|
-
*/
|
|
67
|
-
toSummary(): Log;
|
|
68
67
|
/**
|
|
69
68
|
* Creates and saves a new log entry
|
|
70
69
|
* @param props - Properties for the new log entry
|
|
71
70
|
* @returns Promise that resolves when the log is saved
|
|
72
71
|
*/
|
|
73
|
-
static from(props: Partial<LogEntity
|
|
74
|
-
static system(event: string, metadata: any, entityId?: number): Promise<void>;
|
|
72
|
+
static from(props: Partial<LogEntity>, systemContent?: string): Promise<void>;
|
|
75
73
|
/**
|
|
76
74
|
* Generates localized content for user log entries
|
|
77
75
|
* @param event - The event identifier
|
|
@@ -113,6 +111,22 @@ export declare class LogEntity extends BaseEntity {
|
|
|
113
111
|
*/
|
|
114
112
|
static toCompanyContent(event: string, lang: string, metadata?: any): string;
|
|
115
113
|
static toSystemContent(event: string, metadata?: any): string;
|
|
116
|
-
|
|
117
|
-
|
|
114
|
+
}
|
|
115
|
+
export declare class SystemLogEntity extends LogEntity {
|
|
116
|
+
/**
|
|
117
|
+
* Creates a new LogEntity instance
|
|
118
|
+
* @param props - Partial properties to initialize the entity
|
|
119
|
+
*/
|
|
120
|
+
constructor(props?: Partial<LogEntity>);
|
|
121
|
+
/**
|
|
122
|
+
* Converts the entity to a Log model instance
|
|
123
|
+
* @returns Log model with type, event, content, and creation date
|
|
124
|
+
*/
|
|
125
|
+
toModel(): Log;
|
|
126
|
+
/**
|
|
127
|
+
* Creates and saves a new log entry
|
|
128
|
+
* @param props - Properties for the new log entry
|
|
129
|
+
* @returns Promise that resolves when the log is saved
|
|
130
|
+
*/
|
|
131
|
+
static from(props: Partial<LogEntity>): Promise<void>;
|
|
118
132
|
}
|
|
@@ -10,19 +10,15 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
10
10
|
};
|
|
11
11
|
var LogEntity_1;
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.LogEntity = void 0;
|
|
13
|
+
exports.SystemLogEntity = exports.LogEntity = void 0;
|
|
14
14
|
const common_1 = require("@driveup/common");
|
|
15
15
|
const shared_1 = require("@driveup/shared");
|
|
16
16
|
const nestjs_i18n_1 = require("nestjs-i18n");
|
|
17
17
|
const typeorm_1 = require("typeorm");
|
|
18
|
-
const activity_helper_1 = require("../../utils/activity.helper");
|
|
19
|
-
const DELIMITER = '.log.';
|
|
20
18
|
/**
|
|
21
|
-
* Represents a
|
|
19
|
+
* Represents a profile log entry for tracking events and activities.
|
|
22
20
|
* Logs record important actions and changes across different entity types
|
|
23
21
|
* (users, companies, agents, etc.) and can be localized for display.
|
|
24
|
-
*
|
|
25
|
-
* @extends TrackableEntity
|
|
26
22
|
*/
|
|
27
23
|
let LogEntity = LogEntity_1 = class LogEntity extends typeorm_1.BaseEntity {
|
|
28
24
|
/**
|
|
@@ -39,35 +35,29 @@ let LogEntity = LogEntity_1 = class LogEntity extends typeorm_1.BaseEntity {
|
|
|
39
35
|
*/
|
|
40
36
|
toModel() {
|
|
41
37
|
return new common_1.Log({
|
|
42
|
-
|
|
38
|
+
author: this.author,
|
|
39
|
+
profile: this.profile,
|
|
43
40
|
event: this.event,
|
|
44
41
|
content: this.content,
|
|
45
42
|
createdOn: this.createdOn
|
|
46
43
|
});
|
|
47
44
|
}
|
|
48
|
-
/**
|
|
49
|
-
* Converts the entity to a Log model instance
|
|
50
|
-
* @returns Log model with type, event, content, and creation date
|
|
51
|
-
*/
|
|
52
|
-
toSummary() {
|
|
53
|
-
return this.toModel();
|
|
54
|
-
}
|
|
55
45
|
/**
|
|
56
46
|
* Creates and saves a new log entry
|
|
57
47
|
* @param props - Properties for the new log entry
|
|
58
48
|
* @returns Promise that resolves when the log is saved
|
|
59
49
|
*/
|
|
60
|
-
static async from(props) {
|
|
50
|
+
static async from(props, systemContent) {
|
|
51
|
+
if (!props?.content || props.content.length === 0)
|
|
52
|
+
return;
|
|
61
53
|
const entity = new LogEntity_1(props);
|
|
62
54
|
await entity.save();
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
content: LogEntity_1.toSystemContent(event, metadata)
|
|
70
|
-
});
|
|
55
|
+
if (systemContent) {
|
|
56
|
+
await SystemLogEntity.from({
|
|
57
|
+
...props,
|
|
58
|
+
content: systemContent,
|
|
59
|
+
});
|
|
60
|
+
}
|
|
71
61
|
}
|
|
72
62
|
/**
|
|
73
63
|
* Generates localized content for user log entries
|
|
@@ -77,9 +67,13 @@ let LogEntity = LogEntity_1 = class LogEntity extends typeorm_1.BaseEntity {
|
|
|
77
67
|
* @returns Localized log content string, or empty string if translation not found
|
|
78
68
|
*/
|
|
79
69
|
static toUserContent(event, lang, metadata) {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
70
|
+
let key = `${event}.log.user`;
|
|
71
|
+
let content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
72
|
+
if (key === content) {
|
|
73
|
+
key = `${event}.log`;
|
|
74
|
+
content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
75
|
+
}
|
|
76
|
+
return content === key ? null : content;
|
|
83
77
|
}
|
|
84
78
|
/**
|
|
85
79
|
* Generates localized content for student log entries
|
|
@@ -89,9 +83,13 @@ let LogEntity = LogEntity_1 = class LogEntity extends typeorm_1.BaseEntity {
|
|
|
89
83
|
* @returns Localized log content string, or empty string if translation not found
|
|
90
84
|
*/
|
|
91
85
|
static toStudentContent(event, lang, metadata) {
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
86
|
+
let key = `${event}.log.${shared_1.ProfileType.Student}`;
|
|
87
|
+
let content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
88
|
+
if (key === content) {
|
|
89
|
+
key = `${event}.log`;
|
|
90
|
+
content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
91
|
+
}
|
|
92
|
+
return content === key ? null : content;
|
|
95
93
|
}
|
|
96
94
|
/**
|
|
97
95
|
* Generates localized content for agent log entries
|
|
@@ -101,9 +99,13 @@ let LogEntity = LogEntity_1 = class LogEntity extends typeorm_1.BaseEntity {
|
|
|
101
99
|
* @returns Localized log content string, or empty string if translation not found
|
|
102
100
|
*/
|
|
103
101
|
static toAgentContent(event, lang, metadata) {
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
102
|
+
let key = `${event}.log.${shared_1.ProfileType.Agent}`;
|
|
103
|
+
let content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
104
|
+
if (key === content) {
|
|
105
|
+
key = `${event}.log`;
|
|
106
|
+
content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
107
|
+
}
|
|
108
|
+
return content === key ? null : content;
|
|
107
109
|
}
|
|
108
110
|
/**
|
|
109
111
|
* Generates localized content for instructor log entries
|
|
@@ -113,9 +115,13 @@ let LogEntity = LogEntity_1 = class LogEntity extends typeorm_1.BaseEntity {
|
|
|
113
115
|
* @returns Localized log content string, or empty string if translation not found
|
|
114
116
|
*/
|
|
115
117
|
static toInstructorContent(event, lang, metadata) {
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
118
|
+
let key = `${event}.log.${shared_1.ProfileType.Instructor}`;
|
|
119
|
+
let content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
120
|
+
if (key === content) {
|
|
121
|
+
key = `${event}.log`;
|
|
122
|
+
content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
123
|
+
}
|
|
124
|
+
return content === key ? null : content;
|
|
119
125
|
}
|
|
120
126
|
/**
|
|
121
127
|
* Generates localized content for company log entries
|
|
@@ -125,24 +131,22 @@ let LogEntity = LogEntity_1 = class LogEntity extends typeorm_1.BaseEntity {
|
|
|
125
131
|
* @returns Localized log content string, or empty string if translation not found
|
|
126
132
|
*/
|
|
127
133
|
static toCompanyContent(event, lang, metadata) {
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
134
|
+
let key = `${event}.log.${shared_1.ProfileType.Company}`;
|
|
135
|
+
let content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
136
|
+
if (key === content) {
|
|
137
|
+
key = `${event}.log`;
|
|
138
|
+
content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang });
|
|
139
|
+
}
|
|
140
|
+
return content === key ? null : content;
|
|
131
141
|
}
|
|
132
142
|
static toSystemContent(event, metadata) {
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
return content === key ? '' : content;
|
|
141
|
-
}
|
|
142
|
-
async getActivities() {
|
|
143
|
-
const activities = [];
|
|
144
|
-
activities.push(await (0, activity_helper_1.toActivity)(null, this.createdOn, shared_1.ActivityType.created));
|
|
145
|
-
return activities.filter(a => a);
|
|
143
|
+
let key = `${event}.log.system`;
|
|
144
|
+
let content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang: 'en' });
|
|
145
|
+
if (key === content) {
|
|
146
|
+
key = `${event}.log`;
|
|
147
|
+
content = nestjs_i18n_1.I18nContext.current().t(key, { args: metadata, lang: 'en' });
|
|
148
|
+
}
|
|
149
|
+
return content === key ? null : content;
|
|
146
150
|
}
|
|
147
151
|
};
|
|
148
152
|
exports.LogEntity = LogEntity;
|
|
@@ -157,25 +161,28 @@ __decorate([
|
|
|
157
161
|
__decorate([
|
|
158
162
|
(0, typeorm_1.Column)({
|
|
159
163
|
type: 'enum',
|
|
160
|
-
enum: shared_1.
|
|
161
|
-
default: shared_1.
|
|
162
|
-
nullable: true
|
|
164
|
+
enum: shared_1.Feature,
|
|
165
|
+
default: shared_1.Feature.Account
|
|
163
166
|
}),
|
|
164
167
|
__metadata("design:type", String)
|
|
165
|
-
], LogEntity.prototype, "
|
|
168
|
+
], LogEntity.prototype, "feature", void 0);
|
|
166
169
|
__decorate([
|
|
167
170
|
(0, typeorm_1.Column)({
|
|
168
171
|
type: 'simple-json',
|
|
169
|
-
nullable: true
|
|
170
|
-
default: null
|
|
172
|
+
nullable: true
|
|
171
173
|
}),
|
|
172
174
|
__metadata("design:type", Object)
|
|
173
175
|
], LogEntity.prototype, "profile", void 0);
|
|
174
176
|
__decorate([
|
|
175
177
|
(0, typeorm_1.Column)({
|
|
178
|
+
type: 'json',
|
|
176
179
|
nullable: true,
|
|
177
180
|
default: null
|
|
178
181
|
}),
|
|
182
|
+
__metadata("design:type", shared_1.Person)
|
|
183
|
+
], LogEntity.prototype, "author", void 0);
|
|
184
|
+
__decorate([
|
|
185
|
+
(0, typeorm_1.Column)(),
|
|
179
186
|
__metadata("design:type", Number)
|
|
180
187
|
], LogEntity.prototype, "entityId", void 0);
|
|
181
188
|
__decorate([
|
|
@@ -190,7 +197,46 @@ __decorate([
|
|
|
190
197
|
__metadata("design:type", Date)
|
|
191
198
|
], LogEntity.prototype, "createdOn", void 0);
|
|
192
199
|
exports.LogEntity = LogEntity = LogEntity_1 = __decorate([
|
|
193
|
-
(0, typeorm_1.Entity)('
|
|
200
|
+
(0, typeorm_1.Entity)('logs'),
|
|
194
201
|
__metadata("design:paramtypes", [Object])
|
|
195
202
|
], LogEntity);
|
|
203
|
+
let SystemLogEntity = class SystemLogEntity extends LogEntity {
|
|
204
|
+
/**
|
|
205
|
+
* Creates a new LogEntity instance
|
|
206
|
+
* @param props - Partial properties to initialize the entity
|
|
207
|
+
*/
|
|
208
|
+
constructor(props) {
|
|
209
|
+
super();
|
|
210
|
+
Object.assign(this, props);
|
|
211
|
+
}
|
|
212
|
+
/**
|
|
213
|
+
* Converts the entity to a Log model instance
|
|
214
|
+
* @returns Log model with type, event, content, and creation date
|
|
215
|
+
*/
|
|
216
|
+
toModel() {
|
|
217
|
+
return new common_1.Log({
|
|
218
|
+
author: this.author,
|
|
219
|
+
profile: this.profile,
|
|
220
|
+
event: this.event,
|
|
221
|
+
content: this.content,
|
|
222
|
+
createdOn: this.createdOn
|
|
223
|
+
});
|
|
224
|
+
}
|
|
225
|
+
/**
|
|
226
|
+
* Creates and saves a new log entry
|
|
227
|
+
* @param props - Properties for the new log entry
|
|
228
|
+
* @returns Promise that resolves when the log is saved
|
|
229
|
+
*/
|
|
230
|
+
static async from(props) {
|
|
231
|
+
if (!props?.content || props.content.length === 0)
|
|
232
|
+
return;
|
|
233
|
+
const entity = new LogEntity(props);
|
|
234
|
+
await entity.save();
|
|
235
|
+
}
|
|
236
|
+
};
|
|
237
|
+
exports.SystemLogEntity = SystemLogEntity;
|
|
238
|
+
exports.SystemLogEntity = SystemLogEntity = __decorate([
|
|
239
|
+
(0, typeorm_1.Entity)('systemLogs'),
|
|
240
|
+
__metadata("design:paramtypes", [Object])
|
|
241
|
+
], SystemLogEntity);
|
|
196
242
|
//# sourceMappingURL=log.entity.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"log.entity.js","sourceRoot":"","sources":["../../../src/system/event/log.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"log.entity.js","sourceRoot":"","sources":["../../../src/system/event/log.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,4CAAsC;AACtC,4CAAgF;AAChF,6CAA0C;AAC1C,qCAA+F;AAE/F;;;;GAIG;AAEI,IAAM,SAAS,iBAAf,MAAM,SAAU,SAAQ,oBAAU;IAgFxC;;;OAGG;IACH,YAAY,KAA0B;QACrC,KAAK,EAAE,CAAC;QACR,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC5B,CAAC;IAED;;;OAGG;IACH,OAAO;QACN,OAAO,IAAI,YAAG,CAAC;YACd,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,SAAS,EAAE,IAAI,CAAC,SAAS;SACzB,CAAC,CAAC;IACJ,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,KAAyB,EAAE,aAAsB;QAClE,IAA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