@duvdu-v1/duvdu 1.0.41 → 1.0.43
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/build/auth/src/types/custom-definition.d.ts +0 -0
- package/build/auth/src/types/custom-definition.js +17 -0
- package/build/{index.d.ts → common/src/index.d.ts} +25 -3
- package/build/{index.js → common/src/index.js} +25 -6
- package/build/common/src/models/Bookmark.model.d.ts +29 -0
- package/build/common/src/models/Bookmark.model.js +12 -0
- package/build/common/src/models/Plan.model.d.ts +29 -0
- package/build/common/src/models/Plan.model.js +12 -0
- package/build/common/src/models/Projects.model.d.ts +29 -0
- package/build/common/src/models/Projects.model.js +10 -0
- package/build/common/src/models/Role.model.d.ts +29 -0
- package/build/common/src/models/Role.model.js +13 -0
- package/build/common/src/models/Term.model.d.ts +29 -0
- package/build/common/src/models/Term.model.js +12 -0
- package/build/common/src/models/Ticket.model.d.ts +29 -0
- package/build/common/src/models/Ticket.model.js +35 -0
- package/build/common/src/models/User.model.d.ts +29 -0
- package/build/common/src/models/User.model.js +32 -0
- package/build/common/src/models/category.model.d.ts +29 -0
- package/build/common/src/models/category.model.js +39 -0
- package/build/common/src/types/Bookmarks.d.ts +32 -0
- package/build/common/src/types/Category.d.ts +38 -0
- package/build/common/src/types/Follow.d.ts +30 -0
- package/build/common/src/types/Pagination.d.ts +6 -0
- package/build/common/src/types/Plan.d.ts +36 -0
- package/build/common/src/types/Plan.js +2 -0
- package/build/common/src/types/Projects.d.ts +36 -0
- package/build/common/src/types/Projects.js +2 -0
- package/build/common/src/types/Rate.d.ts +34 -0
- package/build/common/src/types/Rate.js +2 -0
- package/build/common/src/types/Report.d.ts +39 -0
- package/build/common/src/types/Report.js +2 -0
- package/build/common/src/types/Role.d.ts +7 -0
- package/build/common/src/types/Role.js +2 -0
- package/build/common/src/types/Terms.d.ts +3 -0
- package/build/common/src/types/Terms.js +2 -0
- package/build/common/src/types/Ticket.d.ts +41 -0
- package/build/common/src/types/Ticket.js +2 -0
- package/build/common/src/types/UrlQuery.js +2 -0
- package/build/{types/auth → common/src/types}/User.d.ts +30 -6
- package/build/common/src/types/User.js +15 -0
- package/build/common/src/types/success-response.d.ts +3 -0
- package/build/common/src/types/success-response.js +2 -0
- package/build/{utils → common/src/utils}/api-feature.d.ts +0 -1
- package/build/{utils → common/src/utils}/api-feature.js +0 -19
- package/package.json +3 -1
- package/build/types/Pagination.d.ts +0 -7
- package/build/types/auth/endpoints.d.ts +0 -6
- /package/build/{errors → common/src/errors}/bad-request-error.d.ts +0 -0
- /package/build/{errors → common/src/errors}/bad-request-error.js +0 -0
- /package/build/{errors → common/src/errors}/custom-error.d.ts +0 -0
- /package/build/{errors → common/src/errors}/custom-error.js +0 -0
- /package/build/{errors → common/src/errors}/data-base-connections.d.ts +0 -0
- /package/build/{errors → common/src/errors}/data-base-connections.js +0 -0
- /package/build/{errors → common/src/errors}/generic-error.d.ts +0 -0
- /package/build/{errors → common/src/errors}/generic-error.js +0 -0
- /package/build/{errors → common/src/errors}/notfound-error.d.ts +0 -0
- /package/build/{errors → common/src/errors}/notfound-error.js +0 -0
- /package/build/{errors → common/src/errors}/unauthenticated-error.d.ts +0 -0
- /package/build/{errors → common/src/errors}/unauthenticated-error.js +0 -0
- /package/build/{errors → common/src/errors}/unauthorized-error.d.ts +0 -0
- /package/build/{errors → common/src/errors}/unauthorized-error.js +0 -0
- /package/build/{errors → common/src/errors}/validation-error.d.ts +0 -0
- /package/build/{errors → common/src/errors}/validation-error.js +0 -0
- /package/build/{events → common/src/events}/base-listener.d.ts +0 -0
- /package/build/{events → common/src/events}/base-listener.js +0 -0
- /package/build/{events → common/src/events}/base-publisher.d.ts +0 -0
- /package/build/{events → common/src/events}/base-publisher.js +0 -0
- /package/build/{events → common/src/events}/subject.d.ts +0 -0
- /package/build/{events → common/src/events}/subject.js +0 -0
- /package/build/{middlewares → common/src/middlewares}/auth.middleware.d.ts +0 -0
- /package/build/{middlewares → common/src/middlewares}/auth.middleware.js +0 -0
- /package/build/{middlewares → common/src/middlewares}/database-connection.d.ts +0 -0
- /package/build/{middlewares → common/src/middlewares}/database-connection.js +0 -0
- /package/build/{middlewares → common/src/middlewares}/global-error-handling.middleware.d.ts +0 -0
- /package/build/{middlewares → common/src/middlewares}/global-error-handling.middleware.js +0 -0
- /package/build/{middlewares → common/src/middlewares}/global-upload.middleware.d.ts +0 -0
- /package/build/{middlewares → common/src/middlewares}/global-upload.middleware.js +0 -0
- /package/build/{middlewares → common/src/middlewares}/global-validator.middleware.d.ts +0 -0
- /package/build/{middlewares → common/src/middlewares}/global-validator.middleware.js +0 -0
- /package/build/{middlewares → common/src/middlewares}/isAuthorized.middleware.d.ts +0 -0
- /package/build/{middlewares → common/src/middlewares}/isAuthorized.middleware.js +0 -0
- /package/build/{types/JwtPayload.js → common/src/types/Bookmarks.js} +0 -0
- /package/build/{types/Pagination.js → common/src/types/Category.js} +0 -0
- /package/build/{types/UrlQuery.js → common/src/types/Follow.js} +0 -0
- /package/build/{types → common/src/types}/JwtPayload.d.ts +0 -0
- /package/build/{types/auth/User.js → common/src/types/JwtPayload.js} +0 -0
- /package/build/{types/auth/endpoints.js → common/src/types/Pagination.js} +0 -0
- /package/build/{types → common/src/types}/Permissions.d.ts +0 -0
- /package/build/{types → common/src/types}/Permissions.js +0 -0
- /package/build/{types → common/src/types}/UrlQuery.d.ts +0 -0
- /package/build/{types → common/src/types}/model-names.d.ts +0 -0
- /package/build/{types → common/src/types}/model-names.js +0 -0
- /package/build/{types → common/src/types}/systemRoles.d.ts +0 -0
- /package/build/{types → common/src/types}/systemRoles.js +0 -0
- /package/build/{utils → common/src/utils}/generateToken.d.ts +0 -0
- /package/build/{utils → common/src/utils}/generateToken.js +0 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/// <reference types="mongoose/types/aggregate" />
|
|
2
|
+
/// <reference types="mongoose/types/callback" />
|
|
3
|
+
/// <reference types="mongoose/types/collection" />
|
|
4
|
+
/// <reference types="mongoose/types/connection" />
|
|
5
|
+
/// <reference types="mongoose/types/cursor" />
|
|
6
|
+
/// <reference types="mongoose/types/document" />
|
|
7
|
+
/// <reference types="mongoose/types/error" />
|
|
8
|
+
/// <reference types="mongoose/types/expressions" />
|
|
9
|
+
/// <reference types="mongoose/types/helpers" />
|
|
10
|
+
/// <reference types="mongoose/types/middlewares" />
|
|
11
|
+
/// <reference types="mongoose/types/indexes" />
|
|
12
|
+
/// <reference types="mongoose/types/models" />
|
|
13
|
+
/// <reference types="mongoose/types/mongooseoptions" />
|
|
14
|
+
/// <reference types="mongoose/types/pipelinestage" />
|
|
15
|
+
/// <reference types="mongoose/types/populate" />
|
|
16
|
+
/// <reference types="mongoose/types/query" />
|
|
17
|
+
/// <reference types="mongoose/types/schemaoptions" />
|
|
18
|
+
/// <reference types="mongoose/types/schematypes" />
|
|
19
|
+
/// <reference types="mongoose/types/session" />
|
|
20
|
+
/// <reference types="mongoose/types/types" />
|
|
21
|
+
/// <reference types="mongoose/types/utility" />
|
|
22
|
+
/// <reference types="mongoose/types/validation" />
|
|
23
|
+
/// <reference types="mongoose/types/virtuals" />
|
|
24
|
+
/// <reference types="mongoose/types/inferschematype" />
|
|
25
|
+
import { Types } from 'mongoose';
|
|
26
|
+
import { Iuser } from './User';
|
|
27
|
+
export interface Ifollow {
|
|
28
|
+
sourceUser: Types.ObjectId | Iuser;
|
|
29
|
+
targetUser: Types.ObjectId | Iuser;
|
|
30
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/// <reference types="mongoose/types/aggregate" />
|
|
2
|
+
/// <reference types="mongoose/types/callback" />
|
|
3
|
+
/// <reference types="mongoose/types/collection" />
|
|
4
|
+
/// <reference types="mongoose/types/connection" />
|
|
5
|
+
/// <reference types="mongoose/types/cursor" />
|
|
6
|
+
/// <reference types="mongoose/types/document" />
|
|
7
|
+
/// <reference types="mongoose/types/error" />
|
|
8
|
+
/// <reference types="mongoose/types/expressions" />
|
|
9
|
+
/// <reference types="mongoose/types/helpers" />
|
|
10
|
+
/// <reference types="mongoose/types/middlewares" />
|
|
11
|
+
/// <reference types="mongoose/types/indexes" />
|
|
12
|
+
/// <reference types="mongoose/types/models" />
|
|
13
|
+
/// <reference types="mongoose/types/mongooseoptions" />
|
|
14
|
+
/// <reference types="mongoose/types/pipelinestage" />
|
|
15
|
+
/// <reference types="mongoose/types/populate" />
|
|
16
|
+
/// <reference types="mongoose/types/query" />
|
|
17
|
+
/// <reference types="mongoose/types/schemaoptions" />
|
|
18
|
+
/// <reference types="mongoose/types/schematypes" />
|
|
19
|
+
/// <reference types="mongoose/types/session" />
|
|
20
|
+
/// <reference types="mongoose/types/types" />
|
|
21
|
+
/// <reference types="mongoose/types/utility" />
|
|
22
|
+
/// <reference types="mongoose/types/validation" />
|
|
23
|
+
/// <reference types="mongoose/types/virtuals" />
|
|
24
|
+
/// <reference types="mongoose/types/inferschematype" />
|
|
25
|
+
import { Types } from 'mongoose';
|
|
26
|
+
import { Irole } from './Role';
|
|
27
|
+
export interface Iplan {
|
|
28
|
+
id: string;
|
|
29
|
+
title: {
|
|
30
|
+
ar: string;
|
|
31
|
+
en: string;
|
|
32
|
+
};
|
|
33
|
+
key: string;
|
|
34
|
+
role: Types.ObjectId | Irole;
|
|
35
|
+
status: boolean;
|
|
36
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/// <reference types="mongoose/types/aggregate" />
|
|
2
|
+
/// <reference types="mongoose/types/callback" />
|
|
3
|
+
/// <reference types="mongoose/types/collection" />
|
|
4
|
+
/// <reference types="mongoose/types/connection" />
|
|
5
|
+
/// <reference types="mongoose/types/cursor" />
|
|
6
|
+
/// <reference types="mongoose/types/document" />
|
|
7
|
+
/// <reference types="mongoose/types/error" />
|
|
8
|
+
/// <reference types="mongoose/types/expressions" />
|
|
9
|
+
/// <reference types="mongoose/types/helpers" />
|
|
10
|
+
/// <reference types="mongoose/types/middlewares" />
|
|
11
|
+
/// <reference types="mongoose/types/indexes" />
|
|
12
|
+
/// <reference types="mongoose/types/models" />
|
|
13
|
+
/// <reference types="mongoose/types/mongooseoptions" />
|
|
14
|
+
/// <reference types="mongoose/types/pipelinestage" />
|
|
15
|
+
/// <reference types="mongoose/types/populate" />
|
|
16
|
+
/// <reference types="mongoose/types/query" />
|
|
17
|
+
/// <reference types="mongoose/types/schemaoptions" />
|
|
18
|
+
/// <reference types="mongoose/types/schematypes" />
|
|
19
|
+
/// <reference types="mongoose/types/session" />
|
|
20
|
+
/// <reference types="mongoose/types/types" />
|
|
21
|
+
/// <reference types="mongoose/types/utility" />
|
|
22
|
+
/// <reference types="mongoose/types/validation" />
|
|
23
|
+
/// <reference types="mongoose/types/virtuals" />
|
|
24
|
+
/// <reference types="mongoose/types/inferschematype" />
|
|
25
|
+
import { Types } from 'mongoose';
|
|
26
|
+
import { Iuser } from './User';
|
|
27
|
+
export interface Iproject {
|
|
28
|
+
id: string;
|
|
29
|
+
cover: string[];
|
|
30
|
+
title: {
|
|
31
|
+
en: string;
|
|
32
|
+
ar: string;
|
|
33
|
+
};
|
|
34
|
+
owner: Iuser | Types.ObjectId;
|
|
35
|
+
creatives: (Iuser | Types.ObjectId)[];
|
|
36
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/// <reference types="mongoose/types/aggregate" />
|
|
2
|
+
/// <reference types="mongoose/types/callback" />
|
|
3
|
+
/// <reference types="mongoose/types/collection" />
|
|
4
|
+
/// <reference types="mongoose/types/connection" />
|
|
5
|
+
/// <reference types="mongoose/types/cursor" />
|
|
6
|
+
/// <reference types="mongoose/types/document" />
|
|
7
|
+
/// <reference types="mongoose/types/error" />
|
|
8
|
+
/// <reference types="mongoose/types/expressions" />
|
|
9
|
+
/// <reference types="mongoose/types/helpers" />
|
|
10
|
+
/// <reference types="mongoose/types/middlewares" />
|
|
11
|
+
/// <reference types="mongoose/types/indexes" />
|
|
12
|
+
/// <reference types="mongoose/types/models" />
|
|
13
|
+
/// <reference types="mongoose/types/mongooseoptions" />
|
|
14
|
+
/// <reference types="mongoose/types/pipelinestage" />
|
|
15
|
+
/// <reference types="mongoose/types/populate" />
|
|
16
|
+
/// <reference types="mongoose/types/query" />
|
|
17
|
+
/// <reference types="mongoose/types/schemaoptions" />
|
|
18
|
+
/// <reference types="mongoose/types/schematypes" />
|
|
19
|
+
/// <reference types="mongoose/types/session" />
|
|
20
|
+
/// <reference types="mongoose/types/types" />
|
|
21
|
+
/// <reference types="mongoose/types/utility" />
|
|
22
|
+
/// <reference types="mongoose/types/validation" />
|
|
23
|
+
/// <reference types="mongoose/types/virtuals" />
|
|
24
|
+
/// <reference types="mongoose/types/inferschematype" />
|
|
25
|
+
import { Types } from 'mongoose';
|
|
26
|
+
import { Iproject } from './Projects';
|
|
27
|
+
import { Iuser } from './User';
|
|
28
|
+
export interface Irate {
|
|
29
|
+
id: string;
|
|
30
|
+
sourceUser: Types.ObjectId | Iuser;
|
|
31
|
+
project: Types.ObjectId | Iproject;
|
|
32
|
+
rate: number;
|
|
33
|
+
desc: string;
|
|
34
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/// <reference types="mongoose/types/aggregate" />
|
|
2
|
+
/// <reference types="mongoose/types/callback" />
|
|
3
|
+
/// <reference types="mongoose/types/collection" />
|
|
4
|
+
/// <reference types="mongoose/types/connection" />
|
|
5
|
+
/// <reference types="mongoose/types/cursor" />
|
|
6
|
+
/// <reference types="mongoose/types/document" />
|
|
7
|
+
/// <reference types="mongoose/types/error" />
|
|
8
|
+
/// <reference types="mongoose/types/expressions" />
|
|
9
|
+
/// <reference types="mongoose/types/helpers" />
|
|
10
|
+
/// <reference types="mongoose/types/middlewares" />
|
|
11
|
+
/// <reference types="mongoose/types/indexes" />
|
|
12
|
+
/// <reference types="mongoose/types/models" />
|
|
13
|
+
/// <reference types="mongoose/types/mongooseoptions" />
|
|
14
|
+
/// <reference types="mongoose/types/pipelinestage" />
|
|
15
|
+
/// <reference types="mongoose/types/populate" />
|
|
16
|
+
/// <reference types="mongoose/types/query" />
|
|
17
|
+
/// <reference types="mongoose/types/schemaoptions" />
|
|
18
|
+
/// <reference types="mongoose/types/schematypes" />
|
|
19
|
+
/// <reference types="mongoose/types/session" />
|
|
20
|
+
/// <reference types="mongoose/types/types" />
|
|
21
|
+
/// <reference types="mongoose/types/utility" />
|
|
22
|
+
/// <reference types="mongoose/types/validation" />
|
|
23
|
+
/// <reference types="mongoose/types/virtuals" />
|
|
24
|
+
/// <reference types="mongoose/types/inferschematype" />
|
|
25
|
+
import { Types } from 'mongoose';
|
|
26
|
+
import { Iproject } from './Projects';
|
|
27
|
+
import { Iuser } from './User';
|
|
28
|
+
export interface Ireport {
|
|
29
|
+
sourceUser: Types.ObjectId | Iuser;
|
|
30
|
+
targetUser: Types.ObjectId | Iuser;
|
|
31
|
+
project: Types.ObjectId | Iproject;
|
|
32
|
+
desc: string;
|
|
33
|
+
attachments: [string];
|
|
34
|
+
state: {
|
|
35
|
+
isClosed: boolean;
|
|
36
|
+
closedBy: Types.ObjectId;
|
|
37
|
+
feedback: string;
|
|
38
|
+
};
|
|
39
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/// <reference types="mongoose/types/aggregate" />
|
|
2
|
+
/// <reference types="mongoose/types/callback" />
|
|
3
|
+
/// <reference types="mongoose/types/collection" />
|
|
4
|
+
/// <reference types="mongoose/types/connection" />
|
|
5
|
+
/// <reference types="mongoose/types/cursor" />
|
|
6
|
+
/// <reference types="mongoose/types/document" />
|
|
7
|
+
/// <reference types="mongoose/types/error" />
|
|
8
|
+
/// <reference types="mongoose/types/expressions" />
|
|
9
|
+
/// <reference types="mongoose/types/helpers" />
|
|
10
|
+
/// <reference types="mongoose/types/middlewares" />
|
|
11
|
+
/// <reference types="mongoose/types/indexes" />
|
|
12
|
+
/// <reference types="mongoose/types/models" />
|
|
13
|
+
/// <reference types="mongoose/types/mongooseoptions" />
|
|
14
|
+
/// <reference types="mongoose/types/pipelinestage" />
|
|
15
|
+
/// <reference types="mongoose/types/populate" />
|
|
16
|
+
/// <reference types="mongoose/types/query" />
|
|
17
|
+
/// <reference types="mongoose/types/schemaoptions" />
|
|
18
|
+
/// <reference types="mongoose/types/schematypes" />
|
|
19
|
+
/// <reference types="mongoose/types/session" />
|
|
20
|
+
/// <reference types="mongoose/types/types" />
|
|
21
|
+
/// <reference types="mongoose/types/utility" />
|
|
22
|
+
/// <reference types="mongoose/types/validation" />
|
|
23
|
+
/// <reference types="mongoose/types/virtuals" />
|
|
24
|
+
/// <reference types="mongoose/types/inferschematype" />
|
|
25
|
+
import { Types } from 'mongoose';
|
|
26
|
+
import { Iuser } from './User';
|
|
27
|
+
export interface Iticket {
|
|
28
|
+
id: string;
|
|
29
|
+
userId: Types.ObjectId | Iuser;
|
|
30
|
+
name: string;
|
|
31
|
+
phoneNumber: {
|
|
32
|
+
key: string;
|
|
33
|
+
number: string;
|
|
34
|
+
};
|
|
35
|
+
message: string;
|
|
36
|
+
state: {
|
|
37
|
+
isClosed: boolean;
|
|
38
|
+
closedBy: Types.ObjectId;
|
|
39
|
+
feedback: string;
|
|
40
|
+
};
|
|
41
|
+
}
|
|
@@ -23,6 +23,19 @@
|
|
|
23
23
|
/// <reference types="mongoose/types/virtuals" />
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
import { Types } from 'mongoose';
|
|
26
|
+
import { Icategory } from './Category';
|
|
27
|
+
import { Irole } from './Role';
|
|
28
|
+
export declare enum VerificationReason {
|
|
29
|
+
updateOldPhoneNumber = "update-old-phone-number",
|
|
30
|
+
updateOldPhoneNumberVerified = "update-old-phone-number-verified",
|
|
31
|
+
updateNewPhoneNumber = "update-new-phone-number",
|
|
32
|
+
verifyUpdatedPhoneNumber = "verify-updated-phone-number",
|
|
33
|
+
forgetPassword = "forget-password",
|
|
34
|
+
forgetPasswordVerified = "forget-password-verified",
|
|
35
|
+
signup = "signup",
|
|
36
|
+
completeSginUp = "complete-sginup",
|
|
37
|
+
CompleteSginUpVerfied = "complete-sginup-verified"
|
|
38
|
+
}
|
|
26
39
|
export interface Iuser {
|
|
27
40
|
id: string;
|
|
28
41
|
googleId?: string;
|
|
@@ -35,9 +48,11 @@ export interface Iuser {
|
|
|
35
48
|
username: string;
|
|
36
49
|
password?: string;
|
|
37
50
|
verificationCode?: {
|
|
38
|
-
code
|
|
39
|
-
expireAt
|
|
51
|
+
code?: string;
|
|
52
|
+
expireAt?: string;
|
|
53
|
+
reason?: VerificationReason;
|
|
40
54
|
};
|
|
55
|
+
isVerified: boolean;
|
|
41
56
|
token?: string;
|
|
42
57
|
profileImage?: string;
|
|
43
58
|
coverImage?: string;
|
|
@@ -45,18 +60,27 @@ export interface Iuser {
|
|
|
45
60
|
lat: number;
|
|
46
61
|
lng: number;
|
|
47
62
|
};
|
|
48
|
-
|
|
63
|
+
category?: Types.ObjectId | Icategory;
|
|
49
64
|
acceptedProjectsCounter: number;
|
|
50
65
|
profileViews: number;
|
|
51
66
|
about?: string;
|
|
52
67
|
isOnline: boolean;
|
|
53
68
|
isAvaliableToInstantProjects: boolean;
|
|
54
|
-
pricePerHour
|
|
55
|
-
|
|
56
|
-
|
|
69
|
+
pricePerHour: number;
|
|
70
|
+
role: Types.ObjectId | Irole;
|
|
71
|
+
hasVerificationBadge: boolean;
|
|
57
72
|
avaliableContracts: number;
|
|
58
73
|
rate: {
|
|
59
74
|
ratersCounter: number;
|
|
60
75
|
totalRates: number;
|
|
61
76
|
};
|
|
77
|
+
currentRank: string;
|
|
78
|
+
isBlocked: {
|
|
79
|
+
value: boolean;
|
|
80
|
+
reason: string;
|
|
81
|
+
};
|
|
82
|
+
followCount: {
|
|
83
|
+
following: number;
|
|
84
|
+
followers: number;
|
|
85
|
+
};
|
|
62
86
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.VerificationReason = void 0;
|
|
4
|
+
var VerificationReason;
|
|
5
|
+
(function (VerificationReason) {
|
|
6
|
+
VerificationReason["updateOldPhoneNumber"] = "update-old-phone-number";
|
|
7
|
+
VerificationReason["updateOldPhoneNumberVerified"] = "update-old-phone-number-verified";
|
|
8
|
+
VerificationReason["updateNewPhoneNumber"] = "update-new-phone-number";
|
|
9
|
+
VerificationReason["verifyUpdatedPhoneNumber"] = "verify-updated-phone-number";
|
|
10
|
+
VerificationReason["forgetPassword"] = "forget-password";
|
|
11
|
+
VerificationReason["forgetPasswordVerified"] = "forget-password-verified";
|
|
12
|
+
VerificationReason["signup"] = "signup";
|
|
13
|
+
VerificationReason["completeSginUp"] = "complete-sginup";
|
|
14
|
+
VerificationReason["CompleteSginUpVerfied"] = "complete-sginup-verified";
|
|
15
|
+
})(VerificationReason || (exports.VerificationReason = VerificationReason = {}));
|
|
@@ -50,24 +50,5 @@ class Api_Feature {
|
|
|
50
50
|
}
|
|
51
51
|
return this;
|
|
52
52
|
}
|
|
53
|
-
pagination(documentCount) {
|
|
54
|
-
const page = +(this.queryString.page || 1);
|
|
55
|
-
const limit = +(this.queryString.limit || 10);
|
|
56
|
-
const skip = (page - 1) * limit;
|
|
57
|
-
const endPageIndex = page * limit;
|
|
58
|
-
const pagination = {};
|
|
59
|
-
pagination.currentPage = page;
|
|
60
|
-
pagination.limit = limit;
|
|
61
|
-
pagination.numberOfPages = Math.ceil(documentCount / limit);
|
|
62
|
-
if (endPageIndex < documentCount) {
|
|
63
|
-
pagination.nextPage = page + 1;
|
|
64
|
-
}
|
|
65
|
-
if (skip > 0) {
|
|
66
|
-
pagination.previousPage = page - 1;
|
|
67
|
-
}
|
|
68
|
-
this.mongooseQuery = this.mongooseQuery.skip(skip).limit(limit);
|
|
69
|
-
this.paginateResult = pagination;
|
|
70
|
-
return this;
|
|
71
|
-
}
|
|
72
53
|
}
|
|
73
54
|
exports.Api_Feature = Api_Feature;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@duvdu-v1/duvdu",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.43",
|
|
4
4
|
"main": "./build/index.js",
|
|
5
5
|
"types": "./build/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
"license": "ISC",
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@types/express": "^4.17.21",
|
|
22
|
+
"@types/express-session": "^1.18.0",
|
|
22
23
|
"@types/jsonwebtoken": "^9.0.5",
|
|
23
24
|
"@types/multer": "^1.4.11",
|
|
24
25
|
"@types/node": "^20.11.0",
|
|
@@ -26,6 +27,7 @@
|
|
|
26
27
|
"@typescript-eslint/parser": "^6.19.0",
|
|
27
28
|
"express": "^4.18.2",
|
|
28
29
|
"express-async-errors": "^3.1.1",
|
|
30
|
+
"express-session": "^1.18.0",
|
|
29
31
|
"express-validator": "^7.0.1",
|
|
30
32
|
"jsonwebtoken": "^9.0.2",
|
|
31
33
|
"mongoose": "^8.0.4",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|