@lyxa.ai/core 1.0.19 → 1.0.21

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.
Files changed (156) hide show
  1. package/dist/index.js +4 -0
  2. package/dist/index.js.map +1 -1
  3. package/dist/libraries/mongo/models/admin-access-control.model.js +13 -2
  4. package/dist/libraries/mongo/models/admin-access-control.model.js.map +1 -1
  5. package/dist/libraries/mongo/models/attribute.model.d.ts +1 -1
  6. package/dist/libraries/mongo/models/attribute.model.js +3 -2
  7. package/dist/libraries/mongo/models/attribute.model.js.map +1 -1
  8. package/dist/libraries/mongo/models/card.model.d.ts +24 -0
  9. package/dist/libraries/mongo/models/card.model.js +109 -0
  10. package/dist/libraries/mongo/models/card.model.js.map +1 -0
  11. package/dist/libraries/mongo/models/cart-participant.model.d.ts +17 -0
  12. package/dist/libraries/mongo/models/cart-participant.model.js +81 -0
  13. package/dist/libraries/mongo/models/cart-participant.model.js.map +1 -0
  14. package/dist/libraries/mongo/models/cart.model.d.ts +6 -9
  15. package/dist/libraries/mongo/models/cart.model.js +16 -33
  16. package/dist/libraries/mongo/models/cart.model.js.map +1 -1
  17. package/dist/libraries/mongo/models/category.model.d.ts +1 -2
  18. package/dist/libraries/mongo/models/category.model.js +2 -7
  19. package/dist/libraries/mongo/models/category.model.js.map +1 -1
  20. package/dist/libraries/mongo/models/core-auth-identity.model.d.ts +1 -2
  21. package/dist/libraries/mongo/models/core-auth-identity.model.js +1 -3
  22. package/dist/libraries/mongo/models/core-auth-identity.model.js.map +1 -1
  23. package/dist/libraries/mongo/models/core-user.model.d.ts +0 -2
  24. package/dist/libraries/mongo/models/core-user.model.js +2 -4
  25. package/dist/libraries/mongo/models/core-user.model.js.map +1 -1
  26. package/dist/libraries/mongo/models/embedded/addon.model.d.ts +8 -0
  27. package/dist/libraries/mongo/models/embedded/addon.model.js +34 -0
  28. package/dist/libraries/mongo/models/embedded/addon.model.js.map +1 -0
  29. package/dist/libraries/mongo/models/embedded/line-item-attribute.model.d.ts +7 -0
  30. package/dist/libraries/mongo/models/embedded/line-item-attribute.model.js +29 -0
  31. package/dist/libraries/mongo/models/embedded/line-item-attribute.model.js.map +1 -0
  32. package/dist/libraries/mongo/models/embedded/order-cancel.model.d.ts +7 -0
  33. package/dist/libraries/mongo/models/embedded/order-cancel.model.js +34 -0
  34. package/dist/libraries/mongo/models/embedded/order-cancel.model.js.map +1 -0
  35. package/dist/libraries/mongo/models/embedded/order-pricing.model.d.ts +18 -0
  36. package/dist/libraries/mongo/models/embedded/order-pricing.model.js +97 -0
  37. package/dist/libraries/mongo/models/embedded/order-pricing.model.js.map +1 -0
  38. package/dist/libraries/mongo/models/embedded/payment-attempt.model.d.ts +10 -0
  39. package/dist/libraries/mongo/models/embedded/payment-attempt.model.js +60 -0
  40. package/dist/libraries/mongo/models/embedded/payment-attempt.model.js.map +1 -0
  41. package/dist/libraries/mongo/models/embedded/payment-details.model.d.ts +9 -0
  42. package/dist/libraries/mongo/models/embedded/payment-details.model.js +52 -0
  43. package/dist/libraries/mongo/models/embedded/payment-details.model.js.map +1 -0
  44. package/dist/libraries/mongo/models/embedded/payment-infromation.model.d.ts +7 -0
  45. package/dist/libraries/mongo/models/embedded/payment-infromation.model.js +43 -0
  46. package/dist/libraries/mongo/models/embedded/payment-infromation.model.js.map +1 -0
  47. package/dist/libraries/mongo/models/embedded/portion.model.d.ts +5 -0
  48. package/dist/libraries/mongo/models/embedded/portion.model.js +32 -0
  49. package/dist/libraries/mongo/models/embedded/portion.model.js.map +1 -0
  50. package/dist/libraries/mongo/models/embedded/rider-equipment.model.d.ts +4 -0
  51. package/dist/libraries/mongo/models/embedded/rider-equipment.model.js +27 -0
  52. package/dist/libraries/mongo/models/embedded/rider-equipment.model.js.map +1 -0
  53. package/dist/libraries/mongo/models/embedded/status-timeline.model.d.ts +14 -0
  54. package/dist/libraries/mongo/models/embedded/status-timeline.model.js +59 -0
  55. package/dist/libraries/mongo/models/embedded/status-timeline.model.js.map +1 -0
  56. package/dist/libraries/mongo/models/embedded/zone-geometry.mode.d.ts +2 -1
  57. package/dist/libraries/mongo/models/embedded/zone-geometry.mode.js +2 -1
  58. package/dist/libraries/mongo/models/embedded/zone-geometry.mode.js.map +1 -1
  59. package/dist/libraries/mongo/models/faq.model.d.ts +0 -1
  60. package/dist/libraries/mongo/models/faq.model.js +0 -5
  61. package/dist/libraries/mongo/models/faq.model.js.map +1 -1
  62. package/dist/libraries/mongo/models/index.d.ts +46 -29
  63. package/dist/libraries/mongo/models/index.js +48 -31
  64. package/dist/libraries/mongo/models/index.js.map +1 -1
  65. package/dist/libraries/mongo/models/line-item.model.d.ts +19 -0
  66. package/dist/libraries/mongo/models/line-item.model.js +84 -0
  67. package/dist/libraries/mongo/models/line-item.model.js.map +1 -0
  68. package/dist/libraries/mongo/models/order-delivery.model.d.ts +24 -0
  69. package/dist/libraries/mongo/models/order-delivery.model.js +119 -0
  70. package/dist/libraries/mongo/models/order-delivery.model.js.map +1 -0
  71. package/dist/libraries/mongo/models/order-payment.model.d.ts +21 -0
  72. package/dist/libraries/mongo/models/order-payment.model.js +96 -0
  73. package/dist/libraries/mongo/models/order-payment.model.js.map +1 -0
  74. package/dist/libraries/mongo/models/order-pricing.model.d.ts +18 -0
  75. package/dist/libraries/mongo/models/order-pricing.model.js +88 -0
  76. package/dist/libraries/mongo/models/order-pricing.model.js.map +1 -0
  77. package/dist/libraries/mongo/models/order.model.d.ts +17 -1
  78. package/dist/libraries/mongo/models/order.model.js +83 -2
  79. package/dist/libraries/mongo/models/order.model.js.map +1 -1
  80. package/dist/libraries/mongo/models/product.model.js +1 -3
  81. package/dist/libraries/mongo/models/product.model.js.map +1 -1
  82. package/dist/libraries/mongo/models/providers/areeba-card.model.d.ts +14 -0
  83. package/dist/libraries/mongo/models/providers/areeba-card.model.js +69 -0
  84. package/dist/libraries/mongo/models/providers/areeba-card.model.js.map +1 -0
  85. package/dist/libraries/mongo/models/providers/core-apple-auth-identity.model.d.ts +0 -2
  86. package/dist/libraries/mongo/models/providers/core-apple-auth-identity.model.js +1 -4
  87. package/dist/libraries/mongo/models/providers/core-apple-auth-identity.model.js.map +1 -1
  88. package/dist/libraries/mongo/models/providers/core-email-auth-identity.model.d.ts +0 -2
  89. package/dist/libraries/mongo/models/providers/core-email-auth-identity.model.js +1 -4
  90. package/dist/libraries/mongo/models/providers/core-email-auth-identity.model.js.map +1 -1
  91. package/dist/libraries/mongo/models/providers/core-google-auth-identity.model.d.ts +0 -2
  92. package/dist/libraries/mongo/models/providers/core-google-auth-identity.model.js +1 -4
  93. package/dist/libraries/mongo/models/providers/core-google-auth-identity.model.js.map +1 -1
  94. package/dist/libraries/mongo/models/providers/core-phone-auth-identity.model.d.ts +0 -2
  95. package/dist/libraries/mongo/models/providers/core-phone-auth-identity.model.js +1 -4
  96. package/dist/libraries/mongo/models/providers/core-phone-auth-identity.model.js.map +1 -1
  97. package/dist/libraries/mongo/models/providers/courier-order.model.d.ts +23 -0
  98. package/dist/libraries/mongo/models/providers/courier-order.model.js +89 -0
  99. package/dist/libraries/mongo/models/providers/courier-order.model.js.map +1 -0
  100. package/dist/libraries/mongo/models/providers/regular-order.model.d.ts +23 -0
  101. package/dist/libraries/mongo/models/providers/regular-order.model.js +85 -0
  102. package/dist/libraries/mongo/models/providers/regular-order.model.js.map +1 -0
  103. package/dist/libraries/mongo/models/rating-setting.model.d.ts +1 -0
  104. package/dist/libraries/mongo/models/rating-setting.model.js +11 -2
  105. package/dist/libraries/mongo/models/rating-setting.model.js.map +1 -1
  106. package/dist/libraries/mongo/models/request-area.model.d.ts +2 -2
  107. package/dist/libraries/mongo/models/request-area.model.js +2 -2
  108. package/dist/libraries/mongo/models/request-area.model.js.map +1 -1
  109. package/dist/libraries/mongo/models/rider-timeout.model.d.ts +10 -0
  110. package/dist/libraries/mongo/models/rider-timeout.model.js +47 -0
  111. package/dist/libraries/mongo/models/rider-timeout.model.js.map +1 -0
  112. package/dist/libraries/mongo/models/rider-tracking.model.d.ts +10 -0
  113. package/dist/libraries/mongo/models/rider-tracking.model.js +47 -0
  114. package/dist/libraries/mongo/models/rider-tracking.model.js.map +1 -0
  115. package/dist/libraries/mongo/models/rider.model.d.ts +50 -1
  116. package/dist/libraries/mongo/models/rider.model.js +238 -2
  117. package/dist/libraries/mongo/models/rider.model.js.map +1 -1
  118. package/dist/libraries/mongo/models/shared/address.model.d.ts +6 -3
  119. package/dist/libraries/mongo/models/shared/address.model.js +24 -13
  120. package/dist/libraries/mongo/models/shared/address.model.js.map +1 -1
  121. package/dist/libraries/mongo/models/shared/geo-location.model.d.ts +4 -0
  122. package/dist/libraries/mongo/models/shared/geo-location.model.js +27 -0
  123. package/dist/libraries/mongo/models/shared/geo-location.model.js.map +1 -0
  124. package/dist/libraries/mongo/models/shop-category.model.d.ts +1 -0
  125. package/dist/libraries/mongo/models/shop-category.model.js +7 -1
  126. package/dist/libraries/mongo/models/shop-category.model.js.map +1 -1
  127. package/dist/libraries/mongo/models/shop.model.d.ts +1 -1
  128. package/dist/libraries/mongo/models/shop.model.js +2 -2
  129. package/dist/libraries/mongo/models/shop.model.js.map +1 -1
  130. package/dist/libraries/mongo/models/user.model.d.ts +30 -0
  131. package/dist/libraries/mongo/models/user.model.js +129 -0
  132. package/dist/libraries/mongo/models/user.model.js.map +1 -0
  133. package/dist/libraries/mongo/models/zone.model.d.ts +5 -5
  134. package/dist/libraries/mongo/models/zone.model.js +11 -11
  135. package/dist/libraries/mongo/models/zone.model.js.map +1 -1
  136. package/dist/libraries/mongo/plugins/soft-delete-plugin.d.ts +8 -5
  137. package/dist/libraries/mongo/plugins/soft-delete-plugin.js +28 -0
  138. package/dist/libraries/mongo/plugins/soft-delete-plugin.js.map +1 -1
  139. package/dist/utilities/enum.d.ts +87 -9
  140. package/dist/utilities/enum.js +103 -9
  141. package/dist/utilities/enum.js.map +1 -1
  142. package/dist/utilities/pagination.d.ts +4 -1
  143. package/dist/utilities/pagination.js +44 -4
  144. package/dist/utilities/pagination.js.map +1 -1
  145. package/dist/utilities/response.js +1 -1
  146. package/dist/utilities/response.js.map +1 -1
  147. package/dist/utilities/transformers.d.ts +14 -3
  148. package/dist/utilities/transformers.js +37 -6
  149. package/dist/utilities/transformers.js.map +1 -1
  150. package/dist/utilities/validation/common-validation.d.ts +354 -29
  151. package/dist/utilities/validation/common-validation.js +39 -10
  152. package/dist/utilities/validation/common-validation.js.map +1 -1
  153. package/dist/utilities/validation/global-validation.d.ts +49 -20
  154. package/dist/utilities/validation/global-validation.js +6 -4
  155. package/dist/utilities/validation/global-validation.js.map +1 -1
  156. package/package.json +2 -2
