@medusajs/link-modules 0.2.12 → 1.0.0-rc-20241001083650

Sign up to get free protection for your applications and to get access to all the features.
Files changed (212) hide show
  1. package/dist/definitions/cart-payment-collection.d.ts +2 -1
  2. package/dist/definitions/cart-payment-collection.d.ts.map +1 -0
  3. package/dist/definitions/cart-payment-collection.js +15 -9
  4. package/dist/definitions/cart-payment-collection.js.map +1 -0
  5. package/dist/definitions/cart-promotion.d.ts +2 -1
  6. package/dist/definitions/cart-promotion.d.ts.map +1 -0
  7. package/dist/definitions/cart-promotion.js +22 -18
  8. package/dist/definitions/cart-promotion.js.map +1 -0
  9. package/dist/definitions/fulfillment-provider-location.d.ts +3 -0
  10. package/dist/definitions/fulfillment-provider-location.d.ts.map +1 -0
  11. package/dist/definitions/fulfillment-provider-location.js +72 -0
  12. package/dist/definitions/fulfillment-provider-location.js.map +1 -0
  13. package/dist/definitions/fulfillment-set-location.d.ts +3 -2
  14. package/dist/definitions/fulfillment-set-location.d.ts.map +1 -0
  15. package/dist/definitions/fulfillment-set-location.js +42 -33
  16. package/dist/definitions/fulfillment-set-location.js.map +1 -0
  17. package/dist/definitions/index.d.ts +7 -9
  18. package/dist/definitions/index.d.ts.map +1 -0
  19. package/dist/definitions/index.js +7 -9
  20. package/dist/definitions/index.js.map +1 -0
  21. package/dist/definitions/order-cart.d.ts +3 -0
  22. package/dist/definitions/order-cart.d.ts.map +1 -0
  23. package/dist/definitions/order-cart.js +68 -0
  24. package/dist/definitions/order-cart.js.map +1 -0
  25. package/dist/definitions/order-claim-payment-collection.d.ts +3 -0
  26. package/dist/definitions/order-claim-payment-collection.d.ts.map +1 -0
  27. package/dist/definitions/order-claim-payment-collection.js +74 -0
  28. package/dist/definitions/order-claim-payment-collection.js.map +1 -0
  29. package/dist/definitions/order-exchange-payment-collection.d.ts +3 -0
  30. package/dist/definitions/order-exchange-payment-collection.d.ts.map +1 -0
  31. package/dist/definitions/order-exchange-payment-collection.js +74 -0
  32. package/dist/definitions/order-exchange-payment-collection.js.map +1 -0
  33. package/dist/definitions/order-fulfillment.d.ts +3 -0
  34. package/dist/definitions/order-fulfillment.d.ts.map +1 -0
  35. package/dist/definitions/order-fulfillment.js +72 -0
  36. package/dist/definitions/order-fulfillment.js.map +1 -0
  37. package/dist/definitions/order-payment-collection.d.ts +3 -0
  38. package/dist/definitions/order-payment-collection.d.ts.map +1 -0
  39. package/dist/definitions/order-payment-collection.js +72 -0
  40. package/dist/definitions/order-payment-collection.js.map +1 -0
  41. package/dist/definitions/order-promotion.d.ts +2 -1
  42. package/dist/definitions/order-promotion.d.ts.map +1 -0
  43. package/dist/definitions/order-promotion.js +20 -11
  44. package/dist/definitions/order-promotion.js.map +1 -0
  45. package/dist/definitions/order-return-fulfillment.d.ts +3 -0
  46. package/dist/definitions/order-return-fulfillment.d.ts.map +1 -0
  47. package/dist/definitions/order-return-fulfillment.js +69 -0
  48. package/dist/definitions/order-return-fulfillment.js.map +1 -0
  49. package/dist/definitions/product-sales-channel.d.ts +2 -1
  50. package/dist/definitions/product-sales-channel.d.ts.map +1 -0
  51. package/dist/definitions/product-sales-channel.js +18 -9
  52. package/dist/definitions/product-sales-channel.js.map +1 -0
  53. package/dist/definitions/product-variant-inventory-item.d.ts +2 -1
  54. package/dist/definitions/product-variant-inventory-item.d.ts.map +1 -0
  55. package/dist/definitions/product-variant-inventory-item.js +21 -11
  56. package/dist/definitions/product-variant-inventory-item.js.map +1 -0
  57. package/dist/definitions/product-variant-price-set.d.ts +2 -1
  58. package/dist/definitions/product-variant-price-set.d.ts.map +1 -0
  59. package/dist/definitions/product-variant-price-set.js +18 -12
  60. package/dist/definitions/product-variant-price-set.js.map +1 -0
  61. package/dist/definitions/publishable-api-key-sales-channel.d.ts +2 -1
  62. package/dist/definitions/publishable-api-key-sales-channel.d.ts.map +1 -0
  63. package/dist/definitions/publishable-api-key-sales-channel.js +22 -8
  64. package/dist/definitions/publishable-api-key-sales-channel.js.map +1 -0
  65. package/dist/definitions/readonly/cart-customer.d.ts +3 -0
  66. package/dist/definitions/readonly/cart-customer.d.ts.map +1 -0
  67. package/dist/definitions/{cart-customer.js → readonly/cart-customer.js} +14 -5
  68. package/dist/definitions/readonly/cart-customer.js.map +1 -0
  69. package/dist/definitions/readonly/cart-product.d.ts +3 -0
  70. package/dist/definitions/readonly/cart-product.d.ts.map +1 -0
  71. package/dist/definitions/readonly/cart-product.js +50 -0
  72. package/dist/definitions/readonly/cart-product.js.map +1 -0
  73. package/dist/definitions/readonly/cart-region.d.ts +3 -0
  74. package/dist/definitions/readonly/cart-region.d.ts.map +1 -0
  75. package/dist/definitions/{cart-region.js → readonly/cart-region.js} +14 -5
  76. package/dist/definitions/readonly/cart-region.js.map +1 -0
  77. package/dist/definitions/readonly/cart-sales-channel.d.ts +3 -0
  78. package/dist/definitions/readonly/cart-sales-channel.d.ts.map +1 -0
  79. package/dist/definitions/{cart-sales-channel.js → readonly/cart-sales-channel.js} +14 -5
  80. package/dist/definitions/readonly/cart-sales-channel.js.map +1 -0
  81. package/dist/definitions/readonly/index.d.ts +12 -0
  82. package/dist/definitions/readonly/index.d.ts.map +1 -0
  83. package/dist/definitions/readonly/index.js +28 -0
  84. package/dist/definitions/readonly/index.js.map +1 -0
  85. package/dist/definitions/readonly/inventory-level-stock-location.d.ts +3 -0
  86. package/dist/definitions/readonly/inventory-level-stock-location.d.ts.map +1 -0
  87. package/dist/definitions/{inventory-level-stock-location.js → readonly/inventory-level-stock-location.js} +8 -3
  88. package/dist/definitions/readonly/inventory-level-stock-location.js.map +1 -0
  89. package/dist/definitions/readonly/line-item-adjustment-promotion.d.ts +3 -0
  90. package/dist/definitions/readonly/line-item-adjustment-promotion.d.ts.map +1 -0
  91. package/dist/definitions/readonly/line-item-adjustment-promotion.js +24 -0
  92. package/dist/definitions/readonly/line-item-adjustment-promotion.js.map +1 -0
  93. package/dist/definitions/readonly/order-customer.d.ts +3 -0
  94. package/dist/definitions/readonly/order-customer.d.ts.map +1 -0
  95. package/dist/definitions/{order-customer.js → readonly/order-customer.js} +14 -5
  96. package/dist/definitions/readonly/order-customer.js.map +1 -0
  97. package/dist/definitions/readonly/order-product.d.ts +3 -0
  98. package/dist/definitions/readonly/order-product.d.ts.map +1 -0
  99. package/dist/definitions/readonly/order-product.js +51 -0
  100. package/dist/definitions/readonly/order-product.js.map +1 -0
  101. package/dist/definitions/readonly/order-region.d.ts +3 -0
  102. package/dist/definitions/readonly/order-region.d.ts.map +1 -0
  103. package/dist/definitions/{order-region.js → readonly/order-region.js} +14 -5
  104. package/dist/definitions/readonly/order-region.js.map +1 -0
  105. package/dist/definitions/readonly/order-sales-channel.d.ts +3 -0
  106. package/dist/definitions/readonly/order-sales-channel.d.ts.map +1 -0
  107. package/dist/definitions/readonly/order-sales-channel.js +38 -0
  108. package/dist/definitions/readonly/order-sales-channel.js.map +1 -0
  109. package/dist/definitions/readonly/store-currency.d.ts +3 -0
  110. package/dist/definitions/readonly/store-currency.d.ts.map +1 -0
  111. package/dist/definitions/readonly/store-currency.js +24 -0
  112. package/dist/definitions/readonly/store-currency.js.map +1 -0
  113. package/dist/definitions/region-payment-provider.d.ts +2 -1
  114. package/dist/definitions/region-payment-provider.d.ts.map +1 -0
  115. package/dist/definitions/region-payment-provider.js +20 -11
  116. package/dist/definitions/region-payment-provider.js.map +1 -0
  117. package/dist/definitions/sales-channel-location.d.ts +2 -1
  118. package/dist/definitions/sales-channel-location.d.ts.map +1 -0
  119. package/dist/definitions/sales-channel-location.js +23 -11
  120. package/dist/definitions/sales-channel-location.js.map +1 -0
  121. package/dist/definitions/shipping-option-price-set.d.ts +2 -1
  122. package/dist/definitions/shipping-option-price-set.d.ts.map +1 -0
  123. package/dist/definitions/shipping-option-price-set.js +12 -9
  124. package/dist/definitions/shipping-option-price-set.js.map +1 -0
  125. package/dist/index.d.ts +3 -2
  126. package/dist/index.d.ts.map +1 -0
  127. package/dist/index.js +3 -2
  128. package/dist/index.js.map +1 -0
  129. package/dist/initialize/index.d.ts +13 -4
  130. package/dist/initialize/index.d.ts.map +1 -0
  131. package/dist/initialize/index.js +42 -28
  132. package/dist/initialize/index.js.map +1 -0
  133. package/dist/initialize/module-definition.d.ts +2 -1
  134. package/dist/initialize/module-definition.d.ts.map +1 -0
  135. package/dist/initialize/module-definition.js +2 -2
  136. package/dist/initialize/module-definition.js.map +1 -0
  137. package/dist/loaders/connection.d.ts +2 -1
  138. package/dist/loaders/connection.d.ts.map +1 -0
  139. package/dist/loaders/connection.js +3 -3
  140. package/dist/loaders/connection.js.map +1 -0
  141. package/dist/loaders/container.d.ts +2 -2
  142. package/dist/loaders/container.d.ts.map +1 -0
  143. package/dist/loaders/container.js +6 -7
  144. package/dist/loaders/container.js.map +1 -0
  145. package/dist/loaders/index.d.ts +2 -1
  146. package/dist/loaders/index.d.ts.map +1 -0
  147. package/dist/loaders/index.js +2 -2
  148. package/dist/loaders/index.js.map +1 -0
  149. package/dist/migration/index.d.ts +103 -2
  150. package/dist/migration/index.d.ts.map +1 -0
  151. package/dist/migration/index.js +341 -46
  152. package/dist/migration/index.js.map +1 -0
  153. package/dist/repositories/index.d.ts +2 -1
  154. package/dist/repositories/index.d.ts.map +1 -0
  155. package/dist/repositories/index.js +2 -1
  156. package/dist/repositories/index.js.map +1 -0
  157. package/dist/repositories/link.d.ts +20 -20
  158. package/dist/repositories/link.d.ts.map +1 -0
  159. package/dist/repositories/link.js +3 -3
  160. package/dist/repositories/link.js.map +1 -0
  161. package/dist/services/dynamic-service-class.d.ts +2 -1
  162. package/dist/services/dynamic-service-class.d.ts.map +1 -0
  163. package/dist/services/dynamic-service-class.js +10 -3
  164. package/dist/services/dynamic-service-class.js.map +1 -0
  165. package/dist/services/index.d.ts +1 -0
  166. package/dist/services/index.d.ts.map +1 -0
  167. package/dist/services/index.js +1 -0
  168. package/dist/services/index.js.map +1 -0
  169. package/dist/services/link-module-service.d.ts +5 -3
  170. package/dist/services/link-module-service.d.ts.map +1 -0
  171. package/dist/services/link-module-service.js +34 -41
  172. package/dist/services/link-module-service.js.map +1 -0
  173. package/dist/services/link.d.ts +2 -1
  174. package/dist/services/link.d.ts.map +1 -0
  175. package/dist/services/link.js +2 -1
  176. package/dist/services/link.js.map +1 -0
  177. package/dist/tsconfig.tsbuildinfo +1 -0
  178. package/dist/types/index.d.ts +2 -1
  179. package/dist/types/index.d.ts.map +1 -0
  180. package/dist/types/index.js +1 -0
  181. package/dist/types/index.js.map +1 -0
  182. package/dist/utils/compress-name.d.ts +2 -0
  183. package/dist/utils/compress-name.d.ts.map +1 -0
  184. package/dist/utils/compress-name.js +33 -0
  185. package/dist/utils/compress-name.js.map +1 -0
  186. package/dist/utils/generate-entity.d.ts +2 -1
  187. package/dist/utils/generate-entity.d.ts.map +1 -0
  188. package/dist/utils/generate-entity.js +6 -6
  189. package/dist/utils/generate-entity.js.map +1 -0
  190. package/dist/utils/generate-schema.d.ts +2 -1
  191. package/dist/utils/generate-schema.d.ts.map +1 -0
  192. package/dist/utils/generate-schema.js +76 -20
  193. package/dist/utils/generate-schema.js.map +1 -0
  194. package/dist/utils/index.d.ts +1 -1
  195. package/dist/utils/index.d.ts.map +1 -0
  196. package/dist/utils/index.js +5 -6
  197. package/dist/utils/index.js.map +1 -0
  198. package/package.json +22 -15
  199. package/dist/definitions/cart-customer.d.ts +0 -2
  200. package/dist/definitions/cart-region.d.ts +0 -2
  201. package/dist/definitions/cart-sales-channel.d.ts +0 -2
  202. package/dist/definitions/inventory-level-stock-location.d.ts +0 -2
  203. package/dist/definitions/order-customer.d.ts +0 -2
  204. package/dist/definitions/order-region.d.ts +0 -2
  205. package/dist/definitions/order-sales-channel.d.ts +0 -2
  206. package/dist/definitions/order-sales-channel.js +0 -67
  207. package/dist/definitions/product-shipping-profile.d.ts +0 -2
  208. package/dist/definitions/product-shipping-profile.js +0 -61
  209. package/dist/definitions/store-default-currency.d.ts +0 -2
  210. package/dist/definitions/store-default-currency.js +0 -19
  211. package/dist/utils/compose-link-name.d.ts +0 -2
  212. package/dist/utils/compose-link-name.js +0 -12
