@lyxa.ai/core 1.0.65 → 1.0.66-beta.2
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/libraries/mongo/models/embedded/courier-order-finance.model.d.ts +5 -0
- package/dist/libraries/mongo/models/embedded/courier-order-finance.model.js +24 -0
- package/dist/libraries/mongo/models/embedded/courier-order-finance.model.js.map +1 -0
- package/dist/libraries/mongo/models/embedded/order-finance.model.d.ts +13 -0
- package/dist/libraries/mongo/models/embedded/order-finance.model.js +52 -0
- package/dist/libraries/mongo/models/embedded/order-finance.model.js.map +1 -0
- package/dist/libraries/mongo/models/embedded/regular-order-finance.model.d.ts +16 -0
- package/dist/libraries/mongo/models/embedded/regular-order-finance.model.js +71 -0
- package/dist/libraries/mongo/models/embedded/regular-order-finance.model.js.map +1 -0
- package/dist/libraries/mongo/models/index.d.ts +0 -9
- package/dist/libraries/mongo/models/index.js +1 -10
- package/dist/libraries/mongo/models/index.js.map +1 -1
- package/dist/libraries/mongo/models/order.model.d.ts +2 -0
- package/dist/libraries/mongo/models/order.model.js +6 -1
- package/dist/libraries/mongo/models/order.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/courier-order.model.d.ts +2 -0
- package/dist/libraries/mongo/models/providers/courier-order.model.js +6 -0
- package/dist/libraries/mongo/models/providers/courier-order.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/regular-order.model.d.ts +2 -0
- package/dist/libraries/mongo/models/providers/regular-order.model.js +6 -0
- package/dist/libraries/mongo/models/providers/regular-order.model.js.map +1 -1
- package/dist/libraries/mongo/models/shop.model.d.ts +15 -15
- package/dist/libraries/mongo/models/shop.model.js +87 -67
- package/dist/libraries/mongo/models/shop.model.js.map +1 -1
- package/dist/libraries/mongo/models/user-app-section-setting.model.js +1 -0
- package/dist/libraries/mongo/models/user-app-section-setting.model.js.map +1 -1
- package/dist/utilities/validation/common-validation.d.ts +7 -7
- package/package.json +1 -1
- package/dist/libraries/mongo/models/embedded/charge-setting.model.d.ts +0 -14
- package/dist/libraries/mongo/models/embedded/charge-setting.model.js +0 -60
- package/dist/libraries/mongo/models/embedded/charge-setting.model.js.map +0 -1
- package/dist/libraries/mongo/models/terms-condition.model.d.ts +0 -8
- package/dist/libraries/mongo/models/terms-condition.model.js +0 -51
- package/dist/libraries/mongo/models/terms-condition.model.js.map +0 -1
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.CourierOrderFinance = void 0;
|
|
13
|
+
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
|
+
const order_finance_model_1 = require("./order-finance.model");
|
|
15
|
+
const profit_model_1 = require("../embedded/profit.model");
|
|
16
|
+
class CourierOrderFinance extends order_finance_model_1.OrderFinance {
|
|
17
|
+
companyProfit;
|
|
18
|
+
}
|
|
19
|
+
exports.CourierOrderFinance = CourierOrderFinance;
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, typegoose_1.prop)({ type: () => profit_model_1.CourierOrderProfit }),
|
|
22
|
+
__metadata("design:type", profit_model_1.CourierOrderProfit)
|
|
23
|
+
], CourierOrderFinance.prototype, "companyProfit", void 0);
|
|
24
|
+
//# sourceMappingURL=courier-order-finance.model.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"courier-order-finance.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/courier-order-finance.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,+DAAqD;AACrD,2DAA8D;AAE9D,MAAa,mBAAoB,SAAQ,kCAAY;IAE7C,aAAa,CAAsB;CAC1C;AAHD,kDAGC;AADO;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,iCAAkB,EAAE,CAAC;8BAClB,iCAAkB;0DAAC","sourcesContent":["import { prop } from '@typegoose/typegoose';\nimport { OrderFinance } from './order-finance.model';\nimport { CourierOrderProfit } from '../embedded/profit.model';\n\nexport class CourierOrderFinance extends OrderFinance {\n\t@prop({ type: () => CourierOrderProfit })\n\tpublic companyProfit?: CourierOrderProfit;\n}\n"]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
|
|
2
|
+
import { OrderPricing } from './order-pricing.model';
|
|
3
|
+
import { PaymentInformation } from './payment-infromation.model';
|
|
4
|
+
import { PaymentMethod } from '../../../../utilities/enum';
|
|
5
|
+
import { RiderProfit } from './profit.model';
|
|
6
|
+
export declare class OrderFinance extends TimeStamps {
|
|
7
|
+
exchangeRate?: number;
|
|
8
|
+
paymentMethod?: PaymentMethod;
|
|
9
|
+
paymentInformation?: PaymentInformation;
|
|
10
|
+
pricing?: OrderPricing;
|
|
11
|
+
riderProfit?: RiderProfit;
|
|
12
|
+
processedAt?: Date;
|
|
13
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.OrderFinance = void 0;
|
|
13
|
+
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
|
+
const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
15
|
+
const order_pricing_model_1 = require("./order-pricing.model");
|
|
16
|
+
const payment_infromation_model_1 = require("./payment-infromation.model");
|
|
17
|
+
const enum_1 = require("../../../../utilities/enum");
|
|
18
|
+
const profit_model_1 = require("./profit.model");
|
|
19
|
+
class OrderFinance extends defaultClasses_1.TimeStamps {
|
|
20
|
+
exchangeRate;
|
|
21
|
+
paymentMethod;
|
|
22
|
+
paymentInformation;
|
|
23
|
+
pricing;
|
|
24
|
+
riderProfit;
|
|
25
|
+
processedAt;
|
|
26
|
+
}
|
|
27
|
+
exports.OrderFinance = OrderFinance;
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, typegoose_1.prop)({ type: Number, default: 1 }),
|
|
30
|
+
__metadata("design:type", Number)
|
|
31
|
+
], OrderFinance.prototype, "exchangeRate", void 0);
|
|
32
|
+
__decorate([
|
|
33
|
+
(0, typegoose_1.prop)({ type: String, enum: enum_1.PaymentMethod, default: enum_1.PaymentMethod.CASH }),
|
|
34
|
+
__metadata("design:type", String)
|
|
35
|
+
], OrderFinance.prototype, "paymentMethod", void 0);
|
|
36
|
+
__decorate([
|
|
37
|
+
(0, typegoose_1.prop)({ type: () => payment_infromation_model_1.PaymentInformation }),
|
|
38
|
+
__metadata("design:type", payment_infromation_model_1.PaymentInformation)
|
|
39
|
+
], OrderFinance.prototype, "paymentInformation", void 0);
|
|
40
|
+
__decorate([
|
|
41
|
+
(0, typegoose_1.prop)({ type: () => order_pricing_model_1.OrderPricing }),
|
|
42
|
+
__metadata("design:type", order_pricing_model_1.OrderPricing)
|
|
43
|
+
], OrderFinance.prototype, "pricing", void 0);
|
|
44
|
+
__decorate([
|
|
45
|
+
(0, typegoose_1.prop)({ type: () => profit_model_1.RiderProfit }),
|
|
46
|
+
__metadata("design:type", profit_model_1.RiderProfit)
|
|
47
|
+
], OrderFinance.prototype, "riderProfit", void 0);
|
|
48
|
+
__decorate([
|
|
49
|
+
(0, typegoose_1.prop)({ type: Date }),
|
|
50
|
+
__metadata("design:type", Date)
|
|
51
|
+
], OrderFinance.prototype, "processedAt", void 0);
|
|
52
|
+
//# sourceMappingURL=order-finance.model.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"order-finance.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/order-finance.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,4EAAqE;AACrE,+DAAqD;AACrD,2EAAiE;AACjE,qDAA2D;AAC3D,iDAA6C;AAE7C,MAAa,YAAa,SAAQ,2BAAU;IAEpC,YAAY,CAAU;IAGtB,aAAa,CAAiB;IAGrC,kBAAkB,CAAsB;IAGjC,OAAO,CAAgB;IAGvB,WAAW,CAAe;IAG1B,WAAW,CAAQ;CAC1B;AAlBD,oCAkBC;AAhBO;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;;kDACN;AAGtB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,oBAAa,EAAE,OAAO,EAAE,oBAAa,CAAC,IAAI,EAAE,CAAC;;mDACpC;AAGrC;IADC,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,8CAAkB,EAAE,CAAC;8BACpB,8CAAkB;wDAAC;AAGjC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,kCAAY,EAAE,CAAC;8BAClB,kCAAY;6CAAC;AAGvB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,0BAAW,EAAE,CAAC;8BACb,0BAAW;iDAAC;AAG1B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;8BACA,IAAI;iDAAC","sourcesContent":["import { prop } from '@typegoose/typegoose';\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\nimport { OrderPricing } from './order-pricing.model';\nimport { PaymentInformation } from './payment-infromation.model';\nimport { PaymentMethod } from '../../../../utilities/enum';\nimport { RiderProfit } from './profit.model';\n\nexport class OrderFinance extends TimeStamps {\n\t@prop({ type: Number, default: 1 })\n\tpublic exchangeRate?: number;\n\n\t@prop({ type: String, enum: PaymentMethod, default: PaymentMethod.CASH })\n\tpublic paymentMethod?: PaymentMethod;\n\n\t@prop({ type: () => PaymentInformation })\n\tpaymentInformation?: PaymentInformation;\n\n\t@prop({ type: () => OrderPricing })\n\tpublic pricing?: OrderPricing;\n\n\t@prop({ type: () => RiderProfit })\n\tpublic riderProfit?: RiderProfit;\n\n\t@prop({ type: Date })\n\tpublic processedAt?: Date;\n}\n"]}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { OrderFinance } from './order-finance.model';
|
|
2
|
+
import { RegularOrderProfit } from '../embedded/profit.model';
|
|
3
|
+
import { Vat } from '../embedded/vat.model';
|
|
4
|
+
import { CouponDetails, LoyaltyPoint, MarketingCut } from '../embedded/marketing-cut.model';
|
|
5
|
+
export declare class RegularOrderFinance extends OrderFinance {
|
|
6
|
+
companyProfit?: RegularOrderProfit;
|
|
7
|
+
shopProfit?: RegularOrderProfit;
|
|
8
|
+
vat?: Vat;
|
|
9
|
+
discount?: MarketingCut;
|
|
10
|
+
buy1get1?: MarketingCut;
|
|
11
|
+
loyaltyPoint?: LoyaltyPoint;
|
|
12
|
+
coupon?: CouponDetails;
|
|
13
|
+
freeDelivery?: MarketingCut;
|
|
14
|
+
replacementOrder?: MarketingCut;
|
|
15
|
+
endorseLoss?: MarketingCut;
|
|
16
|
+
}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.RegularOrderFinance = void 0;
|
|
13
|
+
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
|
+
const order_finance_model_1 = require("./order-finance.model");
|
|
15
|
+
const profit_model_1 = require("../embedded/profit.model");
|
|
16
|
+
const vat_model_1 = require("../embedded/vat.model");
|
|
17
|
+
const marketing_cut_model_1 = require("../embedded/marketing-cut.model");
|
|
18
|
+
class RegularOrderFinance extends order_finance_model_1.OrderFinance {
|
|
19
|
+
companyProfit;
|
|
20
|
+
shopProfit;
|
|
21
|
+
vat;
|
|
22
|
+
discount;
|
|
23
|
+
buy1get1;
|
|
24
|
+
loyaltyPoint;
|
|
25
|
+
coupon;
|
|
26
|
+
freeDelivery;
|
|
27
|
+
replacementOrder;
|
|
28
|
+
endorseLoss;
|
|
29
|
+
}
|
|
30
|
+
exports.RegularOrderFinance = RegularOrderFinance;
|
|
31
|
+
__decorate([
|
|
32
|
+
(0, typegoose_1.prop)({ type: () => profit_model_1.RegularOrderProfit }),
|
|
33
|
+
__metadata("design:type", profit_model_1.RegularOrderProfit)
|
|
34
|
+
], RegularOrderFinance.prototype, "companyProfit", void 0);
|
|
35
|
+
__decorate([
|
|
36
|
+
(0, typegoose_1.prop)({ type: () => profit_model_1.RegularOrderProfit }),
|
|
37
|
+
__metadata("design:type", profit_model_1.RegularOrderProfit)
|
|
38
|
+
], RegularOrderFinance.prototype, "shopProfit", void 0);
|
|
39
|
+
__decorate([
|
|
40
|
+
(0, typegoose_1.prop)({ type: () => vat_model_1.Vat }),
|
|
41
|
+
__metadata("design:type", vat_model_1.Vat)
|
|
42
|
+
], RegularOrderFinance.prototype, "vat", void 0);
|
|
43
|
+
__decorate([
|
|
44
|
+
(0, typegoose_1.prop)({ type: () => marketing_cut_model_1.MarketingCut }),
|
|
45
|
+
__metadata("design:type", marketing_cut_model_1.MarketingCut)
|
|
46
|
+
], RegularOrderFinance.prototype, "discount", void 0);
|
|
47
|
+
__decorate([
|
|
48
|
+
(0, typegoose_1.prop)({ type: () => marketing_cut_model_1.MarketingCut }),
|
|
49
|
+
__metadata("design:type", marketing_cut_model_1.MarketingCut)
|
|
50
|
+
], RegularOrderFinance.prototype, "buy1get1", void 0);
|
|
51
|
+
__decorate([
|
|
52
|
+
(0, typegoose_1.prop)({ type: () => marketing_cut_model_1.LoyaltyPoint }),
|
|
53
|
+
__metadata("design:type", marketing_cut_model_1.LoyaltyPoint)
|
|
54
|
+
], RegularOrderFinance.prototype, "loyaltyPoint", void 0);
|
|
55
|
+
__decorate([
|
|
56
|
+
(0, typegoose_1.prop)({ type: () => marketing_cut_model_1.CouponDetails }),
|
|
57
|
+
__metadata("design:type", marketing_cut_model_1.CouponDetails)
|
|
58
|
+
], RegularOrderFinance.prototype, "coupon", void 0);
|
|
59
|
+
__decorate([
|
|
60
|
+
(0, typegoose_1.prop)({ type: () => marketing_cut_model_1.MarketingCut }),
|
|
61
|
+
__metadata("design:type", marketing_cut_model_1.MarketingCut)
|
|
62
|
+
], RegularOrderFinance.prototype, "freeDelivery", void 0);
|
|
63
|
+
__decorate([
|
|
64
|
+
(0, typegoose_1.prop)({ type: () => marketing_cut_model_1.MarketingCut }),
|
|
65
|
+
__metadata("design:type", marketing_cut_model_1.MarketingCut)
|
|
66
|
+
], RegularOrderFinance.prototype, "replacementOrder", void 0);
|
|
67
|
+
__decorate([
|
|
68
|
+
(0, typegoose_1.prop)({ type: () => marketing_cut_model_1.MarketingCut }),
|
|
69
|
+
__metadata("design:type", marketing_cut_model_1.MarketingCut)
|
|
70
|
+
], RegularOrderFinance.prototype, "endorseLoss", void 0);
|
|
71
|
+
//# sourceMappingURL=regular-order-finance.model.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"regular-order-finance.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/regular-order-finance.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,+DAAqD;AACrD,2DAA8D;AAC9D,qDAA4C;AAC5C,yEAA4F;AAE5F,MAAa,mBAAoB,SAAQ,kCAAY;IAE7C,aAAa,CAAsB;IAGnC,UAAU,CAAsB;IAGhC,GAAG,CAAO;IAGV,QAAQ,CAAgB;IAGxB,QAAQ,CAAgB;IAGxB,YAAY,CAAgB;IAG5B,MAAM,CAAiB;IAGvB,YAAY,CAAgB;IAG5B,gBAAgB,CAAgB;IAGhC,WAAW,CAAgB;CAClC;AA9BD,kDA8BC;AA5BO;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,iCAAkB,EAAE,CAAC;8BAClB,iCAAkB;0DAAC;AAGnC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,iCAAkB,EAAE,CAAC;8BACrB,iCAAkB;uDAAC;AAGhC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,eAAG,EAAE,CAAC;8BACb,eAAG;gDAAC;AAGV;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,kCAAY,EAAE,CAAC;8BACjB,kCAAY;qDAAC;AAGxB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,kCAAY,EAAE,CAAC;8BACjB,kCAAY;qDAAC;AAGxB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,kCAAY,EAAE,CAAC;8BACb,kCAAY;yDAAC;AAG5B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,mCAAa,EAAE,CAAC;8BACpB,mCAAa;mDAAC;AAGvB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,kCAAY,EAAE,CAAC;8BACb,kCAAY;yDAAC;AAG5B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,kCAAY,EAAE,CAAC;8BACT,kCAAY;6DAAC;AAGhC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,kCAAY,EAAE,CAAC;8BACd,kCAAY;wDAAC","sourcesContent":["import { prop } from '@typegoose/typegoose';\nimport { OrderFinance } from './order-finance.model';\nimport { RegularOrderProfit } from '../embedded/profit.model';\nimport { Vat } from '../embedded/vat.model';\nimport { CouponDetails, LoyaltyPoint, MarketingCut } from '../embedded/marketing-cut.model';\n\nexport class RegularOrderFinance extends OrderFinance {\n\t@prop({ type: () => RegularOrderProfit })\n\tpublic companyProfit?: RegularOrderProfit;\n\n\t@prop({ type: () => RegularOrderProfit })\n\tpublic shopProfit?: RegularOrderProfit;\n\n\t@prop({ type: () => Vat })\n\tpublic vat?: Vat;\n\n\t@prop({ type: () => MarketingCut })\n\tpublic discount?: MarketingCut;\n\n\t@prop({ type: () => MarketingCut })\n\tpublic buy1get1?: MarketingCut;\n\n\t@prop({ type: () => LoyaltyPoint })\n\tpublic loyaltyPoint?: LoyaltyPoint;\n\n\t@prop({ type: () => CouponDetails })\n\tpublic coupon?: CouponDetails;\n\n\t@prop({ type: () => MarketingCut })\n\tpublic freeDelivery?: MarketingCut;\n\n\t@prop({ type: () => MarketingCut })\n\tpublic replacementOrder?: MarketingCut;\n\n\t@prop({ type: () => MarketingCut })\n\tpublic endorseLoss?: MarketingCut;\n}\n"]}
|
|
@@ -74,9 +74,6 @@ import { Order } from './order.model';
|
|
|
74
74
|
import { RegularOrder } from './providers/regular-order.model';
|
|
75
75
|
import { CourierOrder } from './providers/courier-order.model';
|
|
76
76
|
import { OrderDelivery } from './order-delivery.model';
|
|
77
|
-
import { OrderFinance } from './order-finance.model';
|
|
78
|
-
import { RegularOrderFinance } from './providers/regular-order-finance.model';
|
|
79
|
-
import { CourierOrderFinance } from './providers/courier-order-finance.model';
|
|
80
77
|
import { FinanceSettlement } from './finance-settlement.model';
|
|
81
78
|
import { DefaultChat } from './default-chat.model';
|
|
82
79
|
import { TermsAndConditions } from './terms-and-conditions.model';
|
|
@@ -188,12 +185,6 @@ export * from './providers/regular-order.model';
|
|
|
188
185
|
export * from './providers/courier-order.model';
|
|
189
186
|
export declare const OrderDeliveryModel: ReturnModelType<typeof OrderDelivery>;
|
|
190
187
|
export * from './order-delivery.model';
|
|
191
|
-
export declare const OrderFinanceModel: ReturnModelType<typeof OrderFinance>;
|
|
192
|
-
export declare const RegularOrderFinanceModel: ReturnModelType<typeof RegularOrderFinance>;
|
|
193
|
-
export declare const CourierOrderFinanceModel: ReturnModelType<typeof CourierOrderFinance>;
|
|
194
|
-
export * from './order-finance.model';
|
|
195
|
-
export * from './providers/regular-order-finance.model';
|
|
196
|
-
export * from './providers/courier-order-finance.model';
|
|
197
188
|
export declare const ParentModel: ReturnModelType<typeof Parent>;
|
|
198
189
|
export * from './parent.model';
|
|
199
190
|
export declare const ProductMarketingModel: ReturnModelType<typeof ProductMarketing>;
|
|
@@ -15,7 +15,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
exports.OrderModel = exports.NutritionModel = exports.NotificationModel = exports.MealPlanModel = exports.PunchMarketingModel = exports.LoyaltyPointMarketingModel = exports.FreeDeliveryMarketingModel = exports.FeaturedMarketingModel = exports.DiscountMarketingModel = exports.Buy1Get1MarketingModel = exports.MarketingModel = exports.LoyaltyPointSettingModel = exports.LoyaltyPointCategoryModel = exports.ListContainerModel = exports.LineItemModel = exports.GalleryModel = exports.FinanceSettlementModel = exports.FilterContainerModel = exports.FeaturedSettingModel = exports.FavouriteModel = exports.FaqModel = exports.DishModel = exports.DealSettingModel = exports.ReferralRewardCouponModel = exports.ReferralCodeCouponModel = exports.IndividualUserCouponModel = exports.IndividualStoreCouponModel = exports.GlobalCouponModel = exports.CustomCouponModel = exports.CouponModel = exports.CounterModel = exports.CoreUserModel = exports.CoreAppleAuthIdentityModel = exports.CoreGoogleAuthIdentityModel = exports.CorePhoneAuthIdentityModel = exports.CoreEmailAuthIdentityModel = exports.CoreAuthIdentityModel = exports.CategoryModel = exports.CartParticipantModel = exports.CartModel = exports.AreebaCardModel = exports.CardModel = exports.BrandModel = exports.BOBFinanceModel = exports.BannerModel = exports.AttributeModel = exports.UserAppSectionSettingModel = exports.AdminModel = exports.AdminAccessControlModel = exports.ActivityLogModel = void 0;
|
|
18
|
-
exports.CancellationReasonModel = exports.SupportReasonModel = exports.TermsAndConditionsModel = exports.DefaultChatModel = exports.ZoneModel = exports.UserModel = exports.TagModel = exports.SubscriptionModel = exports.SubscriptionSettingModel = exports.ShopModel = exports.ShopReviewModel = exports.ShopMealPlanModel = exports.ShopCategoryModel = exports.ShopAccessControlModel = exports.SettingModel = exports.RoleModel = exports.RiderModel = exports.RiderTrackingModel = exports.RiderTimeoutModel = exports.RiderReviewModel = exports.RequestAreaModel = exports.ReferralSettingModel = exports.RatingSettingModel = exports.PunchMarketingHistoryModel = exports.ProductModel = exports.ProductMarketingModel = exports.ParentModel = exports.
|
|
18
|
+
exports.CancellationReasonModel = exports.SupportReasonModel = exports.TermsAndConditionsModel = exports.DefaultChatModel = exports.ZoneModel = exports.UserModel = exports.TagModel = exports.SubscriptionModel = exports.SubscriptionSettingModel = exports.ShopModel = exports.ShopReviewModel = exports.ShopMealPlanModel = exports.ShopCategoryModel = exports.ShopAccessControlModel = exports.SettingModel = exports.RoleModel = exports.RiderModel = exports.RiderTrackingModel = exports.RiderTimeoutModel = exports.RiderReviewModel = exports.RequestAreaModel = exports.ReferralSettingModel = exports.RatingSettingModel = exports.PunchMarketingHistoryModel = exports.ProductModel = exports.ProductMarketingModel = exports.ParentModel = exports.OrderDeliveryModel = exports.CourierOrderModel = exports.RegularOrderModel = void 0;
|
|
19
19
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
20
20
|
const admin_model_1 = require("./admin.model");
|
|
21
21
|
const admin_access_control_model_1 = require("./admin-access-control.model");
|
|
@@ -94,9 +94,6 @@ const order_model_1 = require("./order.model");
|
|
|
94
94
|
const regular_order_model_1 = require("./providers/regular-order.model");
|
|
95
95
|
const courier_order_model_1 = require("./providers/courier-order.model");
|
|
96
96
|
const order_delivery_model_1 = require("./order-delivery.model");
|
|
97
|
-
const order_finance_model_1 = require("./order-finance.model");
|
|
98
|
-
const regular_order_finance_model_1 = require("./providers/regular-order-finance.model");
|
|
99
|
-
const courier_order_finance_model_1 = require("./providers/courier-order-finance.model");
|
|
100
97
|
const finance_settlement_model_1 = require("./finance-settlement.model");
|
|
101
98
|
const default_chat_model_1 = require("./default-chat.model");
|
|
102
99
|
const terms_and_conditions_model_1 = require("./terms-and-conditions.model");
|
|
@@ -208,12 +205,6 @@ __exportStar(require("./providers/regular-order.model"), exports);
|
|
|
208
205
|
__exportStar(require("./providers/courier-order.model"), exports);
|
|
209
206
|
exports.OrderDeliveryModel = (0, typegoose_1.getModelForClass)(order_delivery_model_1.OrderDelivery);
|
|
210
207
|
__exportStar(require("./order-delivery.model"), exports);
|
|
211
|
-
exports.OrderFinanceModel = (0, typegoose_1.getModelForClass)(order_finance_model_1.OrderFinance);
|
|
212
|
-
exports.RegularOrderFinanceModel = (0, typegoose_1.getDiscriminatorModelForClass)(exports.OrderFinanceModel, regular_order_finance_model_1.RegularOrderFinance, enum_1.OrderType.REGULAR);
|
|
213
|
-
exports.CourierOrderFinanceModel = (0, typegoose_1.getDiscriminatorModelForClass)(exports.OrderFinanceModel, courier_order_finance_model_1.CourierOrderFinance, enum_1.OrderType.COURIER);
|
|
214
|
-
__exportStar(require("./order-finance.model"), exports);
|
|
215
|
-
__exportStar(require("./providers/regular-order-finance.model"), exports);
|
|
216
|
-
__exportStar(require("./providers/courier-order-finance.model"), exports);
|
|
217
208
|
exports.ParentModel = (0, typegoose_1.getModelForClass)(parent_model_1.Parent);
|
|
218
209
|
__exportStar(require("./parent.model"), exports);
|
|
219
210
|
exports.ProductMarketingModel = (0, typegoose_1.getModelForClass)(product_marketing_model_1.ProductMarketing);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"/","sources":["libraries/mongo/models/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,oDAAwG;AACxG,+CAAsC;AACtC,6EAAkE;AAClE,6DAAmD;AACnD,qFAAyE;AACzE,uDAA8C;AAC9C,iDAAwC;AACxC,2DAAiD;AACjD,+CAAsC;AACtC,qDAA4C;AAC5C,mDAA0C;AAC1C,iDAAwC;AACxC,6DAAmD;AACnD,6CAAoC;AACpC,2CAAkC;AAClC,uDAA8C;AAC9C,q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AkB,CAAC,CAAC;AACxH,8DAA4C","sourcesContent":["import { getDiscriminatorModelForClass, getModelForClass, ReturnModelType } from '@typegoose/typegoose';\nimport { Admin } from './admin.model';\nimport { AdminAccessControl } from './admin-access-control.model';\nimport { ActivityLog } from './activity-log.model';\nimport { UserAppSectionSetting } from './user-app-section-setting.model';\nimport { Attribute } from './attribute.model';\nimport { Banner } from './banner.model';\nimport { BOBFinance } from './bob-finance.model';\nimport { Brand } from './brand.model';\nimport { Category } from './category.model';\nimport { Counter } from './counter.model';\nimport { Coupon } from './coupon.model';\nimport { DealSetting } from './deal-setting.model';\nimport { Dish } from './dish.model';\nimport { Faq } from './faq.model';\nimport { Favourite } from './favourite.model';\nimport { FeaturedSetting } from './featured-setting.model';\nimport { FilterContainer } from './filter-container.model';\nimport { ListContainer } from './list-container.model';\nimport { LoyaltyPointCategory } from './loyalty-point-category.model';\nimport { LoyaltyPointSetting } from './loyalty-point-setting.model';\nimport { Marketing } from './marketing.model';\nimport { MealPlan } from './meal-plan.model';\nimport { Nutrition } from './nutrition.model';\nimport { Parent } from './parent.model';\nimport { ProductMarketing } from './product-marketing.model';\nimport { Product } from './product.model';\nimport { PunchMarketingHistory } from './punch-marketing-history.model';\nimport { RatingSetting } from './rating-setting.model';\nimport { ReferralSetting } from './referral-setting.model';\nimport { RequestArea } from './request-area.model';\nimport { RiderReview } from './rider-review.model';\nimport { Role } from './role.model';\nimport { createGlobalDiscriminatorModel, createGlobalModel } from '../../mongo';\nimport { Setting } from './setting.model';\nimport { ShopAccessControl } from './shop-access-control.model';\nimport { ShopCategory } from './shop-category.model';\nimport { ShopMealPlan } from './shop-meal-plan.model';\nimport { ShopReview } from './shop-review.model';\nimport { Shop } from './shop.model';\nimport { SubscriptionSetting } from './subscription-setting.model';\nimport { Subscription } from './subscription.model';\nimport { Tag } from './tag.model';\nimport { Zone } from './zone.model';\nimport { Buy1Get1Marketing } from './providers/buy1-get1-marketing.model';\nimport {\n\tCardType,\n\tCoreAuthIdentityType,\n\tCouponType,\n\tMarketingType,\n\tOrderType,\n} from '../../../utilities/enum';\nimport { CustomCoupon } from './providers/custom-coupon.model';\nimport { DiscountMarketing } from './providers/discount-marketing.model';\nimport { FeaturedMarketing } from './providers/featured-marketing.model';\nimport { FreeDeliveryMarketing } from './providers/free-delivery-marketing.model';\nimport { GlobalCoupon } from './providers/global-coupon.model';\nimport { IndividualStoreCoupon } from './providers/individual-store-coupon.model';\nimport { IndividualUserCoupon } from './providers/individual-user-coupon.model';\nimport { LoyaltyPointMarketing } from './providers/loyalty-point-marketing.model';\nimport { PunchMarketing } from './providers/punch-marketing.model';\nimport { ReferralCodeCoupon } from './providers/referral-code-coupon.model';\nimport { ReferralRewardCoupon } from './providers/referral-reward-coupon.model';\nimport { Notification } from './notification.model';\nimport { CoreAuthIdentity } from './core-auth-identity.model';\nimport { CoreEmailAuthIdentity } from './providers/core-email-auth-identity.model';\nimport { CorePhoneAuthIdentity } from './providers/core-phone-auth-identity.model';\nimport { CoreGoogleAuthIdentity } from './providers/core-google-auth-identity.model';\nimport { CoreAppleAuthIdentity } from './providers/core-apple-auth-identity.model';\nimport { CoreUser } from './core-user.model';\nimport { Card } from './card.model';\nimport { AreebaCard } from './providers/areeba-card.model';\nimport { RiderTracking } from './rider-tracking.model';\nimport { Rider } from './rider.model';\nimport { RiderTimeout } from './rider-timeout.model';\nimport { User } from './user.model';\nimport { Cart } from './cart.model';\nimport { LineItem } from './line-item.model';\nimport { CartParticipant } from './cart-participant.model';\nimport { Gallery } from './gallery.model';\nimport { Order } from './order.model';\nimport { RegularOrder } from './providers/regular-order.model';\nimport { CourierOrder } from './providers/courier-order.model';\nimport { OrderDelivery } from './order-delivery.model';\nimport { OrderFinance } from './order-finance.model';\nimport { RegularOrderFinance } from './providers/regular-order-finance.model';\nimport { CourierOrderFinance } from './providers/courier-order-finance.model';\nimport { FinanceSettlement } from './finance-settlement.model';\nimport { DefaultChat } from './default-chat.model';\nimport { TermsAndConditions } from './terms-and-conditions.model';\nimport { CancellationReason } from './cancellation-reason.model';\nimport { SupportReason } from './support-reason.model';\n\n\nexport const ActivityLogModel: ReturnModelType<typeof ActivityLog> = getModelForClass(ActivityLog);\nexport * from './activity-log.model';\n\nexport const AdminAccessControlModel: ReturnModelType<typeof AdminAccessControl> =\n\tgetModelForClass(AdminAccessControl);\nexport * from './admin-access-control.model';\n\nexport const AdminModel: ReturnModelType<typeof Admin> = getModelForClass(Admin);\nexport * from './admin.model';\n\nexport const UserAppSectionSettingModel: ReturnModelType<typeof UserAppSectionSetting> =\n\tgetModelForClass(UserAppSectionSetting);\nexport * from './user-app-section-setting.model';\n\nexport const AttributeModel: ReturnModelType<typeof Attribute> = getModelForClass(Attribute);\nexport * from './attribute.model';\n\nexport const BannerModel: ReturnModelType<typeof Banner> = getModelForClass(Banner);\nexport * from './banner.model';\n\nexport const BOBFinanceModel: ReturnModelType<typeof BOBFinance> = getModelForClass(BOBFinance);\nexport * from './bob-finance.model';\n\nexport const BrandModel: ReturnModelType<typeof Brand> = getModelForClass(Brand);\nexport * from './brand.model';\n\nexport const CardModel: ReturnModelType<typeof Card> = createGlobalModel(Card);\nexport const AreebaCardModel: ReturnModelType<typeof AreebaCard> = createGlobalDiscriminatorModel(\n\tCardModel,\n\tAreebaCard,\n\tCardType.AREEBA\n);\nexport * from './card.model';\nexport * from './providers/areeba-card.model';\n\nexport const CartModel: ReturnModelType<typeof Cart> = getModelForClass(Cart);\nexport * from './cart.model';\n\nexport const CartParticipantModel: ReturnModelType<typeof CartParticipant> =\n\tgetModelForClass(CartParticipant);\nexport * from './cart-participant.model';\n\nexport const CategoryModel: ReturnModelType<typeof Category> = getModelForClass(Category);\nexport * from './category.model';\n\nexport const CoreAuthIdentityModel: ReturnModelType<typeof CoreAuthIdentity> =\n\tcreateGlobalModel(CoreAuthIdentity);\nexport const CoreEmailAuthIdentityModel: ReturnModelType<typeof CoreEmailAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreEmailAuthIdentity, CoreAuthIdentityType.EMAIL);\nexport const CorePhoneAuthIdentityModel: ReturnModelType<typeof CorePhoneAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CorePhoneAuthIdentity, CoreAuthIdentityType.PHONE);\nexport const CoreGoogleAuthIdentityModel: ReturnModelType<typeof CoreGoogleAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreGoogleAuthIdentity, CoreAuthIdentityType.GOOGLE);\nexport const CoreAppleAuthIdentityModel: ReturnModelType<typeof CoreAppleAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreAppleAuthIdentity, CoreAuthIdentityType.APPLE);\nexport * from './core-auth-identity.model';\nexport * from './providers/core-apple-auth-identity.model';\nexport * from './providers/core-email-auth-identity.model';\nexport * from './providers/core-google-auth-identity.model';\nexport * from './providers/core-phone-auth-identity.model';\n\nexport const CoreUserModel: ReturnModelType<typeof CoreUser> = createGlobalModel(CoreUser);\nexport * from './core-user.model';\n\nexport const CounterModel: ReturnModelType<typeof Counter> = getModelForClass(Counter);\nexport * from './counter.model';\n\nexport const CouponModel: ReturnModelType<typeof Coupon> = getModelForClass(Coupon);\nexport const CustomCouponModel: ReturnModelType<typeof CustomCoupon> = getDiscriminatorModelForClass(\n\tCouponModel,\n\tCustomCoupon,\n\tCouponType.CUSTOM_COUPON\n);\nexport const GlobalCouponModel: ReturnModelType<typeof GlobalCoupon> = getDiscriminatorModelForClass(\n\tCouponModel,\n\tGlobalCoupon,\n\tCouponType.GLOBAL\n);\nexport const IndividualStoreCouponModel: ReturnModelType<typeof IndividualStoreCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, IndividualStoreCoupon, CouponType.INDIVIDUAL_STORE);\nexport const IndividualUserCouponModel: ReturnModelType<typeof IndividualUserCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, IndividualUserCoupon, CouponType.INDIVIDUAL_USER);\nexport const ReferralCodeCouponModel: ReturnModelType<typeof ReferralCodeCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ReferralCodeCoupon, CouponType.REFERRAL_CODE);\nexport const ReferralRewardCouponModel: ReturnModelType<typeof ReferralRewardCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ReferralRewardCoupon, CouponType.REFERRAL_REWARD);\nexport * from './coupon.model';\nexport * from './providers/custom-coupon.model';\nexport * from './providers/global-coupon.model';\nexport * from './providers/individual-store-coupon.model';\nexport * from './providers/individual-user-coupon.model';\nexport * from './providers/referral-code-coupon.model';\nexport * from './providers/referral-reward-coupon.model';\n\nexport const DealSettingModel: ReturnModelType<typeof DealSetting> = getModelForClass(DealSetting);\nexport * from './deal-setting.model';\n\nexport const DishModel: ReturnModelType<typeof Dish> = getModelForClass(Dish);\nexport * from './dish.model';\n\nexport const FaqModel: ReturnModelType<typeof Faq> = getModelForClass(Faq);\nexport * from './faq.model';\n\nexport const FavouriteModel: ReturnModelType<typeof Favourite> = getModelForClass(Favourite);\nexport * from './favourite.model';\n\nexport const FeaturedSettingModel: ReturnModelType<typeof FeaturedSetting> =\n\tgetModelForClass(FeaturedSetting);\nexport * from './featured-setting.model';\n\nexport const FilterContainerModel: ReturnModelType<typeof FilterContainer> =\n\tgetModelForClass(FilterContainer);\nexport * from './filter-container.model';\n\nexport const FinanceSettlementModel: ReturnModelType<typeof FinanceSettlement> =\n\tgetModelForClass(FinanceSettlement);\nexport * from './finance-settlement.model';\n\nexport const GalleryModel: ReturnModelType<typeof Gallery> = getModelForClass(Gallery);\nexport * from './gallery.model';\n\nexport const LineItemModel: ReturnModelType<typeof LineItem> = getModelForClass(LineItem);\nexport * from './line-item.model';\n\nexport const ListContainerModel: ReturnModelType<typeof ListContainer> = getModelForClass(ListContainer);\nexport * from './list-container.model';\n\nexport const LoyaltyPointCategoryModel: ReturnModelType<typeof LoyaltyPointCategory> =\n\tgetModelForClass(LoyaltyPointCategory);\nexport * from './loyalty-point-category.model';\n\nexport const LoyaltyPointSettingModel: ReturnModelType<typeof LoyaltyPointSetting> =\n\tgetModelForClass(LoyaltyPointSetting);\nexport * from './loyalty-point-setting.model';\n\nexport const MarketingModel: ReturnModelType<typeof Marketing> = getModelForClass(Marketing);\nexport const Buy1Get1MarketingModel: ReturnModelType<typeof Buy1Get1Marketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, Buy1Get1Marketing, MarketingType.BUY1GET1);\nexport const DiscountMarketingModel: ReturnModelType<typeof DiscountMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, DiscountMarketing, MarketingType.DISCOUNT);\nexport const FeaturedMarketingModel: ReturnModelType<typeof FeaturedMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, FeaturedMarketing, MarketingType.FEATURED);\nexport const FreeDeliveryMarketingModel: ReturnModelType<typeof FreeDeliveryMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, FreeDeliveryMarketing, MarketingType.FREE_DELIVERY);\nexport const LoyaltyPointMarketingModel: ReturnModelType<typeof LoyaltyPointMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, LoyaltyPointMarketing, MarketingType.LOYALTY_POINT);\nexport const PunchMarketingModel: ReturnModelType<typeof PunchMarketing> = getDiscriminatorModelForClass(\n\tMarketingModel,\n\tPunchMarketing,\n\tMarketingType.PUNCH_MARKETING\n);\nexport * from './marketing.model';\nexport * from './providers/buy1-get1-marketing.model';\nexport * from './providers/discount-marketing.model';\nexport * from './providers/featured-marketing.model';\nexport * from './providers/free-delivery-marketing.model';\nexport * from './providers/loyalty-point-marketing.model';\nexport * from './providers/punch-marketing.model';\n\nexport const MealPlanModel: ReturnModelType<typeof MealPlan> = getModelForClass(MealPlan);\nexport * from './meal-plan.model';\n\nexport const NotificationModel: ReturnModelType<typeof Notification> = getModelForClass(Notification);\nexport * from './notification.model';\n\nexport const NutritionModel: ReturnModelType<typeof Nutrition> = getModelForClass(Nutrition);\nexport * from './nutrition.model';\n\nexport const OrderModel: ReturnModelType<typeof Order> = getModelForClass(Order);\nexport const RegularOrderModel: ReturnModelType<typeof RegularOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tRegularOrder,\n\tOrderType.REGULAR\n);\nexport const CourierOrderModel: ReturnModelType<typeof CourierOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tCourierOrder,\n\tOrderType.COURIER\n);\nexport * from './order.model';\nexport * from './providers/regular-order.model';\nexport * from './providers/courier-order.model';\n\nexport const OrderDeliveryModel: ReturnModelType<typeof OrderDelivery> = getModelForClass(OrderDelivery);\nexport * from './order-delivery.model';\n\nexport const OrderFinanceModel: ReturnModelType<typeof OrderFinance> = getModelForClass(OrderFinance);\nexport const RegularOrderFinanceModel: ReturnModelType<typeof RegularOrderFinance> =\n\tgetDiscriminatorModelForClass(OrderFinanceModel, RegularOrderFinance, OrderType.REGULAR);\nexport const CourierOrderFinanceModel: ReturnModelType<typeof CourierOrderFinance> =\n\tgetDiscriminatorModelForClass(OrderFinanceModel, CourierOrderFinance, OrderType.COURIER);\nexport * from './order-finance.model';\nexport * from './providers/regular-order-finance.model';\nexport * from './providers/courier-order-finance.model';\n\nexport const ParentModel: ReturnModelType<typeof Parent> = getModelForClass(Parent);\nexport * from './parent.model';\n\nexport const ProductMarketingModel: ReturnModelType<typeof ProductMarketing> =\n\tgetModelForClass(ProductMarketing);\nexport * from './product-marketing.model';\n\nexport const ProductModel: ReturnModelType<typeof Product> = getModelForClass(Product);\nexport * from './product.model';\n\nexport const PunchMarketingHistoryModel: ReturnModelType<typeof PunchMarketingHistory> =\n\tgetModelForClass(PunchMarketingHistory);\nexport * from './punch-marketing-history.model';\n\nexport const RatingSettingModel: ReturnModelType<typeof RatingSetting> = getModelForClass(RatingSetting);\nexport * from './rating-setting.model';\n\nexport const ReferralSettingModel: ReturnModelType<typeof ReferralSetting> =\n\tgetModelForClass(ReferralSetting);\nexport * from './referral-setting.model';\n\nexport const RequestAreaModel: ReturnModelType<typeof RequestArea> = getModelForClass(RequestArea);\nexport * from './request-area.model';\n\nexport const RiderReviewModel: ReturnModelType<typeof RiderReview> = getModelForClass(RiderReview);\nexport * from './rider-review.model';\n\nexport const RiderTimeoutModel: ReturnModelType<typeof RiderTimeout> = getModelForClass(RiderTimeout);\nexport * from './rider-timeout.model';\n\nexport const RiderTrackingModel: ReturnModelType<typeof RiderTracking> = getModelForClass(RiderTracking);\nexport * from './rider-tracking.model';\n\nexport const RiderModel: ReturnModelType<typeof Rider> = getModelForClass(Rider);\nexport * from './rider.model';\n\nexport const RoleModel: ReturnModelType<typeof Role> = createGlobalModel(Role);\nexport * from './role.model';\n\nexport const SettingModel: ReturnModelType<typeof Setting> = getModelForClass(Setting);\nexport * from './setting.model';\n\nexport const ShopAccessControlModel: ReturnModelType<typeof ShopAccessControl> =\n\tgetModelForClass(ShopAccessControl);\nexport * from './shop-access-control.model';\n\nexport const ShopCategoryModel: ReturnModelType<typeof ShopCategory> = getModelForClass(ShopCategory);\nexport * from './shop-category.model';\n\nexport const ShopMealPlanModel: ReturnModelType<typeof ShopMealPlan> = getModelForClass(ShopMealPlan);\nexport * from './shop-meal-plan.model';\n\nexport const ShopReviewModel: ReturnModelType<typeof ShopReview> = getModelForClass(ShopReview);\nexport * from './shop-review.model';\n\nexport const ShopModel: ReturnModelType<typeof Shop> = getModelForClass(Shop);\nexport * from './shop.model';\n\nexport const SubscriptionSettingModel: ReturnModelType<typeof SubscriptionSetting> =\n\tgetModelForClass(SubscriptionSetting);\nexport * from './subscription-setting.model';\n\nexport const SubscriptionModel: ReturnModelType<typeof Subscription> = getModelForClass(Subscription);\nexport * from './subscription.model';\n\nexport const TagModel: ReturnModelType<typeof Tag> = getModelForClass(Tag);\nexport * from './tag.model';\n\nexport const UserModel: ReturnModelType<typeof User> = getModelForClass(User);\nexport * from './user.model';\n\nexport const ZoneModel: ReturnModelType<typeof Zone> = getModelForClass(Zone);\nexport * from './zone.model';\n\n\nexport const DefaultChatModel: ReturnModelType <typeof DefaultChat> = getModelForClass(DefaultChat);\nexport * from './default-chat.model';\n\nexport const TermsAndConditionsModel: ReturnModelType<typeof TermsAndConditions> = getModelForClass(TermsAndConditions);\nexport * from './terms-and-conditions.model';\n\nexport const SupportReasonModel: ReturnModelType<typeof SupportReason> = getModelForClass(SupportReason)\nexport * from './support-reason.model';\n\nexport const CancellationReasonModel: ReturnModelType<typeof CancellationReason> = getModelForClass(CancellationReason);\nexport * from './cancellation-reason.model';"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"/","sources":["libraries/mongo/models/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,oDAAwG;AACxG,+CAAsC;AACtC,6EAAkE;AAClE,6DAAmD;AACnD,qFAAyE;AACzE,uDAA8C;AAC9C,iDAAwC;AACxC,2DAAiD;AACjD,+CAAsC;AACtC,qDAA4C;AAC5C,mDAA0C;AAC1C,iDAAwC;AACxC,6DAAmD;AACnD,6CAAoC;AACpC,2CAAkC;AAClC,uDAA8C;AAC9C,qEAA2D;AAC3D,qEAA2D;AAC3D,iEAAuD;AACvD,iFAAsE;AACtE,+EAAoE;AACpE,uDAA8C;AAC9C,uDAA6C;AAC7C,uDAA8C;AAC9C,iDAAwC;AACxC,uEAA6D;AAC7D,mDAA0C;AAC1C,mFAAwE;AACxE,iEAAuD;AACvD,qEAA2D;AAC3D,6DAAmD;AACnD,6DAAmD;AACnD,6CAAoC;AACpC,uCAAgF;AAChF,mDAA0C;AAC1C,2EAAgE;AAChE,+DAAqD;AACrD,iEAAsD;AACtD,2DAAiD;AACjD,6CAAoC;AACpC,6EAAmE;AACnE,6DAAoD;AACpD,2CAAkC;AAClC,6CAAoC;AACpC,qFAA0E;AAC1E,kDAMiC;AACjC,yEAA+D;AAC/D,mFAAyE;AACzE,mFAAyE;AACzE,6FAAkF;AAClF,yEAA+D;AAC/D,6FAAkF;AAClF,2FAAgF;AAChF,6FAAkF;AAClF,6EAAmE;AACnE,uFAA4E;AAC5E,2FAAgF;AAChF,6DAAoD;AACpD,yEAA8D;AAC9D,+FAAmF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,QAAA,uBAAuB,GAA+C,IAAA,4BAAgB,EAAC,+CAAkB,CAAC,CAAC;AACxH,+DAA6C;AAEhC,QAAA,kBAAkB,GAA0C,IAAA,4BAAgB,EAAC,oCAAa,CAAC,CAAA;AACxG,yDAAuC;AAE1B,QAAA,uBAAuB,GAA+C,IAAA,4BAAgB,EAAC,8CAAkB,CAAC,CAAC;AACxH,8DAA4C","sourcesContent":["import { getDiscriminatorModelForClass, getModelForClass, ReturnModelType } from '@typegoose/typegoose';\nimport { Admin } from './admin.model';\nimport { AdminAccessControl } from './admin-access-control.model';\nimport { ActivityLog } from './activity-log.model';\nimport { UserAppSectionSetting } from './user-app-section-setting.model';\nimport { Attribute } from './attribute.model';\nimport { Banner } from './banner.model';\nimport { BOBFinance } from './bob-finance.model';\nimport { Brand } from './brand.model';\nimport { Category } from './category.model';\nimport { Counter } from './counter.model';\nimport { Coupon } from './coupon.model';\nimport { DealSetting } from './deal-setting.model';\nimport { Dish } from './dish.model';\nimport { Faq } from './faq.model';\nimport { Favourite } from './favourite.model';\nimport { FeaturedSetting } from './featured-setting.model';\nimport { FilterContainer } from './filter-container.model';\nimport { ListContainer } from './list-container.model';\nimport { LoyaltyPointCategory } from './loyalty-point-category.model';\nimport { LoyaltyPointSetting } from './loyalty-point-setting.model';\nimport { Marketing } from './marketing.model';\nimport { MealPlan } from './meal-plan.model';\nimport { Nutrition } from './nutrition.model';\nimport { Parent } from './parent.model';\nimport { ProductMarketing } from './product-marketing.model';\nimport { Product } from './product.model';\nimport { PunchMarketingHistory } from './punch-marketing-history.model';\nimport { RatingSetting } from './rating-setting.model';\nimport { ReferralSetting } from './referral-setting.model';\nimport { RequestArea } from './request-area.model';\nimport { RiderReview } from './rider-review.model';\nimport { Role } from './role.model';\nimport { createGlobalDiscriminatorModel, createGlobalModel } from '../../mongo';\nimport { Setting } from './setting.model';\nimport { ShopAccessControl } from './shop-access-control.model';\nimport { ShopCategory } from './shop-category.model';\nimport { ShopMealPlan } from './shop-meal-plan.model';\nimport { ShopReview } from './shop-review.model';\nimport { Shop } from './shop.model';\nimport { SubscriptionSetting } from './subscription-setting.model';\nimport { Subscription } from './subscription.model';\nimport { Tag } from './tag.model';\nimport { Zone } from './zone.model';\nimport { Buy1Get1Marketing } from './providers/buy1-get1-marketing.model';\nimport {\n\tCardType,\n\tCoreAuthIdentityType,\n\tCouponType,\n\tMarketingType,\n\tOrderType,\n} from '../../../utilities/enum';\nimport { CustomCoupon } from './providers/custom-coupon.model';\nimport { DiscountMarketing } from './providers/discount-marketing.model';\nimport { FeaturedMarketing } from './providers/featured-marketing.model';\nimport { FreeDeliveryMarketing } from './providers/free-delivery-marketing.model';\nimport { GlobalCoupon } from './providers/global-coupon.model';\nimport { IndividualStoreCoupon } from './providers/individual-store-coupon.model';\nimport { IndividualUserCoupon } from './providers/individual-user-coupon.model';\nimport { LoyaltyPointMarketing } from './providers/loyalty-point-marketing.model';\nimport { PunchMarketing } from './providers/punch-marketing.model';\nimport { ReferralCodeCoupon } from './providers/referral-code-coupon.model';\nimport { ReferralRewardCoupon } from './providers/referral-reward-coupon.model';\nimport { Notification } from './notification.model';\nimport { CoreAuthIdentity } from './core-auth-identity.model';\nimport { CoreEmailAuthIdentity } from './providers/core-email-auth-identity.model';\nimport { CorePhoneAuthIdentity } from './providers/core-phone-auth-identity.model';\nimport { CoreGoogleAuthIdentity } from './providers/core-google-auth-identity.model';\nimport { CoreAppleAuthIdentity } from './providers/core-apple-auth-identity.model';\nimport { CoreUser } from './core-user.model';\nimport { Card } from './card.model';\nimport { AreebaCard } from './providers/areeba-card.model';\nimport { RiderTracking } from './rider-tracking.model';\nimport { Rider } from './rider.model';\nimport { RiderTimeout } from './rider-timeout.model';\nimport { User } from './user.model';\nimport { Cart } from './cart.model';\nimport { LineItem } from './line-item.model';\nimport { CartParticipant } from './cart-participant.model';\nimport { Gallery } from './gallery.model';\nimport { Order } from './order.model';\nimport { RegularOrder } from './providers/regular-order.model';\nimport { CourierOrder } from './providers/courier-order.model';\nimport { OrderDelivery } from './order-delivery.model';\nimport { FinanceSettlement } from './finance-settlement.model';\nimport { DefaultChat } from './default-chat.model';\nimport { TermsAndConditions } from './terms-and-conditions.model';\nimport { CancellationReason } from './cancellation-reason.model';\nimport { SupportReason } from './support-reason.model';\n\n\nexport const ActivityLogModel: ReturnModelType<typeof ActivityLog> = getModelForClass(ActivityLog);\nexport * from './activity-log.model';\n\nexport const AdminAccessControlModel: ReturnModelType<typeof AdminAccessControl> =\n\tgetModelForClass(AdminAccessControl);\nexport * from './admin-access-control.model';\n\nexport const AdminModel: ReturnModelType<typeof Admin> = getModelForClass(Admin);\nexport * from './admin.model';\n\nexport const UserAppSectionSettingModel: ReturnModelType<typeof UserAppSectionSetting> =\n\tgetModelForClass(UserAppSectionSetting);\nexport * from './user-app-section-setting.model';\n\nexport const AttributeModel: ReturnModelType<typeof Attribute> = getModelForClass(Attribute);\nexport * from './attribute.model';\n\nexport const BannerModel: ReturnModelType<typeof Banner> = getModelForClass(Banner);\nexport * from './banner.model';\n\nexport const BOBFinanceModel: ReturnModelType<typeof BOBFinance> = getModelForClass(BOBFinance);\nexport * from './bob-finance.model';\n\nexport const BrandModel: ReturnModelType<typeof Brand> = getModelForClass(Brand);\nexport * from './brand.model';\n\nexport const CardModel: ReturnModelType<typeof Card> = createGlobalModel(Card);\nexport const AreebaCardModel: ReturnModelType<typeof AreebaCard> = createGlobalDiscriminatorModel(\n\tCardModel,\n\tAreebaCard,\n\tCardType.AREEBA\n);\nexport * from './card.model';\nexport * from './providers/areeba-card.model';\n\nexport const CartModel: ReturnModelType<typeof Cart> = getModelForClass(Cart);\nexport * from './cart.model';\n\nexport const CartParticipantModel: ReturnModelType<typeof CartParticipant> =\n\tgetModelForClass(CartParticipant);\nexport * from './cart-participant.model';\n\nexport const CategoryModel: ReturnModelType<typeof Category> = getModelForClass(Category);\nexport * from './category.model';\n\nexport const CoreAuthIdentityModel: ReturnModelType<typeof CoreAuthIdentity> =\n\tcreateGlobalModel(CoreAuthIdentity);\nexport const CoreEmailAuthIdentityModel: ReturnModelType<typeof CoreEmailAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreEmailAuthIdentity, CoreAuthIdentityType.EMAIL);\nexport const CorePhoneAuthIdentityModel: ReturnModelType<typeof CorePhoneAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CorePhoneAuthIdentity, CoreAuthIdentityType.PHONE);\nexport const CoreGoogleAuthIdentityModel: ReturnModelType<typeof CoreGoogleAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreGoogleAuthIdentity, CoreAuthIdentityType.GOOGLE);\nexport const CoreAppleAuthIdentityModel: ReturnModelType<typeof CoreAppleAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreAppleAuthIdentity, CoreAuthIdentityType.APPLE);\nexport * from './core-auth-identity.model';\nexport * from './providers/core-apple-auth-identity.model';\nexport * from './providers/core-email-auth-identity.model';\nexport * from './providers/core-google-auth-identity.model';\nexport * from './providers/core-phone-auth-identity.model';\n\nexport const CoreUserModel: ReturnModelType<typeof CoreUser> = createGlobalModel(CoreUser);\nexport * from './core-user.model';\n\nexport const CounterModel: ReturnModelType<typeof Counter> = getModelForClass(Counter);\nexport * from './counter.model';\n\nexport const CouponModel: ReturnModelType<typeof Coupon> = getModelForClass(Coupon);\nexport const CustomCouponModel: ReturnModelType<typeof CustomCoupon> = getDiscriminatorModelForClass(\n\tCouponModel,\n\tCustomCoupon,\n\tCouponType.CUSTOM_COUPON\n);\nexport const GlobalCouponModel: ReturnModelType<typeof GlobalCoupon> = getDiscriminatorModelForClass(\n\tCouponModel,\n\tGlobalCoupon,\n\tCouponType.GLOBAL\n);\nexport const IndividualStoreCouponModel: ReturnModelType<typeof IndividualStoreCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, IndividualStoreCoupon, CouponType.INDIVIDUAL_STORE);\nexport const IndividualUserCouponModel: ReturnModelType<typeof IndividualUserCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, IndividualUserCoupon, CouponType.INDIVIDUAL_USER);\nexport const ReferralCodeCouponModel: ReturnModelType<typeof ReferralCodeCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ReferralCodeCoupon, CouponType.REFERRAL_CODE);\nexport const ReferralRewardCouponModel: ReturnModelType<typeof ReferralRewardCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ReferralRewardCoupon, CouponType.REFERRAL_REWARD);\nexport * from './coupon.model';\nexport * from './providers/custom-coupon.model';\nexport * from './providers/global-coupon.model';\nexport * from './providers/individual-store-coupon.model';\nexport * from './providers/individual-user-coupon.model';\nexport * from './providers/referral-code-coupon.model';\nexport * from './providers/referral-reward-coupon.model';\n\nexport const DealSettingModel: ReturnModelType<typeof DealSetting> = getModelForClass(DealSetting);\nexport * from './deal-setting.model';\n\nexport const DishModel: ReturnModelType<typeof Dish> = getModelForClass(Dish);\nexport * from './dish.model';\n\nexport const FaqModel: ReturnModelType<typeof Faq> = getModelForClass(Faq);\nexport * from './faq.model';\n\nexport const FavouriteModel: ReturnModelType<typeof Favourite> = getModelForClass(Favourite);\nexport * from './favourite.model';\n\nexport const FeaturedSettingModel: ReturnModelType<typeof FeaturedSetting> =\n\tgetModelForClass(FeaturedSetting);\nexport * from './featured-setting.model';\n\nexport const FilterContainerModel: ReturnModelType<typeof FilterContainer> =\n\tgetModelForClass(FilterContainer);\nexport * from './filter-container.model';\n\nexport const FinanceSettlementModel: ReturnModelType<typeof FinanceSettlement> =\n\tgetModelForClass(FinanceSettlement);\nexport * from './finance-settlement.model';\n\nexport const GalleryModel: ReturnModelType<typeof Gallery> = getModelForClass(Gallery);\nexport * from './gallery.model';\n\nexport const LineItemModel: ReturnModelType<typeof LineItem> = getModelForClass(LineItem);\nexport * from './line-item.model';\n\nexport const ListContainerModel: ReturnModelType<typeof ListContainer> = getModelForClass(ListContainer);\nexport * from './list-container.model';\n\nexport const LoyaltyPointCategoryModel: ReturnModelType<typeof LoyaltyPointCategory> =\n\tgetModelForClass(LoyaltyPointCategory);\nexport * from './loyalty-point-category.model';\n\nexport const LoyaltyPointSettingModel: ReturnModelType<typeof LoyaltyPointSetting> =\n\tgetModelForClass(LoyaltyPointSetting);\nexport * from './loyalty-point-setting.model';\n\nexport const MarketingModel: ReturnModelType<typeof Marketing> = getModelForClass(Marketing);\nexport const Buy1Get1MarketingModel: ReturnModelType<typeof Buy1Get1Marketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, Buy1Get1Marketing, MarketingType.BUY1GET1);\nexport const DiscountMarketingModel: ReturnModelType<typeof DiscountMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, DiscountMarketing, MarketingType.DISCOUNT);\nexport const FeaturedMarketingModel: ReturnModelType<typeof FeaturedMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, FeaturedMarketing, MarketingType.FEATURED);\nexport const FreeDeliveryMarketingModel: ReturnModelType<typeof FreeDeliveryMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, FreeDeliveryMarketing, MarketingType.FREE_DELIVERY);\nexport const LoyaltyPointMarketingModel: ReturnModelType<typeof LoyaltyPointMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, LoyaltyPointMarketing, MarketingType.LOYALTY_POINT);\nexport const PunchMarketingModel: ReturnModelType<typeof PunchMarketing> = getDiscriminatorModelForClass(\n\tMarketingModel,\n\tPunchMarketing,\n\tMarketingType.PUNCH_MARKETING\n);\nexport * from './marketing.model';\nexport * from './providers/buy1-get1-marketing.model';\nexport * from './providers/discount-marketing.model';\nexport * from './providers/featured-marketing.model';\nexport * from './providers/free-delivery-marketing.model';\nexport * from './providers/loyalty-point-marketing.model';\nexport * from './providers/punch-marketing.model';\n\nexport const MealPlanModel: ReturnModelType<typeof MealPlan> = getModelForClass(MealPlan);\nexport * from './meal-plan.model';\n\nexport const NotificationModel: ReturnModelType<typeof Notification> = getModelForClass(Notification);\nexport * from './notification.model';\n\nexport const NutritionModel: ReturnModelType<typeof Nutrition> = getModelForClass(Nutrition);\nexport * from './nutrition.model';\n\nexport const OrderModel: ReturnModelType<typeof Order> = getModelForClass(Order);\nexport const RegularOrderModel: ReturnModelType<typeof RegularOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tRegularOrder,\n\tOrderType.REGULAR\n);\nexport const CourierOrderModel: ReturnModelType<typeof CourierOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tCourierOrder,\n\tOrderType.COURIER\n);\nexport * from './order.model';\nexport * from './providers/regular-order.model';\nexport * from './providers/courier-order.model';\n\nexport const OrderDeliveryModel: ReturnModelType<typeof OrderDelivery> = getModelForClass(OrderDelivery);\nexport * from './order-delivery.model';\n\nexport const ParentModel: ReturnModelType<typeof Parent> = getModelForClass(Parent);\nexport * from './parent.model';\n\nexport const ProductMarketingModel: ReturnModelType<typeof ProductMarketing> =\n\tgetModelForClass(ProductMarketing);\nexport * from './product-marketing.model';\n\nexport const ProductModel: ReturnModelType<typeof Product> = getModelForClass(Product);\nexport * from './product.model';\n\nexport const PunchMarketingHistoryModel: ReturnModelType<typeof PunchMarketingHistory> =\n\tgetModelForClass(PunchMarketingHistory);\nexport * from './punch-marketing-history.model';\n\nexport const RatingSettingModel: ReturnModelType<typeof RatingSetting> = getModelForClass(RatingSetting);\nexport * from './rating-setting.model';\n\nexport const ReferralSettingModel: ReturnModelType<typeof ReferralSetting> =\n\tgetModelForClass(ReferralSetting);\nexport * from './referral-setting.model';\n\nexport const RequestAreaModel: ReturnModelType<typeof RequestArea> = getModelForClass(RequestArea);\nexport * from './request-area.model';\n\nexport const RiderReviewModel: ReturnModelType<typeof RiderReview> = getModelForClass(RiderReview);\nexport * from './rider-review.model';\n\nexport const RiderTimeoutModel: ReturnModelType<typeof RiderTimeout> = getModelForClass(RiderTimeout);\nexport * from './rider-timeout.model';\n\nexport const RiderTrackingModel: ReturnModelType<typeof RiderTracking> = getModelForClass(RiderTracking);\nexport * from './rider-tracking.model';\n\nexport const RiderModel: ReturnModelType<typeof Rider> = getModelForClass(Rider);\nexport * from './rider.model';\n\nexport const RoleModel: ReturnModelType<typeof Role> = createGlobalModel(Role);\nexport * from './role.model';\n\nexport const SettingModel: ReturnModelType<typeof Setting> = getModelForClass(Setting);\nexport * from './setting.model';\n\nexport const ShopAccessControlModel: ReturnModelType<typeof ShopAccessControl> =\n\tgetModelForClass(ShopAccessControl);\nexport * from './shop-access-control.model';\n\nexport const ShopCategoryModel: ReturnModelType<typeof ShopCategory> = getModelForClass(ShopCategory);\nexport * from './shop-category.model';\n\nexport const ShopMealPlanModel: ReturnModelType<typeof ShopMealPlan> = getModelForClass(ShopMealPlan);\nexport * from './shop-meal-plan.model';\n\nexport const ShopReviewModel: ReturnModelType<typeof ShopReview> = getModelForClass(ShopReview);\nexport * from './shop-review.model';\n\nexport const ShopModel: ReturnModelType<typeof Shop> = getModelForClass(Shop);\nexport * from './shop.model';\n\nexport const SubscriptionSettingModel: ReturnModelType<typeof SubscriptionSetting> =\n\tgetModelForClass(SubscriptionSetting);\nexport * from './subscription-setting.model';\n\nexport const SubscriptionModel: ReturnModelType<typeof Subscription> = getModelForClass(Subscription);\nexport * from './subscription.model';\n\nexport const TagModel: ReturnModelType<typeof Tag> = getModelForClass(Tag);\nexport * from './tag.model';\n\nexport const UserModel: ReturnModelType<typeof User> = getModelForClass(User);\nexport * from './user.model';\n\nexport const ZoneModel: ReturnModelType<typeof Zone> = getModelForClass(Zone);\nexport * from './zone.model';\n\n\nexport const DefaultChatModel: ReturnModelType <typeof DefaultChat> = getModelForClass(DefaultChat);\nexport * from './default-chat.model';\n\nexport const TermsAndConditionsModel: ReturnModelType<typeof TermsAndConditions> = getModelForClass(TermsAndConditions);\nexport * from './terms-and-conditions.model';\n\nexport const SupportReasonModel: ReturnModelType<typeof SupportReason> = getModelForClass(SupportReason)\nexport * from './support-reason.model';\n\nexport const CancellationReasonModel: ReturnModelType<typeof CancellationReason> = getModelForClass(CancellationReason);\nexport * from './cancellation-reason.model';"]}
|
|
@@ -3,10 +3,12 @@ import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
|
|
|
3
3
|
import { OrderType } from '../../../utilities/enum';
|
|
4
4
|
import { OrderCancel } from './embedded/order-cancel.model';
|
|
5
5
|
import { User } from './user.model';
|
|
6
|
+
import { Rider } from './rider.model';
|
|
6
7
|
export declare class Order extends TimeStamps {
|
|
7
8
|
orderId: string;
|
|
8
9
|
orderType?: OrderType;
|
|
9
10
|
user: Ref<User>;
|
|
11
|
+
rider?: Ref<Rider>;
|
|
10
12
|
instruction?: string;
|
|
11
13
|
note?: string;
|
|
12
14
|
scheduledFor?: Date;
|
|
@@ -15,10 +15,12 @@ const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
|
15
15
|
const enum_1 = require("../../../utilities/enum");
|
|
16
16
|
const order_cancel_model_1 = require("./embedded/order-cancel.model");
|
|
17
17
|
const user_model_1 = require("./user.model");
|
|
18
|
+
const rider_model_1 = require("./rider.model");
|
|
18
19
|
let Order = class Order extends defaultClasses_1.TimeStamps {
|
|
19
20
|
orderId;
|
|
20
21
|
orderType;
|
|
21
22
|
user;
|
|
23
|
+
rider;
|
|
22
24
|
instruction;
|
|
23
25
|
note;
|
|
24
26
|
scheduledFor;
|
|
@@ -39,6 +41,10 @@ __decorate([
|
|
|
39
41
|
(0, typegoose_1.prop)({ required: true, ref: () => user_model_1.User }),
|
|
40
42
|
__metadata("design:type", Object)
|
|
41
43
|
], Order.prototype, "user", void 0);
|
|
44
|
+
__decorate([
|
|
45
|
+
(0, typegoose_1.prop)({ ref: () => rider_model_1.Rider, index: true }),
|
|
46
|
+
__metadata("design:type", Object)
|
|
47
|
+
], Order.prototype, "rider", void 0);
|
|
42
48
|
__decorate([
|
|
43
49
|
(0, typegoose_1.prop)({ type: String }),
|
|
44
50
|
__metadata("design:type", String)
|
|
@@ -76,7 +82,6 @@ exports.Order = Order = __decorate([
|
|
|
76
82
|
(0, typegoose_1.index)({ createdAt: -1 }),
|
|
77
83
|
(0, typegoose_1.index)({ orderStatus: 1, createdAt: -1 }),
|
|
78
84
|
(0, typegoose_1.index)({ user: 1, createdAt: -1 }),
|
|
79
|
-
(0, typegoose_1.index)({ shop: 1, orderStatus: 1 }),
|
|
80
85
|
(0, typegoose_1.index)({ rider: 1, orderStatus: 1 })
|
|
81
86
|
], Order);
|
|
82
87
|
//# sourceMappingURL=order.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"order.model.js","sourceRoot":"/","sources":["libraries/mongo/models/order.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAgF;AAChF,4EAAqE;AACrE,kDAAoD;AACpD,sEAA4D;AAC5D,6CAAoC;
|
|
1
|
+
{"version":3,"file":"order.model.js","sourceRoot":"/","sources":["libraries/mongo/models/order.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAgF;AAChF,4EAAqE;AACrE,kDAAoD;AACpD,sEAA4D;AAC5D,6CAAoC;AACpC,+CAAsC;AAe/B,IAAM,KAAK,GAAX,MAAM,KAAM,SAAQ,2BAAU;IAE7B,OAAO,CAAS;IAGhB,SAAS,CAAa;IAGtB,IAAI,CAAY;IAGhB,KAAK,CAAc;IAGnB,WAAW,CAAU;IAGrB,IAAI,CAAU;IAGd,YAAY,CAAQ;IAGpB,WAAW,CAAe;IAG1B,WAAW,CAAW;IAGtB,aAAa,CAAW;CAC/B,CAAA;AA9BY,sBAAK;AAEV;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;;sCAC9B;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,gBAAS,EAAE,OAAO,EAAE,gBAAS,CAAC,OAAO,EAAE,CAAC;;wCACvC;AAGtB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EA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AE,SAAS,EAAE,CAAC,CAAC,EAAE,CAAC;IACjC,IAAA,iBAAK,EAAC,EAAE,KAAK,EAAE,CAAC,EAAE,WAAW,EAAE,CAAC,EAAE,CAAC;GACvB,KAAK,CA8BjB","sourcesContent":["import { prop, Ref, modelOptions, index, Severity } from '@typegoose/typegoose';\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\nimport { OrderType } from '../../../utilities/enum';\nimport { OrderCancel } from './embedded/order-cancel.model';\nimport { User } from './user.model';\nimport { Rider } from './rider.model';\n\n@modelOptions({\n\tschemaOptions: {\n\t\tcollection: 'orders',\n\t\tdiscriminatorKey: 'orderType',\n\t\ttoJSON: { virtuals: true },\n\t\ttoObject: { virtuals: true },\n\t},\n\toptions: { allowMixed: Severity.ALLOW },\n})\n@index({ createdAt: -1 })\n@index({ orderStatus: 1, createdAt: -1 })\n@index({ user: 1, createdAt: -1 })\n@index({ rider: 1, orderStatus: 1 })\nexport class Order extends TimeStamps {\n\t@prop({ required: true, type: String, unique: true })\n\tpublic orderId: string;\n\n\t@prop({ type: String, enum: OrderType, default: OrderType.REGULAR })\n\tpublic orderType?: OrderType;\n\n\t@prop({ required: true, ref: () => User })\n\tpublic user: Ref<User>;\n\n\t@prop({ ref: () => Rider, index: true })\n\tpublic rider?: Ref<Rider>;\n\t\n\t@prop({ type: String })\n\tpublic instruction?: string;\n\n\t@prop({ type: String })\n\tpublic note?: string;\n\n\t@prop({ type: Date })\n\tpublic scheduledFor?: Date;\n\n\t@prop({ type: () => OrderCancel })\n\tpublic orderCancel?: OrderCancel;\n\n\t@prop({ type: Boolean, default: false })\n\tpublic isLateOrder?: boolean;\n\n\t@prop({ type: Boolean, default: false })\n\tpublic isUrgentOrder?: boolean;\n}\n"]}
|
|
@@ -2,6 +2,7 @@ import { Order } from '../order.model';
|
|
|
2
2
|
import { CourierOrderStatus, CourierServiceType, OrderType } from '../../../../utilities/enum';
|
|
3
3
|
import { CourierAddress } from '../shared/address.model';
|
|
4
4
|
import { CourierOrderStatusTimeline } from '../embedded/status-timeline.model';
|
|
5
|
+
import { CourierOrderFinance } from '../embedded/courier-order-finance.model';
|
|
5
6
|
declare class CourierItem {
|
|
6
7
|
productName: string;
|
|
7
8
|
productImage?: string;
|
|
@@ -19,5 +20,6 @@ export declare class CourierOrder extends Order {
|
|
|
19
20
|
pickupAddress: CourierAddress;
|
|
20
21
|
deliveryAddress: CourierAddress;
|
|
21
22
|
items?: CourierItem[];
|
|
23
|
+
finance: CourierOrderFinance;
|
|
22
24
|
}
|
|
23
25
|
export {};
|
|
@@ -15,6 +15,7 @@ const order_model_1 = require("../order.model");
|
|
|
15
15
|
const enum_1 = require("../../../../utilities/enum");
|
|
16
16
|
const address_model_1 = require("../shared/address.model");
|
|
17
17
|
const status_timeline_model_1 = require("../embedded/status-timeline.model");
|
|
18
|
+
const courier_order_finance_model_1 = require("../embedded/courier-order-finance.model");
|
|
18
19
|
class CourierItem {
|
|
19
20
|
productName;
|
|
20
21
|
productImage;
|
|
@@ -60,6 +61,7 @@ class CourierOrder extends order_model_1.Order {
|
|
|
60
61
|
pickupAddress;
|
|
61
62
|
deliveryAddress;
|
|
62
63
|
items;
|
|
64
|
+
finance;
|
|
63
65
|
}
|
|
64
66
|
exports.CourierOrder = CourierOrder;
|
|
65
67
|
__decorate([
|
|
@@ -86,4 +88,8 @@ __decorate([
|
|
|
86
88
|
(0, typegoose_1.prop)({ type: () => [CourierItem], default: [] }),
|
|
87
89
|
__metadata("design:type", Array)
|
|
88
90
|
], CourierOrder.prototype, "items", void 0);
|
|
91
|
+
__decorate([
|
|
92
|
+
(0, typegoose_1.prop)({ required: true, type: courier_order_finance_model_1.CourierOrderFinance }),
|
|
93
|
+
__metadata("design:type", courier_order_finance_model_1.CourierOrderFinance)
|
|
94
|
+
], CourierOrder.prototype, "finance", void 0);
|
|
89
95
|
//# sourceMappingURL=courier-order.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"courier-order.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/courier-order.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,gDAAuC;AACvC,qDAA+F;AAC/F,2DAAyD;AACzD,6EAA+E;
|
|
1
|
+
{"version":3,"file":"courier-order.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/courier-order.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,gDAAuC;AACvC,qDAA+F;AAC/F,2DAAyD;AACzD,6EAA+E;AAC/E,yFAA8E;AAE9E,MAAM,WAAW;IAET,WAAW,CAAS;IAGpB,YAAY,CAAU;IAGtB,QAAQ,CAAS;IAGjB,SAAS,CAAU;IAGnB,kBAAkB,CAAU;IAG5B,UAAU,CAAU;IAGpB,mBAAmB,CAAU;CACpC;AAnBO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;gDACE;AAGpB;IADN,IAAA,gBAAI,GAAE;;iDACsB;AAGtB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;6CACT;AAGjB;IADN,IAAA,gBAAI,GAAE;;8CACmB;AAGnB;IADN,IAAA,gBAAI,GAAE;;uDAC4B;AAG5B;IADN,IAAA,gBAAI,GAAE;;+CACoB;AAGpB;IADN,IAAA,gBAAI,GAAE;;wDAC6B;AAGrC,MAAa,YAAa,SAAQ,mBAAK;IAC/B,SAAS,GAAG,gBAAS,CAAC,OAAgB,CAAC;IAGvC,MAAM,CAAsB;IAG5B,cAAc,CAA+B;IAG7C,WAAW,CAAsB;IAGjC,aAAa,CAAkB;IAG/B,eAAe,CAAkB;IAGjC,KAAK,CAAiB;IAGtB,OAAO,CAAsB;CACpC;AAvBD,oCAuBC;AAnBO;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,yBAAkB,EAAE,OAAO,EAAE,yBAAkB,CAAC,MAAM,EAAE,CAAC;;4CAClD;AAG5B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,kDAA0B,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;oDACZ;AAG7C;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,yBAAkB,EAAE,CAAC;;iDACzB;AAGjC;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,8BAAc,EAAE,CAAC;8BAC9B,8BAAc;mDAAC;AAG/B;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,8BAAc,EAAE,CAAC;8BACtB,8BAAc;qDAAC;AAGjC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,WAAW,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;2CACpB;AAGtB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,iDAAmB,EAAE,CAAC;8BACpC,iDAAmB;6CAAC","sourcesContent":["import { prop } from '@typegoose/typegoose';\nimport { Order } from '../order.model';\nimport { CourierOrderStatus, CourierServiceType, OrderType } from '../../../../utilities/enum';\nimport { CourierAddress } from '../shared/address.model';\nimport { CourierOrderStatusTimeline } from '../embedded/status-timeline.model';\nimport { CourierOrderFinance } from '../embedded/courier-order-finance.model';\n\nclass CourierItem {\n\t@prop({ required: true })\n\tpublic productName: string;\n\n\t@prop()\n\tpublic productImage?: string;\n\n\t@prop({ required: true, min: 1 })\n\tpublic quantity: number;\n\n\t@prop()\n\tpublic unitPrice?: number;\n\n\t@prop()\n\tpublic secondaryUnitPrice?: number;\n\n\t@prop()\n\tpublic totalPrice?: number;\n\n\t@prop()\n\tpublic secondaryTotalPrice?: number;\n}\n\nexport class CourierOrder extends Order {\n\tpublic orderType = OrderType.COURIER as const;\n\n\t@prop({ type: String, enum: CourierOrderStatus, default: CourierOrderStatus.PLACED })\n\tpublic status?: CourierOrderStatus;\n\n\t@prop({ type: () => [CourierOrderStatusTimeline], default: [] })\n\tpublic statusTimeline: CourierOrderStatusTimeline[];\n\n\t@prop({ required: true, type: String, enum: CourierServiceType })\n\tpublic courierType!: CourierServiceType;\n\n\t@prop({ required: true, type: () => CourierAddress })\n\tpublic pickupAddress!: CourierAddress;\n\n\t@prop({ required: true, type: CourierAddress })\n\tpublic deliveryAddress!: CourierAddress;\n\n\t@prop({ type: () => [CourierItem], default: [] })\n\tpublic items?: CourierItem[];\n\n\t@prop({ required: true, type: CourierOrderFinance })\n\tpublic finance: CourierOrderFinance;\n}\n"]}
|
|
@@ -7,6 +7,7 @@ import { Cart } from '../cart.model';
|
|
|
7
7
|
import { Address, UserAddress } from '../shared/address.model';
|
|
8
8
|
import { RegularOrderStatusTimeline } from '../embedded/status-timeline.model';
|
|
9
9
|
import { OrderRefund } from '../embedded/order-refund.model';
|
|
10
|
+
import { RegularOrderFinance } from '../embedded/regular-order-finance.model';
|
|
10
11
|
export declare class RegularOrder extends Order {
|
|
11
12
|
orderType: OrderType.REGULAR;
|
|
12
13
|
status?: string;
|
|
@@ -23,4 +24,5 @@ export declare class RegularOrder extends Order {
|
|
|
23
24
|
originalOrderForReplacement?: Ref<Order>;
|
|
24
25
|
isRefunded?: boolean;
|
|
25
26
|
refundInformation?: OrderRefund;
|
|
27
|
+
finance: RegularOrderFinance;
|
|
26
28
|
}
|
|
@@ -19,6 +19,7 @@ const cart_model_1 = require("../cart.model");
|
|
|
19
19
|
const address_model_1 = require("../shared/address.model");
|
|
20
20
|
const status_timeline_model_1 = require("../embedded/status-timeline.model");
|
|
21
21
|
const order_refund_model_1 = require("../embedded/order-refund.model");
|
|
22
|
+
const regular_order_finance_model_1 = require("../embedded/regular-order-finance.model");
|
|
22
23
|
class RegularOrder extends order_model_1.Order {
|
|
23
24
|
orderType = enum_1.OrderType.REGULAR;
|
|
24
25
|
status;
|
|
@@ -35,6 +36,7 @@ class RegularOrder extends order_model_1.Order {
|
|
|
35
36
|
originalOrderForReplacement;
|
|
36
37
|
isRefunded;
|
|
37
38
|
refundInformation;
|
|
39
|
+
finance;
|
|
38
40
|
}
|
|
39
41
|
exports.RegularOrder = RegularOrder;
|
|
40
42
|
__decorate([
|
|
@@ -93,4 +95,8 @@ __decorate([
|
|
|
93
95
|
(0, typegoose_1.prop)({ type: order_refund_model_1.OrderRefund }),
|
|
94
96
|
__metadata("design:type", order_refund_model_1.OrderRefund)
|
|
95
97
|
], RegularOrder.prototype, "refundInformation", void 0);
|
|
98
|
+
__decorate([
|
|
99
|
+
(0, typegoose_1.prop)({ required: true, type: regular_order_finance_model_1.RegularOrderFinance }),
|
|
100
|
+
__metadata("design:type", regular_order_finance_model_1.RegularOrderFinance)
|
|
101
|
+
], RegularOrder.prototype, "finance", void 0);
|
|
96
102
|
//# sourceMappingURL=regular-order.model.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"regular-order.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/regular-order.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiD;AACjD,gDAAuC;AACvC,qDAAqF;AACrF,kDAAyC;AACzC,8CAAqC;AACrC,8CAAqC;AACrC,2DAA+D;AAC/D,6EAA+E;AAC/E,uEAA6D;
|
|
1
|
+
{"version":3,"file":"regular-order.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/regular-order.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiD;AACjD,gDAAuC;AACvC,qDAAqF;AACrF,kDAAyC;AACzC,8CAAqC;AACrC,8CAAqC;AACrC,2DAA+D;AAC/D,6EAA+E;AAC/E,uEAA6D;AAC7D,yFAA8E;AAE9E,MAAa,YAAa,SAAQ,mBAAK;IAC/B,SAAS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;;0CAClB;AAGjB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,iBAAI,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;;0CAChC;AAGjB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;;oDACR;AAGzB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;;4DACI;AAGhC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;;wDACJ;AAG7B;IADN,IAAA,gBAAI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,mBAAK,EAAE,CAAC;;iEACqB;AAGzC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;;gDACZ;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,gCAAW,EAAE,CAAC;8BACD,gCAAW;uDAAC;AAGhC;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,iDAAmB,EAAE,CAAC;8BACpC,iDAAmB;6CAAC","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\nimport { Order } from '../order.model';\nimport { ItemType, OrderType, RegularOrderStatus } from '../../../../utilities/enum';\nimport { Parent } from '../parent.model';\nimport { Shop } from '../shop.model';\nimport { Cart } from '../cart.model';\nimport { Address, UserAddress } from '../shared/address.model';\nimport { RegularOrderStatusTimeline } from '../embedded/status-timeline.model';\nimport { OrderRefund } from '../embedded/order-refund.model';\nimport { RegularOrderFinance } from '../embedded/regular-order-finance.model';\n\nexport class RegularOrder extends Order {\n\tpublic orderType = OrderType.REGULAR as const;\n\n\t@prop({ type: String, enum: RegularOrderStatus, default: RegularOrderStatus.PLACED })\n\tpublic status?: string;\n\n\t@prop({ type: () => [RegularOrderStatusTimeline], default: [] })\n\tpublic statusTimeline: RegularOrderStatusTimeline[];\n\n\t@prop({ type: String, enum: ItemType, default: ItemType.FOOD })\n\tpublic itemType?: string;\n\n\t@prop({ required: true, type: Address })\n\tpublic pickupAddress: Address;\n\n\t@prop({ required: true, type: UserAddress })\n\tpublic deliveryAddress: UserAddress;\n\n\t@prop({ required: true, ref: () => Parent })\n\tpublic parent!: Ref<Parent>;\n\n\t@prop({ required: true, ref: () => Shop })\n\tpublic shop!: Ref<Shop>;\n\n\t@prop({ required: true, ref: () => Cart, unique: true })\n\tpublic cart!: Ref<Cart>;\n\n\t@prop({ type: Boolean, default: false })\n\tpublic isShopDelivery?: boolean;\n\n\t@prop({ type: Number, default: 0 })\n\tpublic preparingTimeInMinutes?: number;\n\n\t@prop({ type: Boolean, default: false })\n\tpublic isReplacementOrder?: boolean;\n\n\t@prop({ ref: () => Order })\n\tpublic originalOrderForReplacement?: Ref<Order>;\n\n\t@prop({ type: Boolean, default: false })\n\tpublic isRefunded?: boolean;\n\n\t@prop({ type: OrderRefund })\n\tpublic refundInformation?: OrderRefund;\n\n\t@prop({ required: true, type: RegularOrderFinance })\n\tpublic finance: RegularOrderFinance;\n}\n"]}
|
|
@@ -10,13 +10,15 @@ import { Tag } from './tag.model';
|
|
|
10
10
|
import { Zone } from './zone.model';
|
|
11
11
|
import { DeliveryInfo } from './embedded/delivery-info.model';
|
|
12
12
|
export declare class Shop extends TimeStamps {
|
|
13
|
-
slug: string;
|
|
14
|
-
parent: Ref<Parent>;
|
|
15
|
-
itemType: ItemType;
|
|
16
13
|
name: string;
|
|
17
|
-
brand: Ref<Brand>;
|
|
18
14
|
ownerName: string;
|
|
19
15
|
email: string;
|
|
16
|
+
slug?: string;
|
|
17
|
+
parent: Ref<Parent>;
|
|
18
|
+
itemType: ItemType;
|
|
19
|
+
status: Status;
|
|
20
|
+
brand: Ref<Brand>;
|
|
21
|
+
priceRange?: number;
|
|
20
22
|
phoneNumber: string;
|
|
21
23
|
userPhoneNumber: string;
|
|
22
24
|
additionalPhoneNumbers?: string[];
|
|
@@ -25,28 +27,26 @@ export declare class Shop extends TimeStamps {
|
|
|
25
27
|
logo?: string;
|
|
26
28
|
banner?: string;
|
|
27
29
|
document?: ShopDocument;
|
|
28
|
-
isBeirutAuthentic: boolean;
|
|
29
|
-
isVisibleToUser: boolean;
|
|
30
|
-
status: Status;
|
|
31
30
|
onlineStatus?: ShopOnlineStatus;
|
|
32
|
-
|
|
33
|
-
isRiderNoteVisible?: boolean;
|
|
34
|
-
riderNote?: string;
|
|
35
|
-
priceRange?: number;
|
|
31
|
+
workHourSetting?: WorkHourSetting;
|
|
36
32
|
dietaries?: string[];
|
|
37
33
|
tags?: Ref<Tag>[];
|
|
34
|
+
isBeirutAuthentic: boolean;
|
|
35
|
+
isVisibleToUser: boolean;
|
|
38
36
|
isShopDelivery?: boolean;
|
|
39
37
|
deliveryFee?: number;
|
|
40
38
|
minimumOrderAmount?: number;
|
|
41
39
|
orderCapacity?: number;
|
|
40
|
+
shopActiveTimingsOfCurrentDate?: StartEndTime[];
|
|
41
|
+
deliveryInfo?: DeliveryInfo;
|
|
42
|
+
sortingOrder?: number;
|
|
43
|
+
allowSpecialInstructions?: boolean;
|
|
44
|
+
isRiderNoteVisible?: boolean;
|
|
45
|
+
riderNote?: string;
|
|
42
46
|
defaultPreparationTime?: number;
|
|
43
47
|
exchangeRate?: number;
|
|
44
|
-
workHourSetting?: WorkHourSetting;
|
|
45
|
-
shopActiveTimingsOfCurrentDate?: StartEndTime[];
|
|
46
48
|
isFavouriteCategoryVisible?: boolean;
|
|
47
49
|
favouriteCategoryTitle?: string;
|
|
48
50
|
isBestSellerCategoryVisible?: boolean;
|
|
49
51
|
bestSellerCategoryTitle?: string;
|
|
50
|
-
deliveryInfo?: DeliveryInfo;
|
|
51
|
-
sortingOrder?: number;
|
|
52
52
|
}
|
|
@@ -8,6 +8,9 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
8
8
|
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
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
+
};
|
|
11
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
15
|
exports.Shop = void 0;
|
|
13
16
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
@@ -22,14 +25,17 @@ const tag_model_1 = require("./tag.model");
|
|
|
22
25
|
const zone_model_1 = require("./zone.model");
|
|
23
26
|
const delivery_info_model_1 = require("./embedded/delivery-info.model");
|
|
24
27
|
const _1 = require(".");
|
|
28
|
+
const slugify_1 = __importDefault(require("slugify"));
|
|
25
29
|
let Shop = class Shop extends defaultClasses_1.TimeStamps {
|
|
30
|
+
name;
|
|
31
|
+
ownerName;
|
|
32
|
+
email;
|
|
26
33
|
slug;
|
|
27
34
|
parent;
|
|
28
35
|
itemType;
|
|
29
|
-
|
|
36
|
+
status;
|
|
30
37
|
brand;
|
|
31
|
-
|
|
32
|
-
email;
|
|
38
|
+
priceRange;
|
|
33
39
|
phoneNumber;
|
|
34
40
|
userPhoneNumber;
|
|
35
41
|
additionalPhoneNumbers;
|
|
@@ -38,34 +44,44 @@ let Shop = class Shop extends defaultClasses_1.TimeStamps {
|
|
|
38
44
|
logo;
|
|
39
45
|
banner;
|
|
40
46
|
document;
|
|
41
|
-
isBeirutAuthentic;
|
|
42
|
-
isVisibleToUser;
|
|
43
|
-
status;
|
|
44
47
|
onlineStatus;
|
|
45
|
-
|
|
46
|
-
isRiderNoteVisible;
|
|
47
|
-
riderNote;
|
|
48
|
-
priceRange;
|
|
48
|
+
workHourSetting;
|
|
49
49
|
dietaries;
|
|
50
50
|
tags;
|
|
51
|
+
isBeirutAuthentic;
|
|
52
|
+
isVisibleToUser;
|
|
51
53
|
isShopDelivery;
|
|
52
54
|
deliveryFee;
|
|
53
55
|
minimumOrderAmount;
|
|
54
56
|
orderCapacity;
|
|
57
|
+
shopActiveTimingsOfCurrentDate;
|
|
58
|
+
deliveryInfo;
|
|
59
|
+
sortingOrder;
|
|
60
|
+
allowSpecialInstructions;
|
|
61
|
+
isRiderNoteVisible;
|
|
62
|
+
riderNote;
|
|
55
63
|
defaultPreparationTime;
|
|
56
64
|
exchangeRate;
|
|
57
|
-
workHourSetting;
|
|
58
|
-
shopActiveTimingsOfCurrentDate;
|
|
59
65
|
isFavouriteCategoryVisible;
|
|
60
66
|
favouriteCategoryTitle;
|
|
61
67
|
isBestSellerCategoryVisible;
|
|
62
68
|
bestSellerCategoryTitle;
|
|
63
|
-
deliveryInfo;
|
|
64
|
-
sortingOrder;
|
|
65
69
|
};
|
|
66
70
|
exports.Shop = Shop;
|
|
67
71
|
__decorate([
|
|
68
|
-
(0, typegoose_1.prop)({ required: true,
|
|
72
|
+
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
73
|
+
__metadata("design:type", String)
|
|
74
|
+
], Shop.prototype, "name", void 0);
|
|
75
|
+
__decorate([
|
|
76
|
+
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
77
|
+
__metadata("design:type", String)
|
|
78
|
+
], Shop.prototype, "ownerName", void 0);
|
|
79
|
+
__decorate([
|
|
80
|
+
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
81
|
+
__metadata("design:type", String)
|
|
82
|
+
], Shop.prototype, "email", void 0);
|
|
83
|
+
__decorate([
|
|
84
|
+
(0, typegoose_1.prop)({ unique: true, type: String }),
|
|
69
85
|
__metadata("design:type", String)
|
|
70
86
|
], Shop.prototype, "slug", void 0);
|
|
71
87
|
__decorate([
|
|
@@ -77,21 +93,17 @@ __decorate([
|
|
|
77
93
|
__metadata("design:type", String)
|
|
78
94
|
], Shop.prototype, "itemType", void 0);
|
|
79
95
|
__decorate([
|
|
80
|
-
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
96
|
+
(0, typegoose_1.prop)({ required: true, type: String, enum: enum_1.Status, default: enum_1.Status.ACTIVE }),
|
|
81
97
|
__metadata("design:type", String)
|
|
82
|
-
], Shop.prototype, "
|
|
98
|
+
], Shop.prototype, "status", void 0);
|
|
83
99
|
__decorate([
|
|
84
100
|
(0, typegoose_1.prop)({ required: true, ref: () => brand_model_1.Brand }),
|
|
85
101
|
__metadata("design:type", Object)
|
|
86
102
|
], Shop.prototype, "brand", void 0);
|
|
87
103
|
__decorate([
|
|
88
|
-
(0, typegoose_1.prop)({
|
|
89
|
-
__metadata("design:type",
|
|
90
|
-
], Shop.prototype, "
|
|
91
|
-
__decorate([
|
|
92
|
-
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
93
|
-
__metadata("design:type", String)
|
|
94
|
-
], Shop.prototype, "email", void 0);
|
|
104
|
+
(0, typegoose_1.prop)({ type: Number, default: 1, min: 1, max: 4 }),
|
|
105
|
+
__metadata("design:type", Number)
|
|
106
|
+
], Shop.prototype, "priceRange", void 0);
|
|
95
107
|
__decorate([
|
|
96
108
|
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
97
109
|
__metadata("design:type", String)
|
|
@@ -124,18 +136,6 @@ __decorate([
|
|
|
124
136
|
(0, typegoose_1.prop)({ type: shop_document_model_1.ShopDocument }),
|
|
125
137
|
__metadata("design:type", shop_document_model_1.ShopDocument)
|
|
126
138
|
], Shop.prototype, "document", void 0);
|
|
127
|
-
__decorate([
|
|
128
|
-
(0, typegoose_1.prop)({ required: true, type: Boolean }),
|
|
129
|
-
__metadata("design:type", Boolean)
|
|
130
|
-
], Shop.prototype, "isBeirutAuthentic", void 0);
|
|
131
|
-
__decorate([
|
|
132
|
-
(0, typegoose_1.prop)({ required: true, type: Boolean }),
|
|
133
|
-
__metadata("design:type", Boolean)
|
|
134
|
-
], Shop.prototype, "isVisibleToUser", void 0);
|
|
135
|
-
__decorate([
|
|
136
|
-
(0, typegoose_1.prop)({ required: true, type: String, enum: enum_1.Status, default: enum_1.Status.ACTIVE }),
|
|
137
|
-
__metadata("design:type", String)
|
|
138
|
-
], Shop.prototype, "status", void 0);
|
|
139
139
|
__decorate([
|
|
140
140
|
(0, typegoose_1.prop)({
|
|
141
141
|
type: String,
|
|
@@ -145,21 +145,9 @@ __decorate([
|
|
|
145
145
|
__metadata("design:type", String)
|
|
146
146
|
], Shop.prototype, "onlineStatus", void 0);
|
|
147
147
|
__decorate([
|
|
148
|
-
(0, typegoose_1.prop)({ type:
|
|
149
|
-
__metadata("design:type",
|
|
150
|
-
], Shop.prototype, "
|
|
151
|
-
__decorate([
|
|
152
|
-
(0, typegoose_1.prop)({ type: Boolean, default: false }),
|
|
153
|
-
__metadata("design:type", Boolean)
|
|
154
|
-
], Shop.prototype, "isRiderNoteVisible", void 0);
|
|
155
|
-
__decorate([
|
|
156
|
-
(0, typegoose_1.prop)({ type: String }),
|
|
157
|
-
__metadata("design:type", String)
|
|
158
|
-
], Shop.prototype, "riderNote", void 0);
|
|
159
|
-
__decorate([
|
|
160
|
-
(0, typegoose_1.prop)({ type: Number, default: 1, min: 1, max: 4 }),
|
|
161
|
-
__metadata("design:type", Number)
|
|
162
|
-
], Shop.prototype, "priceRange", void 0);
|
|
148
|
+
(0, typegoose_1.prop)({ type: work_hour_model_1.WorkHourSetting }),
|
|
149
|
+
__metadata("design:type", work_hour_model_1.WorkHourSetting)
|
|
150
|
+
], Shop.prototype, "workHourSetting", void 0);
|
|
163
151
|
__decorate([
|
|
164
152
|
(0, typegoose_1.prop)({ type: () => [String], default: [] }),
|
|
165
153
|
__metadata("design:type", Array)
|
|
@@ -168,6 +156,14 @@ __decorate([
|
|
|
168
156
|
(0, typegoose_1.prop)({ ref: () => tag_model_1.Tag, default: [] }),
|
|
169
157
|
__metadata("design:type", Array)
|
|
170
158
|
], Shop.prototype, "tags", void 0);
|
|
159
|
+
__decorate([
|
|
160
|
+
(0, typegoose_1.prop)({ required: true, type: Boolean }),
|
|
161
|
+
__metadata("design:type", Boolean)
|
|
162
|
+
], Shop.prototype, "isBeirutAuthentic", void 0);
|
|
163
|
+
__decorate([
|
|
164
|
+
(0, typegoose_1.prop)({ required: true, type: Boolean }),
|
|
165
|
+
__metadata("design:type", Boolean)
|
|
166
|
+
], Shop.prototype, "isVisibleToUser", void 0);
|
|
171
167
|
__decorate([
|
|
172
168
|
(0, typegoose_1.prop)({ type: Boolean, default: false }),
|
|
173
169
|
__metadata("design:type", Boolean)
|
|
@@ -184,6 +180,30 @@ __decorate([
|
|
|
184
180
|
(0, typegoose_1.prop)({ type: Number, default: Infinity }),
|
|
185
181
|
__metadata("design:type", Number)
|
|
186
182
|
], Shop.prototype, "orderCapacity", void 0);
|
|
183
|
+
__decorate([
|
|
184
|
+
(0, typegoose_1.prop)({ type: () => [work_hour_model_1.StartEndTime], default: [] }),
|
|
185
|
+
__metadata("design:type", Array)
|
|
186
|
+
], Shop.prototype, "shopActiveTimingsOfCurrentDate", void 0);
|
|
187
|
+
__decorate([
|
|
188
|
+
(0, typegoose_1.prop)({ type: delivery_info_model_1.DeliveryInfo }),
|
|
189
|
+
__metadata("design:type", delivery_info_model_1.DeliveryInfo)
|
|
190
|
+
], Shop.prototype, "deliveryInfo", void 0);
|
|
191
|
+
__decorate([
|
|
192
|
+
(0, typegoose_1.prop)({ type: Number }),
|
|
193
|
+
__metadata("design:type", Number)
|
|
194
|
+
], Shop.prototype, "sortingOrder", void 0);
|
|
195
|
+
__decorate([
|
|
196
|
+
(0, typegoose_1.prop)({ type: Boolean, default: false }),
|
|
197
|
+
__metadata("design:type", Boolean)
|
|
198
|
+
], Shop.prototype, "allowSpecialInstructions", void 0);
|
|
199
|
+
__decorate([
|
|
200
|
+
(0, typegoose_1.prop)({ type: Boolean, default: false }),
|
|
201
|
+
__metadata("design:type", Boolean)
|
|
202
|
+
], Shop.prototype, "isRiderNoteVisible", void 0);
|
|
203
|
+
__decorate([
|
|
204
|
+
(0, typegoose_1.prop)({ type: String }),
|
|
205
|
+
__metadata("design:type", String)
|
|
206
|
+
], Shop.prototype, "riderNote", void 0);
|
|
187
207
|
__decorate([
|
|
188
208
|
(0, typegoose_1.prop)({ type: Number, default: 10 }),
|
|
189
209
|
__metadata("design:type", Number)
|
|
@@ -192,14 +212,6 @@ __decorate([
|
|
|
192
212
|
(0, typegoose_1.prop)({ type: Number, default: null }),
|
|
193
213
|
__metadata("design:type", Number)
|
|
194
214
|
], Shop.prototype, "exchangeRate", void 0);
|
|
195
|
-
__decorate([
|
|
196
|
-
(0, typegoose_1.prop)({ type: work_hour_model_1.WorkHourSetting }),
|
|
197
|
-
__metadata("design:type", work_hour_model_1.WorkHourSetting)
|
|
198
|
-
], Shop.prototype, "workHourSetting", void 0);
|
|
199
|
-
__decorate([
|
|
200
|
-
(0, typegoose_1.prop)({ type: () => [work_hour_model_1.StartEndTime], default: [] }),
|
|
201
|
-
__metadata("design:type", Array)
|
|
202
|
-
], Shop.prototype, "shopActiveTimingsOfCurrentDate", void 0);
|
|
203
215
|
__decorate([
|
|
204
216
|
(0, typegoose_1.prop)({ required: false, type: () => Boolean }),
|
|
205
217
|
__metadata("design:type", Boolean)
|
|
@@ -216,14 +228,6 @@ __decorate([
|
|
|
216
228
|
(0, typegoose_1.prop)({ required: false, type: () => String }),
|
|
217
229
|
__metadata("design:type", String)
|
|
218
230
|
], Shop.prototype, "bestSellerCategoryTitle", void 0);
|
|
219
|
-
__decorate([
|
|
220
|
-
(0, typegoose_1.prop)({ type: delivery_info_model_1.DeliveryInfo }),
|
|
221
|
-
__metadata("design:type", delivery_info_model_1.DeliveryInfo)
|
|
222
|
-
], Shop.prototype, "deliveryInfo", void 0);
|
|
223
|
-
__decorate([
|
|
224
|
-
(0, typegoose_1.prop)({ type: Number }),
|
|
225
|
-
__metadata("design:type", Number)
|
|
226
|
-
], Shop.prototype, "sortingOrder", void 0);
|
|
227
231
|
exports.Shop = Shop = __decorate([
|
|
228
232
|
(0, typegoose_1.modelOptions)({
|
|
229
233
|
schemaOptions: { collection: 'shops' },
|
|
@@ -254,6 +258,22 @@ exports.Shop = Shop = __decorate([
|
|
|
254
258
|
return next(error);
|
|
255
259
|
}
|
|
256
260
|
}
|
|
261
|
+
try {
|
|
262
|
+
if (this.isNew) {
|
|
263
|
+
const baseSlug = (0, slugify_1.default)(this.name, { lower: true, strict: true });
|
|
264
|
+
let slug = baseSlug;
|
|
265
|
+
let count = 0;
|
|
266
|
+
while (await _1.ShopModel.exists({ slug })) {
|
|
267
|
+
count++;
|
|
268
|
+
slug = `${baseSlug}-${count}`;
|
|
269
|
+
}
|
|
270
|
+
this.slug = slug;
|
|
271
|
+
}
|
|
272
|
+
next();
|
|
273
|
+
}
|
|
274
|
+
catch (error) {
|
|
275
|
+
next(error);
|
|
276
|
+
}
|
|
257
277
|
next();
|
|
258
278
|
})
|
|
259
279
|
], Shop);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shop.model.js","sourceRoot":"/","sources":["libraries/mongo/models/shop.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAqF;AACrF,4EAAqE;AACrE,kDAA6E;AAC7E,+CAAsC;AACtC,wEAA8D;AAC9D,iDAAwC;AACxC,0DAAiD;AACjD,8DAAyE;AACzE,2CAAkC;AAClC,6CAAoC;AACpC,wEAA8D;AAC9D,wBAA8B;AAoCvB,IAAM,IAAI,GAAV,MAAM,IAAK,SAAQ,2BAAU;IAE5B,IAAI,CAAU;IAGd,MAAM,CAAc;IAGpB,QAAQ,CAAY;IAGpB,IAAI,CAAU;IAGd,KAAK,CAAa;IAGlB,SAAS,CAAU;IAGnB,KAAK,CAAU;IAGf,WAAW,CAAU;IAGrB,eAAe,CAAU;IAGzB,sBAAsB,CAAY;IAGlC,OAAO,CAAW;IAGlB,IAAI,CAAa;IAGjB,IAAI,CAAU;IAGd,MAAM,CAAU;IAGhB,QAAQ,CAAgB;IAGxB,iBAAiB,CAAW;IAG5B,eAAe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AAE,IAAI,EAAE,uBAAuB,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,EAAE,CAAC;IAC/F,IAAA,iBAAK,EAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,CAAC;IACpC,IAAA,eAAG,EAAO,MAAM,EAAE,KAAK,WAAW,IAAI;QAEtC,IAAI,IAAI,CAAC,KAAK,IAAI,OAAO,IAAI,CAAC,YAAY,KAAK,WAAW,EAAE,CAAC;YAC5D,IAAI,CAAC;gBAEJ,MAAM,eAAe,GAAG,MAAM,YAAS,CAAC,SAAS,CAA8B;oBAC9E;wBACC,MAAM,EAAE;4BACP,QAAQ,EAAE,IAAI,CAAC,QAAQ;4BACvB,SAAS,EAAE,IAAI;yBACf;qBACD;oBACD;wBACC,MAAM,EAAE;4BACP,GAAG,EAAE,IAAI;4BACT,eAAe,EAAE,EAAE,IAAI,EAAE,eAAe,EAAE;yBAC1C;qBACD;iBACD,CAAC,CAAC,IAAI,EAAE,CAAC;gBAGV,IAAI,CAAC,YAAY,GAAG,CAAC,eAAe,CAAC,CAAC,CAAC,EAAE,eAAe,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;YACrE,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBAChB,OAAO,IAAI,CAAC,KAAc,CAAC,CAAC;YAC7B,CAAC;QACF,CAAC;QACD,IAAI,EAAE,CAAC;IACR,CAAC,CAAC;GACW,IAAI,CA0HhB","sourcesContent":["import { modelOptions, prop, Ref, Severity, Index, pre } from '@typegoose/typegoose';\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\nimport { ItemType, ShopOnlineStatus, Status } from '../../../utilities/enum';\nimport { Brand } from './brand.model';\nimport { ShopDocument } from './embedded/shop-document.model';\nimport { Parent } from './parent.model';\nimport { Address } from './shared/address.model';\nimport { StartEndTime, WorkHourSetting } from './shared/work-hour.model';\nimport { Tag } from './tag.model';\nimport { Zone } from './zone.model';\nimport { DeliveryInfo } from './embedded/delivery-info.model';\nimport { ShopModel } from '.';\n\n@modelOptions({\n\tschemaOptions: { collection: 'shops' },\n\toptions: { allowMixed: Severity.ALLOW },\n})\n@Index({ name: 1, itemType: 1 }, { unique: true, partialFilterExpression: { deletedAt: null } })\n@Index({ itemType: 1, deletedAt: 1 })\n@pre<Shop>('save', async function (next) {\n\t// Only set sortingOrder if it's a new document or sortingOrder is not set\n\tif (this.isNew || typeof this.sortingOrder === 'undefined') {\n\t\ttry {\n\t\t\t// Find the maximum sortingOrder for shops with the same itemType that aren't deleted\n\t\t\tconst maxSortingOrder = await ShopModel.aggregate<{ maxSortingOrder: number }>([\n\t\t\t\t{\n\t\t\t\t\t$match: {\n\t\t\t\t\t\titemType: this.itemType,\n\t\t\t\t\t\tdeletedAt: null,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\t$group: {\n\t\t\t\t\t\t_id: null,\n\t\t\t\t\t\tmaxSortingOrder: { $max: '$sortingOrder' },\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t]).exec();\n\n\t\t\t// Set the new sortingOrder to max + 1 (or 0 if no items found)\n\t\t\tthis.sortingOrder = (maxSortingOrder[0]?.maxSortingOrder ?? -1) + 1;\n\t\t} catch (error) {\n\t\t\treturn next(error as Error);\n\t\t}\n\t}\n\tnext();\n})\nexport class Shop extends TimeStamps {\n\t@prop({ required: true, unique: true, type: String })\n\tpublic slug!: string;\n\n\t@prop({ required: true, ref: () => Parent })\n\tpublic parent: Ref<Parent>;\n\n\t@prop({ required: true, type: String, enum: ItemType })\n\tpublic itemType!: ItemType;\n\n\t@prop({ required: true, type: String })\n\tpublic name!: string;\n\n\t@prop({ required: true, ref: () => Brand })\n\tpublic brand: Ref<Brand>;\n\n\t@prop({ required: true, type: String })\n\tpublic ownerName!: string;\n\n\t@prop({ required: true, type: String })\n\tpublic email!: string;\n\n\t@prop({ required: true, type: String })\n\tpublic phoneNumber!: string;\n\n\t@prop({ required: true, type: String })\n\tpublic userPhoneNumber!: string;\n\n\t@prop({ type: () => [String], default: [] })\n\tpublic additionalPhoneNumbers?: string[];\n\n\t@prop({ required: true, type: Address })\n\tpublic address!: Address;\n\n\t@prop({ required: true, ref: () => Zone })\n\tpublic zone!: Ref<Zone>;\n\n\t@prop({ type: String })\n\tpublic logo?: string;\n\n\t@prop({ type: String })\n\tpublic banner?: string;\n\n\t@prop({ type: ShopDocument })\n\tpublic document?: ShopDocument;\n\n\t@prop({ required: true, type: Boolean })\n\tpublic isBeirutAuthentic!: boolean;\n\n\t@prop({ required: true, type: Boolean })\n\tpublic isVisibleToUser!: boolean;\n\n\t@prop({ required: true, type: String, enum: Status, default: Status.ACTIVE })\n\tpublic status!: Status;\n\n\t@prop({\n\t\ttype: String,\n\t\tenum: ShopOnlineStatus,\n\t\tdefault: ShopOnlineStatus.OFFLINE,\n\t})\n\tpublic onlineStatus?: ShopOnlineStatus;\n\n\t// Setting\n\t@prop({ type: Boolean, default: false })\n\tpublic allowSpecialInstructions?: boolean;\n\n\t@prop({ type: Boolean, default: false })\n\tpublic isRiderNoteVisible?: boolean;\n\n\t@prop({ type: String })\n\tpublic riderNote?: string;\n\n\t@prop({ type: Number, default: 1, min: 1, max: 4 })\n\tpublic priceRange?: number;\n\n\t@prop({ type: () => [String], default: [] })\n\tpublic dietaries?: string[];\n\n\t@prop({ ref: () => Tag, default: [] })\n\tpublic tags?: Ref<Tag>[];\n\n\t@prop({ type: Boolean, default: false })\n\tpublic isShopDelivery?: boolean;\n\n\t@prop({ type: Number })\n\tpublic deliveryFee?: number;\n\n\t@prop({ type: Number, default: 0 })\n\tpublic minimumOrderAmount?: number;\n\n\t@prop({ type: Number, default: Infinity })\n\tpublic orderCapacity?: number;\n\n\t@prop({ type: Number, default: 10 })\n\tpublic defaultPreparationTime?: number;\n\n\t@prop({ type: Number, default: null })\n\texchangeRate?: number;\n\n\t@prop({ type: WorkHourSetting })\n\tpublic workHourSetting?: WorkHourSetting;\n\n\t@prop({ type: () => [StartEndTime], default: [] })\n\tpublic shopActiveTimingsOfCurrentDate?: StartEndTime[];\n\n\t@prop({ required: false, type: () => Boolean })\n\tpublic isFavouriteCategoryVisible?: boolean;\n\n\t@prop({ required: false, type: () => String })\n\tpublic favouriteCategoryTitle?: string;\n\n\t@prop({ required: false, type: () => Boolean })\n\tpublic isBestSellerCategoryVisible?: boolean;\n\n\t@prop({ required: false, type: () => String })\n\tpublic bestSellerCategoryTitle?: string;\n\n\t@prop({ type: DeliveryInfo })\n\tpublic deliveryInfo?: DeliveryInfo;\n\n\t@prop({ type: Number })\n\tpublic sortingOrder?: number;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"shop.model.js","sourceRoot":"/","sources":["libraries/mongo/models/shop.model.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,oDAAqF;AACrF,4EAAqE;AACrE,kDAA6E;AAC7E,+CAAsC;AACtC,wEAA8D;AAC9D,iDAAwC;AACxC,0DAAiD;AACjD,8DAAyE;AACzE,2CAAkC;AAClC,6CAAoC;AACpC,wEAA8D;AAC9D,wBAA8B;AAC9B,sDAA8B;AAmDvB,IAAM,IAAI,GAAV,MAAM,IAAK,SAAQ,2BAAU;IAE5B,IAAI,CAAU;IAGd,SAAS,CAAU;IAGnB,KAAK,CAAU;IAGf,IAAI,CAAU;IAGd,MAAM,CAAc;IAGpB,QAAQ,CAAY;IAGpB,MAAM,CAAU;IAGhB,KAAK,CAAa;IAGlB,UAAU,CAAU;IAGpB,WAAW,CAAU;IAGrB,eAAe,CAAU;IAGzB,sBAAsB,CAAY;IAGlC,OAAO,CAAW;IAGlB,IAAI,CAAa;IAGjB,IAAI,CAAU;IAGd,MAAM,CAAU;IAGhB,QAAQ,CAAgB;IAOxB,YAAY,CAAoB;IAGhC,eAAe,CAAmB;IAGlC,SAAS,CAAY;IAGrB,IAAI,CAAc;IAGlB,iBAAiB,CAAW;IAG5B,eAAe,CAAW;IAG1B,cAAc,CAAW;IAGzB,WAAW,CAAU;IAGrB,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,KAAc,CAAC,CAAC;QACtB,CAAC;QACD,IAAI,EAAE,CAAC;IACR,CAAC,CAAC;GACW,IAAI,CA0HhB","sourcesContent":["import { modelOptions, prop, Ref, Severity, Index, pre } from '@typegoose/typegoose';\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\nimport { ItemType, ShopOnlineStatus, Status } from '../../../utilities/enum';\nimport { Brand } from './brand.model';\nimport { ShopDocument } from './embedded/shop-document.model';\nimport { Parent } from './parent.model';\nimport { Address } from './shared/address.model';\nimport { StartEndTime, WorkHourSetting } from './shared/work-hour.model';\nimport { Tag } from './tag.model';\nimport { Zone } from './zone.model';\nimport { DeliveryInfo } from './embedded/delivery-info.model';\nimport { ShopModel } from '.';\nimport slugify from 'slugify';\n\n@modelOptions({\n\tschemaOptions: { collection: 'shops' },\n\toptions: { allowMixed: Severity.ALLOW },\n})\n@Index({ name: 1, itemType: 1 }, { unique: true, partialFilterExpression: { deletedAt: null } })\n@Index({ itemType: 1, deletedAt: 1 })\n@pre<Shop>('save', async function (next) {\n\t// Only set sortingOrder if it's a new document or sortingOrder is not set\n\tif (this.isNew || typeof this.sortingOrder === 'undefined') {\n\t\ttry {\n\t\t\t// Find the maximum sortingOrder for shops with the same itemType that aren't deleted\n\t\t\tconst maxSortingOrder = await ShopModel.aggregate<{ maxSortingOrder: number }>([\n\t\t\t\t{\n\t\t\t\t\t$match: {\n\t\t\t\t\t\titemType: this.itemType,\n\t\t\t\t\t\tdeletedAt: null,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\t$group: {\n\t\t\t\t\t\t_id: null,\n\t\t\t\t\t\tmaxSortingOrder: { $max: '$sortingOrder' },\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t]).exec();\n\n\t\t\t// Set the new sortingOrder to max + 1 (or 0 if no items found)\n\t\t\tthis.sortingOrder = (maxSortingOrder[0]?.maxSortingOrder ?? -1) + 1;\n\t\t} catch (error) {\n\t\t\treturn next(error as Error);\n\t\t}\n\t}\n\ttry {\n\t\tif (this.isNew) {\n\t\t\tconst baseSlug = slugify(this.name, { lower: true, strict: true });\n\t\t\tlet slug = baseSlug;\n\t\t\tlet count = 0;\n\t\t\twhile (await ShopModel.exists({ slug })) {\n\t\t\t\tcount++;\n\t\t\t\tslug = `${baseSlug}-${count}`;\n\t\t\t}\n\t\t\tthis.slug = slug;\n\t\t}\n\t\tnext();\n\t} catch (error) {\n\t\tnext(error as Error);\n\t}\n\tnext();\n})\nexport class Shop extends TimeStamps {\n\t@prop({ required: true, type: String })\n\tpublic name!: string;\n\n\t@prop({ required: true, type: String })\n\tpublic ownerName!: string;\n\n\t@prop({ required: true, type: String })\n\tpublic email!: string;\n\n\t@prop({ unique: true, type: String })\n\tpublic slug?: string;\n\n\t@prop({ required: true, ref: () => Parent })\n\tpublic parent: Ref<Parent>;\n\n\t@prop({ required: true, type: String, enum: ItemType })\n\tpublic itemType!: ItemType;\n\n\t@prop({ required: true, type: String, enum: Status, default: Status.ACTIVE })\n\tpublic status!: Status;\n\n\t@prop({ required: true, ref: () => Brand })\n\tpublic brand: Ref<Brand>;\n\n\t@prop({ type: Number, default: 1, min: 1, max: 4 })\n\tpublic priceRange?: number;\n\n\t@prop({ required: true, type: String })\n\tpublic phoneNumber!: string;\n\n\t@prop({ required: true, type: String })\n\tpublic userPhoneNumber!: string;\n\n\t@prop({ type: () => [String], default: [] })\n\tpublic additionalPhoneNumbers?: string[];\n\n\t@prop({ required: true, type: Address })\n\tpublic address!: Address;\n\n\t@prop({ required: true, ref: () => Zone })\n\tpublic zone!: Ref<Zone>;\n\n\t@prop({ type: String })\n\tpublic logo?: string;\n\n\t@prop({ type: String })\n\tpublic banner?: string;\n\n\t@prop({ type: ShopDocument })\n\tpublic document?: ShopDocument;\n\n\t@prop({\n\t\ttype: String,\n\t\tenum: ShopOnlineStatus,\n\t\tdefault: ShopOnlineStatus.OFFLINE,\n\t})\n\tpublic onlineStatus?: ShopOnlineStatus;\n\n\t@prop({ type: WorkHourSetting })\n\tpublic workHourSetting?: WorkHourSetting;\n\n\t@prop({ type: () => [String], default: [] })\n\tpublic dietaries?: string[];\n\n\t@prop({ ref: () => Tag, default: [] })\n\tpublic tags?: Ref<Tag>[];\n\n\t@prop({ required: true, type: Boolean })\n\tpublic isBeirutAuthentic!: boolean;\n\n\t@prop({ required: true, type: Boolean })\n\tpublic isVisibleToUser!: boolean;\n\n\t@prop({ type: Boolean, default: false })\n\tpublic isShopDelivery?: boolean;\n\n\t@prop({ type: Number })\n\tpublic deliveryFee?: number;\n\n\t@prop({ type: Number, default: 0 })\n\tpublic minimumOrderAmount?: number;\n\n\t@prop({ type: Number, default: Infinity })\n\tpublic orderCapacity?: number;\n\n\t@prop({ type: () => [StartEndTime], default: [] })\n\tpublic shopActiveTimingsOfCurrentDate?: StartEndTime[];\n\n\t@prop({ type: DeliveryInfo })\n\tpublic deliveryInfo?: DeliveryInfo;\n\n\t@prop({ type: Number })\n\tpublic sortingOrder?: number;\n\n\t// Setting\n\t@prop({ type: Boolean, default: false })\n\tpublic allowSpecialInstructions?: boolean;\n\n\t@prop({ type: Boolean, default: false })\n\tpublic isRiderNoteVisible?: boolean;\n\n\t@prop({ type: String })\n\tpublic riderNote?: string;\n\n\t@prop({ type: Number, default: 10 })\n\tpublic defaultPreparationTime?: number;\n\n\t@prop({ type: Number, default: null })\n\texchangeRate?: number;\n\n\t@prop({ required: false, type: () => Boolean })\n\tpublic isFavouriteCategoryVisible?: boolean;\n\n\t@prop({ required: false, type: () => String })\n\tpublic favouriteCategoryTitle?: string;\n\n\t@prop({ required: false, type: () => Boolean })\n\tpublic isBestSellerCategoryVisible?: boolean;\n\n\t@prop({ required: false, type: () => String })\n\tpublic bestSellerCategoryTitle?: string;\n}\n"]}
|
|
@@ -44,6 +44,7 @@ __decorate([
|
|
|
44
44
|
], UserAppSectionSetting.prototype, "sortingOrder", void 0);
|
|
45
45
|
exports.UserAppSectionSetting = UserAppSectionSetting = __decorate([
|
|
46
46
|
(0, typegoose_1.modelOptions)({ schemaOptions: { collection: 'userAppSectionSetting' } }),
|
|
47
|
+
(0, typegoose_1.Index)({ itemType: 1, section: 1 }, { unique: true }),
|
|
47
48
|
(0, typegoose_1.pre)('save', async function (next) {
|
|
48
49
|
if (this.isNew || typeof this.sortingOrder === 'undefined') {
|
|
49
50
|
try {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user-app-section-setting.model.js","sourceRoot":"/","sources":["libraries/mongo/models/user-app-section-setting.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"user-app-section-setting.model.js","sourceRoot":"/","sources":["libraries/mongo/models/user-app-section-setting.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAsE;AACtE,4EAAqE;AACrE,kDAA6F;AAC7F,wBAA+C;AAkCxC,IAAM,qBAAqB,GAA3B,MAAM,qBAAsB,SAAQ,2BAAU;IAE7C,QAAQ,CAA0B;IAGlC,OAAO,CAAsB;IAG7B,KAAK,CAAU;IAGf,MAAM,CAAU;IAGhB,YAAY,CAAU;CAC7B,CAAA;AAfY,sDAAqB;AAE1B;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,6BAAsB,EAAE,CAAC;;uDAC5B;AAGlC;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,yBAAkB,EAAE,CAAC;;sDAC7B;AAG7B;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACjB;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,aAAM,EAAE,OAAO,EAAE,aAAM,CAAC,MAAM,EAAE,CAAC;;qDACtC;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;2DACM;gCAdjB,qBAAqB;IAhCjC,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,uBAAuB,EAAC,EAAE,CAAC;IACvE,IAAA,iBAAK,EACL,EAAE,QAAQ,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,EAC3B,EAAE,MAAM,EAAE,IAAI,EAAE,CAChB;IACA,IAAA,eAAG,EAAwB,MAAM,EAAE,KAAK,WAAW,IAAI;QAEvD,IAAI,IAAI,CAAC,KAAK,IAAI,OAAO,IAAI,CAAC,YAAY,KAAK,WAAW,EAAE,CAAC;YAC5D,IAAI,CAAC;gBAEJ,MAAM,eAAe,GAAG,MAAM,6BAA0B,CAAC,SAAS,CAA8B;oBAC/F;wBACC,MAAM,EAAE;4BACP,SAAS,EAAE,IAAI;yBACf;qBACD;oBACD;wBACC,MAAM,EAAE;4BACP,GAAG,EAAE,IAAI;4BACT,eAAe,EAAE,EAAE,IAAI,EAAE,eAAe,EAAE;yBAC1C;qBACD;iBACD,CAAC,CAAC,IAAI,EAAE,CAAC;gBAGV,IAAI,CAAC,YAAY,GAAG,CAAC,eAAe,CAAC,CAAC,CAAC,EAAE,eAAe,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;YACrE,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBAChB,OAAO,IAAI,CAAC,KAAc,CAAC,CAAC;YAC7B,CAAC;QACF,CAAC;QACD,IAAI,EAAE,CAAC;IACR,CAAC,CAAC;GACW,qBAAqB,CAejC","sourcesContent":["import { Index, modelOptions, pre, prop } from '@typegoose/typegoose';\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\nimport { Status, UserAppSectionItemType, UserAppSectionType } from '../../../utilities/enum';\nimport { UserAppSectionSettingModel } from '.';\n\n@modelOptions({ schemaOptions: { collection: 'userAppSectionSetting'} })\n@Index(\n\t{ itemType: 1, section: 1 },\n\t{ unique: true }\n)\n@pre<UserAppSectionSetting>('save', async function (next) {\n\t// Only set sortingOrder if it's a new document or sortingOrder is not set\n\tif (this.isNew || typeof this.sortingOrder === 'undefined') {\n\t\ttry {\n\t\t\t// Find the maximum sortingOrder that aren't deleted\n\t\t\tconst maxSortingOrder = await UserAppSectionSettingModel.aggregate<{ maxSortingOrder: number }>([\n\t\t\t\t{\n\t\t\t\t\t$match: {\n\t\t\t\t\t\tdeletedAt: null,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\t$group: {\n\t\t\t\t\t\t_id: null,\n\t\t\t\t\t\tmaxSortingOrder: { $max: '$sortingOrder' },\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t]).exec();\n\n\t\t\t// Set the new sortingOrder to max + 1 (or 0 if no items found)\n\t\t\tthis.sortingOrder = (maxSortingOrder[0]?.maxSortingOrder ?? -1) + 1;\n\t\t} catch (error) {\n\t\t\treturn next(error as Error);\n\t\t}\n\t}\n\tnext();\n})\nexport class UserAppSectionSetting extends TimeStamps {\n\t@prop({ required: true, type: String, enum: UserAppSectionItemType })\n\tpublic itemType!: UserAppSectionItemType;\n\n\t@prop({ required: true, type: String, enum: UserAppSectionType })\n\tpublic section!: UserAppSectionType;\n\n\t@prop({ required: true, type: String })\n\tpublic alias!: string;\n\n\t@prop({ type: String, enum: Status, default: Status.ACTIVE })\n\tpublic status?: Status;\n\n\t@prop({ type: Number })\n\tpublic sortingOrder?: number;\n}\n"]}
|
|
@@ -195,7 +195,7 @@ export declare const AddressSchema: z.ZodObject<{
|
|
|
195
195
|
city?: string | null | undefined;
|
|
196
196
|
zone?: string | import("mongoose").Types.ObjectId | undefined;
|
|
197
197
|
}>;
|
|
198
|
-
export declare const UserAddressSchema: z.ZodObject<
|
|
198
|
+
export declare const UserAddressSchema: z.ZodObject<{
|
|
199
199
|
address: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
200
200
|
description: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
201
201
|
city: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -214,13 +214,13 @@ export declare const UserAddressSchema: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
214
214
|
latitude: z.ZodNumber;
|
|
215
215
|
longitude: z.ZodNumber;
|
|
216
216
|
zone: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, import("mongoose").Types.ObjectId, string>, z.ZodType<import("mongoose").Types.ObjectId, z.ZodTypeDef, import("mongoose").Types.ObjectId>]>>;
|
|
217
|
-
}
|
|
217
|
+
} & {
|
|
218
218
|
addressLabel: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
219
219
|
apartment: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
220
220
|
buildingName: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
221
221
|
deliveryOption: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
222
222
|
instructions: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
223
|
-
}
|
|
223
|
+
}, "strip", z.ZodTypeAny, {
|
|
224
224
|
location: {
|
|
225
225
|
type: GeoLocationType;
|
|
226
226
|
coordinates: [number, number];
|
|
@@ -257,7 +257,7 @@ export declare const UserAddressSchema: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
257
257
|
deliveryOption?: string | null | undefined;
|
|
258
258
|
instructions?: string | null | undefined;
|
|
259
259
|
}>;
|
|
260
|
-
export declare const CourierAddressSchema: z.ZodObject<
|
|
260
|
+
export declare const CourierAddressSchema: z.ZodObject<{
|
|
261
261
|
address: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
262
262
|
description: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
263
263
|
city: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -276,16 +276,16 @@ export declare const CourierAddressSchema: z.ZodObject<z.objectUtil.extendShape<
|
|
|
276
276
|
latitude: z.ZodNumber;
|
|
277
277
|
longitude: z.ZodNumber;
|
|
278
278
|
zone: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, import("mongoose").Types.ObjectId, string>, z.ZodType<import("mongoose").Types.ObjectId, z.ZodTypeDef, import("mongoose").Types.ObjectId>]>>;
|
|
279
|
-
}
|
|
279
|
+
} & {
|
|
280
280
|
addressLabel: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
281
281
|
apartment: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
282
282
|
buildingName: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
283
283
|
deliveryOption: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
284
284
|
instructions: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodString>> | z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
285
|
-
}
|
|
285
|
+
} & {
|
|
286
286
|
name: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
287
287
|
phoneNumber: z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
288
|
-
}
|
|
288
|
+
}, "strip", z.ZodTypeAny, {
|
|
289
289
|
location: {
|
|
290
290
|
type: GeoLocationType;
|
|
291
291
|
coordinates: [number, number];
|
package/package.json
CHANGED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { ValueType } from '../../../../utilities/enum';
|
|
2
|
-
declare class DeliveryCharge {
|
|
3
|
-
from: number;
|
|
4
|
-
to: number;
|
|
5
|
-
charge: number;
|
|
6
|
-
riderCut: number;
|
|
7
|
-
}
|
|
8
|
-
export declare class ChargeSetting {
|
|
9
|
-
valueType?: ValueType;
|
|
10
|
-
value?: number;
|
|
11
|
-
deliveryCharges?: DeliveryCharge[];
|
|
12
|
-
deliveryChargesForCourier?: DeliveryCharge[];
|
|
13
|
-
}
|
|
14
|
-
export {};
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.ChargeSetting = void 0;
|
|
13
|
-
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
|
-
const enum_1 = require("../../../../utilities/enum");
|
|
15
|
-
class DeliveryCharge {
|
|
16
|
-
from;
|
|
17
|
-
to;
|
|
18
|
-
charge;
|
|
19
|
-
riderCut;
|
|
20
|
-
}
|
|
21
|
-
__decorate([
|
|
22
|
-
(0, typegoose_1.prop)({ required: true, type: Number, min: 0 }),
|
|
23
|
-
__metadata("design:type", Number)
|
|
24
|
-
], DeliveryCharge.prototype, "from", void 0);
|
|
25
|
-
__decorate([
|
|
26
|
-
(0, typegoose_1.prop)({ required: true, type: Number, min: 0 }),
|
|
27
|
-
__metadata("design:type", Number)
|
|
28
|
-
], DeliveryCharge.prototype, "to", void 0);
|
|
29
|
-
__decorate([
|
|
30
|
-
(0, typegoose_1.prop)({ required: true, type: Number, min: 0 }),
|
|
31
|
-
__metadata("design:type", Number)
|
|
32
|
-
], DeliveryCharge.prototype, "charge", void 0);
|
|
33
|
-
__decorate([
|
|
34
|
-
(0, typegoose_1.prop)({ required: true, type: Number, min: 0 }),
|
|
35
|
-
__metadata("design:type", Number)
|
|
36
|
-
], DeliveryCharge.prototype, "riderCut", void 0);
|
|
37
|
-
class ChargeSetting {
|
|
38
|
-
valueType;
|
|
39
|
-
value;
|
|
40
|
-
deliveryCharges;
|
|
41
|
-
deliveryChargesForCourier;
|
|
42
|
-
}
|
|
43
|
-
exports.ChargeSetting = ChargeSetting;
|
|
44
|
-
__decorate([
|
|
45
|
-
(0, typegoose_1.prop)({ type: String, enum: enum_1.ValueType, default: enum_1.ValueType.PERCENTAGE }),
|
|
46
|
-
__metadata("design:type", String)
|
|
47
|
-
], ChargeSetting.prototype, "valueType", void 0);
|
|
48
|
-
__decorate([
|
|
49
|
-
(0, typegoose_1.prop)({ type: Number, min: 0 }),
|
|
50
|
-
__metadata("design:type", Number)
|
|
51
|
-
], ChargeSetting.prototype, "value", void 0);
|
|
52
|
-
__decorate([
|
|
53
|
-
(0, typegoose_1.prop)({ type: () => [DeliveryCharge], default: [] }),
|
|
54
|
-
__metadata("design:type", Array)
|
|
55
|
-
], ChargeSetting.prototype, "deliveryCharges", void 0);
|
|
56
|
-
__decorate([
|
|
57
|
-
(0, typegoose_1.prop)({ type: () => [DeliveryCharge], default: [] }),
|
|
58
|
-
__metadata("design:type", Array)
|
|
59
|
-
], ChargeSetting.prototype, "deliveryChargesForCourier", void 0);
|
|
60
|
-
//# sourceMappingURL=charge-setting.model.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"charge-setting.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/charge-setting.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,qDAAuD;AAEvD,MAAM,cAAc;IAEZ,IAAI,CAAU;IAGd,EAAE,CAAU;IAGZ,MAAM,CAAU;IAGhB,QAAQ,CAAU;CACzB;AAVO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;4CAC1B;AAGd;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;0CAC5B;AAGZ;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;8CACxB;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;gDACtB;AAG1B,MAAa,aAAa;IAElB,SAAS,CAAa;IAGtB,KAAK,CAAU;IAGf,eAAe,CAAoB;IAGnC,yBAAyB,CAAoB;CACpD;AAZD,sCAYC;AAVO;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,gBAAS,EAAE,OAAO,EAAE,gBAAS,CAAC,UAAU,EAAE,CAAC;;gDAC1C;AAGtB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;4CACT;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,cAAc,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;sDACV;AAGnC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,cAAc,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;gEACA","sourcesContent":["import { prop } from '@typegoose/typegoose';\nimport { ValueType } from '../../../../utilities/enum';\n\nclass DeliveryCharge {\n\t@prop({ required: true, type: Number, min: 0 })\n\tpublic from!: number;\n\n\t@prop({ required: true, type: Number, min: 0 })\n\tpublic to!: number;\n\n\t@prop({ required: true, type: Number, min: 0 })\n\tpublic charge!: number;\n\n\t@prop({ required: true, type: Number, min: 0 })\n\tpublic riderCut!: number;\n}\n\nexport class ChargeSetting {\n\t@prop({ type: String, enum: ValueType, default: ValueType.PERCENTAGE })\n\tpublic valueType?: ValueType;\n\n\t@prop({ type: Number, min: 0 })\n\tpublic value?: number;\n\n\t@prop({ type: () => [DeliveryCharge], default: [] })\n\tpublic deliveryCharges?: DeliveryCharge[];\n\n\t@prop({ type: () => [DeliveryCharge], default: [] })\n\tpublic deliveryChargesForCourier?: DeliveryCharge[];\n}\n"]}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
|
|
2
|
-
export declare class TermsAndConditions extends TimeStamps {
|
|
3
|
-
privacyMessage: string;
|
|
4
|
-
userTermsAndConditions: string;
|
|
5
|
-
shopTermsAndConditions: string;
|
|
6
|
-
riderTermsAndConditions: string;
|
|
7
|
-
lyxaPlusTermsAndConditions: string;
|
|
8
|
-
}
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.TermsAndConditions = void 0;
|
|
13
|
-
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
|
-
const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
15
|
-
let TermsAndConditions = class TermsAndConditions extends defaultClasses_1.TimeStamps {
|
|
16
|
-
privacyMessage;
|
|
17
|
-
userTermsAndConditions;
|
|
18
|
-
shopTermsAndConditions;
|
|
19
|
-
riderTermsAndConditions;
|
|
20
|
-
lyxaPlusTermsAndConditions;
|
|
21
|
-
};
|
|
22
|
-
exports.TermsAndConditions = TermsAndConditions;
|
|
23
|
-
__decorate([
|
|
24
|
-
(0, typegoose_1.prop)({ default: '' }),
|
|
25
|
-
__metadata("design:type", String)
|
|
26
|
-
], TermsAndConditions.prototype, "privacyMessage", void 0);
|
|
27
|
-
__decorate([
|
|
28
|
-
(0, typegoose_1.prop)({ default: '' }),
|
|
29
|
-
__metadata("design:type", String)
|
|
30
|
-
], TermsAndConditions.prototype, "userTermsAndConditions", void 0);
|
|
31
|
-
__decorate([
|
|
32
|
-
(0, typegoose_1.prop)({ default: '' }),
|
|
33
|
-
__metadata("design:type", String)
|
|
34
|
-
], TermsAndConditions.prototype, "shopTermsAndConditions", void 0);
|
|
35
|
-
__decorate([
|
|
36
|
-
(0, typegoose_1.prop)({ default: '' }),
|
|
37
|
-
__metadata("design:type", String)
|
|
38
|
-
], TermsAndConditions.prototype, "riderTermsAndConditions", void 0);
|
|
39
|
-
__decorate([
|
|
40
|
-
(0, typegoose_1.prop)({ default: '' }),
|
|
41
|
-
__metadata("design:type", String)
|
|
42
|
-
], TermsAndConditions.prototype, "lyxaPlusTermsAndConditions", void 0);
|
|
43
|
-
exports.TermsAndConditions = TermsAndConditions = __decorate([
|
|
44
|
-
(0, typegoose_1.modelOptions)({
|
|
45
|
-
schemaOptions: {
|
|
46
|
-
collection: 'terms-and-conditions',
|
|
47
|
-
timestamps: true,
|
|
48
|
-
},
|
|
49
|
-
})
|
|
50
|
-
], TermsAndConditions);
|
|
51
|
-
//# sourceMappingURL=terms-condition.model.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"terms-condition.model.js","sourceRoot":"/","sources":["libraries/mongo/models/terms-condition.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA0D;AAC1D,4EAAqE;AAQ9D,IAAM,kBAAkB,GAAxB,MAAM,kBAAmB,SAAQ,2BAAU;IAE1C,cAAc,CAAS;IAGvB,sBAAsB,CAAS;IAG/B,sBAAsB,CAAS;IAG/B,uBAAuB,CAAS;IAGhC,0BAA0B,CAAS;CAC1C,CAAA;AAfY,gDAAkB;AAEvB;IADN,IAAA,gBAAI,EAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;0DACQ;AAGvB;IADN,IAAA,gBAAI,EAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;kEACgB;AAG/B;IADN,IAAA,gBAAI,EAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;kEACgB;AAG/B;IADN,IAAA,gBAAI,EAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;mEACiB;AAGhC;IADN,IAAA,gBAAI,EAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;sEACoB;6BAd9B,kBAAkB;IAN9B,IAAA,wBAAY,EAAC;QACb,aAAa,EAAE;YACd,UAAU,EAAE,sBAAsB;YAClC,UAAU,EAAE,IAAI;SAChB;KACD,CAAC;GACW,kBAAkB,CAe9B","sourcesContent":["import { modelOptions, prop } from '@typegoose/typegoose';\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\n\n@modelOptions({\n\tschemaOptions: {\n\t\tcollection: 'terms-and-conditions',\n\t\ttimestamps: true,\n\t},\n})\nexport class TermsAndConditions extends TimeStamps {\n\t@prop({ default: '' })\n\tpublic privacyMessage: string;\n\n\t@prop({ default: '' })\n\tpublic userTermsAndConditions: string;\n\n\t@prop({ default: '' })\n\tpublic shopTermsAndConditions: string;\n\n\t@prop({ default: '' })\n\tpublic riderTermsAndConditions: string;\n\n\t@prop({ default: '' })\n\tpublic lyxaPlusTermsAndConditions: string;\n}\n"]}
|