easywork-common-lib 1.0.444 → 1.0.446
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/entities/helpers/sales/poliza/poliza_beneficiary.entity.d.ts +2 -3
- package/dist/entities/helpers/sales/poliza/poliza_beneficiary.entity.js +36 -23
- package/dist/entities/helpers/sales/poliza/poliza_beneficiary.entity.js.map +1 -1
- package/dist/entities/sales/beneficiarios/person.entity.d.ts +2 -5
- package/dist/entities/sales/beneficiarios/person.entity.js +37 -35
- package/dist/entities/sales/beneficiarios/person.entity.js.map +1 -1
- package/package.json +1 -1
- package/tsconfig.tsbuildinfo +1 -1
|
@@ -3,10 +3,9 @@ import { Poliza } from "../../../sales/poliza.entity";
|
|
|
3
3
|
import { BeneficiaryPerson } from "../../../sales/beneficiarios/person.entity";
|
|
4
4
|
export declare class PolizaBeneficiary extends BaseEntity {
|
|
5
5
|
id?: string;
|
|
6
|
+
metadata: Record<string, any>;
|
|
6
7
|
polizaId: string;
|
|
7
|
-
beneficiaryId: string;
|
|
8
|
-
relation: string;
|
|
9
|
-
percentage: number;
|
|
10
8
|
poliza: Poliza;
|
|
9
|
+
beneficiaryId: string;
|
|
11
10
|
beneficiary: BeneficiaryPerson;
|
|
12
11
|
}
|
|
@@ -17,50 +17,62 @@ const swagger_1 = require("@nestjs/swagger");
|
|
|
17
17
|
const person_entity_1 = require("../../../sales/beneficiarios/person.entity");
|
|
18
18
|
let PolizaBeneficiary = class PolizaBeneficiary extends typeorm_1.BaseEntity {
|
|
19
19
|
id;
|
|
20
|
+
metadata;
|
|
20
21
|
polizaId;
|
|
21
|
-
beneficiaryId;
|
|
22
|
-
relation;
|
|
23
|
-
percentage;
|
|
24
22
|
poliza;
|
|
23
|
+
beneficiaryId;
|
|
25
24
|
beneficiary;
|
|
26
25
|
};
|
|
27
26
|
exports.PolizaBeneficiary = PolizaBeneficiary;
|
|
28
27
|
__decorate([
|
|
29
|
-
(0, swagger_1.ApiProperty)({
|
|
28
|
+
(0, swagger_1.ApiProperty)({
|
|
29
|
+
type: String,
|
|
30
|
+
description: "UUID of the policy beneficiary",
|
|
31
|
+
format: "uuid",
|
|
32
|
+
}),
|
|
30
33
|
(0, typeorm_1.PrimaryGeneratedColumn)("uuid"),
|
|
31
34
|
__metadata("design:type", String)
|
|
32
35
|
], PolizaBeneficiary.prototype, "id", void 0);
|
|
33
36
|
__decorate([
|
|
34
|
-
(0, swagger_1.ApiProperty)({
|
|
37
|
+
(0, swagger_1.ApiProperty)({
|
|
38
|
+
type: Object,
|
|
39
|
+
description: "Additional metadata for the comment",
|
|
40
|
+
required: false,
|
|
41
|
+
}),
|
|
42
|
+
(0, typeorm_1.Column)({
|
|
43
|
+
type: "json",
|
|
44
|
+
nullable: true,
|
|
45
|
+
}),
|
|
46
|
+
__metadata("design:type", Object)
|
|
47
|
+
], PolizaBeneficiary.prototype, "metadata", void 0);
|
|
48
|
+
__decorate([
|
|
49
|
+
(0, swagger_1.ApiProperty)({ type: String, description: "ID of the associated policy" }),
|
|
35
50
|
(0, typeorm_1.Column)(),
|
|
36
51
|
__metadata("design:type", String)
|
|
37
52
|
], PolizaBeneficiary.prototype, "polizaId", void 0);
|
|
38
|
-
__decorate([
|
|
39
|
-
(0, swagger_1.ApiProperty)({ type: String, description: 'ID of the associated beneficiary', format: 'uuid' }),
|
|
40
|
-
(0, typeorm_1.Column)({ type: "uuid" }),
|
|
41
|
-
__metadata("design:type", String)
|
|
42
|
-
], PolizaBeneficiary.prototype, "beneficiaryId", void 0);
|
|
43
|
-
__decorate([
|
|
44
|
-
(0, swagger_1.ApiProperty)({ type: String, description: 'Relation description or type', required: false }),
|
|
45
|
-
(0, typeorm_1.Column)({ nullable: true }),
|
|
46
|
-
__metadata("design:type", String)
|
|
47
|
-
], PolizaBeneficiary.prototype, "relation", void 0);
|
|
48
|
-
__decorate([
|
|
49
|
-
(0, swagger_1.ApiProperty)({ type: Number, description: 'Distribution percentage', required: false }),
|
|
50
|
-
(0, typeorm_1.Column)({ nullable: true }),
|
|
51
|
-
__metadata("design:type", Number)
|
|
52
|
-
], PolizaBeneficiary.prototype, "percentage", void 0);
|
|
53
53
|
__decorate([
|
|
54
54
|
(0, class_transformer_1.Exclude)(),
|
|
55
|
-
(0, swagger_1.ApiProperty)({ type: () => poliza_entity_1.Poliza, description:
|
|
56
|
-
(0, typeorm_1.ManyToOne)(() => poliza_entity_1.Poliza, poliza => poliza.beneficiaries, {
|
|
55
|
+
(0, swagger_1.ApiProperty)({ type: () => poliza_entity_1.Poliza, description: "Policy entity associated" }),
|
|
56
|
+
(0, typeorm_1.ManyToOne)(() => poliza_entity_1.Poliza, (poliza) => poliza.beneficiaries, {
|
|
57
57
|
onDelete: "CASCADE",
|
|
58
58
|
onUpdate: "CASCADE",
|
|
59
59
|
}),
|
|
60
60
|
__metadata("design:type", poliza_entity_1.Poliza)
|
|
61
61
|
], PolizaBeneficiary.prototype, "poliza", void 0);
|
|
62
62
|
__decorate([
|
|
63
|
-
(0, swagger_1.ApiProperty)({
|
|
63
|
+
(0, swagger_1.ApiProperty)({
|
|
64
|
+
type: String,
|
|
65
|
+
description: "ID of the associated beneficiary",
|
|
66
|
+
format: "uuid",
|
|
67
|
+
}),
|
|
68
|
+
(0, typeorm_1.Column)({ type: "uuid" }),
|
|
69
|
+
__metadata("design:type", String)
|
|
70
|
+
], PolizaBeneficiary.prototype, "beneficiaryId", void 0);
|
|
71
|
+
__decorate([
|
|
72
|
+
(0, swagger_1.ApiProperty)({
|
|
73
|
+
type: () => person_entity_1.BeneficiaryPerson,
|
|
74
|
+
description: "Beneficiary person associated",
|
|
75
|
+
}),
|
|
64
76
|
(0, typeorm_1.ManyToOne)(() => person_entity_1.BeneficiaryPerson, {
|
|
65
77
|
onDelete: "CASCADE",
|
|
66
78
|
onUpdate: "CASCADE",
|
|
@@ -68,6 +80,7 @@ __decorate([
|
|
|
68
80
|
__metadata("design:type", person_entity_1.BeneficiaryPerson)
|
|
69
81
|
], PolizaBeneficiary.prototype, "beneficiary", void 0);
|
|
70
82
|
exports.PolizaBeneficiary = PolizaBeneficiary = __decorate([
|
|
83
|
+
(0, typeorm_1.Index)(["polizaId", "beneficiaryId"], { unique: true }),
|
|
71
84
|
(0, typeorm_1.Entity)()
|
|
72
85
|
], PolizaBeneficiary);
|
|
73
86
|
//# sourceMappingURL=poliza_beneficiary.entity.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"poliza_beneficiary.entity.js","sourceRoot":"","sources":["../../../../../src/entities/helpers/sales/poliza/poliza_beneficiary.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"poliza_beneficiary.entity.js","sourceRoot":"","sources":["../../../../../src/entities/helpers/sales/poliza/poliza_beneficiary.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qCAOiB;AACjB,yDAA4C;AAC5C,gEAAsD;AACtD,6CAA8C;AAC9C,8EAA+E;AAIxE,IAAM,iBAAiB,GAAvB,MAAM,iBAAkB,SAAQ,oBAAU;IAO/C,EAAE,CAAU;IAWZ,QAAQ,CAAsB;IAI9B,QAAQ,CAAS;IAQV,MAAM,CAAS;IAQtB,aAAa,CAAS;IAUf,WAAW,CAAoB;CACvC,CAAA;AAjDY,8CAAiB;AAO5B;IANC,IAAA,qBAAW,EAAC;QACX,IAAI,EAAE,MAAM;QACZ,WAAW,EAAE,gCAAgC;QAC7C,MAAM,EAAE,MAAM;KACf,CAAC;IACD,IAAA,gCAAsB,EAAC,MAAM,CAAC;;6CACnB;AAWZ;IATC,IAAA,qBAAW,EAAC;QACX,IAAI,EAAE,MAAM;QACZ,WAAW,EAAE,qCAAqC;QAClD,QAAQ,EAAE,KAAK;KAChB,CAAC;IACD,IAAA,gBAAM,EAAC;QACN,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACf,CAAC;;mDAC4B;AAI9B;IAFC,IAAA,qBAAW,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,6BAA6B,EAAE,CAAC;IACzE,IAAA,gBAAM,GAAE;;mDACQ;AAQV;IANN,IAAA,2BAAO,GAAE;IACT,IAAA,qBAAW,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,sBAAM,EAAE,WAAW,EAAE,0BAA0B,EAAE,CAAC;IAC5E,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,sBAAM,EAAE,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,aAAa,EAAE;QACzD,QAAQ,EAAE,SAAS;QACnB,QAAQ,EAAE,SAAS;KACpB,CAAC;8BACa,sBAAM;iDAAC;AAQtB;IANC,IAAA,qBAAW,EAAC;QACX,IAAI,EAAE,MAAM;QACZ,WAAW,EAAE,kCAAkC;QAC/C,MAAM,EAAE,MAAM;KACf,CAAC;IACD,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;wDACH;AAUf;IARN,IAAA,qBAAW,EAAC;QACX,IAAI,EAAE,GAAG,EAAE,CAAC,iCAAiB;QAC7B,WAAW,EAAE,+BAA+B;KAC7C,CAAC;IACD,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,iCAAiB,EAAE;QAClC,QAAQ,EAAE,SAAS;QACnB,QAAQ,EAAE,SAAS;KACpB,CAAC;8BACkB,iCAAiB;sDAAC;4BAhD3B,iBAAiB;IAF7B,IAAA,eAAK,EAAC,CAAC,UAAU,EAAE,eAAe,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;IACtD,IAAA,gBAAM,GAAE;GACI,iBAAiB,CAiD7B"}
|
|
@@ -1,13 +1,10 @@
|
|
|
1
1
|
import { EntityBase } from "../../../common/database/base.entity";
|
|
2
2
|
import { User } from "../../user.entity";
|
|
3
|
+
import { PolizaInsurance } from "../../helpers";
|
|
3
4
|
export declare class BeneficiaryPerson extends EntityBase {
|
|
4
5
|
codigo?: number;
|
|
5
6
|
fullName?: string;
|
|
6
|
-
|
|
7
|
-
lastName?: string;
|
|
8
|
-
seniorityDate: Date;
|
|
9
|
-
policyPlan?: string;
|
|
10
|
-
movementDescription?: string;
|
|
7
|
+
company?: PolizaInsurance;
|
|
11
8
|
createdBy?: User;
|
|
12
9
|
modifiedBy?: User;
|
|
13
10
|
}
|
|
@@ -14,55 +14,53 @@ const swagger_1 = require("@nestjs/swagger");
|
|
|
14
14
|
const base_entity_1 = require("../../../common/database/base.entity");
|
|
15
15
|
const typeorm_1 = require("typeorm");
|
|
16
16
|
const user_entity_1 = require("../../user.entity");
|
|
17
|
+
const helpers_1 = require("../../helpers");
|
|
17
18
|
let BeneficiaryPerson = class BeneficiaryPerson extends base_entity_1.EntityBase {
|
|
18
19
|
codigo;
|
|
19
20
|
fullName;
|
|
20
|
-
|
|
21
|
-
lastName;
|
|
22
|
-
seniorityDate;
|
|
23
|
-
policyPlan;
|
|
24
|
-
movementDescription;
|
|
21
|
+
company;
|
|
25
22
|
createdBy;
|
|
26
23
|
modifiedBy;
|
|
27
24
|
};
|
|
28
25
|
exports.BeneficiaryPerson = BeneficiaryPerson;
|
|
29
26
|
__decorate([
|
|
30
|
-
(0, swagger_1.ApiProperty)({
|
|
31
|
-
|
|
27
|
+
(0, swagger_1.ApiProperty)({
|
|
28
|
+
type: Number,
|
|
29
|
+
description: "Codigo de cliente",
|
|
30
|
+
required: false,
|
|
31
|
+
}),
|
|
32
|
+
(0, typeorm_1.Column)({ name: "codigo", nullable: true, unique: true }),
|
|
32
33
|
__metadata("design:type", Number)
|
|
33
34
|
], BeneficiaryPerson.prototype, "codigo", void 0);
|
|
34
35
|
__decorate([
|
|
35
|
-
(0, swagger_1.ApiProperty)({
|
|
36
|
-
|
|
36
|
+
(0, swagger_1.ApiProperty)({
|
|
37
|
+
type: String,
|
|
38
|
+
description: "Full name of the beneficiary",
|
|
39
|
+
required: false,
|
|
40
|
+
}),
|
|
41
|
+
(0, typeorm_1.Column)({ length: 150, nullable: true }),
|
|
37
42
|
__metadata("design:type", String)
|
|
38
43
|
], BeneficiaryPerson.prototype, "fullName", void 0);
|
|
39
44
|
__decorate([
|
|
40
|
-
(0, swagger_1.ApiProperty)({
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
(0,
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
(0,
|
|
51
|
-
(
|
|
52
|
-
|
|
53
|
-
], BeneficiaryPerson.prototype, "seniorityDate", void 0);
|
|
54
|
-
__decorate([
|
|
55
|
-
(0, swagger_1.ApiProperty)({ type: String, description: 'Policy plan', required: false }),
|
|
56
|
-
(0, typeorm_1.Column)({ length: 50, nullable: true }),
|
|
57
|
-
__metadata("design:type", String)
|
|
58
|
-
], BeneficiaryPerson.prototype, "policyPlan", void 0);
|
|
59
|
-
__decorate([
|
|
60
|
-
(0, swagger_1.ApiProperty)({ type: String, description: 'Description of the movement', required: false }),
|
|
61
|
-
(0, typeorm_1.Column)({ length: 50, nullable: true }),
|
|
62
|
-
__metadata("design:type", String)
|
|
63
|
-
], BeneficiaryPerson.prototype, "movementDescription", void 0);
|
|
45
|
+
(0, swagger_1.ApiProperty)({
|
|
46
|
+
type: () => helpers_1.PolizaInsurance,
|
|
47
|
+
description: "Insurance associated with the beneficiary",
|
|
48
|
+
required: false,
|
|
49
|
+
}),
|
|
50
|
+
(0, typeorm_1.ManyToOne)(() => helpers_1.PolizaInsurance, {
|
|
51
|
+
onDelete: "SET NULL",
|
|
52
|
+
onUpdate: "CASCADE",
|
|
53
|
+
nullable: true,
|
|
54
|
+
}),
|
|
55
|
+
(0, typeorm_1.JoinColumn)(),
|
|
56
|
+
__metadata("design:type", helpers_1.PolizaInsurance)
|
|
57
|
+
], BeneficiaryPerson.prototype, "company", void 0);
|
|
64
58
|
__decorate([
|
|
65
|
-
(0, swagger_1.ApiProperty)({
|
|
59
|
+
(0, swagger_1.ApiProperty)({
|
|
60
|
+
type: () => user_entity_1.User,
|
|
61
|
+
description: "User who created the beneficiary",
|
|
62
|
+
required: false,
|
|
63
|
+
}),
|
|
66
64
|
(0, typeorm_1.ManyToOne)(() => user_entity_1.User, {
|
|
67
65
|
onDelete: "SET NULL",
|
|
68
66
|
onUpdate: "CASCADE",
|
|
@@ -72,7 +70,11 @@ __decorate([
|
|
|
72
70
|
__metadata("design:type", user_entity_1.User)
|
|
73
71
|
], BeneficiaryPerson.prototype, "createdBy", void 0);
|
|
74
72
|
__decorate([
|
|
75
|
-
(0, swagger_1.ApiProperty)({
|
|
73
|
+
(0, swagger_1.ApiProperty)({
|
|
74
|
+
type: () => user_entity_1.User,
|
|
75
|
+
description: "User who modified the beneficiary",
|
|
76
|
+
required: false,
|
|
77
|
+
}),
|
|
76
78
|
(0, typeorm_1.ManyToOne)(() => user_entity_1.User, {
|
|
77
79
|
onDelete: "SET NULL",
|
|
78
80
|
onUpdate: "CASCADE",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"person.entity.js","sourceRoot":"","sources":["../../../../src/entities/sales/beneficiarios/person.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,6CAA8C;AAC9C,sEAAkE;AAClE,qCAAgE;AAChE,mDAAyC;
|
|
1
|
+
{"version":3,"file":"person.entity.js","sourceRoot":"","sources":["../../../../src/entities/sales/beneficiarios/person.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,6CAA8C;AAC9C,sEAAkE;AAClE,qCAAgE;AAChE,mDAAyC;AACzC,2CAAgD;AAGzC,IAAM,iBAAiB,GAAvB,MAAM,iBAAkB,SAAQ,wBAAU;IAO/C,MAAM,CAAU;IAShB,QAAQ,CAAU;IAalB,OAAO,CAAmB;IAa1B,SAAS,CAAQ;IAajB,UAAU,CAAQ;CACnB,CAAA;AAxDY,8CAAiB;AAO5B;IANC,IAAA,qBAAW,EAAC;QACX,IAAI,EAAE,MAAM;QACZ,WAAW,EAAE,mBAAmB;QAChC,QAAQ,EAAE,KAAK;KAChB,CAAC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