plac-micro-common 1.3.43 → 1.3.45
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/constants/index.d.ts +1 -0
- package/dist/constants/index.js +15 -0
- package/dist/constants/redis.constant.d.ts +12 -0
- package/dist/constants/redis.constant.js +15 -0
- package/dist/models/application/application.entity.d.ts +5 -1
- package/dist/models/application/application.entity.js +22 -1
- package/dist/types/application.type.d.ts +4 -0
- package/dist/types/application.type.js +6 -1
- package/dist/types/business.type.d.ts +3 -1
- package/dist/types/business.type.js +3 -1
- package/package.json +1 -1
package/dist/constants/index.js
CHANGED
|
@@ -1,4 +1,18 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
2
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
17
|
exports.APP_ERROR_CODES = exports.DISPLAY_DATE_TIME_FORMAT = exports.DISPLAY_DATE_FORMAT = void 0;
|
|
4
18
|
exports.DISPLAY_DATE_FORMAT = "DD MMM YYYY";
|
|
@@ -7,3 +21,4 @@ exports.APP_ERROR_CODES = {
|
|
|
7
21
|
ApplicationNotFound: "APPLICATION_NOT_FOUND",
|
|
8
22
|
ApplicationInfoMissing: "APPLICATION_INFO_MISSING",
|
|
9
23
|
};
|
|
24
|
+
__exportStar(require("./redis.constant"), exports);
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export declare const REDIS_CACHE_KEYS: {
|
|
2
|
+
readonly General: {
|
|
3
|
+
readonly MaritalStatus: "v1:general:dropdown:marital-status";
|
|
4
|
+
readonly Nationality: "v1:general:dropdown:nationality";
|
|
5
|
+
readonly Relationship: "v1:general:dropdown:relationship";
|
|
6
|
+
readonly PaymentMethod: "v1:general:dropdown:payment-method";
|
|
7
|
+
readonly Occupation: "v1:general:dropdown:occupation";
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
export declare const REDIS_CACHE_TTL: {
|
|
11
|
+
Dropdown: number;
|
|
12
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.REDIS_CACHE_TTL = exports.REDIS_CACHE_KEYS = void 0;
|
|
4
|
+
exports.REDIS_CACHE_KEYS = {
|
|
5
|
+
General: {
|
|
6
|
+
MaritalStatus: "v1:general:dropdown:marital-status",
|
|
7
|
+
Nationality: "v1:general:dropdown:nationality",
|
|
8
|
+
Relationship: "v1:general:dropdown:relationship",
|
|
9
|
+
PaymentMethod: "v1:general:dropdown:payment-method",
|
|
10
|
+
Occupation: "v1:general:dropdown:occupation",
|
|
11
|
+
},
|
|
12
|
+
};
|
|
13
|
+
exports.REDIS_CACHE_TTL = {
|
|
14
|
+
Dropdown: 60 * 60 * 6, // 6 hours
|
|
15
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { _BaseEntity } from "../_base_entity";
|
|
2
|
-
import { ApplicationStatus, AppPhLaRelation } from "../../types";
|
|
2
|
+
import { AppFormType, ApplicationStatus, AppPhLaRelation } from "../../types";
|
|
3
3
|
import { OrganizationBranchEntity, OrganizationEntity, OrganizationStaffEntity } from "../core";
|
|
4
4
|
import { AppCoverageEntity } from "./app_coverage.entity";
|
|
5
5
|
import { AppPersonEntity } from "./app_person.entity";
|
|
@@ -10,7 +10,11 @@ import { AppDocumentEntity } from "./app_document.entity";
|
|
|
10
10
|
import { AppPaymentEntity } from "./app_payment.entity";
|
|
11
11
|
export declare class ApplicationEntity extends _BaseEntity {
|
|
12
12
|
id: string;
|
|
13
|
+
form_type: AppFormType;
|
|
13
14
|
application_no: string;
|
|
15
|
+
cover_note_no?: string | null;
|
|
16
|
+
policy_no?: string | null;
|
|
17
|
+
receipt_no?: string | null;
|
|
14
18
|
ph_la_relation: AppPhLaRelation;
|
|
15
19
|
external_ref?: string | null;
|
|
16
20
|
legacy_id?: string | null;
|
|
@@ -30,9 +30,30 @@ __decorate([
|
|
|
30
30
|
__metadata("design:type", String)
|
|
31
31
|
], ApplicationEntity.prototype, "id", void 0);
|
|
32
32
|
__decorate([
|
|
33
|
-
(0, typeorm_1.Column)({
|
|
33
|
+
(0, typeorm_1.Column)({
|
|
34
|
+
type: "varchar",
|
|
35
|
+
length: 10,
|
|
36
|
+
comment: (0, utils_1.enumToCommentString)(types_1.AppFormType),
|
|
37
|
+
default: types_1.AppFormType.FullUnderwriting,
|
|
38
|
+
}),
|
|
39
|
+
__metadata("design:type", String)
|
|
40
|
+
], ApplicationEntity.prototype, "form_type", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
(0, typeorm_1.Column)({ type: "varchar", length: 25, unique: true }),
|
|
34
43
|
__metadata("design:type", String)
|
|
35
44
|
], ApplicationEntity.prototype, "application_no", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
(0, typeorm_1.Column)({ type: "varchar", length: 25, nullable: true, unique: true }),
|
|
47
|
+
__metadata("design:type", Object)
|
|
48
|
+
], ApplicationEntity.prototype, "cover_note_no", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
(0, typeorm_1.Column)({ type: "varchar", length: 25, nullable: true, unique: true }),
|
|
51
|
+
__metadata("design:type", Object)
|
|
52
|
+
], ApplicationEntity.prototype, "policy_no", void 0);
|
|
53
|
+
__decorate([
|
|
54
|
+
(0, typeorm_1.Column)({ type: "varchar", length: 25, nullable: true, unique: true }),
|
|
55
|
+
__metadata("design:type", Object)
|
|
56
|
+
], ApplicationEntity.prototype, "receipt_no", void 0);
|
|
36
57
|
__decorate([
|
|
37
58
|
(0, typeorm_1.Column)({
|
|
38
59
|
type: "varchar",
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AppPaymentStatus = exports.AppPaymentType = exports.AppDocumentType = exports.UwAnswerValueType = exports.AppCoverageType = exports.AppPhLaRelation = exports.AppPersonRole = exports.ApplicationActionType = exports.ApplicationStatus = void 0;
|
|
3
|
+
exports.AppPaymentStatus = exports.AppPaymentType = exports.AppDocumentType = exports.UwAnswerValueType = exports.AppCoverageType = exports.AppPhLaRelation = exports.AppPersonRole = exports.ApplicationActionType = exports.ApplicationStatus = exports.AppFormType = void 0;
|
|
4
|
+
var AppFormType;
|
|
5
|
+
(function (AppFormType) {
|
|
6
|
+
AppFormType["FullUnderwriting"] = "full_uw";
|
|
7
|
+
AppFormType["Simplified"] = "sio";
|
|
8
|
+
})(AppFormType || (exports.AppFormType = AppFormType = {}));
|
|
4
9
|
var ApplicationStatus;
|
|
5
10
|
(function (ApplicationStatus) {
|
|
6
11
|
ApplicationStatus["New"] = "new";
|
|
@@ -17,7 +17,9 @@ export declare enum ChannelType {
|
|
|
17
17
|
}
|
|
18
18
|
export declare enum DocumentType {
|
|
19
19
|
Application = "application",
|
|
20
|
-
Policy = "policy",
|
|
21
20
|
Claim = "claim",
|
|
21
|
+
CoverNote = "cover_note",
|
|
22
|
+
OfficialReceipt = "official_receipt",
|
|
23
|
+
Policy = "policy",
|
|
22
24
|
Quotation = "quotation"
|
|
23
25
|
}
|
|
@@ -23,7 +23,9 @@ var ChannelType;
|
|
|
23
23
|
var DocumentType;
|
|
24
24
|
(function (DocumentType) {
|
|
25
25
|
DocumentType["Application"] = "application";
|
|
26
|
-
DocumentType["Policy"] = "policy";
|
|
27
26
|
DocumentType["Claim"] = "claim";
|
|
27
|
+
DocumentType["CoverNote"] = "cover_note";
|
|
28
|
+
DocumentType["OfficialReceipt"] = "official_receipt";
|
|
29
|
+
DocumentType["Policy"] = "policy";
|
|
28
30
|
DocumentType["Quotation"] = "quotation";
|
|
29
31
|
})(DocumentType || (exports.DocumentType = DocumentType = {}));
|