biz-email-builder-shared 1.6.38 → 1.6.39

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.
@@ -7,8 +7,9 @@ export interface IBookmarkFolder extends Document {
7
7
  name: string;
8
8
  user: Types.ObjectId;
9
9
  templates: IBookmarkTemplate[];
10
- createdAt?: Date;
11
- updateAt?: Date;
10
+ createdAt: Date;
11
+ updateAt: Date;
12
+ isDeleted: boolean;
12
13
  }
13
14
  export declare const BookmarkModel: import("mongoose").Model<IBookmarkFolder, {}, {}, {}, Document<unknown, {}, IBookmarkFolder> & IBookmarkFolder & Required<{
14
15
  _id: unknown;
@@ -1 +1 @@
1
- {"version":3,"file":"bookmark.entity.d.ts","sourceRoot":"","sources":["../../src/entity/bookmark.entity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,QAAQ,EAAE,KAAK,EAAE,MAAM,UAAU,CAAC;AAE1D,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,KAAK,CAAC,QAAQ,CAAC;IACzB,OAAO,CAAC,EAAE,IAAI,CAAC;CAChB;AAED,MAAM,WAAW,eAAgB,SAAQ,QAAQ;IAC/C,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,KAAK,CAAC,QAAQ,CAAC;IACrB,SAAS,EAAE,iBAAiB,EAAE,CAAC;IAC/B,SAAS,CAAC,EAAE,IAAI,CAAC;IACjB,QAAQ,CAAC,EAAE,IAAI,CAAA;CAChB;AAcD,eAAO,MAAM,aAAa;;;;OAA2D,CAAC"}
1
+ {"version":3,"file":"bookmark.entity.d.ts","sourceRoot":"","sources":["../../src/entity/bookmark.entity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,QAAQ,EAAE,KAAK,EAAE,MAAM,UAAU,CAAC;AAE1D,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,KAAK,CAAC,QAAQ,CAAC;IACzB,OAAO,CAAC,EAAE,IAAI,CAAC;CAChB;AAED,MAAM,WAAW,eAAgB,SAAQ,QAAQ;IAC/C,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,KAAK,CAAC,QAAQ,CAAC;IACrB,SAAS,EAAE,iBAAiB,EAAE,CAAC;IAC/B,SAAS,EAAE,IAAI,CAAC;IAChB,QAAQ,EAAE,IAAI,CAAC;IACf,SAAS,EAAE,OAAO,CAAC;CACpB;AAeD,eAAO,MAAM,aAAa;;;;OAA2D,CAAC"}
@@ -9,6 +9,7 @@ const BookmarkTemplateSchema = new mongoose_1.Schema({
9
9
  const BookmarkFolderSchema = new mongoose_1.Schema({
10
10
  name: { type: String, required: true, },
11
11
  user: { type: mongoose_1.Schema.Types.ObjectId, ref: 'user', required: true, },
12
- templates: [BookmarkTemplateSchema]
12
+ templates: [BookmarkTemplateSchema],
13
+ isDeleted: { type: Boolean, default: false }
13
14
  }, { timestamps: true });
14
15
  exports.BookmarkModel = (0, mongoose_1.model)('bookmark', BookmarkFolderSchema);
@@ -2,9 +2,6 @@ import { Types } from "mongoose";
2
2
  export interface IOrganisation extends Document {
3
3
  name: string;
4
4
  user: Types.ObjectId;
5
- websiteURL: string;
6
- phoneNumber: string;
7
- industryName: string;
8
5
  isDisable: boolean;
9
6
  deletedAt: Date | null;
10
7
  updatedBy: Types.ObjectId;
@@ -1 +1 @@
1
- {"version":3,"file":"organisation.entity.d.ts","sourceRoot":"","sources":["../../src/entity/organisation.entity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,EAAE,MAAM,UAAU,CAAC;AAEhD,MAAM,WAAW,aAAc,SAAQ,QAAQ;IAC7C,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,KAAK,CAAC,QAAQ,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;IACrB,SAAS,EAAE,OAAO,CAAC;IACnB,SAAS,EAAE,IAAI,GAAG,IAAI,CAAC;IACvB,SAAS,EAAE,KAAK,CAAC,QAAQ,CAAC;IAC1B,SAAS,EAAE,IAAI,CAAC;IAChB,SAAS,EAAE,IAAI,CAAC;CACjB;AAaD,eAAO,MAAM,iBAAiB;SACs9H,MAAO,QAAQ;;;OAD16H,CAAC"}
1
+ {"version":3,"file":"organisation.entity.d.ts","sourceRoot":"","sources":["../../src/entity/organisation.entity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,EAAE,MAAM,UAAU,CAAC;AAEhD,MAAM,WAAW,aAAc,SAAQ,QAAQ;IAC7C,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,KAAK,CAAC,QAAQ,CAAC;IACrB,SAAS,EAAE,OAAO,CAAC;IACnB,SAAS,EAAE,IAAI,GAAG,IAAI,CAAC;IACvB,SAAS,EAAE,KAAK,CAAC,QAAQ,CAAC;IAC1B,SAAS,EAAE,IAAI,CAAC;IAChB,SAAS,EAAE,IAAI,CAAC;CACjB;AAUD,eAAO,MAAM,iBAAiB;SACorI,MAAO,QAAQ;;;OADxoI,CAAC"}
@@ -5,9 +5,6 @@ const mongoose_1 = require("mongoose");
5
5
  const OrganisationSchema = new mongoose_1.Schema({
6
6
  name: { type: String, required: true },
7
7
  user: { type: mongoose_1.Schema.Types.ObjectId, ref: "user", required: true },
8
- websiteURL: { type: String, required: true },
9
- phoneNumber: { type: String, required: true },
10
- industryName: { type: String, required: true },
11
8
  isDisable: { type: Boolean, default: false },
12
9
  deletedAt: { type: Date, default: null },
13
10
  updatedBy: { type: mongoose_1.Schema.Types.ObjectId, ref: "user", required: true },
@@ -0,0 +1,24 @@
1
+ import { Document } from 'mongoose';
2
+ export interface IGeneralDetails {
3
+ companyName: string;
4
+ industry: string;
5
+ website: string;
6
+ phoneNumber: string;
7
+ }
8
+ export interface IBillingDetails {
9
+ numberOfLicense: number;
10
+ billingDuration: string;
11
+ }
12
+ export interface UserInfo extends Document {
13
+ generalDetails: IGeneralDetails;
14
+ billingDetails: IBillingDetails;
15
+ createdAt: Date;
16
+ updateAt: Date;
17
+ isDeleted: boolean;
18
+ }
19
+ export declare const UserInfoModel: import("mongoose").Model<UserInfo, {}, {}, {}, Document<unknown, {}, UserInfo> & UserInfo & Required<{
20
+ _id: unknown;
21
+ }> & {
22
+ __v: number;
23
+ }, any>;
24
+ //# sourceMappingURL=user-info.entity.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"user-info.entity.d.ts","sourceRoot":"","sources":["../../src/entity/user-info.entity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,QAAQ,EAAS,MAAM,UAAU,CAAC;AAEnD,MAAM,WAAW,eAAe;IAC9B,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,eAAe;IAC9B,eAAe,EAAE,MAAM,CAAC;IACxB,eAAe,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,WAAW,QAAS,SAAQ,QAAQ;IACxC,cAAc,EAAE,eAAe,CAAC;IAChC,cAAc,EAAE,eAAe,CAAC;IAChC,SAAS,EAAE,IAAI,CAAC;IAChB,QAAQ,EAAE,IAAI,CAAC;IACf,SAAS,EAAE,OAAO,CAAC;CACpB;AAuBD,eAAO,MAAM,aAAa;;;;OAA+C,CAAC"}
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.UserInfoModel = void 0;
4
+ const mongoose_1 = require("mongoose");
5
+ const GeneralDetailsSchema = new mongoose_1.Schema({
6
+ companyName: { type: String, required: true },
7
+ industry: { type: String, required: true },
8
+ website: { type: String, required: true },
9
+ phoneNumber: { type: String, required: true },
10
+ }, { _id: false });
11
+ const BillingDetailsSchema = new mongoose_1.Schema({
12
+ numberOfLicense: { type: Number, required: true },
13
+ billingDuration: { type: String, required: true },
14
+ }, { _id: false });
15
+ const UserInfoSchema = new mongoose_1.Schema({
16
+ generalDetails: { type: GeneralDetailsSchema, required: true },
17
+ billingDetails: { type: BillingDetailsSchema, required: true },
18
+ isDeleted: { type: Boolean, default: false }
19
+ }, { timestamps: true });
20
+ exports.UserInfoModel = (0, mongoose_1.model)('user-info', UserInfoSchema);
@@ -47,7 +47,7 @@ const authorize = () => {
47
47
  let currentPlanDetail = await entity_1.PlanHistoryModel.find({ user: user._id.toString(), isTransactionSuccessfull: true }).populate({ path: "subscriptionPlanId", select: "_id planName" }).lean().exec();
48
48
  if (currentPlanDetail && currentPlanDetail.length) {
49
49
  req.userSubsciptionQuota = currentPlanDetail[0].subscriptionQuota;
50
- req.currentPlanId = currentPlanDetail[0].subscriptionPlanId;
50
+ req.currentPlan = currentPlanDetail[0].subscriptionPlanId;
51
51
  if (currentPlanDetail[0].renewalDate) {
52
52
  req.isSubscriptionActive = !(currentPlanDetail[0].renewalDate < new Date());
53
53
  }
@@ -19,7 +19,7 @@ export interface IRequestUser {
19
19
  _id: string;
20
20
  }
21
21
  export interface IRequest extends Request {
22
- currentPlanId?: Object | string;
22
+ currentPlan?: Object | string;
23
23
  user?: IRequestUser;
24
24
  isSubscriptionActive?: boolean;
25
25
  userSubsciptionQuota?: ISubscriptionQuota;
@@ -1 +1 @@
1
- {"version":3,"file":"IRequest.d.ts","sourceRoot":"","sources":["../../src/types/IRequest.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClC,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAC1E,OAAO,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAE/C,MAAM,WAAW,YAAY;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,IAAI,EAAE,KAAK,CAAC;IACZ,UAAU,EAAE,cAAc,CAAC;IAC3B,MAAM,EAAE,KAAK,CAAC;QACV,IAAI,EAAE,MAAM,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WAAW,QAAS,SAAQ,OAAO;IACrC,WAAW,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC9B,IAAI,CAAC,EAAE,YAAY,CAAC;IACpB,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAC/B,oBAAoB,CAAC,EAAE,kBAAkB,CAAC;IAC1C,IAAI,CAAC,EAAE,GAAG,CAAC;CACd"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "biz-email-builder-shared",
3
- "version": "1.6.38",
3
+ "version": "1.6.39",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "files": [