law-common 2.9.0 → 2.9.2-beta.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/src/api/index.d.ts +1 -1
- package/dist/src/api/index.js +1 -1
- package/dist/src/api/interface/bank.entity.response.d.ts +11 -0
- package/dist/src/api/interface/bank.update.dto.interface.d.ts +2 -1
- package/dist/src/api/interface/bank_history.api.d.ts +3 -0
- package/dist/src/api/interface/user.create.dto.interace.d.ts +1 -1
- package/dist/src/api/interface/user.update.dto.interface.d.ts +1 -1
- package/dist/src/entities/enums/bank_action.enum.d.ts +12 -0
- package/dist/src/entities/enums/bank_action.enum.js +43 -0
- package/dist/src/entities/enums/bank_entity_keys.enum.d.ts +17 -0
- package/dist/src/entities/enums/bank_entity_keys.enum.js +51 -0
- package/dist/src/entities/enums/bank_status.enum.d.ts +13 -0
- package/dist/src/entities/enums/bank_status.enum.js +26 -0
- package/dist/src/entities/enums/user.entity.enum.d.ts +7 -1
- package/dist/src/entities/enums/user.entity.enum.js +8 -1
- package/dist/src/entities/index.d.ts +4 -0
- package/dist/src/entities/index.js +4 -0
- package/dist/src/entities/interface/bank.entity.interface.d.ts +9 -1
- package/dist/src/entities/interface/bank_history.entity.interface.d.ts +14 -0
- package/dist/src/entities/interface/bank_history.entity.interface.js +5 -0
- package/dist/src/entities/interface/client.entity.interface.d.ts +1 -1
- package/dist/src/entities/interface/entity.utils.interface.d.ts +38 -2
- package/dist/src/entities/interface/timesheet_history.entity.interface.d.ts +0 -23
- package/dist/src/entities/interface/user.entity.interface.d.ts +4 -2
- package/dist/src/entities/interface/user.entity.interface.js +3 -0
- package/dist/src/enums/error.key.enum.d.ts +3 -1
- package/dist/src/enums/error.key.enum.js +2 -0
- package/package.json +33 -33
- package/dist/src/api/interface/timesheet_history_entity.response.d.ts +0 -12
- /package/dist/src/api/interface/{timesheet_history_entity.response.js → bank_history.api.js} +0 -0
package/dist/src/api/index.d.ts
CHANGED
|
@@ -63,4 +63,4 @@ export * from "./interface/billing.history.api";
|
|
|
63
63
|
export * from "./interface/billing_timesheet_history.api";
|
|
64
64
|
export * from "./interface/reimbursement_history.api";
|
|
65
65
|
export * from "./interface/reimbursement_expense.api";
|
|
66
|
-
export * from "./interface/
|
|
66
|
+
export * from "./interface/bank_history.api";
|
package/dist/src/api/index.js
CHANGED
|
@@ -79,4 +79,4 @@ __exportStar(require("./interface/billing.history.api"), exports);
|
|
|
79
79
|
__exportStar(require("./interface/billing_timesheet_history.api"), exports);
|
|
80
80
|
__exportStar(require("./interface/reimbursement_history.api"), exports);
|
|
81
81
|
__exportStar(require("./interface/reimbursement_expense.api"), exports);
|
|
82
|
-
__exportStar(require("./interface/
|
|
82
|
+
__exportStar(require("./interface/bank_history.api"), exports);
|
|
@@ -1,4 +1,15 @@
|
|
|
1
|
+
import { BankActionEnum, BankStatusEnum } from "../../entities";
|
|
1
2
|
import { IBankApiEntity } from "./bank.entity.api";
|
|
2
3
|
import { IBaseResponse } from "./base.response.interface";
|
|
3
4
|
export type IBankApiEntityResponse = IBaseResponse<IBankApiEntity>;
|
|
4
5
|
export type IBankApiEntityResponseArray = IBaseResponse<IBankApiEntity[]>;
|
|
6
|
+
export type IBankFlowConfig = {
|
|
7
|
+
[key in BankStatusEnum]?: {
|
|
8
|
+
actions: {
|
|
9
|
+
[key in BankActionEnum]?: {
|
|
10
|
+
permissions: string[];
|
|
11
|
+
next: () => BankStatusEnum;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IUserApiEntity } from "./user.entity.api";
|
|
2
|
-
export interface IUserCreateDto extends Omit<IUserApiEntity, "id" | "updatedOn" | "updatedBy" | "createdBy" | "createdOn"> {
|
|
2
|
+
export interface IUserCreateDto extends Omit<IUserApiEntity, "id" | "updatedOn" | "updatedBy" | "createdBy" | "createdOn" | "password" | "status"> {
|
|
3
3
|
panDocument?: File;
|
|
4
4
|
aadharDocument?: File;
|
|
5
5
|
passportDocument?: File;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IUserApiEntity } from "./user.entity.api";
|
|
2
|
-
export interface IUserUpdateDto extends Omit<IUserApiEntity,
|
|
2
|
+
export interface IUserUpdateDto extends Omit<IUserApiEntity, "createdOn" | "updatedOn" | "createdBy" | "updatedBy" | "id"> {
|
|
3
3
|
panDocument?: File;
|
|
4
4
|
aadharDocument?: File;
|
|
5
5
|
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export declare enum BankActionEnum {
|
|
2
|
+
VIEW = "view",
|
|
3
|
+
EDIT = "edit",
|
|
4
|
+
DELETE = "delete",
|
|
5
|
+
CREATE = "create",
|
|
6
|
+
APPROVE = "approve",
|
|
7
|
+
REJECT = "reject",
|
|
8
|
+
RECALL = "recall"
|
|
9
|
+
}
|
|
10
|
+
export declare namespace BankActionEnum {
|
|
11
|
+
function getLabel(action: BankActionEnum): string;
|
|
12
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BankActionEnum = void 0;
|
|
4
|
+
const error_key_enum_1 = require("../../enums/error.key.enum");
|
|
5
|
+
const exceptions_1 = require("../../exceptions");
|
|
6
|
+
var BankActionEnum;
|
|
7
|
+
(function (BankActionEnum) {
|
|
8
|
+
BankActionEnum["VIEW"] = "view";
|
|
9
|
+
BankActionEnum["EDIT"] = "edit";
|
|
10
|
+
BankActionEnum["DELETE"] = "delete";
|
|
11
|
+
BankActionEnum["CREATE"] = "create";
|
|
12
|
+
BankActionEnum["APPROVE"] = "approve";
|
|
13
|
+
BankActionEnum["REJECT"] = "reject";
|
|
14
|
+
BankActionEnum["RECALL"] = "recall";
|
|
15
|
+
})(BankActionEnum || (exports.BankActionEnum = BankActionEnum = {}));
|
|
16
|
+
(function (BankActionEnum) {
|
|
17
|
+
const actionLabelMap = {
|
|
18
|
+
[BankActionEnum.APPROVE]: "Approve",
|
|
19
|
+
[BankActionEnum.VIEW]: "View",
|
|
20
|
+
[BankActionEnum.EDIT]: "Edit",
|
|
21
|
+
[BankActionEnum.DELETE]: "Delete",
|
|
22
|
+
[BankActionEnum.CREATE]: "Create",
|
|
23
|
+
[BankActionEnum.REJECT]: "Reject",
|
|
24
|
+
[BankActionEnum.RECALL]: "Recall",
|
|
25
|
+
};
|
|
26
|
+
function getLabel(action) {
|
|
27
|
+
if (!Object.values(BankActionEnum).includes(action)) {
|
|
28
|
+
throw new exceptions_1.AppBadRequestException({
|
|
29
|
+
key: error_key_enum_1.ErrorKeyEnum.BANK_FLOW_ACTION,
|
|
30
|
+
message: ["Invalid action value"],
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
const label = actionLabelMap[action];
|
|
34
|
+
if (!label) {
|
|
35
|
+
throw new exceptions_1.AppBadRequestException({
|
|
36
|
+
key: error_key_enum_1.ErrorKeyEnum.BANK_FLOW_ACTION,
|
|
37
|
+
message: ["Invalid action value"],
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
return label;
|
|
41
|
+
}
|
|
42
|
+
BankActionEnum.getLabel = getLabel;
|
|
43
|
+
})(BankActionEnum || (exports.BankActionEnum = BankActionEnum = {}));
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export declare enum BankEntityKeysEnum {
|
|
2
|
+
id = "id",
|
|
3
|
+
accountName = "accountName",
|
|
4
|
+
organizationId = "organizationId",
|
|
5
|
+
name = "name",
|
|
6
|
+
accountNo = "accountNo",
|
|
7
|
+
branchAddress = "branchAddress",
|
|
8
|
+
micrCode = "micrCode",
|
|
9
|
+
ifscCode = "ifscCode",
|
|
10
|
+
emailForPaymentInfoCsv = "emailForPaymentInfoCsv",
|
|
11
|
+
status = "status",
|
|
12
|
+
remark = "remark"
|
|
13
|
+
}
|
|
14
|
+
export declare namespace BankEntityKeysEnum {
|
|
15
|
+
const keyLabelMap: Record<BankEntityKeysEnum, string>;
|
|
16
|
+
function getLabel(key: BankEntityKeysEnum): string;
|
|
17
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BankEntityKeysEnum = void 0;
|
|
4
|
+
const error_key_enum_1 = require("../../enums/error.key.enum");
|
|
5
|
+
const exceptions_1 = require("../../exceptions");
|
|
6
|
+
var BankEntityKeysEnum;
|
|
7
|
+
(function (BankEntityKeysEnum) {
|
|
8
|
+
BankEntityKeysEnum["id"] = "id";
|
|
9
|
+
BankEntityKeysEnum["accountName"] = "accountName";
|
|
10
|
+
BankEntityKeysEnum["organizationId"] = "organizationId";
|
|
11
|
+
BankEntityKeysEnum["name"] = "name";
|
|
12
|
+
BankEntityKeysEnum["accountNo"] = "accountNo";
|
|
13
|
+
BankEntityKeysEnum["branchAddress"] = "branchAddress";
|
|
14
|
+
BankEntityKeysEnum["micrCode"] = "micrCode";
|
|
15
|
+
BankEntityKeysEnum["ifscCode"] = "ifscCode";
|
|
16
|
+
BankEntityKeysEnum["emailForPaymentInfoCsv"] = "emailForPaymentInfoCsv";
|
|
17
|
+
BankEntityKeysEnum["status"] = "status";
|
|
18
|
+
BankEntityKeysEnum["remark"] = "remark";
|
|
19
|
+
})(BankEntityKeysEnum || (exports.BankEntityKeysEnum = BankEntityKeysEnum = {}));
|
|
20
|
+
(function (BankEntityKeysEnum) {
|
|
21
|
+
BankEntityKeysEnum.keyLabelMap = {
|
|
22
|
+
[BankEntityKeysEnum.id]: "Bank ID",
|
|
23
|
+
[BankEntityKeysEnum.accountName]: "Account Name",
|
|
24
|
+
[BankEntityKeysEnum.organizationId]: "Organization ID",
|
|
25
|
+
[BankEntityKeysEnum.name]: "Bank Name",
|
|
26
|
+
[BankEntityKeysEnum.accountNo]: "Account Number",
|
|
27
|
+
[BankEntityKeysEnum.branchAddress]: "Branch Address",
|
|
28
|
+
[BankEntityKeysEnum.micrCode]: "MICR Code",
|
|
29
|
+
[BankEntityKeysEnum.ifscCode]: "IFSC Code",
|
|
30
|
+
[BankEntityKeysEnum.emailForPaymentInfoCsv]: "Email for Payment Info CSV",
|
|
31
|
+
[BankEntityKeysEnum.status]: "Status",
|
|
32
|
+
[BankEntityKeysEnum.remark]: "Remark",
|
|
33
|
+
};
|
|
34
|
+
function getLabel(key) {
|
|
35
|
+
if (!Object.values(BankEntityKeysEnum).includes(key)) {
|
|
36
|
+
throw new exceptions_1.AppBadRequestException({
|
|
37
|
+
key: error_key_enum_1.ErrorKeyEnum.BANK_KEY,
|
|
38
|
+
message: ["Invalid key name"],
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
const label = BankEntityKeysEnum.keyLabelMap[key];
|
|
42
|
+
if (!label) {
|
|
43
|
+
throw new exceptions_1.AppBadRequestException({
|
|
44
|
+
key: error_key_enum_1.ErrorKeyEnum.BANK_KEY,
|
|
45
|
+
message: ["Invalid key name"],
|
|
46
|
+
});
|
|
47
|
+
}
|
|
48
|
+
return label;
|
|
49
|
+
}
|
|
50
|
+
BankEntityKeysEnum.getLabel = getLabel;
|
|
51
|
+
})(BankEntityKeysEnum || (exports.BankEntityKeysEnum = BankEntityKeysEnum = {}));
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare enum BankStatusEnum {
|
|
2
|
+
CREATE_APPROVAL = "create_approval",
|
|
3
|
+
EDIT_APPROVAL = "edit_approval",
|
|
4
|
+
DELETE_APPROVAL = "delete_approval",
|
|
5
|
+
REJECTED = "rejected",
|
|
6
|
+
APPROVED = "approved",
|
|
7
|
+
DELETED = "deleted",
|
|
8
|
+
RESOLVED_REJECTED = "resolved_rejected"
|
|
9
|
+
}
|
|
10
|
+
export declare namespace BankStatusEnum {
|
|
11
|
+
function getNames(): string[];
|
|
12
|
+
function parse(value: string): BankStatusEnum;
|
|
13
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BankStatusEnum = void 0;
|
|
4
|
+
var BankStatusEnum;
|
|
5
|
+
(function (BankStatusEnum) {
|
|
6
|
+
BankStatusEnum["CREATE_APPROVAL"] = "create_approval";
|
|
7
|
+
BankStatusEnum["EDIT_APPROVAL"] = "edit_approval";
|
|
8
|
+
BankStatusEnum["DELETE_APPROVAL"] = "delete_approval";
|
|
9
|
+
BankStatusEnum["REJECTED"] = "rejected";
|
|
10
|
+
BankStatusEnum["APPROVED"] = "approved";
|
|
11
|
+
BankStatusEnum["DELETED"] = "deleted";
|
|
12
|
+
BankStatusEnum["RESOLVED_REJECTED"] = "resolved_rejected";
|
|
13
|
+
})(BankStatusEnum || (exports.BankStatusEnum = BankStatusEnum = {}));
|
|
14
|
+
(function (BankStatusEnum) {
|
|
15
|
+
function getNames() {
|
|
16
|
+
return Object.values(BankStatusEnum).filter((value) => typeof value === "string");
|
|
17
|
+
}
|
|
18
|
+
BankStatusEnum.getNames = getNames;
|
|
19
|
+
function parse(value) {
|
|
20
|
+
if (Object.values(BankStatusEnum).includes(value)) {
|
|
21
|
+
return value;
|
|
22
|
+
}
|
|
23
|
+
throw new Error("Invalid bank status");
|
|
24
|
+
}
|
|
25
|
+
BankStatusEnum.parse = parse;
|
|
26
|
+
})(BankStatusEnum || (exports.BankStatusEnum = BankStatusEnum = {}));
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
export declare enum UserStatusEnum {
|
|
2
2
|
active = "active",
|
|
3
3
|
deactive = "deactive",
|
|
4
|
-
suspended = "suspended"
|
|
4
|
+
suspended = "suspended",
|
|
5
|
+
pending = "pending"
|
|
5
6
|
}
|
|
6
7
|
export declare enum UserRoleEnum {
|
|
7
8
|
admin = "admin",
|
|
@@ -12,6 +13,11 @@ export declare enum UserRoleEnum {
|
|
|
12
13
|
secretary = "secretary",
|
|
13
14
|
hr = "hr"
|
|
14
15
|
}
|
|
16
|
+
export declare enum UserGenderEnum {
|
|
17
|
+
male = "male",
|
|
18
|
+
female = "female",
|
|
19
|
+
prefer_not_to_say = "prefer_not_to_say"
|
|
20
|
+
}
|
|
15
21
|
export declare namespace UserRoleEnum {
|
|
16
22
|
function getNames(): string[];
|
|
17
23
|
function parse(value: string): UserRoleEnum;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UserRoleEnum = exports.UserStatusEnum = void 0;
|
|
3
|
+
exports.UserGenderEnum = exports.UserRoleEnum = exports.UserStatusEnum = void 0;
|
|
4
4
|
var UserStatusEnum;
|
|
5
5
|
(function (UserStatusEnum) {
|
|
6
6
|
UserStatusEnum["active"] = "active";
|
|
7
7
|
UserStatusEnum["deactive"] = "deactive";
|
|
8
8
|
UserStatusEnum["suspended"] = "suspended";
|
|
9
|
+
UserStatusEnum["pending"] = "pending";
|
|
9
10
|
})(UserStatusEnum || (exports.UserStatusEnum = UserStatusEnum = {}));
|
|
10
11
|
var UserRoleEnum;
|
|
11
12
|
(function (UserRoleEnum) {
|
|
@@ -17,6 +18,12 @@ var UserRoleEnum;
|
|
|
17
18
|
UserRoleEnum["secretary"] = "secretary";
|
|
18
19
|
UserRoleEnum["hr"] = "hr";
|
|
19
20
|
})(UserRoleEnum || (exports.UserRoleEnum = UserRoleEnum = {}));
|
|
21
|
+
var UserGenderEnum;
|
|
22
|
+
(function (UserGenderEnum) {
|
|
23
|
+
UserGenderEnum["male"] = "male";
|
|
24
|
+
UserGenderEnum["female"] = "female";
|
|
25
|
+
UserGenderEnum["prefer_not_to_say"] = "prefer_not_to_say";
|
|
26
|
+
})(UserGenderEnum || (exports.UserGenderEnum = UserGenderEnum = {}));
|
|
20
27
|
(function (UserRoleEnum) {
|
|
21
28
|
function getNames() {
|
|
22
29
|
return Object.values(UserRoleEnum).filter((value) => typeof value === "string");
|
|
@@ -48,3 +48,7 @@ export * from "./interface/reimbursement_history.entity.interface";
|
|
|
48
48
|
export * from "./interface/reimbursement_expense.entity.interface";
|
|
49
49
|
export * from "./enums/entity_search_constraint_type.enum";
|
|
50
50
|
export * from "./enums/timesheet_entity_keys.enum";
|
|
51
|
+
export * from "./enums/bank_action.enum";
|
|
52
|
+
export * from "./enums/bank_status.enum";
|
|
53
|
+
export * from "./interface/bank_history.entity.interface";
|
|
54
|
+
export * from "./enums/bank_entity_keys.enum";
|
|
@@ -64,3 +64,7 @@ __exportStar(require("./interface/reimbursement_history.entity.interface"), expo
|
|
|
64
64
|
__exportStar(require("./interface/reimbursement_expense.entity.interface"), exports);
|
|
65
65
|
__exportStar(require("./enums/entity_search_constraint_type.enum"), exports);
|
|
66
66
|
__exportStar(require("./enums/timesheet_entity_keys.enum"), exports);
|
|
67
|
+
__exportStar(require("./enums/bank_action.enum"), exports);
|
|
68
|
+
__exportStar(require("./enums/bank_status.enum"), exports);
|
|
69
|
+
__exportStar(require("./interface/bank_history.entity.interface"), exports);
|
|
70
|
+
__exportStar(require("./enums/bank_entity_keys.enum"), exports);
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { BankActionEnum } from "../enums/bank_action.enum";
|
|
2
|
+
import { BankStatusEnum } from "../enums/bank_status.enum";
|
|
1
3
|
import { IAuditColumnEntity } from "./audit-column.entity.interface";
|
|
2
4
|
import { IEntityFilterData } from "./entity.utils.interface";
|
|
3
5
|
export interface IBankEntity extends IAuditColumnEntity {
|
|
@@ -9,6 +11,12 @@ export interface IBankEntity extends IAuditColumnEntity {
|
|
|
9
11
|
branchAddress: string;
|
|
10
12
|
micrCode: string;
|
|
11
13
|
ifscCode: string;
|
|
12
|
-
|
|
14
|
+
emailForPaymentInfoCsv: string;
|
|
15
|
+
status?: BankStatusEnum;
|
|
16
|
+
remark?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface IBankActionDataDto {
|
|
19
|
+
action: BankActionEnum;
|
|
20
|
+
remark?: string;
|
|
13
21
|
}
|
|
14
22
|
export type IBankEntityFilterData = IEntityFilterData<IBankEntity>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { HistoryOperationEnum } from "../enums/history_operation.enum";
|
|
2
|
+
import { IAuditColumnEntity } from "./audit-column.entity.interface";
|
|
3
|
+
import { IEntityCreateDto, IEntityFilterData } from "./entity.utils.interface";
|
|
4
|
+
export interface IBankHistoryEntity extends IAuditColumnEntity {
|
|
5
|
+
id: number;
|
|
6
|
+
entityId: number;
|
|
7
|
+
operation: HistoryOperationEnum;
|
|
8
|
+
data: string;
|
|
9
|
+
}
|
|
10
|
+
export interface IBankHistoryCreateDto extends IEntityCreateDto<IBankHistoryEntity> {
|
|
11
|
+
}
|
|
12
|
+
export interface IBankHistorySearchDto extends IEntityFilterData<IBankHistoryEntity> {
|
|
13
|
+
}
|
|
14
|
+
export declare const bankHistoryExcludeKeys: string[];
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { ConvertToArray } from "../../misc";
|
|
2
2
|
import { Modify } from "../../misc/interface/modify.interface";
|
|
3
|
+
import { EntitySearchConstraintTypeEnum } from "../enums/entity_search_constraint_type.enum";
|
|
4
|
+
import { HistoryOperationEnum } from "../enums/history_operation.enum";
|
|
3
5
|
import { IAuditColumnEntity } from "./audit-column.entity.interface";
|
|
4
6
|
export type IApiEntity<T extends {
|
|
5
7
|
createdOn: Date;
|
|
@@ -8,8 +10,8 @@ export type IApiEntity<T extends {
|
|
|
8
10
|
createdOn: string;
|
|
9
11
|
updatedOn: string;
|
|
10
12
|
}>;
|
|
11
|
-
export type IEntityCreateDto<T> = Omit<T,
|
|
12
|
-
export type IEntityUpdateDto<T> = Omit<Partial<T>,
|
|
13
|
+
export type IEntityCreateDto<T> = Omit<T, "id" | keyof IAuditColumnEntity>;
|
|
14
|
+
export type IEntityUpdateDto<T> = Omit<Partial<T>, "id" | keyof IAuditColumnEntity>;
|
|
13
15
|
export type IEntityApiResponse<T extends {
|
|
14
16
|
createdOn: Date;
|
|
15
17
|
updatedOn: Date;
|
|
@@ -29,3 +31,37 @@ export type IEntityFilterData<T> = ConvertToArray<IEntityUpdateDto<T>> & {
|
|
|
29
31
|
[key in keyof T]?: T[key];
|
|
30
32
|
};
|
|
31
33
|
};
|
|
34
|
+
export type IEntitySearchConstraint = {
|
|
35
|
+
entityId: number[];
|
|
36
|
+
constraint: {
|
|
37
|
+
since: IEntitySearchSinceConstraint;
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
export type IEntitySearchSinceConstraint = {
|
|
41
|
+
type: EntitySearchConstraintTypeEnum;
|
|
42
|
+
columnKey: string;
|
|
43
|
+
value: number;
|
|
44
|
+
};
|
|
45
|
+
export type IEntityHistoryParsed = {
|
|
46
|
+
parsedData: any;
|
|
47
|
+
id: number;
|
|
48
|
+
entityId: number;
|
|
49
|
+
operation: HistoryOperationEnum;
|
|
50
|
+
data: string;
|
|
51
|
+
createdOn: Date;
|
|
52
|
+
updatedOn: Date;
|
|
53
|
+
createdBy: number;
|
|
54
|
+
updatedBy: number;
|
|
55
|
+
};
|
|
56
|
+
export type IHistoryEntitySearchByConstraintResponse = {
|
|
57
|
+
id: number;
|
|
58
|
+
createdBy: number;
|
|
59
|
+
changedLogs: IHistoryEntityChangedLogs[];
|
|
60
|
+
};
|
|
61
|
+
export type IHistoryEntityChangedLogs = {
|
|
62
|
+
key: string;
|
|
63
|
+
label: string;
|
|
64
|
+
newValue: string | number;
|
|
65
|
+
oldValue: string | number;
|
|
66
|
+
timeStamp: string;
|
|
67
|
+
};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { EntitySearchConstraintTypeEnum } from "../enums/entity_search_constraint_type.enum";
|
|
2
1
|
import { HistoryOperationEnum } from "../enums/history_operation.enum";
|
|
3
2
|
import { IAuditColumnEntity } from "./audit-column.entity.interface";
|
|
4
3
|
import { IEntityCreateDto, IEntityFilterData } from "./entity.utils.interface";
|
|
@@ -15,25 +14,3 @@ export interface ITimesheetHistoryUpdateDto extends IEntityCreateDto<ITimesheetH
|
|
|
15
14
|
export interface ITimesheetHistorySearchDto extends IEntityFilterData<ITimesheetHistoryEntity> {
|
|
16
15
|
}
|
|
17
16
|
export declare const timesheetHistoryExcludeKeys: string[];
|
|
18
|
-
export type IEntitySearchConstraint = {
|
|
19
|
-
entityId: number[];
|
|
20
|
-
constraint: {
|
|
21
|
-
since: IEntitySearchSinceConstraint;
|
|
22
|
-
};
|
|
23
|
-
};
|
|
24
|
-
export type IEntitySearchSinceConstraint = {
|
|
25
|
-
type: EntitySearchConstraintTypeEnum;
|
|
26
|
-
columnKey: string;
|
|
27
|
-
value: number;
|
|
28
|
-
};
|
|
29
|
-
export type ITimesheetHistoryParsed = {
|
|
30
|
-
parsedData: any;
|
|
31
|
-
id: number;
|
|
32
|
-
entityId: number;
|
|
33
|
-
operation: HistoryOperationEnum;
|
|
34
|
-
data: string;
|
|
35
|
-
createdOn: Date;
|
|
36
|
-
updatedOn: Date;
|
|
37
|
-
createdBy: number;
|
|
38
|
-
updatedBy: number;
|
|
39
|
-
};
|
|
@@ -8,7 +8,7 @@ export interface IUserEntity extends IAuditColumnEntity {
|
|
|
8
8
|
email: string;
|
|
9
9
|
contactNo: string;
|
|
10
10
|
secondaryContactNo?: string;
|
|
11
|
-
password
|
|
11
|
+
password?: string;
|
|
12
12
|
userCode?: string;
|
|
13
13
|
joiningDate?: Date;
|
|
14
14
|
endDate?: Date;
|
|
@@ -21,7 +21,7 @@ export interface IUserEntity extends IAuditColumnEntity {
|
|
|
21
21
|
aadharNo?: string;
|
|
22
22
|
aadharDocumentUrl?: string;
|
|
23
23
|
role: UserRoleEnum;
|
|
24
|
-
status
|
|
24
|
+
status?: UserStatusEnum;
|
|
25
25
|
organizationId?: number;
|
|
26
26
|
passportDocumentUrl?: string;
|
|
27
27
|
academicQualificationDocumentUrl?: string;
|
|
@@ -39,3 +39,5 @@ export interface IUserEntity extends IAuditColumnEntity {
|
|
|
39
39
|
permissions?: string[];
|
|
40
40
|
}
|
|
41
41
|
export type IUserEntityFilterData = IEntityFilterData<IUserEntity>;
|
|
42
|
+
export declare const charForPassword = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
|
43
|
+
export declare const passwordLength = 12;
|
|
@@ -5,5 +5,7 @@ export declare enum ErrorKeyEnum {
|
|
|
5
5
|
BILLING_FLOW_ACTION = "BILLING_FLOW_ACTION",
|
|
6
6
|
REIMBURSEMENT_FLOW_ACTION = "REIMBURSEMENT_FLOW_ACTION",
|
|
7
7
|
REIMBURSEMENT_EXPENSE_FLOW_ACTION = "REIMBURSEMENT_EXPENSE_FLOW_ACTION",
|
|
8
|
-
TIMESHEET_KEY = "TIMESHEET_KEY"
|
|
8
|
+
TIMESHEET_KEY = "TIMESHEET_KEY",
|
|
9
|
+
BANK_FLOW_ACTION = "BANK_FLOW_ACTION",
|
|
10
|
+
BANK_KEY = "BANK_KEY"
|
|
9
11
|
}
|
|
@@ -10,4 +10,6 @@ var ErrorKeyEnum;
|
|
|
10
10
|
ErrorKeyEnum["REIMBURSEMENT_FLOW_ACTION"] = "REIMBURSEMENT_FLOW_ACTION";
|
|
11
11
|
ErrorKeyEnum["REIMBURSEMENT_EXPENSE_FLOW_ACTION"] = "REIMBURSEMENT_EXPENSE_FLOW_ACTION";
|
|
12
12
|
ErrorKeyEnum["TIMESHEET_KEY"] = "TIMESHEET_KEY";
|
|
13
|
+
ErrorKeyEnum["BANK_FLOW_ACTION"] = "BANK_FLOW_ACTION";
|
|
14
|
+
ErrorKeyEnum["BANK_KEY"] = "BANK_KEY";
|
|
13
15
|
})(ErrorKeyEnum || (exports.ErrorKeyEnum = ErrorKeyEnum = {}));
|
package/package.json
CHANGED
|
@@ -1,35 +1,35 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
2
|
+
"name": "law-common",
|
|
3
|
+
"version": "2.9.2-beta.11",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"files": [
|
|
7
|
+
"dist/**/*"
|
|
8
|
+
],
|
|
9
|
+
"scripts": {
|
|
10
|
+
"clean": "rm -rf dist",
|
|
11
|
+
"build": "npm run clean && tsc",
|
|
12
|
+
"publish:beta": "npm version prerelease --preid beta && git push && npm run build && npm publish --tag beta",
|
|
13
|
+
"publish:patch": "npm version patch && git push && npm run build && npm publish",
|
|
14
|
+
"publish:minor": "npm version minor && git push && npm run build && npm publish",
|
|
15
|
+
"publish:major": "npm version major && git push && npm run build && npm publish",
|
|
16
|
+
"link": "npm run build && npm link",
|
|
17
|
+
"test": "jest"
|
|
18
|
+
},
|
|
19
|
+
"keywords": [],
|
|
20
|
+
"author": "",
|
|
21
|
+
"license": "ISC",
|
|
22
|
+
"devDependencies": {
|
|
23
|
+
"@types/jest": "^29.5.13",
|
|
24
|
+
"@types/node": "^22.6.1",
|
|
25
|
+
"jest": "^29.7.0",
|
|
26
|
+
"ts-jest": "^29.2.5",
|
|
27
|
+
"ts-node": "^10.9.2",
|
|
28
|
+
"typescript": "^5.6.2"
|
|
29
|
+
},
|
|
30
|
+
"dependencies": {
|
|
31
|
+
"@types/express": "^5.0.0",
|
|
32
|
+
"@types/multer": "^1.4.12",
|
|
33
|
+
"date-fns": "^4.1.0"
|
|
34
|
+
}
|
|
35
35
|
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
export type ITimesheetHistoryEntitySearchByConstraintResponse = {
|
|
2
|
-
id: number;
|
|
3
|
-
createdBy: number;
|
|
4
|
-
changedLogs: ITimesheetHistoryEntityChangedLogs[];
|
|
5
|
-
};
|
|
6
|
-
export type ITimesheetHistoryEntityChangedLogs = {
|
|
7
|
-
key: string;
|
|
8
|
-
label: string;
|
|
9
|
-
newValue: string | number;
|
|
10
|
-
oldValue: string | number;
|
|
11
|
-
timeStamp: string;
|
|
12
|
-
};
|
/package/dist/src/api/interface/{timesheet_history_entity.response.js → bank_history.api.js}
RENAMED
|
File without changes
|