@@ -0,0 +1,14 @@
1
+ import { Card } from '../card.model';
2
+ import { AreebaCardStatus } from '../../../../utilities/enum';
3
+ export declare class AreebaCard extends Card {
4
+ orderId?: string;
5
+ sessionId?: string;
6
+ brand?: string;
7
+ expiry?: string;
8
+ fundingMethod?: string;
9
+ nameOnCard?: string;
10
+ number?: string;
11
+ scheme?: string;
12
+ token?: string;
13
+ status?: AreebaCardStatus;
14
+ }
@@ -0,0 +1,69 @@
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.AreebaCard = void 0;
13
+ const typegoose_1 = require("@typegoose/typegoose");
14
+ const card_model_1 = require("../card.model");
15
+ const enum_1 = require("../../../../utilities/enum");
16
+ class AreebaCard extends card_model_1.Card {
17
+ orderId;
18
+ sessionId;
19
+ brand;
20
+ expiry;
21
+ fundingMethod;
22
+ nameOnCard;
23
+ number;
24
+ scheme;
25
+ token;
26
+ status;
27
+ }
28
+ exports.AreebaCard = AreebaCard;
29
+ __decorate([
30
+ (0, typegoose_1.prop)({ type: String }),
31
+ __metadata("design:type", String)
32
+ ], AreebaCard.prototype, "orderId", void 0);
33
+ __decorate([
34
+ (0, typegoose_1.prop)({ type: String }),
35
+ __metadata("design:type", String)
36
+ ], AreebaCard.prototype, "sessionId", void 0);
37
+ __decorate([
38
+ (0, typegoose_1.prop)({ type: String }),
39
+ __metadata("design:type", String)
40
+ ], AreebaCard.prototype, "brand", void 0);
41
+ __decorate([
42
+ (0, typegoose_1.prop)({ type: String }),
43
+ __metadata("design:type", String)
44
+ ], AreebaCard.prototype, "expiry", void 0);
45
+ __decorate([
46
+ (0, typegoose_1.prop)({ type: String }),
47
+ __metadata("design:type", String)
48
+ ], AreebaCard.prototype, "fundingMethod", void 0);
49
+ __decorate([
50
+ (0, typegoose_1.prop)({ type: String }),
51
+ __metadata("design:type", String)
52
+ ], AreebaCard.prototype, "nameOnCard", void 0);
53
+ __decorate([
54
+ (0, typegoose_1.prop)({ type: String }),
55
+ __metadata("design:type", String)
56
+ ], AreebaCard.prototype, "number", void 0);
57
+ __decorate([
58
+ (0, typegoose_1.prop)({ type: String }),
59
+ __metadata("design:type", String)
60
+ ], AreebaCard.prototype, "scheme", void 0);
61
+ __decorate([
62
+ (0, typegoose_1.prop)({ type: String }),
63
+ __metadata("design:type", String)
64
+ ], AreebaCard.prototype, "token", void 0);
65
+ __decorate([
66
+ (0, typegoose_1.prop)({ type: String, enum: enum_1.AreebaCardStatus, default: enum_1.AreebaCardStatus.PENDING }),
67
+ __metadata("design:type", String)
68
+ ], AreebaCard.prototype, "status", void 0);
69
+ //# sourceMappingURL=areeba-card.model.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"areeba-card.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/areeba-card.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,8CAAqC;AACrC,qDAA8D;AAE9D,MAAa,UAAW,SAAQ,iBAAI;IAE5B,OAAO,CAAU;IAGjB,SAAS,CAAU;IAGnB,KAAK,CAAU;IAGf,MAAM,CAAU;IAGhB,aAAa,CAAU;IAGvB,UAAU,CAAU;IAGpB,MAAM,CAAU;IAGhB,MAAM,CAAU;IAGhB,KAAK,CAAU;IAGf,MAAM,CAAoB;CACjC;AA9BD,gCA8BC;AA5BO;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;2CACC;AAGjB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;6CACG;AAGnB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;yCACD;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;0CACA;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;iDACO;AAGvB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;8CACI;AAGpB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;0CACA;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;0CACA;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;yCACD;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,uBAAgB,EAAE,OAAO,EAAE,uBAAgB,CAAC,OAAO,EAAE,CAAC;;0CACjD","sourcesContent":["import { prop } from '@typegoose/typegoose';\r\nimport { Card } from '../card.model';\r\nimport { AreebaCardStatus } from '../../../../utilities/enum';\r\n\r\nexport class AreebaCard extends Card {\r\n\t@prop({ type: String })\r\n\tpublic orderId?: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic sessionId?: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic brand?: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic expiry?: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic fundingMethod?: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic nameOnCard?: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic number?: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic scheme?: string;\r\n\r\n\t@prop({ type: String })\r\n\tpublic token?: string;\r\n\r\n\t@prop({ type: String, enum: AreebaCardStatus, default: AreebaCardStatus.PENDING })\r\n\tpublic status?: AreebaCardStatus;\r\n}\r\n"]}
@@ -1,6 +1,4 @@
1
- import { ReturnModelType } from '@typegoose/typegoose';
2
1
  import { CoreAuthIdentity } from '../core-auth-identity.model';
