law-common 1.0.18 → 1.0.19
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/enums/country.entity.enum.d.ts +10 -0
- package/dist/entities/enums/country.entity.enum.js +32 -0
- package/dist/entities/enums/user.entity.enum.d.ts +11 -0
- package/dist/entities/enums/user.entity.enum.js +16 -0
- package/dist/entities/index.d.ts +3 -0
- package/dist/entities/index.js +3 -0
- package/dist/entities/interface/user.entity.interface.d.ts +25 -0
- package/dist/entities/interface/user.entity.interface.js +2 -0
- package/package.json +1 -1
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CountryEnum = void 0;
|
|
4
|
+
var CountryEnum;
|
|
5
|
+
(function (CountryEnum) {
|
|
6
|
+
CountryEnum["India"] = "India";
|
|
7
|
+
CountryEnum["USA"] = "USA";
|
|
8
|
+
CountryEnum["UK"] = "UK";
|
|
9
|
+
})(CountryEnum || (exports.CountryEnum = CountryEnum = {}));
|
|
10
|
+
(function (CountryEnum) {
|
|
11
|
+
function values() {
|
|
12
|
+
return Object.keys(CountryEnum).filter((type) => isNaN(type) && type !== 'values');
|
|
13
|
+
}
|
|
14
|
+
CountryEnum.values = values;
|
|
15
|
+
function keys() {
|
|
16
|
+
return Object.keys(CountryEnum).filter((type) => isNaN(type) && type !== 'values');
|
|
17
|
+
}
|
|
18
|
+
CountryEnum.keys = keys;
|
|
19
|
+
function getCountryTimezone(country) {
|
|
20
|
+
switch (country) {
|
|
21
|
+
case CountryEnum.India:
|
|
22
|
+
return 'Asia/Kolkata';
|
|
23
|
+
case CountryEnum.USA:
|
|
24
|
+
return 'America/New_York';
|
|
25
|
+
case CountryEnum.UK:
|
|
26
|
+
return 'Europe/London';
|
|
27
|
+
default:
|
|
28
|
+
return 'UTC';
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
CountryEnum.getCountryTimezone = getCountryTimezone;
|
|
32
|
+
})(CountryEnum || (exports.CountryEnum = CountryEnum = {}));
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UserRoleEnum = exports.UserStatusEnum = void 0;
|
|
4
|
+
var UserStatusEnum;
|
|
5
|
+
(function (UserStatusEnum) {
|
|
6
|
+
UserStatusEnum["active"] = "active";
|
|
7
|
+
UserStatusEnum["deactive"] = "deactive";
|
|
8
|
+
UserStatusEnum["suspended"] = "suspended";
|
|
9
|
+
})(UserStatusEnum || (exports.UserStatusEnum = UserStatusEnum = {}));
|
|
10
|
+
var UserRoleEnum;
|
|
11
|
+
(function (UserRoleEnum) {
|
|
12
|
+
UserRoleEnum["admin"] = "admin";
|
|
13
|
+
UserRoleEnum["employee"] = "employee";
|
|
14
|
+
UserRoleEnum["partner"] = "partner";
|
|
15
|
+
UserRoleEnum["accountant"] = "accountant";
|
|
16
|
+
})(UserRoleEnum || (exports.UserRoleEnum = UserRoleEnum = {}));
|
package/dist/entities/index.d.ts
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
export * from "./enums/task.entity.enum";
|
|
2
|
+
export * from "./enums/user.entity.enum";
|
|
3
|
+
export * from "./enums/country.entity.enum";
|
|
2
4
|
export * from "./func/convert-to-common-entity.func";
|
|
3
5
|
export * from "./interface/audit-column.entity.interface";
|
|
4
6
|
export * from "./interface/entity.utils.interface";
|
|
5
7
|
export * from "./interface/task.entity.interface";
|
|
8
|
+
export * from "./interface/user.entity.interface";
|
package/dist/entities/index.js
CHANGED
|
@@ -15,7 +15,10 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./enums/task.entity.enum"), exports);
|
|
18
|
+
__exportStar(require("./enums/user.entity.enum"), exports);
|
|
19
|
+
__exportStar(require("./enums/country.entity.enum"), exports);
|
|
18
20
|
__exportStar(require("./func/convert-to-common-entity.func"), exports);
|
|
19
21
|
__exportStar(require("./interface/audit-column.entity.interface"), exports);
|
|
20
22
|
__exportStar(require("./interface/entity.utils.interface"), exports);
|
|
21
23
|
__exportStar(require("./interface/task.entity.interface"), exports);
|
|
24
|
+
__exportStar(require("./interface/user.entity.interface"), exports);
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { CountryEnum } from "../enums/country.entity.enum";
|
|
2
|
+
import { UserRoleEnum, UserStatusEnum } from "../enums/user.entity.enum";
|
|
3
|
+
import { IAuditColumnEntity } from "./audit-column.entity.interface";
|
|
4
|
+
export interface IUserEntity extends IAuditColumnEntity {
|
|
5
|
+
id: number;
|
|
6
|
+
name: string;
|
|
7
|
+
email: string;
|
|
8
|
+
contactNo: string;
|
|
9
|
+
secondaryContactNo: string;
|
|
10
|
+
password: string;
|
|
11
|
+
userCode: string;
|
|
12
|
+
joiningDate: Date;
|
|
13
|
+
endDate: Date;
|
|
14
|
+
address: string;
|
|
15
|
+
zipCode: number;
|
|
16
|
+
country: CountryEnum;
|
|
17
|
+
designation: string;
|
|
18
|
+
panNo: string;
|
|
19
|
+
panDocumentUrl: string;
|
|
20
|
+
aadharNo: string;
|
|
21
|
+
aadharDocumentUrl: string;
|
|
22
|
+
role: UserRoleEnum;
|
|
23
|
+
status: UserStatusEnum;
|
|
24
|
+
organizationId: number;
|
|
25
|
+
}
|