tychat-contracts 1.0.9 → 1.0.11
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/index.d.ts +1 -1
- package/dist/auth/index.d.ts.map +1 -1
- package/dist/patients/create-patient.dto.d.ts +1 -1
- package/dist/patients/create-patient.dto.d.ts.map +1 -1
- package/dist/patients/create-patient.dto.js +6 -6
- package/dist/patients/index.d.ts +1 -0
- package/dist/patients/index.d.ts.map +1 -1
- package/dist/patients/index.js +1 -0
- package/dist/patients/list-patients-query.dto.d.ts +5 -0
- package/dist/patients/list-patients-query.dto.d.ts.map +1 -0
- package/dist/patients/list-patients-query.dto.js +45 -0
- package/package.json +1 -1
- package/src/auth/index.ts +1 -1
- package/src/patients/create-patient.dto.ts +5 -5
- package/src/patients/index.ts +1 -0
- package/src/patients/list-patients-query.dto.ts +29 -0
package/dist/auth/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export { LoginDto } from './login.dto';
|
|
2
|
-
export { LoginPayload, ValidatePayload, RefreshPayload, CreateUserPayload, } from './auth-kafka.payloads';
|
|
2
|
+
export type { LoginPayload, ValidatePayload, RefreshPayload, CreateUserPayload, } from './auth-kafka.payloads';
|
|
3
3
|
export { RefreshTokenDto } from './refresh-token.dto';
|
|
4
4
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/auth/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/auth/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/auth/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,YAAY,EACV,YAAY,EACZ,eAAe,EACf,cAAc,EACd,iBAAiB,GAClB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-patient.dto.d.ts","sourceRoot":"","sources":["../../src/patients/create-patient.dto.ts"],"names":[],"mappings":"AAWA,qBAAa,gBAAgB;IAS3B,IAAI,EAAE,MAAM,CAAC;IAUb,GAAG,EAAE,MAAM,CAAC;IAOZ,SAAS,EAAE,MAAM,CAAC;IAOlB,aAAa,EAAE,OAAO,CAAC;IAWvB,qBAAqB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAUtC,
|
|
1
|
+
{"version":3,"file":"create-patient.dto.d.ts","sourceRoot":"","sources":["../../src/patients/create-patient.dto.ts"],"names":[],"mappings":"AAWA,qBAAa,gBAAgB;IAS3B,IAAI,EAAE,MAAM,CAAC;IAUb,GAAG,EAAE,MAAM,CAAC;IAOZ,SAAS,EAAE,MAAM,CAAC;IAOlB,aAAa,EAAE,OAAO,CAAC;IAWvB,qBAAqB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAUtC,kBAAkB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACpC"}
|
|
@@ -18,7 +18,7 @@ class CreatePatientDto {
|
|
|
18
18
|
birthDate;
|
|
19
19
|
hasDisability;
|
|
20
20
|
disabilityDescription;
|
|
21
|
-
|
|
21
|
+
initialObservation;
|
|
22
22
|
}
|
|
23
23
|
exports.CreatePatientDto = CreatePatientDto;
|
|
24
24
|
__decorate([
|
|
@@ -72,12 +72,12 @@ __decorate([
|
|
|
72
72
|
], CreatePatientDto.prototype, "disabilityDescription", void 0);
|
|
73
73
|
__decorate([
|
|
74
74
|
(0, swagger_1.ApiPropertyOptional)({
|
|
75
|
-
description: '
|
|
76
|
-
example: 'Paciente
|
|
77
|
-
maxLength:
|
|
75
|
+
description: 'Observação inicial do paciente (opcional)',
|
|
76
|
+
example: 'Paciente chegou com queixa de dor nas costas',
|
|
77
|
+
maxLength: 2000,
|
|
78
78
|
}),
|
|
79
79
|
(0, class_validator_1.IsString)(),
|
|
80
80
|
(0, class_validator_1.IsOptional)(),
|
|
81
|
-
(0, class_validator_1.MaxLength)(
|
|
81
|
+
(0, class_validator_1.MaxLength)(2000),
|
|
82
82
|
__metadata("design:type", Object)
|
|
83
|
-
], CreatePatientDto.prototype, "
|
|
83
|
+
], CreatePatientDto.prototype, "initialObservation", void 0);
|
package/dist/patients/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/patients/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,6BAA6B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/patients/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,2BAA2B,CAAC"}
|
package/dist/patients/index.js
CHANGED
|
@@ -17,3 +17,4 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
17
17
|
__exportStar(require("./create-patient.dto"), exports);
|
|
18
18
|
__exportStar(require("./update-patient.dto"), exports);
|
|
19
19
|
__exportStar(require("./patient-history-entry.dto"), exports);
|
|
20
|
+
__exportStar(require("./list-patients-query.dto"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-patients-query.dto.d.ts","sourceRoot":"","sources":["../../src/patients/list-patients-query.dto.ts"],"names":[],"mappings":"AAGA,qBAAa,oBAAoB;IAU/B,IAAI,CAAC,EAAE,MAAM,CAAC;IAad,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB"}
|
|
@@ -0,0 +1,45 @@
|
|
|
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.ListPatientsQueryDto = void 0;
|
|
13
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
class ListPatientsQueryDto {
|
|
16
|
+
page;
|
|
17
|
+
limit;
|
|
18
|
+
}
|
|
19
|
+
exports.ListPatientsQueryDto = ListPatientsQueryDto;
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, swagger_1.ApiPropertyOptional)({
|
|
22
|
+
description: 'Número da página (iniciando em 1)',
|
|
23
|
+
example: 1,
|
|
24
|
+
minimum: 1,
|
|
25
|
+
default: 1,
|
|
26
|
+
}),
|
|
27
|
+
(0, class_validator_1.IsOptional)(),
|
|
28
|
+
(0, class_validator_1.IsInt)(),
|
|
29
|
+
(0, class_validator_1.Min)(1),
|
|
30
|
+
__metadata("design:type", Number)
|
|
31
|
+
], ListPatientsQueryDto.prototype, "page", void 0);
|
|
32
|
+
__decorate([
|
|
33
|
+
(0, swagger_1.ApiPropertyOptional)({
|
|
34
|
+
description: 'Quantidade de registros por página',
|
|
35
|
+
example: 20,
|
|
36
|
+
minimum: 1,
|
|
37
|
+
maximum: 100,
|
|
38
|
+
default: 20,
|
|
39
|
+
}),
|
|
40
|
+
(0, class_validator_1.IsOptional)(),
|
|
41
|
+
(0, class_validator_1.IsInt)(),
|
|
42
|
+
(0, class_validator_1.Min)(1),
|
|
43
|
+
(0, class_validator_1.Max)(100),
|
|
44
|
+
__metadata("design:type", Number)
|
|
45
|
+
], ListPatientsQueryDto.prototype, "limit", void 0);
|
package/package.json
CHANGED
package/src/auth/index.ts
CHANGED
|
@@ -56,13 +56,13 @@ export class CreatePatientDto {
|
|
|
56
56
|
disabilityDescription?: string | null;
|
|
57
57
|
|
|
58
58
|
@ApiPropertyOptional({
|
|
59
|
-
description: '
|
|
60
|
-
example: 'Paciente
|
|
61
|
-
maxLength:
|
|
59
|
+
description: 'Observação inicial do paciente (opcional)',
|
|
60
|
+
example: 'Paciente chegou com queixa de dor nas costas',
|
|
61
|
+
maxLength: 2000,
|
|
62
62
|
})
|
|
63
63
|
@IsString()
|
|
64
64
|
@IsOptional()
|
|
65
|
-
@MaxLength(
|
|
66
|
-
|
|
65
|
+
@MaxLength(2000)
|
|
66
|
+
initialObservation?: string | null;
|
|
67
67
|
}
|
|
68
68
|
|
package/src/patients/index.ts
CHANGED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { ApiPropertyOptional } from '@nestjs/swagger';
|
|
2
|
+
import { IsInt, IsOptional, Max, Min } from 'class-validator';
|
|
3
|
+
|
|
4
|
+
export class ListPatientsQueryDto {
|
|
5
|
+
@ApiPropertyOptional({
|
|
6
|
+
description: 'Número da página (iniciando em 1)',
|
|
7
|
+
example: 1,
|
|
8
|
+
minimum: 1,
|
|
9
|
+
default: 1,
|
|
10
|
+
})
|
|
11
|
+
@IsOptional()
|
|
12
|
+
@IsInt()
|
|
13
|
+
@Min(1)
|
|
14
|
+
page?: number;
|
|
15
|
+
|
|
16
|
+
@ApiPropertyOptional({
|
|
17
|
+
description: 'Quantidade de registros por página',
|
|
18
|
+
example: 20,
|
|
19
|
+
minimum: 1,
|
|
20
|
+
maximum: 100,
|
|
21
|
+
default: 20,
|
|
22
|
+
})
|
|
23
|
+
@IsOptional()
|
|
24
|
+
@IsInt()
|
|
25
|
+
@Min(1)
|
|
26
|
+
@Max(100)
|
|
27
|
+
limit?: number;
|
|
28
|
+
}
|
|
29
|
+
|