@servicelabsco/nestjs-utility-services 1.1.55 → 1.1.57
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/auth/auth.module.js +2 -3
- package/dist/auth/auth.module.js.map +1 -1
- package/dist/auth/controllers/auth.controller.d.ts +1 -1
- package/dist/auth/controllers/auth.controller.js.map +1 -1
- package/dist/auth/controllers/social.controller.d.ts +1 -6
- package/dist/auth/controllers/social.controller.js +0 -44
- package/dist/auth/controllers/social.controller.js.map +1 -1
- package/dist/auth/dtos/user.access.dto.d.ts +1 -1
- package/dist/auth/es6.classes.d.ts +0 -3
- package/dist/auth/es6.classes.js +0 -3
- package/dist/auth/es6.classes.js.map +1 -1
- package/dist/auth/index.d.ts +0 -1
- package/dist/auth/index.js +0 -1
- package/dist/auth/index.js.map +1 -1
- package/dist/auth/services/index.d.ts +1 -0
- package/dist/auth/services/index.js +1 -0
- package/dist/auth/services/index.js.map +1 -1
- package/dist/common/es6.classes.d.ts +0 -2
- package/dist/common/es6.classes.js +0 -2
- package/dist/common/es6.classes.js.map +1 -1
- package/dist/common/exceptions/index.d.ts +1 -0
- package/dist/common/exceptions/index.js +1 -0
- package/dist/common/exceptions/index.js.map +1 -1
- package/dist/common/index.d.ts +0 -1
- package/dist/common/index.js +0 -1
- package/dist/common/index.js.map +1 -1
- package/dist/common/libraries/index.d.ts +1 -0
- package/dist/common/libraries/index.js +1 -0
- package/dist/common/libraries/index.js.map +1 -1
- package/dist/main.js +0 -2
- package/dist/main.js.map +1 -1
- package/dist/platformUtility/dtos/index.d.ts +3 -0
- package/dist/platformUtility/dtos/index.js +3 -0
- package/dist/platformUtility/dtos/index.js.map +1 -1
- package/dist/platformUtility/es6.classes.d.ts +1 -1
- package/dist/platformUtility/jobs/test.job.js.map +1 -1
- package/dist/platformUtility/services/index.d.ts +1 -0
- package/dist/platformUtility/services/index.js +1 -0
- package/dist/platformUtility/services/index.js.map +1 -1
- package/package.json +1 -6
- package/dist/auth/strategies/fb.strategy.d.ts +0 -10
- package/dist/auth/strategies/fb.strategy.js +0 -41
- package/dist/auth/strategies/fb.strategy.js.map +0 -1
- package/dist/auth/strategies/google.strategy.d.ts +0 -10
- package/dist/auth/strategies/google.strategy.js +0 -41
- package/dist/auth/strategies/google.strategy.js.map +0 -1
- package/dist/auth/strategies/index.d.ts +0 -2
- package/dist/auth/strategies/index.js +0 -19
- package/dist/auth/strategies/index.js.map +0 -1
- package/dist/common/guards/index.d.ts +0 -1
- package/dist/common/guards/index.js +0 -18
- package/dist/common/guards/index.js.map +0 -1
- package/dist/common/guards/login.guard.d.ts +0 -6
- package/dist/common/guards/login.guard.js +0 -24
- package/dist/common/guards/login.guard.js.map +0 -1
- package/dist/platformUtility/jobs/failed.bull.job.job.d.ts +0 -7
- package/dist/platformUtility/jobs/failed.bull.job.job.js +0 -29
- package/dist/platformUtility/jobs/failed.bull.job.job.js.map +0 -1
- package/dist/platformUtility/jobs/pending.bull.job.job.d.ts +0 -7
- package/dist/platformUtility/jobs/pending.bull.job.job.js +0 -29
- package/dist/platformUtility/jobs/pending.bull.job.job.js.map +0 -1
- package/dist/platformUtility/subscribers/failed.bull.job.subscriber.d.ts +0 -12
- package/dist/platformUtility/subscribers/failed.bull.job.subscriber.js +0 -40
- package/dist/platformUtility/subscribers/failed.bull.job.subscriber.js.map +0 -1
- package/dist/platformUtility/subscribers/pending.bull.job.subscriber.d.ts +0 -12
- package/dist/platformUtility/subscribers/pending.bull.job.subscriber.js +0 -40
- package/dist/platformUtility/subscribers/pending.bull.job.subscriber.js.map +0 -1
- package/dist/system/controllers/job.controller.d.ts +0 -16
- package/dist/system/controllers/job.controller.js +0 -137
- package/dist/system/controllers/job.controller.js.map +0 -1
package/dist/auth/auth.module.js
CHANGED
@@ -9,7 +9,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
9
|
exports.AuthModule = void 0;
|
10
10
|
const common_1 = require("@nestjs/common");
|
11
11
|
const jwt_1 = require("@nestjs/jwt");
|
12
|
-
const passport_1 = require("@nestjs/passport");
|
13
12
|
const typeorm_1 = require("@nestjs/typeorm");
|
14
13
|
const platform_utility_module_1 = require("../platformUtility/platform.utility.module");
|
15
14
|
const es6_classes_1 = require("./es6.classes");
|
@@ -18,8 +17,8 @@ let AuthModule = class AuthModule {
|
|
18
17
|
};
|
19
18
|
AuthModule = __decorate([
|
20
19
|
(0, common_1.Module)({
|
21
|
-
imports: [typeorm_1.TypeOrmModule.forFeature(es6_classes_1.default.entities),
|
22
|
-
providers: [...es6_classes_1.default.services
|
20
|
+
imports: [typeorm_1.TypeOrmModule.forFeature(es6_classes_1.default.entities), jwt_1.JwtModule.register(jwtConfig), (0, common_1.forwardRef)(() => platform_utility_module_1.PlatformUtilityModule)],
|
21
|
+
providers: [...es6_classes_1.default.services],
|
23
22
|
exports: [...es6_classes_1.default.services],
|
24
23
|
})
|
25
24
|
], AuthModule);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"auth.module.js","sourceRoot":"","sources":["../../src/auth/auth.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAAoD;AACpD,qCAAwC;AACxC
|
1
|
+
{"version":3,"file":"auth.module.js","sourceRoot":"","sources":["../../src/auth/auth.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAAoD;AACpD,qCAAwC;AACxC,6CAAgD;AAChD,wFAAmF;AACnF,+CAAuC;AACvC,kDAAmD;AAO5C,IAAM,UAAU,GAAhB,MAAM,UAAU;CAAG,CAAA;AAAb,UAAU;IALtB,IAAA,eAAM,EAAC;QACJ,OAAO,EAAE,CAAC,uBAAa,CAAC,UAAU,CAAC,qBAAU,CAAC,QAAQ,CAAC,EAAE,eAAS,CAAC,QAAQ,CAAC,SAAS,CAAC,EAAE,IAAA,mBAAU,EAAC,GAAG,EAAE,CAAC,+CAAqB,CAAC,CAAC;QAChI,SAAS,EAAE,CAAC,GAAG,qBAAU,CAAC,QAAQ,CAAC;QACnC,OAAO,EAAE,CAAC,GAAG,qBAAU,CAAC,QAAQ,CAAC;KACpC,CAAC;GACW,UAAU,CAAG;AAAb,gCAAU"}
|
@@ -12,7 +12,7 @@ export declare class AuthController {
|
|
12
12
|
constructor(authService: AuthService, userService: UserService, deviceTokenService: DeviceTokenService);
|
13
13
|
checkLogin(): Promise<UserAccessDto>;
|
14
14
|
login(body: UserLoginDto, req: Request): Promise<UserAccessDto>;
|
15
|
-
loginInfo(req: Request): Promise<any>;
|
15
|
+
loginInfo(req: Request | any): Promise<any>;
|
16
16
|
device(req: Request, body: DeviceTokenEntity): Promise<DeviceTokenEntity>;
|
17
17
|
getToken(req: Request, token: string): Promise<UserAccessDto>;
|
18
18
|
logout(req: Request): Promise<any[]>;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"auth.controller.js","sourceRoot":"","sources":["../../../src/auth/controllers/auth.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,2CAAyF;AACzF,+EAA2E;AAC3E,+FAAyF;AACzF,qFAAiF;AACjF,sDAAmD;AACnD,gEAA4D;AAE5D,2DAAsD;AACtD,yEAAoE;AACpE,2EAAsE;AACtE,yDAAqD;AACrD,2DAAuD;AACvD,2EAAsE;AACtE,2DAAuD;AAIhD,IAAM,cAAc,GAApB,MAAM,cAAc;IACvB,YACqB,WAAwB,EACxB,WAAwB,EACxB,kBAAsC;QAFtC,gBAAW,GAAX,WAAW,CAAa;QACxB,gBAAW,GAAX,WAAW,CAAa;QACxB,uBAAkB,GAAlB,kBAAkB,CAAoB;IACxD,CAAC;IAQE,AAAN,KAAK,CAAC,UAAU;QACZ,MAAM,IAAI,GAAG,WAAI,CAAC,IAAI,EAAE,CAAC;QACzB,IAAI,CAAC,IAAI;YAAE,MAAM,IAAI,gDAAqB,EAAE,CAAC;QAE7C,OAAO,IAAI,CAAC,WAAW,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;IAC9C,CAAC;IAUK,AAAN,KAAK,CAAC,KAAK,CAAS,IAAkB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a,CAAC,OAAO,CAAC,KAAK,EAAE,YAAY,EAAE,EAAE;YACzC,QAAQ,CAAC,IAAI,CAAC,YAAY,CAAC,UAAU,EAAE,CAAC,CAAC;QAC7C,CAAC,CAAC,CAAC;QAEH,OAAO,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE;YACtC,OAAO,GAAG,CAAC;QACf,CAAC,CAAC,CAAC;IACP,CAAC;CACJ,CAAA;AA5HS;IADL,IAAA,YAAG,GAAE;;;;gDAML;AAUK;IADL,IAAA,aAAI,EAAC,OAAO,CAAC;IACD,WAAA,IAAA,aAAI,GAAE,CAAA;IAAsB,WAAA,IAAA,YAAG,GAAE,CAAA;;qCAApB,6BAAY;;2CAWrC;AAWK;IADL,IAAA,YAAG,EAAC,MAAM,CAAC;IACK,WAAA,IAAA,YAAG,GAAE,CAAA;;;;+CAIrB;AASK;IADL,IAAA,aAAI,EAAC,QAAQ,CAAC;IACD,WAAA,IAAA,YAAG,GAAE,CAAA;IAAgB,WAAA,IAAA,aAAI,GAAE,CAAA;;6CAAO,uCAAiB;;4CAEhE;AAUK;IADL,IAAA,aAAI,EAAC,OAAO,CAAC;IACE,WAAA,IAAA,YAAG,GAAE,CAAA;IAAgB,WAAA,IAAA,aAAI,EAAC,eAAe,CAAC,CAAA;;;;8CA8BzD;AAQK;IADL,IAAA,aAAI,EAAC,QAAQ,CAAC;IACD,WAAA,IAAA,YAAG,GAAE,CAAA;;;;4CAuBlB;AAxIQ,cAAc;IAD1B,IAAA,mBAAU,EAAC,MAAM,CAAC;qCAGmB,0BAAW;QACX,0BAAW;QACJ,yCAAkB;GAJlD,cAAc,CAyI1B;AAzIY,wCAAc"}
|
@@ -1,15 +1,10 @@
|
|
1
|
-
|
1
|
+
import { Request } from 'express';
|
2
2
|
import { AuthService } from '../services/auth.service';
|
3
3
|
import { SocialService } from '../services/social.service';
|
4
|
-
import { Request } from 'express';
|
5
4
|
export declare class SocialController {
|
6
5
|
private readonly authService;
|
7
6
|
private readonly socialService;
|
8
7
|
constructor(authService: AuthService, socialService: SocialService);
|
9
|
-
socialGoogleLogin(): import("..").UserAccessDto;
|
10
|
-
socialGoogleCallback(req: Request): Express.User;
|
11
|
-
socialFbLogin(): import("..").UserAccessDto;
|
12
|
-
socialFbCallback(req: Request): Express.User;
|
13
8
|
fbLogin(req: Request, accessToken: string): Promise<any>;
|
14
9
|
googleLogin(req: Request, accessToken: string): Promise<any>;
|
15
10
|
}
|
@@ -14,8 +14,6 @@ var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
15
15
|
exports.SocialController = void 0;
|
16
16
|
const common_1 = require("@nestjs/common");
|
17
|
-
const passport_1 = require("@nestjs/passport");
|
18
|
-
const auth_1 = require("../../common/libraries/auth");
|
19
17
|
const auth_service_1 = require("../services/auth.service");
|
20
18
|
const social_service_1 = require("../services/social.service");
|
21
19
|
let SocialController = class SocialController {
|
@@ -23,18 +21,6 @@ let SocialController = class SocialController {
|
|
23
21
|
this.authService = authService;
|
24
22
|
this.socialService = socialService;
|
25
23
|
}
|
26
|
-
socialGoogleLogin() {
|
27
|
-
return auth_1.Auth.user();
|
28
|
-
}
|
29
|
-
socialGoogleCallback(req) {
|
30
|
-
return req.user;
|
31
|
-
}
|
32
|
-
socialFbLogin() {
|
33
|
-
return auth_1.Auth.user();
|
34
|
-
}
|
35
|
-
socialFbCallback(req) {
|
36
|
-
return req.user;
|
37
|
-
}
|
38
24
|
async fbLogin(req, accessToken) {
|
39
25
|
const user = await this.socialService.fbLogin(accessToken);
|
40
26
|
if (!user)
|
@@ -45,36 +31,6 @@ let SocialController = class SocialController {
|
|
45
31
|
return this.socialService.googleLogin(accessToken);
|
46
32
|
}
|
47
33
|
};
|
48
|
-
__decorate([
|
49
|
-
(0, common_1.UseGuards)((0, passport_1.AuthGuard)('google')),
|
50
|
-
(0, common_1.Get)('google'),
|
51
|
-
__metadata("design:type", Function),
|
52
|
-
__metadata("design:paramtypes", []),
|
53
|
-
__metadata("design:returntype", void 0)
|
54
|
-
], SocialController.prototype, "socialGoogleLogin", null);
|
55
|
-
__decorate([
|
56
|
-
(0, common_1.UseGuards)((0, passport_1.AuthGuard)('google')),
|
57
|
-
(0, common_1.Get)('google/callback'),
|
58
|
-
__param(0, (0, common_1.Req)()),
|
59
|
-
__metadata("design:type", Function),
|
60
|
-
__metadata("design:paramtypes", [Object]),
|
61
|
-
__metadata("design:returntype", void 0)
|
62
|
-
], SocialController.prototype, "socialGoogleCallback", null);
|
63
|
-
__decorate([
|
64
|
-
(0, common_1.UseGuards)((0, passport_1.AuthGuard)('facebook')),
|
65
|
-
(0, common_1.Get)('fb'),
|
66
|
-
__metadata("design:type", Function),
|
67
|
-
__metadata("design:paramtypes", []),
|
68
|
-
__metadata("design:returntype", void 0)
|
69
|
-
], SocialController.prototype, "socialFbLogin", null);
|
70
|
-
__decorate([
|
71
|
-
(0, common_1.UseGuards)((0, passport_1.AuthGuard)('facebook')),
|
72
|
-
(0, common_1.Get)('fb/callback'),
|
73
|
-
__param(0, (0, common_1.Req)()),
|
74
|
-
__metadata("design:type", Function),
|
75
|
-
__metadata("design:paramtypes", [Object]),
|
76
|
-
__metadata("design:returntype", void 0)
|
77
|
-
], SocialController.prototype, "socialFbCallback", null);
|
78
34
|
__decorate([
|
79
35
|
(0, common_1.Post)('fb'),
|
80
36
|
__param(0, (0, common_1.Req)()),
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"social.controller.js","sourceRoot":"","sources":["../../../src/auth/controllers/social.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,
|
1
|
+
{"version":3,"file":"social.controller.js","sourceRoot":"","sources":["../../../src/auth/controllers/social.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,2CAAoF;AAEpF,2DAAuD;AACvD,+DAA2D;AAGpD,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;IAOzB,YAA6B,WAAwB,EAAmB,aAA4B;QAAvE,gBAAW,GAAX,WAAW,CAAa;QAAmB,kBAAa,GAAb,aAAa,CAAe;IAAG,CAAC;IAGlG,AAAN,KAAK,CAAC,OAAO,CAAQ,GAAY,EAAwB,WAAmB;QACxE,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,aAAa,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC;QAC3D,IAAI,CAAC,IAAI;YAAE,MAAM,IAAI,8BAAqB,EAAE,CAAC;QAE7C,OAAO,IAAI,CAAC,WAAW,CAAC,gBAAgB,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;IACxD,CAAC;IAGK,AAAN,KAAK,CAAC,WAAW,CAAQ,GAAY,EAAwB,WAAmB;QAC5E,OAAO,IAAI,CAAC,aAAa,CAAC,WAAW,CAAC,WAAW,CAAC,CAAC;IACvD,CAAC;CACJ,CAAA;AAXS;IADL,IAAA,aAAI,EAAC,IAAI,CAAC;IACI,WAAA,IAAA,YAAG,GAAE,CAAA;IAAgB,WAAA,IAAA,aAAI,EAAC,cAAc,CAAC,CAAA;;;;+CAKvD;AAGK;IADL,IAAA,aAAI,EAAC,QAAQ,CAAC;IACI,WAAA,IAAA,YAAG,GAAE,CAAA;IAAgB,WAAA,IAAA,aAAI,EAAC,cAAc,CAAC,CAAA;;;;mDAE3D;AApBQ,gBAAgB;IAD5B,IAAA,mBAAU,EAAC,QAAQ,CAAC;qCAQyB,0BAAW,EAAkC,8BAAa;GAP3F,gBAAgB,CAqB5B;AArBY,4CAAgB"}
|
@@ -23,14 +23,11 @@ import { Es6Service } from './services/es6.service';
|
|
23
23
|
import { RefreshTokenService } from './services/refresh.token.service';
|
24
24
|
import { SocialService } from './services/social.service';
|
25
25
|
import { UserService } from './services/user.service';
|
26
|
-
import { FbStrategy } from './strategies/fb.strategy';
|
27
|
-
import { GoogleStrategy } from './strategies/google.strategy';
|
28
26
|
declare const es6Classes: {
|
29
27
|
controllers: (typeof AuthController | typeof SocialController | typeof UserController)[];
|
30
28
|
dtos: (typeof UserLoginDto | typeof CreateUserDto | typeof OfflineUserDto | typeof PermissionAssignmentDto | typeof RoleAssignmentDto | typeof UpdateUserDto)[];
|
31
29
|
entities: (typeof CreatorEntity | typeof CountryEntity | typeof UserReferralEntity | typeof DeviceTokenEntity | typeof RefreshTokenEntity)[];
|
32
30
|
middlewares: (typeof BasicAuthMiddleware | typeof JwtMiddleware | typeof RestrictedMiddleware | typeof InternalMiddleware)[];
|
33
31
|
services: (typeof RefreshTokenService | typeof AuthService | typeof DeviceTokenService | typeof UserService | typeof SocialService | typeof AccessManager | typeof Es6Service)[];
|
34
|
-
strategies: (typeof FbStrategy | typeof GoogleStrategy)[];
|
35
32
|
};
|
36
33
|
export default es6Classes;
|
package/dist/auth/es6.classes.js
CHANGED
@@ -27,15 +27,12 @@ const es6_service_1 = require("./services/es6.service");
|
|
27
27
|
const refresh_token_service_1 = require("./services/refresh.token.service");
|
28
28
|
const social_service_1 = require("./services/social.service");
|
29
29
|
const user_service_1 = require("./services/user.service");
|
30
|
-
const fb_strategy_1 = require("./strategies/fb.strategy");
|
31
|
-
const google_strategy_1 = require("./strategies/google.strategy");
|
32
30
|
const es6Classes = {
|
33
31
|
controllers: [auth_controller_1.AuthController, social_controller_1.SocialController, user_controller_1.UserController],
|
34
32
|
dtos: [create_user_dto_1.CreateUserDto, offline_user_dto_1.OfflineUserDto, permission_assignment_dto_1.PermissionAssignmentDto, role_assignment_dto_1.RoleAssignmentDto, update_user_dto_1.UpdateUserDto, user_access_dto_1.UserAccessDto, user_login_dto_1.UserLoginDto],
|
35
33
|
entities: [country_entity_1.CountryEntity, creator_entity_1.CreatorEntity, device_token_entity_1.DeviceTokenEntity, refresh_token_entity_1.RefreshTokenEntity, user_entity_1.UserEntity, user_referral_entity_1.UserReferralEntity],
|
36
34
|
middlewares: [basic_auth_middleware_1.BasicAuthMiddleware, internal_middleware_1.InternalMiddleware, jwt_middleware_1.JwtMiddleware, restricted_middleware_1.RestrictedMiddleware],
|
37
35
|
services: [access_manager_1.AccessManager, auth_service_1.AuthService, device_token_service_1.DeviceTokenService, es6_service_1.Es6Service, refresh_token_service_1.RefreshTokenService, social_service_1.SocialService, user_service_1.UserService],
|
38
|
-
strategies: [fb_strategy_1.FbStrategy, google_strategy_1.GoogleStrategy],
|
39
36
|
};
|
40
37
|
exports.default = es6Classes;
|
41
38
|
//# sourceMappingURL=es6.classes.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"es6.classes.js","sourceRoot":"","sources":["../../src/auth/es6.classes.ts"],"names":[],"mappings":";;AAAA,mEAA+D;AAC/D,uEAAmE;AACnE,mEAA+D;AAC/D,4DAAuD;AACvD,8DAAyD;AACzD,gFAA2E;AAC3E,oEAA+D;AAC/D,4DAAuD;AACvD,4DAAuD;AACvD,0DAAqD;AACrD,8DAA0D;AAC1D,8DAA0D;AAC1D,wEAAmE;AACnE,0EAAqE;AACrE,wDAAoD;AACpD,0EAAqE;AACrE,+EAA0E;AAC1E,2EAAuE;AACvE,iEAA6D;AAC7D,+EAA2E;AAC3E,8DAA0D;AAC1D,0DAAsD;AACtD,0EAAqE;AACrE,wDAAoD;AACpD,4EAAuE;AACvE,8DAA0D;AAC1D,0DAAsD;
|
1
|
+
{"version":3,"file":"es6.classes.js","sourceRoot":"","sources":["../../src/auth/es6.classes.ts"],"names":[],"mappings":";;AAAA,mEAA+D;AAC/D,uEAAmE;AACnE,mEAA+D;AAC/D,4DAAuD;AACvD,8DAAyD;AACzD,gFAA2E;AAC3E,oEAA+D;AAC/D,4DAAuD;AACvD,4DAAuD;AACvD,0DAAqD;AACrD,8DAA0D;AAC1D,8DAA0D;AAC1D,wEAAmE;AACnE,0EAAqE;AACrE,wDAAoD;AACpD,0EAAqE;AACrE,+EAA0E;AAC1E,2EAAuE;AACvE,iEAA6D;AAC7D,+EAA2E;AAC3E,8DAA0D;AAC1D,0DAAsD;AACtD,0EAAqE;AACrE,wDAAoD;AACpD,4EAAuE;AACvE,8DAA0D;AAC1D,0DAAsD;AAEtD,MAAM,UAAU,GAAG;IACf,WAAW,EAAE,CAAC,gCAAc,EAAE,oCAAgB,EAAE,gCAAc,CAAC;IAC/D,IAAI,EAAE,CAAC,+BAAa,EAAE,iCAAc,EAAE,mDAAuB,EAAE,uCAAiB,EAAE,+BAAa,EAAE,+BAAa,EAAE,6BAAY,CAAC;IAC7H,QAAQ,EAAE,CAAC,8BAAa,EAAE,8BAAa,EAAE,uCAAiB,EAAE,yCAAkB,EAAE,wBAAU,EAAE,yCAAkB,CAAC;IAC/G,WAAW,EAAE,CAAC,2CAAmB,EAAE,wCAAkB,EAAE,8BAAa,EAAE,4CAAoB,CAAC;IAC3F,QAAQ,EAAE,CAAC,8BAAa,EAAE,0BAAW,EAAE,yCAAkB,EAAE,wBAAU,EAAE,2CAAmB,EAAE,8BAAa,EAAE,0BAAW,CAAC;CAC1H,CAAC;AAEF,kBAAe,UAAU,CAAC"}
|
package/dist/auth/index.d.ts
CHANGED
package/dist/auth/index.js
CHANGED
@@ -19,6 +19,5 @@ __exportStar(require("./dtos"), exports);
|
|
19
19
|
__exportStar(require("./entities"), exports);
|
20
20
|
__exportStar(require("./middlewares"), exports);
|
21
21
|
__exportStar(require("./services"), exports);
|
22
|
-
__exportStar(require("./strategies"), exports);
|
23
22
|
__exportStar(require("./auth.module"), exports);
|
24
23
|
//# sourceMappingURL=index.js.map
|
package/dist/auth/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/auth/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,yCAAuB;AACvB,6CAA2B;AAC3B,gDAA8B;AAC9B,6CAA2B;AAC3B
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/auth/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,yCAAuB;AACvB,6CAA2B;AAC3B,gDAA8B;AAC9B,6CAA2B;AAC3B,gDAA8B"}
|
@@ -20,4 +20,5 @@ __exportStar(require("./device.token.service"), exports);
|
|
20
20
|
__exportStar(require("./refresh.token.service"), exports);
|
21
21
|
__exportStar(require("./social.service"), exports);
|
22
22
|
__exportStar(require("./user.service"), exports);
|
23
|
+
__exportStar(require("./es6.service"), exports);
|
23
24
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/auth/services/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mDAAiC;AACjC,iDAA+B;AAC/B,yDAAuC;AACvC,0DAAwC;AACxC,mDAAiC;AACjC,iDAA+B"}
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/auth/services/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mDAAiC;AACjC,iDAA+B;AAC/B,yDAAuC;AACvC,0DAAwC;AACxC,mDAAiC;AACjC,iDAA+B;AAC/B,gDAA8B"}
|
@@ -16,7 +16,6 @@ import { RenameColumnDto } from './dtos/rename.column.dto';
|
|
16
16
|
import { ReportBodyDto } from './dtos/report.body.dto';
|
17
17
|
import { ReportDataManagerDto } from './dtos/report.data.manager.dto';
|
18
18
|
import { AccessException } from './exceptions/access.exception';
|
19
|
-
import { LoginGuard } from './guards/login.guard';
|
20
19
|
import { BaseMigrationUtility } from './libraries/base.migration.utility';
|
21
20
|
import { CommonConsumer } from './libraries/common.consumer';
|
22
21
|
import { DataManager } from './libraries/data.manager';
|
@@ -30,7 +29,6 @@ import { SeederUtility } from './libraries/seeder.utility';
|
|
30
29
|
declare const es6Classes: {
|
31
30
|
dtos: (typeof AggregationParamDto | typeof CaptureRecordIndexDto | typeof CaptureRecordShowDto | typeof LayoutColumnDbDto | typeof GenericIndexParamDto | typeof RecordDataManagerDto | typeof RecordTabDto | typeof GroupParamDto | typeof ReportBodyDto | typeof ReportDataManagerDto | typeof MetaDataDto | typeof DatabaseEventDto | typeof ForeignMigrationDto | typeof GenericShowParamDto | typeof IndexColumnDto | typeof KeyValueParamDto | typeof RenameColumnDto)[];
|
32
31
|
exceptions: (typeof AccessException)[];
|
33
|
-
guards: (typeof LoginGuard)[];
|
34
32
|
libraries: (typeof GenericIndexParser | typeof GenericShowParser | typeof DataManager | typeof ListManager | typeof RecordManager | typeof ReportDataManager | typeof ReportListManager | typeof BaseMigrationUtility | typeof CommonConsumer | typeof SeederUtility)[];
|
35
33
|
};
|
36
34
|
export default es6Classes;
|
@@ -23,7 +23,6 @@ const maintenance_exception_1 = require("./exceptions/maintenance.exception");
|
|
23
23
|
const no_logged_user_exception_1 = require("./exceptions/no.logged.user.exception");
|
24
24
|
const operation_exception_1 = require("./exceptions/operation.exception");
|
25
25
|
const subscription_exception_1 = require("./exceptions/subscription.exception");
|
26
|
-
const login_guard_1 = require("./guards/login.guard");
|
27
26
|
const auth_1 = require("./libraries/auth");
|
28
27
|
const base_migration_utility_1 = require("./libraries/base.migration.utility");
|
29
28
|
const class_mapper_1 = require("./libraries/class.mapper");
|
@@ -69,7 +68,6 @@ const es6Classes = {
|
|
69
68
|
report_data_manager_dto_1.ReportDataManagerDto,
|
70
69
|
],
|
71
70
|
exceptions: [access_exception_1.AccessException, maintenance_exception_1.MaintenanceException, no_logged_user_exception_1.NoLoggedUserException, operation_exception_1.OperationException, subscription_exception_1.SubscriptionException],
|
72
|
-
guards: [login_guard_1.LoginGuard],
|
73
71
|
libraries: [
|
74
72
|
auth_1.Auth,
|
75
73
|
base_migration_utility_1.BaseMigrationUtility,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"es6.classes.js","sourceRoot":"","sources":["../../src/common/es6.classes.ts"],"names":[],"mappings":";;AAAA,wEAAmE;AACnE,8EAAwE;AACxE,4EAAsE;AACtE,kEAA6D;AAC7D,wEAAmE;AACnE,4EAAsE;AACtE,0EAAoE;AACpE,4DAAuD;AACvD,8DAAyD;AACzD,8DAAyD;AACzD,oEAA8D;AAC9D,sEAAgE;AAChE,wDAAmD;AACnD,4EAAsE;AACtE,0DAAqD;AACrD,gEAA2D;AAC3D,4DAAuD;AACvD,4EAAsE;AACtE,oEAAgE;AAChE,8EAA0E;AAC1E,oFAA8E;AAC9E,0EAAsE;AACtE,gFAA4E;AAC5E,
|
1
|
+
{"version":3,"file":"es6.classes.js","sourceRoot":"","sources":["../../src/common/es6.classes.ts"],"names":[],"mappings":";;AAAA,wEAAmE;AACnE,8EAAwE;AACxE,4EAAsE;AACtE,kEAA6D;AAC7D,wEAAmE;AACnE,4EAAsE;AACtE,0EAAoE;AACpE,4DAAuD;AACvD,8DAAyD;AACzD,8DAAyD;AACzD,oEAA8D;AAC9D,sEAAgE;AAChE,wDAAmD;AACnD,4EAAsE;AACtE,0DAAqD;AACrD,gEAA2D;AAC3D,4DAAuD;AACvD,4EAAsE;AACtE,oEAAgE;AAChE,8EAA0E;AAC1E,oFAA8E;AAC9E,0EAAsE;AACtE,gFAA4E;AAC5E,2CAAwC;AACxC,+EAA0E;AAC1E,2DAAuD;AACvD,iEAA6D;AAC7D,6DAAyD;AACzD,uDAAmD;AACnD,qEAAgE;AAChE,qEAAiE;AACjE,2DAAuD;AACvD,2DAAuD;AACvD,qDAAiD;AACjD,2EAAsE;AACtE,yEAAoE;AACpE,2CAAwC;AACxC,2DAAuD;AACvD,qEAAiE;AACjE,mEAA+D;AAC/D,+DAA2D;AAC3D,uEAAkE;AAClE,yEAAoE;AACpE,yEAAoE;AACpE,qFAAgF;AAChF,+DAA2D;AAE3D,MAAM,UAAU,GAAG;IACf,IAAI,EAAE;QACF,2CAAmB;QACnB,gDAAqB;QACrB,8CAAoB;QACpB,qCAAgB;QAChB,2CAAmB;QACnB,8CAAoB;QACpB,4CAAmB;QACnB,+BAAa;QACb,iCAAc;QACd,iCAAc;QACd,sCAAgB;QAChB,wCAAiB;QACjB,2BAAW;QACX,8CAAoB;QACpB,6BAAY;QACZ,mCAAe;QACf,+BAAa;QACb,8CAAoB;KACvB;IACD,UAAU,EAAE,CAAC,kCAAe,EAAE,4CAAoB,EAAE,gDAAqB,EAAE,wCAAkB,EAAE,8CAAqB,CAAC;IACrH,SAAS,EAAE;QACP,WAAI;QACJ,6CAAoB;QACpB,0BAAW;QACX,gCAAc;QACd,4BAAY;QACZ,sBAAS;QACT,mCAAe;QACf,oCAAgB;QAChB,0BAAW;QACX,0BAAW;QACX,oBAAQ;QACR,yCAAkB;QAClB,uCAAiB;QACjB,WAAI;QACJ,0BAAW;QACX,oCAAgB;QAChB,kCAAe;QACf,8BAAa;QACb,qCAAgB;QAChB,uCAAiB;QACjB,uCAAiB;QACjB,mDAAuB;QACvB,8BAAa;KAChB;CACJ,CAAC;AAEF,kBAAe,UAAU,CAAC"}
|
@@ -18,4 +18,5 @@ __exportStar(require("./access.exception"), exports);
|
|
18
18
|
__exportStar(require("./maintenance.exception"), exports);
|
19
19
|
__exportStar(require("./no.logged.user.exception"), exports);
|
20
20
|
__exportStar(require("./operation.exception"), exports);
|
21
|
+
__exportStar(require("./subscription.exception"), exports);
|
21
22
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/common/exceptions/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qDAAmC;AACnC,0DAAwC;AACxC,6DAA2C;AAC3C,wDAAsC"}
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/common/exceptions/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qDAAmC;AACnC,0DAAwC;AACxC,6DAA2C;AAC3C,wDAAsC;AACtC,2DAAyC"}
|
package/dist/common/index.d.ts
CHANGED
package/dist/common/index.js
CHANGED
@@ -16,7 +16,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
17
17
|
__exportStar(require("./dtos"), exports);
|
18
18
|
__exportStar(require("./exceptions"), exports);
|
19
|
-
__exportStar(require("./guards"), exports);
|
20
19
|
__exportStar(require("./libraries"), exports);
|
21
20
|
__exportStar(require("./common.module"), exports);
|
22
21
|
//# sourceMappingURL=index.js.map
|
package/dist/common/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/common/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yCAAuB;AACvB,+CAA6B;AAC7B,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/common/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yCAAuB;AACvB,+CAA6B;AAC7B,8CAA4B;AAC5B,kDAAgC"}
|
@@ -37,4 +37,5 @@ __exportStar(require("./report.data.manager"), exports);
|
|
37
37
|
__exportStar(require("./report.list.manager"), exports);
|
38
38
|
__exportStar(require("./reverse.migration.utility"), exports);
|
39
39
|
__exportStar(require("./seeder.utility"), exports);
|
40
|
+
__exportStar(require("./base.job.interface"), exports);
|
40
41
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/common/libraries/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yCAAuB;AACvB,2DAAyC;AACzC,iDAA+B;AAC/B,oDAAkC;AAClC,kDAAgC;AAChC,+CAA6B;AAC7B,sDAAoC;AACpC,sDAAoC;AACpC,iDAA+B;AAC/B,iDAA+B;AAC/B,8CAA4B;AAC5B,yDAAuC;AACvC,wDAAsC;AACtC,yCAAuB;AACvB,iDAA+B;AAC/B,sDAAoC;AACpC,qDAAmC;AACnC,mDAAiC;AACjC,uDAAqC;AACrC,wDAAsC;AACtC,wDAAsC;AACtC,8DAA4C;AAC5C,mDAAiC"}
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/common/libraries/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yCAAuB;AACvB,2DAAyC;AACzC,iDAA+B;AAC/B,oDAAkC;AAClC,kDAAgC;AAChC,+CAA6B;AAC7B,sDAAoC;AACpC,sDAAoC;AACpC,iDAA+B;AAC/B,iDAA+B;AAC/B,8CAA4B;AAC5B,yDAAuC;AACvC,wDAAsC;AACtC,yCAAuB;AACvB,iDAA+B;AAC/B,sDAAoC;AACpC,qDAAmC;AACnC,mDAAiC;AACjC,uDAAqC;AACrC,wDAAsC;AACtC,wDAAsC;AACtC,8DAA4C;AAC5C,mDAAiC;AACjC,uDAAqC"}
|
package/dist/main.js
CHANGED
@@ -8,7 +8,6 @@ const config = require("config");
|
|
8
8
|
const httpContext = require("express-http-context");
|
9
9
|
const express_rate_limit_1 = require("express-rate-limit");
|
10
10
|
const helmet_1 = require("helmet");
|
11
|
-
const passport = require("passport");
|
12
11
|
require("source-map-support/register");
|
13
12
|
const app_module_1 = require("./app.module");
|
14
13
|
const corsConfig = require("./config/cors.config");
|
@@ -18,7 +17,6 @@ require('source-map-support').install();
|
|
18
17
|
Error.stackTraceLimit = 100;
|
19
18
|
async function bootstrap() {
|
20
19
|
const app = await core_1.NestFactory.create(app_module_1.AppModule);
|
21
|
-
app.use(passport.initialize());
|
22
20
|
app.use(bodyParser.json());
|
23
21
|
app.use(httpContext.middleware);
|
24
22
|
app.use((0, helmet_1.default)());
|
package/dist/main.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"main.js","sourceRoot":"","sources":["../src/main.ts"],"names":[],"mappings":";;AAAA,2CAAgD;AAChD,uCAA2C;AAC3C,0CAA0C;AAC1C,2CAA2C;AAC3C,iCAAiC;AACjC,oDAAoD;AACpD,2DAA2C;AAC3C,mCAA4B;AAC5B,
|
1
|
+
{"version":3,"file":"main.js","sourceRoot":"","sources":["../src/main.ts"],"names":[],"mappings":";;AAAA,2CAAgD;AAChD,uCAA2C;AAC3C,0CAA0C;AAC1C,2CAA2C;AAC3C,iCAAiC;AACjC,oDAAoD;AACpD,2D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|
@@ -5,3 +5,6 @@ export * from './queue.options.dto';
|
|
5
5
|
export * from './mail.options.dto';
|
6
6
|
export * from './common.attributes.dto';
|
7
7
|
export * from './remote.raw.response.dto';
|
8
|
+
export * from './failed.bull.job.attributes.dto';
|
9
|
+
export * from './pending.bull.job.attributes.dto';
|
10
|
+
export * from './job.payload.dto';
|
@@ -21,4 +21,7 @@ __exportStar(require("./queue.options.dto"), exports);
|
|
21
21
|
__exportStar(require("./mail.options.dto"), exports);
|
22
22
|
__exportStar(require("./common.attributes.dto"), exports);
|
23
23
|
__exportStar(require("./remote.raw.response.dto"), exports);
|
24
|
+
__exportStar(require("./failed.bull.job.attributes.dto"), exports);
|
25
|
+
__exportStar(require("./pending.bull.job.attributes.dto"), exports);
|
26
|
+
__exportStar(require("./job.payload.dto"), exports);
|
24
27
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/platformUtility/dtos/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qDAAmC;AACnC,mEAAiD;AACjD,mEAAiD;AACjD,sDAAoC;AACpC,qDAAmC;AACnC,0DAAwC;AACxC,4DAA0C"}
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/platformUtility/dtos/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qDAAmC;AACnC,mEAAiD;AACjD,mEAAiD;AACjD,sDAAoC;AACpC,qDAAmC;AACnC,0DAAwC;AACxC,4DAA0C;AAC1C,mEAAiD;AACjD,oEAAkD;AAClD,oDAAkC"}
|
@@ -57,7 +57,7 @@ declare const es6Classes: {
|
|
57
57
|
jobs: (typeof LoadFailedBullJob | typeof RecordWatcherJob | typeof ReloadPendingBullJob | typeof TestJob)[];
|
58
58
|
libraries: (typeof FileSystemUtility | typeof CommonSqsPolling | typeof CreateEntityConstantsFile | typeof CreateEs6ClassesFile | typeof CreateEs6JobsFile | typeof CreateEs6ServiceFile | typeof CreateIndexFile | typeof ProcessCommonMail | typeof ProcessPostmarkMail | typeof ProcessSmtpMail)[];
|
59
59
|
middlewares: (typeof MaintenanceMiddleware | typeof TrimPipe)[];
|
60
|
-
services: (typeof CacheService | typeof RemoteRequestService | typeof SqlService | typeof DynamoService | typeof MaintenanceService | typeof ShutdownService | typeof AuditService | typeof FcmNotificationService | typeof MailService | typeof StartupService | typeof
|
60
|
+
services: (typeof CacheService | typeof RemoteRequestService | typeof SqlService | typeof DynamoService | typeof MaintenanceService | typeof ShutdownService | typeof AuditService | typeof FcmNotificationService | typeof MailService | typeof StartupService | typeof SqsService | typeof Es6JobsService | typeof Es6Service | typeof LocalPropertyService | typeof QueueService)[];
|
61
61
|
subscribers: (typeof BaseSubscriber)[];
|
62
62
|
};
|
63
63
|
export default es6Classes;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"test.job.js","sourceRoot":"","sources":["../../../src/platformUtility/jobs/test.job.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAA4C;AAC5C,oEAAgE;AAChE,+DAA2D;
|
1
|
+
{"version":3,"file":"test.job.js","sourceRoot":"","sources":["../../../src/platformUtility/jobs/test.job.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAA4C;AAC5C,oEAAgE;AAChE,+DAA2D;AAGpD,IAAM,OAAO,GAAb,MAAM,OAAQ,SAAQ,sBAAS;IAGlC,YAA+B,YAA0B;QACrD,KAAK,EAAE,CAAC;QADmB,iBAAY,GAAZ,YAAY,CAAc;IAEzD,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,IAAS;IAEtB,CAAC;CACJ,CAAA;AAVY,OAAO;IADnB,IAAA,mBAAU,GAAE;qCAIoC,4BAAY;GAHhD,OAAO,CAUnB;AAVY,0BAAO"}
|
@@ -26,4 +26,5 @@ __exportStar(require("./remote.request.service"), exports);
|
|
26
26
|
__exportStar(require("./shutdown.service"), exports);
|
27
27
|
__exportStar(require("./sql.service"), exports);
|
28
28
|
__exportStar(require("./startup.service"), exports);
|
29
|
+
__exportStar(require("./sqs.service"), exports);
|
29
30
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/platformUtility/services/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,kDAAgC;AAChC,kDAAgC;AAChC,mDAAiC;AACjC,6DAA2C;AAC3C,2DAAyC;AACzC,iDAA+B;AAC/B,wDAAsC;AACtC,kDAAgC;AAChC,2DAAyC;AACzC,qDAAmC;AACnC,gDAA8B;AAC9B,oDAAkC"}
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/platformUtility/services/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,kDAAgC;AAChC,kDAAgC;AAChC,mDAAiC;AACjC,6DAA2C;AAC3C,2DAAyC;AACzC,iDAA+B;AAC/B,wDAAsC;AACtC,kDAAgC;AAChC,2DAAyC;AACzC,qDAAmC;AACnC,gDAA8B;AAC9B,oDAAkC;AAClC,gDAA8B"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@servicelabsco/nestjs-utility-services",
|
3
|
-
"version": "1.1.
|
3
|
+
"version": "1.1.57",
|
4
4
|
"description": "NestJS generic packages to support development",
|
5
5
|
"author": "Hemant Kumar Sah <hemantanshu@gmail.com>",
|
6
6
|
"license": "MIT",
|
@@ -54,7 +54,6 @@
|
|
54
54
|
"@nestjs/common": "^9.0.0",
|
55
55
|
"@nestjs/core": "^9.0.0",
|
56
56
|
"@nestjs/jwt": "^10.0.2",
|
57
|
-
"@nestjs/passport": "^9.0.0",
|
58
57
|
"@nestjs/platform-express": "^9.0.0",
|
59
58
|
"@nestjs/platform-socket.io": "^9.0.7",
|
60
59
|
"@nestjs/swagger": "^6.0.4",
|
@@ -80,9 +79,6 @@
|
|
80
79
|
"nestjs-console": "^8.0.0",
|
81
80
|
"nodemailer": "^6.9.1",
|
82
81
|
"parse-bearer-token": "^1.0.1",
|
83
|
-
"passport": "^0.6.0",
|
84
|
-
"passport-facebook": "^3.0.0",
|
85
|
-
"passport-google-oauth20": "^2.0.0",
|
86
82
|
"pg": "^8.7.3",
|
87
83
|
"postmark": "^3.0.12",
|
88
84
|
"prompt-sync": "^4.2.0",
|
@@ -104,7 +100,6 @@
|
|
104
100
|
"@types/jest": "^28.1.4",
|
105
101
|
"@types/multer": "^1.4.7",
|
106
102
|
"@types/node": "^18.6.3",
|
107
|
-
"@types/passport-local": "^1.0.34",
|
108
103
|
"@types/supertest": "^2.0.12",
|
109
104
|
"@typescript-eslint/eslint-plugin": "^5.30.5",
|
110
105
|
"@typescript-eslint/parser": "^5.30.5",
|
@@ -1,10 +0,0 @@
|
|
1
|
-
import { AuthService } from '../services/auth.service';
|
2
|
-
import { UserService } from '../services/user.service';
|
3
|
-
declare const FbStrategy_base: new (...args: any[]) => any;
|
4
|
-
export declare class FbStrategy extends FbStrategy_base {
|
5
|
-
private readonly authService;
|
6
|
-
private readonly userService;
|
7
|
-
constructor(authService: AuthService, userService: UserService);
|
8
|
-
validate(request: any, accessToken: string, profile: any, done: any): Promise<import("..").UserAccessDto>;
|
9
|
-
}
|
10
|
-
export {};
|
@@ -1,41 +0,0 @@
|
|
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
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
10
|
-
};
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
12
|
-
exports.FbStrategy = void 0;
|
13
|
-
const common_1 = require("@nestjs/common");
|
14
|
-
const passport_1 = require("@nestjs/passport");
|
15
|
-
const passport_facebook_1 = require("passport-facebook");
|
16
|
-
const auth_service_1 = require("../services/auth.service");
|
17
|
-
const user_service_1 = require("../services/user.service");
|
18
|
-
const fbConfig = require("../../config/fb.config");
|
19
|
-
let FbStrategy = class FbStrategy extends (0, passport_1.PassportStrategy)(passport_facebook_1.Strategy, 'facebook') {
|
20
|
-
constructor(authService, userService) {
|
21
|
-
super(fbConfig);
|
22
|
-
this.authService = authService;
|
23
|
-
this.userService = userService;
|
24
|
-
}
|
25
|
-
async validate(request, accessToken, profile, done) {
|
26
|
-
const email = profile.emails[0].value;
|
27
|
-
const name = profile.name;
|
28
|
-
const user = await this.userService.createUser({
|
29
|
-
name,
|
30
|
-
email,
|
31
|
-
password: '',
|
32
|
-
});
|
33
|
-
return this.authService.getUserObject(user.id);
|
34
|
-
}
|
35
|
-
};
|
36
|
-
FbStrategy = __decorate([
|
37
|
-
(0, common_1.Injectable)(),
|
38
|
-
__metadata("design:paramtypes", [auth_service_1.AuthService, user_service_1.UserService])
|
39
|
-
], FbStrategy);
|
40
|
-
exports.FbStrategy = FbStrategy;
|
41
|
-
//# sourceMappingURL=fb.strategy.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"fb.strategy.js","sourceRoot":"","sources":["../../../src/auth/strategies/fb.strategy.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAA4C;AAC5C,+CAAoD;AACpD,yDAA6C;AAC7C,2DAAuD;AACvD,2DAAuD;AACvD,mDAAoD;AAG7C,IAAM,UAAU,GAAhB,MAAM,UAAW,SAAQ,IAAA,2BAAgB,EAAC,4BAAQ,EAAE,UAAU,CAAC;IAMlE,YAA6B,WAAwB,EAAmB,WAAwB;QAC5F,KAAK,CAAC,QAAQ,CAAC,CAAC;QADS,gBAAW,GAAX,WAAW,CAAa;QAAmB,gBAAW,GAAX,WAAW,CAAa;IAEhG,CAAC;IAWD,KAAK,CAAC,QAAQ,CAAC,OAAY,EAAE,WAAmB,EAAE,OAAO,EAAE,IAAS;QAChE,MAAM,KAAK,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC;QACtC,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC;QAG1B,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,WAAW,CAAC,UAAU,CAAC;YAC3C,IAAI;YACJ,KAAK;YACL,QAAQ,EAAE,EAAE;SACf,CAAC,CAAC;QAGH,OAAO,IAAI,CAAC,WAAW,CAAC,aAAa,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACnD,CAAC;CACJ,CAAA;AAjCY,UAAU;IADtB,IAAA,mBAAU,GAAE;qCAOiC,0BAAW,EAAgC,0BAAW;GANvF,UAAU,CAiCtB;AAjCY,gCAAU"}
|
@@ -1,10 +0,0 @@
|
|
1
|
-
import { AuthService } from '../services/auth.service';
|
2
|
-
import { UserService } from '../services/user.service';
|
3
|
-
declare const GoogleStrategy_base: new (...args: any[]) => any;
|
4
|
-
export declare class GoogleStrategy extends GoogleStrategy_base {
|
5
|
-
private readonly authService;
|
6
|
-
private readonly userService;
|
7
|
-
constructor(authService: AuthService, userService: UserService);
|
8
|
-
validate(request: any, accessToken: string, profile: any, done: any): Promise<import("..").UserAccessDto>;
|
9
|
-
}
|
10
|
-
export {};
|
@@ -1,41 +0,0 @@
|
|
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
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
10
|
-
};
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
12
|
-
exports.GoogleStrategy = void 0;
|
13
|
-
const common_1 = require("@nestjs/common");
|
14
|
-
const passport_1 = require("@nestjs/passport");
|
15
|
-
const passport_google_oauth20_1 = require("passport-google-oauth20");
|
16
|
-
const auth_service_1 = require("../services/auth.service");
|
17
|
-
const user_service_1 = require("../services/user.service");
|
18
|
-
const googleConfig = require("../../config/google.config");
|
19
|
-
let GoogleStrategy = class GoogleStrategy extends (0, passport_1.PassportStrategy)(passport_google_oauth20_1.Strategy, 'google') {
|
20
|
-
constructor(authService, userService) {
|
21
|
-
super(googleConfig);
|
22
|
-
this.authService = authService;
|
23
|
-
this.userService = userService;
|
24
|
-
}
|
25
|
-
async validate(request, accessToken, profile, done) {
|
26
|
-
const email = profile.emails[0].value;
|
27
|
-
const name = profile.name;
|
28
|
-
const user = await this.userService.createUser({
|
29
|
-
name,
|
30
|
-
email,
|
31
|
-
password: '',
|
32
|
-
});
|
33
|
-
return this.authService.getUserObject(user.id);
|
34
|
-
}
|
35
|
-
};
|
36
|
-
GoogleStrategy = __decorate([
|
37
|
-
(0, common_1.Injectable)(),
|
38
|
-
__metadata("design:paramtypes", [auth_service_1.AuthService, user_service_1.UserService])
|
39
|
-
], GoogleStrategy);
|
40
|
-
exports.GoogleStrategy = GoogleStrategy;
|
41
|
-
//# sourceMappingURL=google.strategy.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"google.strategy.js","sourceRoot":"","sources":["../../../src/auth/strategies/google.strategy.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAA4C;AAC5C,+CAAoD;AACpD,qEAAmD;AACnD,2DAAuD;AACvD,2DAAuD;AACvD,2DAA4D;AASrD,IAAM,cAAc,GAApB,MAAM,cAAe,SAAQ,IAAA,2BAAgB,EAAC,kCAAQ,EAAE,QAAQ,CAAC;IAMpE,YAA6B,WAAwB,EAAmB,WAAwB;QAC5F,KAAK,CAAC,YAAY,CAAC,CAAC;QADK,gBAAW,GAAX,WAAW,CAAa;QAAmB,gBAAW,GAAX,WAAW,CAAa;IAEhG,CAAC;IAYD,KAAK,CAAC,QAAQ,CAAC,OAAY,EAAE,WAAmB,EAAE,OAAO,EAAE,IAAS;QAChE,MAAM,KAAK,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC;QACtC,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC;QAG1B,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,WAAW,CAAC,UAAU,CAAC;YAC3C,IAAI;YACJ,KAAK;YACL,QAAQ,EAAE,EAAE;SACf,CAAC,CAAC;QAGH,OAAO,IAAI,CAAC,WAAW,CAAC,aAAa,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACnD,CAAC;CACJ,CAAA;AAlCY,cAAc;IAD1B,IAAA,mBAAU,GAAE;qCAOiC,0BAAW,EAAgC,0BAAW;GANvF,cAAc,CAkC1B;AAlCY,wCAAc"}
|
@@ -1,19 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
3
|
-
if (k2 === undefined) k2 = k;
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
7
|
-
}
|
8
|
-
Object.defineProperty(o, k2, desc);
|
9
|
-
}) : (function(o, m, k, k2) {
|
10
|
-
if (k2 === undefined) k2 = k;
|
11
|
-
o[k2] = m[k];
|
12
|
-
}));
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
|
-
};
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
-
__exportStar(require("./fb.strategy"), exports);
|
18
|
-
__exportStar(require("./google.strategy"), exports);
|
19
|
-
//# sourceMappingURL=index.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/auth/strategies/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,oDAAkC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
export * from './login.guard';
|
@@ -1,18 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
3
|
-
if (k2 === undefined) k2 = k;
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
7
|
-
}
|
8
|
-
Object.defineProperty(o, k2, desc);
|
9
|
-
}) : (function(o, m, k, k2) {
|
10
|
-
if (k2 === undefined) k2 = k;
|
11
|
-
o[k2] = m[k];
|
12
|
-
}));
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
|
-
};
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
-
__exportStar(require("./login.guard"), exports);
|
18
|
-
//# sourceMappingURL=index.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/common/guards/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B"}
|
@@ -1,6 +0,0 @@
|
|
1
|
-
import { ExecutionContext } from '@nestjs/common';
|
2
|
-
declare const LoginGuard_base: import("@nestjs/passport").Type<import("@nestjs/passport").IAuthGuard>;
|
3
|
-
export declare class LoginGuard extends LoginGuard_base {
|
4
|
-
canActivate(context: ExecutionContext): Promise<boolean>;
|
5
|
-
}
|
6
|
-
export {};
|
@@ -1,24 +0,0 @@
|
|
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.LoginGuard = void 0;
|
10
|
-
const common_1 = require("@nestjs/common");
|
11
|
-
const passport_1 = require("@nestjs/passport");
|
12
|
-
let LoginGuard = class LoginGuard extends (0, passport_1.AuthGuard)('local') {
|
13
|
-
async canActivate(context) {
|
14
|
-
const result = (await super.canActivate(context));
|
15
|
-
const request = context.switchToHttp().getRequest();
|
16
|
-
await super.logIn(request);
|
17
|
-
return result;
|
18
|
-
}
|
19
|
-
};
|
20
|
-
LoginGuard = __decorate([
|
21
|
-
(0, common_1.Injectable)()
|
22
|
-
], LoginGuard);
|
23
|
-
exports.LoginGuard = LoginGuard;
|
24
|
-
//# sourceMappingURL=login.guard.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"login.guard.js","sourceRoot":"","sources":["../../../src/common/guards/login.guard.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAA8D;AAC9D,+CAA6C;AAGtC,IAAM,UAAU,GAAhB,MAAM,UAAW,SAAQ,IAAA,oBAAS,EAAC,OAAO,CAAC;IAC9C,KAAK,CAAC,WAAW,CAAC,OAAyB;QACvC,MAAM,MAAM,GAAG,CAAC,MAAM,KAAK,CAAC,WAAW,CAAC,OAAO,CAAC,CAAY,CAAC;QAC7D,MAAM,OAAO,GAAG,OAAO,CAAC,YAAY,EAAE,CAAC,UAAU,EAAE,CAAC;QACpD,MAAM,KAAK,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC3B,OAAO,MAAM,CAAC;IAClB,CAAC;CACJ,CAAA;AAPY,UAAU;IADtB,IAAA,mBAAU,GAAE;GACA,UAAU,CAOtB;AAPY,gCAAU"}
|
@@ -1,7 +0,0 @@
|
|
1
|
-
import { CommonJob, DatabaseEventDto, QueueService } from '@servicelabsco/nestjs-utility-services';
|
2
|
-
import { FailedBullJobEntity } from '../entities/failed.bull.job.entity';
|
3
|
-
export declare class FailedBullJobJob extends CommonJob {
|
4
|
-
protected readonly queueService: QueueService;
|
5
|
-
constructor(queueService: QueueService);
|
6
|
-
handle(evt: DatabaseEventDto<FailedBullJobEntity>): Promise<void>;
|
7
|
-
}
|
@@ -1,29 +0,0 @@
|
|
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
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
10
|
-
};
|
11
|
-
var _a;
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
13
|
-
exports.FailedBullJobJob = void 0;
|
14
|
-
const common_1 = require("@nestjs/common");
|
15
|
-
const nestjs_utility_services_1 = require("@servicelabsco/nestjs-utility-services");
|
16
|
-
let FailedBullJobJob = class FailedBullJobJob extends nestjs_utility_services_1.CommonJob {
|
17
|
-
constructor(queueService) {
|
18
|
-
super();
|
19
|
-
this.queueService = queueService;
|
20
|
-
}
|
21
|
-
async handle(evt) {
|
22
|
-
}
|
23
|
-
};
|
24
|
-
FailedBullJobJob = __decorate([
|
25
|
-
(0, common_1.Injectable)(),
|
26
|
-
__metadata("design:paramtypes", [typeof (_a = typeof nestjs_utility_services_1.QueueService !== "undefined" && nestjs_utility_services_1.QueueService) === "function" ? _a : Object])
|
27
|
-
], FailedBullJobJob);
|
28
|
-
exports.FailedBullJobJob = FailedBullJobJob;
|
29
|
-
//# sourceMappingURL=failed.bull.job.job.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"failed.bull.job.job.js","sourceRoot":"","sources":["../../../src/platformUtility/jobs/failed.bull.job.job.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,2CAA4C;AAC5C,oFAAmG;AAG5F,IAAM,gBAAgB,GAAtB,MAAM,gBAAiB,SAAQ,mCAAS;IAC3C,YACuB,YAA0B;QAE7C,KAAK,EAAE,CAAC;QAFW,iBAAY,GAAZ,YAAY,CAAc;IAGjD,CAAC;IACD,KAAK,CAAC,MAAM,CAAC,GAA0C;IACvD,CAAC;CACJ,CAAA;AARY,gBAAgB;IAD5B,IAAA,mBAAU,GAAE;yDAG4B,sCAAY,oBAAZ,sCAAY;GAFxC,gBAAgB,CAQ5B;AARY,4CAAgB"}
|
@@ -1,7 +0,0 @@
|
|
1
|
-
import { CommonJob, DatabaseEventDto, QueueService } from '@servicelabsco/nestjs-utility-services';
|
2
|
-
import { PendingBullJobEntity } from '../entities/pending.bull.job.entity';
|
3
|
-
export declare class PendingBullJobJob extends CommonJob {
|
4
|
-
protected readonly queueService: QueueService;
|
5
|
-
constructor(queueService: QueueService);
|
6
|
-
handle(evt: DatabaseEventDto<PendingBullJobEntity>): Promise<void>;
|
7
|
-
}
|
@@ -1,29 +0,0 @@
|
|
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
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
10
|
-
};
|
11
|
-
var _a;
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
13
|
-
exports.PendingBullJobJob = void 0;
|
14
|
-
const common_1 = require("@nestjs/common");
|
15
|
-
const nestjs_utility_services_1 = require("@servicelabsco/nestjs-utility-services");
|
16
|
-
let PendingBullJobJob = class PendingBullJobJob extends nestjs_utility_services_1.CommonJob {
|
17
|
-
constructor(queueService) {
|
18
|
-
super();
|
19
|
-
this.queueService = queueService;
|
20
|
-
}
|
21
|
-
async handle(evt) {
|
22
|
-
}
|
23
|
-
};
|
24
|
-
PendingBullJobJob = __decorate([
|
25
|
-
(0, common_1.Injectable)(),
|
26
|
-
__metadata("design:paramtypes", [typeof (_a = typeof nestjs_utility_services_1.QueueService !== "undefined" && nestjs_utility_services_1.QueueService) === "function" ? _a : Object])
|
27
|
-
], PendingBullJobJob);
|
28
|
-
exports.PendingBullJobJob = PendingBullJobJob;
|
29
|
-
//# sourceMappingURL=pending.bull.job.job.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"pending.bull.job.job.js","sourceRoot":"","sources":["../../../src/platformUtility/jobs/pending.bull.job.job.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,2CAA4C;AAC5C,oFAAmG;AAG5F,IAAM,iBAAiB,GAAvB,MAAM,iBAAkB,SAAQ,mCAAS;IAC5C,YACuB,YAA0B;QAE7C,KAAK,EAAE,CAAC;QAFW,iBAAY,GAAZ,YAAY,CAAc;IAGjD,CAAC;IACD,KAAK,CAAC,MAAM,CAAC,GAA2C;IACxD,CAAC;CACJ,CAAA;AARY,iBAAiB;IAD7B,IAAA,mBAAU,GAAE;yDAG4B,sCAAY,oBAAZ,sCAAY;GAFxC,iBAAiB,CAQ7B;AARY,8CAAiB"}
|
@@ -1,12 +0,0 @@
|
|
1
|
-
import { CommonSubscriber } from '@servicelabsco/nestjs-utility-services';
|
2
|
-
import { DataSource, InsertEvent, UpdateEvent } from 'typeorm';
|
3
|
-
import { FailedBullJobEntity } from '../entities/failed.bull.job.entity';
|
4
|
-
import { FailedBullJobJob } from '../jobs/failed.bull.job.job';
|
5
|
-
export declare class FailedBullJobSubscriber extends CommonSubscriber<FailedBullJobEntity> {
|
6
|
-
private readonly dataSource;
|
7
|
-
private readonly failedBullJobJob;
|
8
|
-
constructor(dataSource: DataSource, failedBullJobJob: FailedBullJobJob);
|
9
|
-
listenTo(): typeof FailedBullJobEntity;
|
10
|
-
afterInsert(event: InsertEvent<FailedBullJobEntity>): Promise<void>;
|
11
|
-
afterUpdate(event: UpdateEvent<FailedBullJobEntity>): Promise<void>;
|
12
|
-
}
|
@@ -1,40 +0,0 @@
|
|
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
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
10
|
-
};
|
11
|
-
var _a;
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
13
|
-
exports.FailedBullJobSubscriber = void 0;
|
14
|
-
const nestjs_utility_services_1 = require("@servicelabsco/nestjs-utility-services");
|
15
|
-
const typeorm_1 = require("typeorm");
|
16
|
-
const failed_bull_job_entity_1 = require("../entities/failed.bull.job.entity");
|
17
|
-
const failed_bull_job_job_1 = require("../jobs/failed.bull.job.job");
|
18
|
-
let FailedBullJobSubscriber = class FailedBullJobSubscriber extends nestjs_utility_services_1.CommonSubscriber {
|
19
|
-
constructor(dataSource, failedBullJobJob) {
|
20
|
-
super();
|
21
|
-
this.dataSource = dataSource;
|
22
|
-
this.failedBullJobJob = failedBullJobJob;
|
23
|
-
dataSource.subscribers.push(this);
|
24
|
-
}
|
25
|
-
listenTo() {
|
26
|
-
return failed_bull_job_entity_1.FailedBullJobEntity;
|
27
|
-
}
|
28
|
-
async afterInsert(event) {
|
29
|
-
await this.failedBullJobJob.delayedDispatch(this.getEventData(event));
|
30
|
-
}
|
31
|
-
async afterUpdate(event) {
|
32
|
-
await this.failedBullJobJob.delayedDispatch(this.getEventData(event));
|
33
|
-
}
|
34
|
-
};
|
35
|
-
FailedBullJobSubscriber = __decorate([
|
36
|
-
(0, typeorm_1.EventSubscriber)(),
|
37
|
-
__metadata("design:paramtypes", [typeorm_1.DataSource, typeof (_a = typeof failed_bull_job_job_1.FailedBullJobJob !== "undefined" && failed_bull_job_job_1.FailedBullJobJob) === "function" ? _a : Object])
|
38
|
-
], FailedBullJobSubscriber);
|
39
|
-
exports.FailedBullJobSubscriber = FailedBullJobSubscriber;
|
40
|
-
//# sourceMappingURL=failed.bull.job.subscriber.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"failed.bull.job.subscriber.js","sourceRoot":"","sources":["../../../src/platformUtility/subscribers/failed.bull.job.subscriber.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,oFAA0E;AAC1E,qCAAgF;AAChF,+EAAyE;AACzE,qEAA+D;AAExD,IAAM,uBAAuB,GAA7B,MAAM,uBAAwB,SAAQ,0CAAqC;IAC9E,YAA6B,UAAsB,EAAmB,gBAAkC;QACpG,KAAK,EAAE,CAAC;QADiB,eAAU,GAAV,UAAU,CAAY;QAAmB,qBAAgB,GAAhB,gBAAgB,CAAkB;QAEpG,UAAU,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACtC,CAAC;IACD,QAAQ;QACJ,OAAO,4CAAmB,CAAC;IAC/B,CAAC;IACD,KAAK,CAAC,WAAW,CAAC,KAAuC;QACrD,MAAM,IAAI,CAAC,gBAAgB,CAAC,eAAe,CAAC,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC;IAC1E,CAAC;IAED,KAAK,CAAC,WAAW,CAAC,KAAuC;QACrD,MAAM,IAAI,CAAC,gBAAgB,CAAC,eAAe,CAAC,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC;IAC1E,CAAC;CACJ,CAAA;AAfY,uBAAuB;IADnC,IAAA,yBAAe,GAAE;qCAE2B,oBAAU,sBAAqC,sCAAgB,oBAAhB,sCAAgB;GAD/F,uBAAuB,CAenC;AAfY,0DAAuB"}
|
@@ -1,12 +0,0 @@
|
|
1
|
-
import { CommonSubscriber } from '@servicelabsco/nestjs-utility-services';
|
2
|
-
import { DataSource, InsertEvent, UpdateEvent } from 'typeorm';
|
3
|
-
import { PendingBullJobEntity } from '../entities/pending.bull.job.entity';
|
4
|
-
import { PendingBullJobJob } from '../jobs/pending.bull.job.job';
|
5
|
-
export declare class PendingBullJobSubscriber extends CommonSubscriber<PendingBullJobEntity> {
|
6
|
-
private readonly dataSource;
|
7
|
-
private readonly pendingBullJobJob;
|
8
|
-
constructor(dataSource: DataSource, pendingBullJobJob: PendingBullJobJob);
|
9
|
-
listenTo(): typeof PendingBullJobEntity;
|
10
|
-
afterInsert(event: InsertEvent<PendingBullJobEntity>): Promise<void>;
|
11
|
-
afterUpdate(event: UpdateEvent<PendingBullJobEntity>): Promise<void>;
|
12
|
-
}
|
@@ -1,40 +0,0 @@
|
|
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
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
10
|
-
};
|
11
|
-
var _a;
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
13
|
-
exports.PendingBullJobSubscriber = void 0;
|
14
|
-
const nestjs_utility_services_1 = require("@servicelabsco/nestjs-utility-services");
|
15
|
-
const typeorm_1 = require("typeorm");
|
16
|
-
const pending_bull_job_entity_1 = require("../entities/pending.bull.job.entity");
|
17
|
-
const pending_bull_job_job_1 = require("../jobs/pending.bull.job.job");
|
18
|
-
let PendingBullJobSubscriber = class PendingBullJobSubscriber extends nestjs_utility_services_1.CommonSubscriber {
|
19
|
-
constructor(dataSource, pendingBullJobJob) {
|
20
|
-
super();
|
21
|
-
this.dataSource = dataSource;
|
22
|
-
this.pendingBullJobJob = pendingBullJobJob;
|
23
|
-
dataSource.subscribers.push(this);
|
24
|
-
}
|
25
|
-
listenTo() {
|
26
|
-
return pending_bull_job_entity_1.PendingBullJobEntity;
|
27
|
-
}
|
28
|
-
async afterInsert(event) {
|
29
|
-
await this.pendingBullJobJob.delayedDispatch(this.getEventData(event));
|
30
|
-
}
|
31
|
-
async afterUpdate(event) {
|
32
|
-
await this.pendingBullJobJob.delayedDispatch(this.getEventData(event));
|
33
|
-
}
|
34
|
-
};
|
35
|
-
PendingBullJobSubscriber = __decorate([
|
36
|
-
(0, typeorm_1.EventSubscriber)(),
|
37
|
-
__metadata("design:paramtypes", [typeorm_1.DataSource, typeof (_a = typeof pending_bull_job_job_1.PendingBullJobJob !== "undefined" && pending_bull_job_job_1.PendingBullJobJob) === "function" ? _a : Object])
|
38
|
-
], PendingBullJobSubscriber);
|
39
|
-
exports.PendingBullJobSubscriber = PendingBullJobSubscriber;
|
40
|
-
//# sourceMappingURL=pending.bull.job.subscriber.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"pending.bull.job.subscriber.js","sourceRoot":"","sources":["../../../src/platformUtility/subscribers/pending.bull.job.subscriber.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,oFAA0E;AAC1E,qCAAgF;AAChF,iFAA2E;AAC3E,uEAAiE;AAE1D,IAAM,wBAAwB,GAA9B,MAAM,wBAAyB,SAAQ,0CAAsC;IAChF,YAA6B,UAAsB,EAAmB,iBAAoC;QACtG,KAAK,EAAE,CAAC;QADiB,eAAU,GAAV,UAAU,CAAY;QAAmB,sBAAiB,GAAjB,iBAAiB,CAAmB;QAEtG,UAAU,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACtC,CAAC;IACD,QAAQ;QACJ,OAAO,8CAAoB,CAAC;IAChC,CAAC;IACD,KAAK,CAAC,WAAW,CAAC,KAAwC;QACtD,MAAM,IAAI,CAAC,iBAAiB,CAAC,eAAe,CAAC,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC;IAC3E,CAAC;IAED,KAAK,CAAC,WAAW,CAAC,KAAwC;QACtD,MAAM,IAAI,CAAC,iBAAiB,CAAC,eAAe,CAAC,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC;IAC3E,CAAC;CACJ,CAAA;AAfY,wBAAwB;IADpC,IAAA,yBAAe,GAAE;qCAE2B,oBAAU,sBAAsC,wCAAiB,oBAAjB,wCAAiB;GADjG,wBAAwB,CAepC;AAfY,4DAAwB"}
|
@@ -1,16 +0,0 @@
|
|
1
|
-
import { JobRecordParamDto } from '../dtos/job.record.param.dto';
|
2
|
-
import { QueueService } from './../../platformUtility/services/queue.service';
|
3
|
-
export declare class JobController {
|
4
|
-
private readonly queueService;
|
5
|
-
constructor(queueService: QueueService);
|
6
|
-
getWorkers(): Promise<any[]>;
|
7
|
-
getQueueStats(): Promise<any[]>;
|
8
|
-
getWaitingJobs(param: JobRecordParamDto): Promise<any[]>;
|
9
|
-
getDelayedJobs(param: JobRecordParamDto): Promise<any[]>;
|
10
|
-
getActiveJobs(param: JobRecordParamDto): Promise<any[]>;
|
11
|
-
getCompletedJobs(param: JobRecordParamDto): Promise<any[]>;
|
12
|
-
getFailedJobs(param: JobRecordParamDto): Promise<any[]>;
|
13
|
-
getJobInfo(id: number): Promise<import("bull").Job<any>>;
|
14
|
-
retryJob(id: number): Promise<import("bull").Job<any>>;
|
15
|
-
removeJob(id: number): Promise<void>;
|
16
|
-
}
|
@@ -1,137 +0,0 @@
|
|
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
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
10
|
-
};
|
11
|
-
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
12
|
-
return function (target, key) { decorator(target, key, paramIndex); }
|
13
|
-
};
|
14
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
15
|
-
exports.JobController = void 0;
|
16
|
-
const common_1 = require("@nestjs/common");
|
17
|
-
const job_record_param_dto_1 = require("../dtos/job.record.param.dto");
|
18
|
-
const queue_service_1 = require("./../../platformUtility/services/queue.service");
|
19
|
-
let JobController = class JobController {
|
20
|
-
constructor(queueService) {
|
21
|
-
this.queueService = queueService;
|
22
|
-
}
|
23
|
-
getWorkers() {
|
24
|
-
return this.queueService.getWorkers();
|
25
|
-
}
|
26
|
-
getQueueStats() {
|
27
|
-
return this.queueService.getWorkers();
|
28
|
-
}
|
29
|
-
getWaitingJobs(param) {
|
30
|
-
const startRecord = (param.page - 1) * param.limit;
|
31
|
-
const endRecord = param.page * param.limit;
|
32
|
-
return this.queueService.getWaitingJobs(startRecord, endRecord);
|
33
|
-
}
|
34
|
-
getDelayedJobs(param) {
|
35
|
-
const startRecord = (param.page - 1) * param.limit;
|
36
|
-
const endRecord = param.page * param.limit;
|
37
|
-
return this.queueService.getDelayedJobs(startRecord, endRecord);
|
38
|
-
}
|
39
|
-
getActiveJobs(param) {
|
40
|
-
const startRecord = (param.page - 1) * param.limit;
|
41
|
-
const endRecord = param.page * param.limit;
|
42
|
-
return this.queueService.getActiveJobs(startRecord, endRecord);
|
43
|
-
}
|
44
|
-
getCompletedJobs(param) {
|
45
|
-
const startRecord = (param.page - 1) * param.limit;
|
46
|
-
const endRecord = param.page * param.limit;
|
47
|
-
return this.queueService.getCompletedJobs(startRecord, endRecord);
|
48
|
-
}
|
49
|
-
getFailedJobs(param) {
|
50
|
-
const startRecord = (param.page - 1) * param.limit;
|
51
|
-
const endRecord = param.page * param.limit;
|
52
|
-
return this.queueService.getFailedJobs(startRecord, endRecord);
|
53
|
-
}
|
54
|
-
getJobInfo(id) {
|
55
|
-
return this.queueService.getJobDetails(id);
|
56
|
-
}
|
57
|
-
retryJob(id) {
|
58
|
-
return this.queueService.retryJob(id);
|
59
|
-
}
|
60
|
-
removeJob(id) {
|
61
|
-
return this.queueService.removeJob(id);
|
62
|
-
}
|
63
|
-
};
|
64
|
-
__decorate([
|
65
|
-
(0, common_1.Get)('get-workers'),
|
66
|
-
__metadata("design:type", Function),
|
67
|
-
__metadata("design:paramtypes", []),
|
68
|
-
__metadata("design:returntype", void 0)
|
69
|
-
], JobController.prototype, "getWorkers", null);
|
70
|
-
__decorate([
|
71
|
-
(0, common_1.Get)('get-stats'),
|
72
|
-
__metadata("design:type", Function),
|
73
|
-
__metadata("design:paramtypes", []),
|
74
|
-
__metadata("design:returntype", void 0)
|
75
|
-
], JobController.prototype, "getQueueStats", null);
|
76
|
-
__decorate([
|
77
|
-
(0, common_1.Get)('get-waiting'),
|
78
|
-
__param(0, (0, common_1.Param)()),
|
79
|
-
__metadata("design:type", Function),
|
80
|
-
__metadata("design:paramtypes", [job_record_param_dto_1.JobRecordParamDto]),
|
81
|
-
__metadata("design:returntype", void 0)
|
82
|
-
], JobController.prototype, "getWaitingJobs", null);
|
83
|
-
__decorate([
|
84
|
-
(0, common_1.Get)('get-delayed'),
|
85
|
-
__param(0, (0, common_1.Param)()),
|
86
|
-
__metadata("design:type", Function),
|
87
|
-
__metadata("design:paramtypes", [job_record_param_dto_1.JobRecordParamDto]),
|
88
|
-
__metadata("design:returntype", void 0)
|
89
|
-
], JobController.prototype, "getDelayedJobs", null);
|
90
|
-
__decorate([
|
91
|
-
(0, common_1.Get)('get-active'),
|
92
|
-
__param(0, (0, common_1.Param)()),
|
93
|
-
__metadata("design:type", Function),
|
94
|
-
__metadata("design:paramtypes", [job_record_param_dto_1.JobRecordParamDto]),
|
95
|
-
__metadata("design:returntype", void 0)
|
96
|
-
], JobController.prototype, "getActiveJobs", null);
|
97
|
-
__decorate([
|
98
|
-
(0, common_1.Get)('get-completed'),
|
99
|
-
__param(0, (0, common_1.Param)()),
|
100
|
-
__metadata("design:type", Function),
|
101
|
-
__metadata("design:paramtypes", [job_record_param_dto_1.JobRecordParamDto]),
|
102
|
-
__metadata("design:returntype", void 0)
|
103
|
-
], JobController.prototype, "getCompletedJobs", null);
|
104
|
-
__decorate([
|
105
|
-
(0, common_1.Get)('get-failed'),
|
106
|
-
__param(0, (0, common_1.Param)()),
|
107
|
-
__metadata("design:type", Function),
|
108
|
-
__metadata("design:paramtypes", [job_record_param_dto_1.JobRecordParamDto]),
|
109
|
-
__metadata("design:returntype", void 0)
|
110
|
-
], JobController.prototype, "getFailedJobs", null);
|
111
|
-
__decorate([
|
112
|
-
(0, common_1.Get)(':id'),
|
113
|
-
__param(0, (0, common_1.Param)('id')),
|
114
|
-
__metadata("design:type", Function),
|
115
|
-
__metadata("design:paramtypes", [Number]),
|
116
|
-
__metadata("design:returntype", void 0)
|
117
|
-
], JobController.prototype, "getJobInfo", null);
|
118
|
-
__decorate([
|
119
|
-
(0, common_1.Post)('retry/:id'),
|
120
|
-
__param(0, (0, common_1.Param)('id')),
|
121
|
-
__metadata("design:type", Function),
|
122
|
-
__metadata("design:paramtypes", [Number]),
|
123
|
-
__metadata("design:returntype", void 0)
|
124
|
-
], JobController.prototype, "retryJob", null);
|
125
|
-
__decorate([
|
126
|
-
(0, common_1.Delete)(':id'),
|
127
|
-
__param(0, (0, common_1.Param)('id')),
|
128
|
-
__metadata("design:type", Function),
|
129
|
-
__metadata("design:paramtypes", [Number]),
|
130
|
-
__metadata("design:returntype", void 0)
|
131
|
-
], JobController.prototype, "removeJob", null);
|
132
|
-
JobController = __decorate([
|
133
|
-
(0, common_1.Controller)('api/admin/job'),
|
134
|
-
__metadata("design:paramtypes", [queue_service_1.QueueService])
|
135
|
-
], JobController);
|
136
|
-
exports.JobController = JobController;
|
137
|
-
//# sourceMappingURL=job.controller.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"job.controller.js","sourceRoot":"","sources":["../../../src/system/controllers/job.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,2CAAsE;AACtE,uEAAiE;AACjE,kFAA8E;AAQvE,IAAM,aAAa,GAAnB,MAAM,aAAa;IAMtB,YAA6B,YAA0B;QAA1B,iBAAY,GAAZ,YAAY,CAAc;IAAG,CAAC;IAQ3D,UAAU;QACN,OAAO,IAAI,CAAC,YAAY,CAAC,UAAU,EAAE,CAAC;IAC1C,CAAC;IAQD,aAAa;QACT,OAAO,IAAI,CAAC,YAAY,CAAC,UAAU,EAAE,CAAC;IAC1C,CAAC;IASD,cAAc,CAAU,KAAwB;QAC5C,MAAM,WAAW,GAAW,CAAC,KAAK,CAAC,IAAI,GAAG,CAAC,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC;QAC3D,MAAM,SAAS,GAAW,KAAK,CAAC,IAAI,GAAG,KAAK,CAAC,KAAK,CAAC;QAEnD,OAAO,IAAI,CAAC,YAAY,CAAC,cAAc,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;IACpE,CAAC;IASD,cAAc,CAAU,KAAwB;QAC5C,MAAM,WAAW,GAAG,CAAC,KAAK,CAAC,IAAI,GAAG,CAAC,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC;QACnD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,GAAG,KAAK,CAAC,KAAK,CAAC;QAE3C,OAAO,IAAI,CAAC,YAAY,CAAC,cAAc,C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