3
2
  export declare class CoreAppleAuthIdentity extends CoreAuthIdentity {
4
3
  token: string;
5
4
  }
6
- export declare const CoreAppleAuthIdentityModel: ReturnModelType<typeof CoreAppleAuthIdentity>;
@@ -9,11 +9,9 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.CoreAppleAuthIdentityModel = exports.CoreAppleAuthIdentity = void 0;
12
+ exports.CoreAppleAuthIdentity = void 0;
13
13
  const typegoose_1 = require("@typegoose/typegoose");
14
14
  const core_auth_identity_model_1 = require("../core-auth-identity.model");
15
- const enum_1 = require("../../../../utilities/enum");
16
- const mongo_1 = require("../../../mongo");
17
15
  class CoreAppleAuthIdentity extends core_auth_identity_model_1.CoreAuthIdentity {
18
16
  token;
19
17
  }
@@ -22,5 +20,4 @@ __decorate([
22
20
  (0, typegoose_1.prop)({ required: true, type: String }),
23
21
  __metadata("design:type", String)
24
22
  ], CoreAppleAuthIdentity.prototype, "token", void 0);
25
- exports.CoreAppleAuthIdentityModel = (0, mongo_1.createGlobalDiscriminatorModel)(core_auth_identity_model_1.CoreAuthIdentityModel, CoreAppleAuthIdentity, enum_1.CoreAuthIdentityType.APPLE);
26
23
  //# sourceMappingURL=core-apple-auth-identity.model.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"core-apple-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-apple-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,KAAK,CAAU;CACtB;AAHD,sDAGC;AADO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACjB;AAGV,QAAA,0BAA0B,GACtC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,qBAAqB,EAAE,2BAAoB,CAAC,KAAK,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\nimport { CoreAuthIdentity, CoreAuthIdentityModel } from '../core-auth-identity.model';\nimport { CoreAuthIdentityType } from '../../../../utilities/enum';\nimport { createGlobalDiscriminatorModel } from '../../../mongo';\n\nexport class CoreAppleAuthIdentity extends CoreAuthIdentity {\n\t@prop({ required: true, type: String })\n\tpublic token!: string;\n}\n\nexport const CoreAppleAuthIdentityModel: ReturnModelType<typeof CoreAppleAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreAppleAuthIdentity, CoreAuthIdentityType.APPLE);\n"]}
1
+ {"version":3,"file":"core-apple-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-apple-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,0EAA+D;AAE/D,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,KAAK,CAAU;CACtB;AAHD,sDAGC;AADO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACjB","sourcesContent":["import { prop } from '@typegoose/typegoose';\r\nimport { CoreAuthIdentity } from '../core-auth-identity.model';\r\n\r\nexport class CoreAppleAuthIdentity extends CoreAuthIdentity {\r\n\t@prop({ required: true, type: String })\r\n\tpublic token!: string;\r\n}\r\n"]}
@@ -1,4 +1,3 @@
1
- import { ReturnModelType } from '@typegoose/typegoose';
2
1
  import { CoreAuthIdentity } from '../core-auth-identity.model';
3
2
  import { OTPFields } from '../embedded/otp-fields.model';