@@ -0,0 +1,74 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.OrderExchangePaymentCollection = void 0;
4
+ const utils_1 = require("@medusajs/framework/utils");
5
+ exports.OrderExchangePaymentCollection = {
6
+ serviceName: utils_1.LINKS.OrderExchangePaymentCollection,
7
+ isLink: true,
8
+ databaseConfig: {
9
+ tableName: "order_exchange_payment_collection",
10
+ idPrefix: "excpay",
11
+ },
12
+ alias: [
13
+ {
14
+ name: [
15
+ "order_exchange_payment_collection",
16
+ "order_exchange_payment_collections",
17
+ ],
18
+ entity: "LinkOrderExchangePaymentCollection",
19
+ },
20
+ ],
21
+ primaryKeys: ["id", "exchange_id", "payment_collection_id"],
22
+ relationships: [
23
+ {
24
+ serviceName: utils_1.Modules.ORDER,
25
+ entity: "OrderExchange",
26
+ primaryKey: "id",
27
+ foreignKey: "exchange_id",
28
+ alias: "order",
29
+ args: {
30
+ methodSuffix: "OrderExchanges",
31
+ },
32
+ },
33
+ {
34
+ serviceName: utils_1.Modules.PAYMENT,
35
+ entity: "PaymentCollection",
36
+ primaryKey: "id",
37
+ foreignKey: "payment_collection_id",
38
+ alias: "payment_collection",
39
+ args: {
40
+ methodSuffix: "PaymentCollections",
41
+ },
42
+ },
43
+ ],
44
+ extends: [
45
+ {
46
+ serviceName: utils_1.Modules.ORDER,
47
+ fieldAlias: {
48
+ exchange_payment_collections: {
49
+ path: "exchange_payment_collections_link.payment_collection",
50
+ isList: true,
51
+ },
52
+ },
53
+ relationship: {
54
+ serviceName: utils_1.LINKS.OrderExchangePaymentCollection,
55
+ primaryKey: "exchange_id",
56
+ foreignKey: "id",
57
+ alias: "exchange_payment_collections_link",
58
+ },
59
+ },
60
+ {
61
+ serviceName: utils_1.Modules.PAYMENT,
62
+ fieldAlias: {
63
+ exchange: "order_exchange_link.order",
64
+ },
65
+ relationship: {
66
+ serviceName: utils_1.LINKS.OrderExchangePaymentCollection,
67
+ primaryKey: "payment_collection_id",
68
+ foreignKey: "id",
69
+ alias: "order_exchange_link",
70
+ },
71
+ },
72
+ ],
73
+ };
74
+ //# sourceMappingURL=order-exchange-payment-collection.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-exchange-payment-collection.js","sourceRoot":"","sources":["../../src/definitions/order-exchange-payment-collection.ts"],"names":[],"mappings":";;;AACA,qDAA0D;AAE7C,QAAA,8BAA8B,GAAuB;IAChE,WAAW,EAAE,aAAK,CAAC,8BAA8B;IACjD,MAAM,EAAE,IAAI;IACZ,cAAc,EAAE;QACd,SAAS,EAAE,mCAAmC;QAC9C,QAAQ,EAAE,QAAQ;KACnB;IACD,KAAK,EAAE;QACL;YACE,IAAI,EAAE;gBACJ,mCAAmC;gBACnC,oCAAoC;aACrC;YACD,MAAM,EAAE,oCAAoC;SAC7C;KACF;IACD,WAAW,EAAE,CAAC,IAAI,EAAE,aAAa,EAAE,uBAAuB,CAAC;IAC3D,aAAa,EAAE;QACb;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,MAAM,EAAE,eAAe;YACvB,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,aAAa;YACzB,KAAK,EAAE,OAAO;YACd,IAAI,EAAE;gBACJ,YAAY,EAAE,gBAAgB;aAC/B;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,OAAO;YAC5B,MAAM,EAAE,mBAAmB;YAC3B,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,uBAAuB;YACnC,KAAK,EAAE,oBAAoB;YAC3B,IAAI,EAAE;gBACJ,YAAY,EAAE,oBAAoB;aACnC;SACF;KACF;IACD,OAAO,EAAE;QACP;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,UAAU,EAAE;gBACV,4BAA4B,EAAE;oBAC5B,IAAI,EAAE,sDAAsD;oBAC5D,MAAM,EAAE,IAAI;iBACb;aACF;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,8BAA8B;gBACjD,UAAU,EAAE,aAAa;gBACzB,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,mCAAmC;aAC3C;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,OAAO;YAC5B,UAAU,EAAE;gBACV,QAAQ,EAAE,2BAA2B;aACtC;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,8BAA8B;gBACjD,UAAU,EAAE,uBAAuB;gBACnC,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,qBAAqB;aAC7B;SACF;KACF;CACF,CAAA"}
@@ -0,0 +1,3 @@
1
+ import { ModuleJoinerConfig } from "@medusajs/framework/types";
2
+ export declare const OrderFulfillment: ModuleJoinerConfig;
3
+ //# sourceMappingURL=order-fulfillment.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-fulfillment.d.ts","sourceRoot":"","sources":["../../src/definitions/order-fulfillment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA;AAG9D,eAAO,MAAM,gBAAgB,EAAE,kBAkE9B,CAAA"}
@@ -0,0 +1,72 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.OrderFulfillment = void 0;
4
+ const utils_1 = require("@medusajs/framework/utils");
5
+ exports.OrderFulfillment = {
6
+ serviceName: utils_1.LINKS.OrderFulfillment,
7
+ isLink: true,
8
+ databaseConfig: {
9
+ tableName: "order_fulfillment",
10
+ idPrefix: "ordful",
11
+ },
12
+ alias: [
13
+ {
14
+ name: ["order_fulfillment", "order_fulfillments"],
15
+ entity: "LinkOrderFulfillment",
16
+ },
17
+ ],
18
+ primaryKeys: ["id", "order_id", "fulfillment_id"],
19
+ relationships: [
20
+ {
21
+ serviceName: utils_1.Modules.ORDER,
22
+ entity: "Order",
23
+ primaryKey: "id",
24
+ foreignKey: "order_id",
25
+ alias: "order",
26
+ args: {
27
+ methodSuffix: "Orders",
28
+ },
29
+ },
30
+ {
31
+ serviceName: utils_1.Modules.FULFILLMENT,
32
+ entity: "Fulfillment",
33
+ primaryKey: "id",
34
+ foreignKey: "fulfillment_id",
35
+ alias: "fulfillments",
36
+ args: {
37
+ methodSuffix: "Fulfillments",
38
+ },
39
+ },
40
+ ],
41
+ extends: [
42
+ {
43
+ serviceName: utils_1.Modules.ORDER,
44
+ fieldAlias: {
45
+ fulfillments: {
46
+ path: "fulfillment_link.fulfillments",
47
+ isList: true,
48
+ },
49
+ },
50
+ relationship: {
51
+ serviceName: utils_1.LINKS.OrderFulfillment,
52
+ primaryKey: "order_id",
53
+ foreignKey: "id",
54
+ alias: "fulfillment_link",
55
+ isList: true,
56
+ },
57
+ },
58
+ {
59
+ serviceName: utils_1.Modules.FULFILLMENT,
60
+ fieldAlias: {
61
+ order: "order_link.order",
62
+ },
63
+ relationship: {
64
+ serviceName: utils_1.LINKS.OrderFulfillment,
65
+ primaryKey: "fulfillment_id",
66
+ foreignKey: "id",
67
+ alias: "order_link",
68
+ },
69
+ },
70
+ ],
71
+ };
72
+ //# sourceMappingURL=order-fulfillment.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-fulfillment.js","sourceRoot":"","sources":["../../src/definitions/order-fulfillment.ts"],"names":[],"mappings":";;;AACA,qDAA0D;AAE7C,QAAA,gBAAgB,GAAuB;IAClD,WAAW,EAAE,aAAK,CAAC,gBAAgB;IACnC,MAAM,EAAE,IAAI;IACZ,cAAc,EAAE;QACd,SAAS,EAAE,mBAAmB;QAC9B,QAAQ,EAAE,QAAQ;KACnB;IACD,KAAK,EAAE;QACL;YACE,IAAI,EAAE,CAAC,mBAAmB,EAAE,oBAAoB,CAAC;YACjD,MAAM,EAAE,sBAAsB;SAC/B;KACF;IACD,WAAW,EAAE,CAAC,IAAI,EAAE,UAAU,EAAE,gBAAgB,CAAC;IACjD,aAAa,EAAE;QACb;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,MAAM,EAAE,OAAO;YACf,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,UAAU;YACtB,KAAK,EAAE,OAAO;YACd,IAAI,EAAE;gBACJ,YAAY,EAAE,QAAQ;aACvB;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,WAAW;YAChC,MAAM,EAAE,aAAa;YACrB,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,gBAAgB;YAC5B,KAAK,EAAE,cAAc;YACrB,IAAI,EAAE;gBACJ,YAAY,EAAE,cAAc;aAC7B;SACF;KACF;IACD,OAAO,EAAE;QACP;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,UAAU,EAAE;gBACV,YAAY,EAAE;oBACZ,IAAI,EAAE,+BAA+B;oBACrC,MAAM,EAAE,IAAI;iBACb;aACF;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,gBAAgB;gBACnC,UAAU,EAAE,UAAU;gBACtB,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,kBAAkB;gBACzB,MAAM,EAAE,IAAI;aACb;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,WAAW;YAChC,UAAU,EAAE;gBACV,KAAK,EAAE,kBAAkB;aAC1B;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,gBAAgB;gBACnC,UAAU,EAAE,gBAAgB;gBAC5B,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,YAAY;aACpB;SACF;KACF;CACF,CAAA"}
@@ -0,0 +1,3 @@
1
+ import { ModuleJoinerConfig } from "@medusajs/framework/types";
2
+ export declare const OrderPaymentCollection: ModuleJoinerConfig;
3
+ //# sourceMappingURL=order-payment-collection.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-payment-collection.d.ts","sourceRoot":"","sources":["../../src/definitions/order-payment-collection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA;AAG9D,eAAO,MAAM,sBAAsB,EAAE,kBAkEpC,CAAA"}
@@ -0,0 +1,72 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.OrderPaymentCollection = void 0;
4
+ const utils_1 = require("@medusajs/framework/utils");
5
+ exports.OrderPaymentCollection = {
6
+ serviceName: utils_1.LINKS.OrderPaymentCollection,
7
+ isLink: true,
8
+ databaseConfig: {
9
+ tableName: "order_payment_collection",
10
+ idPrefix: "ordpay",
11
+ },
12
+ alias: [
13
+ {
14
+ name: ["order_payment_collection", "order_payment_collections"],
15
+ entity: "LinkOrderPaymentCollection",
16
+ },
17
+ ],
18
+ primaryKeys: ["id", "order_id", "payment_collection_id"],
19
+ relationships: [
20
+ {
21
+ serviceName: utils_1.Modules.ORDER,
22
+ entity: "Order",
23
+ primaryKey: "id",
24
+ foreignKey: "order_id",
25
+ alias: "order",
26
+ args: {
27
+ methodSuffix: "Orders",
28
+ },
29
+ },
30
+ {
31
+ serviceName: utils_1.Modules.PAYMENT,
32
+ entity: "PaymentCollection",
33
+ primaryKey: "id",
34
+ foreignKey: "payment_collection_id",
35
+ alias: "payment_collection",
36
+ args: {
37
+ methodSuffix: "PaymentCollections",
38
+ },
39
+ deleteCascade: true,
40
+ },
41
+ ],
42
+ extends: [
43
+ {
44
+ serviceName: utils_1.Modules.ORDER,
45
+ fieldAlias: {
46
+ payment_collections: {
47
+ path: "payment_collections_link.payment_collection",
48
+ isList: true,
49
+ },
50
+ },
51
+ relationship: {
52
+ serviceName: utils_1.LINKS.OrderPaymentCollection,
53
+ primaryKey: "order_id",
54
+ foreignKey: "id",
55
+ alias: "payment_collections_link",
56
+ },
57
+ },
58
+ {
59
+ serviceName: utils_1.Modules.PAYMENT,
60
+ fieldAlias: {
61
+ order: "order_link.order",
62
+ },
63
+ relationship: {
64
+ serviceName: utils_1.LINKS.OrderPaymentCollection,
65
+ primaryKey: "payment_collection_id",
66
+ foreignKey: "id",
67
+ alias: "order_link",
68
+ },
69
+ },
70
+ ],
71
+ };
72
+ //# sourceMappingURL=order-payment-collection.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-payment-collection.js","sourceRoot":"","sources":["../../src/definitions/order-payment-collection.ts"],"names":[],"mappings":";;;AACA,qDAA0D;AAE7C,QAAA,sBAAsB,GAAuB;IACxD,WAAW,EAAE,aAAK,CAAC,sBAAsB;IACzC,MAAM,EAAE,IAAI;IACZ,cAAc,EAAE;QACd,SAAS,EAAE,0BAA0B;QACrC,QAAQ,EAAE,QAAQ;KACnB;IACD,KAAK,EAAE;QACL;YACE,IAAI,EAAE,CAAC,0BAA0B,EAAE,2BAA2B,CAAC;YAC/D,MAAM,EAAE,4BAA4B;SACrC;KACF;IACD,WAAW,EAAE,CAAC,IAAI,EAAE,UAAU,EAAE,uBAAuB,CAAC;IACxD,aAAa,EAAE;QACb;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,MAAM,EAAE,OAAO;YACf,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,UAAU;YACtB,KAAK,EAAE,OAAO;YACd,IAAI,EAAE;gBACJ,YAAY,EAAE,QAAQ;aACvB;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,OAAO;YAC5B,MAAM,EAAE,mBAAmB;YAC3B,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,uBAAuB;YACnC,KAAK,EAAE,oBAAoB;YAC3B,IAAI,EAAE;gBACJ,YAAY,EAAE,oBAAoB;aACnC;YACD,aAAa,EAAE,IAAI;SACpB;KACF;IACD,OAAO,EAAE;QACP;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,UAAU,EAAE;gBACV,mBAAmB,EAAE;oBACnB,IAAI,EAAE,6CAA6C;oBACnD,MAAM,EAAE,IAAI;iBACb;aACF;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,sBAAsB;gBACzC,UAAU,EAAE,UAAU;gBACtB,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,0BAA0B;aAClC;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,OAAO;YAC5B,UAAU,EAAE;gBACV,KAAK,EAAE,kBAAkB;aAC1B;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,sBAAsB;gBACzC,UAAU,EAAE,uBAAuB;gBACnC,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,YAAY;aACpB;SACF;KACF;CACF,CAAA"}
@@ -1,2 +1,3 @@
1
- import { ModuleJoinerConfig } from "@medusajs/types";
1
+ import { ModuleJoinerConfig } from "@medusajs/framework/types";
2
2
  export declare const OrderPromotion: ModuleJoinerConfig;
