@lyxa.ai/core 1.0.15 → 1.0.16
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/index.d.ts +4 -4
- package/dist/index.js +6 -7
- package/dist/index.js.map +1 -1
- package/dist/libraries/auth/index.d.ts +3 -3
- package/dist/libraries/auth/index.js +26 -26
- package/dist/libraries/auth/index.js.map +1 -1
- package/dist/libraries/auth/refreshtoken.d.ts +1 -1
- package/dist/libraries/auth/refreshtoken.js +6 -10
- package/dist/libraries/auth/refreshtoken.js.map +1 -1
- package/dist/libraries/auth/repository.d.ts +3 -3
- package/dist/libraries/auth/repository.js +1 -5
- package/dist/libraries/auth/repository.js.map +1 -1
- package/dist/libraries/configuration/index.d.ts +2 -2
- package/dist/libraries/configuration/index.js +20 -20
- package/dist/libraries/configuration/index.js.map +1 -1
- package/dist/libraries/configuration/types/EnvironmentConfigurationType.js.map +1 -1
- package/dist/libraries/dispatcher/index.d.ts +2 -2
- package/dist/libraries/dispatcher/index.js +2 -2
- package/dist/libraries/dispatcher/index.js.map +1 -1
- package/dist/libraries/event/BaseEvent.js.map +1 -1
- package/dist/libraries/event/decorators/metadata.d.ts +1 -1
- package/dist/libraries/event/decorators/metadata.js.map +1 -1
- package/dist/libraries/event/decorators/subscribe.js.map +1 -1
- package/dist/libraries/event/index.d.ts +1 -1
- package/dist/libraries/event/index.js +6 -6
- package/dist/libraries/event/index.js.map +1 -1
- package/dist/libraries/event/registry/SubscriptionRegistry.js.map +1 -1
- package/dist/libraries/event/test/OrderCreationEvent.d.ts +1 -1
- package/dist/libraries/event/test/OrderCreationEvent.js +9 -6
- package/dist/libraries/event/test/OrderCreationEvent.js.map +1 -1
- package/dist/libraries/firebase/index.d.ts +1 -1
- package/dist/libraries/firebase/index.js.map +1 -1
- package/dist/libraries/index.d.ts +9 -9
- package/dist/libraries/index.js +1 -1
- package/dist/libraries/index.js.map +1 -1
- package/dist/libraries/logger/index.d.ts +1 -1
- package/dist/libraries/logger/index.js +9 -9
- package/dist/libraries/logger/index.js.map +1 -1
- package/dist/libraries/mongo/index.d.ts +1 -1
- package/dist/libraries/mongo/index.js +11 -11
- package/dist/libraries/mongo/index.js.map +1 -1
- package/dist/libraries/mongo/models/activity-log.model.d.ts +1 -2
- package/dist/libraries/mongo/models/activity-log.model.js +1 -2
- package/dist/libraries/mongo/models/activity-log.model.js.map +1 -1
- package/dist/libraries/mongo/models/admin-access-control.model.d.ts +1 -2
- package/dist/libraries/mongo/models/admin-access-control.model.js +1 -2
- package/dist/libraries/mongo/models/admin-access-control.model.js.map +1 -1
- package/dist/libraries/mongo/models/admin.model.d.ts +3 -2
- package/dist/libraries/mongo/models/admin.model.js +20 -3
- package/dist/libraries/mongo/models/admin.model.js.map +1 -1
- package/dist/libraries/mongo/models/app-screen-setting.model.d.ts +0 -2
- package/dist/libraries/mongo/models/app-screen-setting.model.js +1 -2
- package/dist/libraries/mongo/models/app-screen-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/attribute.model.d.ts +1 -2
- package/dist/libraries/mongo/models/attribute.model.js +1 -2
- package/dist/libraries/mongo/models/attribute.model.js.map +1 -1
- package/dist/libraries/mongo/models/banner.model.d.ts +1 -2
- package/dist/libraries/mongo/models/banner.model.js +1 -2
- package/dist/libraries/mongo/models/banner.model.js.map +1 -1
- package/dist/libraries/mongo/models/base/base-coupon.model.js.map +1 -1
- package/dist/libraries/mongo/models/base/base-review.model.js.map +1 -1
- package/dist/libraries/mongo/models/bob-finance.model.d.ts +2 -3
- package/dist/libraries/mongo/models/bob-finance.model.js +2 -3
- package/dist/libraries/mongo/models/bob-finance.model.js.map +1 -1
- package/dist/libraries/mongo/models/brand.model.d.ts +0 -2
- package/dist/libraries/mongo/models/brand.model.js +1 -2
- package/dist/libraries/mongo/models/brand.model.js.map +1 -1
- package/dist/libraries/mongo/models/category.model.d.ts +1 -2
- package/dist/libraries/mongo/models/category.model.js +1 -2
- package/dist/libraries/mongo/models/category.model.js.map +1 -1
- package/dist/libraries/mongo/models/core-auth-identity.model.js.map +1 -1
- package/dist/libraries/mongo/models/core-user.model.js.map +1 -1
- package/dist/libraries/mongo/models/counter.model.d.ts +0 -2
- package/dist/libraries/mongo/models/counter.model.js +1 -2
- package/dist/libraries/mongo/models/counter.model.js.map +1 -1
- package/dist/libraries/mongo/models/coupon.model.d.ts +0 -2
- package/dist/libraries/mongo/models/coupon.model.js +4 -3
- package/dist/libraries/mongo/models/coupon.model.js.map +1 -1
- package/dist/libraries/mongo/models/deal-setting.model.d.ts +0 -2
- package/dist/libraries/mongo/models/deal-setting.model.js +1 -2
- package/dist/libraries/mongo/models/deal-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/dish.model.d.ts +1 -2
- package/dist/libraries/mongo/models/dish.model.js +1 -2
- package/dist/libraries/mongo/models/dish.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/attribute-item.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/attribute-map.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/business-development-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/charge-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/charge.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/courier-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/currency-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/currency.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/featured-item.mode.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/otp-fields.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/package.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/parent-document.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/payout-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/price.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/product-nutrition.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/referral-discount-config.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/rider-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/service-fee-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/shop-document.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/subscription-summary.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/zone-geometry.mode.js.map +1 -1
- package/dist/libraries/mongo/models/faq.model.d.ts +0 -2
- package/dist/libraries/mongo/models/faq.model.js +1 -2
- package/dist/libraries/mongo/models/faq.model.js.map +1 -1
- package/dist/libraries/mongo/models/favourite.model.d.ts +3 -4
- package/dist/libraries/mongo/models/favourite.model.js +3 -4
- package/dist/libraries/mongo/models/favourite.model.js.map +1 -1
- package/dist/libraries/mongo/models/featured-setting.model.d.ts +0 -2
- package/dist/libraries/mongo/models/featured-setting.model.js +1 -2
- package/dist/libraries/mongo/models/featured-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/filter-container.model.d.ts +0 -1
- package/dist/libraries/mongo/models/filter-container.model.js +1 -2
- package/dist/libraries/mongo/models/filter-container.model.js.map +1 -1
- package/dist/libraries/mongo/models/index.d.ts +113 -7
- package/dist/libraries/mongo/models/index.js +117 -7
- package/dist/libraries/mongo/models/index.js.map +1 -1
- package/dist/libraries/mongo/models/list-container.model.d.ts +2 -3
- package/dist/libraries/mongo/models/list-container.model.js +2 -3
- package/dist/libraries/mongo/models/list-container.model.js.map +1 -1
- package/dist/libraries/mongo/models/loyalty-point-category.model.d.ts +0 -2
- package/dist/libraries/mongo/models/loyalty-point-category.model.js +1 -2
- package/dist/libraries/mongo/models/loyalty-point-category.model.js.map +1 -1
- package/dist/libraries/mongo/models/loyalty-point-setting.model.d.ts +0 -2
- package/dist/libraries/mongo/models/loyalty-point-setting.model.js +1 -2
- package/dist/libraries/mongo/models/loyalty-point-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/marketing.model.d.ts +2 -3
- package/dist/libraries/mongo/models/marketing.model.js +13 -5
- package/dist/libraries/mongo/models/marketing.model.js.map +1 -1
- package/dist/libraries/mongo/models/meal-plan.model.d.ts +0 -2
- package/dist/libraries/mongo/models/meal-plan.model.js +1 -2
- package/dist/libraries/mongo/models/meal-plan.model.js.map +1 -1
- package/dist/libraries/mongo/models/notification.model.d.ts +8 -9
- package/dist/libraries/mongo/models/notification.model.js +8 -9
- package/dist/libraries/mongo/models/notification.model.js.map +1 -1
- package/dist/libraries/mongo/models/nutrition.model.d.ts +0 -2
- package/dist/libraries/mongo/models/nutrition.model.js +1 -2
- package/dist/libraries/mongo/models/nutrition.model.js.map +1 -1
- package/dist/libraries/mongo/models/order.model.js.map +1 -1
- package/dist/libraries/mongo/models/parent.model.d.ts +3 -4
- package/dist/libraries/mongo/models/parent.model.js +8 -5
- package/dist/libraries/mongo/models/parent.model.js.map +1 -1
- package/dist/libraries/mongo/models/payout.model.js.map +1 -1
- package/dist/libraries/mongo/models/product-marketing.model.d.ts +3 -4
- package/dist/libraries/mongo/models/product-marketing.model.js +3 -4
- package/dist/libraries/mongo/models/product-marketing.model.js.map +1 -1
- package/dist/libraries/mongo/models/product.model.d.ts +1 -3
- package/dist/libraries/mongo/models/product.model.js +8 -4
- package/dist/libraries/mongo/models/product.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/buy1-get1-marketing.model.d.ts +1 -2
- package/dist/libraries/mongo/models/providers/buy1-get1-marketing.model.js +1 -2
- package/dist/libraries/mongo/models/providers/buy1-get1-marketing.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/core-apple-auth-identity.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/core-email-auth-identity.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/core-google-auth-identity.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/core-phone-auth-identity.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/custom-coupon.model.d.ts +1 -2
- package/dist/libraries/mongo/models/providers/custom-coupon.model.js +1 -3
- package/dist/libraries/mongo/models/providers/custom-coupon.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/discount-marketing.model.d.ts +1 -2
- package/dist/libraries/mongo/models/providers/discount-marketing.model.js +1 -2
- package/dist/libraries/mongo/models/providers/discount-marketing.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/featured-marketing.model.d.ts +0 -2
- package/dist/libraries/mongo/models/providers/featured-marketing.model.js +1 -2
- package/dist/libraries/mongo/models/providers/featured-marketing.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/free-delivery-marketing.model.d.ts +0 -2
- package/dist/libraries/mongo/models/providers/free-delivery-marketing.model.js +1 -2
- package/dist/libraries/mongo/models/providers/free-delivery-marketing.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/global-coupon.model.d.ts +0 -2
- package/dist/libraries/mongo/models/providers/global-coupon.model.js +1 -4
- package/dist/libraries/mongo/models/providers/global-coupon.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/individual-store-coupon.model.d.ts +1 -2
- package/dist/libraries/mongo/models/providers/individual-store-coupon.model.js +1 -3
- package/dist/libraries/mongo/models/providers/individual-store-coupon.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/individual-user-coupon.model.d.ts +1 -2
- package/dist/libraries/mongo/models/providers/individual-user-coupon.model.js +1 -3
- package/dist/libraries/mongo/models/providers/individual-user-coupon.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/loyalty-point-marketing.model.d.ts +1 -2
- package/dist/libraries/mongo/models/providers/loyalty-point-marketing.model.js +1 -2
- package/dist/libraries/mongo/models/providers/loyalty-point-marketing.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/punch-marketing.model.d.ts +0 -2
- package/dist/libraries/mongo/models/providers/punch-marketing.model.js +1 -2
- package/dist/libraries/mongo/models/providers/punch-marketing.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/referral-code-coupon.model.d.ts +1 -2
- package/dist/libraries/mongo/models/providers/referral-code-coupon.model.js +1 -2
- package/dist/libraries/mongo/models/providers/referral-code-coupon.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/referral-reward-coupon.model.d.ts +1 -2
- package/dist/libraries/mongo/models/providers/referral-reward-coupon.model.js +1 -3
- package/dist/libraries/mongo/models/providers/referral-reward-coupon.model.js.map +1 -1
- package/dist/libraries/mongo/models/punch-marketing-history.model.d.ts +1 -2
- package/dist/libraries/mongo/models/punch-marketing-history.model.js +1 -2
- package/dist/libraries/mongo/models/punch-marketing-history.model.js.map +1 -1
- package/dist/libraries/mongo/models/rating-setting.model.d.ts +0 -2
- package/dist/libraries/mongo/models/rating-setting.model.js +1 -2
- package/dist/libraries/mongo/models/rating-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/referral-setting.model.d.ts +0 -2
- package/dist/libraries/mongo/models/referral-setting.model.js +1 -2
- package/dist/libraries/mongo/models/referral-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/request-area.model.d.ts +1 -2
- package/dist/libraries/mongo/models/request-area.model.js +1 -2
- package/dist/libraries/mongo/models/request-area.model.js.map +1 -1
- package/dist/libraries/mongo/models/rider-review.model.d.ts +1 -2
- package/dist/libraries/mongo/models/rider-review.model.js +1 -2
- package/dist/libraries/mongo/models/rider-review.model.js.map +1 -1
- package/dist/libraries/mongo/models/rider.model.js.map +1 -1
- package/dist/libraries/mongo/models/role.model.d.ts +0 -2
- package/dist/libraries/mongo/models/role.model.js +1 -3
- package/dist/libraries/mongo/models/role.model.js.map +1 -1
- package/dist/libraries/mongo/models/setting.model.d.ts +6 -8
- package/dist/libraries/mongo/models/setting.model.js +7 -8
- package/dist/libraries/mongo/models/setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/shared/address.model.d.ts +1 -1
- package/dist/libraries/mongo/models/shared/address.model.js.map +1 -1
- package/dist/libraries/mongo/models/shared/duration.model.js.map +1 -1
- package/dist/libraries/mongo/models/shared/work-hour.model.d.ts +1 -1
- package/dist/libraries/mongo/models/shared/work-hour.model.js +1 -1
- package/dist/libraries/mongo/models/shared/work-hour.model.js.map +1 -1
- package/dist/libraries/mongo/models/shop-access-control.model.d.ts +1 -2
- package/dist/libraries/mongo/models/shop-access-control.model.js +1 -2
- package/dist/libraries/mongo/models/shop-access-control.model.js.map +1 -1
- package/dist/libraries/mongo/models/shop-category.model.d.ts +2 -3
- package/dist/libraries/mongo/models/shop-category.model.js +2 -3
- package/dist/libraries/mongo/models/shop-category.model.js.map +1 -1
- package/dist/libraries/mongo/models/shop-meal-plan.model.d.ts +2 -3
- package/dist/libraries/mongo/models/shop-meal-plan.model.js +2 -3
- package/dist/libraries/mongo/models/shop-meal-plan.model.js.map +1 -1
- package/dist/libraries/mongo/models/shop-product.model.d.ts +4 -5
- package/dist/libraries/mongo/models/shop-product.model.js +4 -5
- package/dist/libraries/mongo/models/shop-product.model.js.map +1 -1
- package/dist/libraries/mongo/models/shop-review.model.d.ts +1 -2
- package/dist/libraries/mongo/models/shop-review.model.js +1 -2
- package/dist/libraries/mongo/models/shop-review.model.js.map +1 -1
- package/dist/libraries/mongo/models/shop.model.d.ts +3 -4
- package/dist/libraries/mongo/models/shop.model.js +12 -6
- package/dist/libraries/mongo/models/shop.model.js.map +1 -1
- package/dist/libraries/mongo/models/subscription-setting.model.d.ts +0 -2
- package/dist/libraries/mongo/models/subscription-setting.model.js +7 -3
- package/dist/libraries/mongo/models/subscription-setting.model.js.map +1 -1
- package/dist/libraries/mongo/models/subscription.model.d.ts +3 -4
- package/dist/libraries/mongo/models/subscription.model.js +13 -6
- package/dist/libraries/mongo/models/subscription.model.js.map +1 -1
- package/dist/libraries/mongo/models/tag.model.d.ts +0 -2
- package/dist/libraries/mongo/models/tag.model.js +1 -2
- package/dist/libraries/mongo/models/tag.model.js.map +1 -1
- package/dist/libraries/mongo/models/transaction.model.js.map +1 -1
- package/dist/libraries/mongo/models/zone.model.d.ts +0 -2
- package/dist/libraries/mongo/models/zone.model.js +1 -2
- package/dist/libraries/mongo/models/zone.model.js.map +1 -1
- package/dist/libraries/mongo/plugins/soft-delete-plugin.d.ts +8 -7
- package/dist/libraries/mongo/plugins/soft-delete-plugin.js +6 -6
- package/dist/libraries/mongo/plugins/soft-delete-plugin.js.map +1 -1
- package/dist/libraries/redis/index.d.ts +1 -1
- package/dist/libraries/redis/index.js +4 -1
- package/dist/libraries/redis/index.js.map +1 -1
- package/dist/libraries/secrets/index.d.ts +2 -2
- package/dist/libraries/secrets/index.js +13 -13
- package/dist/libraries/secrets/index.js.map +1 -1
- package/dist/libraries/trpc/context.d.ts +4 -4
- package/dist/libraries/trpc/context.js +1 -1
- package/dist/libraries/trpc/context.js.map +1 -1
- package/dist/libraries/trpc/index.js.map +1 -1
- package/dist/libraries/trpc/middlewares/auth.d.ts +1 -1
- package/dist/libraries/trpc/middlewares/auth.js +12 -13
- package/dist/libraries/trpc/middlewares/auth.js.map +1 -1
- package/dist/libraries/trpc/middlewares/cors.d.ts +12 -0
- package/dist/libraries/trpc/middlewares/cors.js +50 -0
- package/dist/libraries/trpc/middlewares/cors.js.map +1 -0
- package/dist/libraries/twilio/index.d.ts +1 -1
- package/dist/libraries/twilio/index.js +2 -3
- package/dist/libraries/twilio/index.js.map +1 -1
- package/dist/libraries/upload/index.js +3 -3
- package/dist/libraries/upload/index.js.map +1 -1
- package/dist/utilities/enum.js.map +1 -1
- package/dist/utilities/error-handler.js.map +1 -1
- package/dist/utilities/error-middleware.js.map +1 -1
- package/dist/utilities/pagination.d.ts +4 -4
- package/dist/utilities/pagination.js +3 -8
- package/dist/utilities/pagination.js.map +1 -1
- package/dist/utilities/transformers.d.ts +2 -2
- package/dist/utilities/transformers.js +6 -6
- package/dist/utilities/transformers.js.map +1 -1
- package/dist/utilities/validation/common-validation.js.map +1 -1
- package/dist/utilities/validation/global-validation.js.map +1 -1
- package/dist/utilities/validation/index.js.map +1 -1
- package/package.json +44 -41
|
@@ -9,12 +9,12 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.Marketing = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
14
|
const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
15
|
-
const shop_model_1 = require("./shop.model");
|
|
16
15
|
const enum_1 = require("../../../utilities/enum");
|
|
17
16
|
const duration_model_1 = require("./shared/duration.model");
|
|
17
|
+
const shop_model_1 = require("./shop.model");
|
|
18
18
|
let Marketing = class Marketing extends defaultClasses_1.TimeStamps {
|
|
19
19
|
shop;
|
|
20
20
|
marketingType;
|
|
@@ -41,7 +41,11 @@ __decorate([
|
|
|
41
41
|
__metadata("design:type", duration_model_1.Duration)
|
|
42
42
|
], Marketing.prototype, "duration", void 0);
|
|
43
43
|
__decorate([
|
|
44
|
-
(0, typegoose_1.prop)({
|
|
44
|
+
(0, typegoose_1.prop)({
|
|
45
|
+
type: String,
|
|
46
|
+
enum: enum_1.MarketingStatus,
|
|
47
|
+
default: enum_1.MarketingStatus.ACTIVE,
|
|
48
|
+
}),
|
|
45
49
|
__metadata("design:type", String)
|
|
46
50
|
], Marketing.prototype, "status", void 0);
|
|
47
51
|
__decorate([
|
|
@@ -49,7 +53,11 @@ __decorate([
|
|
|
49
53
|
__metadata("design:type", Object)
|
|
50
54
|
], Marketing.prototype, "pausedAt", void 0);
|
|
51
55
|
exports.Marketing = Marketing = __decorate([
|
|
52
|
-
(0, typegoose_1.modelOptions)({
|
|
56
|
+
(0, typegoose_1.modelOptions)({
|
|
57
|
+
schemaOptions: {
|
|
58
|
+
collection: 'marketings',
|
|
59
|
+
discriminatorKey: 'marketingType',
|
|
60
|
+
},
|
|
61
|
+
})
|
|
53
62
|
], Marketing);
|
|
54
|
-
exports.MarketingModel = (0, typegoose_1.getModelForClass)(Marketing);
|
|
55
63
|
//# sourceMappingURL=marketing.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"marketing.model.js","sourceRoot":"/","sources":["libraries/mongo/models/marketing.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"marketing.model.js","sourceRoot":"/","sources":["libraries/mongo/models/marketing.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA+D;AAC/D,4EAAqE;AACrE,kDAAyE;AACzE,4DAAmD;AACnD,6CAAoC;AAQ7B,IAAM,SAAS,GAAf,MAAM,SAAU,SAAQ,2BAAU;IAEjC,IAAI,CAAa;IAGjB,aAAa,CAAiB;IAG9B,gBAAgB,CAAW;IAG3B,QAAQ,CAAY;IAOpB,MAAM,CAAmB;IAGzB,QAAQ,CAAe;CAC9B,CAAA;AAtBY,8BAAS;AAEd;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,iBAAI,EAAE,CAAC;;uCAClB;AAGjB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,oBAAa,EAAE,CAAC;;gDACvB;AAG9B;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;;mDACN;AAG3B;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,yBAAQ,EAAE,CAAC;8BACvB,yBAAQ;2CAAC;AAOpB;IALN,IAAA,gBAAI,EAAC;QACL,IAAI,EAAE,MAAM;QACZ,IAAI,EAAE,sBAAe;QACrB,OAAO,EAAE,sBAAe,CAAC,MAAM;KAC/B,CAAC;;yCAC8B;AAGzB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;;2CACN;oBArBlB,SAAS;IANrB,IAAA,wBAAY,EAAC;QACb,aAAa,EAAE;YACd,UAAU,EAAE,YAAY;YACxB,gBAAgB,EAAE,eAAe;SACjC;KACD,CAAC;GACW,SAAS,CAsBrB","sourcesContent":["import { modelOptions, prop, Ref } from '@typegoose/typegoose';\r\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\r\nimport { MarketingStatus, MarketingType } from '../../../utilities/enum';\r\nimport { Duration } from './shared/duration.model';\r\nimport { Shop } from './shop.model';\r\n\r\n@modelOptions({\r\n\tschemaOptions: {\r\n\t\tcollection: 'marketings',\r\n\t\tdiscriminatorKey: 'marketingType',\r\n\t},\r\n})\r\nexport class Marketing extends TimeStamps {\r\n\t@prop({ required: true, ref: () => Shop })\r\n\tpublic shop!: Ref<Shop>;\r\n\r\n\t@prop({ required: true, type: String, enum: MarketingType })\r\n\tpublic marketingType!: MarketingType;\r\n\r\n\t@prop({ required: true, type: Boolean })\r\n\tpublic isAppliedByAdmin!: boolean;\r\n\r\n\t@prop({ required: true, type: Duration })\r\n\tpublic duration!: Duration;\r\n\r\n\t@prop({\r\n\t\ttype: String,\r\n\t\tenum: MarketingStatus,\r\n\t\tdefault: MarketingStatus.ACTIVE,\r\n\t})\r\n\tpublic status?: MarketingStatus;\r\n\r\n\t@prop({ type: Date, default: null })\r\n\tpublic pausedAt?: Date | null;\r\n}\r\n"]}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { ReturnModelType } from '@typegoose/typegoose';
|
|
2
1
|
import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
|
|
3
2
|
export declare class MealPlan extends TimeStamps {
|
|
4
3
|
name: string;
|
|
@@ -8,4 +7,3 @@ export declare class MealPlan extends TimeStamps {
|
|
|
8
7
|
suitedFor?: string[];
|
|
9
8
|
dietContains?: string[];
|
|
10
9
|
}
|
|
11
|
-
export declare const MealPlanModel: ReturnModelType<typeof MealPlan>;
|
|
@@ -9,7 +9,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.MealPlan = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
14
|
const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
15
15
|
let MealPlan = class MealPlan extends defaultClasses_1.TimeStamps {
|
|
@@ -48,5 +48,4 @@ __decorate([
|
|
|
48
48
|
exports.MealPlan = MealPlan = __decorate([
|
|
49
49
|
(0, typegoose_1.modelOptions)({ schemaOptions: { collection: 'mealPlans' } })
|
|
50
50
|
], MealPlan);
|
|
51
|
-
exports.MealPlanModel = (0, typegoose_1.getModelForClass)(MealPlan);
|
|
52
51
|
//# sourceMappingURL=meal-plan.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"meal-plan.model.js","sourceRoot":"/","sources":["libraries/mongo/models/meal-plan.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"meal-plan.model.js","sourceRoot":"/","sources":["libraries/mongo/models/meal-plan.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA0D;AAC1D,4EAAqE;AAG9D,IAAM,QAAQ,GAAd,MAAM,QAAS,SAAQ,2BAAU;IAEhC,IAAI,CAAU;IAGd,KAAK,CAAU;IAGf,gBAAgB,CAAU;IAG1B,eAAe,CAAU;IAGzB,SAAS,CAAY;IAGrB,YAAY,CAAY;CAC/B,CAAA;AAlBY,4BAAQ;AAEb;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;sCAClB;AAGd;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;uCACjB;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;kDACN;AAG1B;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;iDACP;AAGzB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;2CAChB;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;8CACb;mBAjBnB,QAAQ;IADpB,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,WAAW,EAAE,EAAE,CAAC;GAChD,QAAQ,CAkBpB","sourcesContent":["import { modelOptions, prop } from '@typegoose/typegoose';\r\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\r\n\r\n@modelOptions({ schemaOptions: { collection: 'mealPlans' } })\r\nexport class MealPlan extends TimeStamps {\r\n\t@prop({ required: true, type: String })\r\n\tpublic name!: string;\r\n\r\n\t@prop({ required: true, type: String })\r\n\tpublic image!: string;\r\n\r\n\t@prop({ required: true, type: String })\r\n\tpublic shortDescription!: string;\r\n\r\n\t@prop({ required: true, type: String })\r\n\tpublic fullDescription!: string;\r\n\r\n\t@prop({ type: () => [String], default: [] })\r\n\tpublic suitedFor?: string[];\r\n\r\n\t@prop({ type: () => [String], default: [] })\r\n\tpublic dietContains?: string[];\r\n}\r\n"]}
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { mongoose, Ref
|
|
1
|
+
import { mongoose, Ref } from '@typegoose/typegoose';
|
|
2
2
|
import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
|
|
3
3
|
import { ClickType, NotificationAccountType } from '../../../utilities/enum';
|
|
4
|
-
import { CoreUser } from './core-user.model';
|
|
5
|
-
import { Parent } from './parent.model';
|
|
6
|
-
import { Shop } from './shop.model';
|
|
7
4
|
import { Admin } from './admin.model';
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import { Order } from './order.model';
|
|
5
|
+
import { BOBFinance } from './bob-finance.model';
|
|
6
|
+
import { CoreUser } from './core-user.model';
|
|
11
7
|
import { ListContainer } from './list-container.model';
|
|
8
|
+
import { Order } from './order.model';
|
|
9
|
+
import { Parent } from './parent.model';
|
|
12
10
|
import { Payout } from './payout.model';
|
|
13
|
-
import {
|
|
11
|
+
import { Product } from './product.model';
|
|
14
12
|
import { RequestArea } from './request-area.model';
|
|
13
|
+
import { Rider } from './rider.model';
|
|
14
|
+
import { Shop } from './shop.model';
|
|
15
15
|
export declare class Notification extends TimeStamps {
|
|
16
16
|
title: string;
|
|
17
17
|
body: string;
|
|
@@ -37,4 +37,3 @@ export declare class Notification extends TimeStamps {
|
|
|
37
37
|
isSendByAdmin?: boolean;
|
|
38
38
|
seenBy?: mongoose.Types.ObjectId[];
|
|
39
39
|
}
|
|
40
|
-
export declare const NotificationModel: ReturnModelType<typeof Notification>;
|
|
@@ -9,21 +9,21 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.Notification = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
14
|
const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
15
15
|
const enum_1 = require("../../../utilities/enum");
|
|
16
|
-
const core_user_model_1 = require("./core-user.model");
|
|
17
|
-
const parent_model_1 = require("./parent.model");
|
|
18
|
-
const shop_model_1 = require("./shop.model");
|
|
19
16
|
const admin_model_1 = require("./admin.model");
|
|
20
|
-
const
|
|
21
|
-
const
|
|
22
|
-
const order_model_1 = require("./order.model");
|
|
17
|
+
const bob_finance_model_1 = require("./bob-finance.model");
|
|
18
|
+
const core_user_model_1 = require("./core-user.model");
|
|
23
19
|
const list_container_model_1 = require("./list-container.model");
|
|
20
|
+
const order_model_1 = require("./order.model");
|
|
21
|
+
const parent_model_1 = require("./parent.model");
|
|
24
22
|
const payout_model_1 = require("./payout.model");
|
|
25
|
-
const
|
|
23
|
+
const product_model_1 = require("./product.model");
|
|
26
24
|
const request_area_model_1 = require("./request-area.model");
|
|
25
|
+
const rider_model_1 = require("./rider.model");
|
|
26
|
+
const shop_model_1 = require("./shop.model");
|
|
27
27
|
let Notification = class Notification extends defaultClasses_1.TimeStamps {
|
|
28
28
|
title;
|
|
29
29
|
body;
|
|
@@ -151,5 +151,4 @@ exports.Notification = Notification = __decorate([
|
|
|
151
151
|
(0, typegoose_1.index)({ parents: 1, accountType: 1, createdAt: 1 }),
|
|
152
152
|
(0, typegoose_1.index)({ accountType: 1, type: 1, createdAt: 1 })
|
|
153
153
|
], Notification);
|
|
154
|
-
exports.NotificationModel = (0, typegoose_1.getModelForClass)(Notification);
|
|
155
154
|
//# sourceMappingURL=notification.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"notification.model.js","sourceRoot":"/","sources":["libraries/mongo/models/notification.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"notification.model.js","sourceRoot":"/","sources":["libraries/mongo/models/notification.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAgF;AAChF,4EAAqE;AACrE,kDAA6E;AAC7E,+CAAsC;AACtC,2DAAiD;AACjD,uDAA6C;AAC7C,iEAAuD;AACvD,+CAAsC;AACtC,iDAAwC;AACxC,iDAAwC;AACxC,mDAA0C;AAC1C,6DAAmD;AACnD,+CAAsC;AACtC,6CAAoC;AAS7B,IAAM,YAAY,GAAlB,MAAM,YAAa,SAAQ,2BAAU;IAEpC,KAAK,CAAU;IAGf,IAAI,CA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/defaultClasses';\r\nimport { ClickType, NotificationAccountType } from '../../../utilities/enum';\r\nimport { Admin } from './admin.model';\r\nimport { BOBFinance } from './bob-finance.model';\r\nimport { CoreUser } from './core-user.model';\r\nimport { ListContainer } from './list-container.model';\r\nimport { Order } from './order.model';\r\nimport { Parent } from './parent.model';\r\nimport { Payout } from './payout.model';\r\nimport { Product } from './product.model';\r\nimport { RequestArea } from './request-area.model';\r\nimport { Rider } from './rider.model';\r\nimport { Shop } from './shop.model';\r\n\r\n@modelOptions({ schemaOptions: { collection: 'notifications' } })\r\n@index({ users: 1, accountType: 1, createdAt: 1 })\r\n@index({ shops: 1, accountType: 1, createdAt: 1 })\r\n@index({ riders: 1, accountType: 1, createdAt: 1 })\r\n@index({ admins: 1, accountType: 1, createdAt: 1 })\r\n@index({ parents: 1, accountType: 1, createdAt: 1 })\r\n@index({ accountType: 1, type: 1, createdAt: 1 })\r\nexport class Notification extends TimeStamps {\r\n\t@prop({ required: true, type: String })\r\n\tpublic title!: string;\r\n\r\n\t@prop({ required: true, type: String })\r\n\tpublic body!: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic image?: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic sound?: string;\r\n\r\n\t@prop({ required: true, type: String, enum: NotificationAccountType })\r\n\tpublic accountType!: NotificationAccountType;\r\n\r\n\t@prop({ type: Boolean, default: false })\r\n\tpublic isGlobal?: boolean;\r\n\r\n\t@prop({ ref: () => CoreUser, default: [] })\r\n\tpublic users?: Ref<CoreUser>[];\r\n\r\n\t@prop({ ref: () => Parent, default: [] })\r\n\tpublic parents?: Ref<Parent>[];\r\n\r\n\t@prop({ ref: () => Shop, default: [] })\r\n\tpublic shops?: Ref<Shop>[];\r\n\r\n\t@prop({ ref: () => Rider, default: [] })\r\n\tpublic riders?: Ref<Rider>[];\r\n\r\n\t@prop({ ref: () => Admin, default: [] })\r\n\tpublic admins?: Ref<Admin>[];\r\n\r\n\t@prop({ type: Boolean, default: false })\r\n\tpublic isClickable?: boolean;\r\n\r\n\t@prop({ type: String, enum: ClickType })\r\n\tpublic clickType?: ClickType;\r\n\r\n\t@prop({ type: String, trim: true })\r\n\tpublic clickableUrl?: string;\r\n\r\n\t@prop({ ref: () => Order })\r\n\tpublic clickableOrder?: Ref<Order>;\r\n\r\n\t@prop({ ref: () => Shop })\r\n\tpublic clickableShop?: Ref<Shop>;\r\n\r\n\t@prop({ ref: () => Product })\r\n\tpublic clickableProduct?: Ref<Product>;\r\n\r\n\t@prop({ ref: () => ListContainer })\r\n\tpublic clickableListContainer?: Ref<ListContainer>;\r\n\r\n\t@prop({ ref: () => Payout })\r\n\tpublic clickablePayout?: Ref<Payout>;\r\n\r\n\t@prop({ ref: () => BOBFinance })\r\n\tpublic clickableBOBFinance?: Ref<BOBFinance>;\r\n\r\n\t@prop({ ref: () => RequestArea })\r\n\tpublic clickableRequestArea?: Ref<RequestArea>;\r\n\r\n\t@prop({ type: Boolean, default: false })\r\n\tpublic isSendByAdmin?: boolean;\r\n\r\n\t@prop({ type: () => [mongoose.Types.ObjectId], default: [] })\r\n\tpublic seenBy?: mongoose.Types.ObjectId[];\r\n}\r\n"]}
|
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
import { ReturnModelType } from '@typegoose/typegoose';
|
|
2
1
|
import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
|
|
3
2
|
import { Status } from '../../../utilities/enum';
|
|
4
3
|
export declare class Nutrition extends TimeStamps {
|
|
5
4
|
name: string;
|
|
6
5
|
status?: Status;
|
|
7
6
|
}
|
|
8
|
-
export declare const NutritionModel: ReturnModelType<typeof Nutrition>;
|
|
@@ -9,7 +9,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.Nutrition = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
14
|
const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
15
15
|
const enum_1 = require("../../../utilities/enum");
|
|
@@ -29,5 +29,4 @@ __decorate([
|
|
|
29
29
|
exports.Nutrition = Nutrition = __decorate([
|
|
30
30
|
(0, typegoose_1.modelOptions)({ schemaOptions: { collection: 'nutritions' } })
|
|
31
31
|
], Nutrition);
|
|
32
|
-
exports.NutritionModel = (0, typegoose_1.getModelForClass)(Nutrition);
|
|
33
32
|
//# sourceMappingURL=nutrition.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nutrition.model.js","sourceRoot":"/","sources":["libraries/mongo/models/nutrition.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"nutrition.model.js","sourceRoot":"/","sources":["libraries/mongo/models/nutrition.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA0D;AAC1D,4EAAqE;AACrE,kDAAiD;AAG1C,IAAM,SAAS,GAAf,MAAM,SAAU,SAAQ,2BAAU;IAEjC,IAAI,CAAU;IAGd,MAAM,CAAU;CACvB,CAAA;AANY,8BAAS;AAEd;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;uCAClB;AAGd;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,aAAM,EAAE,OAAO,EAAE,aAAM,CAAC,MAAM,EAAE,CAAC;;yCACtC;oBALX,SAAS;IADrB,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,YAAY,EAAE,EAAE,CAAC;GACjD,SAAS,CAMrB","sourcesContent":["import { modelOptions, prop } from '@typegoose/typegoose';\r\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\r\nimport { Status } from '../../../utilities/enum';\r\n\r\n@modelOptions({ schemaOptions: { collection: 'nutritions' } })\r\nexport class Nutrition extends TimeStamps {\r\n\t@prop({ required: true, type: String })\r\n\tpublic name!: string;\r\n\r\n\t@prop({ type: String, enum: Status, default: Status.ACTIVE })\r\n\tpublic status?: Status;\r\n}\r\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"order.model.js","sourceRoot":"/","sources":["libraries/mongo/models/order.model.ts"],"names":[],"mappings":";;;AAAA,MAAa,KAAK;CAAG;AAArB,sBAAqB","sourcesContent":["export class Order {}\
|
|
1
|
+
{"version":3,"file":"order.model.js","sourceRoot":"/","sources":["libraries/mongo/models/order.model.ts"],"names":[],"mappings":";;;AAAA,MAAa,KAAK;CAAG;AAArB,sBAAqB","sourcesContent":["export class Order {}\n"]}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ref } from '@typegoose/typegoose';
|
|
2
2
|
import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
|
|
3
|
-
import { Address } from './shared/address.model';
|
|
4
3
|
import { ChargeType, ItemType, Status } from '../../../utilities/enum';
|
|
5
|
-
import { Charge } from './embedded/charge.model';
|
|
6
4
|
import { Admin } from './admin.model';
|
|
5
|
+
import { Charge } from './embedded/charge.model';
|
|
7
6
|
import { ParentDocument } from './embedded/parent-document.model';
|
|
7
|
+
import { Address } from './shared/address.model';
|
|
8
8
|
export declare class Parent extends TimeStamps {
|
|
9
9
|
name: string;
|
|
10
10
|
phoneNumber: string;
|
|
@@ -18,4 +18,3 @@ export declare class Parent extends TimeStamps {
|
|
|
18
18
|
profilePhoto: string;
|
|
19
19
|
document: ParentDocument;
|
|
20
20
|
}
|
|
21
|
-
export declare const ParentModel: ReturnModelType<typeof Parent>;
|
|
@@ -9,14 +9,14 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.Parent = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
14
|
const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
15
|
-
const address_model_1 = require("./shared/address.model");
|
|
16
15
|
const enum_1 = require("../../../utilities/enum");
|
|
17
|
-
const charge_model_1 = require("./embedded/charge.model");
|
|
18
16
|
const admin_model_1 = require("./admin.model");
|
|
17
|
+
const charge_model_1 = require("./embedded/charge.model");
|
|
19
18
|
const parent_document_model_1 = require("./embedded/parent-document.model");
|
|
19
|
+
const address_model_1 = require("./shared/address.model");
|
|
20
20
|
let Parent = class Parent extends defaultClasses_1.TimeStamps {
|
|
21
21
|
name;
|
|
22
22
|
phoneNumber;
|
|
@@ -76,8 +76,11 @@ __decorate([
|
|
|
76
76
|
__metadata("design:type", parent_document_model_1.ParentDocument)
|
|
77
77
|
], Parent.prototype, "document", void 0);
|
|
78
78
|
exports.Parent = Parent = __decorate([
|
|
79
|
-
(0, typegoose_1.index)({ companyName: 1, itemType: 1 }, {
|
|
79
|
+
(0, typegoose_1.index)({ companyName: 1, itemType: 1 }, {
|
|
80
|
+
unique: true,
|
|
81
|
+
partialFilterExpression: { deletedAt: null },
|
|
82
|
+
name: 'companyName_itemType_unique',
|
|
83
|
+
}),
|
|
80
84
|
(0, typegoose_1.modelOptions)({ schemaOptions: { collection: 'parents' } })
|
|
81
85
|
], Parent);
|
|
82
|
-
exports.ParentModel = (0, typegoose_1.getModelForClass)(Parent);
|
|
83
86
|
//# sourceMappingURL=parent.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parent.model.js","sourceRoot":"/","sources":["libraries/mongo/models/parent.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"parent.model.js","sourceRoot":"/","sources":["libraries/mongo/models/parent.model.ts"],"names":[],"mappings":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E,GAAG,EAAE,GAAG,EAAE,CAAC,mBAAK,EAAE,CAAC;;oDACc;AAGlC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,aAAM,EAAE,OAAO,EAAE,aAAM,CAAC,MAAM,EAAE,CAAC;;sCACtC;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;4CACV;AAGtB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,sCAAc,EAAE,CAAC;8BAC7B,sCAAc;wCAAC;iBAhCrB,MAAM;IATlB,IAAA,iBAAK,EACL,EAAE,WAAW,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,EAC/B;QACC,MAAM,EAAE,IAAI;QACZ,uBAAuB,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE;QAC5C,IAAI,EAAE,6BAA6B;KACnC,CACD;IACA,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,SAAS,EAAE,EAAE,CAAC;GAC9C,MAAM,CAiClB","sourcesContent":["import { index, modelOptions, prop, Ref } from '@typegoose/typegoose';\r\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\r\nimport { ChargeType, ItemType, Status } from '../../../utilities/enum';\r\nimport { Admin } from './admin.model';\r\nimport { Charge } from './embedded/charge.model';\r\nimport { ParentDocument } from './embedded/parent-document.model';\r\nimport { Address } from './shared/address.model';\r\n\r\n@index(\r\n\t{ companyName: 1, itemType: 1 },\r\n\t{\r\n\t\tunique: true,\r\n\t\tpartialFilterExpression: { deletedAt: null },\r\n\t\tname: 'companyName_itemType_unique',\r\n\t}\r\n)\r\n@modelOptions({ schemaOptions: { collection: 'parents' } })\r\nexport class Parent extends TimeStamps {\r\n\t@prop({ required: true, type: String })\r\n\tpublic name!: string;\r\n\r\n\t@prop({ required: true, type: String })\r\n\tpublic phoneNumber!: string;\r\n\r\n\t@prop({ required: true, type: Address })\r\n\tpublic address!: Address;\r\n\r\n\t@prop({ required: true, type: String, enum: ChargeType })\r\n\tpublic chargeType!: ChargeType;\r\n\r\n\t@prop({ type: Charge })\r\n\tpublic charge?: Charge;\r\n\r\n\t@prop({ required: true, type: String, enum: ItemType })\r\n\tpublic itemType!: ItemType;\r\n\r\n\t@prop({ required: true, type: Boolean, default: true })\r\n\tpublic isServiceFeeCharged!: boolean;\r\n\r\n\t@prop({ ref: () => Admin })\r\n\tpublic businessDevExecutive?: Ref<Admin>;\r\n\r\n\t@prop({ type: String, enum: Status, default: Status.ACTIVE })\r\n\tpublic status?: Status;\r\n\r\n\t@prop({ required: true, type: String })\r\n\tpublic profilePhoto!: string;\r\n\r\n\t@prop({ required: true, type: ParentDocument })\r\n\tpublic document!: ParentDocument;\r\n}\r\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"payout.model.js","sourceRoot":"/","sources":["libraries/mongo/models/payout.model.ts"],"names":[],"mappings":";;;AAAA,MAAa,MAAM;CAAG;AAAtB,wBAAsB","sourcesContent":["export class Payout {}\
|
|
1
|
+
{"version":3,"file":"payout.model.js","sourceRoot":"/","sources":["libraries/mongo/models/payout.model.ts"],"names":[],"mappings":";;;AAAA,MAAa,MAAM;CAAG;AAAtB,wBAAsB","sourcesContent":["export class Payout {}\n"]}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Ref
|
|
2
|
-
import { Product } from './product.model';
|
|
3
|
-
import { Marketing } from './marketing.model';
|
|
1
|
+
import { Ref } from '@typegoose/typegoose';
|
|
4
2
|
import { ValueType } from '../../../utilities/enum';
|
|
5
3
|
import { LoyaltyPointCategory } from './loyalty-point-category.model';
|
|
4
|
+
import { Marketing } from './marketing.model';
|
|
5
|
+
import { Product } from './product.model';
|
|
6
6
|
export declare class ProductMarketing {
|
|
7
7
|
product: Ref<Product>;
|
|
8
8
|
marketing: Ref<Marketing>;
|
|
@@ -10,4 +10,3 @@ export declare class ProductMarketing {
|
|
|
10
10
|
valueType?: ValueType;
|
|
11
11
|
value: number;
|
|
12
12
|
}
|
|
13
|
-
export declare const ProductMarketingModel: ReturnModelType<typeof ProductMarketing>;
|
|
@@ -9,12 +9,12 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.ProductMarketing = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
|
-
const product_model_1 = require("./product.model");
|
|
15
|
-
const marketing_model_1 = require("./marketing.model");
|
|
16
14
|
const enum_1 = require("../../../utilities/enum");
|
|
17
15
|
const loyalty_point_category_model_1 = require("./loyalty-point-category.model");
|
|
16
|
+
const marketing_model_1 = require("./marketing.model");
|
|
17
|
+
const product_model_1 = require("./product.model");
|
|
18
18
|
let ProductMarketing = class ProductMarketing {
|
|
19
19
|
product;
|
|
20
20
|
marketing;
|
|
@@ -46,5 +46,4 @@ __decorate([
|
|
|
46
46
|
exports.ProductMarketing = ProductMarketing = __decorate([
|
|
47
47
|
(0, typegoose_1.modelOptions)({ schemaOptions: { collection: 'productMarketings' } })
|
|
48
48
|
], ProductMarketing);
|
|
49
|
-
exports.ProductMarketingModel = (0, typegoose_1.getModelForClass)(ProductMarketing);
|
|
50
49
|
//# sourceMappingURL=product-marketing.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"product-marketing.model.js","sourceRoot":"/","sources":["libraries/mongo/models/product-marketing.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"product-marketing.model.js","sourceRoot":"/","sources":["libraries/mongo/models/product-marketing.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA+D;AAC/D,kDAAoD;AACpD,iFAAsE;AACtE,uDAA8C;AAC9C,mDAA0C;AAGnC,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;IAErB,OAAO,CAAgB;IAGvB,SAAS,CAAkB;IAG3B,oBAAoB,CAA6B;IAGjD,SAAS,CAAa;IAGtB,KAAK,CAAU;CACtB,CAAA;AAfY,4CAAgB;AAErB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,uBAAO,EAAE,CAAC;;iDACf;AAGvB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,2BAAS,EAAE,CAAC;;mDACb;AAG3B;IADN,IAAA,gBAAI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,mDAAoB,EAAE,CAAC;;8DACc;AAGjD;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,gBAAS,EAAE,OAAO,EAAE,gBAAS,CAAC,UAAU,EAAE,CAAC;;mDAC1C;AAGtB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;+CACjB;2BAdV,gBAAgB;IAD5B,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,mBAAmB,EAAE,EAAE,CAAC;GACxD,gBAAgB,CAe5B","sourcesContent":["import { modelOptions, prop, Ref } from '@typegoose/typegoose';\r\nimport { ValueType } from '../../../utilities/enum';\r\nimport { LoyaltyPointCategory } from './loyalty-point-category.model';\r\nimport { Marketing } from './marketing.model';\r\nimport { Product } from './product.model';\r\n\r\n@modelOptions({ schemaOptions: { collection: 'productMarketings' } })\r\nexport class ProductMarketing {\r\n\t@prop({ required: true, ref: () => Product })\r\n\tpublic product!: Ref<Product>;\r\n\r\n\t@prop({ required: true, ref: () => Marketing })\r\n\tpublic marketing!: Ref<Marketing>;\r\n\r\n\t@prop({ ref: () => LoyaltyPointCategory }) // this field only for loyalty marketing\r\n\tpublic loyaltyPointCategory?: Ref<LoyaltyPointCategory>;\r\n\r\n\t@prop({ type: String, enum: ValueType, default: ValueType.PERCENTAGE })\r\n\tpublic valueType?: ValueType;\r\n\r\n\t@prop({ required: true, type: Number })\r\n\tpublic value!: number;\r\n}\r\n"]}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { ReturnModelType } from '@typegoose/typegoose';
|
|
2
1
|
import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
|
|
3
|
-
import { ProductNutrition } from './embedded/product-nutrition.model';
|
|
4
2
|
import { FoodGroup, ItemType, ProductDietaryType, Status } from '../../../utilities/enum';
|
|
3
|
+
import { ProductNutrition } from './embedded/product-nutrition.model';
|
|
5
4
|
export declare class Product extends TimeStamps {
|
|
6
5
|
name: string;
|
|
7
6
|
barcode?: string;
|
|
@@ -18,4 +17,3 @@ export declare class Product extends TimeStamps {
|
|
|
18
17
|
storingTemperature?: number;
|
|
19
18
|
storingTemperatureUnit?: string;
|
|
20
19
|
}
|
|
21
|
-
export declare const ProductModel: ReturnModelType<typeof Product>;
|
|
@@ -9,11 +9,11 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.Product = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
14
|
const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
15
|
-
const product_nutrition_model_1 = require("./embedded/product-nutrition.model");
|
|
16
15
|
const enum_1 = require("../../../utilities/enum");
|
|
16
|
+
const product_nutrition_model_1 = require("./embedded/product-nutrition.model");
|
|
17
17
|
let Product = class Product extends defaultClasses_1.TimeStamps {
|
|
18
18
|
name;
|
|
19
19
|
barcode;
|
|
@@ -89,7 +89,11 @@ __decorate([
|
|
|
89
89
|
], Product.prototype, "storingTemperatureUnit", void 0);
|
|
90
90
|
exports.Product = Product = __decorate([
|
|
91
91
|
(0, typegoose_1.modelOptions)({ schemaOptions: { collection: 'products' } }),
|
|
92
|
-
(0, typegoose_1.Index)({ name: 1, itemType: 1 }, {
|
|
92
|
+
(0, typegoose_1.Index)({ name: 1, itemType: 1 }, {
|
|
93
|
+
unique: true,
|
|
94
|
+
partialFilterExpression: {
|
|
95
|
+
itemType: { $in: [enum_1.ItemType.GROCERY, enum_1.ItemType.PHARMACY] },
|
|
96
|
+
},
|
|
97
|
+
})
|
|
93
98
|
], Product);
|
|
94
|
-
exports.ProductModel = (0, typegoose_1.getModelForClass)(Product);
|
|
95
99
|
//# sourceMappingURL=product.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"product.model.js","sourceRoot":"/","sources":["libraries/mongo/models/product.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"product.model.js","sourceRoot":"/","sources":["libraries/mongo/models/product.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiE;AACjE,4EAAqE;AACrE,kDAA0F;AAC1F,gFAAsE;AAY/D,IAAM,OAAO,GAAb,MAAM,OAAQ,SAAQ,2BAAU;IAE/B,IAAI,CAAU;IAGd,OAAO,CAAU;IAGjB,QAAQ,CAAY;IAGpB,SAAS,CAAa;IAGtB,MAAM,CAAY;IAGlB,MAAM,CAAU;IAGhB,oBAAoB,CAAU;IAG9B,oBAAoB,CAAU;IAG9B,gBAAgB,CAAU;IAG1B,iBAAiB,CAAU;IAG3B,UAAU,CAAsB;IAGhC,YAAY,CAAwB;IAGpC,kBAAkB,CAAU;IAG5B,sBAAsB,CAAU;CACvC,CAAA;AA1CY,0BAAO;AAEZ;IADN,IAAA,gBAAI,EAAC,EAAE,QAA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AAGpC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;mDACY;AAG5B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;uDACgB;kBAzC3B,OAAO;IAVnB,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,UAAU,EAAE,EAAE,CAAC;IAC3D,IAAA,iBAAK,EACL,EAAE,IAAI,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,EACxB;QACC,MAAM,EAAE,IAAI;QACZ,uBAAuB,EAAE;YACxB,QAAQ,EAAE,EAAE,GAAG,EAAE,CAAC,eAAQ,CAAC,OAAO,EAAE,eAAQ,CAAC,QAAQ,CAAC,EAAE;SACxD;KACD,CACD;GACY,OAAO,CA0CnB","sourcesContent":["import { Index, modelOptions, prop } from '@typegoose/typegoose';\r\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\r\nimport { FoodGroup, ItemType, ProductDietaryType, Status } from '../../../utilities/enum';\r\nimport { ProductNutrition } from './embedded/product-nutrition.model';\r\n\r\n@modelOptions({ schemaOptions: { collection: 'products' } })\r\n@Index(\r\n\t{ name: 1, itemType: 1 },\r\n\t{\r\n\t\tunique: true,\r\n\t\tpartialFilterExpression: {\r\n\t\t\titemType: { $in: [ItemType.GROCERY, ItemType.PHARMACY] },\r\n\t\t},\r\n\t}\r\n)\r\nexport class Product extends TimeStamps {\r\n\t@prop({ required: true, type: String })\r\n\tpublic name!: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic barcode?: string;\r\n\r\n\t@prop({ required: true, type: String, enum: ItemType })\r\n\tpublic itemType!: ItemType;\r\n\r\n\t@prop({ type: String, enum: FoodGroup })\r\n\tpublic foodGroup?: FoodGroup;\r\n\r\n\t@prop({ required: true, type: [String] })\r\n\tpublic images!: string[];\r\n\r\n\t@prop({ type: String, enum: Status, default: Status.ACTIVE })\r\n\tpublic status?: Status;\r\n\r\n\t@prop({ type: Number, min: 0 })\r\n\tpublic nutritionServingSize?: number;\r\n\r\n\t@prop({ type: String })\r\n\tpublic nutritionServingUnit?: string;\r\n\r\n\t@prop({ type: Number, min: 0 })\r\n\tpublic nutritionPerUnit?: number;\r\n\r\n\t@prop({ type: Number, min: 0 })\r\n\tpublic nutritionCalories?: number;\r\n\r\n\t@prop({ type: [ProductNutrition], default: [] })\r\n\tpublic nutritions?: ProductNutrition[];\r\n\r\n\t@prop({ type: [String], enum: ProductDietaryType, default: [] })\r\n\tpublic dietaryTypes?: ProductDietaryType[];\r\n\r\n\t@prop({ type: Number })\r\n\tpublic storingTemperature?: number;\r\n\r\n\t@prop({ type: String })\r\n\tpublic storingTemperatureUnit?: string;\r\n}\r\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Ref
|
|
1
|
+
import { Ref } from '@typegoose/typegoose';
|
|
2
2
|
import { MarketingType } from '../../../../utilities/enum';
|
|
3
3
|
import { Marketing } from '../marketing.model';
|
|
4
4
|
import { Product } from '../product.model';
|
|
@@ -9,4 +9,3 @@ export declare class Buy1Get1Marketing extends Marketing {
|
|
|
9
9
|
spendLimit?: number;
|
|
10
10
|
isOnlyForSubscriber?: boolean;
|
|
11
11
|
}
|
|
12
|
-
export declare const Buy1Get1MarketingModel: ReturnModelType<typeof Buy1Get1Marketing>;
|
|
@@ -9,7 +9,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.Buy1Get1Marketing = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
14
|
const enum_1 = require("../../../../utilities/enum");
|
|
15
15
|
const marketing_model_1 = require("../marketing.model");
|
|
@@ -38,5 +38,4 @@ __decorate([
|
|
|
38
38
|
(0, typegoose_1.prop)({ type: Boolean, default: false }),
|
|
39
39
|
__metadata("design:type", Boolean)
|
|
40
40
|
], Buy1Get1Marketing.prototype, "isOnlyForSubscriber", void 0);
|
|
41
|
-
exports.Buy1Get1MarketingModel = (0, typegoose_1.getDiscriminatorModelForClass)(marketing_model_1.MarketingModel, Buy1Get1Marketing, enum_1.MarketingType.BUY1GET1);
|
|
42
41
|
//# sourceMappingURL=buy1-get1-marketing.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"buy1-get1-marketing.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/buy1-get1-marketing.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"buy1-get1-marketing.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/buy1-get1-marketing.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiD;AACjD,qDAA2D;AAC3D,wDAA+C;AAC/C,oDAA2C;AAE3C,MAAa,iBAAkB,SAAQ,2BAAS;IACxC,aAAa,GAAG,oBAAa,CAAC,QAAiB,CAAC;IAGhD,YAAY,CAAW;IAGvB,QAAQ,CAAkB;IAG1B,UAAU,CAAU;IAGpB,mBAAmB,CAAW;CACrC;AAdD,8CAcC;AAVO;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;;uDACV;AAGvB;IADN,IAAA,gBAAI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,uBAAO,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;mDACT;AAG1B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;;qDACR;AAGpB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;;8DACH","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\r\nimport { MarketingType } from '../../../../utilities/enum';\r\nimport { Marketing } from '../marketing.model';\r\nimport { Product } from '../product.model';\r\n\r\nexport class Buy1Get1Marketing extends Marketing {\r\n\tpublic marketingType = MarketingType.BUY1GET1 as const;\r\n\r\n\t@prop({ type: Boolean, default: false })\r\n\tpublic isEntireMenu?: boolean;\r\n\r\n\t@prop({ ref: () => Product, default: [] })\r\n\tpublic products?: Ref<Product>[];\r\n\r\n\t@prop({ type: Number, default: 0 })\r\n\tpublic spendLimit?: number;\r\n\r\n\t@prop({ type: Boolean, default: false })\r\n\tpublic isOnlyForSubscriber?: boolean;\r\n}\r\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core-apple-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-apple-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,KAAK,CAAU;CACtB;AAHD,sDAGC;AADO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACjB;AAGV,QAAA,0BAA0B,GACtC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,qBAAqB,EAAE,2BAAoB,CAAC,KAAK,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\
|
|
1
|
+
{"version":3,"file":"core-apple-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-apple-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,KAAK,CAAU;CACtB;AAHD,sDAGC;AADO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACjB;AAGV,QAAA,0BAA0B,GACtC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,qBAAqB,EAAE,2BAAoB,CAAC,KAAK,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\nimport { CoreAuthIdentity, CoreAuthIdentityModel } from '../core-auth-identity.model';\nimport { CoreAuthIdentityType } from '../../../../utilities/enum';\nimport { createGlobalDiscriminatorModel } from '../../../mongo';\n\nexport class CoreAppleAuthIdentity extends CoreAuthIdentity {\n\t@prop({ required: true, type: String })\n\tpublic token!: string;\n}\n\nexport const CoreAppleAuthIdentityModel: ReturnModelType<typeof CoreAppleAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreAppleAuthIdentity, CoreAuthIdentityType.APPLE);\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core-email-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-email-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,mEAAyD;AACzD,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,KAAK,CAAU;IAGf,QAAQ,CAAU;IAGlB,GAAG,CAAa;CACvB;AATD,sDASC;AAPO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACjB;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;uDACd;AAGlB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,4BAAS,EAAE,CAAC;8BAC7B,4BAAS;kDAAC;AAGX,QAAA,0BAA0B,GACtC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,qBAAqB,EAAE,2BAAoB,CAAC,KAAK,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\
|
|
1
|
+
{"version":3,"file":"core-email-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-email-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,mEAAyD;AACzD,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,KAAK,CAAU;IAGf,QAAQ,CAAU;IAGlB,GAAG,CAAa;CACvB;AATD,sDASC;AAPO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACjB;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;uDACd;AAGlB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,4BAAS,EAAE,CAAC;8BAC7B,4BAAS;kDAAC;AAGX,QAAA,0BAA0B,GACtC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,qBAAqB,EAAE,2BAAoB,CAAC,KAAK,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\nimport { CoreAuthIdentity, CoreAuthIdentityModel } from '../core-auth-identity.model';\nimport { OTPFields } from '../embedded/otp-fields.model';\nimport { CoreAuthIdentityType } from '../../../../utilities/enum';\nimport { createGlobalDiscriminatorModel } from '../../../mongo';\n\nexport class CoreEmailAuthIdentity extends CoreAuthIdentity {\n\t@prop({ required: true, type: String })\n\tpublic email!: string;\n\n\t@prop({ required: true, type: String })\n\tpublic password!: string;\n\n\t@prop({ required: true, type: OTPFields })\n\tpublic otp!: OTPFields;\n}\n\nexport const CoreEmailAuthIdentityModel: ReturnModelType<typeof CoreEmailAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreEmailAuthIdentity, CoreAuthIdentityType.EMAIL);\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core-google-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-google-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,sBAAuB,SAAQ,2CAAgB;IAEpD,KAAK,CAAU;CACtB;AAHD,wDAGC;AADO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;qDACjB;AAGV,QAAA,2BAA2B,GACvC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,sBAAsB,EAAE,2BAAoB,CAAC,MAAM,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\
|
|
1
|
+
{"version":3,"file":"core-google-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-google-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,sBAAuB,SAAQ,2CAAgB;IAEpD,KAAK,CAAU;CACtB;AAHD,wDAGC;AADO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;qDACjB;AAGV,QAAA,2BAA2B,GACvC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,sBAAsB,EAAE,2BAAoB,CAAC,MAAM,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\nimport { CoreAuthIdentity, CoreAuthIdentityModel } from '../core-auth-identity.model';\nimport { CoreAuthIdentityType } from '../../../../utilities/enum';\nimport { createGlobalDiscriminatorModel } from '../../../mongo';\n\nexport class CoreGoogleAuthIdentity extends CoreAuthIdentity {\n\t@prop({ required: true, type: String })\n\tpublic token!: string;\n}\n\nexport const CoreGoogleAuthIdentityModel: ReturnModelType<typeof CoreGoogleAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreGoogleAuthIdentity, CoreAuthIdentityType.GOOGLE);\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core-phone-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-phone-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,mEAAyD;AACzD,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,WAAW,CAAU;IAGrB,GAAG,CAAa;CACvB;AAND,sDAMC;AAJO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;0DACX;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,4BAAS,EAAE,CAAC;8BAC7B,4BAAS;kDAAC;AAGX,QAAA,0BAA0B,GACtC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,qBAAqB,EAAE,2BAAoB,CAAC,KAAK,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\
|
|
1
|
+
{"version":3,"file":"core-phone-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-phone-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,mEAAyD;AACzD,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,WAAW,CAAU;IAGrB,GAAG,CAAa;CACvB;AAND,sDAMC;AAJO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;0DACX;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,4BAAS,EAAE,CAAC;8BAC7B,4BAAS;kDAAC;AAGX,QAAA,0BAA0B,GACtC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,qBAAqB,EAAE,2BAAoB,CAAC,KAAK,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\nimport { CoreAuthIdentity, CoreAuthIdentityModel } from '../core-auth-identity.model';\nimport { OTPFields } from '../embedded/otp-fields.model';\nimport { CoreAuthIdentityType } from '../../../../utilities/enum';\nimport { createGlobalDiscriminatorModel } from '../../../mongo';\n\nexport class CorePhoneAuthIdentity extends CoreAuthIdentity {\n\t@prop({ required: true, type: String })\n\tpublic phoneNumber!: string;\n\n\t@prop({ required: true, type: OTPFields })\n\tpublic otp!: OTPFields;\n}\n\nexport const CorePhoneAuthIdentityModel: ReturnModelType<typeof CorePhoneAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CorePhoneAuthIdentity, CoreAuthIdentityType.PHONE);\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Ref
|
|
1
|
+
import { Ref } from '@typegoose/typegoose';
|
|
2
2
|
import { CouponType, ItemType } from '../../../../utilities/enum';
|
|
3
3
|
import { BaseCoupon } from '../base/base-coupon.model';
|
|
4
4
|
import { CoreUser } from '../core-user.model';
|
|
@@ -9,4 +9,3 @@ export declare class CustomCoupon extends BaseCoupon {
|
|
|
9
9
|
itemTypes?: ItemType[];
|
|
10
10
|
shops?: Ref<Shop>[];
|
|
11
11
|
}
|
|
12
|
-
export declare const CustomCouponModel: ReturnModelType<typeof CustomCoupon>;
|
|
@@ -9,13 +9,12 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.CustomCoupon = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
14
|
const enum_1 = require("../../../../utilities/enum");
|
|
15
15
|
const base_coupon_model_1 = require("../base/base-coupon.model");
|
|
16
16
|
const core_user_model_1 = require("../core-user.model");
|
|
17
17
|
const shop_model_1 = require("../shop.model");
|
|
18
|
-
const coupon_model_1 = require("../coupon.model");
|
|
19
18
|
class CustomCoupon extends base_coupon_model_1.BaseCoupon {
|
|
20
19
|
couponType = enum_1.CouponType.CUSTOM_COUPON;
|
|
21
20
|
influencer;
|
|
@@ -35,5 +34,4 @@ __decorate([
|
|
|
35
34
|
(0, typegoose_1.prop)({ ref: () => shop_model_1.Shop, default: [] }),
|
|
36
35
|
__metadata("design:type", Array)
|
|
37
36
|
], CustomCoupon.prototype, "shops", void 0);
|
|
38
|
-
exports.CustomCouponModel = (0, typegoose_1.getDiscriminatorModelForClass)(coupon_model_1.CouponModel, CustomCoupon, enum_1.CouponType.CUSTOM_COUPON);
|
|
39
37
|
//# sourceMappingURL=custom-coupon.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"custom-coupon.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/custom-coupon.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"custom-coupon.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/custom-coupon.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiD;AACjD,qDAAkE;AAClE,iEAAuD;AACvD,wDAA8C;AAC9C,8CAAqC;AAErC,MAAa,YAAa,SAAQ,8BAAU;IACpC,UAAU,GAAG,iBAAU,CAAC,aAAsB,CAAC;IAG/C,UAAU,CAAiB;IAG3B,SAAS,CAAc;IAGvB,KAAK,CAAe;CAC3B;AAXD,oCAWC;AAPO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,0BAAQ,EAAE,CAAC;;gDACZ;AAG3B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,eAAQ,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;+CACxB;AAGvB;IADN,IAAA,gBAAI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,iBAAI,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;2CACZ","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\r\nimport { CouponType, ItemType } from '../../../../utilities/enum';\r\nimport { BaseCoupon } from '../base/base-coupon.model';\r\nimport { CoreUser } from '../core-user.model';\r\nimport { Shop } from '../shop.model';\r\n\r\nexport class CustomCoupon extends BaseCoupon {\r\n\tpublic couponType = CouponType.CUSTOM_COUPON as const;\r\n\r\n\t@prop({ required: true, ref: () => CoreUser })\r\n\tpublic influencer!: Ref<CoreUser>;\r\n\r\n\t@prop({ type: [String], enum: ItemType, default: [] })\r\n\tpublic itemTypes?: ItemType[];\r\n\r\n\t@prop({ ref: () => Shop, default: [] })\r\n\tpublic shops?: Ref<Shop>[];\r\n}\r\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Ref
|
|
1
|
+
import { Ref } from '@typegoose/typegoose';
|
|
2
2
|
import { MarketingType, ValueType } from '../../../../utilities/enum';
|
|
3
3
|
import { Marketing } from '../marketing.model';
|
|
4
4
|
import { ProductMarketing } from '../product-marketing.model';
|
|
@@ -12,4 +12,3 @@ export declare class DiscountMarketing extends Marketing {
|
|
|
12
12
|
spendLimit?: number;
|
|
13
13
|
isOnlyForSubscriber?: boolean;
|
|
14
14
|
}
|
|
15
|
-
export declare const DiscountMarketingModel: ReturnModelType<typeof DiscountMarketing>;
|
|
@@ -9,7 +9,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.DiscountMarketing = void 0;
|
|
13
13
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
14
|
const enum_1 = require("../../../../utilities/enum");
|
|
15
15
|
const marketing_model_1 = require("../marketing.model");
|
|
@@ -53,5 +53,4 @@ __decorate([
|
|
|
53
53
|
(0, typegoose_1.prop)({ type: Boolean, default: false }),
|
|
54
54
|
__metadata("design:type", Boolean)
|
|
55
55
|
], DiscountMarketing.prototype, "isOnlyForSubscriber", void 0);
|
|
56
|
-
exports.DiscountMarketingModel = (0, typegoose_1.getDiscriminatorModelForClass)(marketing_model_1.MarketingModel, DiscountMarketing, enum_1.MarketingType.DISCOUNT);
|
|
57
56
|
//# sourceMappingURL=discount-marketing.model.js.map
|