4
3
  export declare class CoreEmailAuthIdentity extends CoreAuthIdentity {
@@ -6,4 +5,3 @@ export declare class CoreEmailAuthIdentity extends CoreAuthIdentity {
6
5
  password: string;
7
6
  otp: OTPFields;
8
7
  }
9
- export declare const CoreEmailAuthIdentityModel: ReturnModelType<typeof CoreEmailAuthIdentity>;
@@ -9,12 +9,10 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.CoreEmailAuthIdentityModel = exports.CoreEmailAuthIdentity = void 0;
12
+ exports.CoreEmailAuthIdentity = void 0;
13
13
  const typegoose_1 = require("@typegoose/typegoose");
14
14
  const core_auth_identity_model_1 = require("../core-auth-identity.model");
15
15
  const otp_fields_model_1 = require("../embedded/otp-fields.model");
16
- const enum_1 = require("../../../../utilities/enum");
17
- const mongo_1 = require("../../../mongo");
18
16
  class CoreEmailAuthIdentity extends core_auth_identity_model_1.CoreAuthIdentity {
19
17
  email;
20
18
  password;
@@ -33,5 +31,4 @@ __decorate([
33
31
  (0, typegoose_1.prop)({ required: true, type: otp_fields_model_1.OTPFields }),
34
32
  __metadata("design:type", otp_fields_model_1.OTPFields)
35
33
  ], CoreEmailAuthIdentity.prototype, "otp", void 0);
36
- exports.CoreEmailAuthIdentityModel = (0, mongo_1.createGlobalDiscriminatorModel)(core_auth_identity_model_1.CoreAuthIdentityModel, CoreEmailAuthIdentity, enum_1.CoreAuthIdentityType.EMAIL);
37
34
  //# sourceMappingURL=core-email-auth-identity.model.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"core-email-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-email-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,mEAAyD;AACzD,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,KAAK,CAAU;IAGf,QAAQ,CAAU;IAGlB,GAAG,CAAa;CACvB;AATD,sDASC;AAPO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACjB;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;uDACd;AAGlB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,4BAAS,EAAE,CAAC;8BAC7B,4BAAS;kDAAC;AAGX,QAAA,0BAA0B,GACtC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,qBAAqB,EAAE,2BAAoB,CAAC,KAAK,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\nimport { CoreAuthIdentity, CoreAuthIdentityModel } from '../core-auth-identity.model';\nimport { OTPFields } from '../embedded/otp-fields.model';\nimport { CoreAuthIdentityType } from '../../../../utilities/enum';\nimport { createGlobalDiscriminatorModel } from '../../../mongo';\n\nexport class CoreEmailAuthIdentity extends CoreAuthIdentity {\n\t@prop({ required: true, type: String })\n\tpublic email!: string;\n\n\t@prop({ required: true, type: String })\n\tpublic password!: string;\n\n\t@prop({ required: true, type: OTPFields })\n\tpublic otp!: OTPFields;\n}\n\nexport const CoreEmailAuthIdentityModel: ReturnModelType<typeof CoreEmailAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreEmailAuthIdentity, CoreAuthIdentityType.EMAIL);\n"]}
1
+ {"version":3,"file":"core-email-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-email-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,0EAA+D;AAC/D,mEAAyD;AAEzD,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,KAAK,CAAU;IAGf,QAAQ,CAAU;IAGlB,GAAG,CAAa;CACvB;AATD,sDASC;AAPO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;oDACjB;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;uDACd;AAGlB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,4BAAS,EAAE,CAAC;8BAC7B,4BAAS;kDAAC","sourcesContent":["import { prop } from '@typegoose/typegoose';\r\nimport { CoreAuthIdentity } from '../core-auth-identity.model';\r\nimport { OTPFields } from '../embedded/otp-fields.model';\r\n\r\nexport class CoreEmailAuthIdentity extends CoreAuthIdentity {\r\n\t@prop({ required: true, type: String })\r\n\tpublic email!: string;\r\n\r\n\t@prop({ required: true, type: String })\r\n\tpublic password!: string;\r\n\r\n\t@prop({ required: true, type: OTPFields })\r\n\tpublic otp!: OTPFields;\r\n}\r\n"]}
@@ -1,6 +1,4 @@
1
- import { ReturnModelType } from '@typegoose/typegoose';
2
1
  import { CoreAuthIdentity } from '../core-auth-identity.model';
3
2
  export declare class CoreGoogleAuthIdentity extends CoreAuthIdentity {
4
3
  token: string;
5
4
  }
6
- export declare const CoreGoogleAuthIdentityModel: ReturnModelType<typeof CoreGoogleAuthIdentity>;
@@ -9,11 +9,9 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.CoreGoogleAuthIdentityModel = exports.CoreGoogleAuthIdentity = void 0;
12
+ exports.CoreGoogleAuthIdentity = void 0;
13
13
  const typegoose_1 = require("@typegoose/typegoose");
14
14
  const core_auth_identity_model_1 = require("../core-auth-identity.model");
15
- const enum_1 = require("../../../../utilities/enum");
16
- const mongo_1 = require("../../../mongo");
17
15
  class CoreGoogleAuthIdentity extends core_auth_identity_model_1.CoreAuthIdentity {
18
16
  token;
19
17
  }
@@ -22,5 +20,4 @@ __decorate([
22
20
  (0, typegoose_1.prop)({ required: true, type: String }),
23
21
  __metadata("design:type", String)
24
22
  ], CoreGoogleAuthIdentity.prototype, "token", void 0);
25
- exports.CoreGoogleAuthIdentityModel = (0, mongo_1.createGlobalDiscriminatorModel)(core_auth_identity_model_1.CoreAuthIdentityModel, CoreGoogleAuthIdentity, enum_1.CoreAuthIdentityType.GOOGLE);
26
23
  //# sourceMappingURL=core-google-auth-identity.model.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"core-google-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-google-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,sBAAuB,SAAQ,2CAAgB;IAEpD,KAAK,CAAU;CACtB;AAHD,wDAGC;AADO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;qDACjB;AAGV,QAAA,2BAA2B,GACvC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,sBAAsB,EAAE,2BAAoB,CAAC,MAAM,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\nimport { CoreAuthIdentity, CoreAuthIdentityModel } from '../core-auth-identity.model';\nimport { CoreAuthIdentityType } from '../../../../utilities/enum';\nimport { createGlobalDiscriminatorModel } from '../../../mongo';\n\nexport class CoreGoogleAuthIdentity extends CoreAuthIdentity {\n\t@prop({ required: true, type: String })\n\tpublic token!: string;\n}\n\nexport const CoreGoogleAuthIdentityModel: ReturnModelType<typeof CoreGoogleAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CoreGoogleAuthIdentity, CoreAuthIdentityType.GOOGLE);\n"]}
1
+ {"version":3,"file":"core-google-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-google-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,0EAA+D;AAE/D,MAAa,sBAAuB,SAAQ,2CAAgB;IAEpD,KAAK,CAAU;CACtB;AAHD,wDAGC;AADO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;qDACjB","sourcesContent":["import { prop } from '@typegoose/typegoose';\r\nimport { CoreAuthIdentity } from '../core-auth-identity.model';\r\n\r\nexport class CoreGoogleAuthIdentity extends CoreAuthIdentity {\r\n\t@prop({ required: true, type: String })\r\n\tpublic token!: string;\r\n}\r\n"]}
@@ -1,8 +1,6 @@
1
- import { ReturnModelType } from '@typegoose/typegoose';
2
1
  import { CoreAuthIdentity } from '../core-auth-identity.model';
3
2
  import { OTPFields } from '../embedded/otp-fields.model';
4
3
  export declare class CorePhoneAuthIdentity extends CoreAuthIdentity {
5
4
  phoneNumber: string;
6
5
  otp: OTPFields;
7
6
  }
8
- export declare const CorePhoneAuthIdentityModel: ReturnModelType<typeof CorePhoneAuthIdentity>;
@@ -9,12 +9,10 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.CorePhoneAuthIdentityModel = exports.CorePhoneAuthIdentity = void 0;
12
+ exports.CorePhoneAuthIdentity = void 0;
13
13
  const typegoose_1 = require("@typegoose/typegoose");
14
14
  const core_auth_identity_model_1 = require("../core-auth-identity.model");
15
15
  const otp_fields_model_1 = require("../embedded/otp-fields.model");
16
- const enum_1 = require("../../../../utilities/enum");
17
- const mongo_1 = require("../../../mongo");
18
16
  class CorePhoneAuthIdentity extends core_auth_identity_model_1.CoreAuthIdentity {
19
17
  phoneNumber;
20
18
  otp;
@@ -28,5 +26,4 @@ __decorate([
28
26
  (0, typegoose_1.prop)({ required: true, type: otp_fields_model_1.OTPFields }),
29
27
  __metadata("design:type", otp_fields_model_1.OTPFields)
30
28
  ], CorePhoneAuthIdentity.prototype, "otp", void 0);
31
- exports.CorePhoneAuthIdentityModel = (0, mongo_1.createGlobalDiscriminatorModel)(core_auth_identity_model_1.CoreAuthIdentityModel, CorePhoneAuthIdentity, enum_1.CoreAuthIdentityType.PHONE);
32
29
  //# sourceMappingURL=core-phone-auth-identity.model.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"core-phone-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-phone-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA6D;AAC7D,0EAAsF;AACtF,mEAAyD;AACzD,qDAAkE;AAClE,0CAAgE;AAEhE,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,WAAW,CAAU;IAGrB,GAAG,CAAa;CACvB;AAND,sDAMC;AAJO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;0DACX;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,4BAAS,EAAE,CAAC;8BAC7B,4BAAS;kDAAC;AAGX,QAAA,0BAA0B,GACtC,IAAA,sCAA8B,EAAC,gDAAqB,EAAE,qBAAqB,EAAE,2BAAoB,CAAC,KAAK,CAAC,CAAC","sourcesContent":["import { prop, ReturnModelType } from '@typegoose/typegoose';\nimport { CoreAuthIdentity, CoreAuthIdentityModel } from '../core-auth-identity.model';\nimport { OTPFields } from '../embedded/otp-fields.model';\nimport { CoreAuthIdentityType } from '../../../../utilities/enum';\nimport { createGlobalDiscriminatorModel } from '../../../mongo';\n\nexport class CorePhoneAuthIdentity extends CoreAuthIdentity {\n\t@prop({ required: true, type: String })\n\tpublic phoneNumber!: string;\n\n\t@prop({ required: true, type: OTPFields })\n\tpublic otp!: OTPFields;\n}\n\nexport const CorePhoneAuthIdentityModel: ReturnModelType<typeof CorePhoneAuthIdentity> =\n\tcreateGlobalDiscriminatorModel(CoreAuthIdentityModel, CorePhoneAuthIdentity, CoreAuthIdentityType.PHONE);\n"]}
1
+ {"version":3,"file":"core-phone-auth-identity.model.js","sourceRoot":"/","sources":["libraries/mongo/models/providers/core-phone-auth-identity.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA4C;AAC5C,0EAA+D;AAC/D,mEAAyD;AAEzD,MAAa,qBAAsB,SAAQ,2CAAgB;IAEnD,WAAW,CAAU;IAGrB,GAAG,CAAa;CACvB;AAND,sDAMC;AAJO;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;0DACX;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,4BAAS,EAAE,CAAC;8BAC7B,4BAAS;kDAAC","sourcesContent":["import { prop } from '@typegoose/typegoose';\r\nimport { CoreAuthIdentity } from '../core-auth-identity.model';\r\nimport { OTPFields } from '../embedded/otp-fields.model';\r\n\r\nexport class CorePhoneAuthIdentity extends CoreAuthIdentity {\r\n\t@prop({ required: true, type: String })\r\n\tpublic phoneNumber!: string;\r\n\r\n\t@prop({ required: true, type: OTPFields })\r\n\tpublic otp!: OTPFields;\r\n}\r\n"]}
@@ -0,0 +1,23 @@
1
+ import { Order } from '../order.model';
2
+ import { CourierOrderStatus, CourierServiceType, OrderType } from '../../../../utilities/enum';
3
+ import { CourierAddress } from '../shared/address.model';
4
+ import { CourierOrderStatusTimeline } from '../embedded/status-timeline.model';
5
+ declare class CourierItem {
6
+ productName: string;
7
+ productImage?: string;
8
+ quantity: number;
9
+ unitPrice?: number;
10
+ secondaryUnitPrice?: number;
11
+ totalPrice?: number;
12
+ secondaryTotalPrice?: number;
13
+ }
14
+ export declare class CourierOrder extends Order {
15
+ orderType: OrderType.COURIER;
16
+ status?: CourierOrderStatus;
17
+ statusTimeline: CourierOrderStatusTimeline[];
18
+ courierType: CourierServiceType;
19
+ pickupLocation: CourierAddress;
20
+ deliveryLocation: CourierAddress;
21
+ items?: CourierItem[];
22
+ }
23
+ export {};
@@ -0,0 +1,89 @@
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.CourierOrder = void 0;
13
+ const typegoose_1 = require("@typegoose/typegoose");
14
+ const order_model_1 = require("../order.model");
15
+ const enum_1 = require("../../../../utilities/enum");
16
+ const address_model_1 = require("../shared/address.model");
17
+ const status_timeline_model_1 = require("../embedded/status-timeline.model");
18
+ class CourierItem {
19
+ productName;
20
+ productImage;
21
+ quantity;
22
+ unitPrice;
23
+ secondaryUnitPrice;
24
+ totalPrice;
25
+ secondaryTotalPrice;
26
+ }
27
+ __decorate([
28
+ (0, typegoose_1.prop)({ required: true }),
29
+ __metadata("design:type", String)
30
+ ], CourierItem.prototype, "productName", void 0);
31
+ __decorate([
32
+ (0, typegoose_1.prop)(),
33
+ __metadata("design:type", String)
34
+ ], CourierItem.prototype, "productImage", void 0);
35
+ __decorate([
36
+ (0, typegoose_1.prop)({ required: true, min: 1 }),
37
+ __metadata("design:type", Number)
38
+ ], CourierItem.prototype, "quantity", void 0);
39
+ __decorate([
40
+ (0, typegoose_1.prop)(),
41
+ __metadata("design:type", Number)
42
+ ], CourierItem.prototype, "unitPrice", void 0);
43
+ __decorate([
44
+ (0, typegoose_1.prop)(),
45
+ __metadata("design:type", Number)
46
+ ], CourierItem.prototype, "secondaryUnitPrice", void 0);
47
+ __decorate([
48
+ (0, typegoose_1.prop)(),
49
+ __metadata("design:type", Number)
50
+ ], CourierItem.prototype, "totalPrice", void 0);
51
+ __decorate([
52
+ (0, typegoose_1.prop)(),
53
+ __metadata("design:type", Number)
54
+ ], CourierItem.prototype, "secondaryTotalPrice", void 0);
55
+ class CourierOrder extends order_model_1.Order {
56
+ orderType = enum_1.OrderType.COURIER;
57
+ status;
58
+ statusTimeline;
59
+ courierType;
60
+ pickupLocation;
61
+ deliveryLocation;
62
+ items;
63
+ }
64
+ exports.CourierOrder = CourierOrder;
65
+ __decorate([
66
+ (0, typegoose_1.prop)({ type: String, enum: enum_1.CourierOrderStatus, default: enum_1.CourierOrderStatus.PLACED }),
67
+ __metadata("design:type", String)
68
+ ], CourierOrder.prototype, "status", void 0);
69
+ __decorate([
70
+ (0, typegoose_1.prop)({ type: () => [status_timeline_model_1.CourierOrderStatusTimeline], default: [] }),
71
+ __metadata("design:type", Array)
72
+ ], CourierOrder.prototype, "statusTimeline", void 0);
73
+ __decorate([
74
+ (0, typegoose_1.prop)({ required: true, type: String, enum: enum_1.CourierServiceType }),
75
+ __metadata("design:type", String)
76
+ ], CourierOrder.prototype, "courierType", void 0);
77
+ __decorate([
78
+ (0, typegoose_1.prop)({ required: true, type: () => address_model_1.CourierAddress }),
79
+ __metadata("design:type", address_model_1.CourierAddress)
80
+ ], CourierOrder.prototype, "pickupLocation", void 0);
81
+ __decorate([
82
+ (0, typegoose_1.prop)({ required: true, type: address_model_1.CourierAddress }),
83
+ __metadata("design:type", address_model_1.CourierAddress)
84
+ ], CourierOrder.prototype, "deliveryLocation", void 0);
85
+ __decorate([
86
+ (0, typegoose_1.prop)({ type: () => [CourierItem], default: [] }),
87
+ __metadata("design:type", Array)
88
+ ], CourierOrder.prototype, "items", void 0);
89
+ //# sourceMappingURL=courier-order.model.js.map
@@ -0,0 +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;AAE/E,MAAM,WAAW;IAEhB,WAAW,CAAS;IAGpB,YAAY,CAAU;IAGtB,QAAQ,CAAS;IAGjB,SAAS,CAAU;IAGnB,kBAAkB,CAAU;IAG5B,UAAU,CAAU;IAGpB,mBAAmB,CAAU;CAC7B;AAnBA;IADC,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;gDACL;AAGpB;IADC,IAAA,gBAAI,GAAE;;iDACe;AAGtB;IADC,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;6CAChB;AAGjB;IADC,IAAA,gBAAI,GAAE;;8CACY;AAGnB;IADC,IAAA,gBAAI,GAAE;;uDACqB;AAG5B;IADC,IAAA,gBAAI,GAAE;;+CACa;AAGpB;IADC,IAAA,gBAAI,GAAE;;wDACsB;AAG9B,MAAa,YAAa,SAAQ,mBAAK;IAC/B,SAAS,GAAG,gBAAS,CAAC,OAAgB,CAAC;IAGvC,MAAM,CAAsB;IAG5B,cAAc,CAA+B;IAGpD,WAAW,CAAsB;IAGjC,cAAc,CAAkB;IAGhC,gBAAgB,CAAkB;IAGlC,KAAK,CAAiB;CACtB;AApBD,oCAoBC;AAhBO;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;AAGpD;IADC,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,yBAAkB,EAAE,CAAC;;iDAChC;AAGjC;IADC,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,8BAAc,EAAE,CAAC;8BACpC,8BAAc;oDAAC;AAGhC;IADC,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,8BAAc,EAAE,CAAC;8BAC5B,8BAAc;sDAAC;AAGlC;IADC,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,WAAW,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;2CAC3B","sourcesContent":["import { prop } from '@typegoose/typegoose';\r\nimport { Order } from '../order.model';\r\nimport { CourierOrderStatus, CourierServiceType, OrderType } from '../../../../utilities/enum';\r\nimport { CourierAddress } from '../shared/address.model';\r\nimport { CourierOrderStatusTimeline } from '../embedded/status-timeline.model';\r\n\r\nclass CourierItem {\r\n\t@prop({ required: true })\r\n\tproductName: string;\r\n\r\n\t@prop()\r\n\tproductImage?: string;\r\n\r\n\t@prop({ required: true, min: 1 })\r\n\tquantity: number;\r\n\r\n\t@prop()\r\n\tunitPrice?: number;\r\n\r\n\t@prop()\r\n\tsecondaryUnitPrice?: number;\r\n\r\n\t@prop()\r\n\ttotalPrice?: number;\r\n\r\n\t@prop()\r\n\tsecondaryTotalPrice?: number;\r\n}\r\n\r\nexport class CourierOrder extends Order {\r\n\tpublic orderType = OrderType.COURIER as const;\r\n\r\n\t@prop({ type: String, enum: CourierOrderStatus, default: CourierOrderStatus.PLACED })\r\n\tpublic status?: CourierOrderStatus;\r\n\r\n\t@prop({ type: () => [CourierOrderStatusTimeline], default: [] })\r\n\tpublic statusTimeline: CourierOrderStatusTimeline[];\r\n\r\n\t@prop({ required: true, type: String, enum: CourierServiceType })\r\n\tcourierType!: CourierServiceType;\r\n\r\n\t@prop({ required: true, type: () => CourierAddress })\r\n\tpickupLocation!: CourierAddress;\r\n\r\n\t@prop({ required: true, type: CourierAddress })\r\n\tdeliveryLocation!: CourierAddress;\r\n\r\n\t@prop({ type: () => [CourierItem], default: [] })\r\n\titems?: CourierItem[];\r\n}\r\n"]}
@@ -0,0 +1,23 @@
1
+ import { Ref } from '@typegoose/typegoose';
2
+ import { Order } from '../order.model';
3
+ import { OrderType } from '../../../../utilities/enum';
4
+ import { Parent } from '../parent.model';
5
+ import { Shop } from '../shop.model';
6
+ import { Cart } from '../cart.model';
7
+ import { Address, UserAddress } from '../shared/address.model';
8
+ import { RegularOrderStatusTimeline } from '../embedded/status-timeline.model';
9
+ export declare class RegularOrder extends Order {
10
+ orderType: OrderType.REGULAR;
11
+ status?: string;
12
+ statusTimeline: RegularOrderStatusTimeline[];
13
+ itemType?: string;
14
+ pickupLocation: Address;
15
+ deliveryLocation: UserAddress;
16
+ parent?: Ref<Parent>;
17
+ shop?: Ref<Shop>;
18
+ cart?: Ref<Cart>;
19
+ isShopDelivery?: boolean;
20
+ preparingTimeInMinutes?: number;
21
+ isReplacementOrder?: boolean;
22
+ originalOrderForReplacement?: Ref<Order>;
23
+ }
@@ -0,0 +1,85 @@
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.RegularOrder = void 0;
13
+ const typegoose_1 = require("@typegoose/typegoose");
14
+ const order_model_1 = require("../order.model");
15
+ const enum_1 = require("../../../../utilities/enum");
16
+ const parent_model_1 = require("../parent.model");
17
+ const shop_model_1 = require("../shop.model");
18
+ const cart_model_1 = require("../cart.model");
19
+ const address_model_1 = require("../shared/address.model");
20
+ const status_timeline_model_1 = require("../embedded/status-timeline.model");
21
+ class RegularOrder extends order_model_1.Order {
22
+ orderType = enum_1.OrderType.REGULAR;
23
+ status;
24
+ statusTimeline;
25
+ itemType;
26
+ pickupLocation;
27
+ deliveryLocation;
28
+ parent;
29
+ shop;
30
+ cart;
31
+ isShopDelivery;
32
+ preparingTimeInMinutes;
33
+ isReplacementOrder;
34
+ originalOrderForReplacement;
35
+ }
36
+ exports.RegularOrder = RegularOrder;
37
+ __decorate([
38
+ (0, typegoose_1.prop)({ type: String, enum: enum_1.RegularOrderStatus, default: enum_1.RegularOrderStatus.PLACED }),
39
+ __metadata("design:type", String)
40
+ ], RegularOrder.prototype, "status", void 0);
41
+ __decorate([
42
+ (0, typegoose_1.prop)({ type: () => [status_timeline_model_1.RegularOrderStatusTimeline], default: [] }),
43
+ __metadata("design:type", Array)
44
+ ], RegularOrder.prototype, "statusTimeline", void 0);
45
+ __decorate([
46
+ (0, typegoose_1.prop)({ type: String, enum: enum_1.ItemType, default: enum_1.ItemType.FOOD }),
47
+ __metadata("design:type", String)
48
+ ], RegularOrder.prototype, "itemType", void 0);
49
+ __decorate([
50
+ (0, typegoose_1.prop)({ required: true, type: address_model_1.Address }),
51
+ __metadata("design:type", address_model_1.Address)
52
+ ], RegularOrder.prototype, "pickupLocation", void 0);
53
+ __decorate([
54
+ (0, typegoose_1.prop)({ required: true, type: address_model_1.UserAddress }),
55
+ __metadata("design:type", address_model_1.UserAddress)
56
+ ], RegularOrder.prototype, "deliveryLocation", void 0);
57
+ __decorate([
58
+ (0, typegoose_1.prop)({ ref: () => parent_model_1.Parent }),
59
+ __metadata("design:type", Object)
60
+ ], RegularOrder.prototype, "parent", void 0);
61
+ __decorate([
62
+ (0, typegoose_1.prop)({ ref: () => shop_model_1.Shop }),
63
+ __metadata("design:type", Object)
64
+ ], RegularOrder.prototype, "shop", void 0);
65
+ __decorate([
66
+ (0, typegoose_1.prop)({ ref: () => cart_model_1.Cart }),
67
+ __metadata("design:type", Object)
68
+ ], RegularOrder.prototype, "cart", void 0);
69
+ __decorate([
70
+ (0, typegoose_1.prop)({ type: Boolean, default: false }),
71
+ __metadata("design:type", Boolean)
72
+ ], RegularOrder.prototype, "isShopDelivery", void 0);
73
+ __decorate([
74
+ (0, typegoose_1.prop)({ type: Number, default: 0 }),
75
+ __metadata("design:type", Number)
76
+ ], RegularOrder.prototype, "preparingTimeInMinutes", void 0);
77
+ __decorate([
78
+ (0, typegoose_1.prop)({ type: Boolean, default: false }),
79
+ __metadata("design:type", Boolean)
80
+ ], RegularOrder.prototype, "isReplacementOrder", void 0);
81
+ __decorate([
82
+ (0, typegoose_1.prop)({ ref: () => order_model_1.Order }),
83
+ __metadata("design:type", Object)
84
+ ], RegularOrder.prototype, "originalOrderForReplacement", void 0);
85
+ //# sourceMappingURL=regular-order.model.js.map
@@ -0,0 +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;AAE/E,MAAa,YAAa,SAAQ,mBAAK;IAC/B,SAAS,GAAG,gBAAS,CAAC,OAAgB,CAAC;IAGvC,MAAM,CAAU;IAGhB,cAAc,CAA+B;IAGpD,QAAQ,CAAU;IAGlB,cAAc,CAAU;IAGxB,gBAAgB,CAAc;IAG9B,MAAM,CAAe;IAGrB,IAAI,CAAa;IAGjB,IAAI,CAAa;IAGV,cAAc,CAAW;IAGzB,sBAAsB,CAAU;IAGhC,kBAAkB,CAAW;IAG7B,2BAA2B,CAAc;CAChD;AAtCD,oCAsCC;AAlCO;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,yBAAkB,EAAE,OAAO,EAAE,yBAAkB,CAAC,MAAM,EAAE,CAAC;;4CAC9D;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,kDAA0B,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;;oDACZ;AAGpD;IADC,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,eAAQ,EAAE,OAAO,EAAE,eAAQ,CAAC,IAAI,EAAE,CAAC;;8CAC7C;AAGlB;IADC,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,uBAAO,EAAE,CAAC;8BACxB,uBAAO;oDAAC;AAGxB;IADC,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,2BAAW,EAAE,CAAC;8BAC1B,2BAAW;sDAAC;AAG9B;IADC,IAAA,gBAAI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,qBAAM,EAAE,CAAC;;4CACP;AAGrB;IADC,IAAA,gBAAI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,iBAAI,EAAE,CAAC;;0CACT;AAGjB;IADC,IAAA,gBAAI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,iBAAI,EAAE,CAAC;;0CACT;AAGV;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","sourcesContent":["import { prop, Ref } from '@typegoose/typegoose';\r\nimport { Order } from '../order.model';\r\nimport { ItemType, OrderType, RegularOrderStatus } from '../../../../utilities/enum';\r\nimport { Parent } from '../parent.model';\r\nimport { Shop } from '../shop.model';\r\nimport { Cart } from '../cart.model';\r\nimport { Address, UserAddress } from '../shared/address.model';\r\nimport { RegularOrderStatusTimeline } from '../embedded/status-timeline.model';\r\n\r\nexport class RegularOrder extends Order {\r\n\tpublic orderType = OrderType.REGULAR as const;\r\n\r\n\t@prop({ type: String, enum: RegularOrderStatus, default: RegularOrderStatus.PLACED })\r\n\tpublic status?: string;\r\n\r\n\t@prop({ type: () => [RegularOrderStatusTimeline], default: [] })\r\n\tpublic statusTimeline: RegularOrderStatusTimeline[];\r\n\r\n\t@prop({ type: String, enum: ItemType, default: ItemType.FOOD })\r\n\titemType?: string;\r\n\r\n\t@prop({ required: true, type: Address })\r\n\tpickupLocation: Address;\r\n\r\n\t@prop({ required: true, type: UserAddress })\r\n\tdeliveryLocation: UserAddress;\r\n\r\n\t@prop({ ref: () => Parent })\r\n\tparent?: Ref<Parent>;\r\n\r\n\t@prop({ ref: () => Shop })\r\n\tshop?: Ref<Shop>;\r\n\r\n\t@prop({ ref: () => Cart })\r\n\tcart?: Ref<Cart>;\r\n\r\n\t@prop({ type: Boolean, default: false })\r\n\tpublic isShopDelivery?: boolean;\r\n\r\n\t@prop({ type: Number, default: 0 })\r\n\tpublic preparingTimeInMinutes?: number;\r\n\r\n\t@prop({ type: Boolean, default: false })\r\n\tpublic isReplacementOrder?: boolean;\r\n\r\n\t@prop({ ref: () => Order })\r\n\tpublic originalOrderForReplacement?: Ref<Order>;\r\n}\r\n"]}
@@ -1,6 +1,7 @@
1
1
  import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
2
2
  import { RatingAccountType } from '../../../utilities/enum';
3
3
  export declare class RatingSetting extends TimeStamps {
4
+ title?: string;
4
5
  rating: number;
5
6
  tags: string[];
6
7
  accountType: RatingAccountType;
@@ -14,13 +14,18 @@ const typegoose_1 = require("@typegoose/typegoose");
14
14
  const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
15
15
  const enum_1 = require("../../../utilities/enum");
16
16
  let RatingSetting = class RatingSetting extends defaultClasses_1.TimeStamps {
17
+ title;
17
18
  rating;
18
19
  tags;
19
20
  accountType;
20
21
  };
21
22
  exports.RatingSetting = RatingSetting;
22
23
  __decorate([
23
- (0, typegoose_1.prop)({ required: true, unique: true, type: Number, min: 1, max: 5 }),
24
+ (0, typegoose_1.prop)({ type: String }),
25
+ __metadata("design:type", String)
26
+ ], RatingSetting.prototype, "title", void 0);
27
+ __decorate([
28
+ (0, typegoose_1.prop)({ required: true, type: Number, min: 1, max: 5 }),
24
29
  __metadata("design:type", Number)
25
30
  ], RatingSetting.prototype, "rating", void 0);
26
31
  __decorate([
@@ -32,6 +37,10 @@ __decorate([
32
37
  __metadata("design:type", String)
33
38
  ], RatingSetting.prototype, "accountType", void 0);
34
39
  exports.RatingSetting = RatingSetting = __decorate([
35
- (0, typegoose_1.modelOptions)({ schemaOptions: { collection: 'ratingSettings' } })
40
+ (0, typegoose_1.modelOptions)({ schemaOptions: { collection: 'ratingSettings' } }),
41
+ (0, typegoose_1.Index)({ rating: 1, accountType: 1 }, {
42
+ unique: true,
43
+ partialFilterExpression: { deletedAt: null },
44
+ })
36
45
  ], RatingSetting);
37
46
  //# sourceMappingURL=rating-setting.model.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"rating-setting.model.js","sourceRoot":"/","sources":["libraries/mongo/models/rating-setting.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA0D;AAC1D,4EAAqE;AACrE,kDAA4D;AAGrD,IAAM,aAAa,GAAnB,MAAM,aAAc,SAAQ,2BAAU;IAErC,MAAM,CAAU;IAGhB,IAAI,CAAY;IAGhB,WAAW,CAAqB;CACvC,CAAA;AATY,sCAAa;AAElB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;6CAC9C;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC;;2CACxB;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,wBAAiB,EAAE,CAAC;;kDACzB;wBAR3B,aAAa;IADzB,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,gBAAgB,EAAE,EAAE,CAAC;GACrD,aAAa,CASzB","sourcesContent":["import { modelOptions, prop } from '@typegoose/typegoose';\r\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\r\nimport { RatingAccountType } from '../../../utilities/enum';\r\n\r\n@modelOptions({ schemaOptions: { collection: 'ratingSettings' } })\r\nexport class RatingSetting extends TimeStamps {\r\n\t@prop({ required: true, unique: true, type: Number, min: 1, max: 5 })\r\n\tpublic rating!: number;\r\n\r\n\t@prop({ required: true, type: () => [String] })\r\n\tpublic tags!: string[];\r\n\r\n\t@prop({ required: true, type: String, enum: RatingAccountType })\r\n\tpublic accountType!: RatingAccountType;\r\n}\r\n"]}
1
+ {"version":3,"file":"rating-setting.model.js","sourceRoot":"/","sources":["libraries/mongo/models/rating-setting.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAiE;AACjE,4EAAqE;AACrE,kDAA4D;AAUrD,IAAM,aAAa,GAAnB,MAAM,aAAc,SAAQ,2BAAU;IAErC,KAAK,CAAU;IAGf,MAAM,CAAU;IAGhB,IAAI,CAAY;IAGhB,WAAW,CAAqB;CACvC,CAAA;AAZY,sCAAa;AAElB;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;4CACD;AAGf;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;;6CAChC;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC;;2CACxB;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,wBAAiB,EAAE,CAAC;;kDACzB;wBAX3B,aAAa;IARzB,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,gBAAgB,EAAE,EAAE,CAAC;IACjE,IAAA,iBAAK,EACL,EAAE,MAAM,EAAE,CAAC,EAAE,WAAW,EAAE,CAAC,EAAE,EAC7B;QACC,MAAM,EAAE,IAAI;QACZ,uBAAuB,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE;KAC5C,CACD;GACY,aAAa,CAYzB","sourcesContent":["import { Index, modelOptions, prop } from '@typegoose/typegoose';\r\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\r\nimport { RatingAccountType } from '../../../utilities/enum';\r\n\r\n@modelOptions({ schemaOptions: { collection: 'ratingSettings' } })\r\n@Index(\r\n\t{ rating: 1, accountType: 1 },\r\n\t{\r\n\t\tunique: true,\r\n\t\tpartialFilterExpression: { deletedAt: null },\r\n\t}\r\n)\r\nexport class RatingSetting extends TimeStamps {\r\n\t@prop({ type: String })\r\n\tpublic title?: string;\r\n\r\n\t@prop({ required: true, type: Number, min: 1, max: 5 })\r\n\tpublic rating!: number;\r\n\r\n\t@prop({ required: true, type: () => [String] })\r\n\tpublic tags!: string[];\r\n\r\n\t@prop({ required: true, type: String, enum: RatingAccountType })\r\n\tpublic accountType!: RatingAccountType;\r\n}\r\n"]}
@@ -1,8 +1,8 @@
1
1
  import { Ref } from '@typegoose/typegoose';
2
2
  import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
3
- import { CoreUser } from './core-user.model';
3
+ import { User } from './user.model';
4
4
  import { Address } from './shared/address.model';
5
5
  export declare class RequestArea extends TimeStamps {
6
- user?: Ref<CoreUser>;
6
+ user?: Ref<User>;
7
7
  location: Address;
8
8
  }
@@ -12,7 +12,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.RequestArea = void 0;
13
13
  const typegoose_1 = require("@typegoose/typegoose");
14
14
  const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
15
- const core_user_model_1 = require("./core-user.model");
15
+ const user_model_1 = require("./user.model");
16
16
  const address_model_1 = require("./shared/address.model");
17
17
  let RequestArea = class RequestArea extends defaultClasses_1.TimeStamps {
18
18
  user;
@@ -20,7 +20,7 @@ let RequestArea = class RequestArea extends defaultClasses_1.TimeStamps {
20
20
  };
21
21
  exports.RequestArea = RequestArea;
22
22
  __decorate([
23
- (0, typegoose_1.prop)({ ref: () => core_user_model_1.CoreUser }),
23
+ (0, typegoose_1.prop)({ ref: () => user_model_1.User }),
24
24
  __metadata("design:type", Object)
25
25
  ], RequestArea.prototype, "user", void 0);
26
26
  __decorate([
@@ -1 +1 @@
1
- {"version":3,"file":"request-area.model.js","sourceRoot":"/","sources":["libraries/mongo/models/request-area.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA+D;AAC/D,4EAAqE;AACrE,uDAA6C;AAC7C,0DAAiD;AAG1C,IAAM,WAAW,GAAjB,MAAM,WAAY,SAAQ,2BAAU;IAEnC,IAAI,CAAiB;IAGrB,QAAQ,CAAW;CAC1B,CAAA;AANY,kCAAW;AAEhB;IADN,IAAA,gBAAI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,0BAAQ,EAAE,CAAC;;yCACF;AAGrB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,uBAAO,EAAE,CAAC;8BACtB,uBAAO;6CAAC;sBALd,WAAW;IADvB,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,cAAc,EAAE,EAAE,CAAC;GACnD,WAAW,CAMvB","sourcesContent":["import { modelOptions, prop, Ref } from '@typegoose/typegoose';\r\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\r\nimport { CoreUser } from './core-user.model';\r\nimport { Address } from './shared/address.model';\r\n\r\n@modelOptions({ schemaOptions: { collection: 'requestAreas' } })\r\nexport class RequestArea extends TimeStamps {\r\n\t@prop({ ref: () => CoreUser })\r\n\tpublic user?: Ref<CoreUser>;\r\n\r\n\t@prop({ required: true, type: Address })\r\n\tpublic location!: Address;\r\n}\r\n"]}
1
+ {"version":3,"file":"request-area.model.js","sourceRoot":"/","sources":["libraries/mongo/models/request-area.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA+D;AAC/D,4EAAqE;AACrE,6CAAoC;AACpC,0DAAiD;AAG1C,IAAM,WAAW,GAAjB,MAAM,WAAY,SAAQ,2BAAU;IAEnC,IAAI,CAAa;IAGjB,QAAQ,CAAW;CAC1B,CAAA;AANY,kCAAW;AAEhB;IADN,IAAA,gBAAI,EAAC,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,iBAAI,EAAE,CAAC;;yCACF;AAGjB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,uBAAO,EAAE,CAAC;8BACtB,uBAAO;6CAAC;sBALd,WAAW;IADvB,IAAA,wBAAY,EAAC,EAAE,aAAa,EAAE,EAAE,UAAU,EAAE,cAAc,EAAE,EAAE,CAAC;GACnD,WAAW,CAMvB","sourcesContent":["import { modelOptions, prop, Ref } from '@typegoose/typegoose';\r\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\r\nimport { User } from './user.model';\r\nimport { Address } from './shared/address.model';\r\n\r\n@modelOptions({ schemaOptions: { collection: 'requestAreas' } })\r\nexport class RequestArea extends TimeStamps {\r\n\t@prop({ ref: () => User })\r\n\tpublic user?: Ref<User>;\r\n\r\n\t@prop({ required: true, type: Address })\r\n\tpublic location!: Address;\r\n}\r\n"]}
@@ -0,0 +1,10 @@
1
+ import { Ref } from '@typegoose/typegoose';
2
+ import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
3
+ import { Rider } from './rider.model';
4
+ export declare class RiderTimeout extends TimeStamps {
5
+ rider: Ref<Rider>;
6
+ Date?: Date;
7
+ timeIn?: Date;
8
+ timeOut?: Date;
9
+ activeTotal?: number;
10
+ }