@lyxa.ai/core 1.4.62 → 1.4.63

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.
@@ -67,7 +67,7 @@ __decorate([
67
67
  __metadata("design:type", profit_model_1.ServiceBookingProfit)
68
68
  ], ServiceBookingFinance.prototype, "vendorProfit", void 0);
69
69
  __decorate([
70
- (0, typegoose_1.prop)({ type: () => marketing_cut_model_1.ServicePromotionCut, _id: false }),
70
+ (0, typegoose_1.prop)({ type: () => marketing_cut_model_1.ServicePromotionCut, default: () => new marketing_cut_model_1.ServicePromotionCut(), _id: false }),
71
71
  __metadata("design:type", marketing_cut_model_1.ServicePromotionCut)
72
72
  ], ServiceBookingFinance.prototype, "discount", void 0);
73
73
  __decorate([
@@ -75,11 +75,11 @@ __decorate([
75
75
  __metadata("design:type", marketing_cut_model_1.ServiceCouponDetails)
76
76
  ], ServiceBookingFinance.prototype, "coupon", void 0);
77
77
  __decorate([
78
- (0, typegoose_1.prop)({ type: () => vat_model_1.Vat, _id: false }),
78
+ (0, typegoose_1.prop)({ type: () => vat_model_1.Vat, default: () => new vat_model_1.Vat(), _id: false }),
79
79
  __metadata("design:type", vat_model_1.Vat)
80
80
  ], ServiceBookingFinance.prototype, "vat", void 0);
81
81
  __decorate([
82
- (0, typegoose_1.prop)({ type: () => cashback_amounts_model_1.Cashback, _id: false }),
82
+ (0, typegoose_1.prop)({ type: () => cashback_amounts_model_1.Cashback, default: () => new cashback_amounts_model_1.Cashback(), _id: false }),
83
83
  __metadata("design:type", cashback_amounts_model_1.Cashback)
84
84
  ], ServiceBookingFinance.prototype, "cashBackAmounts", void 0);
85
85
  //# sourceMappingURL=service-booking-finance.model.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"service-booking-finance.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/service-booking-finance.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiD;AACjD,2CAAkC;AAClC,mFAAwE;AACx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C;AAGrC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,mCAAoB,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC;8BACjC,mCAAoB;2DAAC;AAGpC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,yCAAmB,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC;8BACpC,yCAAmB;uDAAC;AAG/B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,0CAAoB,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC;8BACvC,0CAAoB;qDAAC;AAG9B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,eAAG,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC;8BACzB,eAAG;kDAAC;AAGV;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,iCAAQ,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC;8BAClB,iCAAQ;8DAAC","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\nimport { Vat } from './vat.model';\nimport { ServiceBookingPricing } from './service-booking-pricing.model';\nimport { PaymentMethod } from '../../../../utilities/enum';\nimport { ServiceBookingProfit } from './profit.model';\nimport { ServiceCouponDetails, ServicePromotionCut } from './marketing-cut.model';\nimport { Cashback } from './cashback-amounts.model';\nimport { Card } from '../card.model';\nimport { PaymentRecord } from './payment-record.model';\n\nexport class ServiceBookingFinance {\n\t@prop({ required: true, type: Number })\n\tpublic adminCommission!: number;\n\n\t@prop({ type: Number, default: 0 })\n\tpublic exchangeRate?: number;\n\n\t@prop({ required: true, type: String, enum: PaymentMethod })\n\tpublic paymentMethod!: PaymentMethod;\n\n\t@prop({ ref: () => Card })\n\tpublic card?: Ref<Card>;\n\n\t@prop({ type: () => [PaymentRecord], _id: false, default: [] })\n\tpublic paymentRecords?: PaymentRecord[];\n\n\t@prop({ required: true, type: () => ServiceBookingPricing, _id: false })\n\tpublic pricing!: ServiceBookingPricing;\n\n\t@prop({ type: () => ServiceBookingProfit, _id: false })\n\tpublic companyProfit?: ServiceBookingProfit;\n\n\t@prop({ type: () => ServiceBookingProfit, _id: false })\n\tpublic vendorProfit?: ServiceBookingProfit;\n\n\t@prop({ type: () => ServicePromotionCut, _id: false })\n\tpublic discount?: ServicePromotionCut;\n\n\t@prop({ type: () => ServiceCouponDetails, _id: false })\n\tpublic coupon?: ServiceCouponDetails;\n\n\t@prop({ type: () => Vat, _id: false })\n\tpublic vat?: Vat;\n\n\t@prop({ type: () => Cashback, _id: false })\n\tpublic cashBackAmounts?: Cashback;\n}\n"]}
1
+ {"version":3,"file":"service-booking-finance.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/service-booking-finance.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiD;AACjD,2CAAkC;AAClC,mFAAwE;AACxE,qDAA2D;AAC3D,iDAAsD;AACtD,+DAAkF;AAClF,qEAAoD;AACpD,8CAAqC;AACrC,iEAAuD;AAEvD,MAAa,qBAAqB;IAE1B,eAAe,CAAU;IAGzB,YAAY,CAAU;IAGtB,aAAa,CAAiB;IAG9B,IAAI,CAAa;IAGjB,cAAc,CAAmB;IAGjC,OAAO,CAAyB;IAGhC,aAAa,CAAwB;IAGrC,YAAY,CAAwB;IAGpC,QAAQ,CAAuB;IAG/B,MAAM,CAAwB;IAG9B,GAAG,CAAO;IAGV,eAAe,CAAY;CAClC;AApCD,sDAoCC;AAlCO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;8DACP;AAGzB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;;2DACN;AAGtB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,M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;kDAAC;AAGV;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,iCAAQ,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,iCAAQ,EAAE,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC;8BACjD,iCAAQ;8DAAC","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\nimport { Vat } from './vat.model';\nimport { ServiceBookingPricing } from './service-booking-pricing.model';\nimport { PaymentMethod } from '../../../../utilities/enum';\nimport { ServiceBookingProfit } from './profit.model';\nimport { ServiceCouponDetails, ServicePromotionCut } from './marketing-cut.model';\nimport { Cashback } from './cashback-amounts.model';\nimport { Card } from '../card.model';\nimport { PaymentRecord } from './payment-record.model';\n\nexport class ServiceBookingFinance {\n\t@prop({ required: true, type: Number })\n\tpublic adminCommission!: number;\n\n\t@prop({ type: Number, default: 0 })\n\tpublic exchangeRate?: number;\n\n\t@prop({ required: true, type: String, enum: PaymentMethod })\n\tpublic paymentMethod!: PaymentMethod;\n\n\t@prop({ ref: () => Card })\n\tpublic card?: Ref<Card>;\n\n\t@prop({ type: () => [PaymentRecord], _id: false, default: [] })\n\tpublic paymentRecords?: PaymentRecord[];\n\n\t@prop({ required: true, type: () => ServiceBookingPricing, _id: false })\n\tpublic pricing!: ServiceBookingPricing;\n\n\t@prop({ type: () => ServiceBookingProfit, _id: false })\n\tpublic companyProfit?: ServiceBookingProfit;\n\n\t@prop({ type: () => ServiceBookingProfit, _id: false })\n\tpublic vendorProfit?: ServiceBookingProfit;\n\n\t@prop({ type: () => ServicePromotionCut, default: () => new ServicePromotionCut(), _id: false })\n\tpublic discount?: ServicePromotionCut;\n\n\t@prop({ type: () => ServiceCouponDetails, _id: false })\n\tpublic coupon?: ServiceCouponDetails;\n\n\t@prop({ type: () => Vat, default: () => new Vat(), _id: false })\n\tpublic vat?: Vat;\n\n\t@prop({ type: () => Cashback, default: () => new Cashback(), _id: false })\n\tpublic cashBackAmounts?: Cashback;\n}\n"]}
@@ -21,4 +21,5 @@ export declare class ServiceLineItem {
21
21
  secondaryPrice?: number;
22
22
  discountedPrice?: number;
23
23
  secondaryDiscountedPrice?: number;
24
+ isDiscountAppliedByCompany?: boolean;
24
25
  }
@@ -58,6 +58,7 @@ class ServiceLineItem {
58
58
  secondaryPrice;
59
59
  discountedPrice;
60
60
  secondaryDiscountedPrice;
61
+ isDiscountAppliedByCompany;
61
62
  }
62
63
  exports.ServiceLineItem = ServiceLineItem;
63
64
  __decorate([
@@ -96,4 +97,8 @@ __decorate([
96
97
  (0, typegoose_1.prop)({ type: Number }),
97
98
  __metadata("design:type", Number)
98
99
  ], ServiceLineItem.prototype, "secondaryDiscountedPrice", void 0);
100
+ __decorate([
101
+ (0, typegoose_1.prop)({ type: Boolean }),
102
+ __metadata("design:type", Boolean)
103
+ ], ServiceLineItem.prototype, "isDiscountAppliedByCompany", void 0);
99
104
  //# sourceMappingURL=service-line-item.model.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"service-line-item.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/service-line-item.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiD;AACjD,qDAAiE;AACjE,oEAA0D;AAC1D,gEAAsD;AACtD,iEAAuD;AAEvD,MAAa,YAAY;IAEjB,IAAI,CAAU;IAGd,KAAK,CAAU;IAGf,WAAW,CAAU;IAGrB,QAAQ,CAAiB;IAGzB,YAAY,CAAU;IAGtB,qBAAqB,CAAU;CACtC;AAlBD,oCAkBC;AAhBO;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;0CACF;AAGd;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;2CACD;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;iDACK;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,oCAAa,EAAE,CAAC;8B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AI,EAAE,MAAM,EAAE,CAAC;;iEACkB","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\nimport { ServiceLineItemType } from '../../../../utilities/enum';\nimport { ServicePackage } from '../service-package.model';\nimport { ServiceAddon } from '../service-addon.model';\nimport { PreparingTime } from './preparing-time.model';\n\nexport class LineItemSnap {\n\t@prop({ type: String })\n\tpublic name?: string;\n\n\t@prop({ type: String })\n\tpublic image?: string;\n\n\t@prop({ type: String })\n\tpublic description?: string;\n\n\t@prop({ type: PreparingTime })\n\tpublic duration?: PreparingTime;\n\n\t@prop({ type: Number })\n\tpublic materialCost?: number;\n\n\t@prop({ type: Number })\n\tpublic secondaryMaterialCost?: number;\n}\n\n/**\n * A single line item in the service cart.\n *\n * Each line item is either a PACKAGE or an ADDON — never both.\n * The `lineItemType` field is the discriminator:\n *\n * - lineItemType = PACKAGE → `servicePackage` + `lineItemSnap` are set; addon field is absent.\n * - lineItemType = ADDON → `addon` + `lineItemSnap` are set; servicePackage field is absent.\n *\n * `price` — unit price of the item (package price or addon price).\n * `quantity` — how many units of this item are being booked.\n */\nexport class ServiceLineItem {\n\t@prop({ required: true, type: String, enum: ServiceLineItemType })\n\tpublic lineItemType!: ServiceLineItemType;\n\n\t@prop({ ref: () => ServicePackage })\n\tpublic servicePackage?: Ref<ServicePackage>;\n\n\t@prop({ ref: () => ServiceAddon })\n\tpublic addon?: Ref<ServiceAddon>;\n\n\t@prop({ required: true, type: Number })\n\tpublic price!: number;\n\n\t@prop({ required: true, type: Number, min: 1 })\n\tpublic quantity!: number;\n\n\t// Add these fileds when cart will be submitted\n\t@prop({ type: LineItemSnap, _id: false })\n\tpublic lineItemSnap?: LineItemSnap;\n\n\t@prop({ type: Number })\n\tpublic secondaryPrice?: number;\n\n\t@prop({ type: Number })\n\tpublic discountedPrice?: number;\n\n\t@prop({ type: Number })\n\tpublic secondaryDiscountedPrice?: number;\n}\n"]}
1
+ {"version":3,"file":"service-line-item.model.js","sourceRoot":"/","sources":["libraries/m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AI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,kCAAY,EAAE,CAAC;;8CACD;AAG1B;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;8CACjB;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;iDACtB;AAIlB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,YAAY,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC;8BACnB,YAAY;qDAAC;AAG5B;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;uDACQ;AAGxB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;wDACS;AAGzB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;iEACkB;AAGlC;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;;mEACoB","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\nimport { ServiceLineItemType } from '../../../../utilities/enum';\nimport { ServicePackage } from '../service-package.model';\nimport { ServiceAddon } from '../service-addon.model';\nimport { PreparingTime } from './preparing-time.model';\n\nexport class LineItemSnap {\n\t@prop({ type: String })\n\tpublic name?: string;\n\n\t@prop({ type: String })\n\tpublic image?: string;\n\n\t@prop({ type: String })\n\tpublic description?: string;\n\n\t@prop({ type: PreparingTime })\n\tpublic duration?: PreparingTime;\n\n\t@prop({ type: Number })\n\tpublic materialCost?: number;\n\n\t@prop({ type: Number })\n\tpublic secondaryMaterialCost?: number;\n}\n\n/**\n * A single line item in the service cart.\n *\n * Each line item is either a PACKAGE or an ADDON — never both.\n * The `lineItemType` field is the discriminator:\n *\n * - lineItemType = PACKAGE → `servicePackage` + `lineItemSnap` are set; addon field is absent.\n * - lineItemType = ADDON → `addon` + `lineItemSnap` are set; servicePackage field is absent.\n *\n * `price` — unit price of the item (package price or addon price).\n * `quantity` — how many units of this item are being booked.\n */\nexport class ServiceLineItem {\n\t@prop({ required: true, type: String, enum: ServiceLineItemType })\n\tpublic lineItemType!: ServiceLineItemType;\n\n\t@prop({ ref: () => ServicePackage })\n\tpublic servicePackage?: Ref<ServicePackage>;\n\n\t@prop({ ref: () => ServiceAddon })\n\tpublic addon?: Ref<ServiceAddon>;\n\n\t@prop({ required: true, type: Number })\n\tpublic price!: number;\n\n\t@prop({ required: true, type: Number, min: 1 })\n\tpublic quantity!: number;\n\n\t// Add these fileds when cart will be submitted\n\t@prop({ type: LineItemSnap, _id: false })\n\tpublic lineItemSnap?: LineItemSnap;\n\n\t@prop({ type: Number })\n\tpublic secondaryPrice?: number;\n\n\t@prop({ type: Number })\n\tpublic discountedPrice?: number;\n\n\t@prop({ type: Number })\n\tpublic secondaryDiscountedPrice?: number;\n\n\t@prop({ type: Boolean })\n\tpublic isDiscountAppliedByCompany?: boolean;\n}\n"]}
@@ -4,7 +4,7 @@ import { ReviewType } from '../../../../utilities/enum';
4
4
  import { Review } from '../review.model';
5
5
  import { Vendor } from '../vendor.model';
6
6
  export declare class ServiceBookingReview extends Review {
7
- reviewType: ReviewType.PROFESSIONAL;
7
+ reviewType: ReviewType.SERVICE_BOOKING;
8
8
  vendor: Ref<Vendor>;
9
9
  serviceBooking: Ref<ServiceBooking>;
10
10
  }
@@ -16,7 +16,7 @@ const enum_1 = require("../../../../utilities/enum");
16
16
  const review_model_1 = require("../review.model");
17
17
  const vendor_model_1 = require("../vendor.model");
18
18
  class ServiceBookingReview extends review_model_1.Review {
19
- reviewType = enum_1.ReviewType.PROFESSIONAL;
19
+ reviewType = enum_1.ReviewType.SERVICE_BOOKING;
20
20
  vendor;
21
21
  serviceBooking;
22
22
  }
@@ -1 +1 @@
1
- {"version":3,"file":"service-booking-review.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/service-booking-review.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiD;AACjD,oEAA0D;AAC1D,qDAAwD;AACxD,kDAAyC;AACzC,kDAAyC;AAEzC,MAAa,oBAAqB,SAAQ,qBAAM;IACxC,UAAU,GAAG,iBAAU,CAAC,YAAqB,CAAC;IAG9C,MAAM,CAAe;IAGrB,cAAc,CAAuB;CAC5C;AARD,oDAQC;AAJO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,qBAAM,EAAE,CAAC;;oDAChB;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,sCAAc,EAAE,CAAC;;4DACR","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\nimport { ServiceBooking } from '../service-booking.model';\nimport { ReviewType } from '../../../../utilities/enum';\nimport { Review } from '../review.model';\nimport { Vendor } from '../vendor.model';\n\nexport class ServiceBookingReview extends Review {\n\tpublic reviewType = ReviewType.PROFESSIONAL as const;\n\n\t@prop({ required: true, ref: () => Vendor })\n\tpublic vendor!: Ref<Vendor>;\n\n\t@prop({ required: true, ref: () => ServiceBooking })\n\tpublic serviceBooking!: Ref<ServiceBooking>;\n}\n"]}
1
+ {"version":3,"file":"service-booking-review.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/service-booking-review.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiD;AACjD,oEAA0D;AAC1D,qDAAwD;AACxD,kDAAyC;AACzC,kDAAyC;AAEzC,MAAa,oBAAqB,SAAQ,qBAAM;IACxC,UAAU,GAAG,iBAAU,CAAC,eAAwB,CAAC;IAGjD,MAAM,CAAe;IAGrB,cAAc,CAAuB;CAC5C;AARD,oDAQC;AAJO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,qBAAM,EAAE,CAAC;;oDAChB;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,sCAAc,EAAE,CAAC;;4DACR","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\nimport { ServiceBooking } from '../service-booking.model';\nimport { ReviewType } from '../../../../utilities/enum';\nimport { Review } from '../review.model';\nimport { Vendor } from '../vendor.model';\n\nexport class ServiceBookingReview extends Review {\n\tpublic reviewType = ReviewType.SERVICE_BOOKING as const;\n\n\t@prop({ required: true, ref: () => Vendor })\n\tpublic vendor!: Ref<Vendor>;\n\n\t@prop({ required: true, ref: () => ServiceBooking })\n\tpublic serviceBooking!: Ref<ServiceBooking>;\n}\n"]}
@@ -22,7 +22,7 @@ Perfect for sharing types between frontend and backend applications.
22
22
 
23
23
  ## Version
24
24
 
25
- Version: 1.4.62
25
+ Version: 1.4.63
26
26
 
27
27
  ## Dependencies
28
28
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lyxa.ai/types",
3
- "version": "1.4.62",
3
+ "version": "1.4.63",
4
4
  "description": "Lyxa type definitions and validation schemas for both frontend and backend",
5
5
  "author": "elie <42282499+Internalizable@users.noreply.github.com>",
6
6
  "license": "MIT",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lyxa.ai/core",
3
- "version": "1.4.62",
3
+ "version": "1.4.63",
4
4
  "description": "The Core system of the Lyxa services.",
5
5
  "author": "elie <42282499+Internalizable@users.noreply.github.com>",
6
6
  "license": "MIT",