3
+ //# sourceMappingURL=order-promotion.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-promotion.d.ts","sourceRoot":"","sources":["../../src/definitions/order-promotion.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA;AAG9D,eAAO,MAAM,cAAc,EAAE,kBA2D5B,CAAA"}
@@ -1,8 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.OrderPromotion = void 0;
4
- const modules_sdk_1 = require("@medusajs/modules-sdk");
5
- const utils_1 = require("@medusajs/utils");
4
+ const utils_1 = require("@medusajs/framework/utils");
6
5
  exports.OrderPromotion = {
7
6
  serviceName: utils_1.LINKS.OrderPromotion,
8
7
  isLink: true,
@@ -13,44 +12,54 @@ exports.OrderPromotion = {
13
12
  alias: [
14
13
  {
15
14
  name: ["order_promotion", "order_promotions"],
16
- args: {
17
- entity: "LinkOrderPromotion",
18
- },
15
+ entity: "LinkOrderPromotion",
19
16
  },
20
17
  ],
21
18
  primaryKeys: ["id", "order_id", "promotion_id"],
22
19
  relationships: [
23
20
  {
24
- serviceName: modules_sdk_1.Modules.ORDER,
21
+ serviceName: utils_1.Modules.ORDER,
22
+ entity: "Order",
25
23
  primaryKey: "id",
26
24
  foreignKey: "order_id",
27
25
  alias: "order",
26
+ args: {
27
+ methodSuffix: "Orders",
28
+ },
28
29
  },
29
30
  {
30
- serviceName: modules_sdk_1.Modules.PROMOTION,
31
+ serviceName: utils_1.Modules.PROMOTION,
32
+ entity: "Promotion",
31
33
  primaryKey: "id",
32
34
  foreignKey: "promotion_id",
33
35
  alias: "promotion",
36
+ args: {
37
+ methodSuffix: "Promotions",
38
+ },
34
39
  },
35
40
  ],
36
41
  extends: [
37
42
  {
38
- serviceName: modules_sdk_1.Modules.ORDER,
43
+ serviceName: utils_1.Modules.ORDER,
44
+ fieldAlias: {
45
+ promotion: "promotion_link.promotion",
46
+ },
39
47
  relationship: {
40
48
  serviceName: utils_1.LINKS.OrderPromotion,
41
49
  primaryKey: "order_id",
42
50
  foreignKey: "id",
43
- alias: "order_link",
51
+ alias: "promotion_link",
44
52
  },
45
53
  },
46
54
  {
47
- serviceName: modules_sdk_1.Modules.PROMOTION,
55
+ serviceName: utils_1.Modules.PROMOTION,
48
56
  relationship: {
49
57
  serviceName: utils_1.LINKS.OrderPromotion,
50
58
  primaryKey: "promotion_id",
51
59
  foreignKey: "id",
52
- alias: "promotion_link",
60
+ alias: "order_link",
53
61
  },
54
62
  },
55
63
  ],
56
64
  };
65
+ //# sourceMappingURL=order-promotion.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-promotion.js","sourceRoot":"","sources":["../../src/definitions/order-promotion.ts"],"names":[],"mappings":";;;AACA,qDAA0D;AAE7C,QAAA,cAAc,GAAuB;IAChD,WAAW,EAAE,aAAK,CAAC,cAAc;IACjC,MAAM,EAAE,IAAI;IACZ,cAAc,EAAE;QACd,SAAS,EAAE,iBAAiB;QAC5B,QAAQ,EAAE,YAAY;KACvB;IACD,KAAK,EAAE;QACL;YACE,IAAI,EAAE,CAAC,iBAAiB,EAAE,kBAAkB,CAAC;YAC7C,MAAM,EAAE,oBAAoB;SAC7B;KACF;IACD,WAAW,EAAE,CAAC,IAAI,EAAE,UAAU,EAAE,cAAc,CAAC;IAC/C,aAAa,EAAE;QACb;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,MAAM,EAAE,OAAO;YACf,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,UAAU;YACtB,KAAK,EAAE,OAAO;YACd,IAAI,EAAE;gBACJ,YAAY,EAAE,QAAQ;aACvB;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,SAAS;YAC9B,MAAM,EAAE,WAAW;YACnB,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,cAAc;YAC1B,KAAK,EAAE,WAAW;YAClB,IAAI,EAAE;gBACJ,YAAY,EAAE,YAAY;aAC3B;SACF;KACF;IACD,OAAO,EAAE;QACP;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,UAAU,EAAE;gBACV,SAAS,EAAE,0BAA0B;aACtC;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,cAAc;gBACjC,UAAU,EAAE,UAAU;gBACtB,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,gBAAgB;aACxB;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,SAAS;YAC9B,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,cAAc;gBACjC,UAAU,EAAE,cAAc;gBAC1B,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,YAAY;aACpB;SACF;KACF;CACF,CAAA"}
@@ -0,0 +1,3 @@
1
+ import { ModuleJoinerConfig } from "@medusajs/framework/types";
2
+ export declare const ReturnFulfillment: ModuleJoinerConfig;
3
+ //# sourceMappingURL=order-return-fulfillment.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-return-fulfillment.d.ts","sourceRoot":"","sources":["../../src/definitions/order-return-fulfillment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA;AAG9D,eAAO,MAAM,iBAAiB,EAAE,kBA+D/B,CAAA"}
@@ -0,0 +1,69 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ReturnFulfillment = void 0;
4
+ const utils_1 = require("@medusajs/framework/utils");
5
+ exports.ReturnFulfillment = {
6
+ serviceName: utils_1.LINKS.ReturnFulfillment,
7
+ isLink: true,
8
+ databaseConfig: {
9
+ tableName: "return_fulfillment",
10
+ idPrefix: "retful",
11
+ },
12
+ alias: [
13
+ {
14
+ name: ["return_fulfillment", "return_fulfillments"],
15
+ entity: "LinkReturnFulfillment",
16
+ },
17
+ ],
18
+ primaryKeys: ["id", "return_id", "fulfillment_id"],
19
+ relationships: [
20
+ {
21
+ serviceName: utils_1.Modules.ORDER,
22
+ entity: "Order",
23
+ primaryKey: "id",
24
+ foreignKey: "return_id",
25
+ alias: "return",
26
+ args: {
27
+ methodSuffix: "Returns",
28
+ },
29
+ },
30
+ {
31
+ serviceName: utils_1.Modules.FULFILLMENT,
32
+ entity: "Fulfillment",
33
+ primaryKey: "id",
34
+ foreignKey: "fulfillment_id",
35
+ alias: "fulfillments",
36
+ args: {
37
+ methodSuffix: "Fulfillments",
38
+ },
39
+ },
40
+ ],
41
+ extends: [
42
+ {
43
+ serviceName: utils_1.Modules.ORDER,
44
+ fieldAlias: {
45
+ return_fulfillments: {
46
+ path: "return_fulfillment_link.fulfillments",
47
+ isList: true,
48
+ },
49
+ },
50
+ relationship: {
51
+ serviceName: utils_1.LINKS.OrderFulfillment,
52
+ primaryKey: "return_id",
53
+ foreignKey: "id",
54
+ alias: "return_fulfillment_link",
55
+ isList: true,
56
+ },
57
+ },
58
+ {
59
+ serviceName: utils_1.Modules.FULFILLMENT,
60
+ relationship: {
61
+ serviceName: utils_1.LINKS.OrderFulfillment,
62
+ primaryKey: "fulfillment_id",
63
+ foreignKey: "id",
64
+ alias: "return_link",
65
+ },
66
+ },
67
+ ],
68
+ };
69
+ //# sourceMappingURL=order-return-fulfillment.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-return-fulfillment.js","sourceRoot":"","sources":["../../src/definitions/order-return-fulfillment.ts"],"names":[],"mappings":";;;AACA,qDAA0D;AAE7C,QAAA,iBAAiB,GAAuB;IACnD,WAAW,EAAE,aAAK,CAAC,iBAAiB;IACpC,MAAM,EAAE,IAAI;IACZ,cAAc,EAAE;QACd,SAAS,EAAE,oBAAoB;QAC/B,QAAQ,EAAE,QAAQ;KACnB;IACD,KAAK,EAAE;QACL;YACE,IAAI,EAAE,CAAC,oBAAoB,EAAE,qBAAqB,CAAC;YACnD,MAAM,EAAE,uBAAuB;SAChC;KACF;IACD,WAAW,EAAE,CAAC,IAAI,EAAE,WAAW,EAAE,gBAAgB,CAAC;IAClD,aAAa,EAAE;QACb;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,MAAM,EAAE,OAAO;YACf,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,WAAW;YACvB,KAAK,EAAE,QAAQ;YACf,IAAI,EAAE;gBACJ,YAAY,EAAE,SAAS;aACxB;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,WAAW;YAChC,MAAM,EAAE,aAAa;YACrB,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,gBAAgB;YAC5B,KAAK,EAAE,cAAc;YACrB,IAAI,EAAE;gBACJ,YAAY,EAAE,cAAc;aAC7B;SACF;KACF;IACD,OAAO,EAAE;QACP;YACE,WAAW,EAAE,eAAO,CAAC,KAAK;YAC1B,UAAU,EAAE;gBACV,mBAAmB,EAAE;oBACnB,IAAI,EAAE,sCAAsC;oBAC5C,MAAM,EAAE,IAAI;iBACb;aACF;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,gBAAgB;gBACnC,UAAU,EAAE,WAAW;gBACvB,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,yBAAyB;gBAChC,MAAM,EAAE,IAAI;aACb;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,WAAW;YAChC,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,gBAAgB;gBACnC,UAAU,EAAE,gBAAgB;gBAC5B,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,aAAa;aACrB;SACF;KACF;CACF,CAAA"}
@@ -1,2 +1,3 @@
1
- import { ModuleJoinerConfig } from "@medusajs/types";
1
+ import { ModuleJoinerConfig } from "@medusajs/framework/types";
2
2
  export declare const ProductSalesChannel: ModuleJoinerConfig;
3
+ //# sourceMappingURL=product-sales-channel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-sales-channel.d.ts","sourceRoot":"","sources":["../../src/definitions/product-sales-channel.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA;AAG9D,eAAO,MAAM,mBAAmB,EAAE,kBAkEjC,CAAA"}
@@ -1,8 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ProductSalesChannel = void 0;
4
- const modules_sdk_1 = require("@medusajs/modules-sdk");
5
- const utils_1 = require("@medusajs/utils");
4
+ const utils_1 = require("@medusajs/framework/utils");
6
5
  exports.ProductSalesChannel = {
7
6
  serviceName: utils_1.LINKS.ProductSalesChannel,
8
7
  isLink: true,
@@ -21,24 +20,34 @@ exports.ProductSalesChannel = {
21
20
  primaryKeys: ["id", "product_id", "sales_channel_id"],
22
21
  relationships: [
23
22
  {
24
- serviceName: modules_sdk_1.Modules.PRODUCT,
23
+ serviceName: utils_1.Modules.PRODUCT,
24
+ entity: "Product",
25
25
  primaryKey: "id",
26
26
  foreignKey: "product_id",
27
27
  alias: "product",
28
+ args: {
29
+ methodSuffix: "Products",
30
+ },
28
31
  },
29
32
  {
30
- serviceName: modules_sdk_1.Modules.SALES_CHANNEL,
31
- isInternalService: true,
33
+ serviceName: utils_1.Modules.SALES_CHANNEL,
34
+ entity: "SalesChannel",
32
35
  primaryKey: "id",
33
36
  foreignKey: "sales_channel_id",
34
37
  alias: "sales_channel",
38
+ args: {
39
+ methodSuffix: "SalesChannels",
40
+ },
35
41
  },
36
42
  ],
37
43
  extends: [
38
44
  {
39
- serviceName: modules_sdk_1.Modules.PRODUCT,
45
+ serviceName: utils_1.Modules.PRODUCT,
40
46
  fieldAlias: {
41
- sales_channels: "sales_channels_link.sales_channel",
47
+ sales_channels: {
48
+ path: "sales_channels_link.sales_channel",
49
+ isList: true,
50
+ },
42
51
  },
43
52
  relationship: {
44
53
  serviceName: utils_1.LINKS.ProductSalesChannel,
@@ -49,10 +58,9 @@ exports.ProductSalesChannel = {
49
58
  },
50
59
  },
51
60
  {
52
- serviceName: modules_sdk_1.Modules.SALES_CHANNEL,
61
+ serviceName: utils_1.Modules.SALES_CHANNEL,
53
62
  relationship: {
54
63
  serviceName: utils_1.LINKS.ProductSalesChannel,
55
- isInternalService: true,
56
64
  primaryKey: "sales_channel_id",
57
65
  foreignKey: "id",
58
66
  alias: "products_link",
@@ -61,3 +69,4 @@ exports.ProductSalesChannel = {
61
69
  },
62
70
  ],
63
71
  };
72
+ //# sourceMappingURL=product-sales-channel.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-sales-channel.js","sourceRoot":"","sources":["../../src/definitions/product-sales-channel.ts"],"names":[],"mappings":";;;AACA,qDAA0D;AAE7C,QAAA,mBAAmB,GAAuB;IACrD,WAAW,EAAE,aAAK,CAAC,mBAAmB;IACtC,MAAM,EAAE,IAAI;IACZ,cAAc,EAAE;QACd,SAAS,EAAE,uBAAuB;QAClC,QAAQ,EAAE,QAAQ;KACnB;IACD,KAAK,EAAE;QACL;YACE,IAAI,EAAE,uBAAuB;SAC9B;QACD;YACE,IAAI,EAAE,wBAAwB;SAC/B;KACF;IACD,WAAW,EAAE,CAAC,IAAI,EAAE,YAAY,EAAE,kBAAkB,CAAC;IACrD,aAAa,EAAE;QACb;YACE,WAAW,EAAE,eAAO,CAAC,OAAO;YAC5B,MAAM,EAAE,SAAS;YACjB,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,YAAY;YACxB,KAAK,EAAE,SAAS;YAChB,IAAI,EAAE;gBACJ,YAAY,EAAE,UAAU;aACzB;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,aAAa;YAClC,MAAM,EAAE,cAAc;YACtB,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,kBAAkB;YAC9B,KAAK,EAAE,eAAe;YACtB,IAAI,EAAE;gBACJ,YAAY,EAAE,eAAe;aAC9B;SACF;KACF;IACD,OAAO,EAAE;QACP;YACE,WAAW,EAAE,eAAO,CAAC,OAAO;YAC5B,UAAU,EAAE;gBACV,cAAc,EAAE;oBACd,IAAI,EAAE,mCAAmC;oBACzC,MAAM,EAAE,IAAI;iBACb;aACF;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,mBAAmB;gBACtC,UAAU,EAAE,YAAY;gBACxB,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,qBAAqB;gBAC5B,MAAM,EAAE,IAAI;aACb;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,aAAa;YAClC,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,mBAAmB;gBACtC,UAAU,EAAE,kBAAkB;gBAC9B,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,eAAe;gBACtB,MAAM,EAAE,IAAI;aACb;SACF;KACF;CACF,CAAA"}
@@ -1,2 +1,3 @@
1
- import { ModuleJoinerConfig } from "@medusajs/types";
1
+ import { ModuleJoinerConfig } from "@medusajs/framework/types";
2
2
  export declare const ProductVariantInventoryItem: ModuleJoinerConfig;
3
+ //# sourceMappingURL=product-variant-inventory-item.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-variant-inventory-item.d.ts","sourceRoot":"","sources":["../../src/definitions/product-variant-inventory-item.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA;AAG9D,eAAO,MAAM,2BAA2B,EAAE,kBA6EzC,CAAA"}
@@ -1,8 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ProductVariantInventoryItem = void 0;
4
- const utils_1 = require("@medusajs/utils");
5
- const modules_sdk_1 = require("@medusajs/modules-sdk");
4
+ const utils_1 = require("@medusajs/framework/utils");
6
5
  exports.ProductVariantInventoryItem = {
7
6
  serviceName: utils_1.LINKS.ProductVariantInventoryItem,
8
7
  isLink: true,
@@ -22,33 +21,39 @@ exports.ProductVariantInventoryItem = {
22
21
  "product_variant_inventory_item",
23
22
  "product_variant_inventory_items",
24
23
  ],
25
- args: {
26
- entity: "LinkProductVariantInventoryItem",
27
- },
24
+ entity: "LinkProductVariantInventoryItem",
28
25
  },
29
26
  ],
30
27
  primaryKeys: ["id", "variant_id", "inventory_item_id"],
31
28
  relationships: [
32
29
  {
33
- serviceName: modules_sdk_1.Modules.PRODUCT,
30
+ serviceName: utils_1.Modules.PRODUCT,
31
+ entity: "ProductVariant",
34
32
  primaryKey: "id",
35
33
  foreignKey: "variant_id",
36
34
  alias: "variant",
37
35
  args: {
38
- methodSuffix: "Variants",
36
+ methodSuffix: "ProductVariants",
39
37
  },
40
38
  },
41
39
  {
42
- serviceName: modules_sdk_1.Modules.INVENTORY,
40
+ serviceName: utils_1.Modules.INVENTORY,
41
+ entity: "InventoryItem",
43
42
  primaryKey: "id",
44
43
  foreignKey: "inventory_item_id",
45
44
  alias: "inventory",
45
+ args: {
46
+ methodSuffix: "InventoryItems",
47
+ },
46
48
  deleteCascade: true,
47
49
  },
48
50
  ],
49
51
  extends: [
50
52
  {
51
- serviceName: modules_sdk_1.Modules.PRODUCT,
53
+ serviceName: utils_1.Modules.PRODUCT,
54
+ fieldAlias: {
55
+ inventory: "inventory_items.inventory",
56
+ },
52
57
  relationship: {
53
58
  serviceName: utils_1.LINKS.ProductVariantInventoryItem,
54
59
  primaryKey: "variant_id",
@@ -58,16 +63,21 @@ exports.ProductVariantInventoryItem = {
58
63
  },
59
64
  },
60
65
  {
61
- serviceName: modules_sdk_1.Modules.INVENTORY,
66
+ serviceName: utils_1.Modules.INVENTORY,
62
67
  fieldAlias: {
63
- variant: "variant_link.variant",
68
+ variants: {
69
+ path: "variant_link.variant",
70
+ isList: true,
71
+ },
64
72
  },
65
73
  relationship: {
66
74
  serviceName: utils_1.LINKS.ProductVariantInventoryItem,
67
75
  primaryKey: "inventory_item_id",
68
76
  foreignKey: "id",
69
77
  alias: "variant_link",
78
+ isList: true,
70
79
  },
71
80
  },
72
81
  ],
73
82
  };
83
+ //# sourceMappingURL=product-variant-inventory-item.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-variant-inventory-item.js","sourceRoot":"","sources":["../../src/definitions/product-variant-inventory-item.ts"],"names":[],"mappings":";;;AACA,qDAA0D;AAE7C,QAAA,2BAA2B,GAAuB;IAC7D,WAAW,EAAE,aAAK,CAAC,2BAA2B;IAC9C,MAAM,EAAE,IAAI;IACZ,cAAc,EAAE;QACd,SAAS,EAAE,gCAAgC;QAC3C,QAAQ,EAAE,QAAQ;QAClB,WAAW,EAAE;YACX,iBAAiB,EAAE;gBACjB,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,GAAG;aAClB;SACF;KACF;IACD,KAAK,EAAE;QACL;YACE,IAAI,EAAE;gBACJ,gCAAgC;gBAChC,iCAAiC;aAClC;YACD,MAAM,EAAE,iCAAiC;SAC1C;KACF;IACD,WAAW,EAAE,CAAC,IAAI,EAAE,YAAY,EAAE,mBAAmB,CAAC;IACtD,aAAa,EAAE;QACb;YACE,WAAW,EAAE,eAAO,CAAC,OAAO;YAC5B,MAAM,EAAE,gBAAgB;YACxB,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,YAAY;YACxB,KAAK,EAAE,SAAS;YAChB,IAAI,EAAE;gBACJ,YAAY,EAAE,iBAAiB;aAChC;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,SAAS;YAC9B,MAAM,EAAE,eAAe;YACvB,UAAU,EAAE,IAAI;YAChB,UAAU,EAAE,mBAAmB;YAC/B,KAAK,EAAE,WAAW;YAClB,IAAI,EAAE;gBACJ,YAAY,EAAE,gBAAgB;aAC/B;YACD,aAAa,EAAE,IAAI;SACpB;KACF;IACD,OAAO,EAAE;QACP;YACE,WAAW,EAAE,eAAO,CAAC,OAAO;YAC5B,UAAU,EAAE;gBACV,SAAS,EAAE,2BAA2B;aACvC;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,2BAA2B;gBAC9C,UAAU,EAAE,YAAY;gBACxB,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,iBAAiB;gBACxB,MAAM,EAAE,IAAI;aACb;SACF;QACD;YACE,WAAW,EAAE,eAAO,CAAC,SAAS;YAC9B,UAAU,EAAE;gBACV,QAAQ,EAAE;oBACR,IAAI,EAAE,sBAAsB;oBAC5B,MAAM,EAAE,IAAI;iBACb;aACF;YACD,YAAY,EAAE;gBACZ,WAAW,EAAE,aAAK,CAAC,2BAA2B;gBAC9C,UAAU,EAAE,mBAAmB;gBAC/B,UAAU,EAAE,IAAI;gBAChB,KAAK,EAAE,cAAc;gBACrB,MAAM,EAAE,IAAI;aACb;SACF;KACF;CACF,CAAA"}
@@ -1,2 +1,3 @@
1
- import { ModuleJoinerConfig } from "@medusajs/types";
1
+ import { ModuleJoinerConfig } from "@medusajs/framework/types";
2
2
  export declare const ProductVariantPriceSet: ModuleJoinerConfig;
3
+ //# sourceMappingURL=product-variant-price-set.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-variant-price-set.d.ts","sourceRoot":"","sources":["../../src/definitions/product-variant-price-set.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAA;AAG9D,eAAO,MAAM,sBAAsB,EAAE,kBAwEpC,CAAA"}