@biorate/nestjs-tools 1.124.0 → 1.124.1
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/CHANGELOG.md +6 -0
- package/dist/src/app/application/service/client/get-locale.use-case.js +28 -0
- package/dist/src/app/application/service/client/get-locale.use-case.js.map +1 -0
- package/dist/src/app/application/service/client/index.js +2 -2
- package/dist/src/app/application/service/client/index.js.map +1 -1
- package/dist/src/app/application/service/client/set-locale.use-case.js +28 -0
- package/dist/src/app/application/service/client/set-locale.use-case.js.map +1 -0
- package/dist/src/app/infrastructure/controllers/client.controller.js +12 -12
- package/dist/src/app/infrastructure/controllers/client.controller.js.map +1 -1
- package/dist/src/app/infrastructure/controllers/metrics.controller.js +2 -2
- package/dist/src/app/infrastructure/controllers/metrics.controller.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,12 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [1.124.1](https://github.com/biorate/core/compare/v1.124.0...v1.124.1) (2025-05-02)
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
- **nestjs-common:** nameing refactoring ([8225159](https://github.com/biorate/core/commit/82251596524c8e1081ec3c0825f41aef91003558))
|
|
11
|
+
|
|
6
12
|
# [1.124.0](https://github.com/biorate/core/compare/v1.123.0...v1.124.0) (2025-05-01)
|
|
7
13
|
|
|
8
14
|
### Features
|
|
@@ -0,0 +1,28 @@
|
|
|
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.GetLocaleUseCase = void 0;
|
|
13
|
+
const common_1 = require("@nestjs/common");
|
|
14
|
+
const inversion_1 = require("@biorate/inversion");
|
|
15
|
+
let GetLocaleUseCase = class GetLocaleUseCase {
|
|
16
|
+
async execute(lang, namespace) {
|
|
17
|
+
return this.clientProvider.getLang(lang, namespace);
|
|
18
|
+
}
|
|
19
|
+
};
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, common_1.Inject)(inversion_1.Types.ClientProviderPort),
|
|
22
|
+
__metadata("design:type", Object)
|
|
23
|
+
], GetLocaleUseCase.prototype, "clientProvider", void 0);
|
|
24
|
+
GetLocaleUseCase = __decorate([
|
|
25
|
+
(0, common_1.Injectable)()
|
|
26
|
+
], GetLocaleUseCase);
|
|
27
|
+
exports.GetLocaleUseCase = GetLocaleUseCase;
|
|
28
|
+
//# sourceMappingURL=get-locale.use-case.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-locale.use-case.js","sourceRoot":"","sources":["../../../../../../src/app/application/service/client/get-locale.use-case.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAAoD;AACpD,kDAA2C;AAI3C,IAAa,gBAAgB,GAA7B,MAAa,gBAAgB;IAIpB,KAAK,CAAC,OAAO,CAAC,IAAY,EAAE,SAAiB;QAClD,OAAO,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,IAAI,EAAE,SAAS,CAAC,CAAC;IACtD,CAAC;CACF,CAAA;AALoB;IADlB,IAAA,eAAM,EAAC,iBAAK,CAAC,kBAAkB,CAAC;;wDACqB;AAF3C,gBAAgB;IAD5B,IAAA,mBAAU,GAAE;GACA,gBAAgB,CAO5B;AAPY,4CAAgB"}
|
|
@@ -14,6 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./get-
|
|
18
|
-
__exportStar(require("./set-
|
|
17
|
+
__exportStar(require("./get-locale.use-case"), exports);
|
|
18
|
+
__exportStar(require("./set-locale.use-case"), exports);
|
|
19
19
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/app/application/service/client/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/app/application/service/client/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,wDAAsC;AACtC,wDAAsC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
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.SetLocaleUseCase = void 0;
|
|
13
|
+
const common_1 = require("@nestjs/common");
|
|
14
|
+
const inversion_1 = require("@biorate/inversion");
|
|
15
|
+
let SetLocaleUseCase = class SetLocaleUseCase {
|
|
16
|
+
async execute(data, lang, namespace) {
|
|
17
|
+
return this.clientProvider.setLang(data, lang, namespace);
|
|
18
|
+
}
|
|
19
|
+
};
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, common_1.Inject)(inversion_1.Types.ClientProviderPort),
|
|
22
|
+
__metadata("design:type", Object)
|
|
23
|
+
], SetLocaleUseCase.prototype, "clientProvider", void 0);
|
|
24
|
+
SetLocaleUseCase = __decorate([
|
|
25
|
+
(0, common_1.Injectable)()
|
|
26
|
+
], SetLocaleUseCase);
|
|
27
|
+
exports.SetLocaleUseCase = SetLocaleUseCase;
|
|
28
|
+
//# sourceMappingURL=set-locale.use-case.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"set-locale.use-case.js","sourceRoot":"","sources":["../../../../../../src/app/application/service/client/set-locale.use-case.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAAoD;AACpD,kDAA2C;AAI3C,IAAa,gBAAgB,GAA7B,MAAa,gBAAgB;IAIpB,KAAK,CAAC,OAAO,CAAC,IAA4B,EAAE,IAAY,EAAE,SAAiB;QAChF,OAAO,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,IAAI,EAAE,IAAI,EAAE,SAAS,CAAC,CAAC;IAC5D,CAAC;CACF,CAAA;AALoB;IADlB,IAAA,eAAM,EAAC,iBAAK,CAAC,kBAAkB,CAAC;;wDACqB;AAF3C,gBAAgB;IAD5B,IAAA,mBAAU,GAAE;GACA,gBAAgB,CAO5B;AAPY,4CAAgB"}
|
|
@@ -15,18 +15,18 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
15
15
|
exports.ClientController = void 0;
|
|
16
16
|
const common_1 = require("@nestjs/common");
|
|
17
17
|
const swagger_1 = require("@nestjs/swagger");
|
|
18
|
-
const
|
|
18
|
+
const application_1 = require("../../application");
|
|
19
19
|
const dto_1 = require("./dto");
|
|
20
20
|
let ClientController = class ClientController {
|
|
21
|
-
constructor(
|
|
22
|
-
this.
|
|
23
|
-
this.
|
|
21
|
+
constructor(getLoc, setLoc) {
|
|
22
|
+
this.getLoc = getLoc;
|
|
23
|
+
this.setLoc = setLoc;
|
|
24
24
|
}
|
|
25
|
-
|
|
26
|
-
return this.
|
|
25
|
+
getLocale(param) {
|
|
26
|
+
return this.getLoc.execute(param.lang, param.namespace);
|
|
27
27
|
}
|
|
28
|
-
async
|
|
29
|
-
return this.
|
|
28
|
+
async postLocale(param, body) {
|
|
29
|
+
return this.setLoc.execute(body, param.lang, param.namespace);
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
32
|
__decorate([
|
|
@@ -36,7 +36,7 @@ __decorate([
|
|
|
36
36
|
__metadata("design:type", Function),
|
|
37
37
|
__metadata("design:paramtypes", [dto_1.GetLocalesDTO]),
|
|
38
38
|
__metadata("design:returntype", void 0)
|
|
39
|
-
], ClientController.prototype, "
|
|
39
|
+
], ClientController.prototype, "getLocale", null);
|
|
40
40
|
__decorate([
|
|
41
41
|
(0, common_1.Post)('locale/:lang/:namespace'),
|
|
42
42
|
(0, swagger_1.ApiOperation)({ summary: 'Put locale' }),
|
|
@@ -45,12 +45,12 @@ __decorate([
|
|
|
45
45
|
__metadata("design:type", Function),
|
|
46
46
|
__metadata("design:paramtypes", [dto_1.PostLocalesDTO, Object]),
|
|
47
47
|
__metadata("design:returntype", Promise)
|
|
48
|
-
], ClientController.prototype, "
|
|
48
|
+
], ClientController.prototype, "postLocale", null);
|
|
49
49
|
ClientController = __decorate([
|
|
50
50
|
(0, swagger_1.ApiTags)('Client'),
|
|
51
51
|
(0, common_1.Controller)('client'),
|
|
52
|
-
__metadata("design:paramtypes", [
|
|
53
|
-
|
|
52
|
+
__metadata("design:paramtypes", [application_1.GetLocaleUseCase,
|
|
53
|
+
application_1.SetLocaleUseCase])
|
|
54
54
|
], ClientController);
|
|
55
55
|
exports.ClientController = ClientController;
|
|
56
56
|
//# sourceMappingURL=client.controller.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.controller.js","sourceRoot":"","sources":["../../../../../src/app/infrastructure/controllers/client.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,2CAA4E;AAC5E,6CAAwD;AACxD,
|
|
1
|
+
{"version":3,"file":"client.controller.js","sourceRoot":"","sources":["../../../../../src/app/infrastructure/controllers/client.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,2CAA4E;AAC5E,6CAAwD;AACxD,mDAAuE;AACvE,+BAAsD;AAEtD,IAEa,gBAAgB,GAF7B,MAEa,gBAAgB;IAC3B,YACqB,MAAwB,EACxB,MAAwB;QADxB,WAAM,GAAN,MAAM,CAAkB;QACxB,WAAM,GAAN,MAAM,CAAkB;IAC1C,CAAC;IAIM,SAAS,CAAU,KAAoB;QAC/C,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;IAC1D,CAAC;IAIe,AAAN,KAAK,CAAC,UAAU,CACf,KAAqB,EACtB,IAA4B;QAEpC,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;IAChE,CAAC;CACF,CAAA;AAZW;IAFT,IAAA,YAAG,EAAC,yBAAyB,CAAC;IAC9B,IAAA,sBAAY,EAAC,EAAE,OAAO,EAAE,YAAY,EAAE,CAAC;IACnB,WAAA,IAAA,cAAK,GAAE,CAAA;;qCAAQ,mBAAa;;iDAEhD;AAIe;IAFf,IAAA,aAAI,EAAC,yBAAyB,CAAC;IAC/B,IAAA,sBAAY,EAAC,EAAE,OAAO,EAAE,YAAY,EAAE,CAAC;IAErC,WAAA,IAAA,cAAK,GAAE,CAAA;IACP,WAAA,IAAA,aAAI,GAAE,CAAA;;qCADS,oBAAc;;kDAI/B;AAnBU,gBAAgB;IAF5B,IAAA,iBAAO,EAAC,QAAQ,CAAC;IACjB,IAAA,mBAAU,EAAC,QAAQ,CAAC;qCAGU,8BAAgB;QAChB,8BAAgB;GAHlC,gBAAgB,CAoB5B;AApBY,4CAAgB"}
|
|
@@ -12,7 +12,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
12
12
|
exports.MetricsController = void 0;
|
|
13
13
|
const common_1 = require("@nestjs/common");
|
|
14
14
|
const swagger_1 = require("@nestjs/swagger");
|
|
15
|
-
const
|
|
15
|
+
const application_1 = require("../../application");
|
|
16
16
|
let MetricsController = class MetricsController {
|
|
17
17
|
constructor(getMetrics) {
|
|
18
18
|
this.getMetrics = getMetrics;
|
|
@@ -32,7 +32,7 @@ __decorate([
|
|
|
32
32
|
MetricsController = __decorate([
|
|
33
33
|
(0, swagger_1.ApiTags)('Metrics'),
|
|
34
34
|
(0, common_1.Controller)('metrics'),
|
|
35
|
-
__metadata("design:paramtypes", [
|
|
35
|
+
__metadata("design:paramtypes", [application_1.GetMetricsUseCase])
|
|
36
36
|
], MetricsController);
|
|
37
37
|
exports.MetricsController = MetricsController;
|
|
38
38
|
//# sourceMappingURL=metrics.controller.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"metrics.controller.js","sourceRoot":"","sources":["../../../../../src/app/infrastructure/controllers/metrics.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAAyD;AACzD,6CAAwD;AACxD
|
|
1
|
+
{"version":3,"file":"metrics.controller.js","sourceRoot":"","sources":["../../../../../src/app/infrastructure/controllers/metrics.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAAyD;AACzD,6CAAwD;AACxD,mDAAsD;AAEtD,IAEa,iBAAiB,GAF9B,MAEa,iBAAiB;IAC5B,YAAsC,UAA6B;QAA7B,eAAU,GAAV,UAAU,CAAmB;IAAG,CAAC;IAKvD,AAAN,KAAK,CAAC,OAAO;QACrB,OAAO,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC;IACnC,CAAC;CACF,CAAA;AAHiB;IAHf,IAAA,YAAG,GAAE;IACL,IAAA,eAAM,EAAC,cAAc,EAAE,YAAY,CAAC;IACpC,IAAA,sBAAY,EAAC,EAAE,OAAO,EAAE,yBAAyB,EAAE,CAAC;;;;gDAGpD;AARU,iBAAiB;IAF7B,IAAA,iBAAO,EAAC,SAAS,CAAC;IAClB,IAAA,mBAAU,EAAC,SAAS,CAAC;qCAE8B,+BAAiB;GADxD,iBAAiB,CAS7B;AATY,8CAAiB"}
|