biz-slide-core 1.2.83 → 1.2.85
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/entity/analytic.entity.d.ts +50 -0
- package/dist/entity/analytic.entity.d.ts.map +1 -0
- package/dist/entity/common.d.ts +19 -0
- package/dist/entity/common.d.ts.map +1 -0
- package/dist/entity/config.enity.d.ts +33 -0
- package/dist/entity/config.enity.d.ts.map +1 -0
- package/dist/entity/cron.entity.d.ts +33 -0
- package/dist/entity/cron.entity.d.ts.map +1 -0
- package/dist/entity/customer.entity.d.ts +38 -0
- package/dist/entity/customer.entity.d.ts.map +1 -0
- package/dist/entity/image.entity.d.ts +44 -0
- package/dist/entity/image.entity.d.ts.map +1 -0
- package/dist/entity/index.d.ts +19 -0
- package/dist/entity/index.d.ts.map +1 -0
- package/dist/entity/logs.entity.d.ts +34 -0
- package/dist/entity/logs.entity.d.ts.map +1 -0
- package/dist/entity/png-svg.entity.d.ts +47 -0
- package/dist/entity/png-svg.entity.d.ts.map +1 -0
- package/dist/entity/ppt-email-queue.entity.d.ts +34 -0
- package/dist/entity/ppt-email-queue.entity.d.ts.map +1 -0
- package/dist/entity/ppt-event.entity.d.ts +37 -0
- package/dist/entity/ppt-event.entity.d.ts.map +1 -0
- package/dist/entity/ppt-slide.entity.d.ts +44 -0
- package/dist/entity/ppt-slide.entity.d.ts.map +1 -0
- package/dist/entity/ppt.entity.d.ts +62 -0
- package/dist/entity/ppt.entity.d.ts.map +1 -0
- package/{entity → dist/entity}/ppt.entity.js +2 -1
- package/dist/entity/slide-layout.entity.d.ts +45 -0
- package/dist/entity/slide-layout.entity.d.ts.map +1 -0
- package/dist/entity/slide.entity.d.ts +51 -0
- package/dist/entity/slide.entity.d.ts.map +1 -0
- package/dist/entity/socket.entity.d.ts +35 -0
- package/dist/entity/socket.entity.d.ts.map +1 -0
- package/dist/entity/template-type.entity.d.ts +49 -0
- package/dist/entity/template-type.entity.d.ts.map +1 -0
- package/dist/entity/template.entity.d.ts +40 -0
- package/dist/entity/template.entity.d.ts.map +1 -0
- package/dist/entity/training-queue.entity.d.ts +39 -0
- package/dist/entity/training-queue.entity.d.ts.map +1 -0
- package/dist/entity/user.entity.d.ts +38 -0
- package/dist/entity/user.entity.d.ts.map +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/middleware/authentication.d.ts +8 -0
- package/dist/middleware/authentication.d.ts.map +1 -0
- package/{middleware → dist/middleware}/authentication.js +2 -1
- package/dist/middleware/index.d.ts +4 -0
- package/dist/middleware/index.d.ts.map +1 -0
- package/dist/middleware/role.d.ts +6 -0
- package/dist/middleware/role.d.ts.map +1 -0
- package/dist/middleware/schemaValidate.d.ts +5 -0
- package/dist/middleware/schemaValidate.d.ts.map +1 -0
- package/dist/resHandler/errorHandler.d.ts +17 -0
- package/dist/resHandler/errorHandler.d.ts.map +1 -0
- package/dist/resHandler/index.d.ts +3 -0
- package/dist/resHandler/index.d.ts.map +1 -0
- package/dist/resHandler/successHandler.d.ts +3 -0
- package/dist/resHandler/successHandler.d.ts.map +1 -0
- package/dist/types/IController.d.ts +6 -0
- package/dist/types/IController.d.ts.map +1 -0
- package/dist/types/IRequest.d.ts +8 -0
- package/dist/types/IRequest.d.ts.map +1 -0
- package/dist/types/index.d.ts +11 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/utilities/callWithRetries.d.ts +2 -0
- package/dist/utilities/callWithRetries.d.ts.map +1 -0
- package/dist/utilities/createFolder.d.ts +2 -0
- package/dist/utilities/createFolder.d.ts.map +1 -0
- package/dist/utilities/encryptionUtils.d.ts +4 -0
- package/dist/utilities/encryptionUtils.d.ts.map +1 -0
- package/dist/utilities/hasAbusiveWords.d.ts +4 -0
- package/dist/utilities/hasAbusiveWords.d.ts.map +1 -0
- package/dist/utilities/index.d.ts +6 -0
- package/dist/utilities/index.d.ts.map +1 -0
- package/dist/utilities/pngSvgCategories.d.ts +168 -0
- package/dist/utilities/pngSvgCategories.d.ts.map +1 -0
- package/package.json +2 -1
- package/src/entity/analytic.entity.ts +62 -0
- package/src/entity/common.ts +19 -0
- package/src/entity/config.enity.ts +18 -0
- package/src/entity/cron.entity.ts +22 -0
- package/src/entity/customer.entity.ts +40 -0
- package/src/entity/image.entity.ts +32 -0
- package/src/entity/index.ts +20 -0
- package/src/entity/logs.entity.ts +20 -0
- package/src/entity/png-svg.entity.ts +44 -0
- package/src/entity/ppt-email-queue.entity.ts +22 -0
- package/src/entity/ppt-event.entity.ts +25 -0
- package/src/entity/ppt-slide.entity.ts +40 -0
- package/src/entity/ppt.entity.ts +79 -0
- package/src/entity/slide-layout.entity.ts +56 -0
- package/src/entity/slide.entity.ts +61 -0
- package/src/entity/socket.entity.ts +20 -0
- package/src/entity/template-type.entity.ts +87 -0
- package/src/entity/template.entity.ts +38 -0
- package/src/entity/training-queue.entity.ts +26 -0
- package/src/entity/user.entity.ts +24 -0
- package/src/index.ts +6 -0
- package/src/middleware/authentication.ts +150 -0
- package/src/middleware/index.ts +3 -0
- package/src/middleware/role.ts +5 -0
- package/src/middleware/schemaValidate.ts +20 -0
- package/src/resHandler/errorHandler.ts +66 -0
- package/src/resHandler/index.ts +2 -0
- package/src/resHandler/successHandler.ts +11 -0
- package/src/types/IController.ts +6 -0
- package/src/types/IRequest.ts +8 -0
- package/src/types/index.ts +11 -0
- package/src/utilities/callWithRetries.ts +9 -0
- package/src/utilities/createFolder.ts +11 -0
- package/src/utilities/encryptionUtils.ts +26 -0
- package/src/utilities/hasAbusiveWords.ts +33 -0
- package/src/utilities/index.ts +5 -0
- package/src/utilities/pngSvgCategories.ts +167 -0
- package/tsconfig.json +11 -0
- /package/{entity → dist/entity}/analytic.entity.js +0 -0
- /package/{entity → dist/entity}/common.js +0 -0
- /package/{entity → dist/entity}/config.enity.js +0 -0
- /package/{entity → dist/entity}/cron.entity.js +0 -0
- /package/{entity → dist/entity}/customer.entity.js +0 -0
- /package/{entity → dist/entity}/image.entity.js +0 -0
- /package/{entity → dist/entity}/index.js +0 -0
- /package/{entity → dist/entity}/logs.entity.js +0 -0
- /package/{entity → dist/entity}/png-svg.entity.js +0 -0
- /package/{entity → dist/entity}/ppt-email-queue.entity.js +0 -0
- /package/{entity → dist/entity}/ppt-event.entity.js +0 -0
- /package/{entity → dist/entity}/ppt-slide.entity.js +0 -0
- /package/{entity → dist/entity}/slide-layout.entity.js +0 -0
- /package/{entity → dist/entity}/slide.entity.js +0 -0
- /package/{entity → dist/entity}/socket.entity.js +0 -0
- /package/{entity → dist/entity}/template-type.entity.js +0 -0
- /package/{entity → dist/entity}/template.entity.js +0 -0
- /package/{entity → dist/entity}/training-queue.entity.js +0 -0
- /package/{entity → dist/entity}/user.entity.js +0 -0
- /package/{index.js → dist/index.js} +0 -0
- /package/{middleware → dist/middleware}/index.js +0 -0
- /package/{middleware → dist/middleware}/role.js +0 -0
- /package/{middleware → dist/middleware}/schemaValidate.js +0 -0
- /package/{resHandler → dist/resHandler}/errorHandler.js +0 -0
- /package/{resHandler → dist/resHandler}/index.js +0 -0
- /package/{resHandler → dist/resHandler}/successHandler.js +0 -0
- /package/{types → dist/types}/IController.js +0 -0
- /package/{types → dist/types}/IRequest.js +0 -0
- /package/{types → dist/types}/index.js +0 -0
- /package/{utilities → dist/utilities}/callWithRetries.js +0 -0
- /package/{utilities → dist/utilities}/createFolder.js +0 -0
- /package/{utilities → dist/utilities}/encryptionUtils.js +0 -0
- /package/{utilities → dist/utilities}/hasAbusiveWords.js +0 -0
- /package/{utilities → dist/utilities}/index.js +0 -0
- /package/{utilities → dist/utilities}/pngSvgCategories.js +0 -0
@@ -0,0 +1,168 @@
|
|
1
|
+
export declare const pngSvgCategories: {
|
2
|
+
Logo: {
|
3
|
+
Outline: {
|
4
|
+
alias: string;
|
5
|
+
};
|
6
|
+
Monogram: {
|
7
|
+
alias: string;
|
8
|
+
};
|
9
|
+
Wordmark: {
|
10
|
+
alias: string;
|
11
|
+
};
|
12
|
+
Emblem: {
|
13
|
+
alias: string;
|
14
|
+
};
|
15
|
+
"Abstract Logo": {
|
16
|
+
alias: string;
|
17
|
+
};
|
18
|
+
Mascot: {
|
19
|
+
alias: string;
|
20
|
+
};
|
21
|
+
};
|
22
|
+
Icons: {
|
23
|
+
Outline: {
|
24
|
+
alias: string;
|
25
|
+
};
|
26
|
+
Pictogram: {
|
27
|
+
alias: string;
|
28
|
+
};
|
29
|
+
"Broken Line": {
|
30
|
+
alias: string;
|
31
|
+
};
|
32
|
+
"Gradient Line": {
|
33
|
+
alias: string;
|
34
|
+
};
|
35
|
+
"Gradient Shape": {
|
36
|
+
alias: string;
|
37
|
+
};
|
38
|
+
Doodle: {
|
39
|
+
alias: string;
|
40
|
+
};
|
41
|
+
Flat: {
|
42
|
+
alias: string;
|
43
|
+
};
|
44
|
+
Minimalistic: {
|
45
|
+
alias: string;
|
46
|
+
};
|
47
|
+
Isometric: {
|
48
|
+
alias: string;
|
49
|
+
};
|
50
|
+
"3D Icons": {
|
51
|
+
alias: string;
|
52
|
+
};
|
53
|
+
};
|
54
|
+
Illustrations: {
|
55
|
+
"Hand Drawn": {
|
56
|
+
alias: string;
|
57
|
+
};
|
58
|
+
Glow: {
|
59
|
+
alias: string;
|
60
|
+
};
|
61
|
+
"Pixel Art": {
|
62
|
+
alias: string;
|
63
|
+
};
|
64
|
+
Watercolour: {
|
65
|
+
alias: string;
|
66
|
+
};
|
67
|
+
Psychedelic: {
|
68
|
+
alias: string;
|
69
|
+
};
|
70
|
+
"80's": {
|
71
|
+
alias: string;
|
72
|
+
};
|
73
|
+
"Digital Art": {
|
74
|
+
alias: string;
|
75
|
+
};
|
76
|
+
Abstract: {
|
77
|
+
alias: string;
|
78
|
+
};
|
79
|
+
Realistic: {
|
80
|
+
alias: string;
|
81
|
+
};
|
82
|
+
"Comic Style": {
|
83
|
+
alias: string;
|
84
|
+
};
|
85
|
+
Fantasy: {
|
86
|
+
alias: string;
|
87
|
+
};
|
88
|
+
Anime: {
|
89
|
+
alias: string;
|
90
|
+
};
|
91
|
+
Minimalist: {
|
92
|
+
alias: string;
|
93
|
+
};
|
94
|
+
"Pencil Sketch": {
|
95
|
+
alias: string;
|
96
|
+
};
|
97
|
+
};
|
98
|
+
"3D illustration": {
|
99
|
+
Wireframe: {
|
100
|
+
alias: string;
|
101
|
+
};
|
102
|
+
"Low Poly": {
|
103
|
+
alias: string;
|
104
|
+
};
|
105
|
+
"Cartoon 3D": {
|
106
|
+
alias: string;
|
107
|
+
};
|
108
|
+
"Plastic 3D": {
|
109
|
+
alias: string;
|
110
|
+
};
|
111
|
+
"3D render": {
|
112
|
+
alias: string;
|
113
|
+
};
|
114
|
+
};
|
115
|
+
Photorealism: {
|
116
|
+
"Photorealistic Painting": {
|
117
|
+
alias: string;
|
118
|
+
};
|
119
|
+
"Photorealistic Drawing": {
|
120
|
+
alias: string;
|
121
|
+
};
|
122
|
+
Hyperealism: {
|
123
|
+
alias: string;
|
124
|
+
};
|
125
|
+
Photorealism: {
|
126
|
+
alias: string;
|
127
|
+
};
|
128
|
+
};
|
129
|
+
"Vector Art": {
|
130
|
+
"Line Art": {
|
131
|
+
alias: string;
|
132
|
+
};
|
133
|
+
Cartoon: {
|
134
|
+
alias: string;
|
135
|
+
};
|
136
|
+
"Vector Kawai": {
|
137
|
+
alias: string;
|
138
|
+
};
|
139
|
+
Linocut: {
|
140
|
+
alias: string;
|
141
|
+
};
|
142
|
+
Engraving: {
|
143
|
+
alias: string;
|
144
|
+
};
|
145
|
+
"Doodle Line Art": {
|
146
|
+
alias: string;
|
147
|
+
};
|
148
|
+
Geometric: {
|
149
|
+
alias: string;
|
150
|
+
};
|
151
|
+
Abstract: {
|
152
|
+
alias: string;
|
153
|
+
};
|
154
|
+
Vintage: {
|
155
|
+
alias: string;
|
156
|
+
};
|
157
|
+
Minimalist: {
|
158
|
+
alias: string;
|
159
|
+
};
|
160
|
+
Stylized: {
|
161
|
+
alias: string;
|
162
|
+
};
|
163
|
+
"Flat Design": {
|
164
|
+
alias: string;
|
165
|
+
};
|
166
|
+
};
|
167
|
+
};
|
168
|
+
//# sourceMappingURL=pngSvgCategories.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"pngSvgCategories.d.ts","sourceRoot":"","sources":["../../src/utilities/pngSvgCategories.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsK5B,CAAA"}
|
package/package.json
CHANGED
@@ -0,0 +1,62 @@
|
|
1
|
+
import { Schema, model, Types } from "mongoose";
|
2
|
+
|
3
|
+
export interface ILayoutAnalyticsSchema {
|
4
|
+
name: string;
|
5
|
+
count: number;
|
6
|
+
percentage: number;
|
7
|
+
}
|
8
|
+
|
9
|
+
export interface IEventsSchema {
|
10
|
+
name: string;
|
11
|
+
count: number;
|
12
|
+
}
|
13
|
+
|
14
|
+
export interface IAnalyticSchema {
|
15
|
+
appName: string;
|
16
|
+
noOfPPT: number;
|
17
|
+
totalDownloaded: number;
|
18
|
+
navigateFromGPT: number;
|
19
|
+
noOfGuestPPT: number;
|
20
|
+
events: Array<IEventsSchema>;
|
21
|
+
totalSlides: number;
|
22
|
+
layouts: Array<ILayoutAnalyticsSchema>;
|
23
|
+
analyticsDate: Date;
|
24
|
+
templateTypeId: Types.ObjectId;
|
25
|
+
}
|
26
|
+
|
27
|
+
const eventSchema = new Schema<IEventsSchema>({
|
28
|
+
name: { type: String, required: true },
|
29
|
+
count: { type: Number, default: 0 }
|
30
|
+
}, {
|
31
|
+
timestamps: false,
|
32
|
+
_id: false
|
33
|
+
})
|
34
|
+
|
35
|
+
const layoutAnalyticsSchema = new Schema<ILayoutAnalyticsSchema>({
|
36
|
+
name: { type: String, required: true },
|
37
|
+
count: { type: Number, default: 0 },
|
38
|
+
percentage: { type: Number, default: 0 }
|
39
|
+
}, {
|
40
|
+
timestamps: false,
|
41
|
+
_id: false
|
42
|
+
});
|
43
|
+
|
44
|
+
const AnalyticSchema = new Schema<IAnalyticSchema>(
|
45
|
+
{
|
46
|
+
templateTypeId: { type: Schema.Types.ObjectId, ref: "template-type" },
|
47
|
+
appName: { type: String, required: true },
|
48
|
+
noOfPPT: { type: Number, default: 0 },
|
49
|
+
totalDownloaded: { type: Number, default: 0 },
|
50
|
+
navigateFromGPT: { type: Number, default: 0 },
|
51
|
+
noOfGuestPPT: { type: Number, default: 0 },
|
52
|
+
events: { type: [eventSchema], default: [] },
|
53
|
+
totalSlides: { type: Number, default: 0 },
|
54
|
+
layouts: {type: [layoutAnalyticsSchema], default: []},
|
55
|
+
analyticsDate: { type: Date, default: Date.now }
|
56
|
+
},
|
57
|
+
{
|
58
|
+
timestamps: true,
|
59
|
+
}
|
60
|
+
);
|
61
|
+
|
62
|
+
export const AnalyticModel = model<IAnalyticSchema>("analytic", AnalyticSchema);
|
@@ -0,0 +1,19 @@
|
|
1
|
+
export interface IMessageSchema {
|
2
|
+
message: string;
|
3
|
+
keys: Array<string>;
|
4
|
+
}
|
5
|
+
export interface ISystemLayout {
|
6
|
+
system: IMessageSchema;
|
7
|
+
user: IMessageSchema;
|
8
|
+
}
|
9
|
+
|
10
|
+
export interface IVariantsSystemLayout {
|
11
|
+
single: {
|
12
|
+
system: IMessageSchema;
|
13
|
+
user: IMessageSchema;
|
14
|
+
},
|
15
|
+
multiple: {
|
16
|
+
system: IMessageSchema;
|
17
|
+
user: IMessageSchema;
|
18
|
+
}
|
19
|
+
}
|
@@ -0,0 +1,18 @@
|
|
1
|
+
import { Schema, model, Types } from "mongoose";
|
2
|
+
|
3
|
+
export interface IConfigSchema {
|
4
|
+
configType: string;
|
5
|
+
value: string;
|
6
|
+
}
|
7
|
+
|
8
|
+
const CongigSchema = new Schema<IConfigSchema>(
|
9
|
+
{
|
10
|
+
configType: { type: String, required: true },
|
11
|
+
value: { type: String, required: true },
|
12
|
+
},
|
13
|
+
{
|
14
|
+
timestamps: true,
|
15
|
+
}
|
16
|
+
);
|
17
|
+
|
18
|
+
export const ConfigModel = model<IConfigSchema>("config", CongigSchema);
|
@@ -0,0 +1,22 @@
|
|
1
|
+
import { Schema, model } from "mongoose";
|
2
|
+
|
3
|
+
export interface ICronSchema {
|
4
|
+
name: string;
|
5
|
+
status: boolean;
|
6
|
+
}
|
7
|
+
|
8
|
+
|
9
|
+
const CronSchema = new Schema<ICronSchema>(
|
10
|
+
{
|
11
|
+
name: { type: String, required: true },
|
12
|
+
status: { type: Boolean, default: false}
|
13
|
+
},
|
14
|
+
{
|
15
|
+
timestamps: true,
|
16
|
+
}
|
17
|
+
);
|
18
|
+
|
19
|
+
CronSchema.index({userId: 1});
|
20
|
+
|
21
|
+
|
22
|
+
export const CronModel = model<ICronSchema>("cron", CronSchema);
|
@@ -0,0 +1,40 @@
|
|
1
|
+
import { Schema, model } from "mongoose";
|
2
|
+
|
3
|
+
export interface IEmailTemplateStatus {
|
4
|
+
sent: boolean;
|
5
|
+
}
|
6
|
+
|
7
|
+
|
8
|
+
export interface ICustomerSchema {
|
9
|
+
appName: string;
|
10
|
+
userId: string;
|
11
|
+
emailId: string;
|
12
|
+
emailTemplateStatus: Record<string, IEmailTemplateStatus>
|
13
|
+
}
|
14
|
+
|
15
|
+
const EmailTemplateStatusSchema = new Schema<IEmailTemplateStatus>(
|
16
|
+
{
|
17
|
+
sent: { type: Boolean, default: false },
|
18
|
+
},
|
19
|
+
{
|
20
|
+
timestamps: false,
|
21
|
+
_id: false
|
22
|
+
}
|
23
|
+
);
|
24
|
+
|
25
|
+
const CustomerSchema = new Schema<ICustomerSchema>(
|
26
|
+
{
|
27
|
+
appName: { type: String, required: true },
|
28
|
+
userId: { type: String, required: true},
|
29
|
+
emailId: { type: String, default: "" },
|
30
|
+
emailTemplateStatus: {type: Map, of: EmailTemplateStatusSchema}
|
31
|
+
},
|
32
|
+
{
|
33
|
+
timestamps: true,
|
34
|
+
}
|
35
|
+
);
|
36
|
+
|
37
|
+
CustomerSchema.index({userId: 1});
|
38
|
+
|
39
|
+
|
40
|
+
export const CustomerModel = model<ICustomerSchema>("customer", CustomerSchema);
|
@@ -0,0 +1,32 @@
|
|
1
|
+
import { Schema, model, Types } from "mongoose";
|
2
|
+
|
3
|
+
export interface IImageSchema {
|
4
|
+
focusPoint: { x: number, y: number };
|
5
|
+
url: string;
|
6
|
+
radius: string;
|
7
|
+
keywords: [string] | null;
|
8
|
+
title: string;
|
9
|
+
aliasName: string;
|
10
|
+
userId: Types.ObjectId;
|
11
|
+
createdAt: Date;
|
12
|
+
updatedAt: Date;
|
13
|
+
deletedAt: Date;
|
14
|
+
}
|
15
|
+
|
16
|
+
const ImageSchema = new Schema<IImageSchema>(
|
17
|
+
{
|
18
|
+
focusPoint: { x: Number, y: Number },
|
19
|
+
url: { type: String, required: true },
|
20
|
+
radius: { type: String, required: true },
|
21
|
+
aliasName: { type: String, required: true },
|
22
|
+
keywords: { type: [String], default: [] },
|
23
|
+
title: { type: String, required: true },
|
24
|
+
userId: { type: Schema.Types.ObjectId, ref: "user" },
|
25
|
+
deletedAt: { type: Date, default: null },
|
26
|
+
},
|
27
|
+
{
|
28
|
+
timestamps: true,
|
29
|
+
}
|
30
|
+
);
|
31
|
+
|
32
|
+
export const ImageModel = model<IImageSchema>("image", ImageSchema);
|
@@ -0,0 +1,20 @@
|
|
1
|
+
export * from "./image.entity";
|
2
|
+
export * from "./png-svg.entity";
|
3
|
+
export * from "./ppt-event.entity";
|
4
|
+
export * from "./ppt-slide.entity";
|
5
|
+
export * from "./ppt.entity";
|
6
|
+
export * from "./slide-layout.entity";
|
7
|
+
export * from "./slide.entity";
|
8
|
+
export * from "./socket.entity";
|
9
|
+
export * from "./template.entity";
|
10
|
+
export * from "./template-type.entity";
|
11
|
+
export * from "./user.entity";
|
12
|
+
export * from "./training-queue.entity";
|
13
|
+
export * from "./config.enity";
|
14
|
+
export * from "./logs.entity";
|
15
|
+
export * from "./analytic.entity";
|
16
|
+
export * from "./ppt-email-queue.entity";
|
17
|
+
export * from "./customer.entity";
|
18
|
+
export * from "./cron.entity";
|
19
|
+
|
20
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
import { Schema, model } from "mongoose";
|
2
|
+
|
3
|
+
export interface ILogsSchema {
|
4
|
+
type: string;
|
5
|
+
event: string;
|
6
|
+
message: string;
|
7
|
+
}
|
8
|
+
|
9
|
+
const LogsSchema = new Schema<ILogsSchema>(
|
10
|
+
{
|
11
|
+
type: { type: String, required: true },
|
12
|
+
event: { type: String, required: true },
|
13
|
+
message: { type: String, required: true },
|
14
|
+
},
|
15
|
+
{
|
16
|
+
timestamps: true,
|
17
|
+
}
|
18
|
+
);
|
19
|
+
|
20
|
+
export const LogsModel = model<ILogsSchema>("logs", LogsSchema);
|
@@ -0,0 +1,44 @@
|
|
1
|
+
import { Schema, model } from "mongoose";
|
2
|
+
|
3
|
+
export interface IPngSvgSchema {
|
4
|
+
title: string;
|
5
|
+
styleCategory: string;
|
6
|
+
styleSubCategory: string;
|
7
|
+
colors: Array<string>;
|
8
|
+
userId: string;
|
9
|
+
isLocked?: boolean;
|
10
|
+
isCompleted?: boolean;
|
11
|
+
isDownloaded?: boolean;
|
12
|
+
hasError?: boolean;
|
13
|
+
optionsDownloaded: any;
|
14
|
+
userReaction: number;
|
15
|
+
userFeedback: string;
|
16
|
+
createdAt?: Date;
|
17
|
+
updatedAt?: Date;
|
18
|
+
deletedAt?: Date;
|
19
|
+
appName: string;
|
20
|
+
}
|
21
|
+
|
22
|
+
const PngSvgSchema = new Schema<IPngSvgSchema>(
|
23
|
+
{
|
24
|
+
deletedAt: { type: Date, default: null },
|
25
|
+
isLocked: { type: Boolean, default: false },
|
26
|
+
optionsDownloaded: Schema.Types.Mixed,
|
27
|
+
isDownloaded: { type: Boolean, default: false },
|
28
|
+
isCompleted: { type: Boolean, default: false },
|
29
|
+
hasError: { type: Boolean, default: false },
|
30
|
+
userId: { type: String, default: null },
|
31
|
+
userReaction: { type: Number, default: 0 },
|
32
|
+
userFeedback: { type: String, default: null },
|
33
|
+
title: { type: String, default: null },
|
34
|
+
styleCategory: { type: String, default: null },
|
35
|
+
styleSubCategory: { type: String, default: null },
|
36
|
+
colors: { type: [{ type: String, default: null }], default: null, _id: false },
|
37
|
+
appName: { type: String, default: null },
|
38
|
+
},
|
39
|
+
{
|
40
|
+
timestamps: true,
|
41
|
+
}
|
42
|
+
);
|
43
|
+
|
44
|
+
export const PngSvgModel = model<IPngSvgSchema>("png-svg", PngSvgSchema);
|
@@ -0,0 +1,22 @@
|
|
1
|
+
import { Schema, model, Types } from "mongoose";
|
2
|
+
|
3
|
+
export interface IPPTEmailQueueSchema {
|
4
|
+
pptRef: Types.ObjectId;
|
5
|
+
emailType: string;
|
6
|
+
sent: boolean;
|
7
|
+
}
|
8
|
+
|
9
|
+
const PPTEmailQueueSchema = new Schema<IPPTEmailQueueSchema>(
|
10
|
+
{
|
11
|
+
pptRef: { type: Schema.Types.ObjectId, ref: 'ppt' },
|
12
|
+
emailType: { type: String, required: true },
|
13
|
+
sent: { type: Boolean, default: false }
|
14
|
+
},
|
15
|
+
{
|
16
|
+
timestamps: true,
|
17
|
+
}
|
18
|
+
);
|
19
|
+
|
20
|
+
PPTEmailQueueSchema.index({sent: 1, createdAt: 1});
|
21
|
+
|
22
|
+
export const PPTEmailQueueModel = model<IPPTEmailQueueSchema>("ppt-email-queue", PPTEmailQueueSchema);
|
@@ -0,0 +1,25 @@
|
|
1
|
+
import { Schema, model, Types } from "mongoose";
|
2
|
+
|
3
|
+
|
4
|
+
export interface IPPTEventSchema {
|
5
|
+
pptRef: Types.ObjectId;
|
6
|
+
event: string;
|
7
|
+
message: string;
|
8
|
+
appName: string;
|
9
|
+
createdAt?: Date;
|
10
|
+
updatedAt?: Date;
|
11
|
+
}
|
12
|
+
|
13
|
+
const PPTEventSchema = new Schema<IPPTEventSchema>(
|
14
|
+
{
|
15
|
+
pptRef: { type: Schema.Types.ObjectId, ref: 'ppt' },
|
16
|
+
message: { type: String, default: null },
|
17
|
+
event: { type: String, default: null },
|
18
|
+
appName: { type: String, default: null }
|
19
|
+
},
|
20
|
+
{
|
21
|
+
timestamps: true,
|
22
|
+
}
|
23
|
+
);
|
24
|
+
|
25
|
+
export const PPTSlideEventModel = model<IPPTEventSchema>("ppt-event", PPTEventSchema);
|
@@ -0,0 +1,40 @@
|
|
1
|
+
import { Schema, model, Types } from "mongoose";
|
2
|
+
export interface IPPTSlideSchema {
|
3
|
+
pptRef: Types.ObjectId;
|
4
|
+
slideRef: Types.ObjectId;
|
5
|
+
slideLayoutRef: Types.ObjectId;
|
6
|
+
title: string;
|
7
|
+
rawData: string;
|
8
|
+
originalData: string;
|
9
|
+
images: string;
|
10
|
+
staticData: string;
|
11
|
+
createdAt?: Date;
|
12
|
+
updatedAt?: Date;
|
13
|
+
deletedAt?: Date;
|
14
|
+
istmp?: boolean;
|
15
|
+
appName: string;
|
16
|
+
}
|
17
|
+
|
18
|
+
const PPTSlideSchema = new Schema<IPPTSlideSchema>(
|
19
|
+
{
|
20
|
+
deletedAt: { type: Date, default: null },
|
21
|
+
pptRef: { type: Schema.Types.ObjectId, ref: 'ppt' },
|
22
|
+
slideRef: { type: Schema.Types.ObjectId, ref: 'slide' },
|
23
|
+
slideLayoutRef: { type: Schema.Types.ObjectId, ref: 'slide-layout' },
|
24
|
+
title: { type: String, default: null },
|
25
|
+
rawData: { type: String, default: "{}" },
|
26
|
+
originalData: { type: String, default: "{}" },
|
27
|
+
staticData: {type: String, default: "{}" },
|
28
|
+
images: { type: String, default: "{}" },
|
29
|
+
istmp: { type: Boolean, default: false },
|
30
|
+
appName: { type: String, default: null },
|
31
|
+
},
|
32
|
+
{
|
33
|
+
timestamps: true,
|
34
|
+
}
|
35
|
+
);
|
36
|
+
|
37
|
+
PPTSlideSchema.index({ createdAt: 1,istmp: 1})
|
38
|
+
|
39
|
+
|
40
|
+
export const PPTSlideModel = model<IPPTSlideSchema>("ppt-slide", PPTSlideSchema);
|
@@ -0,0 +1,79 @@
|
|
1
|
+
import { Schema, model, Types } from "mongoose";
|
2
|
+
|
3
|
+
export interface IPPTSchema {
|
4
|
+
systemGeneratedtopics: Array<string>;
|
5
|
+
userSelectedTopics: Array<string>;
|
6
|
+
userLanguageTopics: Array<string>;
|
7
|
+
colors: Array<string>;
|
8
|
+
slideRefs: Types.ObjectId[];
|
9
|
+
templateId: Types.ObjectId;
|
10
|
+
templateTypeId: Types.ObjectId;
|
11
|
+
prompt: string;
|
12
|
+
promptAlias: string;
|
13
|
+
userId: string;
|
14
|
+
userReaction: number;
|
15
|
+
userFeedback: string;
|
16
|
+
isLocked?: boolean;
|
17
|
+
fileCreated?: boolean;
|
18
|
+
isCompleted?: boolean;
|
19
|
+
createdAt?: Date;
|
20
|
+
updatedAt?: Date;
|
21
|
+
deletedAt?: Date;
|
22
|
+
hasError?: boolean;
|
23
|
+
version?: string;
|
24
|
+
noOfSlides: number;
|
25
|
+
trackIP: string;
|
26
|
+
sessionId: string;
|
27
|
+
fileCreateCount: number;
|
28
|
+
language: string;
|
29
|
+
info: string;
|
30
|
+
addtionalInfoUrl: string;
|
31
|
+
appName: string;
|
32
|
+
navigateFromGPT: boolean;
|
33
|
+
googleDriveId: string;
|
34
|
+
isPartialFile: boolean;
|
35
|
+
isEditable: boolean;
|
36
|
+
}
|
37
|
+
|
38
|
+
const PPTSchema = new Schema<IPPTSchema>(
|
39
|
+
{
|
40
|
+
deletedAt: { type: Date, default: null },
|
41
|
+
isLocked: { type: Boolean, default: false },
|
42
|
+
isCompleted: { type: Boolean, default: false },
|
43
|
+
fileCreated: { type: Boolean, default: false }, // S3 file creation
|
44
|
+
userId: { type: String, default: null },
|
45
|
+
templateTypeId: { type: Schema.Types.ObjectId, ref: "template-type" },
|
46
|
+
systemGeneratedtopics: { type: [String], default: [], _id: false },
|
47
|
+
userSelectedTopics: { type: [String], default: [], _id: false },
|
48
|
+
userLanguageTopics: { type: [String], default: [], _id: false },
|
49
|
+
userReaction: { type: Number, default: 0 },
|
50
|
+
userFeedback: { type: String, default: null },
|
51
|
+
colors: { type: [String], default: [], _id: false },
|
52
|
+
templateId: { type: Schema.Types.ObjectId, ref: 'template' },
|
53
|
+
hasError: { type: Boolean, default: false },
|
54
|
+
slideRefs: {type: [{ type: Schema.Types.ObjectId, ref: 'ppt-slide' }], default: [], _id: false},
|
55
|
+
version: { type: String, default: null },
|
56
|
+
trackIP: { type: String, default: null },
|
57
|
+
sessionId: { type: String, default: null },
|
58
|
+
fileCreateCount: { type: Number, default: 0},
|
59
|
+
language: { type: String, default: "English" },
|
60
|
+
addtionalInfoUrl: { type: String, default: null },
|
61
|
+
info: { type: String, default: null },
|
62
|
+
prompt: { type: String, default: null },
|
63
|
+
promptAlias: { type: String, default: null },
|
64
|
+
noOfSlides: { type: Number, default: null },
|
65
|
+
appName: { type: String, default: null },
|
66
|
+
navigateFromGPT: { type: Boolean, default: false },
|
67
|
+
googleDriveId: { type: String, default: null }, // google file creation
|
68
|
+
isPartialFile: { type: Boolean, default: false }, // was free file created
|
69
|
+
isEditable: { type: Boolean, default: false } // if is editable is true them menas user will get PPT in editable format
|
70
|
+
},
|
71
|
+
{
|
72
|
+
timestamps: true,
|
73
|
+
}
|
74
|
+
);
|
75
|
+
|
76
|
+
PPTSchema.index({userId: 1, isCompleted: 1, hasError: 1, isLocked: 1});
|
77
|
+
|
78
|
+
|
79
|
+
export const PPTModel = model<IPPTSchema>("ppt", PPTSchema);
|
@@ -0,0 +1,56 @@
|
|
1
|
+
import { Schema, model, Types } from "mongoose";
|
2
|
+
import { ISystemLayout, IMessageSchema } from "./common";
|
3
|
+
|
4
|
+
|
5
|
+
export interface ISlideLayoutSchema {
|
6
|
+
name: string;
|
7
|
+
alias: string[];
|
8
|
+
templateTypeId: Types.ObjectId;
|
9
|
+
createdAt: Date;
|
10
|
+
updatedAt: Date;
|
11
|
+
deletedAt: Date;
|
12
|
+
published: boolean;
|
13
|
+
insertSelectionPrompt: ISystemLayout;
|
14
|
+
newSelectionPrompt: ISystemLayout;
|
15
|
+
slideSelectionQuestion: string;
|
16
|
+
category: string;
|
17
|
+
subCategory: string[];
|
18
|
+
displayName: string;
|
19
|
+
}
|
20
|
+
|
21
|
+
const messageSchema = new Schema<IMessageSchema>({
|
22
|
+
message: { type: String },
|
23
|
+
keys: { type: [String] },
|
24
|
+
}, {
|
25
|
+
timestamps: false,
|
26
|
+
_id: false
|
27
|
+
})
|
28
|
+
|
29
|
+
const systemSchema = new Schema<ISystemLayout>({
|
30
|
+
system: messageSchema,
|
31
|
+
user: messageSchema
|
32
|
+
}, {
|
33
|
+
timestamps: false,
|
34
|
+
_id: false
|
35
|
+
})
|
36
|
+
|
37
|
+
const SlideLayoutSchema = new Schema<ISlideLayoutSchema>(
|
38
|
+
{
|
39
|
+
published: { type: Boolean, default: false },
|
40
|
+
name: { type: String, default: "", required: true },
|
41
|
+
displayName: { type: String, default: "" },
|
42
|
+
alias: { type: [String], default: [], _id: false },
|
43
|
+
templateTypeId: { type: Schema.Types.ObjectId, ref: "template-type" },
|
44
|
+
deletedAt: { type: Date, default: null },
|
45
|
+
insertSelectionPrompt: systemSchema,
|
46
|
+
newSelectionPrompt: systemSchema,
|
47
|
+
category: { type: String, default: "Default"},
|
48
|
+
subCategory: { type: [String], default: [], _id: false },
|
49
|
+
slideSelectionQuestion: { type: String, default: ""}
|
50
|
+
},
|
51
|
+
{
|
52
|
+
timestamps: true,
|
53
|
+
}
|
54
|
+
);
|
55
|
+
|
56
|
+
export const SlideLayoutModel = model<ISlideLayoutSchema>("slide-layout", SlideLayoutSchema);
|