plac-micro-common 1.2.39 → 1.2.40

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.
@@ -1,7 +1,7 @@
1
- import { ApplicationEntity } from './application.entity';
2
- import { _BaseEntity } from '../_base_entity';
3
- import { AppPersonRole, Gender, IdentifierType } from '../../types';
4
- export declare class AppPerson extends _BaseEntity {
1
+ import { ApplicationEntity } from "./application.entity";
2
+ import { _BaseEntity } from "../_base_entity";
3
+ import { AppPersonRole, Gender, IdentifierType } from "../../types";
4
+ export declare class AppPersonEntity extends _BaseEntity {
5
5
  id: string;
6
6
  application_id: string;
7
7
  role: AppPersonRole;
@@ -9,103 +9,103 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.AppPerson = void 0;
12
+ exports.AppPersonEntity = void 0;
13
13
  const typeorm_1 = require("typeorm");
14
14
  const application_entity_1 = require("./application.entity");
15
15
  const _base_entity_1 = require("../_base_entity");
16
16
  const types_1 = require("../../types");
17
- let AppPerson = class AppPerson extends _base_entity_1._BaseEntity {
17
+ let AppPersonEntity = class AppPersonEntity extends _base_entity_1._BaseEntity {
18
18
  };
19
- exports.AppPerson = AppPerson;
19
+ exports.AppPersonEntity = AppPersonEntity;
20
20
  __decorate([
21
- (0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
21
+ (0, typeorm_1.PrimaryGeneratedColumn)("uuid"),
22
22
  __metadata("design:type", String)
23
- ], AppPerson.prototype, "id", void 0);
23
+ ], AppPersonEntity.prototype, "id", void 0);
24
24
  __decorate([
25
25
  (0, typeorm_1.Index)(),
26
- (0, typeorm_1.Column)({ type: 'uuid' }),
26
+ (0, typeorm_1.Column)({ type: "uuid" }),
27
27
  __metadata("design:type", String)
28
- ], AppPerson.prototype, "application_id", void 0);
28
+ ], AppPersonEntity.prototype, "application_id", void 0);
29
29
  __decorate([
30
30
  (0, typeorm_1.Index)(),
31
- (0, typeorm_1.Column)({ type: 'varchar', length: 30 }),
31
+ (0, typeorm_1.Column)({ type: "varchar", length: 30 }),
32
32
  __metadata("design:type", String)
33
- ], AppPerson.prototype, "role", void 0);
33
+ ], AppPersonEntity.prototype, "role", void 0);
34
34
  __decorate([
35
- (0, typeorm_1.Column)({ type: 'int', default: 1 }),
35
+ (0, typeorm_1.Column)({ type: "int", default: 1 }),
36
36
  __metadata("design:type", Number)
37
- ], AppPerson.prototype, "sequence_no", void 0);
37
+ ], AppPersonEntity.prototype, "sequence_no", void 0);
38
38
  __decorate([
39
- (0, typeorm_1.Column)({ type: 'varchar', length: 200, nullable: true }),
39
+ (0, typeorm_1.Column)({ type: "varchar", length: 200, nullable: true }),
40
40
  __metadata("design:type", Object)
41
- ], AppPerson.prototype, "first_name", void 0);
41
+ ], AppPersonEntity.prototype, "first_name", void 0);
42
42
  __decorate([
43
- (0, typeorm_1.Column)({ type: 'varchar', length: 200, nullable: true }),
43
+ (0, typeorm_1.Column)({ type: "varchar", length: 200, nullable: true }),
44
44
  __metadata("design:type", Object)
45
- ], AppPerson.prototype, "last_name", void 0);
45
+ ], AppPersonEntity.prototype, "last_name", void 0);
46
46
  __decorate([
47
- (0, typeorm_1.Column)({ type: 'varchar', length: 200, nullable: true }),
47
+ (0, typeorm_1.Column)({ type: "varchar", length: 200, nullable: true }),
48
48
  __metadata("design:type", Object)
49
- ], AppPerson.prototype, "first_name_kh", void 0);
49
+ ], AppPersonEntity.prototype, "first_name_kh", void 0);
50
50
  __decorate([
51
- (0, typeorm_1.Column)({ type: 'varchar', length: 200, nullable: true }),
51
+ (0, typeorm_1.Column)({ type: "varchar", length: 200, nullable: true }),
52
52
  __metadata("design:type", Object)
53
- ], AppPerson.prototype, "last_name_kh", void 0);
53
+ ], AppPersonEntity.prototype, "last_name_kh", void 0);
54
54
  __decorate([
55
- (0, typeorm_1.Column)({ type: 'varchar', length: 200 }),
55
+ (0, typeorm_1.Column)({ type: "varchar", length: 200 }),
56
56
  __metadata("design:type", Object)
57
- ], AppPerson.prototype, "full_name", void 0);
57
+ ], AppPersonEntity.prototype, "full_name", void 0);
58
58
  __decorate([
59
- (0, typeorm_1.Column)({ type: 'varchar', length: 200, nullable: true }),
59
+ (0, typeorm_1.Column)({ type: "varchar", length: 200, nullable: true }),
60
60
  __metadata("design:type", Object)
61
- ], AppPerson.prototype, "full_name_kh", void 0);
61
+ ], AppPersonEntity.prototype, "full_name_kh", void 0);
62
62
  __decorate([
63
63
  (0, typeorm_1.Index)(),
64
- (0, typeorm_1.Column)({ type: 'varchar', length: 10, nullable: true }),
64
+ (0, typeorm_1.Column)({ type: "varchar", length: 10, nullable: true }),
65
65
  __metadata("design:type", Object)
66
- ], AppPerson.prototype, "gender", void 0);
66
+ ], AppPersonEntity.prototype, "gender", void 0);
67
67
  __decorate([
68
- (0, typeorm_1.Column)({ type: 'date', nullable: true }),
68
+ (0, typeorm_1.Column)({ type: "date", nullable: true }),
69
69
  __metadata("design:type", Object)
70
- ], AppPerson.prototype, "date_of_birth", void 0);
70
+ ], AppPersonEntity.prototype, "date_of_birth", void 0);
71
71
  __decorate([
72
- (0, typeorm_1.Column)({ type: 'uuid', nullable: true }),
72
+ (0, typeorm_1.Column)({ type: "uuid", nullable: true }),
73
73
  __metadata("design:type", Object)
74
- ], AppPerson.prototype, "nationality_id", void 0);
74
+ ], AppPersonEntity.prototype, "nationality_id", void 0);
75
75
  __decorate([
76
76
  (0, typeorm_1.Index)(),
77
- (0, typeorm_1.Column)({ type: 'varchar', length: 50, nullable: true }),
77
+ (0, typeorm_1.Column)({ type: "varchar", length: 50, nullable: true }),
78
78
  __metadata("design:type", Object)
79
- ], AppPerson.prototype, "identifier_type", void 0);
79
+ ], AppPersonEntity.prototype, "identifier_type", void 0);
80
80
  __decorate([
81
81
  (0, typeorm_1.Index)(),
82
- (0, typeorm_1.Column)({ type: 'varchar', length: 50, nullable: true }),
82
+ (0, typeorm_1.Column)({ type: "varchar", length: 50, nullable: true }),
83
83
  __metadata("design:type", Object)
84
- ], AppPerson.prototype, "identifier_no", void 0);
84
+ ], AppPersonEntity.prototype, "identifier_no", void 0);
85
85
  __decorate([
86
86
  (0, typeorm_1.Index)(),
87
- (0, typeorm_1.Column)({ type: 'varchar', length: 50, nullable: true }),
87
+ (0, typeorm_1.Column)({ type: "varchar", length: 50, nullable: true }),
88
88
  __metadata("design:type", Object)
89
- ], AppPerson.prototype, "phone_number", void 0);
89
+ ], AppPersonEntity.prototype, "phone_number", void 0);
90
90
  __decorate([
91
91
  (0, typeorm_1.Index)(),
92
- (0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: true }),
92
+ (0, typeorm_1.Column)({ type: "varchar", length: 100, nullable: true }),
93
93
  __metadata("design:type", Object)
94
- ], AppPerson.prototype, "email", void 0);
94
+ ], AppPersonEntity.prototype, "email", void 0);
95
95
  __decorate([
96
- (0, typeorm_1.Column)({ type: 'uuid', nullable: true }),
96
+ (0, typeorm_1.Column)({ type: "uuid", nullable: true }),
97
97
  __metadata("design:type", Object)
98
- ], AppPerson.prototype, "relationship_id", void 0);
98
+ ], AppPersonEntity.prototype, "relationship_id", void 0);
99
99
  __decorate([
100
- (0, typeorm_1.Column)({ type: 'boolean', default: true }),
100
+ (0, typeorm_1.Column)({ type: "boolean", default: true }),
101
101
  __metadata("design:type", Boolean)
102
- ], AppPerson.prototype, "is_active", void 0);
102
+ ], AppPersonEntity.prototype, "is_active", void 0);
103
103
  __decorate([
104
- (0, typeorm_1.ManyToOne)(() => application_entity_1.ApplicationEntity, { onDelete: 'CASCADE' }),
105
- (0, typeorm_1.JoinColumn)({ name: 'application_id' }),
104
+ (0, typeorm_1.ManyToOne)(() => application_entity_1.ApplicationEntity, { onDelete: "CASCADE" }),
105
+ (0, typeorm_1.JoinColumn)({ name: "application_id" }),
106
106
  __metadata("design:type", application_entity_1.ApplicationEntity)
107
- ], AppPerson.prototype, "application", void 0);
108
- exports.AppPerson = AppPerson = __decorate([
109
- (0, typeorm_1.Entity)({ schema: 'application', name: 'app_persons' }),
110
- (0, typeorm_1.Unique)('uq_app_person_role_seq', ['application_id', 'role', 'sequence_no'])
111
- ], AppPerson);
107
+ ], AppPersonEntity.prototype, "application", void 0);
108
+ exports.AppPersonEntity = AppPersonEntity = __decorate([
109
+ (0, typeorm_1.Entity)({ schema: "application", name: "app_persons" }),
110
+ (0, typeorm_1.Unique)("uq_app_person_role_seq", ["application_id", "role", "sequence_no"])
111
+ ], AppPersonEntity);
@@ -1,8 +1,8 @@
1
- import { _BaseEntity } from '../_base_entity';
2
- import { ApplicationEntity } from './application.entity';
3
- import { AppPerson } from './app_person.entity';
4
- import { AppCoverageEntity } from './app_coverage.entity';
5
- import { UnderwritingQuestionEntity } from './underwriting_question.entity';
1
+ import { _BaseEntity } from "../_base_entity";
2
+ import { ApplicationEntity } from "./application.entity";
3
+ import { AppCoverageEntity } from "./app_coverage.entity";
4
+ import { UnderwritingQuestionEntity } from "./underwriting_question.entity";
5
+ import { AppPersonEntity } from "./app_person.entity";
6
6
  export declare class AppUnderwritingAnswerEntity extends _BaseEntity {
7
7
  id: string;
8
8
  application_id: string;
@@ -16,7 +16,7 @@ export declare class AppUnderwritingAnswerEntity extends _BaseEntity {
16
16
  remark?: string | null;
17
17
  sequence_no: number;
18
18
  application?: ApplicationEntity;
19
- application_person?: AppPerson | null;
19
+ application_person?: AppPersonEntity | null;
20
20
  app_coverage?: AppCoverageEntity | null;
21
21
  question?: UnderwritingQuestionEntity;
22
22
  }
@@ -13,86 +13,86 @@ exports.AppUnderwritingAnswerEntity = void 0;
13
13
  const typeorm_1 = require("typeorm");
14
14
  const _base_entity_1 = require("../_base_entity");
15
15
  const application_entity_1 = require("./application.entity");
16
- const app_person_entity_1 = require("./app_person.entity");
17
16
  const app_coverage_entity_1 = require("./app_coverage.entity");
18
17
  const underwriting_question_entity_1 = require("./underwriting_question.entity");
18
+ const app_person_entity_1 = require("./app_person.entity");
19
19
  let AppUnderwritingAnswerEntity = class AppUnderwritingAnswerEntity extends _base_entity_1._BaseEntity {
20
20
  };
21
21
  exports.AppUnderwritingAnswerEntity = AppUnderwritingAnswerEntity;
22
22
  __decorate([
23
- (0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
23
+ (0, typeorm_1.PrimaryGeneratedColumn)("uuid"),
24
24
  __metadata("design:type", String)
25
25
  ], AppUnderwritingAnswerEntity.prototype, "id", void 0);
26
26
  __decorate([
27
27
  (0, typeorm_1.Index)(),
28
- (0, typeorm_1.Column)({ type: 'uuid' }),
28
+ (0, typeorm_1.Column)({ type: "uuid" }),
29
29
  __metadata("design:type", String)
30
30
  ], AppUnderwritingAnswerEntity.prototype, "application_id", void 0);
31
31
  __decorate([
32
32
  (0, typeorm_1.Index)(),
33
- (0, typeorm_1.Column)({ type: 'uuid', nullable: true }),
33
+ (0, typeorm_1.Column)({ type: "uuid", nullable: true }),
34
34
  __metadata("design:type", Object)
35
35
  ], AppUnderwritingAnswerEntity.prototype, "application_person_id", void 0);
36
36
  __decorate([
37
37
  (0, typeorm_1.Index)(),
38
- (0, typeorm_1.Column)({ type: 'uuid', nullable: true }),
38
+ (0, typeorm_1.Column)({ type: "uuid", nullable: true }),
39
39
  __metadata("design:type", Object)
40
40
  ], AppUnderwritingAnswerEntity.prototype, "app_coverage_id", void 0);
41
41
  __decorate([
42
42
  (0, typeorm_1.Index)(),
43
- (0, typeorm_1.Column)({ type: 'uuid' }),
43
+ (0, typeorm_1.Column)({ type: "uuid" }),
44
44
  __metadata("design:type", String)
45
45
  ], AppUnderwritingAnswerEntity.prototype, "question_id", void 0);
46
46
  __decorate([
47
- (0, typeorm_1.Column)({ type: 'varchar', length: 2000, nullable: true }),
47
+ (0, typeorm_1.Column)({ type: "varchar", length: 2000, nullable: true }),
48
48
  __metadata("design:type", Object)
49
49
  ], AppUnderwritingAnswerEntity.prototype, "answer_text", void 0);
50
50
  __decorate([
51
- (0, typeorm_1.Column)({ type: 'numeric', precision: 18, scale: 6, nullable: true }),
51
+ (0, typeorm_1.Column)({ type: "numeric", precision: 18, scale: 6, nullable: true }),
52
52
  __metadata("design:type", Object)
53
53
  ], AppUnderwritingAnswerEntity.prototype, "answer_number", void 0);
54
54
  __decorate([
55
- (0, typeorm_1.Column)({ type: 'date', nullable: true }),
55
+ (0, typeorm_1.Column)({ type: "date", nullable: true }),
56
56
  __metadata("design:type", Object)
57
57
  ], AppUnderwritingAnswerEntity.prototype, "answer_date", void 0);
58
58
  __decorate([
59
- (0, typeorm_1.Column)({ type: 'boolean', nullable: true }),
59
+ (0, typeorm_1.Column)({ type: "boolean", nullable: true }),
60
60
  __metadata("design:type", Object)
61
61
  ], AppUnderwritingAnswerEntity.prototype, "answer_bool", void 0);
62
62
  __decorate([
63
- (0, typeorm_1.Column)({ type: 'varchar', length: 2000, nullable: true }),
63
+ (0, typeorm_1.Column)({ type: "varchar", length: 2000, nullable: true }),
64
64
  __metadata("design:type", Object)
65
65
  ], AppUnderwritingAnswerEntity.prototype, "remark", void 0);
66
66
  __decorate([
67
- (0, typeorm_1.Column)({ type: 'integer', default: 1 }),
67
+ (0, typeorm_1.Column)({ type: "integer", default: 1 }),
68
68
  __metadata("design:type", Number)
69
69
  ], AppUnderwritingAnswerEntity.prototype, "sequence_no", void 0);
70
70
  __decorate([
71
- (0, typeorm_1.ManyToOne)(() => application_entity_1.ApplicationEntity, { onDelete: 'RESTRICT' }),
72
- (0, typeorm_1.JoinColumn)({ name: 'application_id' }),
71
+ (0, typeorm_1.ManyToOne)(() => application_entity_1.ApplicationEntity, { onDelete: "RESTRICT" }),
72
+ (0, typeorm_1.JoinColumn)({ name: "application_id" }),
73
73
  __metadata("design:type", application_entity_1.ApplicationEntity)
74
74
  ], AppUnderwritingAnswerEntity.prototype, "application", void 0);
75
75
  __decorate([
76
- (0, typeorm_1.ManyToOne)(() => app_person_entity_1.AppPerson, { onDelete: 'RESTRICT' }),
77
- (0, typeorm_1.JoinColumn)({ name: 'application_person_id' }),
76
+ (0, typeorm_1.ManyToOne)(() => app_person_entity_1.AppPersonEntity, { onDelete: "RESTRICT" }),
77
+ (0, typeorm_1.JoinColumn)({ name: "application_person_id" }),
78
78
  __metadata("design:type", Object)
79
79
  ], AppUnderwritingAnswerEntity.prototype, "application_person", void 0);
80
80
  __decorate([
81
- (0, typeorm_1.ManyToOne)(() => app_coverage_entity_1.AppCoverageEntity, { onDelete: 'RESTRICT' }),
82
- (0, typeorm_1.JoinColumn)({ name: 'app_coverage_id' }),
81
+ (0, typeorm_1.ManyToOne)(() => app_coverage_entity_1.AppCoverageEntity, { onDelete: "RESTRICT" }),
82
+ (0, typeorm_1.JoinColumn)({ name: "app_coverage_id" }),
83
83
  __metadata("design:type", Object)
84
84
  ], AppUnderwritingAnswerEntity.prototype, "app_coverage", void 0);
85
85
  __decorate([
86
- (0, typeorm_1.ManyToOne)(() => underwriting_question_entity_1.UnderwritingQuestionEntity, { onDelete: 'RESTRICT' }),
87
- (0, typeorm_1.JoinColumn)({ name: 'question_id' }),
86
+ (0, typeorm_1.ManyToOne)(() => underwriting_question_entity_1.UnderwritingQuestionEntity, { onDelete: "RESTRICT" }),
87
+ (0, typeorm_1.JoinColumn)({ name: "question_id" }),
88
88
  __metadata("design:type", underwriting_question_entity_1.UnderwritingQuestionEntity)
89
89
  ], AppUnderwritingAnswerEntity.prototype, "question", void 0);
90
90
  exports.AppUnderwritingAnswerEntity = AppUnderwritingAnswerEntity = __decorate([
91
- (0, typeorm_1.Entity)({ schema: 'application', name: 'app_underwriting_answers' }),
92
- (0, typeorm_1.Unique)('uq_app_uw_ans_scope_question', [
93
- 'application_id',
94
- 'application_person_id',
95
- 'app_coverage_id',
96
- 'question_id',
91
+ (0, typeorm_1.Entity)({ schema: "application", name: "app_underwriting_answers" }),
92
+ (0, typeorm_1.Unique)("uq_app_uw_ans_scope_question", [
93
+ "application_id",
94
+ "application_person_id",
95
+ "app_coverage_id",
96
+ "question_id",
97
97
  ])
98
98
  ], AppUnderwritingAnswerEntity);
@@ -1,8 +1,8 @@
1
1
  import { ApplicationEntity } from "./application.entity";
2
2
  import { AppBeneficiaryEntity } from "./app_beneficiary.entity";
3
3
  import { AppCoverageEntity } from "./app_coverage.entity";
4
- import { AppPerson } from "./app_person.entity";
4
+ import { AppPersonEntity } from "./app_person.entity";
5
5
  import { AppUnderwritingAnswerEntity } from "./app_underwriting_answer.entity";
6
6
  import { UnderwritingQuestionEntity } from "./underwriting_question.entity";
7
- export declare const APPLICATION_ENTITIES: readonly [typeof ApplicationEntity, typeof AppBeneficiaryEntity, typeof AppCoverageEntity, typeof AppPerson, typeof AppUnderwritingAnswerEntity, typeof UnderwritingQuestionEntity];
8
- export { ApplicationEntity, AppBeneficiaryEntity, AppCoverageEntity, AppPerson, AppUnderwritingAnswerEntity, UnderwritingQuestionEntity };
7
+ export declare const APPLICATION_ENTITIES: readonly [typeof ApplicationEntity, typeof AppBeneficiaryEntity, typeof AppCoverageEntity, typeof AppPersonEntity, typeof AppUnderwritingAnswerEntity, typeof UnderwritingQuestionEntity];
8
+ export { ApplicationEntity, AppBeneficiaryEntity, AppCoverageEntity, AppPersonEntity, AppUnderwritingAnswerEntity, UnderwritingQuestionEntity, };
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.UnderwritingQuestionEntity = exports.AppUnderwritingAnswerEntity = exports.AppPerson = exports.AppCoverageEntity = exports.AppBeneficiaryEntity = exports.ApplicationEntity = exports.APPLICATION_ENTITIES = void 0;
3
+ exports.UnderwritingQuestionEntity = exports.AppUnderwritingAnswerEntity = exports.AppPersonEntity = exports.AppCoverageEntity = exports.AppBeneficiaryEntity = exports.ApplicationEntity = exports.APPLICATION_ENTITIES = void 0;
4
4
  const application_entity_1 = require("./application.entity");
5
5
  Object.defineProperty(exports, "ApplicationEntity", { enumerable: true, get: function () { return application_entity_1.ApplicationEntity; } });
6
6
  const app_beneficiary_entity_1 = require("./app_beneficiary.entity");
@@ -8,7 +8,7 @@ Object.defineProperty(exports, "AppBeneficiaryEntity", { enumerable: true, get:
8
8
  const app_coverage_entity_1 = require("./app_coverage.entity");
9
9
  Object.defineProperty(exports, "AppCoverageEntity", { enumerable: true, get: function () { return app_coverage_entity_1.AppCoverageEntity; } });
10
10
  const app_person_entity_1 = require("./app_person.entity");
11
- Object.defineProperty(exports, "AppPerson", { enumerable: true, get: function () { return app_person_entity_1.AppPerson; } });
11
+ Object.defineProperty(exports, "AppPersonEntity", { enumerable: true, get: function () { return app_person_entity_1.AppPersonEntity; } });
12
12
  const app_underwriting_answer_entity_1 = require("./app_underwriting_answer.entity");
13
13
  Object.defineProperty(exports, "AppUnderwritingAnswerEntity", { enumerable: true, get: function () { return app_underwriting_answer_entity_1.AppUnderwritingAnswerEntity; } });
14
14
  const underwriting_question_entity_1 = require("./underwriting_question.entity");
@@ -17,7 +17,7 @@ exports.APPLICATION_ENTITIES = [
17
17
  application_entity_1.ApplicationEntity,
18
18
  app_beneficiary_entity_1.AppBeneficiaryEntity,
19
19
  app_coverage_entity_1.AppCoverageEntity,
20
- app_person_entity_1.AppPerson,
20
+ app_person_entity_1.AppPersonEntity,
21
21
  app_underwriting_answer_entity_1.AppUnderwritingAnswerEntity,
22
- underwriting_question_entity_1.UnderwritingQuestionEntity
22
+ underwriting_question_entity_1.UnderwritingQuestionEntity,
23
23
  ];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "plac-micro-common",
3
- "version": "1.2.39",
3
+ "version": "1.2.40",
4
4
  "types": "dist/index.d.ts",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {