@aldb2b/common 1.0.950 → 1.0.951
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/build/entities/entities.module.js +1 -2
- package/build/entities/entities.module.js.map +1 -1
- package/build/entities/models/common/common.provider.d.ts +19 -0
- package/build/entities/models/common/common.provider.js +26 -0
- package/build/entities/models/common/common.provider.js.map +1 -1
- package/build/entities/models/common/entity.common.module.d.ts +2 -0
- package/build/entities/models/common/entity.common.module.js +29 -0
- package/build/entities/models/common/entity.common.module.js.map +1 -0
- package/build/entities/models/model.providers.d.ts +0 -10
- package/build/entities/models/model.providers.js +0 -2
- package/build/entities/models/model.providers.js.map +1 -1
- package/build/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -11,7 +11,6 @@ const common_1 = require("@nestjs/common");
|
|
|
11
11
|
const mongoose_providers_1 = require("./mongoose.providers");
|
|
12
12
|
const model_providers_1 = require("./models/model.providers");
|
|
13
13
|
const config_1 = require("@nestjs/config");
|
|
14
|
-
const common_2 = require("./models/common");
|
|
15
14
|
let EntitiesModule = class EntitiesModule {
|
|
16
15
|
};
|
|
17
16
|
exports.EntitiesModule = EntitiesModule;
|
|
@@ -23,7 +22,7 @@ exports.EntitiesModule = EntitiesModule = __decorate([
|
|
|
23
22
|
isGlobal: true,
|
|
24
23
|
}),
|
|
25
24
|
],
|
|
26
|
-
controllers: [
|
|
25
|
+
controllers: [],
|
|
27
26
|
providers: [...mongoose_providers_1.mongooseProviders, ...model_providers_1.modelProviders],
|
|
28
27
|
exports: [...mongoose_providers_1.mongooseProviders, ...model_providers_1.modelProviders],
|
|
29
28
|
})
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entities.module.js","sourceRoot":"","sources":["../../src/entities/entities.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAA+C;AAC/C,6DAAwD;AACxD,8DAAyD;AACzD,2CAA6C;
|
|
1
|
+
{"version":3,"file":"entities.module.js","sourceRoot":"","sources":["../../src/entities/entities.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAA+C;AAC/C,6DAAwD;AACxD,8DAAyD;AACzD,2CAA6C;AAatC,IAAM,cAAc,GAApB,MAAM,cAAc;CAAG,CAAA;AAAjB,wCAAc;yBAAd,cAAc;IAX1B,IAAA,eAAM,GAAE;IACR,IAAA,eAAM,EAAC;QACN,OAAO,EAAE;YACP,qBAAY,CAAC,OAAO,CAAC;gBACnB,QAAQ,EAAE,IAAI;aACf,CAAC;SACH;QACD,WAAW,EAAE,EAAE;QACf,SAAS,EAAE,CAAC,GAAG,sCAAiB,EAAE,GAAG,gCAAc,CAAC;QACpD,OAAO,EAAE,CAAC,GAAG,sCAAiB,EAAE,GAAG,gCAAc,CAAC;KACnD,CAAC;GACW,cAAc,CAAG"}
|
|
@@ -52,10 +52,29 @@
|
|
|
52
52
|
import { DatabaseModel } from '../../../enums/database-model.enum';
|
|
53
53
|
import { DatabaseConnection } from '../../../enums/database-connection.enum';
|
|
54
54
|
import { RepositoryProvider } from '../../../enums/repository-provider.enum';
|
|
55
|
+
import { ServiceProvider } from '../../../enums/service-provider.enum';
|
|
56
|
+
import { User } from '../users';
|
|
57
|
+
import { AuditTrail } from './entities/audit-trail.entity';
|
|
58
|
+
import { AuditTrailRepository } from './repositories/audit-trail.repository';
|
|
59
|
+
import { AuditTrailService } from './services/audit-trail.service';
|
|
55
60
|
import { CustomModel } from '../../../db/CustomModel';
|
|
56
61
|
import { PreferenceCustomization } from './entities/preference-customization.entity';
|
|
57
62
|
import { PreferenceCustomizationRepository } from './repositories/preference-customization.repository';
|
|
58
63
|
export declare const commonProviders: ({
|
|
64
|
+
provide: DatabaseModel;
|
|
65
|
+
useFactory: (connection: import("mongoose").Connection, eventConnection: import("mongoose").Connection, userConnection: import("mongoose").Connection) => import("mongoose").Model<AuditTrail, {}, {}, {}, import("mongoose").Document<unknown, {}, AuditTrail> & AuditTrail & Required<{
|
|
66
|
+
_id: string;
|
|
67
|
+
}>, any>;
|
|
68
|
+
inject: DatabaseConnection[];
|
|
69
|
+
} | {
|
|
70
|
+
provide: RepositoryProvider;
|
|
71
|
+
inject: DatabaseModel[];
|
|
72
|
+
useFactory: (auditModel: CustomModel<AuditTrail>) => AuditTrailRepository;
|
|
73
|
+
} | {
|
|
74
|
+
provide: ServiceProvider;
|
|
75
|
+
inject: (DatabaseModel | RepositoryProvider)[];
|
|
76
|
+
useFactory: (auditLogRepository: AuditTrailRepository, userModel: CustomModel<User>) => AuditTrailService;
|
|
77
|
+
} | {
|
|
59
78
|
provide: DatabaseModel;
|
|
60
79
|
useFactory: (connection: import("mongoose").Connection, eventConnection: import("mongoose").Connection, companyConnection: import("mongoose").Connection) => import("mongoose").Model<PreferenceCustomization, {}, {}, {}, import("mongoose").Document<unknown, {}, PreferenceCustomization> & PreferenceCustomization & Required<{
|
|
61
80
|
_id: string;
|
|
@@ -4,9 +4,35 @@ exports.commonProviders = void 0;
|
|
|
4
4
|
const database_model_enum_1 = require("../../../enums/database-model.enum");
|
|
5
5
|
const database_connection_enum_1 = require("../../../enums/database-connection.enum");
|
|
6
6
|
const repository_provider_enum_1 = require("../../../enums/repository-provider.enum");
|
|
7
|
+
const service_provider_enum_1 = require("../../../enums/service-provider.enum");
|
|
8
|
+
const audit_trail_entity_1 = require("./entities/audit-trail.entity");
|
|
9
|
+
const audit_trail_repository_1 = require("./repositories/audit-trail.repository");
|
|
10
|
+
const audit_trail_service_1 = require("./services/audit-trail.service");
|
|
7
11
|
const preference_customization_entity_1 = require("./entities/preference-customization.entity");
|
|
8
12
|
const preference_customization_repository_1 = require("./repositories/preference-customization.repository");
|
|
9
13
|
exports.commonProviders = [
|
|
14
|
+
{
|
|
15
|
+
provide: database_model_enum_1.DatabaseModel.AUDIT_TRAIL_MODEL,
|
|
16
|
+
useFactory: audit_trail_entity_1.auditTrailFactory,
|
|
17
|
+
inject: [
|
|
18
|
+
database_connection_enum_1.DatabaseConnection.CURRENT_CONNECTION,
|
|
19
|
+
database_connection_enum_1.DatabaseConnection.EVENT_CONNECTION,
|
|
20
|
+
database_connection_enum_1.DatabaseConnection.USER_CONNECTION,
|
|
21
|
+
],
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
provide: repository_provider_enum_1.RepositoryProvider.AUDIT_TRAIL_REPOSITORY,
|
|
25
|
+
inject: [database_model_enum_1.DatabaseModel.AUDIT_TRAIL_MODEL],
|
|
26
|
+
useFactory: (auditModel) => new audit_trail_repository_1.AuditTrailRepository(auditModel),
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
provide: service_provider_enum_1.ServiceProvider.AUDIT_TRAIL_SERVICE,
|
|
30
|
+
inject: [
|
|
31
|
+
repository_provider_enum_1.RepositoryProvider.AUDIT_TRAIL_REPOSITORY,
|
|
32
|
+
database_model_enum_1.DatabaseModel.USER_MODEL,
|
|
33
|
+
],
|
|
34
|
+
useFactory: (auditLogRepository, userModel) => new audit_trail_service_1.AuditTrailService(auditLogRepository, userModel),
|
|
35
|
+
},
|
|
10
36
|
{
|
|
11
37
|
provide: database_model_enum_1.DatabaseModel.PREFERENCE_CUSTOMIZATION_MODEL,
|
|
12
38
|
useFactory: preference_customization_entity_1.preferenceCustomizationFactory,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"common.provider.js","sourceRoot":"","sources":["../../../../src/entities/models/common/common.provider.ts"],"names":[],"mappings":";;;AAAA,4EAAkE;AAClE,sFAA4E;AAC5E,sFAA4E;
|
|
1
|
+
{"version":3,"file":"common.provider.js","sourceRoot":"","sources":["../../../../src/entities/models/common/common.provider.ts"],"names":[],"mappings":";;;AAAA,4EAAkE;AAClE,sFAA4E;AAC5E,sFAA4E;AAC5E,gFAAsE;AAEtE,sEAA6E;AAC7E,kFAA4E;AAC5E,wEAAkE;AAElE,gGAGmD;AACnD,4GAAsG;AAEzF,QAAA,eAAe,GAAG;IAC7B;QACE,OAAO,EAAE,mCAAa,CAAC,iBAAiB;QACxC,UAAU,EAAE,sCAAiB;QAC7B,MAAM,EAAE;YACN,6CAAkB,CAAC,kBAAkB;YACrC,6CAAkB,CAAC,gBAAgB;YACnC,6CAAkB,CAAC,eAAe;SACnC;KACF;IACD;QACE,OAAO,EAAE,6CAAkB,CAAC,sBAAsB;QAClD,MAAM,EAAE,CAAC,mCAAa,CAAC,iBAAiB,CAAC;QACzC,UAAU,EAAE,CAAC,UAAmC,EAAE,EAAE,CAClD,IAAI,6CAAoB,CAAC,UAAU,CAAC;KACvC;IACD;QACE,OAAO,EAAE,uCAAe,CAAC,mBAAmB;QAC5C,MAAM,EAAE;YACN,6CAAkB,CAAC,sBAAsB;YACzC,mCAAa,CAAC,UAAU;SACzB;QACD,UAAU,EAAE,CACV,kBAAwC,EACxC,SAA4B,EAC5B,EAAE,CAAC,IAAI,uCAAiB,CAAC,kBAAkB,EAAE,SAAS,CAAC;KAC1D;IAED;QACE,OAAO,EAAE,mCAAa,CAAC,8BAA8B;QACrD,UAAU,EAAE,gEAA8B;QAC1C,MAAM,EAAE;YACN,6CAAkB,CAAC,kBAAkB;YACrC,6CAAkB,CAAC,gBAAgB;YACnC,6CAAkB,CAAC,kBAAkB;SACtC;KACF;IACD;QACE,OAAO,EAAE,6CAAkB,CAAC,mCAAmC;QAC/D,MAAM,EAAE,CAAC,mCAAa,CAAC,8BAA8B,CAAC;QACtD,UAAU,EAAE,CACV,4BAAkE,EAClE,EAAE,CAAC,IAAI,uEAAiC,CAAC,4BAA4B,CAAC;KACzE;CACF,CAAA"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.EntityCommonModule = void 0;
|
|
10
|
+
const common_1 = require("@nestjs/common");
|
|
11
|
+
const config_1 = require("@nestjs/config");
|
|
12
|
+
const preference_customization_controller_1 = require("./controllers/preference-customization.controller");
|
|
13
|
+
let EntityCommonModule = class EntityCommonModule {
|
|
14
|
+
};
|
|
15
|
+
exports.EntityCommonModule = EntityCommonModule;
|
|
16
|
+
exports.EntityCommonModule = EntityCommonModule = __decorate([
|
|
17
|
+
(0, common_1.Global)(),
|
|
18
|
+
(0, common_1.Module)({
|
|
19
|
+
imports: [
|
|
20
|
+
config_1.ConfigModule.forRoot({
|
|
21
|
+
isGlobal: true,
|
|
22
|
+
}),
|
|
23
|
+
],
|
|
24
|
+
controllers: [preference_customization_controller_1.PreferenceCustomizationController],
|
|
25
|
+
providers: [],
|
|
26
|
+
exports: [],
|
|
27
|
+
})
|
|
28
|
+
], EntityCommonModule);
|
|
29
|
+
//# sourceMappingURL=entity.common.module.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"entity.common.module.js","sourceRoot":"","sources":["../../../../src/entities/models/common/entity.common.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAA+C;AAC/C,2CAA6C;AAC7C,2GAAsG;AAa/F,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;CAAG,CAAA;AAArB,gDAAkB;6BAAlB,kBAAkB;IAX9B,IAAA,eAAM,GAAE;IACR,IAAA,eAAM,EAAC;QACN,OAAO,EAAE;YACP,qBAAY,CAAC,OAAO,CAAC;gBACnB,QAAQ,EAAE,IAAI;aACf,CAAC;SACH;QACD,WAAW,EAAE,CAAC,uEAAiC,CAAC;QAChD,SAAS,EAAE,EAAE;QACb,OAAO,EAAE,EAAE;KACZ,CAAC;GACW,kBAAkB,CAAG"}
|
|
@@ -50,16 +50,6 @@
|
|
|
50
50
|
/// <reference types="mongoose/types/inferrawdoctype" />
|
|
51
51
|
/// <reference types="@aldb2b/common/node_modules/mongoose/types/inferschematype" />
|
|
52
52
|
export declare const modelProviders: ({
|
|
53
|
-
provide: import("../..").DatabaseModel;
|
|
54
|
-
useFactory: (connection: import("mongoose").Connection, eventConnection: import("mongoose").Connection, companyConnection: import("mongoose").Connection) => import("mongoose").Model<import("./common").PreferenceCustomization, {}, {}, {}, import("mongoose").Document<unknown, {}, import("./common").PreferenceCustomization> & import("./common").PreferenceCustomization & Required<{
|
|
55
|
-
_id: string;
|
|
56
|
-
}>, any>;
|
|
57
|
-
inject: import("../..").DatabaseConnection[];
|
|
58
|
-
} | {
|
|
59
|
-
provide: import("../..").RepositoryProvider;
|
|
60
|
-
inject: import("../..").DatabaseModel[];
|
|
61
|
-
useFactory: (preferenceCustomizationModel: import("../..").CustomModel<import("./common").PreferenceCustomization>) => import("./common").PreferenceCustomizationRepository;
|
|
62
|
-
} | {
|
|
63
53
|
provide: import("../..").DatabaseModel;
|
|
64
54
|
useFactory: (connection: import("mongoose").Connection, companyConnection: import("mongoose").Connection, eventConnection: import("mongoose").Connection) => import("mongoose").Model<import("./meetings").Meeting, {}, {}, {}, import("mongoose").Document<unknown, {}, import("./meetings").Meeting> & import("./meetings").Meeting & Required<{
|
|
65
55
|
_id: string;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.modelProviders = void 0;
|
|
4
|
-
const common_provider_1 = require("./common/common.provider");
|
|
5
4
|
const companies_1 = require("./companies");
|
|
6
5
|
const events_provider_1 = require("./events/events.provider");
|
|
7
6
|
const meetings_1 = require("./meetings");
|
|
@@ -13,6 +12,5 @@ exports.modelProviders = [
|
|
|
13
12
|
...users_provider_1.userProviders,
|
|
14
13
|
...meetings_1.meetingProviders,
|
|
15
14
|
...subscriptions_provider_1.subscriptionProviders,
|
|
16
|
-
...common_provider_1.commonProviders,
|
|
17
15
|
];
|
|
18
16
|
//# sourceMappingURL=model.providers.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"model.providers.js","sourceRoot":"","sources":["../../../src/entities/models/model.providers.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"model.providers.js","sourceRoot":"","sources":["../../../src/entities/models/model.providers.ts"],"names":[],"mappings":";;;AACA,2CAAgD;AAChD,8DAAyD;AACzD,yCAA6C;AAC7C,mFAA8E;AAC9E,2DAAsD;AAEzC,QAAA,cAAc,GAAG;IAC5B,GAAG,gCAAc;IACjB,GAAG,8BAAkB;IACrB,GAAG,8BAAa;IAChB,GAAG,2BAAgB;IACnB,GAAG,8CAAqB;CACzB,CAAA"}
|