@merkaly/api 0.2.2-12 → 0.2.2-13
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/package.json +1 -1
- package/.output/abstract/app.controller.d.ts +0 -11
- package/.output/abstract/app.controller.d.ts.map +0 -1
- package/.output/abstract/app.controller.js +0 -22
- package/.output/abstract/app.controller.js.map +0 -1
- package/.output/abstract/app.entity.d.ts +0 -9
- package/.output/abstract/app.entity.d.ts.map +0 -1
- package/.output/abstract/app.entity.js +0 -28
- package/.output/abstract/app.entity.js.map +0 -1
- package/.output/abstract/app.exception.d.ts +0 -11
- package/.output/abstract/app.exception.d.ts.map +0 -1
- package/.output/abstract/app.exception.js +0 -37
- package/.output/abstract/app.exception.js.map +0 -1
- package/.output/abstract/app.repository.d.ts +0 -20
- package/.output/abstract/app.repository.d.ts.map +0 -1
- package/.output/abstract/app.repository.js +0 -73
- package/.output/abstract/app.repository.js.map +0 -1
- package/.output/abstract/app.router.d.ts +0 -6
- package/.output/abstract/app.router.d.ts.map +0 -1
- package/.output/abstract/app.router.js +0 -8
- package/.output/abstract/app.router.js.map +0 -1
- package/.output/configs/app.controller.d.ts +0 -11
- package/.output/configs/app.controller.d.ts.map +0 -1
- package/.output/configs/app.controller.js +0 -22
- package/.output/configs/app.controller.js.map +0 -1
- package/.output/configs/app.entity.d.ts +0 -9
- package/.output/configs/app.entity.d.ts.map +0 -1
- package/.output/configs/app.entity.js +0 -28
- package/.output/configs/app.entity.js.map +0 -1
- package/.output/configs/app.exception.d.ts +0 -11
- package/.output/configs/app.exception.d.ts.map +0 -1
- package/.output/configs/app.exception.js +0 -37
- package/.output/configs/app.exception.js.map +0 -1
- package/.output/configs/app.repository.d.ts +0 -20
- package/.output/configs/app.repository.d.ts.map +0 -1
- package/.output/configs/app.repository.js +0 -73
- package/.output/configs/app.repository.js.map +0 -1
- package/.output/configs/app.router.d.ts +0 -6
- package/.output/configs/app.router.d.ts.map +0 -1
- package/.output/configs/app.router.js +0 -8
- package/.output/configs/app.router.js.map +0 -1
- package/.output/decorators/organization.decorator.d.ts +0 -2
- package/.output/decorators/organization.decorator.d.ts.map +0 -1
- package/.output/decorators/organization.decorator.js +0 -10
- package/.output/decorators/organization.decorator.js.map +0 -1
- package/.output/globals/global.controller.d.ts +0 -20
- package/.output/globals/global.controller.d.ts.map +0 -1
- package/.output/globals/global.controller.js +0 -76
- package/.output/globals/global.controller.js.map +0 -1
- package/.output/interceptors/logger.interceptor.d.ts +0 -9
- package/.output/interceptors/logger.interceptor.d.ts.map +0 -1
- package/.output/interceptors/logger.interceptor.js +0 -54
- package/.output/interceptors/logger.interceptor.js.map +0 -1
- package/.output/modules/app.module.d.ts +0 -12
- package/.output/modules/app.module.d.ts.map +0 -1
- package/.output/modules/app.module.js +0 -37
- package/.output/modules/app.module.js.map +0 -1
- package/.output/modules/auth/auth.controller.d.ts +0 -7
- package/.output/modules/auth/auth.controller.d.ts.map +0 -1
- package/.output/modules/auth/auth.controller.js +0 -31
- package/.output/modules/auth/auth.controller.js.map +0 -1
- package/.output/modules/auth/connections/connection.controller.d.ts +0 -8
- package/.output/modules/auth/connections/connection.controller.d.ts.map +0 -1
- package/.output/modules/auth/connections/connection.controller.js +0 -30
- package/.output/modules/auth/connections/connection.controller.js.map +0 -1
- package/.output/modules/auth/connections/connection.module.d.ts +0 -8
- package/.output/modules/auth/connections/connection.module.d.ts.map +0 -1
- package/.output/modules/auth/connections/connection.module.js +0 -22
- package/.output/modules/auth/connections/connection.module.js.map +0 -1
- package/.output/modules/auth/connections/connection.validator.d.ts +0 -10
- package/.output/modules/auth/connections/connection.validator.d.ts.map +0 -1
- package/.output/modules/auth/connections/connection.validator.js +0 -24
- package/.output/modules/auth/connections/connection.validator.js.map +0 -1
- package/.output/modules/auth/members/member.controller.d.ts +0 -8
- package/.output/modules/auth/members/member.controller.d.ts.map +0 -1
- package/.output/modules/auth/members/member.controller.js +0 -30
- package/.output/modules/auth/members/member.controller.js.map +0 -1
- package/.output/modules/auth/members/member.module.d.ts +0 -8
- package/.output/modules/auth/members/member.module.d.ts.map +0 -1
- package/.output/modules/auth/members/member.module.js +0 -22
- package/.output/modules/auth/members/member.module.js.map +0 -1
- package/.output/modules/auth/members/member.validator.d.ts +0 -4
- package/.output/modules/auth/members/member.validator.d.ts.map +0 -1
- package/.output/modules/auth/members/member.validator.js +0 -4
- package/.output/modules/auth/members/member.validator.js.map +0 -1
- package/.output/modules/auth/organizations/organization.controller.d.ts +0 -16
- package/.output/modules/auth/organizations/organization.controller.d.ts.map +0 -1
- package/.output/modules/auth/organizations/organization.controller.js +0 -101
- package/.output/modules/auth/organizations/organization.controller.js.map +0 -1
- package/.output/modules/auth/organizations/organization.module.d.ts +0 -9
- package/.output/modules/auth/organizations/organization.module.d.ts.map +0 -1
- package/.output/modules/auth/organizations/organization.module.js +0 -24
- package/.output/modules/auth/organizations/organization.module.js.map +0 -1
- package/.output/modules/auth/organizations/organization.repository.d.ts +0 -9
- package/.output/modules/auth/organizations/organization.repository.d.ts.map +0 -1
- package/.output/modules/auth/organizations/organization.repository.js +0 -42
- package/.output/modules/auth/organizations/organization.repository.js.map +0 -1
- package/.output/modules/auth/organizations/organization.validator.d.ts +0 -7
- package/.output/modules/auth/organizations/organization.validator.d.ts.map +0 -1
- package/.output/modules/auth/organizations/organization.validator.js +0 -22
- package/.output/modules/auth/organizations/organization.validator.js.map +0 -1
- package/.output/modules/health/health.controller.d.ts +0 -8
- package/.output/modules/health/health.controller.d.ts.map +0 -1
- package/.output/modules/health/health.controller.js +0 -29
- package/.output/modules/health/health.controller.js.map +0 -1
- package/.output/modules/health/health.module.d.ts +0 -9
- package/.output/modules/health/health.module.d.ts.map +0 -1
- package/.output/modules/health/health.module.js +0 -24
- package/.output/modules/health/health.module.js.map +0 -1
- package/.output/modules/health.module.d.ts +0 -3
- package/.output/modules/health.module.d.ts.map +0 -1
- package/.output/modules/health.module.js +0 -14
- package/.output/modules/health.module.js.map +0 -1
- package/.output/modules/settings/organization/organization.entity.d.ts +0 -10
- package/.output/modules/settings/organization/organization.entity.d.ts.map +0 -1
- package/.output/modules/settings/organization/organization.entity.js +0 -11
- package/.output/modules/settings/organization/organization.entity.js.map +0 -1
- package/.output/modules/settings/organizations/organization.controller.d.ts +0 -16
- package/.output/modules/settings/organizations/organization.controller.d.ts.map +0 -1
- package/.output/modules/settings/organizations/organization.controller.js +0 -101
- package/.output/modules/settings/organizations/organization.controller.js.map +0 -1
- package/.output/modules/settings/organizations/organization.module.d.ts +0 -9
- package/.output/modules/settings/organizations/organization.module.d.ts.map +0 -1
- package/.output/modules/settings/organizations/organization.module.js +0 -24
- package/.output/modules/settings/organizations/organization.module.js.map +0 -1
- package/.output/modules/settings/organizations/organization.repository.d.ts +0 -9
- package/.output/modules/settings/organizations/organization.repository.d.ts.map +0 -1
- package/.output/modules/settings/organizations/organization.repository.js +0 -42
- package/.output/modules/settings/organizations/organization.repository.js.map +0 -1
- package/.output/modules/settings/organizations/organization.validator.d.ts +0 -7
- package/.output/modules/settings/organizations/organization.validator.d.ts.map +0 -1
- package/.output/modules/settings/organizations/organization.validator.js +0 -22
- package/.output/modules/settings/organizations/organization.validator.js.map +0 -1
- package/.output/providers/mongo.provider.d.ts +0 -20
- package/.output/providers/mongo.provider.d.ts.map +0 -1
- package/.output/providers/mongo.provider.js +0 -41
- package/.output/providers/mongo.provider.js.map +0 -1
- package/.output/providers/schema.provider.d.ts +0 -12
- package/.output/providers/schema.provider.d.ts.map +0 -1
- package/.output/providers/schema.provider.js +0 -33
- package/.output/providers/schema.provider.js.map +0 -1
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.GlobalController = void 0;
|
|
4
|
-
const common_1 = require("@nestjs/common");
|
|
5
|
-
const mongoose_1 = require("@nestjs/mongoose");
|
|
6
|
-
const terminus_1 = require("@nestjs/terminus");
|
|
7
|
-
const os_1 = __importDefault(require("os"));
|
|
8
|
-
const config_1 = require("../config");
|
|
9
|
-
const public_decorator_1 = require("../decorators/public.decorator");
|
|
10
|
-
const auth0_service_1 = require("../services/auth0.service");
|
|
11
|
-
let GlobalController = class GlobalController {
|
|
12
|
-
health() {
|
|
13
|
-
return this.$health.check([
|
|
14
|
-
() => this.$mongodb.pingCheck('mongodb', { timeout: 1500, connection: this.$connection }),
|
|
15
|
-
() => this.$axios.pingCheck('auth0', `https://${config_1.AppConfig.auth0.domain}`),
|
|
16
|
-
() => this.$memory.checkHeap('memory', 150 * 1024 * 1024),
|
|
17
|
-
]);
|
|
18
|
-
}
|
|
19
|
-
main(session) {
|
|
20
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
return {
|
|
22
|
-
hostname: os_1.default.hostname(),
|
|
23
|
-
version: os_1.default.version(),
|
|
24
|
-
totalmem: os_1.default.totalmem(),
|
|
25
|
-
freemem: os_1.default.freemem(),
|
|
26
|
-
platform: os_1.default.platform(),
|
|
27
|
-
uptime: os_1.default.uptime(),
|
|
28
|
-
};
|
|
29
|
-
});
|
|
30
|
-
}
|
|
31
|
-
};
|
|
32
|
-
__decorate([
|
|
33
|
-
(0, mongoose_1.InjectConnection)(),
|
|
34
|
-
__metadata("design:type", Object)
|
|
35
|
-
], GlobalController.prototype, "$connection", void 0);
|
|
36
|
-
__decorate([
|
|
37
|
-
(0, common_1.Inject)(),
|
|
38
|
-
__metadata("design:type", auth0_service_1.Auth0Service)
|
|
39
|
-
], GlobalController.prototype, "$auth0", void 0);
|
|
40
|
-
__decorate([
|
|
41
|
-
(0, common_1.Inject)(),
|
|
42
|
-
__metadata("design:type", terminus_1.HealthCheckService)
|
|
43
|
-
], GlobalController.prototype, "$health", void 0);
|
|
44
|
-
__decorate([
|
|
45
|
-
(0, common_1.Inject)(),
|
|
46
|
-
__metadata("design:type", terminus_1.MongooseHealthIndicator)
|
|
47
|
-
], GlobalController.prototype, "$mongodb", void 0);
|
|
48
|
-
__decorate([
|
|
49
|
-
(0, common_1.Inject)(),
|
|
50
|
-
__metadata("design:type", terminus_1.HttpHealthIndicator)
|
|
51
|
-
], GlobalController.prototype, "$axios", void 0);
|
|
52
|
-
__decorate([
|
|
53
|
-
(0, common_1.Inject)(),
|
|
54
|
-
__metadata("design:type", terminus_1.MemoryHealthIndicator)
|
|
55
|
-
], GlobalController.prototype, "$memory", void 0);
|
|
56
|
-
__decorate([
|
|
57
|
-
(0, common_1.Get)('/'),
|
|
58
|
-
(0, terminus_1.HealthCheck)(),
|
|
59
|
-
(0, public_decorator_1.Public)(),
|
|
60
|
-
__metadata("design:type", Function),
|
|
61
|
-
__metadata("design:paramtypes", []),
|
|
62
|
-
__metadata("design:returntype", void 0)
|
|
63
|
-
], GlobalController.prototype, "health", null);
|
|
64
|
-
__decorate([
|
|
65
|
-
(0, common_1.Get)('/'),
|
|
66
|
-
(0, public_decorator_1.Public)(),
|
|
67
|
-
__param(0, (0, common_1.Session)()),
|
|
68
|
-
__metadata("design:type", Function),
|
|
69
|
-
__metadata("design:paramtypes", [Object]),
|
|
70
|
-
__metadata("design:returntype", Promise)
|
|
71
|
-
], GlobalController.prototype, "main", null);
|
|
72
|
-
GlobalController = __decorate([
|
|
73
|
-
(0, common_1.Controller)()
|
|
74
|
-
], GlobalController);
|
|
75
|
-
exports.GlobalController = GlobalController;
|
|
76
|
-
//# sourceMappingURL=global.controller.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"global.controller.js","sourceRoot":"","sources":["../../src/globals/global.controller.ts"],"names":[],"mappings":";;;AAAA,2CAAkE;AAClE,+CAAoD;AACpD,+CAM0B;AAG1B,4CAAoB;AACpB,sCAAsC;AACtC,qEAAwD;AACxD,6DAAyD;AAGzD,IAAa,gBAAgB,GAA7B,MAAa,gBAAgB;IAW3B,MAAM;QACJ,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC;YACxB,GAAG,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,SAAS,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,CAAC,WAAW,EAAE,CAAC;YACzF,GAAG,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,OAAO,EAAE,WAAW,kBAAS,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC;YACzE,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,QAAQ,EAAE,GAAG,GAAG,IAAI,GAAG,IAAI,CAAC;SAC1D,CAAC,CAAC;IACL,CAAC;IAIY,IAAI,CAAY,OAAoB;;YAE/C,OAAO;gBACL,QAAQ,EAAE,YAAE,CAAC,QAAQ,EAAE;gBACvB,OAAO,EAAE,YAAE,CAAC,OAAO,EAAE;gBACrB,QAAQ,EAAE,YAAE,CAAC,QAAQ,EAAE;gBACvB,OAAO,EAAE,YAAE,CAAC,OAAO,EAAE;gBACrB,QAAQ,EAAE,YAAE,CAAC,QAAQ,EAAE;gBACvB,MAAM,EAAE,YAAE,CAAC,MAAM,EAAE;aACpB,CAAC;QACJ,CAAC;KAAA;CAEF,CAAA;AAhCqB;IAAnB,IAAA,2BAAgB,GAAE;;qDAA0C;AACnD;IAAT,IAAA,eAAM,GAAE;8BAAyB,4BAAY;gDAAC;AACrC;IAAT,IAAA,eAAM,GAAE;8BAA2B,6BAAkB;iDAAC;AAC7C;IAAT,IAAA,eAAM,GAAE;8BAA4B,kCAAuB;kDAAC;AACnD;IAAT,IAAA,eAAM,GAAE;8BAA0B,8BAAmB;gDAAC;AAC7C;IAAT,IAAA,eAAM,GAAE;8BAA2B,gCAAqB;iDAAC;AAK1D;IAHC,IAAA,YAAG,EAAC,GAAG,CAAC;IACR,IAAA,sBAAW,GAAE;IACb,IAAA,yBAAM,GAAE;;;;8CAOR;AAID;IAFC,IAAA,YAAG,EAAC,GAAG,CAAC;IACR,IAAA,yBAAM,GAAE;IACU,WAAA,IAAA,gBAAO,GAAE,CAAA;;;;4CAU3B;AA/BU,gBAAgB;IAD5B,IAAA,mBAAU,GAAE;GACA,gBAAgB,CAiC5B;AAjCY,4CAAgB"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { CallHandler, ExecutionContext, NestInterceptor } from '@nestjs/common';
|
|
2
|
-
export declare class LoggerInterceptor implements NestInterceptor {
|
|
3
|
-
intercept(context: ExecutionContext, next: CallHandler): import("rxjs").Observable<any>;
|
|
4
|
-
protected generateEmptySpace(word: string, lenght: number, char?: string): string;
|
|
5
|
-
private paintHostName;
|
|
6
|
-
private paintIdentity;
|
|
7
|
-
private paintMethod;
|
|
8
|
-
}
|
|
9
|
-
//# sourceMappingURL=logger.interceptor.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"logger.interceptor.d.ts","sourceRoot":"","sources":["../../src/interceptors/logger.interceptor.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,gBAAgB,EAAc,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAM5F,qBACa,iBAAkB,YAAW,eAAe;IAEhD,SAAS,CAAC,OAAO,EAAE,gBAAgB,EAAE,IAAI,EAAE,WAAW;IAiC7D,SAAS,CAAC,kBAAkB,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,SAAM;IAQrE,OAAO,CAAC,aAAa;IAMrB,OAAO,CAAC,aAAa;IAMrB,OAAO,CAAC,WAAW;CAKpB"}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.LoggerInterceptor = void 0;
|
|
4
|
-
const common_1 = require("@nestjs/common");
|
|
5
|
-
const chalk_1 = __importDefault(require("chalk"));
|
|
6
|
-
const nestjs_console_1 = require("nestjs-console");
|
|
7
|
-
const rxjs_1 = require("rxjs");
|
|
8
|
-
let LoggerInterceptor = class LoggerInterceptor {
|
|
9
|
-
intercept(context, next) {
|
|
10
|
-
const request = context.switchToHttp().getRequest();
|
|
11
|
-
const startDate = Date.now();
|
|
12
|
-
const readableDate = new Intl.DateTimeFormat('es-ES', { dateStyle: 'short', timeStyle: 'long' }).format(startDate);
|
|
13
|
-
const coloredDate = chalk_1.default.yellow(readableDate);
|
|
14
|
-
const coloredIdentity = this.paintIdentity(request.headers.organization || request.headers.host);
|
|
15
|
-
const coloredMethod = this.paintMethod(request.method);
|
|
16
|
-
const coloredUrl = chalk_1.default.cyan(request.originalUrl);
|
|
17
|
-
const spinner = (0, nestjs_console_1.createSpinner)({ prefixText: this.paintHostName(request.hostname) });
|
|
18
|
-
const coloredFullMessage = `[${coloredDate}] ${coloredIdentity} ${coloredMethod}:${coloredUrl} `;
|
|
19
|
-
spinner.start(coloredFullMessage);
|
|
20
|
-
return next
|
|
21
|
-
.handle()
|
|
22
|
-
.pipe((0, rxjs_1.tap)(() => {
|
|
23
|
-
const coloredTime = chalk_1.default.green(`${Date.now() - startDate}ms`);
|
|
24
|
-
spinner.succeed(`${coloredFullMessage} => ${coloredTime}`);
|
|
25
|
-
}), (0, rxjs_1.catchError)((err) => (0, rxjs_1.throwError)(() => {
|
|
26
|
-
const coloredTime = chalk_1.default.redBright(`${Date.now() - startDate}ms || ${err.message}`);
|
|
27
|
-
spinner.fail(`${coloredFullMessage} => ${coloredTime}`);
|
|
28
|
-
return err;
|
|
29
|
-
})));
|
|
30
|
-
}
|
|
31
|
-
generateEmptySpace(word, lenght, char = ' ') {
|
|
32
|
-
const space = new Array(lenght).join(char);
|
|
33
|
-
return word.length > lenght
|
|
34
|
-
? word
|
|
35
|
-
: space.replace(new Array(word.length).join(char), word);
|
|
36
|
-
}
|
|
37
|
-
paintHostName(hostname) {
|
|
38
|
-
const spacedName = this.generateEmptySpace(hostname, 30);
|
|
39
|
-
return chalk_1.default.black(chalk_1.default.bgWhite(spacedName));
|
|
40
|
-
}
|
|
41
|
-
paintIdentity(identity) {
|
|
42
|
-
const spacedName = this.generateEmptySpace(`[${identity}]`, 30);
|
|
43
|
-
return chalk_1.default.magenta(spacedName);
|
|
44
|
-
}
|
|
45
|
-
paintMethod(method) {
|
|
46
|
-
const spacedName = this.generateEmptySpace(`[${method}]`, 8);
|
|
47
|
-
return chalk_1.default.blue(spacedName);
|
|
48
|
-
}
|
|
49
|
-
};
|
|
50
|
-
LoggerInterceptor = __decorate([
|
|
51
|
-
(0, common_1.Injectable)()
|
|
52
|
-
], LoggerInterceptor);
|
|
53
|
-
exports.LoggerInterceptor = LoggerInterceptor;
|
|
54
|
-
//# sourceMappingURL=logger.interceptor.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"logger.interceptor.js","sourceRoot":"","sources":["../../src/interceptors/logger.interceptor.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { MiddlewareConsumer, ModuleMetadata, NestModule } from '@nestjs/common';
|
|
2
|
-
import { AssetModule } from './assets/asset.module';
|
|
3
|
-
import { AuthModule } from './auth/auth.module';
|
|
4
|
-
import { InventoryModule } from './inventory/inventory.module';
|
|
5
|
-
import { SettingModule } from './settings/setting.module';
|
|
6
|
-
import { StoreModule } from './store/store.module';
|
|
7
|
-
export declare const router: (typeof AuthModule | typeof InventoryModule | typeof StoreModule | typeof SettingModule | typeof AssetModule)[];
|
|
8
|
-
export declare const metadata: ModuleMetadata;
|
|
9
|
-
export declare class AppModule implements NestModule {
|
|
10
|
-
configure(consumer: MiddlewareConsumer): MiddlewareConsumer;
|
|
11
|
-
}
|
|
12
|
-
//# sourceMappingURL=app.module.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"app.module.d.ts","sourceRoot":"","sources":["../../src/modules/app.module.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,kBAAkB,EAAU,cAAc,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAIrG,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAGhD,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAEnD,eAAO,MAAM,MAAM,iHAAyE,CAAC;AAW7F,eAAO,MAAM,QAAQ,EAAE,cAItB,CAAC;AAEF,qBACa,SAAU,YAAW,UAAU;IACnC,SAAS,CAAC,QAAQ,EAAE,kBAAkB,GAAG,kBAAkB;CAInE"}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AppModule = exports.metadata = exports.router = void 0;
|
|
4
|
-
const common_1 = require("@nestjs/common");
|
|
5
|
-
const config_1 = require("@nestjs/config");
|
|
6
|
-
const core_1 = require("@nestjs/core");
|
|
7
|
-
const asset_module_1 = require("./assets/asset.module");
|
|
8
|
-
const auth_module_1 = require("./auth/auth.module");
|
|
9
|
-
const command_module_1 = require("./command.module");
|
|
10
|
-
const global_module_1 = require("./global.module");
|
|
11
|
-
const inventory_module_1 = require("./inventory/inventory.module");
|
|
12
|
-
const setting_module_1 = require("./settings/setting.module");
|
|
13
|
-
const store_module_1 = require("./store/store.module");
|
|
14
|
-
exports.router = [auth_module_1.AuthModule, inventory_module_1.InventoryModule, store_module_1.StoreModule, setting_module_1.SettingModule, asset_module_1.AssetModule];
|
|
15
|
-
const modules = [
|
|
16
|
-
...exports.router,
|
|
17
|
-
global_module_1.GlobalModule.register(),
|
|
18
|
-
command_module_1.CommandsModule.register(),
|
|
19
|
-
core_1.RouterModule.register(exports.router),
|
|
20
|
-
common_1.CacheModule.register({ isGlobal: true }),
|
|
21
|
-
config_1.ConfigModule.forRoot({ isGlobal: true }),
|
|
22
|
-
];
|
|
23
|
-
exports.metadata = {
|
|
24
|
-
imports: modules,
|
|
25
|
-
providers: [],
|
|
26
|
-
exports: [],
|
|
27
|
-
};
|
|
28
|
-
let AppModule = class AppModule {
|
|
29
|
-
configure(consumer) {
|
|
30
|
-
return consumer;
|
|
31
|
-
}
|
|
32
|
-
};
|
|
33
|
-
AppModule = __decorate([
|
|
34
|
-
(0, common_1.Module)(exports.metadata)
|
|
35
|
-
], AppModule);
|
|
36
|
-
exports.AppModule = AppModule;
|
|
37
|
-
//# sourceMappingURL=app.module.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"app.module.js","sourceRoot":"","sources":["../../src/modules/app.module.ts"],"names":[],"mappings":";;;AAAA,2CAAqG;AACrG,2CAA8C;AAC9C,uCAA4C;AAE5C,wDAAoD;AACpD,oDAAgD;AAChD,qDAAkD;AAClD,mDAA+C;AAC/C,mEAA+D;AAC/D,8DAA0D;AAC1D,uDAAmD;AAEtC,QAAA,MAAM,GAAG,CAAC,wBAAU,EAAE,kCAAe,EAAE,0BAAW,EAAE,8BAAa,EAAE,0BAAW,CAAC,CAAC;AAE7F,MAAM,OAAO,GAAG;IACd,GAAG,cAAM;IACT,4BAAY,CAAC,QAAQ,EAAE;IACvB,+BAAc,CAAC,QAAQ,EAAE;IACzB,mBAAY,CAAC,QAAQ,CAAC,cAAgB,CAAC;IACvC,oBAAW,CAAC,QAAQ,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IACxC,qBAAY,CAAC,OAAO,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;CACzC,CAAC;AAEW,QAAA,QAAQ,GAAmB;IACtC,OAAO,EAAE,OAAO;IAChB,SAAS,EAAE,EAAE;IACb,OAAO,EAAE,EAAE;CACZ,CAAC;AAGF,IAAa,SAAS,GAAtB,MAAa,SAAS;IACb,SAAS,CAAC,QAA4B;QAE3C,OAAO,QAAQ,CAAC;IAClB,CAAC;CACF,CAAA;AALY,SAAS;IADrB,IAAA,eAAM,EAAC,gBAAQ,CAAC;GACJ,SAAS,CAKrB;AALY,8BAAS"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"auth.controller.d.ts","sourceRoot":"","sources":["../../../src/modules/auth/auth.controller.ts"],"names":[],"mappings":"AAEA,OAAO,EAAgB,IAAI,EAAE,MAAM,OAAO,CAAC;AAE3C,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAE5D,qBAEa,cAAc;IACf,SAAS,CAAC,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC;IAGrC,IAAI,CAAiB,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CAIjE"}
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AuthController = void 0;
|
|
4
|
-
const common_1 = require("@nestjs/common");
|
|
5
|
-
const swagger_1 = require("@nestjs/swagger");
|
|
6
|
-
const user_decorator_1 = require("../../decorators/user.decorator");
|
|
7
|
-
const auth0_service_1 = require("../../services/auth0.service");
|
|
8
|
-
let AuthController = class AuthController {
|
|
9
|
-
user(userId) {
|
|
10
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
11
|
-
return this.$auth0.getUser({ id: userId });
|
|
12
|
-
});
|
|
13
|
-
}
|
|
14
|
-
};
|
|
15
|
-
__decorate([
|
|
16
|
-
(0, common_1.Inject)(),
|
|
17
|
-
__metadata("design:type", auth0_service_1.Auth0Service)
|
|
18
|
-
], AuthController.prototype, "$auth0", void 0);
|
|
19
|
-
__decorate([
|
|
20
|
-
(0, common_1.Get)('/user'),
|
|
21
|
-
__param(0, (0, user_decorator_1.GetUser)('sub')),
|
|
22
|
-
__metadata("design:type", Function),
|
|
23
|
-
__metadata("design:paramtypes", [String]),
|
|
24
|
-
__metadata("design:returntype", Promise)
|
|
25
|
-
], AuthController.prototype, "user", null);
|
|
26
|
-
AuthController = __decorate([
|
|
27
|
-
(0, common_1.Controller)(),
|
|
28
|
-
(0, swagger_1.ApiTags)('auth')
|
|
29
|
-
], AuthController);
|
|
30
|
-
exports.AuthController = AuthController;
|
|
31
|
-
//# sourceMappingURL=auth.controller.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"auth.controller.js","sourceRoot":"","sources":["../../../src/modules/auth/auth.controller.ts"],"names":[],"mappings":";;;AAAA,2CAAyD;AACzD,6CAA0C;AAE1C,oEAA0D;AAC1D,gEAA4D;AAI5D,IAAa,cAAc,GAA3B,MAAa,cAAc;IAIZ,IAAI,CAAiB,MAAc;;YAC9C,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;QAC7C,CAAC;KAAA;CAEF,CAAA;AAPW;IAAT,IAAA,eAAM,GAAE;8BAA4B,4BAAY;8CAAC;AAGlD;IADC,IAAA,YAAG,EAAC,OAAO,CAAC;IACM,WAAA,IAAA,wBAAO,EAAC,KAAK,CAAC,CAAA;;;;0CAEhC;AANU,cAAc;IAF1B,IAAA,mBAAU,GAAE;IACZ,IAAA,iBAAO,EAAC,MAAM,CAAC;GACH,cAAc,CAQ1B;AARY,wCAAc"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { OrganizationConnection } from 'auth0';
|
|
2
|
-
import { SessionData } from 'express-session';
|
|
3
|
-
import { Auth0Service } from '../../../services/auth0.service';
|
|
4
|
-
export declare class ConnectionController {
|
|
5
|
-
protected readonly auth0: Auth0Service;
|
|
6
|
-
find(session: SessionData): Promise<OrganizationConnection[]>;
|
|
7
|
-
}
|
|
8
|
-
//# sourceMappingURL=connection.controller.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"connection.controller.d.ts","sourceRoot":"","sources":["../../../../src/modules/auth/connections/connection.controller.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,sBAAsB,EAAE,MAAM,OAAO,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAE/D,qBAEa,oBAAoB;IACrB,SAAS,CAAC,QAAQ,CAAC,KAAK,EAAE,YAAY,CAAC;IAGpC,IAAI,CAAY,OAAO,EAAE,WAAW,GAAG,OAAO,CAAC,sBAAsB,EAAE,CAAC;CAItF"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ConnectionController = void 0;
|
|
4
|
-
const common_1 = require("@nestjs/common");
|
|
5
|
-
const swagger_1 = require("@nestjs/swagger");
|
|
6
|
-
const auth0_service_1 = require("../../../services/auth0.service");
|
|
7
|
-
let ConnectionController = class ConnectionController {
|
|
8
|
-
find(session) {
|
|
9
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
10
|
-
return this.auth0.organizations.getEnabledConnections({ id: session.organization.id });
|
|
11
|
-
});
|
|
12
|
-
}
|
|
13
|
-
};
|
|
14
|
-
__decorate([
|
|
15
|
-
(0, common_1.Inject)(),
|
|
16
|
-
__metadata("design:type", auth0_service_1.Auth0Service)
|
|
17
|
-
], ConnectionController.prototype, "auth0", void 0);
|
|
18
|
-
__decorate([
|
|
19
|
-
(0, common_1.Get)('/'),
|
|
20
|
-
__param(0, (0, common_1.Session)()),
|
|
21
|
-
__metadata("design:type", Function),
|
|
22
|
-
__metadata("design:paramtypes", [Object]),
|
|
23
|
-
__metadata("design:returntype", Promise)
|
|
24
|
-
], ConnectionController.prototype, "find", null);
|
|
25
|
-
ConnectionController = __decorate([
|
|
26
|
-
(0, common_1.Controller)(),
|
|
27
|
-
(0, swagger_1.ApiTags)('organization')
|
|
28
|
-
], ConnectionController);
|
|
29
|
-
exports.ConnectionController = ConnectionController;
|
|
30
|
-
//# sourceMappingURL=connection.controller.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"connection.controller.js","sourceRoot":"","sources":["../../../../src/modules/auth/connections/connection.controller.ts"],"names":[],"mappings":";;;AAAA,2CAAkE;AAClE,6CAA0C;AAG1C,mEAA+D;AAI/D,IAAa,oBAAoB,GAAjC,MAAa,oBAAoB;IAIlB,IAAI,CAAY,OAAoB;;YAC/C,OAAO,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,qBAAqB,CAAC,EAAE,EAAE,EAAE,OAAO,CAAC,YAAY,CAAC,EAAE,EAAE,CAAC,CAAC;QACzF,CAAC;KAAA;CAEF,CAAA;AAPW;IAAT,IAAA,eAAM,GAAE;8BAA2B,4BAAY;mDAAC;AAGjD;IADC,IAAA,YAAG,EAAC,GAAG,CAAC;IACU,WAAA,IAAA,gBAAO,GAAE,CAAA;;;;gDAE3B;AANU,oBAAoB;IAFhC,IAAA,mBAAU,GAAE;IACZ,IAAA,iBAAO,EAAC,cAAc,CAAC;GACX,oBAAoB,CAQhC;AARY,oDAAoB"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { ModuleMetadata } from '@nestjs/common';
|
|
2
|
-
import { AppRouter } from '../../../configs/app.router';
|
|
3
|
-
export declare const metadata: ModuleMetadata;
|
|
4
|
-
export declare class ConnectionModule extends AppRouter {
|
|
5
|
-
static readonly path = "/connections";
|
|
6
|
-
static readonly module: typeof ConnectionModule;
|
|
7
|
-
}
|
|
8
|
-
//# sourceMappingURL=connection.module.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"connection.module.d.ts","sourceRoot":"","sources":["../../../../src/modules/auth/connections/connection.module.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,cAAc,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAC;AAGxD,eAAO,MAAM,QAAQ,EAAE,cAKtB,CAAC;AAEF,qBACa,gBAAiB,SAAQ,SAAS;IAC7C,gBAAuB,IAAI,kBAAkB;IAE7C,gBAAuB,MAAM,0BAAoB;CAClD"}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var ConnectionModule_1;
|
|
3
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.ConnectionModule = exports.metadata = void 0;
|
|
5
|
-
const common_1 = require("@nestjs/common");
|
|
6
|
-
const app_router_1 = require("../../../configs/app.router");
|
|
7
|
-
const connection_controller_1 = require("./connection.controller");
|
|
8
|
-
exports.metadata = {
|
|
9
|
-
imports: [],
|
|
10
|
-
controllers: [connection_controller_1.ConnectionController],
|
|
11
|
-
providers: [],
|
|
12
|
-
exports: [],
|
|
13
|
-
};
|
|
14
|
-
let ConnectionModule = ConnectionModule_1 = class ConnectionModule extends app_router_1.AppRouter {
|
|
15
|
-
};
|
|
16
|
-
ConnectionModule.path = '/connections';
|
|
17
|
-
ConnectionModule.module = ConnectionModule_1;
|
|
18
|
-
ConnectionModule = ConnectionModule_1 = __decorate([
|
|
19
|
-
(0, common_1.Module)(exports.metadata)
|
|
20
|
-
], ConnectionModule);
|
|
21
|
-
exports.ConnectionModule = ConnectionModule;
|
|
22
|
-
//# sourceMappingURL=connection.module.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"connection.module.js","sourceRoot":"","sources":["../../../../src/modules/auth/connections/connection.module.ts"],"names":[],"mappings":";;;;AAAA,2CAAwD;AACxD,4DAAwD;AACxD,mEAA+D;AAElD,QAAA,QAAQ,GAAmB;IACtC,OAAO,EAAE,EAAE;IACX,WAAW,EAAE,CAAC,4CAAoB,CAAC;IACnC,SAAS,EAAE,EAAE;IACb,OAAO,EAAE,EAAE;CACZ,CAAC;AAGF,IAAa,gBAAgB,wBAA7B,MAAa,gBAAiB,SAAQ,sBAAS;CAI9C,CAAA;AAHwB,qBAAI,GAAG,cAAe,CAAA;AAEtB,uBAAM,GAAG,kBAAiB,CAAA;AAHtC,gBAAgB;IAD5B,IAAA,eAAM,EAAC,gBAAQ,CAAC;GACJ,gBAAgB,CAI5B;AAJY,4CAAgB"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { AddOrganizationEnabledConnection, UpdateOrganizationEnabledConnection } from 'auth0';
|
|
2
|
-
import 'reflect-metadata';
|
|
3
|
-
export declare class CreateConnectionValidator implements AddOrganizationEnabledConnection {
|
|
4
|
-
connection_id: AddOrganizationEnabledConnection['connection_id'];
|
|
5
|
-
assign_membership_on_login: AddOrganizationEnabledConnection['assign_membership_on_login'];
|
|
6
|
-
}
|
|
7
|
-
export declare class UpdateConnectionValidator implements UpdateOrganizationEnabledConnection {
|
|
8
|
-
assign_membership_on_login: UpdateOrganizationEnabledConnection['assign_membership_on_login'];
|
|
9
|
-
}
|
|
10
|
-
//# sourceMappingURL=connection.validator.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"connection.validator.d.ts","sourceRoot":"","sources":["../../../../src/modules/auth/connections/connection.validator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gCAAgC,EAAE,mCAAmC,EAAE,MAAM,OAAO,CAAC;AAE9F,OAAO,kBAAkB,CAAC;AAE1B,qBAAa,yBAA0B,YAAW,gCAAgC;IAEzE,aAAa,EAAE,gCAAgC,CAAC,eAAe,CAAC,CAAC;IAGjE,0BAA0B,EAAE,gCAAgC,CAAC,4BAA4B,CAAC,CAAC;CACnG;AAED,qBAAa,yBAA0B,YAAW,mCAAmC;IAE5E,0BAA0B,EAAE,mCAAmC,CAAC,4BAA4B,CAAC,CAAC;CACtG"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UpdateConnectionValidator = exports.CreateConnectionValidator = void 0;
|
|
4
|
-
const class_validator_1 = require("class-validator");
|
|
5
|
-
require("reflect-metadata");
|
|
6
|
-
class CreateConnectionValidator {
|
|
7
|
-
}
|
|
8
|
-
__decorate([
|
|
9
|
-
(0, class_validator_1.IsString)(),
|
|
10
|
-
__metadata("design:type", Object)
|
|
11
|
-
], CreateConnectionValidator.prototype, "connection_id", void 0);
|
|
12
|
-
__decorate([
|
|
13
|
-
(0, class_validator_1.IsBoolean)(),
|
|
14
|
-
__metadata("design:type", Object)
|
|
15
|
-
], CreateConnectionValidator.prototype, "assign_membership_on_login", void 0);
|
|
16
|
-
exports.CreateConnectionValidator = CreateConnectionValidator;
|
|
17
|
-
class UpdateConnectionValidator {
|
|
18
|
-
}
|
|
19
|
-
__decorate([
|
|
20
|
-
(0, class_validator_1.IsBoolean)(),
|
|
21
|
-
__metadata("design:type", Object)
|
|
22
|
-
], UpdateConnectionValidator.prototype, "assign_membership_on_login", void 0);
|
|
23
|
-
exports.UpdateConnectionValidator = UpdateConnectionValidator;
|
|
24
|
-
//# sourceMappingURL=connection.validator.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"connection.validator.js","sourceRoot":"","sources":["../../../../src/modules/auth/connections/connection.validator.ts"],"names":[],"mappings":";;;AACA,qDAAsD;AACtD,4BAA0B;AAE1B,MAAa,yBAAyB;CAMrC;AAJC;IADC,IAAA,0BAAQ,GAAE;;gEAC6D;AAGxE;IADC,IAAA,2BAAS,GAAE;;6EACsF;AALpG,8DAMC;AAED,MAAa,yBAAyB;CAGrC;AADC;IADC,IAAA,2BAAS,GAAE;;6EACyF;AAFvG,8DAGC"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { OrganizationMember } from 'auth0';
|
|
2
|
-
import { SessionData } from 'express-session';
|
|
3
|
-
import { Auth0Service } from '../../../services/auth0.service';
|
|
4
|
-
export declare class MemberController {
|
|
5
|
-
protected readonly auth0: Auth0Service;
|
|
6
|
-
find(session: SessionData): Promise<OrganizationMember[]>;
|
|
7
|
-
}
|
|
8
|
-
//# sourceMappingURL=member.controller.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"member.controller.d.ts","sourceRoot":"","sources":["../../../../src/modules/auth/members/member.controller.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,kBAAkB,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAE/D,qBAEa,gBAAgB;IACjB,SAAS,CAAC,QAAQ,CAAC,KAAK,EAAE,YAAY,CAAC;IAGpC,IAAI,CAAY,OAAO,EAAE,WAAW,GAAG,OAAO,CAAC,kBAAkB,EAAE,CAAC;CAIlF"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.MemberController = void 0;
|
|
4
|
-
const common_1 = require("@nestjs/common");
|
|
5
|
-
const swagger_1 = require("@nestjs/swagger");
|
|
6
|
-
const auth0_service_1 = require("../../../services/auth0.service");
|
|
7
|
-
let MemberController = class MemberController {
|
|
8
|
-
find(session) {
|
|
9
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
10
|
-
return this.auth0.organizations.getMembers({ id: session.organization.id });
|
|
11
|
-
});
|
|
12
|
-
}
|
|
13
|
-
};
|
|
14
|
-
__decorate([
|
|
15
|
-
(0, common_1.Inject)(),
|
|
16
|
-
__metadata("design:type", auth0_service_1.Auth0Service)
|
|
17
|
-
], MemberController.prototype, "auth0", void 0);
|
|
18
|
-
__decorate([
|
|
19
|
-
(0, common_1.Get)('/'),
|
|
20
|
-
__param(0, (0, common_1.Session)()),
|
|
21
|
-
__metadata("design:type", Function),
|
|
22
|
-
__metadata("design:paramtypes", [Object]),
|
|
23
|
-
__metadata("design:returntype", Promise)
|
|
24
|
-
], MemberController.prototype, "find", null);
|
|
25
|
-
MemberController = __decorate([
|
|
26
|
-
(0, common_1.Controller)(),
|
|
27
|
-
(0, swagger_1.ApiTags)('organization')
|
|
28
|
-
], MemberController);
|
|
29
|
-
exports.MemberController = MemberController;
|
|
30
|
-
//# sourceMappingURL=member.controller.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"member.controller.js","sourceRoot":"","sources":["../../../../src/modules/auth/members/member.controller.ts"],"names":[],"mappings":";;;AAAA,2CAAkE;AAClE,6CAA0C;AAG1C,mEAA+D;AAI/D,IAAa,gBAAgB,GAA7B,MAAa,gBAAgB;IAId,IAAI,CAAY,OAAoB;;YAC/C,OAAO,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,UAAU,CAAC,EAAE,EAAE,EAAE,OAAO,CAAC,YAAY,CAAC,EAAE,EAAE,CAAC,CAAC;QAC9E,CAAC;KAAA;CAEF,CAAA;AAPW;IAAT,IAAA,eAAM,GAAE;8BAA2B,4BAAY;+CAAC;AAGjD;IADC,IAAA,YAAG,EAAC,GAAG,CAAC;IACU,WAAA,IAAA,gBAAO,GAAE,CAAA;;;;4CAE3B;AANU,gBAAgB;IAF5B,IAAA,mBAAU,GAAE;IACZ,IAAA,iBAAO,EAAC,cAAc,CAAC;GACX,gBAAgB,CAQ5B;AARY,4CAAgB"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { ModuleMetadata } from '@nestjs/common';
|
|
2
|
-
import { AppRouter } from '../../../configs/app.router';
|
|
3
|
-
export declare const metadata: ModuleMetadata;
|
|
4
|
-
export declare class MemberModule extends AppRouter {
|
|
5
|
-
static readonly path = "/members";
|
|
6
|
-
static readonly module: typeof MemberModule;
|
|
7
|
-
}
|
|
8
|
-
//# sourceMappingURL=member.module.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"member.module.d.ts","sourceRoot":"","sources":["../../../../src/modules/auth/members/member.module.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,cAAc,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAC;AAGxD,eAAO,MAAM,QAAQ,EAAE,cAKtB,CAAC;AAEF,qBACa,YAAa,SAAQ,SAAS;IACzC,gBAAuB,IAAI,cAAc;IAEzC,gBAAuB,MAAM,sBAAgB;CAC9C"}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var MemberModule_1;
|
|
3
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.MemberModule = exports.metadata = void 0;
|
|
5
|
-
const common_1 = require("@nestjs/common");
|
|
6
|
-
const app_router_1 = require("../../../configs/app.router");
|
|
7
|
-
const member_controller_1 = require("./member.controller");
|
|
8
|
-
exports.metadata = {
|
|
9
|
-
imports: [],
|
|
10
|
-
controllers: [member_controller_1.MemberController],
|
|
11
|
-
providers: [],
|
|
12
|
-
exports: [],
|
|
13
|
-
};
|
|
14
|
-
let MemberModule = MemberModule_1 = class MemberModule extends app_router_1.AppRouter {
|
|
15
|
-
};
|
|
16
|
-
MemberModule.path = '/members';
|
|
17
|
-
MemberModule.module = MemberModule_1;
|
|
18
|
-
MemberModule = MemberModule_1 = __decorate([
|
|
19
|
-
(0, common_1.Module)(exports.metadata)
|
|
20
|
-
], MemberModule);
|
|
21
|
-
exports.MemberModule = MemberModule;
|
|
22
|
-
//# sourceMappingURL=member.module.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"member.module.js","sourceRoot":"","sources":["../../../../src/modules/auth/members/member.module.ts"],"names":[],"mappings":";;;;AAAA,2CAAwD;AACxD,4DAAwD;AACxD,2DAAuD;AAE1C,QAAA,QAAQ,GAAmB;IACtC,OAAO,EAAE,EAAE;IACX,WAAW,EAAE,CAAC,oCAAgB,CAAC;IAC/B,SAAS,EAAE,EAAE;IACb,OAAO,EAAE,EAAE;CACZ,CAAC;AAGF,IAAa,YAAY,oBAAzB,MAAa,YAAa,SAAQ,sBAAS;CAI1C,CAAA;AAHwB,iBAAI,GAAG,UAAW,CAAA;AAElB,mBAAM,GAAG,cAAa,CAAA;AAHlC,YAAY;IADxB,IAAA,eAAM,EAAC,gBAAQ,CAAC;GACJ,YAAY,CAIxB;AAJY,oCAAY"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"member.validator.d.ts","sourceRoot":"","sources":["../../../../src/modules/auth/members/member.validator.ts"],"names":[],"mappings":"AAAA,OAAO,kBAAkB,CAAC;AAE1B,oBAAY,sBAAsB,GAAG,MAAM,EAAE,CAAA;AAE7C,oBAAY,yBAAyB,GAAG,MAAM,EAAE,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"member.validator.js","sourceRoot":"","sources":["../../../../src/modules/auth/members/member.validator.ts"],"names":[],"mappings":";;AAAA,4BAA0B"}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { Organization } from 'auth0';
|
|
2
|
-
import { Auth0Service } from '../../../services/auth0.service';
|
|
3
|
-
import { OrganizationRepository } from './organization.repository';
|
|
4
|
-
import { CreateOrganizationValidator } from './organization.validator';
|
|
5
|
-
export declare class OrganizationController {
|
|
6
|
-
protected readonly $auth0: Auth0Service;
|
|
7
|
-
protected readonly $repository: OrganizationRepository;
|
|
8
|
-
findAll(id: string): Promise<Organization[]>;
|
|
9
|
-
create(validator: CreateOrganizationValidator): Promise<Organization>;
|
|
10
|
-
validate(slug: string): Promise<{
|
|
11
|
-
name: string;
|
|
12
|
-
available: boolean;
|
|
13
|
-
}>;
|
|
14
|
-
current(id: string): Promise<Organization>;
|
|
15
|
-
}
|
|
16
|
-
//# sourceMappingURL=organization.controller.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"organization.controller.d.ts","sourceRoot":"","sources":["../../../../src/modules/auth/organizations/organization.controller.ts"],"names":[],"mappings":"AAYA,OAAO,EAAwC,YAAY,EAAE,MAAM,OAAO,CAAC;AAI3E,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAC/D,OAAO,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AACnE,OAAO,EAAE,2BAA2B,EAAE,MAAM,0BAA0B,CAAC;AAEvE,qBAEa,sBAAsB;IACvB,SAAS,CAAC,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC;IACxC,SAAS,CAAC,QAAQ,CAAC,WAAW,EAAE,sBAAsB,CAAC;IAGpD,OAAO,CAAiB,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,EAAE,CAAC;IAM5D,MAAM,CAAS,SAAS,EAAE,2BAA2B,GAAG,OAAO,CAAC,YAAY,CAAC;IAwB7E,QAAQ,CAAe,IAAI,EAAE,MAAM;;;;IAiBnC,OAAO,CAAoB,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,CAAC;CAO3E"}
|